diff options
author | Stan Seibert <stan@mtrr.org> | 2011-08-05 22:17:39 -0400 |
---|---|---|
committer | Stan Seibert <stan@mtrr.org> | 2011-08-05 22:17:39 -0400 |
commit | 8a084b191c52b5c2bc84ce92d194d27fee2190f8 (patch) | |
tree | 4af6f6d3cc486108f76dfa2dc43839727ef1ad6d | |
parent | 1ffc7c5ab50bd1f27721f818ae137d3ea41add7d (diff) | |
download | chroma-8a084b191c52b5c2bc84ce92d194d27fee2190f8.tar.gz chroma-8a084b191c52b5c2bc84ce92d194d27fee2190f8.tar.bz2 chroma-8a084b191c52b5c2bc84ce92d194d27fee2190f8.zip |
Fix typo in setting direction of particle from sim.py command line.
-rwxr-xr-x | sim.py | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -39,7 +39,7 @@ if __name__ == '__main__': parser.add_option('--particle', type='string', dest='particle', default='e-') parser.add_option('--energy', type='float', dest='energy', default=100.0) parser.add_option('--pos', type='string', dest='pos', default='(0,0,0)') - parser.add_option('--dir', type='string', dest='pos', default='(1,0,0)') + parser.add_option('--dir', type='string', dest='dir', default='(1,0,0)') options, args = parser.parse_args() if len(args) != 1: @@ -53,7 +53,7 @@ if __name__ == '__main__': sys.exit(1) position = np.array(eval(options.pos), dtype=float) - direction = np.array(eval(options.pos), dtype=float) + direction = np.array(eval(options.dir), dtype=float) detector = detectors.find(options.detector) print >>sys.stderr, 'Creating detector...' @@ -102,7 +102,7 @@ if __name__ == '__main__': position=position, direction=direction) nphotons += len(photons['pos']) - + # this will stop and wait for event to finish hit_times = gpu_worker.get_hits() |