3 |
|
// |
4 |
|
// Electron |
5 |
|
// |
6 |
< |
// Details to be worked out... TODO: Needs description ala Muon class |
6 |
> |
// This class holds information about reconstructed electrons from CMSSW. |
7 |
|
// |
8 |
|
// Authors: C.Loizides, J.Bendavid, S.Xie |
9 |
|
//-------------------------------------------------------------------------------------------------- |
10 |
|
|
11 |
< |
#ifndef DATATREE_ELECTRON_H |
12 |
< |
#define DATATREE_ELECTRON_H |
11 |
> |
#ifndef MITANA_DATATREE_ELECTRON_H |
12 |
> |
#define MITANA_DATATREE_ELECTRON_H |
13 |
|
|
14 |
|
#include "MitAna/DataTree/interface/SuperCluster.h" |
15 |
|
#include "MitAna/DataTree/interface/ChargedParticle.h" |
16 |
+ |
#include "MitAna/DataCont/interface/Ref.h" |
17 |
|
|
18 |
|
namespace mithep |
19 |
|
{ |
20 |
|
class Electron : public ChargedParticle |
21 |
|
{ |
22 |
|
public: |
23 |
< |
Electron() : fESuperClusterOverP(0), fESeedClusterOverPout(0), fDeltaEtaSuperClTrkAtVtx(0), |
24 |
< |
fDeltaEtaSeedClTrkAtCalo(0), fDeltaPhiSuperClTrkAtVtx(0), |
25 |
< |
fDeltaPhiSeedClTrkAtCalo(0), fHadronicOverEm(0), fIsEnergyScaleCorrected(0), |
26 |
< |
fIsMomentumCorrected(0), fNumberOfClusters(0), fClassification(0), fE33(0), |
27 |
< |
fE55(0), fCovEtaEta(0), fCoviEtaiEta(0), fCovEtaPhi(0), fCovPhiPhi(0), |
28 |
< |
fCaloIsolation(0), fCaloTowerIsolation(0), fTrackIsolation(0), |
29 |
< |
fEcalJurassicIsolation(0), fHcalJurassicIsolation(0), fPassLooseID(0), |
30 |
< |
fPassTightID(0), fIDLikelihood(0), fPIn(0), fPOut(0) {} |
31 |
< |
~Electron() {} |
23 |
> |
Electron() : |
24 |
> |
fCharge(-99), fScPixCharge(0), |
25 |
> |
fESuperClusterOverP(0), fESeedClusterOverPout(0), fDeltaEtaSuperClTrkAtVtx(0), |
26 |
> |
fDeltaEtaSeedClTrkAtCalo(0), fDeltaPhiSuperClTrkAtVtx(0), |
27 |
> |
fDeltaPhiSeedClTrkAtCalo(0), fFBrem(0), fHadronicOverEm(0), fHcalDepth1OverEcal(0), |
28 |
> |
fHcalDepth2OverEcal(0), fNumberOfClusters(0), fE15(0), fE25Max(0), |
29 |
> |
fE55(0), fCovEtaEta(0), fCoviEtaiEta(0), |
30 |
> |
fCaloIsolation(0), fHcalJurassicIsolation(0), |
31 |
> |
fHcalDepth1TowerSumEtDr04(0), fHcalDepth2TowerSumEtDr04(0), |
32 |
> |
fEcalJurassicIsolation(0), fTrackIsolationDr04(0), fCaloTowerIsolation(0), |
33 |
> |
fHcalDepth1TowerSumEtDr03(0), fHcalDepth2TowerSumEtDr03(0), |
34 |
> |
fEcalRecHitSumEtDr03(0), fTrackIsolation(0), fPassLooseID(0), |
35 |
> |
fPassTightID(0), fIDLikelihood(0), fPIn(0), fPOut(0), fFracSharedHits(0), |
36 |
> |
fMva(0), fD0PV(0), fD0PVErr(0), fIp3dPV(0), fIp3dPVErr(0), |
37 |
> |
fD0PVBS(0), fD0PVBSErr(0), fIp3dPVBS(0), fIp3dPVBSErr(0), |
38 |
> |
fGsfPVCompatibility(0), fGsfPVBSCompatibility(0), |
39 |
> |
fGsfPVCompatibilityMatched(0), fGsfPVBSCompatibilityMatched(0), |
40 |
> |
fConvPartnerDCotTheta(0), fConvPartnerDist(0), fConvPartnerRadius(0), |
41 |
> |
fIsEnergyScaleCorrected(0), fIsMomentumCorrected(0), |
42 |
> |
fClassification(0), fIsEB(), fIsEE(0), fIsEBEEGap(0), fIsEBEtaGap(0), |
43 |
> |
fIsEBPhiGap(0), fIsEEDeeGap(0), fIsEERingGap(0), |
44 |
> |
fIsEcalDriven(0), fIsTrackerDriven(0) {} |
45 |
> |
|
46 |
> |
const Track *BestTrk() const; |
47 |
> |
Double_t D0PV() const { return fD0PV; } |
48 |
> |
Double_t D0PVErr() const { return fD0PVErr; } |
49 |
> |
Double_t D0PVSignificance() const { return fD0PV/fD0PVErr; } |
50 |
> |
Double_t Ip3dPV() const { return fIp3dPV; } |
51 |
> |
Double_t Ip3dPVErr() const { return fIp3dPVErr; } |
52 |
> |
Double_t Ip3dPVSignificance() const { return fIp3dPV/fIp3dPVErr; } |
53 |
> |
Double_t D0PVBS() const { return fD0PVBS; } |
54 |
> |
Double_t D0PVBSErr() const { return fD0PVBSErr; } |
55 |
> |
Double_t D0PVBSSignificance() const { return fD0PVBS/fD0PVBSErr; } |
56 |
> |
Double_t Ip3dPVBS() const { return fIp3dPVBS; } |
57 |
> |
Double_t Ip3dPVBSErr() const { return fIp3dPVBSErr; } |
58 |
> |
Double_t Ip3dPVBSSignificance() const { return fIp3dPVBS/fIp3dPVBSErr; } |
59 |
> |
Double_t GsfPVCompatibility() const { return fGsfPVCompatibility; } |
60 |
> |
Double_t GsfPVBSCompatibility() const { return fGsfPVBSCompatibility; } |
61 |
> |
Double_t GsfPVCompatibilityMatched() const { return fGsfPVCompatibilityMatched; } |
62 |
> |
Double_t GsfPVBSCompatibilityMatched() const { return fGsfPVBSCompatibilityMatched; } |
63 |
> |
Double_t ConvPartnerDCotTheta() const { return fConvPartnerDCotTheta; } |
64 |
> |
Double_t ConvPartnerDist() const { return fConvPartnerDist; } |
65 |
> |
Double_t ConvPartnerRadius() const { return fConvPartnerRadius; } |
66 |
> |
Double_t CaloIsolation() const { return fCaloIsolation; } // *DEPRECATED* |
67 |
> |
Int_t Classification() const { return fClassification; } |
68 |
> |
Double_t CovEtaEta() const { return fCovEtaEta; } |
69 |
> |
Double_t CoviEtaiEta() const { return fCoviEtaiEta; } |
70 |
> |
Double_t DeltaEtaSuperClusterTrackAtVtx() const |
71 |
> |
{ return fDeltaEtaSuperClTrkAtVtx; } |
72 |
> |
Double_t DeltaEtaSeedClusterTrackAtCalo() const |
73 |
> |
{ return fDeltaEtaSeedClTrkAtCalo; } |
74 |
> |
Double_t DeltaPhiSuperClusterTrackAtVtx() const |
75 |
> |
{ return fDeltaPhiSuperClTrkAtVtx; } |
76 |
> |
Double_t DeltaPhiSeedClusterTrackAtCalo() const |
77 |
> |
{ return fDeltaPhiSeedClTrkAtCalo; } |
78 |
> |
Double_t E15() const { return fE15; } |
79 |
> |
Double_t E25Max() const { return fE25Max; } |
80 |
> |
Double_t E55() const { return fE55; } |
81 |
> |
Double_t ESuperClusterOverP() const { return fESuperClusterOverP; } |
82 |
> |
Double_t ESeedClusterOverPout() const { return fESeedClusterOverPout; } |
83 |
> |
Double_t ESeedClusterOverPIn() const; |
84 |
> |
Double_t FBrem() const { return fFBrem; } |
85 |
> |
Double_t FBremOld() const { return (PIn() - POut())/PIn(); } |
86 |
> |
Double_t FracSharedHits() const { return fFracSharedHits; } |
87 |
> |
const Track *GsfTrk() const { return fGsfTrackRef.Obj(); } |
88 |
> |
Double_t HadronicOverEm() const { return fHadronicOverEm; } |
89 |
> |
Double_t HcalDepth1OverEcal() const { return fHcalDepth1OverEcal; } |
90 |
> |
Double_t HcalDepth2OverEcal() const { return fHcalDepth2OverEcal; } |
91 |
> |
Bool_t HasGsfTrk() const { return fGsfTrackRef.IsValid(); } |
92 |
> |
Bool_t HasTrackerTrk() const { return fTrackerTrackRef.IsValid(); } |
93 |
> |
Bool_t HasSuperCluster() const { return fSuperClusterRef.IsValid(); } |
94 |
> |
Double_t HcalIsolation() const { return fHcalJurassicIsolation; } // *DEPRECATED* |
95 |
> |
Double_t IDLikelihood() const { return fIDLikelihood; } |
96 |
> |
Bool_t IsEnergyScaleCorrected() const { return fIsEnergyScaleCorrected; } |
97 |
> |
Bool_t IsMomentumCorrected() const { return fIsMomentumCorrected; } |
98 |
> |
Bool_t IsEB() const { return fIsEB; } |
99 |
> |
Bool_t IsEE() const { return fIsEE; } |
100 |
> |
Bool_t IsEBEEGap() const { return fIsEBEEGap; } |
101 |
> |
Bool_t IsEBEtaGap() const { return fIsEBEtaGap; } |
102 |
> |
Bool_t IsEBPhiGap() const { return fIsEBPhiGap; } |
103 |
> |
Bool_t IsEEDeeGap() const { return fIsEEDeeGap; } |
104 |
> |
Bool_t IsEERingGap() const { return fIsEERingGap; } |
105 |
> |
Bool_t IsEcalDriven() const { return fIsEcalDriven; } |
106 |
> |
Bool_t IsTrackerDriven() const { return fIsTrackerDriven; } |
107 |
> |
Double_t Mva() const { return fMva; } |
108 |
> |
Double_t NumberOfClusters() const { return fNumberOfClusters; } |
109 |
> |
EObjType ObjType() const { return kElectron; } |
110 |
> |
Double_t PassLooseID() const { return fPassLooseID; } |
111 |
> |
Double_t PassTightID() const { return fPassTightID; } |
112 |
> |
Double_t PIn() const { return fPIn; } |
113 |
> |
Double_t POut() const { return fPOut; } |
114 |
> |
const SuperCluster *SCluster() const { return fSuperClusterRef.Obj(); } |
115 |
> |
Double_t ScPixCharge() const { return fScPixCharge; } |
116 |
|
|
117 |
< |
const Track *BestTrk() const; |
118 |
< |
const Track *GsfTrk() const; |
119 |
< |
const Track *TrackerTrk() const; |
120 |
< |
const SuperCluster *SCluster() const; |
121 |
< |
FourVector Mom() const; |
117 |
> |
Double_t EcalRecHitIsoDr04() const { return fEcalJurassicIsolation; } |
118 |
> |
Double_t HcalTowerSumEtDr04() const { return HcalDepth1TowerSumEtDr04() + |
119 |
> |
HcalDepth2TowerSumEtDr04(); } |
120 |
> |
Double_t HcalDepth1TowerSumEtDr04() const { return fHcalDepth1TowerSumEtDr04; } |
121 |
> |
Double_t HcalDepth2TowerSumEtDr04() const { return fHcalDepth2TowerSumEtDr04; } |
122 |
> |
Double_t TrackIsolationDr04() const { return fTrackIsolationDr04; } |
123 |
> |
Double_t EcalRecHitIsoDr03() const { return fEcalRecHitSumEtDr03; } |
124 |
> |
Double_t HcalTowerSumEtDr03() const { return fCaloTowerIsolation; } |
125 |
> |
Double_t HcalDepth1TowerSumEtDr03() const { return fHcalDepth1TowerSumEtDr03; } |
126 |
> |
Double_t HcalDepth2TowerSumEtDr03() const { return fHcalDepth2TowerSumEtDr03; } |
127 |
> |
Double_t TrackIsolationDr03() const { return fTrackIsolation; } |
128 |
> |
|
129 |
> |
|
130 |
> |
void SetCharge(Char_t x) { fCharge = x; ClearCharge(); } |
131 |
> |
void SetScPixCharge(Char_t x) { fScPixCharge = x; } |
132 |
> |
void SetD0PV(Double_t x) { fD0PV = x; } |
133 |
> |
void SetD0PVErr(Double_t x) { fD0PVErr = x; } |
134 |
> |
void SetIp3dPV(Double_t x) { fIp3dPV = x; } |
135 |
> |
void SetIp3dPVErr(Double_t x) { fIp3dPVErr = x; } |
136 |
> |
void SetD0PVBS(Double_t x) { fD0PVBS = x; } |
137 |
> |
void SetD0PVBSErr(Double_t x) { fD0PVBSErr = x; } |
138 |
> |
void SetIp3dPVBS(Double_t x) { fIp3dPVBS = x; } |
139 |
> |
void SetIp3dPVBSErr(Double_t x) { fIp3dPVBSErr = x; } |
140 |
> |
void SetGsfPVCompatibility(Double_t x) { fGsfPVCompatibility = x; } |
141 |
> |
void SetGsfPVBSCompatibility(Double_t x) { fGsfPVBSCompatibility = x; } |
142 |
> |
void SetGsfPVCompatibilityMatched(Double_t x) { fGsfPVCompatibilityMatched = x; } |
143 |
> |
void SetGsfPVBSCompatibilityMatched(Double_t x) { fGsfPVBSCompatibilityMatched = x; } |
144 |
> |
void SetConvPartnerDCotTheta(Double_t x) { fConvPartnerDCotTheta = x; } |
145 |
> |
void SetConvPartnerDist(Double_t x) { fConvPartnerDist = x; } |
146 |
> |
void SetConvPartnerRadius(Double_t x) { fConvPartnerRadius = x; } |
147 |
> |
void SetClassification(Int_t x) { fClassification = x; } |
148 |
> |
void SetCovEtaEta(Double_t CovEtaEta) { fCovEtaEta = CovEtaEta; } |
149 |
> |
void SetCoviEtaiEta(Double_t CoviEtaiEta) { fCoviEtaiEta = CoviEtaiEta; } |
150 |
> |
void SetDeltaEtaSuperClusterTrackAtVtx(Double_t x) |
151 |
> |
{ fDeltaEtaSuperClTrkAtVtx = x; } |
152 |
> |
void SetDeltaEtaSeedClusterTrackAtCalo(Double_t x) |
153 |
> |
{ fDeltaEtaSeedClTrkAtCalo = x; } |
154 |
> |
void SetDeltaPhiSuperClusterTrackAtVtx(Double_t x) |
155 |
> |
{ fDeltaPhiSuperClTrkAtVtx = x; } |
156 |
> |
void SetDeltaPhiSeedClusterTrackAtCalo(Double_t x) |
157 |
> |
{ fDeltaPhiSeedClTrkAtCalo = x; } |
158 |
> |
void SetE15(Double_t x) { fE15 = x; } |
159 |
> |
void SetE25Max(Double_t x) { fE25Max = x; } |
160 |
> |
void SetE55(Double_t x) { fE55 = x; } |
161 |
> |
void SetESeedClusterOverPout(Double_t x) { fESeedClusterOverPout = x; } |
162 |
> |
void SetESuperClusterOverP(Double_t x) { fESuperClusterOverP = x; } |
163 |
> |
void SetFBrem(Double_t x) { fFBrem = x; } |
164 |
> |
void SetFracSharedHits(Double_t x) { fFracSharedHits = x; } |
165 |
> |
void SetGsfTrk(const Track* t) |
166 |
> |
{ fGsfTrackRef = t; ClearCharge(); } |
167 |
> |
void SetHadronicOverEm(Double_t x) { fHadronicOverEm = x; } |
168 |
> |
void SetHcalDepth1OverEcal(Double_t x) { fHcalDepth1OverEcal = x; } |
169 |
> |
void SetHcalDepth2OverEcal(Double_t x) { fHcalDepth2OverEcal = x; } |
170 |
> |
void SetIDLikelihood(Double_t likelihood) { fIDLikelihood = likelihood; } |
171 |
> |
void SetIsEnergyScaleCorrected(Bool_t x) { fIsEnergyScaleCorrected = x; } |
172 |
> |
void SetIsMomentumCorrected(Bool_t x) { fIsMomentumCorrected = x; } |
173 |
> |
void SetNumberOfClusters(Double_t x) { fNumberOfClusters = x; } |
174 |
> |
void SetPIn(Double_t PIn) { fPIn = PIn; } |
175 |
> |
void SetPOut(Double_t POut) { fPOut = POut; } |
176 |
> |
void SetPassLooseID(Double_t passLooseID) { fPassLooseID = passLooseID; } |
177 |
> |
void SetPassTightID(Double_t passTightID) { fPassTightID = passTightID; } |
178 |
> |
void SetPtEtaPhi(Double_t pt, Double_t eta, Double_t phi); |
179 |
> |
void SetSuperCluster(const SuperCluster* sc) |
180 |
> |
{ fSuperClusterRef = sc; } |
181 |
> |
void SetTrackerTrk(const Track* t) |
182 |
> |
{ fTrackerTrackRef = t; ClearCharge(); } |
183 |
> |
void SetEcalRecHitIsoDr04(Double_t x) { fEcalJurassicIsolation = x; } |
184 |
> |
void SetHcalDepth1TowerSumEtDr04(Double_t x) { fHcalDepth1TowerSumEtDr04 = x; } |
185 |
> |
void SetHcalDepth2TowerSumEtDr04(Double_t x) { fHcalDepth2TowerSumEtDr04 = x; } |
186 |
> |
void SetTrackIsolationDr04(Double_t x) { fTrackIsolationDr04 = x; } |
187 |
> |
void SetEcalRecHitIsoDr03(Double_t x) { fEcalRecHitSumEtDr03 = x; } |
188 |
> |
void SetHcalTowerSumEtDr03(Double_t x) { fCaloTowerIsolation = x; } |
189 |
> |
void SetHcalDepth1TowerSumEtDr03(Double_t x) { fHcalDepth1TowerSumEtDr03 = x; } |
190 |
> |
void SetHcalDepth2TowerSumEtDr03(Double_t x) { fHcalDepth2TowerSumEtDr03 = x; } |
191 |
> |
void SetTrackIsolationDr03(Double_t x) { fTrackIsolation = x; } |
192 |
> |
void SetMva(Double_t x) { fMva = x; } |
193 |
> |
void SetIsEB(Bool_t b) { fIsEB = b; } |
194 |
> |
void SetIsEE(Bool_t b) { fIsEE = b; } |
195 |
> |
void SetIsEBEEGap(Bool_t b) { fIsEBEEGap = b; } |
196 |
> |
void SetIsEBEtaGap(Bool_t b) { fIsEBEtaGap = b; } |
197 |
> |
void SetIsEBPhiGap(Bool_t b) { fIsEBPhiGap = b; } |
198 |
> |
void SetIsEEDeeGap(Bool_t b) { fIsEEDeeGap = b; } |
199 |
> |
void SetIsEERingGap(Bool_t b) { fIsEERingGap = b; } |
200 |
> |
void SetIsEcalDriven(Bool_t b) { fIsEcalDriven = b; } |
201 |
> |
void SetIsTrackerDriven(Bool_t b) { fIsTrackerDriven = b; } |
202 |
> |
|
203 |
> |
|
204 |
> |
const Track *TrackerTrk() const { return fTrackerTrackRef.Obj(); } |
205 |
|
const Track *Trk() const { return BestTrk(); } |
38 |
– |
Double_t CaloIsolation() const { return fCaloIsolation; } |
39 |
– |
Double_t CaloTowerIsolation() const { return fCaloTowerIsolation; } |
40 |
– |
Double_t Classification() const { return fClassification; } |
41 |
– |
Double_t CovEtaEta() const { return fCovEtaEta; } |
42 |
– |
Double_t CovEtaPhi() const { return fCovEtaPhi; } |
43 |
– |
Double_t CovPhiPhi() const { return fCovPhiPhi; } |
44 |
– |
Double_t CoviEtaiEta() const { return fCoviEtaiEta; } |
45 |
– |
Double_t DeltaEtaSuperClusterTrackAtVtx() const { return fDeltaEtaSuperClTrkAtVtx; } |
46 |
– |
Double_t DeltaEtaSeedClusterTrackAtCalo() const { return fDeltaEtaSeedClTrkAtCalo; } |
47 |
– |
Double_t DeltaPhiSuperClusterTrackAtVtx() const { return fDeltaPhiSuperClTrkAtVtx; } |
48 |
– |
Double_t DeltaPhiSeedClusterTrackAtCalo() const { return fDeltaPhiSeedClTrkAtCalo; } |
49 |
– |
Double_t E() const; |
50 |
– |
Double_t E33() const { return fE33; } |
51 |
– |
Double_t E55() const { return fE55; } |
52 |
– |
Double_t EcalJurassicIsolation() const { return fEcalJurassicIsolation; } |
53 |
– |
Double_t ESuperClusterOverP() const { return fESuperClusterOverP; } |
54 |
– |
Double_t ESeedClusterOverPout() const { return fESeedClusterOverPout; } |
55 |
– |
Double_t ESeedClusterOverPIn() const; |
56 |
– |
Double_t IDLikelihood() const { return fIDLikelihood; } |
57 |
– |
Double_t IsEnergyScaleCorrected() const { return fIsEnergyScaleCorrected; } |
58 |
– |
Double_t IsMomentumCorrected() const { return fIsMomentumCorrected; } |
59 |
– |
Double_t HadronicOverEm() const { return fHadronicOverEm; } |
60 |
– |
Double_t HcalIsolation() const { return fHcalJurassicIsolation; } |
61 |
– |
Double_t Mass() const { return 0.51099892e-3; } |
62 |
– |
Double_t NumberOfClusters() const { return fNumberOfClusters; } |
63 |
– |
EObjType ObjType() const { return kElectron; } |
64 |
– |
Double_t PassLooseID() const { return fPassLooseID; } |
65 |
– |
Double_t PassTightID() const { return fPassTightID; } |
66 |
– |
Double_t PIn() const { return fPIn; } |
67 |
– |
Double_t POut() const { return fPOut; } |
68 |
– |
Double_t P() const; |
69 |
– |
Double_t Pt() const; |
70 |
– |
Double_t Px() const; |
71 |
– |
Double_t Py() const; |
72 |
– |
Double_t Pz() const; |
73 |
– |
Double_t TrackIsolation() const { return fTrackIsolation; } |
74 |
– |
void SetGsfTrk(const Track* t) |
75 |
– |
{ fGsfTrackRef = const_cast<Track*>(t); } |
76 |
– |
void SetTrackerTrk(const Track* t) |
77 |
– |
{ fTrackerTrackRef = const_cast<Track*>(t); } |
78 |
– |
void SetSuperCluster(const SuperCluster* sc) |
79 |
– |
{ fSuperClusterRef = const_cast<SuperCluster*>(sc); } |
80 |
– |
void SetCaloIsolation(Double_t CaloIsolation) { fCaloIsolation = CaloIsolation; } |
81 |
– |
void SetCaloTowerIsolation(Double_t TowerIso) { fCaloTowerIsolation = TowerIso; } |
82 |
– |
void SetClassification(Double_t x) { fClassification = x; } |
83 |
– |
void SetCovEtaEta(Double_t CovEtaEta) { fCovEtaEta = CovEtaEta; } |
84 |
– |
void SetCovEtaPhi(Double_t CovEtaPhi) { fCovEtaPhi = CovEtaPhi; } |
85 |
– |
void SetCovPhiPhi(Double_t CovPhiPhi) { fCovPhiPhi = CovPhiPhi; } |
86 |
– |
void SetCoviEtaiEta(Double_t CoviEtaiEta) { fCoviEtaiEta = CoviEtaiEta; } |
87 |
– |
void SetDeltaEtaSuperClusterTrackAtVtx(Double_t x) { fDeltaEtaSuperClTrkAtVtx = x; } |
88 |
– |
void SetDeltaEtaSeedClusterTrackAtCalo(Double_t x) { fDeltaEtaSeedClTrkAtCalo = x; } |
89 |
– |
void SetDeltaPhiSuperClusterTrackAtVtx(Double_t x) { fDeltaPhiSuperClTrkAtVtx = x; } |
90 |
– |
void SetDeltaPhiSeedClusterTrackAtCalo(Double_t x) { fDeltaPhiSeedClTrkAtCalo = x; } |
91 |
– |
void SetE33(Double_t E33) { fE33 = E33; } |
92 |
– |
void SetE55(Double_t E55) { fE55 = E55; } |
93 |
– |
void SetEcalJurassicIsolation(Double_t iso ) { fEcalJurassicIsolation = iso; } |
94 |
– |
void SetESuperClusterOverP(Double_t x) { fESuperClusterOverP = x; } |
95 |
– |
void SetESeedClusterOverPout(Double_t x) { fESeedClusterOverPout = x; } |
96 |
– |
void SetHadronicOverEm(Double_t x) { fHadronicOverEm = x; } |
97 |
– |
void SetIDLikelihood(Double_t likelihood) { fIDLikelihood = likelihood; } |
98 |
– |
void SetIsEnergyScaleCorrected(Double_t x) { fIsEnergyScaleCorrected = x; } |
99 |
– |
void SetIsMomentumCorrected(Double_t x) { fIsMomentumCorrected = x; } |
100 |
– |
void SetHcalIsolation(Double_t iso ) { fHcalJurassicIsolation = iso; } |
101 |
– |
void SetNumberOfClusters(Double_t x) { fNumberOfClusters = x; } |
102 |
– |
void SetPassLooseID(Double_t passLooseID) { fPassLooseID = passLooseID; } |
103 |
– |
void SetPassTightID(Double_t passTightID) { fPassTightID = passTightID; } |
104 |
– |
void SetPIn(Double_t PIn) { fPIn = PIn; } |
105 |
– |
void SetPOut(Double_t POut) { fPOut = POut; } |
106 |
– |
void SetTrackIsolation(Double_t TrackIsolation) { fTrackIsolation = TrackIsolation;} |
206 |
|
|
207 |
|
protected: |
208 |
< |
TRef fGsfTrackRef; //global combined track reference |
209 |
< |
TRef fTrackerTrackRef; //tracker track reference |
210 |
< |
TRef fSuperClusterRef; //reference to SuperCluster |
211 |
< |
Double_t fESuperClusterOverP; // |
212 |
< |
Double_t fESeedClusterOverPout; // |
213 |
< |
Double_t fDeltaEtaSuperClTrkAtVtx; // |
214 |
< |
Double_t fDeltaEtaSeedClTrkAtCalo; // |
215 |
< |
Double_t fDeltaPhiSuperClTrkAtVtx; // |
216 |
< |
Double_t fDeltaPhiSeedClTrkAtCalo; // |
217 |
< |
Double_t fHadronicOverEm; // |
218 |
< |
Double_t fIsEnergyScaleCorrected; // |
219 |
< |
Double_t fIsMomentumCorrected; // |
220 |
< |
Double_t fNumberOfClusters; // |
221 |
< |
Double_t fClassification; // |
222 |
< |
Double_t fE33; // |
223 |
< |
Double_t fE55; // |
224 |
< |
Double_t fCovEtaEta; // |
225 |
< |
Double_t fCoviEtaiEta; // |
226 |
< |
Double_t fCovEtaPhi; // |
227 |
< |
Double_t fCovPhiPhi; // |
228 |
< |
Double_t fCaloIsolation; // |
229 |
< |
Double_t fCaloTowerIsolation; // |
230 |
< |
Double_t fTrackIsolation; // |
231 |
< |
Double_t fEcalJurassicIsolation; // |
232 |
< |
Double_t fHcalJurassicIsolation; // |
233 |
< |
Double_t fPassLooseID; // |
234 |
< |
Double_t fPassTightID; // |
235 |
< |
Double_t fIDLikelihood; // |
236 |
< |
Double_t fPIn; // |
237 |
< |
Double_t fPOut; // |
208 |
> |
Double_t GetCharge() const; |
209 |
> |
Double_t GetMass() const { return 0.51099892e-3; } |
210 |
> |
void GetMom() const; |
211 |
> |
|
212 |
> |
Vect3C fMom; //stored three-momentum |
213 |
> |
Char_t fCharge; //stored charge - filled with -99 when reading old files |
214 |
> |
Char_t fScPixCharge; //charge from supercluster-pixel matching |
215 |
> |
Ref<Track> fGsfTrackRef; //gsf track reference |
216 |
> |
Ref<Track> fTrackerTrackRef; //tracker track reference |
217 |
> |
Ref<SuperCluster> fSuperClusterRef; //reference to SuperCluster |
218 |
> |
Double32_t fESuperClusterOverP; //[0,0,14]super cluster e over p ratio |
219 |
> |
Double32_t fESeedClusterOverPout; //[0,0,14]seed cluster e over p mom |
220 |
> |
Double32_t fDeltaEtaSuperClTrkAtVtx; //[0,0,14]delta eta of super cluster with trk |
221 |
> |
Double32_t fDeltaEtaSeedClTrkAtCalo; //[0,0,14]delta eta of seeed cluster with trk |
222 |
> |
Double32_t fDeltaPhiSuperClTrkAtVtx; //[0,0,14]delta phi of super cluster with trk |
223 |
> |
Double32_t fDeltaPhiSeedClTrkAtCalo; //[0,0,14]delta phi of seeed cluster with trk |
224 |
> |
Double32_t fFBrem; //[0,0,14]brem fraction |
225 |
> |
Double32_t fHadronicOverEm; //[0,0,14]hadronic over em fraction *DEPRECATED* |
226 |
> |
Double32_t fHcalDepth1OverEcal; //[0,0,14]hadronic over em fraction depth1 |
227 |
> |
Double32_t fHcalDepth2OverEcal; //[0,0,14]hadronic over em fraction depth2 |
228 |
> |
Double32_t fNumberOfClusters; //[0,0,14]number of associated clusters |
229 |
> |
Double32_t fE15; //[0,0,14]1x5 crystal energy |
230 |
> |
Double32_t fE25Max; //[0,0,14]2x5 crystal energy (max of two possible sums) |
231 |
> |
Double32_t fE55; //[0,0,14]5x5 crystal energy |
232 |
> |
Double32_t fCovEtaEta; //[0,0,14]variance eta-eta |
233 |
> |
Double32_t fCoviEtaiEta; //[0,0,14]covariance eta-eta (in crystals) |
234 |
> |
Double32_t fCaloIsolation; //[0,0,14](non-jura) ecal isolation based on rechits dR 0.3 *DEPRECATED* |
235 |
> |
Double32_t fHcalJurassicIsolation; //[0,0,14]hcal jura iso dR 0.4 *DEPRECATED* |
236 |
> |
Double32_t fHcalDepth1TowerSumEtDr04; //[0,0,14]hcal depth1 tower based isolation dR 0.4 |
237 |
> |
Double32_t fHcalDepth2TowerSumEtDr04; //[0,0,14]hcal depth2 tower based isolation dR 0.4 |
238 |
> |
Double32_t fEcalJurassicIsolation; //[0,0,14]ecal jura iso dR 0.4 *RENAMING* |
239 |
> |
Double32_t fTrackIsolationDr04; //[0,0,14]isolation based on tracks dR 0.4 |
240 |
> |
Double32_t fCaloTowerIsolation; //[0,0,14]hcal tower based isolation dR 0.3 *DEPRECATED* |
241 |
> |
Double32_t fHcalDepth1TowerSumEtDr03; //[0,0,14]hcal depth1 tower based isolation dR 0.3 |
242 |
> |
Double32_t fHcalDepth2TowerSumEtDr03; //[0,0,14]hcal depth2 tower based isolation dR 0.3 |
243 |
> |
Double32_t fEcalRecHitSumEtDr03; //[0,0,14]ecal jura iso dR 0.3 |
244 |
> |
Double32_t fTrackIsolation; //[0,0,14]isolation based on tracks dR 0.3 *RENAMING* |
245 |
> |
Double32_t fPassLooseID; //[0,0,14]pass loose id |
246 |
> |
Double32_t fPassTightID; //[0,0,14]pass tight id |
247 |
> |
Double32_t fIDLikelihood; //[0,0,14]likelihood value |
248 |
> |
Double32_t fPIn; //[0,0,14]momentum at vtx |
249 |
> |
Double32_t fPOut; //[0,0,14]momentum at ecal surface |
250 |
> |
Double32_t fFracSharedHits; //[0,0,14]fraction of shared hits btw gsf and std. track |
251 |
> |
Double32_t fMva; //[0,0,14] pflow mva output |
252 |
> |
Double32_t fD0PV; //[0,0,14]transverse impact parameter to signal PV |
253 |
> |
Double32_t fD0PVErr; //[0,0,14]transverse impact parameter uncertainty to signal PV |
254 |
> |
Double32_t fIp3dPV; //[0,0,14]3d impact parameter to signal PV |
255 |
> |
Double32_t fIp3dPVErr; //[0,0,14]3d impact parameter uncertainty to signal PV |
256 |
> |
Double32_t fD0PVBS; //[0,0,14]transverse impact parameter to signal PV w/ bs constraint |
257 |
> |
Double32_t fD0PVBSErr; //[0,0,14]transverse impact parameter uncertainty to signal PV w/ bs constraint |
258 |
> |
Double32_t fIp3dPVBS; //[0,0,14]3d impact parameter to signal PV w/ bs constraint |
259 |
> |
Double32_t fIp3dPVBSErr; //[0,0,14]3d impact parameter uncertainty to signal PV w/ bs constraint |
260 |
> |
Double32_t fGsfPVCompatibility; //[0,0,14]gsf compatibility with signal PV |
261 |
> |
Double32_t fGsfPVBSCompatibility; //[0,0,14]gsf compatibility with signal PV w/ bs constraint |
262 |
> |
Double32_t fGsfPVCompatibilityMatched; //[0,0,14]gsf compatibility with signal PV (matching ckf track excluded from vertex) |
263 |
> |
Double32_t fGsfPVBSCompatibilityMatched; //[0,0,14]gsf compatibility with signal PV w/ bs constraint (matching ckf track excluded from vertex) |
264 |
> |
Double32_t fConvPartnerDCotTheta; //[0,0,14]delta cot theta to nearest conversion partner track |
265 |
> |
Double32_t fConvPartnerDist; //[0,0,14]distance in x-y plane to nearest conversion partner track |
266 |
> |
Double32_t fConvPartnerRadius; //[0,0,14]radius of helix intersection with conversion partner track |
267 |
> |
Bool_t fIsEnergyScaleCorrected; //class dependent escale correction |
268 |
> |
Bool_t fIsMomentumCorrected; //class dependent E-p combination |
269 |
> |
Int_t fClassification; //classification (see GsfElectron.h) |
270 |
> |
Bool_t fIsEB; //is ECAL barrel |
271 |
> |
Bool_t fIsEE; //is ECAL Endcap |
272 |
> |
Bool_t fIsEBEEGap; //is in barrel-endcap gap |
273 |
> |
Bool_t fIsEBEtaGap; //is in EB eta module gap |
274 |
> |
Bool_t fIsEBPhiGap; //is in EB phi module gap |
275 |
> |
Bool_t fIsEEDeeGap; //is in EE dee gap |
276 |
> |
Bool_t fIsEERingGap; //is in EE ring gap |
277 |
> |
Bool_t fIsEcalDriven; //is std. egamma electron |
278 |
> |
Bool_t fIsTrackerDriven; //is pflow track-seeded electron |
279 |
|
|
280 |
< |
ClassDef(Electron, 1) // Electron class |
280 |
> |
ClassDef(Electron, 5) // Electron class |
281 |
|
}; |
282 |
|
} |
283 |
|
|
286 |
|
{ |
287 |
|
// Return "best" track. |
288 |
|
|
289 |
< |
if (GsfTrk()) |
289 |
> |
if (HasGsfTrk()) |
290 |
|
return GsfTrk(); |
291 |
< |
else if (TrackerTrk()) |
291 |
> |
else if (HasTrackerTrk()) |
292 |
|
return TrackerTrk(); |
293 |
|
|
294 |
|
return 0; |
295 |
|
} |
296 |
|
|
297 |
|
//-------------------------------------------------------------------------------------------------- |
298 |
< |
inline const mithep::Track *mithep::Electron::GsfTrk() const |
298 |
> |
inline Double_t mithep::Electron::GetCharge() const |
299 |
|
{ |
300 |
< |
// Return global combined track. |
300 |
> |
// Return stored charge, unless it is set to invalid (-99), |
301 |
> |
// in that case get charge from track as before |
302 |
|
|
303 |
< |
return static_cast<const Track*>(fGsfTrackRef.GetObject()); |
304 |
< |
} |
305 |
< |
|
306 |
< |
//-------------------------------------------------------------------------------------------------- |
166 |
< |
inline const mithep::Track *mithep::Electron::TrackerTrk() const |
167 |
< |
{ |
168 |
< |
// Return tracker track. |
169 |
< |
|
170 |
< |
return static_cast<const Track*>(fTrackerTrackRef.GetObject()); |
171 |
< |
} |
172 |
< |
//-------------------------------------------------------------------------------------------------- |
173 |
< |
inline const mithep::SuperCluster *mithep::Electron::SCluster() const |
174 |
< |
{ |
175 |
< |
// Return super cluster. |
303 |
> |
if (fCharge==-99) |
304 |
> |
return mithep::ChargedParticle::GetCharge(); |
305 |
> |
else |
306 |
> |
return fCharge; |
307 |
|
|
177 |
– |
return static_cast<const SuperCluster*>(fSuperClusterRef.GetObject()); |
308 |
|
} |
309 |
|
|
310 |
< |
//------------------------------------------------------------------------------------------------- |
311 |
< |
inline mithep::FourVector mithep::Electron::Mom() const |
310 |
> |
//-------------------------------------------------------------------------------------------------- |
311 |
> |
inline void mithep::Electron::GetMom() const |
312 |
|
{ |
313 |
< |
// Return momentum of the electron. We use the direction of the |
314 |
< |
// track and the energy of the SuperCluster. |
313 |
> |
// Get momentum of the electron. We use an explicitly stored three vector, with the pdg mass, |
314 |
> |
// since the momentum vector may be computed non-trivially in cmssw |
315 |
|
|
316 |
< |
return FourVector(Px(), Py(), Pz(), E()); |
316 |
> |
fCachedMom.SetCoordinates(fMom.Rho(),fMom.Eta(),fMom.Phi(),GetMass()); |
317 |
|
} |
318 |
|
|
319 |
|
//------------------------------------------------------------------------------------------------- |
326 |
|
} |
327 |
|
|
328 |
|
//------------------------------------------------------------------------------------------------- |
329 |
< |
inline Double_t mithep::Electron::E() const |
200 |
< |
{ |
201 |
< |
// Return energy of the SuperCluster if present |
202 |
< |
// or else return energy derived from the track. |
203 |
< |
|
204 |
< |
const mithep::SuperCluster *sc = SCluster(); |
205 |
< |
if (sc) |
206 |
< |
return sc->Energy(); |
207 |
< |
else |
208 |
< |
return TMath::Sqrt(Trk()->P()*Trk()->P() + Mass()*Mass()); |
209 |
< |
} |
210 |
< |
|
211 |
< |
//------------------------------------------------------------------------------------------------- |
212 |
< |
inline Double_t mithep::Electron::P() const |
329 |
> |
inline void mithep::Electron::SetPtEtaPhi(Double_t pt, Double_t eta, Double_t phi) |
330 |
|
{ |
331 |
< |
// Return momentum derived from the SuperCluster if present |
215 |
< |
// or else return momentum from the track. |
331 |
> |
// Set three-vector |
332 |
|
|
333 |
< |
const mithep::SuperCluster *sc = SCluster(); |
334 |
< |
if (sc) |
219 |
< |
return TMath::Sqrt(sc->Energy()*sc->Energy() - Mass()*Mass()); |
220 |
< |
else |
221 |
< |
return Trk()->P(); |
222 |
< |
} |
223 |
< |
|
224 |
< |
//------------------------------------------------------------------------------------------------- |
225 |
< |
inline Double_t mithep::Electron::Px() const |
226 |
< |
{ |
227 |
< |
// Return px. |
228 |
< |
|
229 |
< |
return Pt()*TMath::Cos(Trk()->Phi()); |
230 |
< |
} |
231 |
< |
|
232 |
< |
//------------------------------------------------------------------------------------------------- |
233 |
< |
inline Double_t mithep::Electron::Py() const |
234 |
< |
{ |
235 |
< |
// Return py. |
236 |
< |
|
237 |
< |
return Pt()*TMath::Sin(Trk()->Phi()); |
238 |
< |
} |
239 |
< |
|
240 |
< |
//------------------------------------------------------------------------------------------------- |
241 |
< |
inline Double_t mithep::Electron::Pz() const |
242 |
< |
{ |
243 |
< |
// Return pz. |
244 |
< |
|
245 |
< |
return P()*TMath::Sin(Trk()->Lambda()); |
246 |
< |
} |
247 |
< |
|
248 |
< |
//------------------------------------------------------------------------------------------------- |
249 |
< |
inline Double_t mithep::Electron::Pt() const |
250 |
< |
{ |
251 |
< |
// Return pt. |
252 |
< |
|
253 |
< |
return TMath::Abs(P()*TMath::Cos(Trk()->Lambda())); |
333 |
> |
fMom.Set(pt,eta,phi); |
334 |
> |
ClearMom(); |
335 |
|
} |
336 |
|
#endif |