summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStan Seibert <stan@mtrr.org>2011-08-08 15:50:15 -0400
committerStan Seibert <stan@mtrr.org>2011-08-08 15:50:15 -0400
commitf407488241846ec4c566131a0954689f75b8d1cf (patch)
treec8b7069629ac4b1e76b389f6425688aee247f90b
parentfd2cba0f96e2d145e6a2b6e3df91cb6e942c114c (diff)
downloadchroma-f407488241846ec4c566131a0954689f75b8d1cf.tar.gz
chroma-f407488241846ec4c566131a0954689f75b8d1cf.tar.bz2
chroma-f407488241846ec4c566131a0954689f75b8d1cf.zip
Oops. The generator is a process, not a thread.
-rwxr-xr-xsim.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/sim.py b/sim.py
index 9e5f9bd..13e53c6 100755
--- a/sim.py
+++ b/sim.py
@@ -28,7 +28,7 @@ def info(type, value, tb):
sys.excepthook = info
-class GeneratorThread(multiprocessing.Process):
+class GeneratorProcess(multiprocessing.Process):
def __init__(self, particle, energy, position, direction, nevents, material):
multiprocessing.Process.__init__(self)
@@ -114,12 +114,12 @@ def main():
print >>sys.stderr, 'Creating generator...'
detector_material = optics.water
- generator_thread = GeneratorThread(particle=options.particle,
- energy=options.energy,
- position=position,
- direction=direction,
- nevents=options.nevents,
- material=detector_material)
+ generator_thread = GeneratorProcess(particle=options.particle,
+ energy=options.energy,
+ position=position,
+ direction=direction,
+ nevents=options.nevents,
+ material=detector_material)
print >>sys.stderr, 'WARNING: ASSUMING DETECTOR IS WATER!!'
# Do this now so we can get ahead of the photon propagation