HPS-MC
tritrig_prep_and_slic_job.py
Go to the documentation of this file.
1 """!
2 @file tritrig_prep_and_slic_job.py
3 
4 Add mother particle information to tritrig events and rotate them into beam coordinates before simulating detector response using slic.
5 """
6 from hpsmc.generators import StdHepConverter
7 from hpsmc.tools import Unzip, AddMotherFullTruth, BeamCoords, SLIC
8 
9 job.description = 'Convert tritrig events to StdHep and simulate detector response'
10 
11 
12 inputs = list(job.input_files.values())
13 
14 
15 unzip = Unzip(inputs=inputs, outputs=["tritrig.lhe"])
16 
17 
18 cnv = StdHepConverter(inputs=inputs, outputs=['tritrig.stdhep'])
19 
20 
21 mom = AddMotherFullTruth(inputs=[cnv.output_files()[0], unzip.output_files()[0]], outputs=['tritrig_mom.stdhep'])
22 
23 
24 rot = BeamCoords(inputs=['tritrig_mom.stdhep'])
25 
26 
27 slic = SLIC(inputs=rot.output_files())
28 
29 
30 job.add([unzip, cnv, mom, rot, slic])
Convert LHE files to StdHep using EGS5.
Definition: generators.py:135
Add full truth mother particles for physics samples.
Definition: tools.py:742
Transform StdHep events into beam coordinates.
Definition: tools.py:516
Run the SLIC Geant4 simulation.
Definition: tools.py:15
Unzip the input files to outputs.
Definition: tools.py:1218
Tools that can be used in HPSMC jobs.
Definition: tools.py:1