CMS 3D CMS Logo

EgHLTDQMCut.h
Go to the documentation of this file.
1 #ifndef DQMOFFLINE_TRIGGER_EGHLTDQMCUT
2 #define DQMOFFLINE_TRIGGER_EGHLTDQMCUT
3 
4 //class: EgHLTDQMCut
5 //
6 //author: Sam Harper (June 2008)
7 //
8 //WARNING: interface is NOT final, please dont use this class for now without clearing it with me
9 // as I will change it and possibly break all your code
10 //
11 //aim: to allow the user to place a cut on the electron using it or the event
12 //
13 //implimentation:
14 
17 
19 
20 //this is a pure virtual struct which defines the interface to the cut objects
21 //it is also currently uncopyable
22 
23 namespace egHLT {
24 
25  template <class T>
26  struct EgHLTDQMCut {
27  private:
28  //disabling copy and assignment for all objects
29  EgHLTDQMCut& operator=(const EgHLTDQMCut& rhs) { return *this; }
30 
31  protected:
32  //only derived classes can call the copy constructor (needed for clone...)
33  EgHLTDQMCut(const EgHLTDQMCut& rhs) = default;
34 
35  public:
36  EgHLTDQMCut() = default;
37  virtual ~EgHLTDQMCut() = default;
38  virtual bool pass(const T& obj, const OffEvt& evt) const = 0;
39  virtual EgHLTDQMCut<T>* clone() const = 0; //caller owns the pointer
40  };
41 
42  template <class T>
43  struct EgHLTDQMVarCut : public EgHLTDQMCut<T> {
44  private:
45  int cutsToPass_; //the cuts whose eff we are measuring
46  int (T::*cutCodeFunc_)() const;
47 
48  public:
49  EgHLTDQMVarCut(int cutsToPass, int (T::*cutCodeFunc)() const)
50  : cutsToPass_(cutsToPass), cutCodeFunc_(cutCodeFunc) {}
51  ~EgHLTDQMVarCut() override = default;
52 
53  bool pass(const T& obj, const OffEvt& evt) const override;
54  EgHLTDQMCut<T>* clone() const override { return new EgHLTDQMVarCut(*this); } //default copy constructor is fine
55  };
56 
57  //to understand this you need to know about
58  //1) templates
59  //2) inheritance (sort of)
60  //3) function pointers
61  //4) bitwise operations
62  //All it does is get the bitword corresponding to the cuts the electron failed and the mask the bits which correspond to cuts we dont care about and then see if any bits are still set
63  template <class T>
64  bool EgHLTDQMVarCut<T>::pass(const T& obj, const OffEvt& evt) const {
65  if (((obj.*cutCodeFunc_)() & cutsToPass_) == 0)
66  return true;
67  else
68  return false;
69  }
70 
71  //now this is similar to EgHLTDQMVarCut except that it allows a key to specified to the cut code function
72  template <class T, class Key>
73  struct EgHLTDQMUserVarCut : public EgHLTDQMCut<T> {
74  private:
75  int (T::*cutCodeFunc_)(const Key&) const;
76  const Key key_;
78 
79  public:
80  EgHLTDQMUserVarCut(int (T::*cutCodeFunc)(const Key&) const, const Key& key, int cutsNotToMask = ~0x0)
81  : cutCodeFunc_(cutCodeFunc), key_(key), cutsNotToMask_(cutsNotToMask) {}
82  ~EgHLTDQMUserVarCut() override = default;
83 
84  bool pass(const T& obj, const OffEvt& evt) const override;
85  EgHLTDQMCut<T>* clone() const override { return new EgHLTDQMUserVarCut(*this); } //default copy constructor is fine
86  };
87 
88  template <class T, class Key>
89  bool EgHLTDQMUserVarCut<T, Key>::pass(const T& obj, const OffEvt& evt) const {
90  if (((obj.*cutCodeFunc_)(key_)&cutsNotToMask_) == 0)
91  return true;
92  else
93  return false;
94  }
95 
96  template <class T, typename varType>
97  struct EgGreaterCut : public EgHLTDQMCut<T> {
98  private:
100  varType (T::*varFunc_)() const;
101 
102  public:
103  EgGreaterCut(varType cutValue, varType (T::*varFunc)() const) : cutValue_(cutValue), varFunc_(varFunc) {}
104 
105  bool pass(const T& obj, const OffEvt& evt) const override { return (obj.*varFunc_)() > cutValue_; }
106  EgHLTDQMCut<T>* clone() const override { return new EgGreaterCut(*this); } //default copy constructor is fine
107  };
108 
109  //this struct allows multiple cuts to be strung together
110  //now I could quite simply have a link to the next cut defined in the base class
111  //and the operator<< defined there also but I dont for the following reason
112  //1) I'm concerned about a circular chain of cuts (hence why you cant do a EgMultiCut << EgMultiCut)
113  //2) it requires all cuts to multi cut aware in the pass function
114  //in the future I may change it so this class isnt required
115  template <class T>
116  struct EgMultiCut : public EgHLTDQMCut<T> {
117  private:
118  std::vector<const EgHLTDQMCut<T>*> cuts_; //all the points to the cuts we own
119 
120  public:
121  EgMultiCut() = default;
122  EgMultiCut(const EgMultiCut<T>& rhs);
123  ~EgMultiCut() override {
124  for (size_t i = 0; i < cuts_.size(); i++)
125  delete cuts_[i];
126  }
127 
128  //we own any cut given to use this way
129  EgMultiCut<T>& operator<<(const EgHLTDQMCut<T>* inputCut);
130 
131  //basically an AND of all the cuts using short circuit evaluation, starting with the first cut
132  //if no cuts present, will default to true
133  bool pass(const T& obj, const OffEvt& evt) const override;
134  EgHLTDQMCut<T>* clone() const override { return new EgMultiCut(*this); }
135  };
136 
137  template <class T>
139  for (size_t cutNr = 0; cutNr < rhs.cuts_.size(); cutNr++) {
140  cuts_.push_back(rhs.cuts_[cutNr]->clone());
141  }
142  }
143 
144  template <class T>
146  if (typeid(*inputCut) == typeid(EgMultiCut)) {
147  edm::LogError("EgMultiCut") << " Error can not currently load an EgMultiCut inside a EgMultiCut, the practical "
148  "upshot is that the selection you think is being loaded isnt ";
149  } else if (inputCut == nullptr) {
150  edm::LogError("EgMultiCut") << "Error, cut being loaded is null, ignoring";
151  } else
152  cuts_.push_back(inputCut);
153  return *this;
154  }
155 
156  template <class T>
157  bool EgMultiCut<T>::pass(const T& obj, const OffEvt& evt) const {
158  for (size_t i = 0; i < cuts_.size(); i++) {
159  if (!cuts_[i]->pass(obj, evt))
160  return false;
161  }
162  return true;
163  }
164 
165  //pass in which bits you want the trigger to pass
166  //how this works
167  //1) you specify the trigger bits you want to pass
168  //2) you then specify whether you require all to be passed (AND) or just 1 (OR). It assumes OR by default
169  //3) optionally, you can then specify any trigger bits you want to ensure fail. If any of these trigger bits
170  // are passed (OR), then the cut fails, you can also specify only to fail if all are passed (AND)
171  template <class T>
172  struct EgObjTrigCut : public EgHLTDQMCut<T> {
173  public:
174  enum CutLogic { AND, OR };
175 
176  private:
177  //currently fine for default copy construction
182 
183  public:
185  CutLogic passLogic = OR,
187  CutLogic failLogic = AND)
188  : bitsToPass_(bitsToPass), passLogic_(passLogic), bitsToFail_(bitsToFail), failLogic_(failLogic) {}
189  ~EgObjTrigCut() override = default;
190 
191  bool pass(const T& obj, const OffEvt& evt) const override;
192  EgHLTDQMCut<T>* clone() const override { return new EgObjTrigCut(*this); }
193  };
194 
195  template <class T>
196  bool EgObjTrigCut<T>::pass(const T& obj, const OffEvt& evt) const {
197  TrigCodes::TrigBitSet passMasked = bitsToPass_ & obj.trigBits();
198  TrigCodes::TrigBitSet failMasked = bitsToFail_ & obj.trigBits();
199 
200  bool passResult = passLogic_ == AND ? passMasked == bitsToPass_ : passMasked != 0x0;
201  bool failResult = failLogic_ == AND ? failMasked == bitsToFail_ : failMasked != 0x0;
202  if (bitsToFail_ == 0x0)
203  failResult = false; //ensuring it has no effect if bits not specified
204  return passResult && !failResult;
205  }
206 
207  //pass in which bits you want the trigger to pass
208  //can either specify to pass all of the bits (AND) or any of the bits (OR)
209  template <class T>
210  struct EgEvtTrigCut : public EgHLTDQMCut<T> {
211  public:
212  enum CutLogic { AND, OR };
213 
214  private:
215  //currently default copy constructor is fine
218 
219  public:
221  : bitsToPass_(bitsToPass), passLogic_(passLogic) {}
222  ~EgEvtTrigCut() = default;
223 
224  bool pass(const T& obj, const OffEvt& evt) const;
225  EgHLTDQMCut<T>* clone() const { return new EgEvtTrigCut(*this); }
226  };
227 
228  template <class T>
229  bool EgEvtTrigCut<T>::pass(const T& obj, const OffEvt& evt) const {
230  TrigCodes::TrigBitSet passMasked = bitsToPass_ & evt.evtTrigBits();
231  return passLogic_ == AND ? passMasked == bitsToPass_ : passMasked != 0x0;
232  }
233 
234  //nots the cut, ie makes it return false instead of true
235  template <class T>
236  struct EgNotCut : public EgHLTDQMCut<T> {
237  private:
238  EgHLTDQMCut<T>* cut_; //we own it
239 
240  public:
242  EgNotCut(const EgNotCut<T>& rhs) : cut_(rhs.cut_->clone()) {}
243  ~EgNotCut() { delete cut_; }
244 
245  bool pass(const T& obj, const OffEvt& evt) const { return !cut_->pass(obj, evt); }
246  EgHLTDQMCut<T>* clone() const { return new EgNotCut(*this); }
247  };
248 
249  //cut on the charge of the electron
250  template <class T>
251  struct ChargeCut : public EgHLTDQMCut<T> {
252  private:
253  int charge_;
254 
255  public:
257  ~ChargeCut() override = default;
258 
259  bool pass(const T& obj, const OffEvt& evt) const override { return obj.charge() == charge_; }
260  EgHLTDQMCut<T>* clone() const override { return new ChargeCut(*this); }
261  };
262 
263  //this askes if an object statifies the probe criteria and that another electron in the event statisfies the tag
264  //although templated, its hard to think of this working for anything else other then an electron
265  template <class T>
266  struct EgTagProbeCut : public EgHLTDQMCut<T> {
267  private:
269  int (T::*probeCutCodeFunc_)() const;
272  float minMass_;
273  float maxMass_;
274 
275  public:
276  EgTagProbeCut(int probeCutCode,
277  int (T::*probeCutCodeFunc)() const,
278  int tagCutCode,
279  int (OffEle::*tagCutCodeFunc)() const,
280  float minMass = 81.,
281  float maxMass = 101.)
282  : probeCutCode_(probeCutCode),
283  probeCutCodeFunc_(probeCutCodeFunc),
284  tagCutCode_(tagCutCode),
285  tagCutCodeFunc_(tagCutCodeFunc),
286  minMass_(minMass),
287  maxMass_(maxMass) {}
288  ~EgTagProbeCut() override = default;
289 
290  bool pass(const T& obj, const OffEvt& evt) const override;
291  EgHLTDQMCut<T>* clone() const override { return new EgTagProbeCut(*this); }
292  };
293 
294  template <class T>
295  bool EgTagProbeCut<T>::pass(const T& obj, const OffEvt& evt) const {
296  int nrTags = 0;
297  const OffEle* tagEle = nullptr;
298  const std::vector<OffEle>& eles = evt.eles();
299  //we are looking for an *additional* tag
300  for (const auto& ele : eles) {
301  if (((ele.*tagCutCodeFunc_)() & tagCutCode_) == 0x0) {
302  //now a check that the tag is not the same as the probe
303  if (reco::deltaR2(obj.eta(), obj.phi(), ele.eta(), ele.phi()) >
304  0.1 * 0.1) { //not in a cone of 0.1 of probe object
305  nrTags++;
306  tagEle = &ele;
307  }
308  }
309  }
310  if (nrTags ==
311  1) { //we are requiring one and only one additional tag (the obj is automatically excluded from the tag list)
312  if (((obj.*probeCutCodeFunc_)() & probeCutCode_) == 0x0) { //passes probe requirements, lets check the mass
313  float mass = (obj.p4() + tagEle->p4()).mag();
314  if (mass > minMass_ && mass < maxMass_)
315  return true; //mass requirements
316  }
317  }
318  return false;
319  }
320 
321  template <class T>
322  struct EgJetTagProbeCut : public EgHLTDQMCut<T> {
323  private:
326 
327  float minDPhi_;
328  float maxDPhi_;
329 
330  public:
331  EgJetTagProbeCut(int probeCutCode, int (T::*probeCutCodeFunc)() const, float minDPhi = -M_PI, float maxDPhi = M_PI)
332  : probeCutCode_(probeCutCode), probeCutCodeFunc_(probeCutCodeFunc), minDPhi_(minDPhi), maxDPhi_(maxDPhi) {}
333  bool pass(const T& obj, const OffEvt& evt) const override;
334  EgHLTDQMCut<T>* clone() const override { return new EgJetTagProbeCut(*this); }
335  };
336 
337  template <class T>
338  bool EgJetTagProbeCut<T>::pass(const T& obj, const OffEvt& evt) const {
339  int nrProbes = 0;
340  const std::vector<OffEle>& eles = evt.eles();
341  for (const auto& ele : eles) {
342  if (((ele.*probeCutCodeFunc_)() & probeCutCode_) == 0x0) {
343  nrProbes++;
344  }
345  }
346  bool b2bJet = false;
347  const std::vector<reco::CaloJet>& jets = evt.jets();
348  for (const auto& jet : jets) {
349  if (reco::deltaR2(obj.eta(), obj.phi(), jet.eta(), jet.phi()) >
350  0.1 * 0.1) { //not in a cone of 0.1 of probe object
351  float dPhi = reco::deltaPhi(obj.phi(), jet.phi());
352  if (dPhi > minDPhi_ && dPhi < maxDPhi_)
353  b2bJet = true;
354  }
355  }
356 
357  return nrProbes == 1 && b2bJet;
358  }
359 
360  template <class T>
361  struct EgJetB2BCut : public EgHLTDQMCut<T> {
362  private:
363  float minDPhi_;
364  float maxDPhi_;
365  float ptRelDiff_;
366 
367  public:
368  EgJetB2BCut(float minDPhi = -M_PI, float maxDPhi = M_PI, float ptRelDiff = 999)
369  : minDPhi_(minDPhi), maxDPhi_(maxDPhi), ptRelDiff_(ptRelDiff) {}
370  bool pass(const T& obj, const OffEvt& evt) const;
371  EgHLTDQMCut<T>* clone() const { return new EgJetB2BCut(*this); }
372  };
373 
374  template <class T>
375  bool EgJetB2BCut<T>::pass(const T& obj, const OffEvt& evt) const {
376  bool b2bJet = false;
377  const std::vector<reco::CaloJet>& jets = evt.jets();
378  for (const auto& jet : jets) {
379  if (reco::deltaR2(obj.eta(), obj.phi(), jet.eta(), jet.phi()) >
380  0.1 * 0.1) { //not in a cone of 0.1 of probe object
381  float dPhi = reco::deltaPhi(obj.phi(), jet.phi());
382  if (dPhi > minDPhi_ && dPhi < maxDPhi_ && fabs(1 - jet.pt() / obj.pt()) < ptRelDiff_)
383  b2bJet = true;
384  }
385  }
386  return b2bJet;
387  }
388 
389  //requires the the passed in electron and another in the event passes the specified cuts
390  struct EgDiEleCut : public EgHLTDQMCut<OffEle> {
391  private:
392  int cutCode_;
393  int (OffEle::*cutCodeFunc_)() const;
394 
395  public:
396  EgDiEleCut(int cutCode, int (OffEle::*cutCodeFunc)() const) : cutCode_(cutCode), cutCodeFunc_(cutCodeFunc) {}
397  bool pass(const OffEle& obj, const OffEvt& evt) const override;
398  EgHLTDQMCut<OffEle>* clone() const override { return new EgDiEleCut(*this); }
399  };
400 
401  //requires the the passed in electron and another in the event passes the specified cuts
402  template <class Key>
403  struct EgDiEleUserCut : public EgHLTDQMCut<OffEle> {
404  private:
405  int (OffEle::*cutCodeFunc_)(const Key&) const;
406  const Key& key_;
408 
409  public:
410  EgDiEleUserCut(int (OffEle::*cutCodeFunc)(const Key&) const, const Key& key, int cutsNotToMask = ~0x0)
411  : cutCodeFunc_(cutCodeFunc), key_(key), cutsNotToMask_(cutsNotToMask) {}
412  ~EgDiEleUserCut() override = default;
413 
414  bool pass(const OffEle& obj, const OffEvt& evt) const override;
415  EgHLTDQMCut<OffEle>* clone() const override {
416  return new EgDiEleUserCut(*this);
417  } //default copy constructor is fine
418  };
419 
420  template <class Key>
421  bool EgDiEleUserCut<Key>::pass(const OffEle& obj, const OffEvt& evt) const {
422  const std::vector<OffEle>& eles = evt.eles();
423  for (const auto& ele : eles) {
424  if (&ele != &obj) { //different electrons
425  int diEleCutCode = (obj.*cutCodeFunc_)(key_) | (ele.*cutCodeFunc_)(key_);
426  if ((diEleCutCode & cutsNotToMask_) == 0x0)
427  return true;
428  }
429  }
430  return false;
431  }
432 
433  //requires the the passed in photon and another in the event passes the specified cuts
434  struct EgDiPhoCut : public EgHLTDQMCut<OffPho> {
435  private:
436  int cutCode_;
437  int (OffPho::*cutCodeFunc_)() const;
438 
439  public:
440  EgDiPhoCut(int cutCode, int (OffPho::*cutCodeFunc)() const) : cutCode_(cutCode), cutCodeFunc_(cutCodeFunc) {}
441  bool pass(const OffPho& obj, const OffEvt& evt) const override;
442  EgHLTDQMCut<OffPho>* clone() const override { return new EgDiPhoCut(*this); }
443  };
444 
445  //requires passed photon and another in the event passes the specified cuts
446  template <class Key>
447  struct EgDiPhoUserCut : public EgHLTDQMCut<OffPho> {
448  private:
449  int (OffPho::*cutCodeFunc_)(const Key&) const;
450  const Key& key_;
452 
453  public:
454  EgDiPhoUserCut(int (OffPho::*cutCodeFunc)(const Key&) const, const Key& key, int cutsNotToMask = ~0x0)
455  : cutCodeFunc_(cutCodeFunc), key_(key), cutsNotToMask_(cutsNotToMask) {}
456  ~EgDiPhoUserCut() override = default;
457 
458  bool pass(const OffPho& obj, const OffEvt& evt) const override;
459  EgHLTDQMCut<OffPho>* clone() const override {
460  return new EgDiPhoUserCut(*this);
461  } //default copy constructor is fine
462  };
463 
464  template <class Key>
465  bool EgDiPhoUserCut<Key>::pass(const OffPho& obj, const OffEvt& evt) const {
466  const std::vector<OffPho>& phos = evt.phos();
467  for (const auto& pho : phos) {
468  if (&pho != &obj) { //different phoctrons
469 
470  int diPhoCutCode = (obj.*cutCodeFunc_)(key_) | (pho.*cutCodeFunc_)(key_);
471  if ((diPhoCutCode & cutsNotToMask_) == 0x0)
472  return true;
473  }
474  }
475  return false;
476  }
477 
478  //a trigger tag and probe cut
479  //basically we require the electron to pass some cuts
480  //and then do tag and probe on the trigger
481  //removing templates as it makes no sense
482  struct EgTrigTagProbeCut : public EgHLTDQMCut<OffEle> {
483  private:
485  int cutCode_;
486  int (OffEle::*cutCodeFunc_)() const;
487  float minMass_;
488  float maxMass_;
489 
490  public:
492  int cutCode,
493  int (OffEle::*cutCodeFunc)() const,
494  float minMass = 81.,
495  float maxMass = 101.)
496  : bitsToPass_(bitsToPass), cutCode_(cutCode), cutCodeFunc_(cutCodeFunc), minMass_(minMass), maxMass_(maxMass) {}
497  ~EgTrigTagProbeCut() override = default;
498 
499  bool pass(const OffEle& ele, const OffEvt& evt) const override;
500  EgHLTDQMCut<OffEle>* clone() const override { return new EgTrigTagProbeCut(*this); }
501  };
502 
503  //----Morse----
504  //new tag and probe cut
505  //require two wp80 electrons
506  struct EgTrigTagProbeCut_New : public EgHLTDQMCut<OffEle> {
507  private:
510  int cutCode_;
511  int (OffEle::*cutCodeFunc_)() const;
512  float minMass_;
513  float maxMass_;
514 
515  public:
517  TrigCodes::TrigBitSet bit2ToPass,
518  int cutCode,
519  int (OffEle::*cutCodeFunc)() const,
520  float minMass = 81.,
521  float maxMass = 101.)
522  : bit1ToPass_(bit1ToPass),
523  bit2ToPass_(bit2ToPass),
524  cutCode_(cutCode),
525  cutCodeFunc_(cutCodeFunc),
526  minMass_(minMass),
527  maxMass_(maxMass) {}
528  ~EgTrigTagProbeCut_New() override = default;
529 
530  bool pass(const OffEle& ele, const OffEvt& evt) const override;
531  EgHLTDQMCut<OffEle>* clone() const override { return new EgTrigTagProbeCut_New(*this); }
532  };
533  //same for photons
534  struct EgTrigTagProbeCut_NewPho : public EgHLTDQMCut<OffPho> {
535  private:
538  int cutCode_;
539  int (OffPho::*cutCodeFunc_)() const;
540  float minMass_;
541  float maxMass_;
542 
543  public:
545  TrigCodes::TrigBitSet bit2ToPass,
546  int cutCode,
547  int (OffPho::*cutCodeFunc)() const,
548  float minMass = 81.,
549  float maxMass = 101.)
550  : bit1ToPass_(bit1ToPass),
551  bit2ToPass_(bit2ToPass),
552  cutCode_(cutCode),
553  cutCodeFunc_(cutCodeFunc),
554  minMass_(minMass),
555  maxMass_(maxMass) {}
556  ~EgTrigTagProbeCut_NewPho() override = default;
557 
558  bool pass(const OffPho& pho, const OffEvt& evt) const override;
559  EgHLTDQMCut<OffPho>* clone() const override { return new EgTrigTagProbeCut_NewPho(*this); }
560  };
561 
562 } // namespace egHLT
563 #endif
egHLT::EgJetTagProbeCut::maxDPhi_
float maxDPhi_
Definition: EgHLTDQMCut.h:328
egHLT::ChargeCut::charge_
int charge_
Definition: EgHLTDQMCut.h:253
egHLT::EgEvtTrigCut::~EgEvtTrigCut
~EgEvtTrigCut()=default
egHLT::EgGreaterCut::varFunc_
varType(T::* varFunc_)() const
Definition: EgHLTDQMCut.h:100
egHLT::EgDiPhoCut::pass
bool pass(const OffPho &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.cc:111
egHLT::EgTagProbeCut::minMass_
float minMass_
Definition: EgHLTDQMCut.h:272
egHLT::EgDiPhoCut
Definition: EgHLTDQMCut.h:434
egHLT::EgDiEleCut::EgDiEleCut
EgDiEleCut(int cutCode, int(OffEle::*cutCodeFunc)() const)
Definition: EgHLTDQMCut.h:396
mps_fire.i
i
Definition: mps_fire.py:355
egHLT::EgHLTDQMUserVarCut::pass
bool pass(const T &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:89
egHLT::EgJetB2BCut::pass
bool pass(const T &obj, const OffEvt &evt) const
Definition: EgHLTDQMCut.h:375
egHLT::ChargeCut::pass
bool pass(const T &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:259
egHLT::EgTrigTagProbeCut_New::~EgTrigTagProbeCut_New
~EgTrigTagProbeCut_New() override=default
egHLT::EgDiPhoCut::clone
EgHLTDQMCut< OffPho > * clone() const override
Definition: EgHLTDQMCut.h:442
egHLT::EgTrigTagProbeCut::bitsToPass_
TrigCodes::TrigBitSet bitsToPass_
Definition: EgHLTDQMCut.h:484
TkAlMuonSelectors_cfi.cut
cut
Definition: TkAlMuonSelectors_cfi.py:5
egHLT::EgDiPhoUserCut::key_
const Key & key_
Definition: EgHLTDQMCut.h:450
egHLT::ChargeCut::ChargeCut
ChargeCut(int charge)
Definition: EgHLTDQMCut.h:256
egHLT::EgTrigTagProbeCut_New::cutCode_
int cutCode_
Definition: EgHLTDQMCut.h:510
egHLT::EgHLTDQMVarCut::cutsToPass_
int cutsToPass_
Definition: EgHLTDQMCut.h:45
egHLT::EgTagProbeCut::probeCutCode_
int probeCutCode_
Definition: EgHLTDQMCut.h:268
egHLT::EgJetTagProbeCut::probeCutCode_
int probeCutCode_
Definition: EgHLTDQMCut.h:324
reco::deltaPhi
constexpr double deltaPhi(double phi1, double phi2)
Definition: deltaPhi.h:26
egHLT::EgTrigTagProbeCut
Definition: EgHLTDQMCut.h:482
HLT_2018_cff.maxDPhi
maxDPhi
Definition: HLT_2018_cff.py:7827
egHLT::EgHLTDQMCut::EgHLTDQMCut
EgHLTDQMCut()=default
egHLT::OffEvt::phos
const std::vector< OffPho > & phos() const
Definition: EgHLTOffEvt.h:50
egHLT::EgJetTagProbeCut::EgJetTagProbeCut
EgJetTagProbeCut(int probeCutCode, int(T::*probeCutCodeFunc)() const, float minDPhi=-M_PI, float maxDPhi=M_PI)
Definition: EgHLTDQMCut.h:331
egHLT::EgDiPhoCut::EgDiPhoCut
EgDiPhoCut(int cutCode, int(OffPho::*cutCodeFunc)() const)
Definition: EgHLTDQMCut.h:440
egHLT::EgJetB2BCut::EgJetB2BCut
EgJetB2BCut(float minDPhi=-M_PI, float maxDPhi=M_PI, float ptRelDiff=999)
Definition: EgHLTDQMCut.h:368
egHLT::EgObjTrigCut::AND
Definition: EgHLTDQMCut.h:174
egHLT::EgTrigTagProbeCut_NewPho::bit1ToPass_
TrigCodes::TrigBitSet bit1ToPass_
Definition: EgHLTDQMCut.h:536
egHLT::EgTrigTagProbeCut::cutCode_
int cutCode_
Definition: EgHLTDQMCut.h:485
egHLT::EgTagProbeCut::clone
EgHLTDQMCut< T > * clone() const override
Definition: EgHLTDQMCut.h:291
egHLT::OffEvt
Definition: EgHLTOffEvt.h:29
egHLT::EgNotCut::~EgNotCut
~EgNotCut()
Definition: EgHLTDQMCut.h:243
egHLT::EgMultiCut
Definition: EgHLTDQMCut.h:116
egHLT::EgMultiCut::EgMultiCut
EgMultiCut()=default
singleTopDQM_cfi.jets
jets
Definition: singleTopDQM_cfi.py:42
egHLT::EgHLTDQMVarCut::EgHLTDQMVarCut
EgHLTDQMVarCut(int cutsToPass, int(T::*cutCodeFunc)() const)
Definition: EgHLTDQMCut.h:49
egHLT::EgGreaterCut::clone
EgHLTDQMCut< T > * clone() const override
Definition: EgHLTDQMCut.h:106
egHLT::EgHLTDQMUserVarCut::clone
EgHLTDQMCut< T > * clone() const override
Definition: EgHLTDQMCut.h:85
egHLT::EgMultiCut::operator<<
EgMultiCut< T > & operator<<(const EgHLTDQMCut< T > *inputCut)
Definition: EgHLTDQMCut.h:145
egHLT::EgObjTrigCut::OR
Definition: EgHLTDQMCut.h:174
egHLT::OffEle
Definition: EgHLTOffEle.h:29
egHLT::EgTagProbeCut::probeCutCodeFunc_
int(T::* probeCutCodeFunc_)() const
Definition: EgHLTDQMCut.h:269
egHLT::EgTrigTagProbeCut::EgTrigTagProbeCut
EgTrigTagProbeCut(TrigCodes::TrigBitSet bitsToPass, int cutCode, int(OffEle::*cutCodeFunc)() const, float minMass=81., float maxMass=101.)
Definition: EgHLTDQMCut.h:491
egHLT::EgHLTDQMVarCut::pass
bool pass(const T &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:64
egHLT::ChargeCut::clone
EgHLTDQMCut< T > * clone() const override
Definition: EgHLTDQMCut.h:260
egHLT::EgDiEleCut::cutCodeFunc_
int(OffEle::* cutCodeFunc_)() const
Definition: EgHLTDQMCut.h:393
deltaR.h
egHLT::EgEvtTrigCut::CutLogic
CutLogic
Definition: EgHLTDQMCut.h:212
egHLT::OffEvt::jets
const std::vector< reco::CaloJet > & jets() const
Definition: EgHLTOffEvt.h:53
egHLT::EgEvtTrigCut::EgEvtTrigCut
EgEvtTrigCut(TrigCodes::TrigBitSet bitsToPass, CutLogic passLogic=OR)
Definition: EgHLTDQMCut.h:220
egHLT::EgObjTrigCut::failLogic_
CutLogic failLogic_
Definition: EgHLTDQMCut.h:181
egHLT::EgObjTrigCut::clone
EgHLTDQMCut< T > * clone() const override
Definition: EgHLTDQMCut.h:192
egHLT::EgNotCut::pass
bool pass(const T &obj, const OffEvt &evt) const
Definition: EgHLTDQMCut.h:245
egHLT::EgTrigTagProbeCut_New::bit2ToPass_
TrigCodes::TrigBitSet bit2ToPass_
Definition: EgHLTDQMCut.h:509
Key
Definition: GoldenPattern.h:15
egHLT::EgDiPhoUserCut::~EgDiPhoUserCut
~EgDiPhoUserCut() override=default
egHLT::OffEvt::evtTrigBits
TrigCodes::TrigBitSet evtTrigBits() const
Definition: EgHLTOffEvt.h:52
egHLT::EgHLTDQMUserVarCut::~EgHLTDQMUserVarCut
~EgHLTDQMUserVarCut() override=default
egHLT::EgDiPhoCut::cutCodeFunc_
int(OffPho::* cutCodeFunc_)() const
Definition: EgHLTDQMCut.h:437
egHLT::EgDiEleUserCut::key_
const Key & key_
Definition: EgHLTDQMCut.h:406
egHLT::EgTrigTagProbeCut_New::maxMass_
float maxMass_
Definition: EgHLTDQMCut.h:513
egHLT::OffPho
Definition: EgHLTOffPho.h:26
egHLT::EgTrigTagProbeCut_New
Definition: EgHLTDQMCut.h:506
egHLT::EgHLTDQMCut
Definition: EgHLTDQMCut.h:26
egHLT::TrigCodes::TrigBitSet
std::bitset< maxNrBits_ > TrigBitSet
Definition: EgHLTTrigCodes.h:23
egHLT::EgTrigTagProbeCut_New::cutCodeFunc_
int(OffEle::* cutCodeFunc_)() const
Definition: EgHLTDQMCut.h:511
egHLT::EgDiPhoUserCut::cutCodeFunc_
int(OffPho::* cutCodeFunc_)(const Key &) const
Definition: EgHLTDQMCut.h:449
egHLT::EgJetB2BCut::ptRelDiff_
float ptRelDiff_
Definition: EgHLTDQMCut.h:365
HLT_2018_cff.dPhi
dPhi
Definition: HLT_2018_cff.py:12290
egHLT::EgDiEleUserCut::pass
bool pass(const OffEle &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:421
egHLT::EgDiPhoUserCut::EgDiPhoUserCut
EgDiPhoUserCut(int(OffPho::*cutCodeFunc)(const Key &) const, const Key &key, int cutsNotToMask=~0x0)
Definition: EgHLTDQMCut.h:454
egHLT::ChargeCut::~ChargeCut
~ChargeCut() override=default
egHLT::EgObjTrigCut::pass
bool pass(const T &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:196
egHLT::EgDiEleUserCut::clone
EgHLTDQMCut< OffEle > * clone() const override
Definition: EgHLTDQMCut.h:415
egHLT::EgDiPhoUserCut::clone
EgHLTDQMCut< OffPho > * clone() const override
Definition: EgHLTDQMCut.h:459
egHLT::EgTrigTagProbeCut_New::pass
bool pass(const OffEle &ele, const OffEvt &evt) const override
Definition: EgHLTDQMCut.cc:34
egHLT::EgHLTDQMUserVarCut::cutsNotToMask_
int cutsNotToMask_
Definition: EgHLTDQMCut.h:77
dumpRecoGeometry_cfg.varType
varType
Definition: dumpRecoGeometry_cfg.py:8
egHLT::EgJetTagProbeCut::clone
EgHLTDQMCut< T > * clone() const override
Definition: EgHLTDQMCut.h:334
egHLT::EgHLTDQMVarCut::cutCodeFunc_
int(T::* cutCodeFunc_)() const
Definition: EgHLTDQMCut.h:46
getGTfromDQMFile.obj
obj
Definition: getGTfromDQMFile.py:32
egHLT::EgDiEleUserCut::cutCodeFunc_
int(OffEle::* cutCodeFunc_)(const Key &) const
Definition: EgHLTDQMCut.h:405
egHLT::EgTagProbeCut::maxMass_
float maxMass_
Definition: EgHLTDQMCut.h:273
egHLT::EgTrigTagProbeCut::cutCodeFunc_
int(OffEle::* cutCodeFunc_)() const
Definition: EgHLTDQMCut.h:486
egHLT::EgNotCut::cut_
EgHLTDQMCut< T > * cut_
Definition: EgHLTDQMCut.h:238
egHLT::EgHLTDQMUserVarCut::key_
const Key key_
Definition: EgHLTDQMCut.h:76
egHLT::EgJetTagProbeCut::pass
bool pass(const T &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:338
ALCARECOTkAlJpsiMuMu_cff.charge
charge
Definition: ALCARECOTkAlJpsiMuMu_cff.py:47
egHLT::EgHLTDQMUserVarCut::EgHLTDQMUserVarCut
EgHLTDQMUserVarCut(int(T::*cutCodeFunc)(const Key &) const, const Key &key, int cutsNotToMask=~0x0)
Definition: EgHLTDQMCut.h:80
egHLT::EgHLTDQMVarCut::clone
EgHLTDQMCut< T > * clone() const override
Definition: EgHLTDQMCut.h:54
egHLT::EgDiEleCut
Definition: EgHLTDQMCut.h:390
egHLT::EgHLTDQMVarCut
Definition: EgHLTDQMCut.h:43
egHLT::EgJetB2BCut
Definition: EgHLTDQMCut.h:361
egHLT::EgMultiCut::~EgMultiCut
~EgMultiCut() override
Definition: EgHLTDQMCut.h:123
edm::LogError
Definition: MessageLogger.h:183
egHLT::ChargeCut
Definition: EgHLTDQMCut.h:251
egHLT::EgTrigTagProbeCut_NewPho::bit2ToPass_
TrigCodes::TrigBitSet bit2ToPass_
Definition: EgHLTDQMCut.h:537
egHLT::EgJetTagProbeCut::minDPhi_
float minDPhi_
Definition: EgHLTDQMCut.h:327
egHLT::EgMultiCut::clone
EgHLTDQMCut< T > * clone() const override
Definition: EgHLTDQMCut.h:134
egHLT::EgTrigTagProbeCut_NewPho
Definition: EgHLTDQMCut.h:534
egHLT::EgTrigTagProbeCut_New::EgTrigTagProbeCut_New
EgTrigTagProbeCut_New(TrigCodes::TrigBitSet bit1ToPass, TrigCodes::TrigBitSet bit2ToPass, int cutCode, int(OffEle::*cutCodeFunc)() const, float minMass=81., float maxMass=101.)
Definition: EgHLTDQMCut.h:516
B2GTnPMonitor_cfi.maxMass
maxMass
Definition: B2GTnPMonitor_cfi.py:55
egHLT::EgEvtTrigCut::bitsToPass_
TrigCodes::TrigBitSet bitsToPass_
Definition: EgHLTDQMCut.h:216
egHLT::EgDiPhoUserCut
Definition: EgHLTDQMCut.h:447
egHLT::EgNotCut::EgNotCut
EgNotCut(EgHLTDQMCut< T > *cut)
Definition: EgHLTDQMCut.h:241
egHLT::EgObjTrigCut
Definition: EgHLTDQMCut.h:172
reco::deltaR2
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:16
egHLT::EgNotCut::clone
EgHLTDQMCut< T > * clone() const
Definition: EgHLTDQMCut.h:246
egHLT::EgTrigTagProbeCut_NewPho::~EgTrigTagProbeCut_NewPho
~EgTrigTagProbeCut_NewPho() override=default
egHLT::EgTrigTagProbeCut_NewPho::EgTrigTagProbeCut_NewPho
EgTrigTagProbeCut_NewPho(TrigCodes::TrigBitSet bit1ToPass, TrigCodes::TrigBitSet bit2ToPass, int cutCode, int(OffPho::*cutCodeFunc)() const, float minMass=81., float maxMass=101.)
Definition: EgHLTDQMCut.h:544
egHLT::EgGreaterCut
Definition: EgHLTDQMCut.h:97
egHLT::EgObjTrigCut::EgObjTrigCut
EgObjTrigCut(TrigCodes::TrigBitSet bitsToPass, CutLogic passLogic=OR, TrigCodes::TrigBitSet bitsToFail=TrigCodes::TrigBitSet(), CutLogic failLogic=AND)
Definition: EgHLTDQMCut.h:184
createfilelist.int
int
Definition: createfilelist.py:10
egHLT::EgJetTagProbeCut::probeCutCodeFunc_
int(OffEle::* probeCutCodeFunc_)() const
Definition: EgHLTDQMCut.h:325
egHLT::EgTagProbeCut::EgTagProbeCut
EgTagProbeCut(int probeCutCode, int(T::*probeCutCodeFunc)() const, int tagCutCode, int(OffEle::*tagCutCodeFunc)() const, float minMass=81., float maxMass=101.)
Definition: EgHLTDQMCut.h:276
M_PI
#define M_PI
Definition: BXVectorInputProducer.cc:50
reco::tau::qcuts::AND
bool AND(const TrackBaseRef &track, const RecoTauQualityCuts::TrackQCutFuncCollection &cuts)
Definition: RecoTauQualityCuts.cc:268
egHLT::EgHLTDQMUserVarCut
Definition: EgHLTDQMCut.h:73
egHLT::EgDiEleUserCut::~EgDiEleUserCut
~EgDiEleUserCut() override=default
egHLT::EgEvtTrigCut::pass
bool pass(const T &obj, const OffEvt &evt) const
Definition: EgHLTDQMCut.h:229
EgHLTOfflineSource_cfi.tagEle
tagEle
Definition: EgHLTOfflineSource_cfi.py:75
egHLT::EgTagProbeCut::tagCutCodeFunc_
int(OffEle::* tagCutCodeFunc_)() const
Definition: EgHLTDQMCut.h:271
egHLT::EgTagProbeCut
Definition: EgHLTDQMCut.h:266
egHLT::EgJetB2BCut::clone
EgHLTDQMCut< T > * clone() const
Definition: EgHLTDQMCut.h:371
egHLT::EgDiEleUserCut::cutsNotToMask_
int cutsNotToMask_
Definition: EgHLTDQMCut.h:407
egHLT::EgTrigTagProbeCut_NewPho::cutCode_
int cutCode_
Definition: EgHLTDQMCut.h:538
egHLT::EgEvtTrigCut
Definition: EgHLTDQMCut.h:210
egHLT::EgJetB2BCut::minDPhi_
float minDPhi_
Definition: EgHLTDQMCut.h:363
egHLT::EgHLTDQMCut::pass
virtual bool pass(const T &obj, const OffEvt &evt) const =0
egHLT::EgGreaterCut::EgGreaterCut
EgGreaterCut(varType cutValue, varType(T::*varFunc)() const)
Definition: EgHLTDQMCut.h:103
egHLT::EgEvtTrigCut::clone
EgHLTDQMCut< T > * clone() const
Definition: EgHLTDQMCut.h:225
mag
T mag() const
The vector magnitude. Equivalent to sqrt(vec.mag2())
Definition: Basic3DVectorLD.h:127
egHLT::EgObjTrigCut::passLogic_
CutLogic passLogic_
Definition: EgHLTDQMCut.h:179
egHLT::EgHLTDQMCut::operator=
EgHLTDQMCut & operator=(const EgHLTDQMCut &rhs)
Definition: EgHLTDQMCut.h:29
egHLT::EgObjTrigCut::bitsToPass_
TrigCodes::TrigBitSet bitsToPass_
Definition: EgHLTDQMCut.h:178
egHLT::EgTrigTagProbeCut_NewPho::minMass_
float minMass_
Definition: EgHLTDQMCut.h:540
egHLT::EgObjTrigCut::bitsToFail_
TrigCodes::TrigBitSet bitsToFail_
Definition: EgHLTDQMCut.h:180
egHLT::EgTrigTagProbeCut_NewPho::cutCodeFunc_
int(OffPho::* cutCodeFunc_)() const
Definition: EgHLTDQMCut.h:539
egHLT::EgObjTrigCut::CutLogic
CutLogic
Definition: EgHLTDQMCut.h:174
T
long double T
Definition: Basic3DVectorLD.h:48
metsig::jet
Definition: SignAlgoResolutions.h:47
egHLT::EgTagProbeCut::tagCutCode_
int tagCutCode_
Definition: EgHLTDQMCut.h:270
egHLT::EgDiEleUserCut::EgDiEleUserCut
EgDiEleUserCut(int(OffEle::*cutCodeFunc)(const Key &) const, const Key &key, int cutsNotToMask=~0x0)
Definition: EgHLTDQMCut.h:410
egHLT::EgTrigTagProbeCut_NewPho::maxMass_
float maxMass_
Definition: EgHLTDQMCut.h:541
egHLT::EgJetB2BCut::maxDPhi_
float maxDPhi_
Definition: EgHLTDQMCut.h:364
EgHLTOffHistBins_cfi.mass
mass
Definition: EgHLTOffHistBins_cfi.py:34
egHLT::EgTrigTagProbeCut_New::clone
EgHLTDQMCut< OffEle > * clone() const override
Definition: EgHLTDQMCut.h:531
egHLT::EgEvtTrigCut::OR
Definition: EgHLTDQMCut.h:212
egHLT::EgTrigTagProbeCut::~EgTrigTagProbeCut
~EgTrigTagProbeCut() override=default
B2GTnPMonitor_cfi.minMass
minMass
Definition: B2GTnPMonitor_cfi.py:54
egHLT::EgDiEleUserCut
Definition: EgHLTDQMCut.h:403
egHLT::EgNotCut
Definition: EgHLTDQMCut.h:236
egHLT::EgDiPhoCut::cutCode_
int cutCode_
Definition: EgHLTDQMCut.h:436
egHLT::EgTrigTagProbeCut::maxMass_
float maxMass_
Definition: EgHLTDQMCut.h:488
egHLT::EgDiEleCut::pass
bool pass(const OffEle &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.cc:98
egHLT::EgTagProbeCut::~EgTagProbeCut
~EgTagProbeCut() override=default
egHLT::EgGreaterCut::pass
bool pass(const T &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:105
EgHLTTrigCodes.h
egHLT::EgTrigTagProbeCut_New::minMass_
float minMass_
Definition: EgHLTDQMCut.h:512
egHLT::EgTagProbeCut::pass
bool pass(const T &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:295
egHLT::EgJetTagProbeCut
Definition: EgHLTDQMCut.h:322
egHLT::EgDiPhoUserCut::pass
bool pass(const OffPho &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:465
egHLT::EgEvtTrigCut::AND
Definition: EgHLTDQMCut.h:212
egHLT::EgDiPhoUserCut::cutsNotToMask_
int cutsNotToMask_
Definition: EgHLTDQMCut.h:451
EgHLTOffEvt.h
egHLT::OffEvt::eles
const std::vector< OffEle > & eles() const
Definition: EgHLTOffEvt.h:48
egHLT::EgTrigTagProbeCut::pass
bool pass(const OffEle &ele, const OffEvt &evt) const override
Definition: EgHLTDQMCut.cc:5
egHLT
Definition: EgHLTBinData.h:10
crabWrapper.key
key
Definition: crabWrapper.py:19
egHLT::EgHLTDQMCut::~EgHLTDQMCut
virtual ~EgHLTDQMCut()=default
egHLT::EgMultiCut::pass
bool pass(const T &obj, const OffEvt &evt) const override
Definition: EgHLTDQMCut.h:157
egHLT::EgHLTDQMUserVarCut::cutCodeFunc_
int(T::* cutCodeFunc_)(const Key &) const
Definition: EgHLTDQMCut.h:75
egHLT::EgEvtTrigCut::passLogic_
CutLogic passLogic_
Definition: EgHLTDQMCut.h:217
egHLT::EgHLTDQMCut::clone
virtual EgHLTDQMCut< T > * clone() const =0
egHLT::EgObjTrigCut::~EgObjTrigCut
~EgObjTrigCut() override=default
egHLT::EgHLTDQMVarCut::~EgHLTDQMVarCut
~EgHLTDQMVarCut() override=default
egHLT::EgGreaterCut::cutValue_
varType cutValue_
Definition: EgHLTDQMCut.h:99
egHLT::EgTrigTagProbeCut::clone
EgHLTDQMCut< OffEle > * clone() const override
Definition: EgHLTDQMCut.h:500
egHLT::EgDiEleCut::clone
EgHLTDQMCut< OffEle > * clone() const override
Definition: EgHLTDQMCut.h:398
egHLT::EgTrigTagProbeCut_NewPho::clone
EgHLTDQMCut< OffPho > * clone() const override
Definition: EgHLTDQMCut.h:559
egHLT::EgDiEleCut::cutCode_
int cutCode_
Definition: EgHLTDQMCut.h:392
egHLT::EgTrigTagProbeCut_New::bit1ToPass_
TrigCodes::TrigBitSet bit1ToPass_
Definition: EgHLTDQMCut.h:508
egHLT::EgNotCut::EgNotCut
EgNotCut(const EgNotCut< T > &rhs)
Definition: EgHLTDQMCut.h:242
egHLT::EgMultiCut::cuts_
std::vector< const EgHLTDQMCut< T > * > cuts_
Definition: EgHLTDQMCut.h:118
egHLT::EgTrigTagProbeCut_NewPho::pass
bool pass(const OffPho &pho, const OffEvt &evt) const override
Definition: EgHLTDQMCut.cc:66
egHLT::EgTrigTagProbeCut::minMass_
float minMass_
Definition: EgHLTDQMCut.h:487