1 |
//--------------------------------------------------------------------------------------------------
|
2 |
// $Id $
|
3 |
//
|
4 |
// ElectronTools
|
5 |
//
|
6 |
// Helper Class for electron Identification decisions.
|
7 |
//
|
8 |
// Authors: S.Xie
|
9 |
//--------------------------------------------------------------------------------------------------
|
10 |
|
11 |
#ifndef MITPHYSICS_UTILS_ELECTRONTOOLS_H
|
12 |
#define MITPHYSICS_UTILS_ELECTRONTOOLS_H
|
13 |
|
14 |
#include "MitAna/DataTree/interface/Electron.h"
|
15 |
#include "MitAna/DataTree/interface/DecayParticleCol.h"
|
16 |
#include "MitAna/DataTree/interface/VertexCol.h"
|
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 |
|
22 |
namespace mithep {
|
23 |
class ElectronTools {
|
24 |
public:
|
25 |
ElectronTools();
|
26 |
|
27 |
enum EElIdType {
|
28 |
kIdUndef = 0, //not defined
|
29 |
kTight, //"Tight"
|
30 |
kLoose, //"Loose"
|
31 |
kLikelihood, //"Likelihood"
|
32 |
kNoId, //"NoId"
|
33 |
kZeeId, //"ZeeId"
|
34 |
kCustomIdLoose, //"CustomLoose"
|
35 |
kCustomIdTight, //"CustomTight"
|
36 |
kVBTFWorkingPointFakeableId,
|
37 |
kVBTFWorkingPoint95Id,
|
38 |
kVBTFWorkingPoint90Id,
|
39 |
kVBTFWorkingPoint85Id,
|
40 |
kVBTFWorkingPoint80Id,
|
41 |
kVBTFWorkingPointLowPtId,
|
42 |
kVBTFWorkingPoint70Id,
|
43 |
kMVA_BDTG_V3
|
44 |
};
|
45 |
|
46 |
enum EElIsoType {
|
47 |
kIsoUndef = 0, //"not defined"
|
48 |
kTrackCalo, //"TrackCalo"
|
49 |
kTrackJura, //"TrackJura"
|
50 |
kTrackJuraCombined, //"TrackJuraCombined"
|
51 |
kTrackJuraSliding, //"TrackJuraSliding"
|
52 |
kTrackJuraSlidingNoCorrection, //"TrackJuraSlidingNoCorrection"
|
53 |
kCombinedRelativeConeAreaCorrected, //"CombinedRelativeConeAreaCorrected"
|
54 |
kNoIso, //"NoIso"
|
55 |
kPFIso, //"PFIso"
|
56 |
kPFIsoNoL, //"PFIsoNoL"
|
57 |
kZeeIso, //"ZeeIso"
|
58 |
kCustomIso, //"Custom"
|
59 |
kVBTFWorkingPoint95Iso,
|
60 |
kVBTFWorkingPoint90Iso,
|
61 |
kVBTFWorkingPoint85Iso,
|
62 |
kVBTFWorkingPoint80Iso,
|
63 |
kVBTFWorkingPoint70Iso
|
64 |
};
|
65 |
|
66 |
static Bool_t PassChargeFilter(const Electron *el);
|
67 |
static Bool_t PassConversionFilter(const Electron *el, const DecayParticleCol *conversions,
|
68 |
const BaseVertex *vtx, UInt_t nWrongHitsMax=0, Double_t probMin=1e-6,
|
69 |
Double_t lxyMin = 2.0, Bool_t matchCkf = kTRUE, Bool_t requireArbitratedMerged = kFALSE, Double_t trkptMin = -99.);
|
70 |
static Bool_t PassCustomID(const Electron *el, EElIdType idType);
|
71 |
static Bool_t PassCustomIso(const Electron *el, EElIsoType isoType,
|
72 |
Bool_t useCombineIso = kTRUE);
|
73 |
static Bool_t PassD0Cut(const Electron *el, const VertexCol *vertices, Double_t fD0Cut, Int_t nVertex = 0);
|
74 |
static Bool_t PassD0Cut(const Electron *el, const BeamSpotCol *beamspots, Double_t fD0Cut);
|
75 |
static Bool_t PassDZCut(const Electron *el, const VertexCol *vertices, Double_t fDZCut, Int_t nVertex = 0);
|
76 |
static Bool_t PassSpikeRemovalFilter(const Electron *ele);
|
77 |
static Bool_t PassTriggerMatching(const Electron *ele, const TriggerObjectCol *trigobjs);
|
78 |
static Int_t Classify(const Electron *ele);
|
79 |
static Int_t PassTightId(const Electron *ele, const VertexCol *vertices,
|
80 |
const DecayParticleCol *conversions, const Int_t typeCuts,
|
81 |
Double_t beta = 1.0);
|
82 |
static bool compute_cut(double x, double et, double cut_min, double cut_max, bool gtn=false);
|
83 |
static Double_t Likelihood(ElectronLikelihood *LH, const Electron *ele);
|
84 |
|
85 |
ClassDef(ElectronTools, 0) // Muon tools
|
86 |
};
|
87 |
}
|
88 |
|
89 |
#endif
|