rundphase.sh
Go to the documentation of this file.
1 #!/bin/bash
2 
3 ####################
4 ### Far detector ###
5 ####################
6 
7 echo "--- Generating Far Detector Geometry ---"
8 
9 # with wires for larcore
10 perl generate_dunedphase10kt_v2.pl -w 1 -o dphase_geo.xml
11 perl make_gdml.pl -i dphase_geo.xml -o dunedphase10kt_v2.gdml
12 
13 # clean up
14 rm dunedphase10kt_v2_*.gdml
15 rm dphase_geo.xml
16 
17 # no wires for geant
18 perl generate_dunedphase10kt_v2.pl -w 0 -o dphase_geo_nowires.xml
19 perl make_gdml.pl -i dphase_geo_nowires.xml -o dunedphase10kt_v2_nowires.gdml
20 
21 # clean up
22 rm dunedphase10kt_v2_nowires_*.gdml
23 rm dphase_geo_nowires.xml
24 
25 
26 #################################
27 ### Far detector (drift in Y) ###
28 #################################
29 
30 echo "--- Generating Far Detector Geometry Drift in Y--- No Foils"
31 
32 # with wires for larcore
33 perl generate_dunedphase10kt_v2_driftY.pl -w 1 -o dphase_geo_driftY.xml --pmtdensity 1 --TPBFoils 0
34 perl make_gdml.pl -i dphase_geo_driftY.xml -o dunedphase10kt_v2_driftY.gdml
35 
36 # clean up
37 rm dunedphase10kt_v2_driftY_*.gdml
38 rm dphase_geo_driftY.xml
39 
40 # no wires for geant
41 perl generate_dunedphase10kt_v2_driftY.pl -w 0 -o dphase_geo_driftY_nowires.xml --pmtdensity 1 --TPBFoils 0
42 perl make_gdml.pl -i dphase_geo_driftY_nowires.xml -o dunedphase10kt_v2_driftY_nowires.gdml
43 
44 # clean up
45 rm dunedphase10kt_v2_driftY_nowires_*.gdml
46 rm dphase_geo_driftY_nowires.xml
47 
48 
49 echo "--- Generating Far Detector Geometry Drift in Y--- Full Foil"
50 
51 # with wires for larcore
52 perl generate_dunedphase10kt_v2_driftY.pl -w 1 -o dphase_geo_driftY_Foil.xml --pmtdensity 1 --TPBFoils 1
53 perl make_gdml.pl -i dphase_geo_driftY_Foil.xml -o dunedphase10kt_v2_driftY_Foil.gdml
54 
55 # clean up
56 rm dunedphase10kt_v2_driftY_Foil_*.gdml
57 rm dphase_geo_driftY_Foil.xml
58 
59 # no wires for geant
60 perl generate_dunedphase10kt_v2_driftY.pl -w 0 -o dphase_geo_driftY_Foil_nowires.xml --pmtdensity 1 --TPBFoils 1
61 perl make_gdml.pl -i dphase_geo_driftY_Foil_nowires.xml -o dunedphase10kt_v2_driftY_Foil_nowires.gdml
62 
63 # clean up
64 rm dunedphase10kt_v2_driftY_Foil_nowires_*.gdml
65 rm dphase_geo_driftY_Foil_nowires.xml
66 
67 echo "--- Generating Far Detector Geometry Drift in Y--- Half Foil"
68 # with wires for larcore
69 perl generate_dunedphase10kt_v2_driftY.pl -w 1 -o dphase_geo_driftY_HalfFoil.xml --pmtdensity 1 --TPBFoils 2
70 perl make_gdml.pl -i dphase_geo_driftY_HalfFoil.xml -o dunedphase10kt_v2_driftY_HalfFoil.gdml
71 
72 # clean up
73 rm dunedphase10kt_v2_driftY_HalfFoil_*.gdml
74 rm dphase_geo_driftY_HalfFoil.xml
75 
76 # no wires for geant
77 perl generate_dunedphase10kt_v2_driftY.pl -w 0 -o dphase_geo_driftY_HalfFoil_nowires.xml --pmtdensity 1 --TPBFoils 2
78 perl make_gdml.pl -i dphase_geo_driftY_HalfFoil_nowires.xml -o dunedphase10kt_v2_driftY_HalfFoil_nowires.gdml
79 
80 # clean up
81 rm dunedphase10kt_v2_driftY_HalfFoil_nowires_*.gdml
82 rm dphase_geo_driftY_HalfFoil_nowires.xml
83 
84 echo "--- Generating Far Detector Geometry Drift in Y--- No Foil - 2PMT per M2"
85 # with wires for larcore
86 perl generate_dunedphase10kt_v2_driftY.pl -w 1 -o dphase_geo_driftY_2PMTperM2.xml --pmtdensity 2 --TPBFoils 0
87 perl make_gdml.pl -i dphase_geo_driftY_2PMTperM2.xml -o dunedphase10kt_v2_driftY_2PMTperM2.gdml
88 
89 # clean up
90 rm dunedphase10kt_v2_driftY_2PMTperM2_*.gdml
91 rm dphase_geo_driftY_2PMTperM2.xml
92 
93 # no wires for geant
94 perl generate_dunedphase10kt_v2_driftY.pl -w 0 -o dphase_geo_driftY_2PMTperM2_nowires.xml --pmtdensity 2 --TPBFoils 0
95 perl make_gdml.pl -i dphase_geo_driftY_2PMTperM2_nowires.xml -o dunedphase10kt_v2_driftY_2PMTperM2_nowires.gdml
96 
97 # clean up
98 rm dunedphase10kt_v2_driftY_2PMTperM2_nowires_*.gdml
99 rm dphase_geo_driftY_2PMTperM2_nowires.xml
100 
101 
102 
103 echo "--- Generating Far Detector Geometry Drift in Y--- Half Foil - 2PMT per M2"
104 # with wires for larcore
105 perl generate_dunedphase10kt_v2_driftY.pl -w 1 -o dphase_geo_driftY_2PMTperM2_HalfFoil.xml --pmtdensity 2 --TPBFoils 2
106 perl make_gdml.pl -i dphase_geo_driftY_2PMTperM2_HalfFoil.xml -o dunedphase10kt_v2_driftY_2PMTperM2_HalfFoil.gdml
107 
108 # clean up
109 rm dunedphase10kt_v2_driftY_2PMTperM2_HalfFoil_*.gdml
110 rm dphase_geo_driftY_2PMTperM2_HalfFoil.xml
111 
112 # no wires for geant
113 perl generate_dunedphase10kt_v2_driftY.pl -w 0 -o dphase_geo_driftY_2PMTperM2_HalfFoil_nowires.xml --pmtdensity 2 --TPBFoils 2
114 perl make_gdml.pl -i dphase_geo_driftY_2PMTperM2_HalfFoil_nowires.xml -o dunedphase10kt_v2_driftY_2PMTperM2_HalfFoil_nowires.gdml
115 
116 # clean up
117 rm dunedphase10kt_v2_driftY_2PMTperM2_HalfFoil_nowires_*.gdml
118 rm dphase_geo_driftY_2PMTperM2_HalfFoil_nowires.xml
119 
120 ########################################
121 ### Far detector workspace: 2x1 TPCs ###
122 ########################################
123 
124 echo "--- Generating Far Detector Geometry 2x1 workspace ---"
125 
126 # with wires for larcore
127 perl generate_dunedphase10kt_v2.pl -w 1 -k 1 -o dphase_geo_workspace.xml
128 perl make_gdml.pl -i dphase_geo_workspace.xml -o dunedphase10kt_v2_workspace.gdml
129 
130 # clean up
131 rm dunedphase10kt_v2_workspace_*.gdml
132 rm dphase_geo_workspace.xml
133 
134 # no wires for geant
135 perl generate_dunedphase10kt_v2.pl -w 0 -k 1 -o dphase_geo_workspace_nowires.xml
136 perl make_gdml.pl -i dphase_geo_workspace_nowires.xml -o dunedphase10kt_v2_workspace_nowires.gdml
137 
138 # clean up
139 rm dunedphase10kt_v2_workspace_nowires_*.gdml
140 rm dphase_geo_workspace_nowires.xml
141 
142 
143 #####################################################
144 ### Far detector workspace: 2x1 TPCs (drift in Y) ###
145 #####################################################
146 
147 echo "--- Generating Far Detector Geometry 2x1 workspace Drift in Y ---"
148 
149 # with wires for larcore
150 perl generate_dunedphase10kt_v2_driftY.pl -w 1 -k 1 -o dphase_geo_driftY_workspace.xml --pmtdensity 1 --TPBFoils 0
151 perl make_gdml.pl -i dphase_geo_driftY_workspace.xml -o dunedphase10kt_v2_driftY_workspace.gdml
152 
153 # clean up
154 rm dunedphase10kt_v2_driftY_workspace_*.gdml
155 rm dphase_geo_driftY_workspace.xml
156 
157 # no wires for geant
158 perl generate_dunedphase10kt_v2_driftY.pl -w 0 -k 1 -o dphase_geo_driftY_workspace_nowires.xml --pmtdensity 1 --TPBFoils 0
159 perl make_gdml.pl -i dphase_geo_driftY_workspace_nowires.xml -o dunedphase10kt_v2_driftY_workspace_nowires.gdml
160 
161 # clean up
162 rm dunedphase10kt_v2_driftY_workspace_nowires_*.gdml
163 rm dphase_geo_driftY_workspace_nowires.xml
164 
165 ########################################
166 ### Far detector workspace: 4x2 TPCs ###
167 ########################################
168 
169 echo "--- Generating Far Detector Geometry 4x2 workspace ---"
170 
171 # with wires for larcore
172 perl generate_dunedphase10kt_v2.pl -w 1 -k 2 -o dphase_geo_workspace4x2.xml
173 perl make_gdml.pl -i dphase_geo_workspace4x2.xml -o dunedphase10kt_v2_workspace4x2.gdml
174 
175 # clean up
176 rm dunedphase10kt_v2_workspace4x2_*.gdml
177 rm dphase_geo_workspace4x2.xml
178 
179 # no wires for geant
180 perl generate_dunedphase10kt_v2.pl -w 0 -k 2 -o dphase_geo_workspace4x2_nowires.xml -w 0
181 perl make_gdml.pl -i dphase_geo_workspace4x2_nowires.xml -o dunedphase10kt_v2_workspace4x2_nowires.gdml
182 
183 # clean up
184 rm dunedphase10kt_v2_workspace4x2_nowires_*.gdml
185 rm dphase_geo_workspace4x2_nowires.xml
186 
187 
188 #####################################################
189 ### Far detector workspace: 4x2 TPCs (drift in Y) ###
190 #####################################################
191 
192 echo "--- Generating Far Detector Geometry 4x2 workspace Drift in Y ---"
193 
194 # with wires for larcore
195 perl generate_dunedphase10kt_v2_driftY.pl -w 1 -k 2 -o dphase_geo_driftY_workspace4x2.xml --pmtdensity 1 --TPBFoils 0
196 perl make_gdml.pl -i dphase_geo_driftY_workspace4x2.xml -o dunedphase10kt_v2_driftY_workspace4x2.gdml
197 
198 # clean up
199 rm dunedphase10kt_v2_driftY_workspace4x2_*.gdml
200 rm dphase_geo_driftY_workspace4x2.xml
201 
202 # no wires for geant
203 perl generate_dunedphase10kt_v2_driftY.pl -w 0 -k 2 -o dphase_geo_driftY_workspace4x2_nowires.xml -w 0 --pmtdensity 1 --TPBFoils 0
204 perl make_gdml.pl -i dphase_geo_driftY_workspace4x2_nowires.xml -o dunedphase10kt_v2_driftY_workspace4x2_nowires.gdml
205 
206 # clean up
207 rm dunedphase10kt_v2_driftY_workspace4x2_nowires_*.gdml
208 rm dphase_geo_driftY_workspace4x2_nowires.xml
209 
210 
211 #####################################################
212 ### Far detector workspace: 3x3 TPCs (drift in Y) ###
213 #####################################################
214 
215 echo "--- Generating Far Detector Geometry 3x3 workspace Drift in Y ---"
216 
217 # with wires for larcore
218 perl generate_dunedphase10kt_v2_driftY.pl -w 1 -k 3 -o dphase_geo_driftY_workspace3x3.xml --pmtdensity 1 --TPBFoils 0
219 perl make_gdml.pl -i dphase_geo_driftY_workspace3x3.xml -o dunedphase10kt_v2_driftY_workspace3x3.gdml
220 
221 # clean up
222 rm dunedphase10kt_v2_driftY_workspace3x3_*.gdml
223 rm dphase_geo_driftY_workspace3x3.xml
224 
225 # no wires for geant
226 perl generate_dunedphase10kt_v2_driftY.pl -w 0 -k 3 -o dphase_geo_driftY_workspace3x3_nowires.xml -w 0 --pmtdensity 1 --TPBFoils 0
227 perl make_gdml.pl -i dphase_geo_driftY_workspace3x3_nowires.xml -o dunedphase10kt_v2_driftY_workspace3x3_nowires.gdml
228 
229 # clean up
230 rm dunedphase10kt_v2_driftY_workspace3x3_nowires_*.gdml
231 rm dphase_geo_driftY_workspace3x3_nowires.xml
232 
233 
234 ####################
235 ### protoDUNE-DP ###
236 ####################
237 
238 echo "--- Generating protoDUNEDP Geometry ---"
239 
240 # with wires for larcore
241 perl generate_protodunedphase.pl -w 1 -opt 0 -o protodunedphase_geo.xml
242 perl make_gdml.pl -i protodunedphase_geo.xml -o protodunedphase.gdml
243 
244 # clean up
245 rm protodunedphase_geo.xml
246 rm protodunedphase_*.gdml
247 
248 # no wires for geant
249 perl generate_protodunedphase.pl -w 0 -opt 0 -o protodunedphase_geo_nowires.xml
250 perl make_gdml.pl -i protodunedphase_geo_nowires.xml -o protodunedphase_nowires.gdml
251 
252 # clean up
253 rm protodunedphase_geo_nowires.xml
254 rm protodunedphase_nowires_*.gdml
255 
256 
257 #########################################
258 ### protoDUNE-DP rotated (drift in Y) ###
259 #########################################
260 
261 echo "--- Generating protoDUNEDP Geometry Drift in Y ---"
262 
263 # with wires for larcore
264 perl generate_protodunedphase_driftY.pl -w 1 -opt 0 -o protodunedphase_driftY_geo.xml -pmt 0
265 perl make_gdml.pl -i protodunedphase_driftY_geo.xml -o protodunedphase_driftY.gdml
266 
267 # clean up
268 rm protodunedphase_driftY_geo.xml
269 rm protodunedphase_driftY_*.gdml
270 
271 # no wires for geant
272 perl generate_protodunedphase_driftY.pl -w 0 -opt 0 -o protodunedphase_driftY_nowires_geo.xml -pmt 0
273 perl make_gdml.pl -i protodunedphase_driftY_nowires_geo.xml -o protodunedphase_driftY_nowires.gdml
274 
275 # clean up
276 rm protodunedphase_driftY_nowires_geo.xml
277 rm protodunedphase_driftY_nowires_*.gdml
278 
279 
280 echo "--- Generating protoDUNEDP Geometry Drift in Y - Uniform PMT Layout - to be deprecated ---"
281 
282 # with wires for larcore
283 perl generate_protodunedphase_driftY.pl -w 1 -opt 0 -o protodunedphase_driftY_uniform_geo.xml -pmt 1
284 perl make_gdml.pl -i protodunedphase_driftY_uniform_geo.xml -o protodunedphase_driftY_uniform.gdml
285 
286 # clean up
287 rm protodunedphase_driftY_uniform_geo.xml
288 rm protodunedphase_driftY_uniform_*.gdml
289 
290 # no wires for geant
291 perl generate_protodunedphase_driftY.pl -w 0 -opt 0 -o protodunedphase_driftY_uniform_nowires_geo.xml -pmt 1
292 perl make_gdml.pl -i protodunedphase_driftY_uniform_nowires_geo.xml -o protodunedphase_driftY_uniform_nowires.gdml
293 
294 # clean up
295 rm protodunedphase_driftY_uniform_nowires_geo.xml
296 rm protodunedphase_driftY_uniform_nowires_*.gdml
297 
298 
299 ##################################################
300 ### protoDUNE-DP for photon library generation ###
301 ##################################################
302 
303 echo "--- Generating protoDUNEDP OPTICAL Geometry ---"
304 
305 # all detail to generate photon libraries
306 perl generate_protodunedphase.pl -w 1 -opt 1 -o protodunedphase_optical_geo.xml
307 perl make_gdml.pl -i protodunedphase_optical_geo.xml -o protodunedphase_optical.gdml
308 
309 # clean up
310 rm protodunedphase_optical_geo.xml
311 rm protodunedphase_optical_*.gdml
312 
313 # no wires for geant
314 perl generate_protodunedphase.pl -w 0 -opt 1 -o protodunedphase_optical_nowires_geo.xml
315 perl make_gdml.pl -i protodunedphase_optical_nowires_geo.xml -o protodunedphase_optical_nowires.gdml
316 
317 # clean up
318 rm protodunedphase_optical_nowires_geo.xml
319 rm protodunedphase_optical_nowires_*.gdml
320 
321 echo "--- Generating protoDUNEDP OPTICAL Geometry Drift in Y ---"
322 
323 # all detail to generate photon libraries
324 perl generate_protodunedphase_driftY.pl -w 1 -opt 1 -o protodunedphase_driftY_optical_geo.xml -pmt 0
325 perl make_gdml.pl -i protodunedphase_driftY_optical_geo.xml -o protodunedphase_driftY_optical.gdml
326 
327 # clean up
328 rm protodunedphase_driftY_optical_geo.xml
329 rm protodunedphase_driftY_optical_*.gdml
330 
331 # no wires for geant
332 perl generate_protodunedphase_driftY.pl -w 0 -opt 1 -o protodunedphase_driftY_optical_nowires_geo.xml -pmt 0
333 perl make_gdml.pl -i protodunedphase_driftY_optical_nowires_geo.xml -o protodunedphase_driftY_optical_nowires.gdml
334 
335 # clean up
336 rm protodunedphase_driftY_optical_nowires_geo.xml
337 rm protodunedphase_driftY_optical_nowires_*.gdml
338 
339 ########################
340 ### 3x1x1 dual phase ###
341 ########################
342 
343 echo "--- Generating 3x1x1 Geometry ---"
344 
345 # with wires for larcore
346 perl generate_3x1x1dphase.pl -w 1 -o 3x1x1dphase_geo.xml
347 perl make_gdml.pl -i 3x1x1dphase_geo.xml -o 3x1x1dphase.gdml
348 
349 # clean up
350 rm 3x1x1dphase_geo.xml
351 rm 3x1x1dphase_*.gdml
352 
353 # no wires for geant
354 perl generate_3x1x1dphase.pl -w 0 -o 3x1x1dphase_geo_nowires.xml
355 perl make_gdml.pl -i 3x1x1dphase_geo_nowires.xml -o 3x1x1dphase_nowires.gdml
356 
357 # clean up
358 rm 3x1x1dphase_geo_nowires.xml
359 rm 3x1x1dphase_nowires_*.gdml
360 
361 
362 
363 #####################################
364 ### 3x1x1 dual phase (drift in Y) ###
365 #####################################
366 
367 echo "--- Generating 3x1x1 Geometry Drift in Y ---"
368 
369 # with wires for larcore
370 perl generate_3x1x1dphase_driftY.pl -w 1 -o 3x1x1dphase_driftY_geo.xml
371 perl make_gdml.pl -i 3x1x1dphase_driftY_geo.xml -o 3x1x1dphase_driftY.gdml
372 
373 # clean up
374 rm 3x1x1dphase_driftY_geo.xml
375 rm 3x1x1dphase_driftY_*.gdml
376 
377 # no wires for geant
378 perl generate_3x1x1dphase_driftY.pl -w 0 -o 3x1x1dphase_driftY_geo_nowires.xml
379 perl make_gdml.pl -i 3x1x1dphase_driftY_geo_nowires.xml -o 3x1x1dphase_driftY_nowires.gdml
380 
381 # clean up
382 rm 3x1x1dphase_driftY_geo_nowires.xml
383 rm 3x1x1dphase_driftY_nowires_*.gdml
384