7 from AthenaConfiguration.ComponentFactory
import CompFactory
11 from MuonSelectorTools.MuonSelectorToolsConfig
import MuonSelectionToolCfg
12 from .MuonMatchingToolConfig
import MuonMatchingToolConfig
13 monAlg = helper.addAlgorithm(CompFactory.L2muCombMon,
'L2muCombMon',
14 MuonSelectionTool = helper.result().popToolsAndMerge(
MuonSelectionToolCfg(helper.flags, MuQuality=1)),
18 from TrigConfigSvc.TriggerConfigAccess
import getHLTMonitoringAccess
20 Chains = moniAccess.monitoredChains(signatures=
"muonMon",monLevels=[
"shifter",
"t0",
"val"])
21 monAlg.MonitoredChains = [c
for c
in Chains
if (
'mu24_ivarmedium' in c)
or (
'2mu14' in c)]
24 if len(monAlg.MonitoredChains) == 0:
26 monAlg.MonitoredChains = [
'HLT_mu6_L1MU5VF',
'HLT_mu24_ivarmedium_L1MU14FCH',
'HLT_2mu14_L12MU8F']
28 monAlg.Group = GroupName
31 histGroupNonSpecificChain = helper.addGroup(monAlg, GroupName,
'HLT/MuonMon/')
33 histGroupNonSpecificChain.defineHistogram(
'L2CBEta,L2CBPhi;L2muComb_Eta_vs_Phi',
34 title=
'L2muComb Eta vs Phi ;#eta;#phi',
35 type=
'TH2F', path=
'etaphi2D',xbins=108,xmin=-2.7,xmax=2.7, ybins=96,ymin=-ROOT.TMath.Pi(),ymax=ROOT.TMath.Pi())
37 histGroupNonSpecificChain.defineHistogram(
'L2CBAboveCut,LB;L2muComb_Over_OfflineCB_4GeV_Cut',
38 title=
'L2muComb Over OfflineCB 4GeV Cut;LB;Ratio',
39 type=
'TEfficiency', path=
'Ratio',xbins=400,xmin=1.,xmax=801.)
43 for chain
in monAlg.MonitoredChains:
45 histGroup = helper.addGroup(monAlg, GroupName+
'_'+chain,
'HLT/MuonMon/L2muComb/'+chain)
49 histGroup.defineHistogram(chain+
'_Pt;L2muComb_Pt',
50 title=
'L2muComb Pt '+chain+
';p_{T} [GeV];Events',
51 type=
'TH1F', path=
'',xbins=210,xmin=-105.,xmax=105.)
53 histGroup.defineHistogram(chain+
'_Eta;L2muComb_Eta',
54 title=
'L2muComb Eta '+chain+
';#eta;Events',
55 type=
'TH1F', path=
'',xbins=108,xmin=-2.7,xmax=2.7)
57 histGroup.defineHistogram(chain+
'_Phi;L2muComb_Phi',
58 title=
'L2muComb Phi '+chain+
';#phi;Events',
59 type=
'TH1F', path=
'',xbins=96,xmin=-ROOT.TMath.Pi(),xmax=ROOT.TMath.Pi())
61 histGroup.defineHistogram(chain+
'_Eta,'+chain+
'_Phi;L2muComb_Eta_vs_Phi',
62 title=
'L2muComb Eta vs Phi '+chain+
';#eta;#phi',
63 type=
'TH2F', path=
'',xbins=108,xmin=-2.7,xmax=2.7, ybins=96,ymin=-ROOT.TMath.Pi(),ymax=ROOT.TMath.Pi())
67 histGroup.defineHistogram(chain+
'_Eta,'+chain+
'_Phi;L2muComb_Eta_vs_Phi_L2CB_success',
68 title=
'L2muComb Eta vs Phi (L2CB reconstruction success) '+chain+
';#eta;#phi',
69 cutmask=chain+
'_L2CB_success',
70 type=
'TH2F', path=
'',xbins=108,xmin=-2.7,xmax=2.7, ybins=96,ymin=-ROOT.TMath.Pi(),ymax=ROOT.TMath.Pi())
72 histGroup.defineHistogram(chain+
'_Eta,'+chain+
'_Phi;L2muComb_Eta_vs_Phi_L2CBOFFmatching_failure',
73 title=
'L2muComb Eta vs Phi (L2CB reconstruction success Off match failure) '+chain+
';#eta;#phi',
74 cutmask=chain+
'_L2CBOFFmatching_failure',
75 type=
'TH2F', path=
'',xbins=108,xmin=-2.7,xmax=2.7, ybins=96,ymin=-ROOT.TMath.Pi(),ymax=ROOT.TMath.Pi())
77 histGroup.defineHistogram(chain+
'_saEta,'+chain+
'_saPhi;L2MuonSA_Eta_vs_Phi_L2CB_failure',
78 title=
'L2MuonSA Eta vs Phi (L2CB reconstruction failure L2SA Off match success) '+chain+
';#eta;#phi',
79 cutmask=chain+
'_L2CB_failure',
80 type=
'TH2F', path=
'',xbins=108,xmin=-2.7,xmax=2.7, ybins=96,ymin=-ROOT.TMath.Pi(),ymax=ROOT.TMath.Pi())
84 histGroup.defineHistogram(chain+
'_saPt;L2muComb_failed_saPt',
85 title=
'L2MuonSA Pt (GeV/c) for muComb fails '+chain+
';p_{T} [GeV];Events',
86 cutmask=chain+
'_L2SA_success',
87 type=
'TH1F', path=
'',xbins=210,xmin=-105.,xmax=105.)
89 histGroup.defineHistogram(chain+
'_saEta;L2muComb_failed_saEta',
90 title=
'L2MuonSA Eta for muComb fails '+chain+
';#eta;Events',
91 cutmask=chain+
'_L2SA_success',
92 type=
'TH1F', path=
'',xbins=108,xmin=-2.7,xmax=2.7)
94 histGroup.defineHistogram(chain+
'_saPhi;L2muComb_failed_saPhi',
95 title=
'L2MuonSA Phi for muComb fails '+chain+
';#phi;Events',
96 cutmask=chain+
'_L2SA_success',
97 type=
'TH1F', path=
'',xbins=96,xmin=-ROOT.TMath.Pi(),xmax=ROOT.TMath.Pi())
101 histGroup.defineHistogram(chain+
'_ptratio_toSA;L2muComb_ptratio_toSA',
102 title=
'L2muComb pt / L2MuonSA pt '+chain+
';p_{T} ratio;Events',
103 type=
'TH1F', path=
'',xbins=140,xmin=-0.5,xmax=3.)
105 histGroup.defineHistogram(chain+
'_dR_toSA;L2muComb_dR_toSA',
106 title=
'L2muComb delta R to L2MuonSA '+chain+
';#DeltaR;Events',
107 type=
'TH1F', path=
'',xbins=100,xmin=0.,xmax=0.5)
109 histGroup.defineHistogram(chain+
'_dEta_toSA;L2muComb_dEta_toSA',
110 title=
'L2muComb delta eta to L2MuonSA '+chain+
';#Delta#eta;Events',
111 type=
'TH1F', path=
'',xbins=120,xmin=-0.2,xmax=0.2)
113 histGroup.defineHistogram(chain+
'_dPhi_toSA;L2muComb_dPhi_toSA',
114 title=
'L2muComb delta phi to L2MuonSA '+chain+
';#Delta#phi;Events',
115 type=
'TH1F', path=
'',xbins=120,xmin=-0.2,xmax=0.2)
117 histGroup.defineHistogram(chain+
'_MF_error;L2muComb_MF_error',
118 title=
'L2muComb pointer to MuonFeature Error '+chain+
';;Events',
119 type=
'TH1I', path=
'',xbins=4,xmin=0,xmax=4,
120 xlabels=[
"No error",
"Missing muSATrackLink",
"TrackLink and ElementLinnk matching error",
"SA reconstruction Error"])
124 histGroup.defineHistogram(chain+
'_trkPt;L2muComb_trkPt',
125 title=
'L2muComb Trk Pt (GeV/c) '+chain+
';p_{T} [GeV];Events',
126 type=
'TH1F', path=
'',xbins=210,xmin=-105.,xmax=105.)
128 histGroup.defineHistogram(chain+
'_trkEta;L2muComb_trkEta',
129 title=
'L2muComb Trk Eta '+chain+
';#eta;Events',
130 type=
'TH1F', path=
'',xbins=108,xmin=-2.7,xmax=2.7)
132 histGroup.defineHistogram(chain+
'_trkPhi;L2muComb_trkPhi',
133 title=
'L2muComb Trk Phi '+chain+
';#phi;Events',
134 type=
'TH1F', path=
'',xbins=96,xmin=-ROOT.TMath.Pi(),xmax=ROOT.TMath.Pi())
136 histGroup.defineHistogram(chain+
'_trkZ0;L2muComb_trkZ0',
137 title=
'L2muComb Trk z0 (mm) '+chain+
';z0[mm];Events',
138 type=
'TH1F', path=
'',xbins=150,xmin=-300.,xmax=300.)
140 histGroup.defineHistogram(chain+
'_trkChi2;L2muComb_trkChi2',
141 title=
'L2muComb Trk chi2 '+chain+
';#chi^{2};Events',
142 type=
'TH1F', path=
'',xbins=50,xmin=0.,xmax=10.)
146 histGroup.defineHistogram(chain+
'_ptratio_TrktoSA;L2muComb_ptratio_TrktoSA',
147 title=
'L2muComb Trk pt / L2MuonSA pt '+chain+
';p_{T} ratio;Events',
148 type=
'TH1F', path=
'',xbins=140,xmin=-0.5,xmax=3.)
150 histGroup.defineHistogram(chain+
'_dR_TrktoSA;L2muComb_dR_TrktoSA',
151 title=
'L2muComb delta R Trk to L2MuonSA '+chain+
';#DeltaR;Events',
152 type=
'TH1F', path=
'',xbins=100,xmin=0.,xmax=0.5)
154 histGroup.defineHistogram(chain+
'_dEta_TrktoSA;L2muComb_dEta_TrktoSA',
155 title=
'L2muComb delta eta Trk to L2MuonSA '+chain+
';#Delta#eta;Events',
156 type=
'TH1F', path=
'',xbins=120,xmin=-0.2,xmax=0.2)
158 histGroup.defineHistogram(chain+
'_dPhi_TrktoSA;L2muComb_dPhi_TrktoSA',
159 title=
'L2muComb delta phi Trk to L2MuonSA '+chain+
';#Delta#phi;Events',
160 type=
'TH1F', path=
'',xbins=120,xmin=-0.2,xmax=0.2)
164 histGroup.defineHistogram(chain+
'_dRmin;L2muComb_dR_toOffl',
165 title=
'dR between L2muComb and Offline '+chain+
';#DeltaR;Events',
166 type=
'TH1F', path=
'',xbins=100,xmin=0.,xmax=2.)
168 histGroup.defineHistogram(chain+
'_ptresol;L2muComb_ptresol_toOffl',
169 title=
'L2muComb pT resolution wrt Offline '+chain+
';p_{T} resol;Events',
170 type=
'TH1F', path=
'',xbins=100,xmin=-2.,xmax=2.)
172 histGroup.defineHistogram(chain+
'_offEta,'+chain+
'_ptresol;L2muComb_ptresol_toOffl_eta',
173 title=
'L2muComb pT resolution wrt Offline in eta '+chain+
';#eta;p_{T} resol',
174 type=
'TH2F', path=
'',xbins=16,xmin=-3.2,xmax=3.2, ybins=100,ymin=-2.,ymax=2.)
178 histGroup.defineHistogram(chain+
'_L2SARoI_dR;L2MuonSA_L2SARoI_dR_toRecMuonCB',
179 title=
'L2MuonSA L2SARoI dR wrt offline CB '+chain+
';dR(L2SARoI vs offl CB);Events',
180 type=
'TH1F', path=
'',xbins=100,xmin=0.,xmax=0.5)
182 histGroup.defineHistogram(chain+
'_offEta,'+chain+
'_L2SARoI_dEta;L2MuonSA_L2SARoI_dEta_vs_Eta_toRecMuonCB',
183 title=
'L2MuonSA L2SARoI wrt Offline CB muon, d#eta '+chain+
';offl CB #eta;d#eta(L2SARoI vs offl CB)',
184 type=
'TH2F', path=
'',xbins=54,xmin=-2.7,xmax=2.7, ybins=60,ymin=-0.3,ymax=0.3)
186 histGroup.defineHistogram(chain+
'_offEta,'+chain+
'_L2SARoI_dPhi;L2MuonSA_L2SARoI_dPhi_vs_Eta_toRecMuonCB',
187 title=
'L2MuonSA L2SARoI wrt Offline CB muon, d#phi '+chain+
';offl CB #eta;d#phi(L2SARoI vs offl CB)',
188 type=
'TH2F', path=
'',xbins=54,xmin=-2.7,xmax=2.7, ybins=44,ymin=-0.2,ymax=0.2)