3 from AthenaMonitoringKernel.GenericMonitoringTool
import GenericMonitoringTool
7 name = flags.Tracking.ActiveConfig.name
8 doResMon= flags.Tracking.ActiveConfig.doResMon
15 def addSPHistograms(montool, name):
16 if name
in [
'FS',
'JetFS',
'FullScan',
'fullScan',
'fullScanUTT',
'jet']:
17 montool.defineHistogram(
'roi_nSPsPIX', path=
'EXPERT',type=
'TH1F',title=
"Number of Pixel SPs", xbins = 500, xmin=-0.5, xmax=49999.5)
18 montool.defineHistogram(
'roi_nSPsSCT', path=
'EXPERT',type=
'TH1F',title=
"Number of SCT SPs", xbins = 500, xmin=-0.5, xmax=99999.5)
19 montool.defineHistogram(
'roi_phiWidth',path=
'EXPERT',type=
'TH1F',title=
"Phi width of the input RoI",xbins = 100, xmin=0, xmax=6.4)
20 montool.defineHistogram(
'roi_etaWidth',path=
'EXPERT',type=
'TH1F',title=
"Eta width of the input RoI",xbins = 100, xmin=0, xmax=5)
22 montool.defineHistogram(
'roi_nSPsPIX', path=
'EXPERT',type=
'TH1F',title=
"Number of Pixel SPs", xbins = 50, xmin=-0.5, xmax=4999.5)
23 montool.defineHistogram(
'roi_nSPsSCT', path=
'EXPERT',type=
'TH1F',title=
"Number of SCT SPs", xbins = 50, xmin=-0.5, xmax=4999.5)
24 montool.defineHistogram(
'roi_phiWidth',path=
'EXPERT',type=
'TH1F',title=
"Phi width of the input RoI",xbins = 100, xmin=0, xmax=1.0)
25 montool.defineHistogram(
'roi_etaWidth',path=
'EXPERT',type=
'TH1F',title=
"Eta width of the input RoI",xbins = 100, xmin=0, xmax=1.0)
27 montool.defineHistogram(
'roi_eta', path=
'EXPERT',type=
'TH1F',title=
'Eta of the input RoI;;Entries', xbins=100, xmin=-5, xmax=5)
28 montool.defineHistogram(
'roi_phi', path=
'EXPERT',type=
'TH1F',title=
"Phi of the input RoI",xbins = 100, xmin=-3.2, xmax=3.2)
29 montool.defineHistogram(
'roi_z', path=
'EXPERT',type=
'TH1F',title=
"z of the input RoI",xbins = 200, xmin=-400, xmax=400)
30 montool.defineHistogram(
'roi_zWidth', path=
'EXPERT',type=
'TH1F',title=
"z width of the input RoI",xbins = 100, xmin=0, xmax=500)
32 def addDataErrorHistograms(montool):
33 montool.defineHistogram(
'roi_lastStageExecuted',path=
'EXPERT',type=
'TH1F',title=
"Last Step Successfully Executed", xbins = 8 , xmin=-0.5, xmax=7.5,
34 xlabels=[
"Start",
"GetRoI",
"GetSPs",
"ZFinder",
"Triplets",
"TrackMaker",
"TrackFitter",
"TrackConverter"])
36 def addTimingHistograms(montool, name):
37 if name
in [
'FS',
'JetFS',
'FullScan',
'fullScan',
'fullScanUTT',
'jet']:
38 montool.defineHistogram(
'roi_nSPs, TIME_PattReco', path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nSPs", xbins = 200, xmin=0.0, xmax=200000.0, ybins = 100, ymin=0.0, ymax=5000.0)
39 montool.defineHistogram(
'roi_nTracks, TIME_PattReco',path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nTracks", xbins = 50, xmin=0.0, xmax=5000.0, ybins = 100, ymin=0.0, ymax=5000.0)
40 montool.defineHistogram(
'TIME_Total', path=
'EXPERT',type=
'TH1F',title=
"Total time (ms)", xbins = 200, xmin=0.0, xmax=5000.0)
41 montool.defineHistogram(
'TIME_PattReco', path=
'EXPERT',type=
'TH1F',title=
"Pure PattReco time (ms)", xbins = 200, xmin=0.0, xmax=5000.0)
42 montool.defineHistogram(
'TIME_SpacePointConversion', path=
'EXPERT',type=
'TH1F',title=
"SP Conversion time (ms)", xbins = 100, xmin=0.0, xmax=100.0)
43 montool.defineHistogram(
'TIME_ZFinder', path=
'EXPERT',type=
'TH1F',title=
"ZFinder time (ms)", xbins = 200, xmin=0.0, xmax=5000.0)
44 montool.defineHistogram(
'TIME_Triplets', path=
'EXPERT',type=
'TH1F',title=
"Triplets Making time (ms)", xbins = 200, xmin=0.0, xmax=5000.0)
45 montool.defineHistogram(
'TIME_CmbTrack', path=
'EXPERT',type=
'TH1F',title=
"Combined Tracking time (ms)", xbins = 200, xmin=0.0, xmax=5000.0)
46 montool.defineHistogram(
'TIME_TrackFitter', path=
'EXPERT',type=
'TH1F',title=
"Track Fitter time (ms)", xbins = 200, xmin=0.0, xmax=1000.0)
47 elif name==
'jetSuper':
48 montool.defineHistogram(
'roi_nSPs, TIME_PattR1eco', path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nSPs", xbins = 200, xmin=0.0, xmax=3000.0, ybins = 100, ymin=0.0, ymax=1000.0)
49 montool.defineHistogram(
'roi_nTracks, TIME_PattReco',path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nTracks", xbins = 50, xmin=0.0, xmax=200.0, ybins = 100, ymin=0.0, ymax=1000.0)
50 montool.defineHistogram(
'TIME_Total', path=
'EXPERT',type=
'TH1F',title=
"Total time (ms)", xbins = 200, xmin=0.0, xmax=2000.0)
51 montool.defineHistogram(
'TIME_PattReco', path=
'EXPERT',type=
'TH1F',title=
"Pure PattReco time (ms)", xbins = 200, xmin=0.0, xmax=1000.0)
52 montool.defineHistogram(
'TIME_SpacePointConversion', path=
'EXPERT',type=
'TH1F',title=
"SP Conversion time (ms)", xbins = 100, xmin=0.0, xmax=100.0)
53 montool.defineHistogram(
'TIME_ZFinder', path=
'EXPERT',type=
'TH1F',title=
"ZFinder time (ms)", xbins = 200, xmin=0.0, xmax=1000.0)
54 montool.defineHistogram(
'TIME_Triplets', path=
'EXPERT',type=
'TH1F',title=
"Triplets Making time (ms)", xbins = 200, xmin=0.0, xmax=1000.0)
55 montool.defineHistogram(
'TIME_CmbTrack', path=
'EXPERT',type=
'TH1F',title=
"Combined Tracking time (ms)", xbins = 200, xmin=0.0, xmax=1000.0)
56 montool.defineHistogram(
'TIME_TrackFitter', path=
'EXPERT',type=
'TH1F',title=
"Track Fitter time (ms)", xbins = 200, xmin=0.0, xmax=200.0)
57 elif name
in [
'beamSpot',
'beamSpotFS',
'bphysics',
'bmumux']:
58 montool.defineHistogram(
'roi_nSPs, TIME_PattReco', path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nSPs", xbins = 200, xmin=0.0, xmax=3000.0, ybins = 100, ymin=0.0, ymax=2000.0)
59 montool.defineHistogram(
'roi_nTracks, TIME_PattReco',path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nTracks", xbins = 50, xmin=0.0, xmax=200.0, ybins = 100, ymin=0.0, ymax=2000.0)
60 montool.defineHistogram(
'TIME_Total', path=
'EXPERT',type=
'TH1F',title=
"Total time (ms)", xbins = 200, xmin=0.0, xmax=5000.0)
61 montool.defineHistogram(
'TIME_PattReco', path=
'EXPERT',type=
'TH1F',title=
"Pure PattReco time (ms)", xbins = 200, xmin=0.0, xmax=2000.0)
62 montool.defineHistogram(
'TIME_SpacePointConversion', path=
'EXPERT',type=
'TH1F',title=
"SP Conversion time (ms)", xbins = 50, xmin=0.0, xmax=50.0)
63 montool.defineHistogram(
'TIME_Triplets', path=
'EXPERT',type=
'TH1F',title=
"Triplets Making time (ms)", xbins = 200, xmin=0.0, xmax=2000.0)
64 montool.defineHistogram(
'TIME_CmbTrack', path=
'EXPERT',type=
'TH1F',title=
"Combined Tracking time (ms)", xbins = 200, xmin=0.0, xmax=2000.0)
65 montool.defineHistogram(
'TIME_TrackFitter', path=
'EXPERT',type=
'TH1F',title=
"Track Fitter time (ms)", xbins = 200, xmin=0.0, xmax=200.0)
66 elif name
in [
'fullScanLRT',
'FullScanLRT']:
67 montool.defineHistogram(
'roi_nSPs, TIME_PattReco', path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nSPs", xbins = 200, xmin=0.0, xmax=3000.0, ybins = 100, ymin=0.0, ymax=500.0)
68 montool.defineHistogram(
'roi_nTracks, TIME_PattReco',path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nTracks", xbins = 50, xmin=0.0, xmax=200.0, ybins = 100, ymin=0.0, ymax=500.0)
69 montool.defineHistogram(
'TIME_Total', path=
'EXPERT',type=
'TH1F',title=
"Total time (ms)", xbins = 200, xmin=0.0, xmax=5000.0)
70 montool.defineHistogram(
'TIME_PattReco', path=
'EXPERT',type=
'TH1F',title=
"Pure PattReco time (ms)", xbins = 200, xmin=0.0, xmax=2000.0)
71 montool.defineHistogram(
'TIME_SpacePointConversion', path=
'EXPERT',type=
'TH1F',title=
"SP Conversion time (ms)", xbins = 200, xmin=0.0, xmax=200.0)
72 montool.defineHistogram(
'TIME_Triplets', path=
'EXPERT',type=
'TH1F',title=
"Triplets Making time (ms)", xbins = 200, xmin=0.0, xmax=400.0)
73 montool.defineHistogram(
'TIME_CmbTrack', path=
'EXPERT',type=
'TH1F',title=
"Combined Tracking time (ms)", xbins = 200, xmin=0.0, xmax=2000.0)
74 montool.defineHistogram(
'TIME_TrackFitter', path=
'EXPERT',type=
'TH1F',title=
"Track Fitter time (ms)", xbins = 200, xmin=0.0, xmax=200.0)
76 montool.defineHistogram(
'roi_nSPs, TIME_PattReco', path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nSPs", xbins = 200, xmin=0.0, xmax=3000.0, ybins = 100, ymin=0.0, ymax=400.0)
77 montool.defineHistogram(
'roi_nTracks, TIME_PattReco',path=
'EXPERT',type=
'TH2F',title=
"PattReco time; nTracks", xbins = 50, xmin=0.0, xmax=200.0, ybins = 100, ymin=0.0, ymax=400.0)
78 montool.defineHistogram(
'TIME_Total', path=
'EXPERT',type=
'TH1F',title=
"Total time (ms)", xbins = 200, xmin=0.0, xmax=1000.0)
79 montool.defineHistogram(
'TIME_PattReco', path=
'EXPERT',type=
'TH1F',title=
"Pure PattReco time (ms)", xbins = 200, xmin=0.0, xmax=400.0)
80 montool.defineHistogram(
'TIME_SpacePointConversion', path=
'EXPERT',type=
'TH1F',title=
"SP Conversion time (ms)", xbins = 20, xmin=0.0, xmax=20.0)
81 montool.defineHistogram(
'TIME_Triplets', path=
'EXPERT',type=
'TH1F',title=
"Triplets Making time (ms)", xbins = 100, xmin=0.0, xmax=100.0)
82 montool.defineHistogram(
'TIME_CmbTrack', path=
'EXPERT',type=
'TH1F',title=
"Combined Tracking time (ms)", xbins = 200, xmin=0.0, xmax=400.0)
83 montool.defineHistogram(
'TIME_TrackFitter', path=
'EXPERT',type=
'TH1F',title=
"Track Fitter time (ms)", xbins = 50, xmin=0.0, xmax=50.0)
87 def addTrackHistograms(montool, name):
88 if name
in [
'FS',
'JetFS',
'FullScan',
'fullScan',
'fullScanUTT',
'jet']:
89 montool.defineHistogram(
'roi_nSeeds', path=
'EXPERT',type=
'TH1F',title=
"Number of seeds",xbins = 1000, xmin=-0.5, xmax=99999.5)
90 montool.defineHistogram(
'roi_nTracks', path=
'EXPERT',type=
'TH1F',title=
"Number of Tracks",xbins = 100, xmin=-0.5, xmax=9999.5)
91 elif name
in [
'fullScanLRT',
'FullScanLRT']:
92 montool.defineHistogram(
'roi_nSeeds', path=
'EXPERT',type=
'TH1F',title=
"Number of seeds",xbins = 1000, xmin=-0.5, xmax=99999.5)
93 montool.defineHistogram(
'roi_nTracks', path=
'EXPERT',type=
'TH1F',title=
"Number of Tracks",xbins = 100, xmin=-0.5, xmax=5000.5)
95 montool.defineHistogram(
'roi_nSeeds', path=
'EXPERT',type=
'TH1F',title=
"Number of seeds",xbins = 100, xmin=-0.5, xmax=4999.5)
96 montool.defineHistogram(
'roi_nTracks', path=
'EXPERT',type=
'TH1F',title=
"Number of Tracks",xbins = 50, xmin=-0.5, xmax=199.5)
98 montool.defineHistogram(
'roi_nZvertices', path=
'EXPERT',type=
'TH1F',title=
"Number of z vertices",xbins = 60 , xmin=-0.5, xmax=49.5)
99 montool.defineHistogram(
'roi_zVertices', path=
'EXPERT',type=
'TH1F',title=
"ZFinder Vertices",xbins = 501, xmin=-250, xmax=250)
100 montool.defineHistogram(
'roi_nTrk_zVtx', path=
'EXPERT',type=
'TH1F',title=
"Ntrk ZFinder Vertices",xbins = 100, xmin=-0.5, xmax=49.5)
101 montool.defineHistogram(
'trk_nSiHits', path=
'EXPERT',type=
'TH1F',title=
"Total number of Silicon Hits per Track",xbins = 20, xmin=-0.5, xmax=19.5)
102 montool.defineHistogram(
'trk_nPIXHits', path=
'EXPERT',type=
'TH1F',title=
"Number of Pixel Hits per Track",xbins = 10, xmin=-0.5, xmax=9.5)
103 montool.defineHistogram(
'trk_nSCTHits', path=
'EXPERT',type=
'TH1F',title=
"Number of SCT Hits per Track",xbins = 10, xmin=-0.5, xmax=9.5)
104 montool.defineHistogram(
'trk_seedSize', path=
'EXPERT',type=
'TH1F',title=
"Number of Spacepoints per Seed",xbins = 10, xmin=-0.5, xmax=9.5)
105 montool.defineHistogram(
'trk_chi2dof', path=
'EXPERT',type=
'TH1F',title=
"ChiSqd / nDoF",xbins = 100, xmin=0.0, xmax=5)
106 montool.defineHistogram(
'trk_pt', path=
'EXPERT',type=
'TH1F',title=
"pt",xbins = 100, xmin=-2.5e5, xmax=2.5e5)
107 montool.defineHistogram(
'trk_phi0', path=
'EXPERT',type=
'TH1F',title=
"phi",xbins = 100, xmin=-3.2, xmax=3.2)
108 montool.defineHistogram(
'trk_eta', path=
'EXPERT',type=
'TH1F',title=
"eta",xbins = 100, xmin=-5, xmax=5)
109 montool.defineHistogram(
'trk_dPhi0', path=
'EXPERT',type=
'TH1F',title=
"dphi",xbins = 160, xmin=-0.8, xmax=0.8)
110 montool.defineHistogram(
'trk_dEta', path=
'EXPERT',type=
'TH1F',title=
"deta",xbins = 160, xmin=-0.8, xmax=0.8)
112 montool.defineHistogram(
'trk_a0', path=
'EXPERT',type=
'TH1F',title=
"a0",xbins = 100, xmin=-300, xmax=300)
113 montool.defineHistogram(
'trk_a0beam', path=
'EXPERT',type=
'TH1F',title=
"a0beam",xbins = 100, xmin=-300, xmax=300)
114 montool.defineHistogram(
'trk_z0', path=
'EXPERT',type=
'TH1F',title=
"z0",xbins = 100, xmin=-800, xmax=800)
115 montool.defineHistogram(
'trk_z0beam', path=
'EXPERT',type=
'TH1F',title=
"z0beam",xbins = 100, xmin=-800, xmax=800)
116 elif name
in [
'fullScanLRT',
'FullScanLRT']:
117 montool.defineHistogram(
'trk_a0', path=
'EXPERT',type=
'TH1F',title=
"a0",xbins = 100, xmin=-300, xmax=300)
118 montool.defineHistogram(
'trk_a0beam', path=
'EXPERT',type=
'TH1F',title=
"a0beam",xbins = 100, xmin=-300, xmax=300)
119 montool.defineHistogram(
'trk_z0', path=
'EXPERT',type=
'TH1F',title=
"z0",xbins = 100, xmin=-550, xmax=550)
120 montool.defineHistogram(
'trk_z0beam', path=
'EXPERT',type=
'TH1F',title=
"z0beam",xbins = 100, xmin=-550, xmax=550)
122 montool.defineHistogram(
'trk_a0', path=
'EXPERT',type=
'TH1F',title=
"a0",xbins = 200, xmin=-10, xmax=10)
123 montool.defineHistogram(
'trk_a0beam', path=
'EXPERT',type=
'TH1F',title=
"a0beam",xbins = 200, xmin=-10, xmax=10)
124 montool.defineHistogram(
'trk_z0', path=
'EXPERT',type=
'TH1F',title=
"z0",xbins = 200, xmin=-400, xmax=400)
125 montool.defineHistogram(
'trk_z0beam', path=
'EXPERT',type=
'TH1F',title=
"z0beam",xbins = 200, xmin=-400, xmax=400)
127 def addResidualHistograms(self):
128 montool.defineHistogram(
'layer_IBL', path=
'EXPERT',type=
'TH1F',title=
"IBL layer",xbins = 10, xmin=0., xmax=10.)
129 montool.defineHistogram(
'layer_PixB', path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel layer",xbins = 10, xmin=0., xmax=10.)
130 montool.defineHistogram(
'layer_PixE', path=
'EXPERT',type=
'TH1F',title=
"Pixel Endcap layer",xbins = 10, xmin=0., xmax=10.)
131 montool.defineHistogram(
'layer_SCTB', path=
'EXPERT',type=
'TH1F',title=
"SCT Barrel layer",xbins = 10, xmin=0., xmax=10.)
132 montool.defineHistogram(
'layer_SCTE', path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap layer",xbins = 10, xmin=0., xmax=10.)
134 montool.defineHistogram(
'hit_IBLPhiResidual', path=
'EXPERT',type=
'TH1F',title=
"IBL hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
135 montool.defineHistogram(
'hit_IBLEtaResidual', path=
'EXPERT',type=
'TH1F',title=
"IBL hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
136 montool.defineHistogram(
'hit_IBLPhiPull', path=
'EXPERT',type=
'TH1F',title=
"IBL hit-track phi pull",xbins = 100, xmin=-5., xmax=5.)
137 montool.defineHistogram(
'hit_IBLEtaPull', path=
'EXPERT',type=
'TH1F',title=
"IBL hit-track eta pull",xbins = 100, xmin=-5., xmax=5.)
139 montool.defineHistogram(
'hit_PIXBarrelPhiResidual', path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
140 montool.defineHistogram(
'hit_PIXBarrelEtaResidual', path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
141 montool.defineHistogram(
'hit_PIXBarrelL1PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel L1 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
142 montool.defineHistogram(
'hit_PIXBarrelL1EtaResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel L1 hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
143 montool.defineHistogram(
'hit_PIXBarrelL2PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel L2 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
144 montool.defineHistogram(
'hit_PIXBarrelL2EtaResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel L2 hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
145 montool.defineHistogram(
'hit_PIXBarrelL3PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel L3 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
146 montool.defineHistogram(
'hit_PIXBarrelL3EtaResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel L3 hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
147 montool.defineHistogram(
'hit_PIXBarrelPhiPull', path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel hit-track phi pull",xbins = 100, xmin=-5., xmax=5.)
148 montool.defineHistogram(
'hit_PIXBarrelEtaPull', path=
'EXPERT',type=
'TH1F',title=
"Pixel Barrel hit-track eta pull",xbins = 100, xmin=-5., xmax=5.)
150 montool.defineHistogram(
'hit_PIXEndcapPhiResidual', path=
'EXPERT',type=
'TH1F',title=
"Pixel EC hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
151 montool.defineHistogram(
'hit_PIXEndcapEtaResidual', path=
'EXPERT',type=
'TH1F',title=
"Pixel EC hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
152 montool.defineHistogram(
'hit_PIXEndcapL1PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel EC L1 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
153 montool.defineHistogram(
'hit_PIXEndcapL1EtaResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel EC L1 hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
154 montool.defineHistogram(
'hit_PIXEndcapL2PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel EC L2 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
155 montool.defineHistogram(
'hit_PIXEndcapL2EtaResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel EC L2 hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
156 montool.defineHistogram(
'hit_PIXEndcapL3PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel EC L3 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
157 montool.defineHistogram(
'hit_PIXEndcapL3EtaResidual',path=
'EXPERT',type=
'TH1F',title=
"Pixel EC L3 hit-track eta residual",xbins = 100, xmin=-1.0, xmax=1.0)
158 montool.defineHistogram(
'hit_PIXEndcapPhiPull', path=
'EXPERT',type=
'TH1F',title=
"Pixel EC hit-track phi pull",xbins = 100, xmin=-5., xmax=5.)
159 montool.defineHistogram(
'hit_PIXEndcapEtaPull', path=
'EXPERT',type=
'TH1F',title=
"Pixel EC hit-track eta pull",xbins = 100, xmin=-5., xmax=5.)
161 montool.defineHistogram(
'hit_SCTBarrelResidual', path=
'EXPERT',type=
'TH1F',title=
"SCT Barrel hit-track residual",xbins = 100, xmin=-0.5, xmax=0.5)
162 montool.defineHistogram(
'hit_SCTBarrelL1PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Barrel L1 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
163 montool.defineHistogram(
'hit_SCTBarrelL2PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Barrel L2 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
164 montool.defineHistogram(
'hit_SCTBarrelL3PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Barrel L3 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
165 montool.defineHistogram(
'hit_SCTBarrelL4PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Barrel L4 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
166 montool.defineHistogram(
'hit_SCTBarrelPull', path=
'EXPERT',type=
'TH1F',title=
"SCT Barrel hit-track pull",xbins = 100, xmin=-5., xmax=5.)
168 montool.defineHistogram(
'hit_SCTEndcapResidual', path=
'EXPERT',type=
'TH1F',title=
"SCT EC hit-track residual",xbins = 100, xmin=-1.0, xmax=1.0)
169 montool.defineHistogram(
'hit_SCTEndcapL1PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L1 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
170 montool.defineHistogram(
'hit_SCTEndcapL2PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L2 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
171 montool.defineHistogram(
'hit_SCTEndcapL3PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L3 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
172 montool.defineHistogram(
'hit_SCTEndcapL4PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L4 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
173 montool.defineHistogram(
'hit_SCTEndcapL5PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L5 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
174 montool.defineHistogram(
'hit_SCTEndcapL6PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L6 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
175 montool.defineHistogram(
'hit_SCTEndcapL7PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L7 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
176 montool.defineHistogram(
'hit_SCTEndcapL8PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L8 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
177 montool.defineHistogram(
'hit_SCTEndcapL9PhiResidual',path=
'EXPERT',type=
'TH1F',title=
"SCT Endcap L9 hit-track phi residual",xbins = 100, xmin=-0.5, xmax=0.5)
178 montool.defineHistogram(
'hit_SCTEndcapPull', path=
'EXPERT',type=
'TH1F',title=
"SCT EC hit-track pull",xbins = 100, xmin=-5., xmax=5.)
180 def addUTTHistograms(montool, name):
181 montool.defineHistogram(
'trk_dedx', path=
'EXPERT',type=
'TH1F',title=
"Track dEdx (pT > 3 GeV)", xbins = 140, xmin=-0.5, xmax=6.5)
182 montool.defineHistogram(
'trk_dedx_nusedhits', path=
'EXPERT',type=
'TH1F',title=
"Nr of used hits for dEdx",xbins = 11, xmin=-0.5, xmax=10.5)
184 montool.defineHistogram(
'disTrk_nVtx', path=
'EXPERT',type=
'TH1F',title=
"Nr of Vertex for disTrk",xbins = 11, xmin=-0.5, xmax=10.5)
185 montool.defineHistogram(
'disTrk_xVtx', path=
'EXPERT',type=
'TH1F',title=
"X position of primary vertex for disTrk", xbins = 120, xmin=-1.2, xmax=1.2)
186 montool.defineHistogram(
'disTrk_yVtx', path=
'EXPERT',type=
'TH1F',title=
"Y position of primary vertex for disTrk", xbins = 120, xmin=-1.2, xmax=1.2)
187 montool.defineHistogram(
'disTrk_zVtx', path=
'EXPERT',type=
'TH1F',title=
"Z position of primary vertex for disTrk", xbins = 150, xmin=-150, xmax=150)
189 montool.defineHistogram(
'disFailTrk_n', path=
'EXPERT',type=
'TH1F',title=
"Nr of disFailTrk", xbins = 50, xmin=0, xmax=3000)
190 montool.defineHistogram(
'disFailTrk_nclone', path=
'EXPERT',type=
'TH1F',title=
"Nr of disFailTrk (after clone removal)", xbins = 50, xmin=0, xmax=3000)
191 montool.defineHistogram(
'disFailTrk_ncand', path=
'EXPERT',type=
'TH1F',title=
"Nr of disFailTrk (after pre-selection)", xbins = 50, xmin=0, xmax=3000)
192 montool.defineHistogram(
'disCombTrk_n', path=
'EXPERT',type=
'TH1F',title=
"Nr of disCombTrk", xbins = 20, xmin=0, xmax=100)
193 montool.defineHistogram(
'disCombTrk_nclone', path=
'EXPERT',type=
'TH1F',title=
"Nr of disCombTrk (after clone removal)", xbins = 20, xmin=0, xmax=100)
194 montool.defineHistogram(
'disCombTrk_ncand', path=
'EXPERT',type=
'TH1F',title=
"Nr of disCombTrk (after pre-selection)", xbins = 20, xmin=0, xmax=100)
196 if name
in [
'FS',
'JetFS',
'FullScan',
'fullScan',
'fullScanUTT',
'jet']:
197 montool.defineHistogram(
'TIME_dEdxTrk', path=
'EXPERT',type=
'TH1F',title=
"Large dEdx search (ms)", xbins = 20, xmin=0.0, xmax=200.0)
198 montool.defineHistogram(
'TIME_disTrkZVertex', path=
'EXPERT',type=
'TH1F',title=
"UTT z-vertexing time (ms)", xbins = 10, xmin=0.0, xmax=100.0)
199 montool.defineHistogram(
'TIME_disappearingTrack', path=
'EXPERT',type=
'TH1F',title=
"Disappearing track reco time (ms)", xbins = 100, xmin=0.0, xmax=3000.0)
201 montool.defineHistogram(
'TIME_dEdxTrk', path=
'EXPERT',type=
'TH1F',title=
"Large dEdx search (ms)", xbins = 20, xmin=0.0, xmax=20.0)
202 montool.defineHistogram(
'TIME_disTrkZVertex', path=
'EXPERT',type=
'TH1F',title=
"UTT z-vertexing time (ms)", xbins = 10, xmin=0.0, xmax=10.0)
203 montool.defineHistogram(
'TIME_disappearingTrack', path=
'EXPERT',type=
'TH1F',title=
"Disappearing track reco time (ms)", xbins = 100, xmin=0.0, xmax=300.0)
206 addSPHistograms(montool, name)
207 addDataErrorHistograms(montool)
208 addTimingHistograms(montool, name)
209 addTrackHistograms(montool, name)
211 addResidualHistograms(montool)
212 uttMode = flags.Tracking.ActiveConfig.doHitDV
or flags.Tracking.ActiveConfig.doDisappearingTrk
214 addUTTHistograms(montool, name)
219 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
220 from AthenaConfiguration.ComponentFactory
import CompFactory
221 from AthenaConfiguration.AthConfigFlags
import AthConfigFlags
223 def TrigZFinderCfg(flags : AthConfigFlags, numberingTool) -> ComponentAccumulator:
226 if flags.Tracking.ActiveConfig.name ==
"beamSpot" :
231 'UseOnlyPixels' :
True,
235 elif flags.Tracking.ActiveConfig.name ==
"jetSuper" :
239 'UseOnlyPixels' :
True,
245 CompFactory.TrigZFinder( name=
"TrigZFinder",
246 LayerNumberTool=numberingTool,
255 kwargs.setdefault(
"UseNewLayerScheme",
True)
256 acc.setPrivateTools(CompFactory.TrigL2LayerNumberTool(**kwargs))
261 kwargs.setdefault(
"UseNewLayerScheme",
True)
262 acc.setPrivateTools(CompFactory.TrigL2LayerNumberToolITk(**kwargs))
268 kwargs.setdefault(
"UseNewLayerScheme",
True)
270 if "layerNumberTool" not in kwargs:
271 ntargs = {
"UseNewLayerScheme" : kwargs.get(
"UseNewLayerScheme")}
274 kwargs.setdefault(
"DoPhiFiltering", flags.Tracking.ActiveConfig.DoPhiFiltering)
275 kwargs.setdefault(
"UseBeamTilt",
False)
276 kwargs.setdefault(
"PixelSP_ContainerName",
"PixelTrigSpacePoints")
277 kwargs.setdefault(
"SCT_SP_ContainerName",
"SCT_TrigSpacePoints")
278 kwargs.setdefault(
"UsePixelSpacePoints",flags.Tracking.ActiveConfig.UsePixelSpacePoints)
280 from RegionSelector.RegSelToolConfig
import regSelTool_SCT_Cfg, regSelTool_Pixel_Cfg
282 if "RegSelTool_Pixel" not in kwargs:
285 if "RegSelTool_SCT" not in kwargs:
286 kwargs.setdefault(
"RegSelTool_SCT", acc.popToolsAndMerge(
regSelTool_SCT_Cfg( flags)))
289 acc.setPrivateTools(CompFactory.TrigSpacePointConversionTool(**kwargs))
296 kwargs.setdefault(
"UseNewLayerScheme",
True)
298 if "layerNumberTool" not in kwargs:
299 ntargs = {
"UseNewLayerScheme" : kwargs.get(
"UseNewLayerScheme")}
302 kwargs.setdefault(
"DoPhiFiltering", flags.Tracking.ActiveConfig.DoPhiFiltering)
303 kwargs.setdefault(
"UseBeamTilt",
False)
304 kwargs.setdefault(
"PixelSP_ContainerName",
"ITkPixelTrigSpacePoints")
305 kwargs.setdefault(
"SCT_SP_ContainerName",
"ITkStripTrigSpacePoints")
306 kwargs.setdefault(
"UsePixelSpacePoints", (
not flags.Tracking.ActiveConfig.isLRT))
307 kwargs.setdefault(
"UseSctSpacePoints",flags.Tracking.ActiveConfig.isLRT)
309 from RegionSelector.RegSelToolConfig
import (regSelTool_ITkStrip_Cfg, regSelTool_ITkPixel_Cfg)
311 if "RegSelTool_Pixel" not in kwargs:
314 if "RegSelTool_SCT" not in kwargs:
318 acc.setPrivateTools(CompFactory.TrigSpacePointConversionTool(**kwargs))
326 from BeamSpotConditions.BeamSpotConditionsConfig
import BeamSpotCondAlgCfg
329 if "layerNumberTool" not in kwargs:
330 ntargs = {
"UseNewLayerScheme" :
True}
333 kwargs.setdefault(
"DoPhiFiltering", flags.Tracking.ActiveConfig.DoPhiFiltering)
334 kwargs.setdefault(
"UseBeamTilt",
False)
335 kwargs.setdefault(
"PixelSP_ContainerName",
"ITkPixelTrigSpacePoints")
336 kwargs.setdefault(
"SCT_SP_ContainerName",
"ITkStripTrigSpacePoints")
337 kwargs.setdefault(
"UsePixelSpacePoints", (
not flags.Tracking.ActiveConfig.isLRT))
338 kwargs.setdefault(
"UseSctSpacePoints",flags.Tracking.ActiveConfig.isLRT)
339 kwargs.setdefault(
"pTmin", flags.Tracking.ActiveConfig.minPT[0])
340 kwargs.setdefault(
"MaxGraphEdges", 1500000)
341 kwargs.setdefault(
"ConnectionFileName",
"binTables_ITK_RUN4_LRT.txt" if flags.Tracking.ActiveConfig.isLRT
else "binTables_ITK_RUN4.txt")
343 from RegionSelector.RegSelToolConfig
import (regSelTool_ITkStrip_Cfg, regSelTool_ITkPixel_Cfg)
349 acc.setPrivateTools(CompFactory.TrigInDetTrackSeedingTool(**kwargs))
356 from InDetConfig.SiCombinatorialTrackFinderToolConfig
import ITkSiCombinatorialTrackFinder_xkCfg
358 name=
"ITkTrigSiComTrackFinder_"+signature,
359 PixelClusterContainer=
'ITkTrigPixelClusters',
360 SCT_ClusterContainer=
'ITkTrigStripClusters')
362 from InDetConfig.SiTrackMakerConfig
import ITkSiTrackMaker_xkCfg
364 name =
"ITkTrigSiTrackMaker_FTF_",
365 useBremModel = flags.Tracking.ActiveConfig.doBremRecoverySi,
366 CombinatorialTrackFinder = CombinatorialTrackFinderTool)
369 acc.addPublicTool( CompFactory.TrigInDetTrackFollowingTool( name =
"TrigTrackFollowingTool_FTF_"+signature,
370 PixelClusterContainer=
'ITkTrigPixelClusters',
371 SCT_ClusterContainer=
'ITkTrigStripClusters',
372 LayerNumberTool = layerNumberingTool ) )
373 trackMaker.useTrigTrackFollowingTool =
True
374 trackMaker.TrigTrackFollowingTool = acc.getPublicTool(
"TrigTrackFollowingTool_FTF_"+signature)
376 acc.addPublicTool( CompFactory.TrigInDetRoadPredictorTool( name =
"TrigRoadPredictorTool_FTF"+signature, LayerNumberTool = layerNumberingTool ) )
377 trackMaker.useTrigInDetRoadPredictorTool = (
not flags.Tracking.ActiveConfig.isLRT)
378 if trackMaker.useTrigInDetRoadPredictorTool:
379 trackMaker.TrigInDetRoadPredictorTool = acc.getPublicTool(
"TrigRoadPredictorTool_FTF"+signature)
381 acc.addPublicTool(trackMaker)
385 def TrigFastTrackFinderCfg(flags: AthConfigFlags, name: str, RoIs: str, inputTracksName:str =
None) -> ComponentAccumulator:
388 signature = flags.Tracking.ActiveConfig.input_name
389 isCosmicConfig = (signature==
"cosmics")
393 if flags.Trigger.InDetTracking.doGPU:
395 inDetAccelSvc = CompFactory.TrigInDetAccelerationSvc(
"TrigInDetAccelerationSvc")
396 inDetAccelSvc.useITkGeometry = flags.Detector.GeometryITk
397 if flags.Detector.GeometryITk:
398 inDetAccelSvc.MiddleSpacePointLayers = [81000, 82000,
399 90011, 90012, 90013, 90014, 91002, 91003, 91004, 91005,
400 92000, 92001, 92002, 92003, 92004, 92005, 92006, 92007, 92008, 92009, 92010,
401 92011, 92012, 92013, 92014, 92015, 92016, 92017, 92018, 92019, 92020, 92021, 92022,
402 70011, 70012, 70013, 70014, 71002, 71003, 71004, 71005,
403 72000, 72001, 72002, 72003, 72004, 72005, 72006, 72007, 72008, 72009, 72010,
404 72011, 72012, 72013, 72014, 72015, 72016, 72017, 72018, 72019, 72020, 72021, 72022
406 acc.addService(inDetAccelSvc)
408 if flags.Detector.GeometryITk:
409 acc.addPublicTool(CompFactory.TrigITkAccelerationTool(name =
"TrigITkAccelerationTool_FTF"))
411 acc.addPublicTool(CompFactory.TrigInDetAccelerationTool(name =
"TrigInDetAccelerationTool_FTF"))
414 useNewLayerNumberScheme =
True
420 if flags.Detector.GeometryITk:
428 TrackMaker_FTF = acc.getPublicTool(
"ITkTrigSiTrackMaker_FTF_"+signature)
430 acc.addPublicTool( CompFactory.TrigInDetTrackFitter(
"TrigInDetTrackFitter_"+signature ) )
437 from InDetConfig.SiTrackMakerConfig
import TrigSiTrackMaker_xkCfg
438 TrackMaker_FTF = acc.popToolsAndMerge(
441 from TrkConfig.TrkRIO_OnTrackCreatorConfig
import TrigRotCreatorCfg
443 acc.addPublicTool(TrigRotCreator)
446 CompFactory.TrigInDetTrackFitter(
447 name =
"TrigInDetTrackFitter_"+signature,
448 doBremmCorrection = flags.Tracking.ActiveConfig.doBremRecoverySi,
449 correctClusterPos =
True,
450 ROTcreator = TrigRotCreator,
454 acc.addPublicTool(TrackMaker_FTF)
456 theTrigInDetTrackFitter = acc.getPublicTool(
"TrigInDetTrackFitter_"+signature)
458 if (flags.Tracking.ActiveConfig.doZFinder):
459 theTrigZFinder = acc.popToolsAndMerge(
TrigZFinderCfg(flags,numberingTool))
461 if not flags.Tracking.ActiveConfig.doZFinderOnly:
463 if flags.Detector.GeometryITk:
465 from TrkConfig.TrkTrackSummaryToolConfig
import ITkTrackSummaryToolCfg
469 from TrkConfig.TrkTrackSummaryToolConfig
import InDetTrigTrackSummaryToolCfg, InDetTrigFastTrackSummaryToolCfg
470 if flags.Tracking.ActiveConfig.holeSearch_FTF :
475 acc.addPublicTool(trackSummaryTool)
477 from TrkConfig.AtlasExtrapolatorConfig
import AtlasExtrapolatorCfg
479 ftf = CompFactory.TrigFastTrackFinder(
481 useNewLayerNumberScheme = useNewLayerNumberScheme,
482 LayerNumberTool = numberingTool,
483 useGPU = flags.Trigger.InDetTracking.doGPU,
484 SpacePointProviderTool = spTool,
485 MinHits = 3
if flags.Detector.GeometryITk
else 5,
486 Triplet_MinPtFrac = 0.8
if flags.Detector.GeometryITk
else 1,
487 Triplet_nMaxPhiSlice = 53
if "cosmics" not in flags.Tracking.ActiveConfig.name
else 2,
488 LRT_Mode = flags.Tracking.ActiveConfig.isLRT,
489 dodEdxTrk = flags.Tracking.ActiveConfig.dodEdxTrk,
490 doDisappearingTrk = flags.Tracking.ActiveConfig.doDisappearingTrk,
491 Triplet_MaxBufferLength = 3,
492 doSeedRedundancyCheck = flags.Tracking.ActiveConfig.doSeedRedundancyCheck,
493 Triplet_D0Max = flags.Tracking.ActiveConfig.Triplet_D0Max,
494 Triplet_D0_PPS_Max = flags.Tracking.ActiveConfig.Triplet_D0_PPS_Max,
495 TrackInitialD0Max = flags.Tracking.ActiveConfig.TrackInitialD0Max,
496 TrackZ0Max = flags.Tracking.ActiveConfig.TrackZ0Max,
497 TripletDoPPS = flags.Tracking.ActiveConfig.TripletDoPPS,
498 TripletDoPSS =
False,
499 pTmin = flags.Tracking.ActiveConfig.minPT[0]
if flags.Detector.GeometryITk
else flags.Tracking.ActiveConfig.minPT,
500 DoubletDR_Max = flags.Tracking.ActiveConfig.DoubletDR_Max,
501 SeedRadBinWidth = flags.Tracking.ActiveConfig.SeedRadBinWidth,
502 initialTrackMaker = TrackMaker_FTF,
503 trigInDetTrackFitter = theTrigInDetTrackFitter,
504 doZFinder = flags.Tracking.ActiveConfig.doZFinder,
505 TrackSummaryTool = trackSummaryTool,
506 doCloneRemoval = flags.Tracking.ActiveConfig.doCloneRemoval,
507 TracksName = flags.Tracking.ActiveConfig.trkTracks_FTF,
508 doResMon = flags.Tracking.ActiveConfig.doResMon,
512 ITkMode = flags.Detector.GeometryITk,
513 UseTracklets = flags.Detector.GeometryITk,
514 doTrackRefit =
not flags.Detector.GeometryITk,
515 TrackSeedingTool = seedingTool
518 ftf.LRT_D0Min = flags.Tracking.ActiveConfig.LRT_D0Min
519 ftf.LRT_HardMinPt = flags.Tracking.ActiveConfig.LRT_HardPtMin
521 ftf.UseTrigSeedML = flags.Tracking.ActiveConfig.UseTrigSeedML
523 if flags.Trigger.InDetTracking.doGPU:
524 ftf.TrigAccelerationSvc = acc.getService(
"TrigInDetAccelerationSvc")
525 if flags.Detector.GeometryITk:
526 ftf.TrigAccelerationTool = acc.getPublicTool(
"TrigITkAccelerationTool_FTF")
528 ftf.TrigAccelerationTool = acc.getPublicTool(
"TrigInDetAccelerationTool_FTF")
531 ftf.Doublet_FilterRZ =
False
533 from TrigEDMConfig.TriggerEDM
import recordable
534 if flags.Tracking.ActiveConfig.dodEdxTrk:
538 if flags.Tracking.ActiveConfig.doDisappearingTrk:
540 from TrkConfig.TrkGlobalChi2FitterConfig
import InDetTrigGlobalChi2FitterCfg
542 acc.addPublicTool(InDetTrigTrackFitter)
543 ftf.DisTrackFitter = InDetTrigTrackFitter
545 if flags.Tracking.ActiveConfig.doZFinder:
546 ftf.doZFinderOnly = flags.Tracking.ActiveConfig.doZFinderOnly
547 ftf.trigZFinder = theTrigZFinder
548 ftf.zVertexResolution = 20
if flags.Tracking.ActiveConfig.name ==
"jetSuper" else 1
549 ftf.zVertexResolutionEndcap = 150
if flags.Tracking.ActiveConfig.name ==
"jetSuper" else ftf.zVertexResolution
550 ftf.doFastZVertexSeeding =
True
553 ftf.inputTracksName = inputTracksName
555 acc.addEventAlgo(ftf)