CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PFTau.h
Go to the documentation of this file.
1 #ifndef DataFormats_TauReco_PFTau_h
2 #define DataFormats_TauReco_PFTau_h
3 
4 /* class PFTau
5  * the object of this class is created by RecoTauTag/RecoTau PFRecoTauProducer EDProducer starting from the PFTauTagInfo object,
6  * is a hadronic tau-jet candidate -built from a jet made employing a particle flow technique- that analysts manipulate;
7  * authors: Simone Gennai (simone.gennai@cern.ch), Ludovic Houchu (Ludovic.Houchu@cern.ch), Evan Friis (evan.klose.friis@ucdavis.edu)
8  * created: Jun 21 2007,
9  * revised: Tue Aug 31 13:34:40 CEST 2010
10  */
20 
21 #include <iostream>
22 #include <limits>
23 
24 
25 namespace reco {
26 
27 namespace tau {
28 // Forward declaration
29 class RecoTauConstructor;
30 }
31 
32 class PFTau : public BaseTau {
33  public:
35  kNull = -1,
52  };
53 
54  PFTau();
55  PFTau(Charge q,const LorentzVector &,const Point & = Point( 0, 0, 0 ) );
56  virtual ~PFTau() {};
57  PFTau* clone() const;
58 
59  const PFJetRef& jetRef() const;
60  void setjetRef(const PFJetRef&);
61 
62  // DEPRECATED functions to access the PFTauTagInfoRef
63  const PFTauTagInfoRef& pfTauTagInfoRef() const;
65 
67  const PFCandidateRef& leadPFNeutralCand() const;
68  //Can be either the charged or the neutral one
69  const PFCandidateRef& leadPFCand() const;
70 
73  void setleadPFCand(const PFCandidateRef&);
74 
77  float leadPFChargedHadrCandsignedSipt() const;
78  void setleadPFChargedHadrCandsignedSipt(const float&);
79 
81  const PFCandidateRefVector& signalPFCands() const;
83 
87 
91 
95 
99 
103 
107 
111 
114  float isolationPFChargedHadrCandsPtSum() const;
115  void setisolationPFChargedHadrCandsPtSum(const float&);
116 
119  float isolationPFGammaCandsEtSum() const;
120  void setisolationPFGammaCandsEtSum(const float&);
121 
123  float maximumHCALPFClusterEt() const;
124  void setmaximumHCALPFClusterEt(const float&);
125 
127  const std::vector<RecoTauPiZero>& signalPiZeroCandidates() const;
128  void setsignalPiZeroCandidates(const std::vector<RecoTauPiZero>&);
130 
132  const std::vector<RecoTauPiZero>& isolationPiZeroCandidates() const;
133  void setisolationPiZeroCandidates(const std::vector<RecoTauPiZero>&);
135 
139 
140  //Electron rejection
141  float emFraction() const; // Ecal/Hcal Cluster Energy
142  float hcalTotOverPLead() const; // total Hcal Cluster E / leadPFChargedHadron P
143  float hcalMaxOverPLead() const; // max. Hcal Cluster E / leadPFChargedHadron P
144  float hcal3x3OverPLead() const; // Hcal Cluster E in R<0.184 around Ecal impact point of leading track / leadPFChargedHadron P
145  float ecalStripSumEOverPLead() const; // Simple BremsRecovery Sum E / leadPFChargedHadron P
146  float bremsRecoveryEOverPLead() const; // BremsRecovery Sum E / leadPFChargedHadron P
147  reco::TrackRef electronPreIDTrack() const; // Ref to KF track from Electron PreID
148  float electronPreIDOutput() const; // BDT output from Electron PreID
149  bool electronPreIDDecision() const; // Decision from Electron PreID
150 
151  void setemFraction(const float&);
152  void sethcalTotOverPLead(const float&);
153  void sethcalMaxOverPLead(const float&);
154  void sethcal3x3OverPLead(const float&);
155  void setecalStripSumEOverPLead(const float&);
156  void setbremsRecoveryEOverPLead(const float&);
158  void setelectronPreIDOutput(const float&);
159  void setelectronPreIDDecision(const bool&);
160 
161  // For Muon Rejection
162  bool hasMuonReference() const; // check if muon ref exists
163  float caloComp() const;
164  float segComp() const;
165  bool muonDecision() const;
166  void setCaloComp(const float&);
167  void setSegComp(const float&);
168  void setMuonDecision(const bool&);
169 
175 
179 
181  void dump(std::ostream& out=std::cout) const;
182 
183  private:
185  // check overlap with another candidate
186  virtual bool overlap(const Candidate&) const;
187 
190  // SIP
192  // Isolation variables
196 
197  // Electron rejection variables
198  float emFraction_;
205 
206  // Muon rejection variables
207  float caloComp_;
208  float segComp_;
209 
215 
216  // Signal candidates
221 
222  // Isolation candidates
227 
230 
231  // Association of gamma candidates into PiZeros (transient)
232  mutable std::vector<reco::RecoTauPiZero> signalPiZeroCandidates_;
233  mutable std::vector<reco::RecoTauPiZero> isolationPiZeroCandidates_;
234 };
235 
236 std::ostream & operator<<(std::ostream& out, const PFTau& c);
237 
238 }
239 #endif
float ecalStripSumEOverPLead_
Definition: PFTau.h:202
void setisolationPFGammaCands(const PFCandidateRefVector &)
Definition: PFTau.cc:89
bool hasMuonReference() const
Definition: PFTau.cc:179
float maximumHCALPFClusterEt() const
Et of the highest Et HCAL PFCluster.
Definition: PFTau.cc:154
PFCandidateRefVector selectedIsolationPFChargedHadrCands_
Definition: PFTau.h:223
int i
Definition: DBlmapReader.cc:9
RecoTauPiZeroRefVector signalPiZeroCandidatesRefs_
Definition: PFTau.h:228
void setMuonDecision(const bool &)
Definition: PFTau.cc:194
std::vector< reco::RecoTauPiZero > isolationPiZeroCandidates_
Definition: PFTau.h:233
void setisolationPFChargedHadrCands(const PFCandidateRefVector &)
Definition: PFTau.cc:85
void setelectronPreIDOutput(const float &)
Definition: PFTau.cc:175
float isolationPFGammaCandsEtSum() const
Definition: PFTau.cc:151
void setisolationPFNeutrHadrCands(const PFCandidateRefVector &)
Definition: PFTau.cc:87
const PFCandidateRefVector & isolationPFCands() const
PFCandidates in isolation region.
Definition: PFTau.cc:82
const PFJetRef & jetRef() const
Definition: PFTau.cc:50
float isolationPFChargedHadrCandsPtSum() const
Definition: PFTau.cc:148
void setelectronPreIDDecision(const bool &)
Definition: PFTau.cc:176
void setsignalPFNeutrHadrCands(const PFCandidateRefVector &)
Definition: PFTau.cc:78
size_t size_type
Definition: Candidate.h:31
float segComp() const
Definition: PFTau.cc:190
float hcalTotOverPLead() const
Definition: PFTau.cc:159
bool electronPreIDDecision_
Definition: PFTau.h:189
float maximumHCALPFClusterEt_
Definition: PFTau.h:195
const PFCandidateRefVector & signalPFNeutrHadrCands() const
Neutral hadrons in signal region.
Definition: PFTau.cc:77
const PFCandidateRef & leadPFNeutralCand() const
Definition: PFTau.cc:63
bool electronPreIDDecision() const
Definition: PFTau.cc:166
math::XYZTLorentzVector LorentzVector
float isolationPFChargedHadrCandsPtSum_
Definition: PFTau.h:193
float hcal3x3OverPLead() const
Definition: PFTau.cc:161
std::vector< reco::RecoTauPiZero > signalPiZeroCandidates_
Definition: PFTau.h:232
float emFraction() const
Definition: PFTau.cc:158
const PFCandidateRefVector & signalPFChargedHadrCands() const
Charged hadrons in signal region.
Definition: PFTau.cc:75
void sethcal3x3OverPLead(const float &)
Definition: PFTau.cc:171
void setisolationPFGammaCandsEtSum(const float &)
Definition: PFTau.cc:152
void setisolationPFCands(const PFCandidateRefVector &)
Definition: PFTau.cc:83
void setemFraction(const float &)
Definition: PFTau.cc:168
void setleadPFNeutralCand(const PFCandidateRef &)
Definition: PFTau.cc:67
const PFCandidateRefVector & signalPFCands() const
PFCandidates in signal region.
Definition: PFTau.cc:73
bool muonDecision() const
Definition: PFTau.cc:191
reco::PFJetRef jetRef_
Definition: PFTau.h:210
hadronicDecayMode decayMode() const
Definition: PFTau.cc:130
float segComp_
Definition: PFTau.h:208
void dump(std::ostream &out=std::cout) const
prints information on this PFTau
Definition: PFTau.cc:209
void setjetRef(const PFJetRef &)
Definition: PFTau.cc:51
CandidatePtr sourceCandidatePtr(size_type i) const
Definition: PFTau.cc:198
void setsignalPiZeroCandidates(const std::vector< RecoTauPiZero > &)
Definition: PFTau.cc:103
std::ostream & operator<<(std::ostream &, BeamSpot beam)
Definition: BeamSpot.cc:72
float leadPFChargedHadrCandsignedSipt_
Definition: PFTau.h:191
PFCandidateRefVector selectedIsolationPFNeutrHadrCands_
Definition: PFTau.h:223
PFCandidateRefVector selectedIsolationPFGammaCands_
Definition: PFTau.h:223
float caloComp() const
Definition: PFTau.cc:189
const std::vector< RecoTauPiZero > & signalPiZeroCandidates() const
Retrieve the association of signal region gamma candidates into candidate PiZeros.
Definition: PFTau.cc:92
RecoTauPiZeroRefVector isolationPiZeroCandidatesRefs_
Definition: PFTau.h:229
void setIsolationPiZeroCandidatesRefs(const RecoTauPiZeroRefVector &)
Definition: PFTau.cc:111
const PFCandidateRefVector & isolationPFGammaCands() const
Gamma candidates in isolation region.
Definition: PFTau.cc:88
void setsignalPFGammaCands(const PFCandidateRefVector &)
Definition: PFTau.cc:80
void setCaloComp(const float &)
Definition: PFTau.cc:192
math::XYZPoint Point
PFCandidateRef leadPFCand_
Definition: PFTau.h:213
void setsignalPFChargedHadrCands(const PFCandidateRefVector &)
Definition: PFTau.cc:76
void setisolationPFChargedHadrCandsPtSum(const float &)
Definition: PFTau.cc:149
void setleadPFChargedHadrCandsignedSipt(const float &)
Definition: PFTau.cc:71
const PFCandidateRef & leadPFCand() const
Definition: PFTau.cc:64
void setisolationPiZeroCandidates(const std::vector< RecoTauPiZero > &)
Definition: PFTau.cc:126
float leadPFChargedHadrCandsignedSipt() const
Definition: PFTau.cc:70
void setbremsRecoveryEOverPLead(const float &)
Definition: PFTau.cc:173
tuple out
Definition: dbtoconf.py:99
bool muonDecision_
Definition: PFTau.h:188
const std::vector< RecoTauPiZero > & isolationPiZeroCandidates() const
Retrieve the association of isolation region gamma candidates into candidate PiZeros.
Definition: PFTau.cc:115
const PFTauTagInfoRef & pfTauTagInfoRef() const
Definition: PFTau.cc:53
void sethcalMaxOverPLead(const float &)
Definition: PFTau.cc:170
virtual ~PFTau()
Definition: PFTau.h:56
void setleadPFChargedHadrCand(const PFCandidateRef &)
Definition: PFTau.cc:66
const PFCandidateRef & leadPFChargedHadrCand() const
Definition: PFTau.cc:62
PFCandidateRef leadPFChargedHadrCand_
Definition: PFTau.h:212
const PFCandidateRefVector & signalPFGammaCands() const
Gamma candidates in signal region.
Definition: PFTau.cc:79
void setSegComp(const float &)
Definition: PFTau.cc:193
PFTau * clone() const
returns a clone of the Candidate object
Definition: PFTau.cc:47
PFCandidateRef leadPFNeutralCand_
Definition: PFTau.h:213
float bremsRecoveryEOverPLead() const
Definition: PFTau.cc:163
float bremsRecoveryEOverPLead_
Definition: PFTau.h:203
float hcal3x3OverPLead_
Definition: PFTau.h:201
float hcalMaxOverPLead_
Definition: PFTau.h:200
PFTauTagInfoRef PFTauTagInfoRef_
Definition: PFTau.h:211
float electronPreIDOutput_
Definition: PFTau.h:204
hadronicDecayMode
Definition: PFTau.h:34
void setsignalPFCands(const PFCandidateRefVector &)
Definition: PFTau.cc:74
PFCandidateRefVector selectedIsolationPFCands_
Definition: PFTau.h:223
size_type numberOfSourceCandidatePtrs() const
Definition: PFTau.h:174
virtual bool overlap(const Candidate &) const
check overlap with another candidate
Definition: PFTau.cc:204
void setSignalPiZeroCandidatesRefs(const RecoTauPiZeroRefVector &)
Definition: PFTau.cc:107
void setmaximumHCALPFClusterEt(const float &)
Definition: PFTau.cc:155
void setecalStripSumEOverPLead(const float &)
Definition: PFTau.cc:172
tuple cout
Definition: gather_cfg.py:121
void sethcalTotOverPLead(const float &)
Definition: PFTau.cc:169
PFCandidateRefVector selectedSignalPFChargedHadrCands_
Definition: PFTau.h:217
float emFraction_
Definition: PFTau.h:198
PFCandidateRefVector selectedSignalPFCands_
Definition: PFTau.h:217
void setelectronPreIDTrack(const reco::TrackRef &)
Definition: PFTau.cc:174
float hcalMaxOverPLead() const
Definition: PFTau.cc:160
float electronPreIDOutput() const
Definition: PFTau.cc:165
reco::TrackRef electronPreIDTrack() const
Definition: PFTau.cc:164
PFCandidateRefVector selectedSignalPFNeutrHadrCands_
Definition: PFTau.h:217
void setleadPFCand(const PFCandidateRef &)
Definition: PFTau.cc:68
reco::TrackRef electronPreIDTrack_
Definition: PFTau.h:214
PFTau()
Definition: PFTau.cc:8
int Charge
electric charge type
Definition: LeafCandidate.h:23
float isolationPFGammaCandsEtSum_
Definition: PFTau.h:194
float caloComp_
Definition: PFTau.h:207
float ecalStripSumEOverPLead() const
Definition: PFTau.cc:162
const PFCandidateRefVector & isolationPFNeutrHadrCands() const
Definition: PFTau.cc:86
math::XYZPoint Point
point in the space
Definition: LeafCandidate.h:29
PFCandidateRefVector selectedSignalPFGammaCands_
Definition: PFTau.h:217
const PFCandidateRefVector & isolationPFChargedHadrCands() const
Charged candidates in isolation region.
Definition: PFTau.cc:84
void setpfTauTagInfoRef(const PFTauTagInfoRef)
Definition: PFTau.cc:60
float hcalTotOverPLead_
Definition: PFTau.h:199