CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
EgHLTOffEgSel.h
Go to the documentation of this file.
1 #ifndef DQMOFFLINE_TRIGGER_EGHLTOFFEGSEL
2 #define DQMOFFLINE_TRIGGER_EGHLTOFFEGSEL
3 
4 //this class works out which cuts the electron/photon passes/fails
5 //why am I rolling my own, simply put there is no electron/photon cut class that I know off
6 //which will allow isolation and id variables to be cut on at the same time and return
7 //a int with the bits corresponding to cut pass/fail
8 //also I'm going to need to modify this to keep up with trigger cuts
11 
13 
14 #include <iostream>
15 
16 namespace edm {
17  class ParameterSet;
18 }
19 
20 namespace egHLT {
21  class OffEle;
22  class OffPho;
23 
24  class OffEgSel {
25  private:
28 
29  public:
30  OffEgSel() = default; //default, it doesnt to anything
31  explicit OffEgSel(const edm::ParameterSet& config) { setup(config); }
32  ~OffEgSel() = default; //we own nothing so default destructor, copy and assignment okay
33 
34  bool passCuts(const OffEle& ele, int cutMask = ~0x0) const { return getCutCode(ele, cutMask) == 0x0; }
35  int getCutCode(const OffEle& ele, int cutMask = ~0x0) const;
36  static int getCutCode(const OffEle& ele, const EgCutValues& cuts, int cutMask = ~0x0);
37 
38  bool passCuts(const OffPho& pho, int cutMask = ~0x0) const { return getCutCode(pho, cutMask) == 0x0; }
39  int getCutCode(const OffPho& pho, int cutMask = ~0x0) const;
40  static int getCutCode(const OffPho& pho, const EgCutValues& cuts, int cutMask = ~0x0);
41 
44 
45  const EgCutValues& ebCuts() const { return ebCutValues_; }
46  const EgCutValues& eeCuts() const { return eeCutValues_; }
47 
48  void setup(const edm::ParameterSet&);
49  };
50 } // namespace egHLT
51 
52 #endif
bool passCuts(const OffEle &ele, int cutMask=~0x0) const
Definition: EgHLTOffEgSel.h:34
const EgCutValues & ebCuts() const
Definition: EgHLTOffEgSel.h:45
const EgCutValues & eeCuts() const
Definition: EgHLTOffEgSel.h:46
bool passCuts(const OffPho &pho, int cutMask=~0x0) const
Definition: EgHLTOffEgSel.h:38
int getCutCode(const OffEle &ele, int cutMask=~0x0) const
EgCutValues eeCutValues_
Definition: EgHLTOffEgSel.h:27
~OffEgSel()=default
void setEECuts(const EgCutValues &cuts)
Definition: EgHLTOffEgSel.h:43
TkSoA const *__restrict__ CAHitNtupletGeneratorKernelsGPU::QualityCuts cuts
void setup(const edm::ParameterSet &)
void setEBCuts(const EgCutValues &cuts)
Definition: EgHLTOffEgSel.h:42
OffEgSel(const edm::ParameterSet &config)
Definition: EgHLTOffEgSel.h:31
tuple config
parse the configuration file
OffEgSel()=default
EgCutValues ebCutValues_
Definition: EgHLTOffEgSel.h:26