hpstr
The Heavy Photon Search Toolkit for Reconstruction (hpstr) provides an interface to physics data from the HPS experiment saved in the LCIO format and converts it into an ROOT based format.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
rawSvtAnaHits_cfg.py
Go to the documentation of this file.
1import HpstrConf
2import sys
3import os
4import baseConfig as base
5
6base.parser.add_argument("-A", "--onTrk", type=int, dest="onTrk",
7 help="Are we using hits on track or not", metavar="onTrk",default=0)
8base.parser.add_argument("-p", "--tphase", type=int, dest="tphase",
9 help="The Phase of the Event Time", metavar="tphase",default=6)
10
11options = base.parser.parse_args()
12
13# Use the input file to set the output file name
14root1_file = options.inFilename[0]
15root2_file = options.outFilename
16onTrk = options.onTrk
17
18print('Root file Input: %s' % root1_file)
19print('Root file Output: %s' % root2_file)
20
22
23p.run_mode = 1
24p.skip_events = options.skip_events
25p.max_events = options.nevents
26
27# Library containing processors
28p.add_library("libprocessors")
29
30
33
34rawAnaSvt = HpstrConf.Processor('svtana', 'SvtRawDataAnaProcessor')
35
36
39
40#SvtRawAnaData
41
42rawAnaSvt.parameters["debug"] = 0
43rawAnaSvt.parameters["anaName"] = 'rawSvtHitAna'
44rawAnaSvt.parameters["trkrHitColl"] = 'SVTRawTrackerHits' # 'SVTRawHitsOnTrack_KF'#'SVTRawTrackerHits'
45rawAnaSvt.parameters["histCfg"] = os.environ['HPSTR_BASE']+'/analysis/plotconfigs/svt/rawSvtAnaHits.json'
46rawAnaSvt.parameters["sample"] = 0
47
48RegionPath = os.environ['HPSTR_BASE']+"/analysis/selections/svtHit/"
49
50rawAnaSvt.parameters["baselineFile"] = os.environ['HPSTR_BASE']+"/processors/dat/hps_14552_offline_baselines.dat"
51rawAnaSvt.parameters["timeProfiles"] = os.environ['HPSTR_BASE'] + "/processors/dat/hpssvt_014393_database_svt_pulse_shapes_final.dat"
52
53rawAnaSvt.parameters["regionDefinitions"] = [RegionPath+'OneFit.json',
54 RegionPath+'FirstFit.json',
55 RegionPath+'SecondFit.json',
56 RegionPath+'BothFit.json',
57 RegionPath+'CTFit.json',
58 RegionPath+'FTFit.json',
59 RegionPath+'LowTimeDiff.json',
60 RegionPath+'R1.json',
61 RegionPath+'R2.json',
62 RegionPath+'R3.json',
63 RegionPath+'R4.json',
64 RegionPath+'TimeResolution.json'
65 ]
66
67rawAnaSvt.parameters["MatchList"] = ['OneFit', 'CTFit', 'SecondFit']
68rawAnaSvt.parameters["timeref"] = 0.0
69rawAnaSvt.parameters["ampref"] = 0.0
70
71#os.environ['HPSTR_BASE']+'/analysis/plotconfigs/reco/basicRecoHit.json'
72#os.environ['HPSTR_BASE']+'/analysis/plotconfigs/svt/Svt2DBl.json'
73
74# Sequence which the processors will run.
75p.sequence = [rawAnaSvt]
76
77p.input_files = [root1_file]
78p.output_files = [root2_file]
79
80p.printProcess()
Process python class.
Definition HpstrConf.py:20
Processor python class.
Definition HpstrConf.py:4