25 |
|
#include "MitPhysics/Utils/interface/IsolationTools.h" |
26 |
|
#include "MitAna/DataTree/interface/PileupEnergyDensityCol.h" |
27 |
|
|
28 |
+ |
#include "MitPhysics/Utils/interface/RhoUtilities.h" |
29 |
+ |
|
30 |
|
namespace mithep |
31 |
|
{ |
32 |
|
class MuonIDMod : public BaseMod |
48 |
|
Double_t GetTrackIsoCut() const { return fTrackIsolationCut; } |
49 |
|
Bool_t PassMuonMVA_BDTG_IdIso(const Muon *mu, const Vertex *vertex, |
50 |
|
const PileupEnergyDensityCol *PileupEnergyDensity) const; |
51 |
+ |
Bool_t PassMuonIsoRingsV0_BDTG_Iso(const Muon *mu, const Vertex *vertex, |
52 |
+ |
const PileupEnergyDensityCol *PileupEnergyDensity) const; |
53 |
+ |
Bool_t PassMuonIsoDeltaR(const Muon *mu, const Vertex *vertex, |
54 |
+ |
const PileupEnergyDensityCol *PileupEnergyDensity) const; |
55 |
+ |
void SetPrintMVADebugInfo(Bool_t b) { fPrintMVADebugInfo = b; } |
56 |
|
void SetApplyD0Cut(Bool_t b) { fApplyD0Cut = b; } |
57 |
|
void SetApplyDZCut(Bool_t b) { fApplyDZCut = b; } |
58 |
|
void SetCaloIsoCut(Double_t cut) { fCaloIsolationCut = cut; } |
75 |
|
void SetPtMin(Double_t pt) { fMuonPtMin = pt; } |
76 |
|
void SetTrackIsoCut(Double_t cut) { fTrackIsolationCut = cut; } |
77 |
|
void SetIntRadius(Double_t dr) { fIntRadius = dr; } |
78 |
< |
void SetMuonMVAWeightsSubdet0Pt10To14p5(TString s) |
79 |
< |
{ fMuonMVAWeights_Subdet0Pt10To14p5 = s; } |
80 |
< |
void SetMuonMVAWeightsSubdet1Pt10To14p5(TString s) |
81 |
< |
{ fMuonMVAWeights_Subdet1Pt10To14p5 = s; } |
82 |
< |
void SetMuonMVAWeightsSubdet0Pt14p5To20(TString s) |
76 |
< |
{ fMuonMVAWeights_Subdet0Pt14p5To20 = s; } |
77 |
< |
void SetMuonMVAWeightsSubdet1Pt14p5To20(TString s) |
78 |
< |
{ fMuonMVAWeights_Subdet1Pt14p5To20 = s; } |
79 |
< |
void SetMuonMVAWeightsSubdet0Pt20ToInf(TString s) |
80 |
< |
{ fMuonMVAWeights_Subdet0Pt20ToInf = s; } |
81 |
< |
void SetMuonMVAWeightsSubdet1Pt20ToInf(TString s) |
82 |
< |
{ fMuonMVAWeights_Subdet1Pt20ToInf = s; } |
78 |
> |
|
79 |
> |
void SetRhoType(RhoUtilities::RhoType type) |
80 |
> |
{ fTheRhoType = type; }; |
81 |
> |
|
82 |
> |
void SetVertexName(const char* name) { fVertexName = name; } |
83 |
|
|
84 |
|
enum EMuIdType { |
85 |
|
kIdUndef = 0, //not defined |
90 |
|
kWWMuIdV1, //"WWMuIdV1" |
91 |
|
kWWMuIdV2, //"WWMuIdV2" |
92 |
|
kWWMuIdV3, //"WWMuIdV3" |
93 |
+ |
kWWMuIdV4, //"WWMuIdV4" |
94 |
|
kNoId, //"NoId" |
95 |
|
kCustomId, //"Custom" |
96 |
|
kMVAID_BDTG_IDIso //"BDTG ID + Iso03, Iso04 Combined" |
101 |
|
kTrackCaloCombined, //"TrackCaloCombined" |
102 |
|
kTrackCaloSliding, //"TrackCaloSliding" |
103 |
|
kTrackCaloSlidingNoCorrection, //"TrackCaloSlidingNoCorrection" |
104 |
< |
kCombinedRelativeConeAreaCorrected, //"CombinedRelativeConeAreaCorrected" |
104 |
> |
kCombinedRelativeConeAreaCorrected, //"CombinedRelativeConeAreaCorrected" |
105 |
> |
kCombinedRelativeEffectiveAreaCorrected, |
106 |
|
kCustomIso, //"Custom" |
107 |
|
kPFIso, //"PFIso" |
108 |
< |
kPFIsoEffectiveAreaCorrected, //"PFIso with EffectiveArea Pileup Correction" |
108 |
> |
kPFRadialIso, //"PFRadialIso" |
109 |
> |
kPFIsoEffectiveAreaCorrected, //"PFIso with EffectiveArea Pileup Correction" |
110 |
|
kPFIsoNoL, //"PFIsoNoL" |
111 |
|
kNoIso, //"NoIso" |
112 |
< |
kMVAIso_BDTG_IDIso //"BDTG ID + Iso03, Iso04 Combined" |
112 |
> |
kMVAIso_BDTG_IDIso, //"BDTG ID + Iso03, Iso04 Combined" |
113 |
> |
kIsoRingsV0_BDTG_Iso, //"BDTG Iso Rings" |
114 |
> |
kIsoDeltaR //"BGDT Iso dR" |
115 |
|
}; |
116 |
|
enum EMuClassType { |
117 |
|
kClassUndef = 0, //not defined |
128 |
|
protected: |
129 |
|
void Process(); |
130 |
|
void SlaveBegin(); |
131 |
+ |
void Terminate(); |
132 |
|
|
133 |
+ |
Bool_t fPrintMVADebugInfo; //print MVA debug information |
134 |
|
TString fMuonBranchName; //name of muon collection (input) |
135 |
|
TString fCleanMuonsName; //name of exported "good muon" collection |
136 |
|
TString fNonIsolatedMuonsName; //name of imported "old muon" collection |
162 |
|
const BeamSpotCol *fBeamSpot; //!beamspot branch |
163 |
|
const TrackCol *fTracks; //!track branch |
164 |
|
const PFCandidateCol *fPFCandidates; //!pfcandidate branch |
165 |
+ |
const PFCandidateCol *fPFNoPileUpCands; //!pfnpu collection |
166 |
|
Double_t fIntRadius; //!min IntRadius cut in pf isolation |
167 |
|
MuonCol *fNonIsolatedMuons; //!pointer to old muon collection |
168 |
|
ElectronCol *fNonIsolatedElectrons;//!pointer to old electron collection |
170 |
|
const PileupEnergyDensityCol *fPileupEnergyDensity; |
171 |
|
MuonTools *fMuonTools; // interface to tools for muon ID |
172 |
|
MuonIDMVA *fMuonIDMVA; // helper class for MuonMVA |
165 |
– |
TString fMuonMVAWeights_Subdet0Pt10To14p5; |
166 |
– |
TString fMuonMVAWeights_Subdet1Pt10To14p5; |
167 |
– |
TString fMuonMVAWeights_Subdet0Pt14p5To20; |
168 |
– |
TString fMuonMVAWeights_Subdet1Pt14p5To20; |
169 |
– |
TString fMuonMVAWeights_Subdet0Pt20ToInf; |
170 |
– |
TString fMuonMVAWeights_Subdet1Pt20ToInf; |
173 |
|
|
174 |
+ |
RhoUtilities::RhoType fTheRhoType; |
175 |
+ |
|
176 |
|
ClassDef(MuonIDMod, 1) // Muon identification module |
177 |
|
}; |
178 |
|
} |