HPS-MC
 
Loading...
Searching...
No Matches
rad_lhe_to_slic_job.py
Go to the documentation of this file.
1"""!
2@file rad_lhe_to_slic_job.py
3
4Radiative (rad) events from a pre-generated LHE file through SLIC.
5
6"""
7from hpsmc.generators import StdHepConverter
8from hpsmc.tools import Unzip, AddMotherFullTruth, BeamCoords, SLIC
9
10job.description = 'rad from LHE to slic'
11
12
13inputs = list(job.input_files.values())
14
15nevents = job.params.get('nevents', 10000)
16
17
18converter = job.params.get('lhe_converter', 'lhe_rad')
19
20
21unzip = Unzip(inputs=inputs, outputs=['rad.lhe'])
22
23
24cnv = StdHepConverter(name=converter, inputs=inputs)
25
26
27mom = AddMotherFullTruth(inputs=[cnv.output_files()[0], unzip.output_files()[0]],
28 outputs=['rad_mom.stdhep'])
29
30
31rot = BeamCoords(inputs=mom.output_files(), outputs=['rad_mom_rot.stdhep'])
32
33
34slic = SLIC(inputs=rot.output_files(), outputs=['rad_mom_rot.slcio'],
35 nevents=nevents + 1)
36
37
38job.add([unzip, cnv, mom, rot, slic])
Target processing and conversion of LHE files to StdHep using EGS5.
Add full truth mother particles for physics samples.
Definition tools.py:959
Transform StdHep events into beam coordinates.
Definition tools.py:715
Run the SLIC Geant4 simulation.
Definition tools.py:16
Unzip the input files to outputs.
Definition tools.py:1456
Tools that can be used in HPSMC jobs.
Definition tools.py:1