From f6109fc8939c55a9ef8244806d00b3ee07ee1b13 Mon Sep 17 00:00:00 2001 From: Anthony LaTorre Date: Mon, 8 Aug 2011 11:03:07 -0400 Subject: add a simple event viewer. view events by running ./camera.py -i . --- detectors/lbne.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'detectors/lbne.py') diff --git a/detectors/lbne.py b/detectors/lbne.py index 8fe2c18..3e8ae7b 100644 --- a/detectors/lbne.py +++ b/detectors/lbne.py @@ -6,21 +6,24 @@ dir = os.path.split(os.path.realpath(__file__))[0] sys.path.append(dir + '/..') from geometry import * -from solids import build_12inch_pmt, build_12inch_pmt_with_lc +from solids import build_12inch_pmt, build_12inch_pmt_with_lc, build_12inch_pmt_shell from optics import * from transform import rotate, make_rotation_matrix from itertools import product from make import cylinder -def build_lbne(radius, height, nstrings, pmts_per_string, endcap_spacing): - pmt = build_12inch_pmt_with_lc() +def build_lbne(radius, height, nstrings, pmts_per_string, endcap_spacing, physical_model=True): + if physical_model: + pmt = build_12inch_pmt_with_lc() + else: + pmt = build_12inch_pmt_shell() lbne = Geometry() # outer cylinder cylinder_mesh = cylinder(radius, radius, height+height/(pmts_per_string-1), theta=(2*np.pi/nstrings)/4) cylinder_mesh.vertices = rotate(cylinder_mesh.vertices, np.pi/2, (-1,0,0)) - lbne.add_solid(Solid(cylinder_mesh, water, vacuum, black_surface, 0x990000ff)) + lbne.add_solid(Solid(cylinder_mesh, water, vacuum, black_surface, 0xff0000ff)) lbne.pmtids = [] -- cgit