forked from CMUCMS/CommonCode
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathObjectSelector.h
More file actions
114 lines (103 loc) · 2.22 KB
/
ObjectSelector.h
File metadata and controls
114 lines (103 loc) · 2.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
#ifndef ObjectSelectors_h
#define ObjectSelectors_h
#include <bitset>
#include "ObjectVars.h"
namespace susy {
enum PhotonId {
PhLoose12,
PhMedium12,
PhTight12,
PhLoose12Pix,
PhMedium12Pix,
PhTight12Pix,
PhLoose12LV,
PhMedium12LV,
PhTight12LV,
nPhotonId
};
enum ElectronId {
ElVeto12,
ElLoose12,
ElMedium12,
ElTight12,
nElectronId
};
enum MuonId {
MuLoose12,
MuSoft12,
MuTight12,
nMuonId
};
enum JetId {
JtLoose,
nJetId
};
enum PhotonCriteria {
PhFiducial,
PhElectronVeto,
PhHOverE,
PhSigmaIetaIeta,
PhChargedHadronIso,
PhNeutralHadronIso,
PhPhotonIso,
nPhotonCriteria
};
enum ElectronCriteria {
ElFiducial,
ElCombIso,
ElDeltaEta,
ElDeltaPhi,
ElSigmaIetaIeta,
ElHOverE,
ElD0,
ElDZ,
ElEPDiff,
ElMissingHits,
ElConvVeto,
nElectronCriteria
};
enum MuonCriteria {
MuFiducial,
MuGlobalOrTrackerMuon,
MuGlobalMuon,
MuPFMuon,
MuMatchedStations,
MuLayersWithMmt,
MuNormChi2,
MuValidMuonHits,
MuDxy,
MuDz,
MuValidPixelHits,
MuCombIso,
MudpTpT,
nMuonCriteria
};
enum JetCriteria {
JtFiducial,
JtCHFraction,
JtNHFraction,
JtCEFraction,
JtNEFraction,
JtNConstituents,
JtChargedMultiplicity,
nJetCriteria
};
class ObjectSelector {
public:
ObjectSelector();
~ObjectSelector();
static ObjectSelector const* getSelector() { return singleton_; }
static bool isGoodPhoton(PhotonVars const&, PhotonId, std::bitset<nPhotonCriteria>* = 0);
static bool isGoodElectron(ElectronVars const&, ElectronId, std::bitset<nElectronCriteria>* = 0);
static bool isGoodMuon(MuonVars const&, MuonId, std::bitset<nMuonCriteria>* = 0);
static bool isGoodJet(JetVars const&, JetId, std::bitset<nJetCriteria>* = 0);
static bool isGoodVertex(VertexVars const&);
static std::bitset<nPhotonCriteria> phReferences[nPhotonId];
static std::bitset<nElectronCriteria> elReferences[nElectronId];
static std::bitset<nMuonCriteria> muReferences[nMuonId];
static std::bitset<nJetCriteria> jtReferences[nJetId];
private:
static ObjectSelector const* singleton_;
};
}
#endif