11 elif objtype ==
"Photon":
13 elif objtype ==
"Ele":
15 elif objtype ==
"MET" :
17 elif objtype ==
"PFMET" :
19 elif objtype ==
"PFTau":
21 elif objtype ==
"Jet":
26 numer_description =
"# gen %s passed the %s" % (objtypeLatex,triggerpath)
27 denom_description =
"# gen %s " % (objtypeLatex)
29 if plot_type ==
"TurnOn1":
31 xAxis =
"p_{T} of Leading Generated %s (GeV/c)" % (objtype)
32 input_type =
"gen%sMaxPt1" % (objtype)
33 elif plot_type ==
"TurnOn2":
34 title =
"Next-to-Leading pT Turn-On"
35 xAxis =
"p_{T} of Next-to-Leading Generated %s (GeV/c)" % (objtype)
36 input_type =
"gen%sMaxPt2" % (objtype)
37 elif plot_type ==
"EffEta":
38 title =
"#eta Efficiency"
39 xAxis =
"#eta of Generated %s " % (objtype)
40 input_type =
"gen%sEta" % (objtype)
41 elif plot_type ==
"EffPhi":
42 title =
"#phi Efficiency"
43 xAxis =
"#phi of Generated %s " % (objtype)
44 input_type =
"gen%sPhi" % (objtype)
45 elif "TurnOn" in plot_type:
46 title =
"%sth Leading pT Turn-On" % (plot_type[-1])
47 xAxis =
"p_{T} of %sth Leading Generated %s (GeV/c)" % (plot_type[-1], objtype)
48 input_type =
"gen%sMaxPt%s" % (objtype, plot_type[-1])
49 elif plot_type ==
"EffdEtaqq":
50 title =
"#Delta #eta_{qq} Efficiency"
51 xAxis =
"#Delta #eta_{qq} of Generated %s " % (objtype)
52 input_type =
"gen%sdEtaqq" % (objtype)
53 elif plot_type ==
"Effmqq":
54 title =
"m_{qq} Efficiency"
55 xAxis =
"m_{qq} of Generated %s " % (objtype)
56 input_type =
"gen%smqq" % (objtype)
57 elif plot_type ==
"EffdPhibb":
58 title =
"#Delta #phi_{bb} Efficiency"
59 xAxis =
"#Delta #phi_{bb} of Generated %s " % (objtype)
60 input_type =
"gen%sdPhibb" % (objtype)
61 elif plot_type ==
"EffCSV1":
62 title =
"CSV1 Efficiency"
63 xAxis =
"CSV1 of Generated %s " % (objtype)
64 input_type =
"gen%sCSV1" % (objtype)
65 elif plot_type ==
"EffCSV2":
66 title =
"CSV2 Efficiency"
67 xAxis =
"CSV2 of Generated %s " % (objtype)
68 input_type =
"gen%sCSV2" % (objtype)
69 elif plot_type ==
"EffCSV3":
70 title =
"CSV3 Efficiency"
71 xAxis =
"CSV3 of Generated %s " % (objtype)
72 input_type =
"gen%sCSV3" % (objtype)
73 elif plot_type ==
"EffmaxCSV":
74 title =
"max CSV Efficiency"
75 xAxis =
"max CSV of Generated %s " % (objtype)
76 input_type =
"gen%smaxCSV" % (objtype)
78 yAxis =
"%s / %s" % (numer_description, denom_description)
79 all_titles =
"%s for trigger %s; %s; %s" % (title, triggerpath,
81 return "Eff_%s_%s '%s' %s_%s %s" % (input_type,triggerpath,
82 all_titles,input_type,triggerpath,input_type)
88 reco_strings.append(entry
89 .
replace(
"Generated",
"Reconstructed")
95 plot_types = [
"TurnOn1",
"TurnOn2",
"EffEta",
"EffPhi"]
98 obj_types = [
"Mu",
"Ele",
"Photon",
"MET",
"PFMET",
"PFTau",
"Jet"]
101 efficiency_strings = []
106 for an
in _config.analysis:
107 s = _config.__getattribute__(an)
108 vstr = s.__getattribute__(
"hltPathsToCheck")
109 map(
lambda x: triggers.add(x.replace(
"_v",
"")),vstr)
110 triggers =
list(triggers)
115 for type
in plot_types:
116 for obj
in obj_types:
117 for trig
in triggers:
122 for an
in _config.analysis:
123 efficiency_strings.append(
"EffSummaryPaths_"+an+
"_gen ' Efficiency of paths used in "+an+
" ; trigger path ' SummaryPaths_"+an+
"_gen_passingHLT SummaryPaths_"+an+
"_gen")
124 for trig
in triggers:
125 efficiency_strings.append(
"Eff_trueVtxDist_"+an+
"_gen_"+trig+
" ' Efficiency of "+trig+
" vs nb of interactions ; nb events passing each path ' trueVtxDist_"+an+
"_gen_"+trig+
" trueVtxDist_"+an+
"_gen")
131 hltHiggsPostHWW = hltHiggsPostProcessor.clone()
132 hltHiggsPostHWW.subDirs = [
'HLT/Higgs/HWW']
133 hltHiggsPostHWW.efficiencyProfile = efficiency_strings
136 hltHiggsPostHZZ = hltHiggsPostProcessor.clone()
137 hltHiggsPostHZZ.subDirs = [
'HLT/Higgs/HZZ']
138 hltHiggsPostHZZ.efficiencyProfile = efficiency_strings
141 hltHiggsPostHgg = hltHiggsPostProcessor.clone()
142 hltHiggsPostHgg.subDirs = [
'HLT/Higgs/Hgg']
143 hltHiggsPostHgg.efficiencyProfile = efficiency_strings
145 hltHiggsPostDoubleHinTaus = hltHiggsPostProcessor.clone()
146 hltHiggsPostDoubleHinTaus.subDirs = [
'HLT/Higgs/DoubleHinTaus']
147 hltHiggsPostDoubleHinTaus.efficiencyProfile = efficiency_strings
149 hltHiggsPostHiggsDalitz = hltHiggsPostProcessor.clone()
150 hltHiggsPostHiggsDalitz.subDirs = [
'HLT/Higgs/HiggsDalitz']
151 hltHiggsPostHiggsDalitz.efficiencyProfile = efficiency_strings
153 hltHiggsPostH2tau = hltHiggsPostProcessor.clone()
154 hltHiggsPostH2tau.subDirs = [
'HLT/Higgs/H2tau']
155 hltHiggsPostH2tau.efficiencyProfile = efficiency_strings
158 hltHiggsPostHtaunu = hltHiggsPostProcessor.clone()
159 hltHiggsPostHtaunu.subDirs = [
'HLT/Higgs/Htaunu']
160 hltHiggsPostHtaunu.efficiencyProfile = efficiency_strings
163 efficiency_strings_TTHbbej =
list(efficiency_strings)
165 for an
in _config.analysis:
166 for trig
in triggers:
167 efficiency_strings_TTHbbej.append(
"Eff_HtDist_"+an+
"_gen_"+trig+
" ' Efficiency of "+trig+
" vs sum pT of jets ; sum pT of jets ' HtDist_"+an+
"_gen_"+trig+
" HtDist_"+an+
"_gen")
169 efficiency_strings_TTHbbej.extend(
get_reco_strings(efficiency_strings_TTHbbej))
171 hltHiggsPostTTHbbej = hltHiggsPostProcessor.clone()
172 hltHiggsPostTTHbbej.subDirs = [
'HLT/Higgs/TTHbbej']
173 hltHiggsPostTTHbbej.efficiencyProfile = efficiency_strings_TTHbbej
177 NminOneCutNames = (
"EffdEtaqq",
"Effmqq",
"EffdPhibb",
"EffCSV1",
"EffCSV2",
"EffCSV3",
"EffmaxCSV",
"",
"",
"TurnOn1",
"TurnOn2",
"TurnOn3",
"TurnOn4")
179 NminOneCuts = (_config.__getattribute__(
"VBFHbb_2btag")).__getattribute__(
"NminOneCuts")
181 for iCut
in range(0,len(NminOneCuts)):
182 if( NminOneCuts[iCut]
and NminOneCutNames[iCut] ):
183 if( NminOneCutNames[iCut] ==
"EffmaxCSV" ):
185 plot_types.append(NminOneCutNames[iCut])
187 efficiency_strings = []
188 for type
in plot_types:
190 for trig
in triggers:
195 hltHiggsPostVBFHbb_2btag = hltHiggsPostProcessor.clone()
196 hltHiggsPostVBFHbb_2btag.subDirs = [
'HLT/Higgs/VBFHbb_2btag']
197 hltHiggsPostVBFHbb_2btag.efficiencyProfile = efficiency_strings
201 NminOneCutNames = (
"EffdEtaqq",
"Effmqq",
"EffdPhibb",
"EffCSV1",
"EffCSV2",
"EffCSV3",
"EffmaxCSV",
"",
"",
"TurnOn1",
"TurnOn2",
"TurnOn3",
"TurnOn4")
203 NminOneCuts = (_config.__getattribute__(
"VBFHbb_1btag")).__getattribute__(
"NminOneCuts")
205 for iCut
in range(0,len(NminOneCuts)):
206 if( NminOneCuts[iCut]
and NminOneCutNames[iCut] ):
207 if( NminOneCutNames[iCut] ==
"EffmaxCSV" ):
209 plot_types.append(NminOneCutNames[iCut])
211 hltHiggsPostVBFHbb_1btag = hltHiggsPostProcessor.clone()
212 hltHiggsPostVBFHbb_1btag.subDirs = [
'HLT/Higgs/VBFHbb_1btag']
213 hltHiggsPostVBFHbb_1btag.efficiencyProfile = efficiency_strings
217 NminOneCutNames = (
"EffdEtaqq",
"Effmqq",
"EffdPhibb",
"EffCSV1",
"EffCSV2",
"EffCSV3",
"EffmaxCSV",
"",
"",
"TurnOn1",
"TurnOn2",
"TurnOn3",
"TurnOn4")
219 NminOneCuts = (_config.__getattribute__(
"VBFHbb_0btag")).__getattribute__(
"NminOneCuts")
221 for iCut
in range(0,len(NminOneCuts)):
222 if( NminOneCuts[iCut]
and NminOneCutNames[iCut] ):
223 plot_types.append(NminOneCutNames[iCut])
225 hltHiggsPostVBFHbb_0btag = hltHiggsPostProcessor.clone()
226 hltHiggsPostVBFHbb_0btag.subDirs = [
'HLT/Higgs/VBFHbb_0btag']
227 hltHiggsPostVBFHbb_0btag.efficiencyProfile = efficiency_strings
233 plot_types = [
"EffEta",
"EffPhi"]
234 NminOneCuts = (_config.__getattribute__(
"ZnnHbb")).__getattribute__(
"NminOneCuts")
236 for iCut
in range(0,len(NminOneCuts)):
237 if( NminOneCuts[iCut]
and NminOneCutNames[iCut] ):
238 plot_types.append(NminOneCutNames[iCut])
240 efficiency_strings = []
241 for type
in plot_types:
243 for trig
in triggers:
249 plot_types = [
"TurnOn1",
"EffPhi"]
250 efficiency_strings2 = []
251 for type
in plot_types:
252 for obj
in [
"PFMET"]:
253 for trig
in triggers:
257 efficiency_strings += efficiency_strings2
259 hltHiggsPostZnnHbb = hltHiggsPostProcessor.clone()
260 hltHiggsPostZnnHbb.subDirs = [
'HLT/Higgs/ZnnHbb']
261 hltHiggsPostZnnHbb.efficiencyProfile = efficiency_strings
266 NminOneCuts = (_config.__getattribute__(
"X4b")).__getattribute__(
"NminOneCuts")
268 for iCut
in range(0,len(NminOneCuts)):
269 if( NminOneCuts[iCut]
and NminOneCutNames[iCut] ):
270 plot_types.append(NminOneCutNames[iCut])
272 efficiency_strings = []
273 for type
in plot_types:
275 for trig
in triggers:
280 hltHiggsPostX4b = hltHiggsPostProcessor.clone()
281 hltHiggsPostX4b.subDirs = [
'HLT/Higgs/X4b']
282 hltHiggsPostX4b.efficiencyProfile = efficiency_strings
286 hltHiggsPostProcessors = cms.Sequence(
293 hltHiggsPostVBFHbb_0btag+
294 hltHiggsPostVBFHbb_1btag+
295 hltHiggsPostVBFHbb_2btag+
297 hltHiggsPostDoubleHinTaus+
298 hltHiggsPostHiggsDalitz+
if(conf.exists("allCellsPositionCalc"))
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger list("!*","!HLTx*"if it matches 2 triggers or more) will accept the event if all the matching triggers are FAIL.It will reject the event if any of the triggers are PASS or EXCEPTION(this matches the behavior of"!*"before the partial wildcard feature was incorporated).Triggers which are in the READY state are completely ignored.(READY should never be returned since the trigger paths have been run