CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
HLTL1TSeed.cc
Go to the documentation of this file.
1 #include <string>
2 #include <list>
3 #include <vector>
4 #include <algorithm>
5 #include <iostream>
6 #include <sstream>
7 #include <cassert>
8 
24 
26 
27 #include "HLTL1TSeed.h"
28 
29 using namespace std;
30 
31 // constructors
33  : HLTStreamFilter(parSet),
34  //useObjectMaps_(parSet.getParameter<bool>("L1UseL1TriggerObjectMaps")),
35  m_l1SeedsLogicalExpression(parSet.getParameter<string>("L1SeedsLogicalExpression")),
36  m_l1GtObjectMapTag(parSet.getParameter<edm::InputTag>("L1ObjectMapInputTag")),
37  m_l1GtObjectMapToken(consumes<GlobalObjectMapRecord>(m_l1GtObjectMapTag)),
38  m_l1GlobalTag(parSet.getParameter<edm::InputTag>("L1GlobalInputTag")),
39  m_l1GlobalToken(consumes<GlobalAlgBlkBxCollection>(m_l1GlobalTag)),
40  m_l1MuonCollectionsTag(parSet.getParameter<edm::InputTag>("L1MuonInputTag")), // FIX WHEN UNPACKERS ADDED
41  m_l1MuonTag(m_l1MuonCollectionsTag),
42  m_l1MuonToken(consumes<l1t::MuonBxCollection>(m_l1MuonTag)),
43  m_l1EGammaCollectionsTag(parSet.getParameter<edm::InputTag>("L1EGammaInputTag")), // FIX WHEN UNPACKERS ADDED
44  m_l1EGammaTag(m_l1EGammaCollectionsTag),
45  m_l1EGammaToken(consumes<l1t::EGammaBxCollection>(m_l1EGammaTag)),
46  m_l1JetCollectionsTag(parSet.getParameter<edm::InputTag>("L1JetInputTag")), // FIX WHEN UNPACKERS ADDED
47  m_l1JetTag(m_l1JetCollectionsTag),
48  m_l1JetToken(consumes<l1t::JetBxCollection>(m_l1JetTag)),
49  m_l1TauCollectionsTag(parSet.getParameter<edm::InputTag>("L1TauInputTag")), // FIX WHEN UNPACKERS ADDED
50  m_l1TauTag(m_l1TauCollectionsTag),
51  m_l1TauToken(consumes<l1t::TauBxCollection>(m_l1TauTag)),
52  m_l1EtSumCollectionsTag(parSet.getParameter<edm::InputTag>("L1EtSumInputTag")), // FIX WHEN UNPACKERS ADDED
53  m_l1EtSumTag(m_l1EtSumCollectionsTag),
54  m_l1EtSumToken(consumes<l1t::EtSumBxCollection>(m_l1EtSumTag)),
55  m_l1GlobalDecision(false),
56  m_isDebugEnabled(edm::isDebugEnabled()) {
57  if (m_l1SeedsLogicalExpression.empty()) {
58  throw cms::Exception("FailModule") << "\nTrying to seed with an empty L1SeedsLogicalExpression.\n" << std::endl;
59 
60  } else if (m_l1SeedsLogicalExpression != "L1GlobalDecision") {
61  // check also the logical expression - add/remove spaces if needed
63 
64  // list of required algorithms for seeding
65  // dummy values for tokenNumber and tokenResult
68  size_t l1AlgoSeedsSize = m_l1AlgoSeeds.size();
69 
70  m_l1AlgoSeedsRpn.reserve(l1AlgoSeedsSize);
71  m_l1AlgoSeedsObjType.reserve(l1AlgoSeedsSize);
72 
73  } else {
74  m_l1GlobalDecision = true;
75  }
76 }
77 
78 // destructor
80  // empty now
81 }
82 
83 // member functions
84 
88 
89  // # logical expression for the required L1 algorithms;
90  // # the algorithms are specified by name
91  // # allowed operators: "AND", "OR", "NOT", "(", ")"
92  // #
93  // # by convention, "L1GlobalDecision" logical expression means global decision
94  desc.add<string>("L1SeedsLogicalExpression", "");
95  desc.add<edm::InputTag>("L1ObjectMapInputTag", edm::InputTag("hltGtStage2ObjectMap"));
96  desc.add<edm::InputTag>("L1GlobalInputTag", edm::InputTag("hltGtStage2Digis"));
97  desc.add<edm::InputTag>("L1MuonInputTag", edm::InputTag("hltGmtStage2Digis:Muon"));
98  desc.add<edm::InputTag>("L1EGammaInputTag", edm::InputTag("hltCaloStage2Digis:EGamma"));
99  desc.add<edm::InputTag>("L1JetInputTag", edm::InputTag("hltCaloStage2Digis:Jet"));
100  desc.add<edm::InputTag>("L1TauInputTag", edm::InputTag("hltCaloStage2Digis:Tau"));
101  desc.add<edm::InputTag>("L1EtSumInputTag", edm::InputTag("hltCaloStage2Digis:EtSum"));
102  descriptions.add("hltL1TSeed", desc);
103 }
104 
106  const edm::EventSetup& evSetup,
107  trigger::TriggerFilterObjectWithRefs& filterproduct) {
108  bool rc = false;
109 
110  // the filter object
111  if (saveTags()) {
112  // muons
113  filterproduct.addCollectionTag(m_l1MuonTag);
114 
115  // egamma
116  filterproduct.addCollectionTag(m_l1EGammaTag);
117 
118  // jet
119  filterproduct.addCollectionTag(m_l1JetTag);
120 
121  // tau
122  filterproduct.addCollectionTag(m_l1TauTag);
123 
124  // etsum
125  filterproduct.addCollectionTag(m_l1EtSumTag);
126  }
127 
128  // Get all the seeding from iEvent (i.e. L1TriggerObjectMapRecord)
129  //
130  rc = seedsL1TriggerObjectMaps(iEvent, filterproduct);
131 
132  if (m_isDebugEnabled) {
133  dumpTriggerFilterObjectWithRefs(filterproduct);
134  }
135 
136  return rc;
137 }
138 
139 // detailed print of filter content
141  LogTrace("HLTL1TSeed") << "\nHLTL1TSeed::hltFilter "
142  << "\n Dump TriggerFilterObjectWithRefs\n"
143  << endl;
144 
145  vector<l1t::MuonRef> seedsL1Mu;
146  filterproduct.getObjects(trigger::TriggerL1Mu, seedsL1Mu);
147  const size_t sizeSeedsL1Mu = seedsL1Mu.size();
148 
149  LogTrace("HLTL1TSeed") << "\n HLTL1TSeed: seed logical expression = " << m_l1SeedsLogicalExpression << endl;
150 
151  LogTrace("HLTL1TSeed") << "\n L1Mu seeds: " << sizeSeedsL1Mu << endl << endl;
152 
153  for (size_t i = 0; i != sizeSeedsL1Mu; i++) {
154  l1t::MuonRef obj = l1t::MuonRef(seedsL1Mu[i]);
155 
156  LogTrace("HLTL1TSeed") << "\tL1Mu "
157  << "\t"
158  << "q = "
159  << obj->hwCharge() // TEMP get hwCharge insead of charge which is not yet set NEED FIX.
160  << "\t"
161  << "pt = " << obj->pt() << "\t"
162  << "eta = " << obj->eta() << "\t"
163  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
164  }
165 
166  vector<l1t::EGammaRef> seedsL1EG;
167  filterproduct.getObjects(trigger::TriggerL1EG, seedsL1EG);
168  const size_t sizeSeedsL1EG = seedsL1EG.size();
169 
170  LogTrace("HLTL1TSeed") << "\n L1EG seeds: " << sizeSeedsL1EG << endl << endl;
171 
172  for (size_t i = 0; i != sizeSeedsL1EG; i++) {
173  l1t::EGammaRef obj = l1t::EGammaRef(seedsL1EG[i]);
174 
175  LogTrace("HLTL1TSeed") << "\tL1EG "
176  << "\t"
177  << "pt = " << obj->pt() << "\t"
178  << "eta = " << obj->eta() << "\t"
179  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
180  }
181 
182  vector<l1t::JetRef> seedsL1Jet;
183  filterproduct.getObjects(trigger::TriggerL1Jet, seedsL1Jet);
184  const size_t sizeSeedsL1Jet = seedsL1Jet.size();
185 
186  LogTrace("HLTL1TSeed") << "\n L1Jet seeds: " << sizeSeedsL1Jet << endl << endl;
187 
188  for (size_t i = 0; i != sizeSeedsL1Jet; i++) {
189  l1t::JetRef obj = l1t::JetRef(seedsL1Jet[i]);
190 
191  LogTrace("HLTL1TSeed") << "\tL1Jet "
192  << "\t"
193  << "pt = " << obj->pt() << "\t"
194  << "eta = " << obj->eta() << "\t"
195  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
196  }
197 
198  vector<l1t::TauRef> seedsL1Tau;
199  filterproduct.getObjects(trigger::TriggerL1Tau, seedsL1Tau);
200  const size_t sizeSeedsL1Tau = seedsL1Tau.size();
201 
202  LogTrace("HLTL1TSeed") << "\n L1Tau seeds: " << sizeSeedsL1Tau << endl << endl;
203 
204  for (size_t i = 0; i != sizeSeedsL1Tau; i++) {
205  l1t::TauRef obj = l1t::TauRef(seedsL1Tau[i]);
206 
207  LogTrace("HLTL1TSeed") << "\tL1Tau "
208  << "\t"
209  << "pt = " << obj->pt() << "\t"
210  << "eta = " << obj->eta() << "\t"
211  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
212  }
213 
214  vector<l1t::EtSumRef> seedsL1EtSumETT;
215  filterproduct.getObjects(trigger::TriggerL1ETT, seedsL1EtSumETT);
216  const size_t sizeSeedsL1EtSumETT = seedsL1EtSumETT.size();
217  LogTrace("HLTL1TSeed") << "\n L1EtSum ETT seeds: " << sizeSeedsL1EtSumETT << endl << endl;
218 
219  for (size_t i = 0; i != sizeSeedsL1EtSumETT; i++) {
220  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumETT[i]);
221 
222  LogTrace("HLTL1TSeed") << "\tL1EtSum ETT"
223  << "\t"
224  << "pt = " << obj->pt() << "\t"
225  << "eta = " << obj->eta() << "\t"
226  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
227  }
228 
229  vector<l1t::EtSumRef> seedsL1EtSumHTT;
230  filterproduct.getObjects(trigger::TriggerL1HTT, seedsL1EtSumHTT);
231  const size_t sizeSeedsL1EtSumHTT = seedsL1EtSumHTT.size();
232  LogTrace("HLTL1TSeed") << "\n L1EtSum HTT seeds: " << sizeSeedsL1EtSumHTT << endl << endl;
233 
234  for (size_t i = 0; i != sizeSeedsL1EtSumHTT; i++) {
235  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumHTT[i]);
236 
237  LogTrace("HLTL1TSeed") << "\tL1EtSum HTT"
238  << "\t"
239  << "pt = " << obj->pt() << "\t"
240  << "eta = " << obj->eta() << "\t"
241  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
242  }
243 
244  vector<l1t::EtSumRef> seedsL1EtSumETM;
245  filterproduct.getObjects(trigger::TriggerL1ETM, seedsL1EtSumETM);
246  const size_t sizeSeedsL1EtSumETM = seedsL1EtSumETM.size();
247  LogTrace("HLTL1TSeed") << "\n L1EtSum ETM seeds: " << sizeSeedsL1EtSumETM << endl << endl;
248 
249  for (size_t i = 0; i != sizeSeedsL1EtSumETM; i++) {
250  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumETM[i]);
251 
252  LogTrace("HLTL1TSeed") << "\tL1EtSum ETM"
253  << "\t"
254  << "pt = " << obj->pt() << "\t"
255  << "eta = " << obj->eta() << "\t"
256  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
257  }
258 
259  vector<l1t::EtSumRef> seedsL1EtSumETMHF;
260  filterproduct.getObjects(trigger::TriggerL1ETMHF, seedsL1EtSumETMHF);
261  const size_t sizeSeedsL1EtSumETMHF = seedsL1EtSumETMHF.size();
262  LogTrace("HLTL1TSeed") << "\n L1EtSum ETMHF seeds: " << sizeSeedsL1EtSumETMHF << endl << endl;
263 
264  for (size_t i = 0; i != sizeSeedsL1EtSumETMHF; i++) {
265  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumETMHF[i]);
266 
267  LogTrace("HLTL1TSeed") << "\tL1EtSum ETMHF"
268  << "\t"
269  << "pt = " << obj->pt() << "\t"
270  << "eta = " << obj->eta() << "\t"
271  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
272  }
273 
274  vector<l1t::EtSumRef> seedsL1EtSumHTM;
275  filterproduct.getObjects(trigger::TriggerL1HTM, seedsL1EtSumHTM);
276  const size_t sizeSeedsL1EtSumHTM = seedsL1EtSumHTM.size();
277  LogTrace("HLTL1TSeed") << "\n L1EtSum HTM seeds: " << sizeSeedsL1EtSumHTM << endl << endl;
278 
279  for (size_t i = 0; i != sizeSeedsL1EtSumHTM; i++) {
280  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumHTM[i]);
281 
282  LogTrace("HLTL1TSeed") << "\tL1EtSum HTM"
283  << "\t"
284  << "pt = " << obj->pt() << "\t"
285  << "eta = " << obj->eta() << "\t"
286  << "phi = " << obj->phi(); //<< "\t" << "BX = " << obj->bx();
287  }
288 
289  vector<l1t::EtSumRef> seedsL1EtSumCentrality;
290  filterproduct.getObjects(trigger::TriggerL1Centrality, seedsL1EtSumCentrality);
291  const size_t sizeSeedsL1EtSumCentrality = seedsL1EtSumCentrality.size();
292  LogTrace("HLTL1TSeed") << "\n L1EtSum Centrality seeds: " << sizeSeedsL1EtSumCentrality << endl << endl;
293 
294  for (size_t i = 0; i != sizeSeedsL1EtSumCentrality; i++) {
295  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumCentrality[i]);
296 
297  LogTrace("HLTL1TSeed") << "\tL1EtSum Centrality Bits: " << std::bitset<8>(obj->hwPt())
298  << " (hwPt = " << obj->hwPt() << ")";
299  }
300 
301  vector<l1t::EtSumRef> seedsL1EtSumMinBiasHFP0;
302  filterproduct.getObjects(trigger::TriggerL1MinBiasHFP0, seedsL1EtSumMinBiasHFP0);
303  const size_t sizeSeedsL1EtSumMinBiasHFP0 = seedsL1EtSumMinBiasHFP0.size();
304  LogTrace("HLTL1TSeed") << "\n L1EtSum MinBiasHFP0 seeds: " << sizeSeedsL1EtSumMinBiasHFP0 << endl << endl;
305 
306  for (size_t i = 0; i != sizeSeedsL1EtSumMinBiasHFP0; i++) {
307  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumMinBiasHFP0[i]);
308 
309  LogTrace("HLTL1TSeed") << "\tL1EtSum MinBiasHFP0: hwPt = " << obj->hwPt();
310  }
311 
312  vector<l1t::EtSumRef> seedsL1EtSumMinBiasHFM0;
313  filterproduct.getObjects(trigger::TriggerL1MinBiasHFM0, seedsL1EtSumMinBiasHFM0);
314  const size_t sizeSeedsL1EtSumMinBiasHFM0 = seedsL1EtSumMinBiasHFM0.size();
315  LogTrace("HLTL1TSeed") << "\n L1EtSum MinBiasHFM0 seeds: " << sizeSeedsL1EtSumMinBiasHFM0 << endl << endl;
316 
317  for (size_t i = 0; i != sizeSeedsL1EtSumMinBiasHFM0; i++) {
318  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumMinBiasHFM0[i]);
319 
320  LogTrace("HLTL1TSeed") << "\tL1EtSum MinBiasHFM0: hwPt = " << obj->hwPt();
321  }
322 
323  vector<l1t::EtSumRef> seedsL1EtSumMinBiasHFP1;
324  filterproduct.getObjects(trigger::TriggerL1MinBiasHFP1, seedsL1EtSumMinBiasHFP1);
325  const size_t sizeSeedsL1EtSumMinBiasHFP1 = seedsL1EtSumMinBiasHFP1.size();
326  LogTrace("HLTL1TSeed") << "\n L1EtSum MinBiasHFP1 seeds: " << sizeSeedsL1EtSumMinBiasHFP1 << endl << endl;
327 
328  for (size_t i = 0; i != sizeSeedsL1EtSumMinBiasHFP1; i++) {
329  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumMinBiasHFP1[i]);
330 
331  LogTrace("HLTL1TSeed") << "\tL1EtSum MinBiasHFP1: hwPt = " << obj->hwPt();
332  }
333 
334  vector<l1t::EtSumRef> seedsL1EtSumMinBiasHFM1;
335  filterproduct.getObjects(trigger::TriggerL1MinBiasHFM1, seedsL1EtSumMinBiasHFM1);
336  const size_t sizeSeedsL1EtSumMinBiasHFM1 = seedsL1EtSumMinBiasHFM1.size();
337  LogTrace("HLTL1TSeed") << "\n L1EtSum MinBiasHFM1 seeds: " << sizeSeedsL1EtSumMinBiasHFM1 << endl << endl;
338 
339  for (size_t i = 0; i != sizeSeedsL1EtSumMinBiasHFM1; i++) {
340  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumMinBiasHFM1[i]);
341 
342  LogTrace("HLTL1TSeed") << "\tL1EtSum MinBiasHFM1: hwPt = " << obj->hwPt();
343  }
344 
345  vector<l1t::EtSumRef> seedsL1EtSumTowerCount;
346  filterproduct.getObjects(trigger::TriggerL1TowerCount, seedsL1EtSumTowerCount);
347  const size_t sizeSeedsL1EtSumTowerCount = seedsL1EtSumTowerCount.size();
348  LogTrace("HLTL1TSeed") << "\n L1EtSum TowerCount seeds: " << sizeSeedsL1EtSumTowerCount << endl << endl;
349 
350  for (size_t i = 0; i != sizeSeedsL1EtSumTowerCount; i++) {
351  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumTowerCount[i]);
352 
353  LogTrace("HLTL1TSeed") << "\tL1EtSum TowerCount: hwPt = " << obj->hwPt();
354  }
355 
356  vector<l1t::EtSumRef> seedsL1EtSumAsymEt;
357  filterproduct.getObjects(trigger::TriggerL1AsymEt, seedsL1EtSumAsymEt);
358  const size_t sizeSeedsL1EtSumAsymEt = seedsL1EtSumAsymEt.size();
359  LogTrace("HLTL1TSeed") << "\n L1EtSum AsymEt seeds: " << sizeSeedsL1EtSumAsymEt << endl << endl;
360 
361  for (size_t i = 0; i != sizeSeedsL1EtSumAsymEt; i++) {
362  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumAsymEt[i]);
363 
364  LogTrace("HLTL1TSeed") << "\tL1EtSum AsymEt: hwPt = " << obj->hwPt();
365  }
366 
367  vector<l1t::EtSumRef> seedsL1EtSumAsymHt;
368  filterproduct.getObjects(trigger::TriggerL1AsymHt, seedsL1EtSumAsymHt);
369  const size_t sizeSeedsL1EtSumAsymHt = seedsL1EtSumAsymHt.size();
370  LogTrace("HLTL1TSeed") << "\n L1EtSum AsymHt seeds: " << sizeSeedsL1EtSumAsymHt << endl << endl;
371 
372  for (size_t i = 0; i != sizeSeedsL1EtSumAsymHt; i++) {
373  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumAsymHt[i]);
374 
375  LogTrace("HLTL1TSeed") << "\tL1EtSum AsymHt: hwPt = " << obj->hwPt();
376  }
377 
378  vector<l1t::EtSumRef> seedsL1EtSumAsymEtHF;
379  filterproduct.getObjects(trigger::TriggerL1AsymEtHF, seedsL1EtSumAsymEtHF);
380  const size_t sizeSeedsL1EtSumAsymEtHF = seedsL1EtSumAsymEtHF.size();
381  LogTrace("HLTL1TSeed") << "\n L1EtSum AsymEtHF seeds: " << sizeSeedsL1EtSumAsymEtHF << endl << endl;
382 
383  for (size_t i = 0; i != sizeSeedsL1EtSumAsymEtHF; i++) {
384  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumAsymEtHF[i]);
385 
386  LogTrace("HLTL1TSeed") << "\tL1EtSum AsymEtHF: hwPt = " << obj->hwPt();
387  }
388 
389  vector<l1t::EtSumRef> seedsL1EtSumAsymHtHF;
390  filterproduct.getObjects(trigger::TriggerL1AsymHtHF, seedsL1EtSumAsymHtHF);
391  const size_t sizeSeedsL1EtSumAsymHtHF = seedsL1EtSumAsymHtHF.size();
392  LogTrace("HLTL1TSeed") << "\n L1EtSum AsymHtHF seeds: " << sizeSeedsL1EtSumAsymHtHF << endl << endl;
393 
394  for (size_t i = 0; i != sizeSeedsL1EtSumAsymHtHF; i++) {
395  l1t::EtSumRef obj = l1t::EtSumRef(seedsL1EtSumAsymHtHF[i]);
396 
397  LogTrace("HLTL1TSeed") << "\tL1EtSum AsymHtHF: hwPt = " << obj->hwPt();
398  }
399 
400  LogTrace("HLTL1TSeed") << " \n\n" << endl;
401 }
402 
403 // seeding is done via L1 trigger object maps, considering the objects which fired in L1
405  // Two GT objects are obtained from the Event: (1) the unpacked GT and (2) the emulated GT.
406  // Return value of the function is the score of seeding logical expression, evaluated using (1).
407  // Seeding is performed (per l1_algo) if ACCEPT both in (1) and (2). Seed objects are identified
408  // and only available from ObjectMaps created in (2).
409 
410  // define index lists for all particle types
411 
412  std::list<int> listMuon;
413 
414  std::list<int> listEG;
415 
416  std::list<int> listJet;
417  std::list<int> listTau;
418 
419  std::list<int> listETM;
420  std::list<int> listETT;
421  std::list<int> listHTT;
422  std::list<int> listHTM;
423  std::list<int> listETMHF;
424 
425  std::list<int> listJetCounts;
426 
427  std::list<int> listCentrality;
428  std::list<int> listMinBiasHFP0;
429  std::list<int> listMinBiasHFM0;
430  std::list<int> listMinBiasHFP1;
431  std::list<int> listMinBiasHFM1;
432  std::list<int> listTotalEtEm;
433  std::list<int> listMissingEtHF;
434  std::list<int> listTowerCount;
435  std::list<int> listAsymEt;
436  std::list<int> listAsymHt;
437  std::list<int> listAsymEtHF;
438  std::list<int> listAsymHtHF;
439 
440  // get handle to unpacked GT
442  iEvent.getByToken(m_l1GlobalToken, uGtAlgoBlocks);
443 
444  if (!uGtAlgoBlocks.isValid()) {
445  edm::LogWarning("HLTL1TSeed") << " Warning: GlobalAlgBlkBxCollection with input tag " << m_l1GlobalTag
446  << " requested in configuration, but not found in the event." << std::endl;
447 
448  return false;
449  }
450 
451  // check size
452  if (uGtAlgoBlocks->size() == 0) {
453  edm::LogWarning("HLTL1TSeed") << " Warning: GlobalAlgBlkBxCollection with input tag " << m_l1GlobalTag
454  << " is empty." << std::endl;
455 
456  return false;
457  }
458 
459  // get handle to object maps from emulator (one object map per algorithm)
460  edm::Handle<GlobalObjectMapRecord> gtObjectMapRecord;
461  iEvent.getByToken(m_l1GtObjectMapToken, gtObjectMapRecord);
462 
463  if (!gtObjectMapRecord.isValid()) {
464  edm::LogWarning("HLTL1TSeed") << " Warning: GlobalObjectMapRecord with input tag " << m_l1GtObjectMapTag
465  << " requested in configuration, but not found in the event." << std::endl;
466 
467  return false;
468  }
469 
470  if (m_isDebugEnabled) {
471  const std::vector<GlobalObjectMap>& objMaps = gtObjectMapRecord->gtObjectMap();
472 
473  LogTrace("HLTL1TSeed") << "\nHLTL1Seed"
474  << "\n--------------------------------------------------------------------------------------"
475  "-------------------------------";
476 
477  LogTrace("HLTL1TSeed")
478  << "\n\tAlgorithms in L1TriggerObjectMapRecord and GT results ( emulated | initial | prescaled | final ) "
479  << endl;
480 
481  LogTrace("HLTL1TSeed") << "\n\tmap"
482  << "\tAlgoBit" << std::setw(40) << "algoName"
483  << "\t (emul|ini|pre|fin)" << endl;
484 
485  LogTrace("HLTL1TSeed") << "----------------------------------------------------------------------------------------"
486  "-----------------------------";
487 
488  for (size_t imap = 0; imap < objMaps.size(); imap++) {
489  int bit = objMaps[imap].algoBitNumber(); // same as bit from L1T Menu
490 
491  int emulDecision = objMaps[imap].algoGtlResult();
492 
493  // For bx=0 , get 0th AlgoBlock, so in BXvector at(bx=0,i=0)
494  int initDecision = (uGtAlgoBlocks->at(0, 0)).getAlgoDecisionInitial(bit);
495  int presDecision = (uGtAlgoBlocks->at(0, 0)).getAlgoDecisionInterm(bit);
496  int finlDecision = (uGtAlgoBlocks->at(0, 0)).getAlgoDecisionFinal(bit);
497 
498  if (emulDecision != initDecision) {
499  LogTrace("HLTL1TSeed") << "L1T decision (emulated vs. unpacked initial) is not the same:"
500  << "\n\tbit = " << std::setw(3) << bit << std::setw(40) << objMaps[imap].algoName()
501  << "\t emulated decision = " << emulDecision
502  << "\t unpacked initial decision = " << initDecision
503  << "\nThis should not happen. Include the L1TGtEmulCompare module in the sequence."
504  << endl;
505  }
506 
507  LogTrace("HLTL1TSeed") << "\t" << std::setw(3) << imap << "\tbit = " << std::setw(3) << bit << std::setw(40)
508  << objMaps[imap].algoName() << "\t ( " << emulDecision << " | " << initDecision << " | "
509  << presDecision << " | " << finlDecision << " ) ";
510  }
511  LogTrace("HLTL1TSeed") << endl;
512  }
513 
514  // Filter decision in case of "L1GlobalDecision" logical expression.
515  // By convention, it means global decision.
516  // /////////////////////////////////////////////////////////////////
517  if (m_l1GlobalDecision) {
518  // For bx=0 , get 0th AlgoBlock, so in BXvector at(bx=0,i=0)
519  return (uGtAlgoBlocks->at(0, 0)).getFinalOR();
520  }
521 
522  // Update/Reset m_l1AlgoLogicParser by reseting token result
523  // /////////////////////////////////////////////////////////
524  std::vector<GlobalLogicParser::OperandToken>& algOpTokenVector = m_l1AlgoLogicParser.operandTokenVector();
525 
526  for (auto& i : algOpTokenVector) {
527  // rest token result
528  //
529  i.tokenResult = false;
530  }
531 
532  // Update m_l1AlgoLogicParser and store emulator results for algOpTokens
533  // /////////////////////////////////////////////////////////////////////
534  for (auto& i : algOpTokenVector) {
535  std::string algoName = i.tokenName;
536 
537  const GlobalObjectMap* objMap = gtObjectMapRecord->getObjectMap(algoName);
538 
539  if (objMap == nullptr) {
540  throw cms::Exception("FailModule")
541  << "\nAlgorithm " << algoName
542  << ", requested as seed by a HLT path, cannot be matched to a L1 algo name in any GlobalObjectMap\n"
543  << "Please check if algorithm " << algoName << " is present in the L1 menu\n"
544  << std::endl;
545 
546  } else {
547  //(algOpTokenVector[i]).tokenResult = objMap->algoGtlResult();
548 
549  int bit = objMap->algoBitNumber();
550  bool finalAlgoDecision = (uGtAlgoBlocks->at(0, 0)).getAlgoDecisionFinal(bit);
551  i.tokenResult = finalAlgoDecision;
552  }
553  }
554 
555  // Filter decision
556  // ///////////////
557  bool seedsResult = m_l1AlgoLogicParser.expressionResult();
558 
559  if (m_isDebugEnabled) {
560  LogTrace("HLTL1TSeed") << "\nHLTL1TSeed: l1SeedsLogicalExpression (names) = '" << m_l1SeedsLogicalExpression << "'"
561  << "\n Result for logical expression after update of algOpTokens: " << seedsResult << "\n"
562  << std::endl;
563  }
564 
567 
568  for (std::vector<GlobalLogicParser::OperandToken>::const_iterator itSeed = m_l1AlgoSeeds.begin();
569  itSeed != m_l1AlgoSeeds.end();
570  ++itSeed) {
571  std::string algoSeedName = (*itSeed).tokenName;
572 
573  LogTrace("HLTL1TSeed") << "\n ---------------- algo seed name = " << algoSeedName << endl;
574 
575  const GlobalObjectMap* objMap = gtObjectMapRecord->getObjectMap(algoSeedName);
576 
577  if (objMap == nullptr) {
578  // Should not get here
579  //
580  throw cms::Exception("FailModule")
581  << "\nAlgorithm " << algoSeedName
582  << ", requested as seed by a HLT path, cannot be matched to a L1 algo name in any GlobalObjectMap\n"
583  << "Please check if algorithm " << algoSeedName << " is present in the L1 menu\n"
584  << std::endl;
585  }
586 
587  int algoSeedBitNumber = objMap->algoBitNumber();
588  bool algoSeedResult = objMap->algoGtlResult();
589 
590  // unpacked GT results: uGtAlgoBlock has decisions initial, prescaled, and final after masks
591  bool algoSeedResultMaskAndPresc = uGtAlgoBlocks->at(0, 0).getAlgoDecisionFinal(algoSeedBitNumber);
592 
593  LogTrace("HLTL1TSeed") << "\n\tAlgo seed " << algoSeedName << " result emulated | final = " << algoSeedResult
594  << " | " << algoSeedResultMaskAndPresc << endl;
595 
598  if (!algoSeedResultMaskAndPresc)
599  continue;
600 
602  // This should not happen if the emulated and unpacked GT are consistent
604  if (!algoSeedResult)
605  continue;
606 
607  const std::vector<GlobalLogicParser::OperandToken>& opTokenVecObjMap = objMap->operandTokenVector();
608  const std::vector<L1TObjectTypeInCond>& condObjTypeVec = objMap->objectTypeVector();
609  const std::vector<CombinationsInCond>& condCombinations = objMap->combinationVector();
610 
611  LogTrace("HLTL1TSeed") << "\n\talgoName =" << objMap->algoName() << "\talgoBitNumber = " << algoSeedBitNumber
612  << "\talgoGtlResult = " << algoSeedResult << endl
613  << endl;
614 
615  if (opTokenVecObjMap.size() != condObjTypeVec.size()) {
616  edm::LogWarning("HLTL1TSeed")
617  << "\nWarning: GlobalObjectMapRecord with input tag " << m_l1GtObjectMapTag
618  << "\nhas object map for bit number " << algoSeedBitNumber
619  << " which contains different size vectors of operand tokens and of condition object types!" << std::endl;
620 
621  assert(opTokenVecObjMap.size() == condObjTypeVec.size());
622  }
623 
624  if (opTokenVecObjMap.size() != condCombinations.size()) {
625  edm::LogWarning("HLTL1TSeed")
626  << "\nWarning: GlobalObjectMapRecord with input tag " << m_l1GtObjectMapTag
627  << "\nhas object map for bit number " << algoSeedBitNumber
628  << " which contains different size vectors of operand tokens and of condition object combinations!"
629  << std::endl;
630 
631  assert(opTokenVecObjMap.size() == condCombinations.size());
632  }
633 
634  // operands are conditions of L1 algo
635  //
636  for (size_t condNumber = 0; condNumber < opTokenVecObjMap.size(); condNumber++) {
637  std::vector<l1t::GlobalObject> condObjType = condObjTypeVec[condNumber];
638 
639  for (auto& jOb : condObjType) {
640  LogTrace("HLTL1TSeed") << setw(15) << "\tcondObjType = " << jOb << endl;
641  }
642 
643  const std::string condName = opTokenVecObjMap[condNumber].tokenName;
644  bool condResult = opTokenVecObjMap[condNumber].tokenResult;
645 
646  // only procede for conditions that passed
647  //
648  if (!condResult) {
649  continue;
650  }
651 
652  // loop over combinations for a given condition
653  //
654  const CombinationsInCond* condComb = objMap->getCombinationsInCond(condNumber);
655 
656  LogTrace("HLTL1TSeed") << setw(15) << "\tcondCombinations = " << condComb->size() << endl;
657 
658  for (auto const& itComb : (*condComb)) {
659  LogTrace("HLTL1TSeed") << setw(15) << "\tnew combination" << endl;
660 
661  // loop over objects in a combination for a given condition
662  //
663  for (auto itObject = itComb.begin(); itObject != itComb.end(); itObject++) {
664  // in case of object-less triggers (e.g. L1_ZeroBias) condObjType vector is empty, so don't seed!
665  //
666  if (condObjType.empty()) {
667  LogTrace("HLTL1TSeed")
668  << "\talgoName = " << objMap->algoName()
669  << " is object-less L1 algorithm, so do not attempt to store any objects to the list of seeds.\n"
670  << std::endl;
671  continue;
672  }
673 
674  // the index of the object type is the same as the index of the object
675  size_t iType = std::distance(itComb.begin(), itObject);
676 
677  // get object type and push indices on the list
678  //
679  const l1t::GlobalObject objTypeVal = condObjType.at(iType);
680 
681  LogTrace("HLTL1TSeed") << "\tAdd object of type " << objTypeVal << " and index " << (*itObject)
682  << " to the seed list." << std::endl;
683 
684  // THESE OBJECT CASES ARE CURRENTLY MISSING:
685  //gtMinBias,
686  //gtExternal,
687  //ObjNull
688 
689  switch (objTypeVal) {
690  case l1t::gtMu: {
691  listMuon.push_back(*itObject);
692  }
693 
694  break;
695  case l1t::gtEG: {
696  listEG.push_back(*itObject);
697  } break;
698  case l1t::gtJet: {
699  listJet.push_back(*itObject);
700  } break;
701  case l1t::gtTau: {
702  listTau.push_back(*itObject);
703  } break;
704  case l1t::gtETM: {
705  listETM.push_back(*itObject);
706  } break;
707  case l1t::gtETT: {
708  listETT.push_back(*itObject);
709  } break;
710  case l1t::gtHTT: {
711  listHTT.push_back(*itObject);
712  } break;
713  case l1t::gtHTM: {
714  listHTM.push_back(*itObject);
715  } break;
716  case l1t::gtETMHF: {
717  listETMHF.push_back(*itObject);
718  } break;
719  case l1t::gtTowerCount: {
720  listTowerCount.push_back(*itObject);
721  } break;
722  case l1t::gtMinBiasHFP0: {
723  listMinBiasHFP0.push_back(*itObject);
724  } break;
725  case l1t::gtMinBiasHFM0: {
726  listMinBiasHFM0.push_back(*itObject);
727  } break;
728  case l1t::gtMinBiasHFP1: {
729  listMinBiasHFP1.push_back(*itObject);
730  } break;
731  case l1t::gtMinBiasHFM1: {
732  listMinBiasHFM1.push_back(*itObject);
733  } break;
734  case l1t::gtETTem: {
735  listTotalEtEm.push_back(*itObject);
736  } break;
737  case l1t::gtAsymmetryEt: {
738  listAsymEt.push_back(*itObject);
739  } break;
740  case l1t::gtAsymmetryHt: {
741  listAsymHt.push_back(*itObject);
742  } break;
743  case l1t::gtAsymmetryEtHF: {
744  listAsymEtHF.push_back(*itObject);
745  } break;
746  case l1t::gtAsymmetryHtHF: {
747  listAsymHtHF.push_back(*itObject);
748  } break;
749  case l1t::gtCentrality0:
750  case l1t::gtCentrality1:
751  case l1t::gtCentrality2:
752  case l1t::gtCentrality3:
753  case l1t::gtCentrality4:
754  case l1t::gtCentrality5:
755  case l1t::gtCentrality6:
756  case l1t::gtCentrality7: {
757  listCentrality.push_back(*itObject);
758  } break;
759 
760  //case JetCounts: {
761  // listJetCounts.push_back(*itObject);
762  //}
763 
764  break;
765  default: {
766  // should not arrive here
767 
768  LogTrace("HLTL1TSeed") << "\n HLTL1TSeed::hltFilter "
769  << "\n Unknown object of type " << objTypeVal << " and index " << (*itObject)
770  << " in the seed list." << std::endl;
771  } break;
772 
773  } // end switch objTypeVal
774 
775  } // end for itObj
776 
777  } // end for itComb
778 
779  } // end for condition
780 
781  } // end for itSeed
782 
783  // eliminate duplicates
784 
785  listMuon.sort();
786  listMuon.unique();
787 
788  listEG.sort();
789  listEG.unique();
790 
791  listJet.sort();
792  listJet.unique();
793 
794  listTau.sort();
795  listTau.unique();
796 
797  listETM.sort();
798  listETM.unique();
799 
800  listETT.sort();
801  listETT.unique();
802 
803  listHTT.sort();
804  listHTT.unique();
805 
806  listHTM.sort();
807  listHTM.unique();
808 
809  listETMHF.sort();
810  listETMHF.unique();
811 
812  listJetCounts.sort();
813  listJetCounts.unique();
814 
815  listCentrality.sort();
816  listCentrality.unique();
817 
818  listMinBiasHFP0.sort();
819  listMinBiasHFP0.unique();
820 
821  listMinBiasHFM0.sort();
822  listMinBiasHFM0.unique();
823 
824  listMinBiasHFP1.sort();
825  listMinBiasHFP1.unique();
826 
827  listMinBiasHFM1.sort();
828  listMinBiasHFM1.unique();
829 
830  listTotalEtEm.sort();
831  listTotalEtEm.unique();
832 
833  listMissingEtHF.sort();
834  listMissingEtHF.unique();
835 
836  listTowerCount.sort();
837  listTowerCount.unique();
838 
839  listAsymEt.sort();
840  listAsymEt.unique();
841 
842  listAsymHt.sort();
843  listAsymHt.unique();
844 
845  listAsymEtHF.sort();
846  listAsymEtHF.unique();
847 
848  listAsymHtHF.sort();
849  listAsymHtHF.unique();
850 
851  // record the L1 physics objects in the HLT filterproduct
852  // //////////////////////////////////////////////////////
853 
854  // Muon
855  if (!listMuon.empty()) {
857  iEvent.getByToken(m_l1MuonToken, muons);
858 
859  if (!muons.isValid()) {
860  edm::LogWarning("HLTL1TSeed") << "\nWarning: L1MuonBxCollection with input tag " << m_l1MuonTag
861  << "\nrequested in configuration, but not found in the event."
862  << "\nNo muons added to filterproduct." << endl;
863  } else {
864  for (std::list<int>::const_iterator itObj = listMuon.begin(); itObj != listMuon.end(); ++itObj) {
865  // Transform to index for Bx = 0 to begin of BxVector
866  unsigned int index = muons->begin(0) - muons->begin() + *itObj;
867 
868  l1t::MuonRef myref(muons, index);
869  filterproduct.addObject(trigger::TriggerL1Mu, myref);
870  }
871  }
872  }
873 
874  // EG (isolated)
875  if (!listEG.empty()) {
877  iEvent.getByToken(m_l1EGammaToken, egammas);
878  if (!egammas.isValid()) {
879  edm::LogWarning("HLTL1TSeed") << "\nWarning: L1EGammaBxCollection with input tag " << m_l1EGammaTag
880  << "\nrequested in configuration, but not found in the event."
881  << "\nNo egammas added to filterproduct." << endl;
882  } else {
883  for (std::list<int>::const_iterator itObj = listEG.begin(); itObj != listEG.end(); ++itObj) {
884  // Transform to begin of BxVector
885  unsigned int index = egammas->begin(0) - egammas->begin() + *itObj;
886 
887  l1t::EGammaRef myref(egammas, index);
888  filterproduct.addObject(trigger::TriggerL1EG, myref);
889  }
890  }
891  }
892 
893  // Jet
894  if (!listJet.empty()) {
896  iEvent.getByToken(m_l1JetToken, jets);
897 
898  if (!jets.isValid()) {
899  edm::LogWarning("HLTL1TSeed") << "\nWarning: L1JetBxCollection with input tag " << m_l1JetTag
900  << "\nrequested in configuration, but not found in the event."
901  << "\nNo jets added to filterproduct." << endl;
902  } else {
903  for (std::list<int>::const_iterator itObj = listJet.begin(); itObj != listJet.end(); ++itObj) {
904  // Transform to begin of BxVector
905  unsigned int index = jets->begin(0) - jets->begin() + *itObj;
906 
907  l1t::JetRef myref(jets, index);
908  filterproduct.addObject(trigger::TriggerL1Jet, myref);
909  }
910  }
911  }
912 
913  // Tau
914  if (!listTau.empty()) {
916  iEvent.getByToken(m_l1TauToken, taus);
917 
918  if (!taus.isValid()) {
919  edm::LogWarning("HLTL1TSeed") << "\nWarning: L1TauBxCollection with input tag " << m_l1TauTag
920  << "\nrequested in configuration, but not found in the event."
921  << "\nNo taus added to filterproduct." << endl;
922  } else {
923  for (std::list<int>::const_iterator itObj = listTau.begin(); itObj != listTau.end(); ++itObj) {
924  // Transform to begin of BxVector
925  unsigned int index = taus->begin(0) - taus->begin() + *itObj;
926 
927  l1t::TauRef myref(taus, index);
928  filterproduct.addObject(trigger::TriggerL1Tau, myref);
929  }
930  }
931  }
932 
933  // ETT, HTT, ETM, HTM
935  iEvent.getByToken(m_l1EtSumToken, etsums);
936  if (!etsums.isValid()) {
937  edm::LogWarning("HLTL1TSeed") << "\nWarning: L1EtSumBxCollection with input tag " << m_l1EtSumTag
938  << "\nrequested in configuration, but not found in the event."
939  << "\nNo etsums added to filterproduct." << endl;
940  } else {
942 
943  for (iter = etsums->begin(0); iter != etsums->end(0); ++iter) {
944  l1t::EtSumRef myref(etsums, etsums->key(iter));
945 
946  switch (iter->getType()) {
948  if (!listETT.empty())
949  filterproduct.addObject(trigger::TriggerL1ETT, myref);
950  break;
952  if (!listHTT.empty())
953  filterproduct.addObject(trigger::TriggerL1HTT, myref);
954  break;
956  if (!listETM.empty())
957  filterproduct.addObject(trigger::TriggerL1ETM, myref);
958  break;
960  if (!listHTM.empty())
961  filterproduct.addObject(trigger::TriggerL1HTM, myref);
962  break;
964  if (!listETMHF.empty())
965  filterproduct.addObject(trigger::TriggerL1ETMHF, myref);
966  break;
968  if (!listCentrality.empty())
969  filterproduct.addObject(trigger::TriggerL1Centrality, myref);
970  break;
972  if (!listMinBiasHFP0.empty())
973  filterproduct.addObject(trigger::TriggerL1MinBiasHFP0, myref);
974  break;
976  if (!listMinBiasHFM0.empty())
977  filterproduct.addObject(trigger::TriggerL1MinBiasHFM0, myref);
978  break;
980  if (!listMinBiasHFP1.empty())
981  filterproduct.addObject(trigger::TriggerL1MinBiasHFP1, myref);
982  break;
984  if (!listMinBiasHFM1.empty())
985  filterproduct.addObject(trigger::TriggerL1MinBiasHFM1, myref);
986  break;
988  if (!listTotalEtEm.empty())
989  filterproduct.addObject(trigger::TriggerL1TotalEtEm, myref);
990  break;
992  if (!listTowerCount.empty())
993  filterproduct.addObject(trigger::TriggerL1TowerCount, myref);
994  break;
995  case l1t::EtSum::kAsymEt:
996  if (!listAsymEt.empty())
997  filterproduct.addObject(trigger::TriggerL1AsymEt, myref);
998  break;
999  case l1t::EtSum::kAsymHt:
1000  if (!listAsymHt.empty())
1001  filterproduct.addObject(trigger::TriggerL1AsymHt, myref);
1002  break;
1003  case l1t::EtSum::kAsymEtHF:
1004  if (!listAsymEtHF.empty())
1005  filterproduct.addObject(trigger::TriggerL1AsymEtHF, myref);
1006  break;
1007  case l1t::EtSum::kAsymHtHF:
1008  if (!listAsymHtHF.empty())
1009  filterproduct.addObject(trigger::TriggerL1AsymHtHF, myref);
1010  break;
1011  default:
1012  LogTrace("HLTL1TSeed") << " L1EtSum seed of currently unsuported HLT TriggerType. l1t::EtSum type: "
1013  << iter->getType() << "\n";
1014 
1015  } // end switch
1016 
1017  } // end for
1018 
1019  } // end else
1020 
1021  // TODO FIXME uncomment if block when JetCounts implemented
1022 
1023  // // jet counts
1024  // if (!listJetCounts.empty()) {
1025  // edm::Handle<l1extra::L1JetCounts> l1JetCounts;
1026  // iEvent.getByToken(m_l1CollectionsToken.label(), l1JetCounts);
1027  //
1028  // for (std::list<int>::const_iterator itObj = listJetCounts.begin();
1029  // itObj != listJetCounts.end(); ++itObj) {
1030  //
1031  // filterproduct.addObject(trigger::TriggerL1JetCounts,l1extra::L1JetCountsRefProd(l1JetCounts));
1032  // // FIXME: RefProd!
1033  //
1034  // }
1035  //
1036  // }
1037 
1038  LogTrace("HLTL1TSeed") << "\nHLTL1Seed:seedsL1TriggerObjectMaps returning " << seedsResult << endl << endl;
1039 
1040  return seedsResult;
1041 }
1042 
1043 // register as framework plugin
BXVector< EGamma > EGammaBxCollection
Definition: EGamma.h:10
std::string m_l1SeedsLogicalExpression
Definition: HLTL1TSeed.h:97
bool isDebugEnabled()
virtual const bool expressionResult() const
void getObjects(Vids &ids, VRphoton &refs) const
various physics-level getters:
edm::EDGetTokenT< l1t::EtSumBxCollection > m_l1EtSumToken
Definition: HLTL1TSeed.h:131
edm::Ref< EGammaBxCollection > EGammaRef
Definition: TkEGTau.h:35
std::vector< const std::vector< GlobalLogicParser::TokenRPN > * > m_l1AlgoSeedsRpn
vector of Rpn vectors for the required algorithms for seeding
Definition: HLTL1TSeed.h:85
const std::vector< L1TObjectTypeInCond > & objectTypeVector() const
edm::InputTag m_l1MuonTag
Definition: HLTL1TSeed.h:110
HLTL1TSeed(const edm::ParameterSet &)
constructor
Definition: HLTL1TSeed.cc:32
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:539
enum start value shifted to 81 so as to avoid clashes with PDG codes
bool seedsL1TriggerObjectMaps(edm::Event &, trigger::TriggerFilterObjectWithRefs &)
seeding is done via L1 trigger object maps, considering the objects which fired in L1 ...
Definition: HLTL1TSeed.cc:404
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
GlobalObject
Definition: GlobalObject.h:16
edm::Ref< JetBxCollection > JetRef
Definition: Jet.h:12
edm::Ref< EtSumBxCollection > EtSumRef
Definition: EtSum.h:12
bool algoGtlResult() const
assert(be >=bs)
BXVector< Tau > TauBxCollection
Definition: Tau.h:10
std::vector< GlobalLogicParser::OperandToken > expressionSeedsOperandList()
#define LogTrace(id)
void addObject(int id, const reco::RecoEcalCandidateRef &ref)
setters for L3 collections: (id=physics type, and Ref&lt;C&gt;)
std::vector< T >::const_iterator const_iterator
Definition: BXVector.h:18
BXVector< EtSum > EtSumBxCollection
Definition: EtSum.h:10
int iEvent
Definition: GenABIO.cc:224
edm::InputTag m_l1JetTag
Definition: HLTL1TSeed.h:120
edm::InputTag m_l1GtObjectMapTag
InputTag for L1 Global Trigger object maps. This is done per menu. Should be part of Run...
Definition: HLTL1TSeed.h:100
~HLTL1TSeed() override
destructor
Definition: HLTL1TSeed.cc:79
vector< PseudoJet > jets
edm::EDGetTokenT< l1t::JetBxCollection > m_l1JetToken
Definition: HLTL1TSeed.h:121
std::vector< OperandToken > & operandTokenVector()
return the vector of operand tokens
GlobalLogicParser m_l1AlgoLogicParser
logic parser for m_l1SeedsLogicalExpression
Definition: HLTL1TSeed.h:79
edm::EDGetTokenT< l1t::EGammaBxCollection > m_l1EGammaToken
Definition: HLTL1TSeed.h:116
edm::InputTag m_l1EtSumTag
Definition: HLTL1TSeed.h:130
edm::InputTag m_l1TauTag
Definition: HLTL1TSeed.h:125
edm::Ref< TauBxCollection > TauRef
Definition: Tau.h:12
int algoBitNumber() const
get / set bit number for algorithm in the object map
ParameterDescriptionBase * add(U const &iLabel, T const &value)
bool isValid() const
Definition: HandleBase.h:70
const std::vector< CombinationsInCond > & combinationVector() const
BXVector< Muon > MuonBxCollection
Definition: Muon.h:11
const std::vector< GlobalLogicParser::OperandToken > & operandTokenVector() const
bool m_isDebugEnabled
cache edm::isDebugEnabled()
Definition: HLTL1TSeed.h:137
std::vector< GlobalLogicParser::OperandToken > m_l1AlgoSeeds
list of required algorithms for seeding
Definition: HLTL1TSeed.h:82
const std::string & algoName() const
destructor
BXVector< Jet > JetBxCollection
Definition: Jet.h:10
edm::InputTag m_l1EGammaTag
Definition: HLTL1TSeed.h:115
void addCollectionTag(const edm::InputTag &collectionTag)
collectionTags
void add(std::string const &label, ParameterSetDescription const &psetDescription)
edm::InputTag m_l1GlobalTag
InputTag for L1 Global Trigger.
Definition: HLTL1TSeed.h:104
edm::EDGetTokenT< GlobalAlgBlkBxCollection > m_l1GlobalToken
Definition: HLTL1TSeed.h:105
const CombinationsInCond * getCombinationsInCond(const std::string &condNameVal) const
return all the combinations passing the requirements imposed in condition condNameVal ...
tuple muons
Definition: patZpeak.py:39
void dumpTriggerFilterObjectWithRefs(trigger::TriggerFilterObjectWithRefs &) const
detailed print of filter content
Definition: HLTL1TSeed.cc:140
edm::Ref< MuonBxCollection > MuonRef
Definition: Muon.h:13
bool hltFilter(edm::Event &, const edm::EventSetup &, trigger::TriggerFilterObjectWithRefs &filterproduct) override
filter the event
Definition: HLTL1TSeed.cc:105
bool m_l1GlobalDecision
flag to pass if L1TGlobal accept
Definition: HLTL1TSeed.h:134
Log< level::Warning, false > LogWarning
std::vector< SingleCombInCond > CombinationsInCond
all the object combinations evaluated to true in the condition
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
parameter description
Definition: HLTL1TSeed.cc:85
static void makeHLTFilterDescription(edm::ParameterSetDescription &desc)
std::vector< std::vector< const std::vector< l1t::GlobalObject > * > > m_l1AlgoSeedsObjType
vector of object-type vectors for each condition in the required algorithms for seeding ...
Definition: HLTL1TSeed.h:88
edm::EDGetTokenT< l1t::MuonBxCollection > m_l1MuonToken
Definition: HLTL1TSeed.h:111
tuple size
Write out results.
bool saveTags() const
edm::EDGetTokenT< l1t::TauBxCollection > m_l1TauToken
Definition: HLTL1TSeed.h:126
edm::EDGetTokenT< GlobalObjectMapRecord > m_l1GtObjectMapToken
Definition: HLTL1TSeed.h:101