175 def defineEachStepHistograms(xvariable, xlabel, xbins, xmin, xmax):
176 histGroup.defineHistogram(GroupName+
'_'+xvariable+
';'+xvariable,
177 title=
'All offline combined muon '+chain+
';'+xlabel+
';Events',
178 type=
'TH1F',path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
180 histGroup.defineHistogram(GroupName+
'_L1pass,'+GroupName+
'_'+xvariable+
';EffL1MU_'+xvariable+
'_wrt_Probe',
181 title=
'L1MU Efficiency '+chain+
';'+xlabel+
';Efficiency',
182 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
185 histGroup.defineHistogram(GroupName+
'_L2SApass,'+GroupName+
'_'+xvariable+
';EffL2SA_'+xvariable+
'_wrt_Upstream',
186 title=
'L2MuonSA Efficiency '+chain+
' wrt Upstream;'+xlabel+
';Efficiency',
187 cutmask=GroupName+
'_L1pass',
188 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
190 histGroup.defineHistogram(GroupName+
'_L2SApass,'+GroupName+
'_'+xvariable+
';EffL2SA_'+xvariable+
'_wrt_offlineCB',
191 title=
'L2MuonSA Efficiency '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
192 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
195 histGroup.defineHistogram(GroupName+
'_L2CBpass,'+GroupName+
'_'+xvariable+
';EffL2CB_'+xvariable+
'_wrt_Upstream',
196 title=
'L2muComb Efficiency '+chain+
' wrt Upstream;'+xlabel+
';Efficiency',
197 cutmask=GroupName+
'_L2SApass',
198 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
200 histGroup.defineHistogram(GroupName+
'_L2CBpass,'+GroupName+
'_'+xvariable+
';EffL2CB_'+xvariable+
'_wrt_offlineCB',
201 title=
'L2muComb Efficiency '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
202 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
205 histGroup.defineHistogram(GroupName+
'_EFSApass,'+GroupName+
'_'+xvariable+
';EffEFSA_'+xvariable+
'_wrt_Upstream',
206 title=
'EFSA Muon Efficiency '+chain+
' wrt Upstream;'+xlabel+
';Efficiency',
207 cutmask=GroupName+
'_L2CBpass',
208 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
210 histGroup.defineHistogram(GroupName+
'_EFSApass,'+GroupName+
'_'+xvariable+
';EffEFSA_'+xvariable+
'_wrt_offlineCB',
211 title=
'EFSA Muon Efficiency '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
212 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
214 histGroup.defineHistogram(GroupName+
'_EFSApass,'+GroupName+
'_'+xvariable+
';EffEFSA_'+xvariable+
'_wrt_offlineCB_passedL2SA',
215 title=
'EFSA Muon Efficiency passed L2SA '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
216 cutmask=GroupName+
'_L2SApass',
217 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
220 histGroup.defineHistogram(GroupName+
'_EFCBpass,'+GroupName+
'_'+xvariable+
';EffEFCB_'+xvariable+
'_wrt_Upstream',
221 title=
'EFCB Muon Efficiency '+chain+
' wrt Upstream;'+xlabel+
';Efficiency',
222 cutmask=GroupName+
'_EFSApass',
223 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
225 histGroup.defineHistogram(GroupName+
'_EFCBpass,'+GroupName+
'_'+xvariable+
';EffEFCB_'+xvariable+
'_wrt_offlineCB',
226 title=
'EFCB Muon Efficiency '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
227 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
229 histGroup.defineHistogram(GroupName+
'_EFCBpass,'+GroupName+
'_'+xvariable+
';EffEFCB_'+xvariable+
'_wrt_offlineCB_passedL2CB',
230 title=
'EFCB Muon Efficiency passed L2CB '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
231 cutmask=GroupName+
'_L2CBpass',
232 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
235 histGroup.defineHistogram(GroupName+
'_EFSAFSpass,'+GroupName+
'_'+xvariable+
';EffEFSAFS_'+xvariable+
'_wrt_Upstream',
236 title=
'EFSAFS Muon Efficiency '+chain+
' wrt Upstream;'+xlabel+
';Efficiency',
237 cutmask=GroupName+
'_EFCBpass',
238 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
240 histGroup.defineHistogram(GroupName+
'_EFSAFSpass,'+GroupName+
'_'+xvariable+
';EffEFSAFS_'+xvariable+
'_wrt_offlineCB',
241 title=
'EFSAFS Muon Efficiency '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
242 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
244 histGroup.defineHistogram(GroupName+
'_EFSAFSpass,'+GroupName+
'_'+xvariable+
';EffEFSAFS_'+xvariable+
'_wrt_offlineCB_passedL2SA',
245 title=
'EFSAFS Muon Efficiency passed L2SA '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
246 cutmask=GroupName+
'_L2SApass',
247 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
250 histGroup.defineHistogram(GroupName+
'_EFCBFSpass,'+GroupName+
'_'+xvariable+
';EffEFCBFS_'+xvariable+
'_wrt_Upstream',
251 title=
'EFCBFS Muon Efficiency '+chain+
' wrt Upstream;'+xlabel+
';Efficiency',
252 cutmask=GroupName+
'_EFSAFSpass',
253 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
255 histGroup.defineHistogram(GroupName+
'_EFCBFSpass,'+GroupName+
'_'+xvariable+
';EffEFCBFS_'+xvariable+
'_wrt_offlineCB',
256 title=
'EFCBFS Muon Efficiency '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
257 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
259 histGroup.defineHistogram(GroupName+
'_EFCBFSpass,'+GroupName+
'_'+xvariable+
';EffEFCBFS_'+xvariable+
'_wrt_offlineCB_passedL2CB',
260 title=
'EFCBFS Muon Efficiency passed L2CB '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
261 cutmask=GroupName+
'_L2CBpass',
262 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
266 histGroup.defineHistogram(GroupName+
'_EFIsopass,'+GroupName+
'_'+xvariable+
';EffEFIso_'+xvariable+
'_wrt_Upstream',
267 title=
'EFIso Muon Efficiency '+chain+
' wrt Upstream;'+xlabel+
';Efficiency',
268 cutmask=GroupName+
'_EFCBpass',
269 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
271 histGroup.defineHistogram(GroupName+
'_EFIsopass,'+GroupName+
'_'+xvariable+
';EffEFIso_'+xvariable+
'_wrt_offlineCB',
272 title=
'EFIso Muon Efficiency '+chain+
' wrt offlineCB;'+xlabel+
';Efficiency',
273 type=
'TEfficiency', path=
'',xbins=xbins,xmin=xmin,xmax=xmax)
276 defineEachStepHistograms(
'muPt',
'p_{T} [GeV]', 50, 0.0, 100.)
277 defineEachStepHistograms(
'muEta',
'#eta', 30, -3.0, 3.0)
278 defineEachStepHistograms(
'muPhi',
'#phi', 30, -math.pi, math.pi)
279 if flags.GeoModel.Run >= LHCPeriod.Run4:
280 defineEachStepHistograms(
'averageMu',
'average pileup', 4, 100., 220.)
282 defineEachStepHistograms(
'averageMu',
'average pileup', 4, 0., 80.)
285 histGroup.defineHistogram(GroupName+
'_invmass;invmass',
286 title=
'invariant mass of tag & probe muon '+chain+
';inv mass [GeV];Events',
287 type=
'TH1F',path=
'',xbins=40,xmin=0.,xmax=200.)