1 from hpsmc.tools import FilterBunches, JobManager, LCIOCount, LCIOMerge
3 job.description =
'signal-beam from merge to recon'
6 inputs = list(job.input_files.values())
16 signal_file_name.append(input)
18 beam_file_name.append(input)
21 if len(signal_file_name) == 0:
22 raise Exception(
"Missing required input file(s) for signal")
23 if len(beam_file_name) == 0:
24 raise Exception(
"Missing required input file(s) for beam")
27 signal_name =
'signal'
33 signal_beam_name =
'signal-beam'
37 outputs=[
'%s_filt.slcio' % signal_name],
38 filter_event_interval=250, filter_ecal_pairs=
True,
39 filter_ecal_hit_ecut=0.1)
42 count_filter =
LCIOCount(inputs=filter_events.output_files())
46 outputs=[
'%s_filt.slcio' % beam_name],
47 filter_event_interval=0, filter_ecal_pairs=
False,
48 filter_no_cuts=
True, filter_ecal_hit_ecut=-0.1)
51 count_beam =
LCIOCount(inputs=catenate_beam.output_files())
54 merge =
LCIOMerge(inputs=[filter_events.output_files()[0],
55 catenate_beam.output_files()[0]],
56 outputs=[
'%s.slcio' % signal_beam_name],
57 ignore_job_params=[
'nevents'])
60 count_merge =
LCIOCount(inputs=merge.output_files())
64 inputs=merge.output_files(),
65 outputs=[
'%s_readout.slcio' % signal_beam_name])
68 count_readout =
LCIOCount(inputs=readout.output_files())
72 inputs=readout.output_files(),
73 outputs=[
'%s_recon.slcio' % signal_beam_name])
76 count_recon =
LCIOCount(inputs=recon.output_files())
79 job.add([filter_events, count_filter, catenate_beam, count_beam, merge,
80 count_merge, readout, count_readout, recon, count_recon])