17 |
|
#include "MitAna/DataTree/interface/BeamSpotCol.h" |
18 |
|
#include "MitAna/DataTree/interface/TriggerObjectCol.h" |
19 |
|
#include "MitCommon/MathTools/interface/MathUtils.h" |
20 |
+ |
#include "MitPhysics/ElectronLikelihood/interface/ElectronLikelihood.h" |
21 |
+ |
#include <utility> |
22 |
|
|
23 |
|
namespace mithep { |
24 |
|
class ElectronTools { |
34 |
|
kZeeId, //"ZeeId" |
35 |
|
kCustomIdLoose, //"CustomLoose" |
36 |
|
kCustomIdTight, //"CustomTight" |
37 |
+ |
kVBTFWorkingPointFakeableId, |
38 |
|
kVBTFWorkingPoint95Id, |
39 |
|
kVBTFWorkingPoint90Id, |
40 |
|
kVBTFWorkingPoint85Id, |
41 |
|
kVBTFWorkingPoint80Id, |
42 |
< |
kVBTFWorkingPoint80LowPtId, |
43 |
< |
kVBTFWorkingPoint70Id |
42 |
> |
kVBTFWorkingPointLowPtId, |
43 |
> |
kVBTFWorkingPoint70Id, |
44 |
> |
kMVAID_BDTG_NoIPInfo, |
45 |
> |
kMVAID_BDTG_WithIPInfo, |
46 |
> |
kMVAID_BDTG_IDIsoCombined, |
47 |
> |
kHggLeptonTagId, |
48 |
> |
kHggLeptonTagId2012, |
49 |
> |
kHggLeptonTagId2012HCP, |
50 |
> |
kMVAID_BDTG_IDHWW2012TrigV0, |
51 |
> |
kMVAID_BDTG_IDIsoCombinedHWW2012TrigV4 |
52 |
|
}; |
53 |
|
|
54 |
|
enum EElIsoType { |
58 |
|
kTrackJuraCombined, //"TrackJuraCombined" |
59 |
|
kTrackJuraSliding, //"TrackJuraSliding" |
60 |
|
kTrackJuraSlidingNoCorrection, //"TrackJuraSlidingNoCorrection" |
61 |
+ |
kCombinedRelativeConeAreaCorrected, //"CombinedRelativeConeAreaCorrected" |
62 |
|
kNoIso, //"NoIso" |
63 |
|
kPFIso, //"PFIso" |
64 |
|
kPFIsoNoL, //"PFIsoNoL" |
68 |
|
kVBTFWorkingPoint90Iso, |
69 |
|
kVBTFWorkingPoint85Iso, |
70 |
|
kVBTFWorkingPoint80Iso, |
71 |
< |
kVBTFWorkingPoint70Iso |
71 |
> |
kVBTFWorkingPoint70Iso, |
72 |
> |
kMVAIso_BDTG_IDIsoCombined, |
73 |
> |
kPFIso_HWW2012TrigV0, |
74 |
> |
kPFIso_HggLeptonTag2012, |
75 |
> |
kPFIso_HggLeptonTag2012HCP, |
76 |
> |
kMVAIso_BDTG_IDIsoCombinedHWW2012TrigV4 |
77 |
> |
}; |
78 |
> |
|
79 |
> |
enum EElectronEffectiveAreaType { |
80 |
> |
kEleChargedIso03, |
81 |
> |
kEleNeutralHadronIso03, |
82 |
> |
kEleGammaAndNeutralHadronIso03, |
83 |
> |
kEleGammaIso03, |
84 |
> |
kEleGammaIsoVetoEtaStrip03, |
85 |
> |
kEleChargedIso04, |
86 |
> |
kEleNeutralHadronIso04, |
87 |
> |
kEleGammaAndNeutralHadronIso04, |
88 |
> |
kEleGammaIso04, |
89 |
> |
kEleGammaIsoVetoEtaStrip04, |
90 |
> |
kEleNeutralHadronIso007, |
91 |
> |
kEleNeutralIso04, |
92 |
> |
kEleHoverE, |
93 |
> |
kEleHcalDepth1OverEcal, |
94 |
> |
kEleHcalDepth2OverEcal, |
95 |
> |
kEleGammaIsoDR0p0To0p1, |
96 |
> |
kEleGammaIsoDR0p1To0p2, |
97 |
> |
kEleGammaIsoDR0p2To0p3, |
98 |
> |
kEleGammaIsoDR0p3To0p4, |
99 |
> |
kEleGammaIsoDR0p4To0p5, |
100 |
> |
kEleNeutralHadronIsoDR0p0To0p1, |
101 |
> |
kEleNeutralHadronIsoDR0p1To0p2, |
102 |
> |
kEleNeutralHadronIsoDR0p2To0p3, |
103 |
> |
kEleNeutralHadronIsoDR0p3To0p4, |
104 |
> |
kEleNeutralHadronIsoDR0p4To0p5 |
105 |
> |
}; |
106 |
> |
|
107 |
> |
enum EElectronEffectiveAreaTarget { |
108 |
> |
kEleEANoCorr, |
109 |
> |
kEleEAData2011, |
110 |
> |
kEleEAData2012, |
111 |
> |
kEleEASummer11MC, |
112 |
> |
kEleEAFall11MC |
113 |
|
}; |
114 |
|
|
115 |
|
static Bool_t PassChargeFilter(const Electron *el); |
116 |
|
static Bool_t PassConversionFilter(const Electron *el, const DecayParticleCol *conversions, |
117 |
< |
const BaseVertex *vtx, UInt_t nWrongHitsMax=1, Double_t probMin=1e-6, |
118 |
< |
Double_t lxyMin = 2.0, Bool_t matchCkf = kFALSE, Bool_t requireArbitratedMerged = kTRUE); |
117 |
> |
const BaseVertex *vtx, UInt_t nWrongHitsMax=0, Double_t probMin=1e-6, |
118 |
> |
Double_t lxyMin = 2.0, Bool_t matchCkf = kTRUE, Bool_t requireArbitratedMerged = kFALSE, Double_t trkptMin = -99.); |
119 |
|
static Bool_t PassCustomID(const Electron *el, EElIdType idType); |
120 |
|
static Bool_t PassCustomIso(const Electron *el, EElIsoType isoType, |
121 |
|
Bool_t useCombineIso = kTRUE); |
122 |
< |
static Bool_t PassD0Cut(const Electron *el, const VertexCol *vertices, Double_t fD0Cut); |
122 |
> |
static Bool_t PassD0Cut(const Electron *el, const VertexCol *vertices, Double_t fD0Cut, Int_t nVertex = 0); |
123 |
|
static Bool_t PassD0Cut(const Electron *el, const BeamSpotCol *beamspots, Double_t fD0Cut); |
124 |
+ |
static Bool_t PassDZCut(const Electron *el, const VertexCol *vertices, Double_t fDZCut, Int_t nVertex = 0); |
125 |
|
static Bool_t PassSpikeRemovalFilter(const Electron *ele); |
126 |
|
static Bool_t PassTriggerMatching(const Electron *ele, const TriggerObjectCol *trigobjs); |
127 |
|
static Int_t Classify(const Electron *ele); |
129 |
|
const DecayParticleCol *conversions, const Int_t typeCuts, |
130 |
|
Double_t beta = 1.0); |
131 |
|
static bool compute_cut(double x, double et, double cut_min, double cut_max, bool gtn=false); |
132 |
+ |
static Double_t Likelihood(ElectronLikelihood *LH, const Electron *ele); |
133 |
+ |
static Double_t ElectronEffectiveArea(EElectronEffectiveAreaType type, Double_t Eta, |
134 |
+ |
EElectronEffectiveAreaTarget EffectiveAreaTarget = kEleEAData2011); |
135 |
+ |
static std::pair<Double_t,Double_t> ComputeEPCombination( const Electron * ele, const float regression_energy, |
136 |
+ |
const float regression_energy_error); |
137 |
|
|
138 |
+ |
static Bool_t PassHggLeptonTagID(const Electron *el); |
139 |
+ |
static Bool_t PassHggLeptonTagID2012(const Electron *el); |
140 |
+ |
|
141 |
|
ClassDef(ElectronTools, 0) // Muon tools |
142 |
|
}; |
143 |
|
} |