Particle reconstructed by the particle flow algorithm. More...
#include <PFCandidate.h>
Public Types | |
typedef edm::RefVector < reco::PFBlockCollection > | Blocks |
typedef std::pair < reco::PFBlockRef, unsigned > | ElementInBlock |
return indices of elements used in the block | |
typedef std::vector< unsigned > | Elements |
typedef std::vector < ElementInBlock > | ElementsInBlocks |
enum | Flags { NORMAL = 0, E_PHI_SMODULES, E_ETA_0, E_ETA_MODULES, E_BARREL_ENDCAP, E_PRESHOWER_EDGE, E_PRESHOWER, E_ENDCAP_EDGE, H_ETA_0, H_BARREL_ENDCAP, H_ENDCAP_VFCAL, H_VFCAL_EDGE, T_TO_DISP, T_FROM_DISP, T_FROM_V0, T_FROM_GAMMACONV, GAMMA_TO_GAMMACONV } |
enum | ParticleType { X = 0, h, e, mu, gamma, h0, h_HF, egamma_HF } |
particle types More... | |
enum | PFVertexType { kCandVertex = 0, kTrkVertex = 1, kComMuonVertex = 2, kSAMuonVertex = 3, kTrkMuonVertex = 4, kGSFVertex = 5 } |
Public Member Functions | |
void | addElementInBlock (const reco::PFBlockRef &blockref, unsigned elementIndex) |
add an element to the current PFCandidate | |
virtual PFCandidate * | clone () const |
return a clone | |
reco::ConversionRef | conversionRef () const |
return a reference to the original conversion | |
double | deltaP () const |
uncertainty on 3-momentum | |
reco::PFDisplacedVertexRef | displacedVertexRef (Flags type) const |
double | ecalEnergy () const |
return corrected Ecal energy | |
reco::PFCandidateElectronExtraRef | electronExtraRef () const |
return a reference to the electron extra | |
const ElementsInBlocks & | elementsInBlocks () const |
bool | flag (Flags theFlag) const |
return a given flag | |
reco::GsfElectronRef | gsfElectronRef () const |
return a reference to the corresponding GsfElectron if any | |
reco::GsfTrackRef | gsfTrackRef () const |
double | hcalEnergy () const |
return corrected Hcal energy | |
double | hoEnergy () const |
return corrected Hcal energy | |
reco::MuonRef | muonRef () const |
float | mva_e_mu () const |
mva for electron-muon discrimination | |
float | mva_e_pi () const |
mva for electron-pion discrimination | |
float | mva_gamma_nh () const |
mva for neutral hadron - gamma discrimination | |
float | mva_nothing_gamma () const |
mva for gamma detection | |
float | mva_nothing_nh () const |
mva for neutral hadron detection | |
float | mva_pi_mu () const |
mva for pi-muon discrimination | |
size_t | numberOfSourceCandidatePtrs () const |
virtual ParticleType | particleId () const |
PFCandidate () | |
default constructor | |
PFCandidate (const PFCandidatePtr &sourcePtr) | |
constructor from a reference (keeps track of source relationship) | |
PFCandidate (Charge q, const LorentzVector &p4, ParticleType particleId) | |
reco::PFCandidatePhotonExtraRef | photonExtraRef () const |
return a reference to the photon extra | |
reco::PhotonRef | photonRef () const |
return a reference to the corresponding Photon if any | |
const math::XYZPointF & | positionAtECALEntrance () const |
double | pS1Energy () const |
return corrected PS1 energy | |
double | pS2Energy () const |
return corrected PS2 energy | |
double | rawEcalEnergy () const |
return corrected Ecal energy | |
double | rawHcalEnergy () const |
return raw Hcal energy | |
double | rawHoEnergy () const |
return raw Hcal energy | |
void | rescaleMomentum (double rescaleFactor) |
particle momentum *= rescaleFactor | |
void | set_mva_e_mu (float mva) |
set mva for electron-muon discrimination | |
void | set_mva_e_pi (float mva) |
void | set_mva_gamma_nh (float mva) |
set mva for neutral hadron - gamma discrimination | |
void | set_mva_nothing_gamma (float mva) |
set mva for gamma detection | |
void | set_mva_nothing_nh (float mva) |
set mva for neutral hadron detection | |
void | set_mva_pi_mu (float mva) |
set mva for pi-muon discrimination | |
void | setConversionRef (const reco::ConversionRef &ref) |
set ref to original reco conversion | |
void | setDeltaP (double dp) |
set uncertainty on momentum | |
void | setDisplacedVertexRef (const reco::PFDisplacedVertexRef &ref, Flags flag) |
set displaced vertex reference | |
void | setEcalEnergy (float eeRaw, float eeCorr) |
set corrected Ecal energy | |
void | setFlag (Flags theFlag, bool value) |
set a given flag | |
void | setGsfElectronRef (const reco::GsfElectronRef &ref) |
set GsfElectronRef | |
void | setGsfTrackRef (const reco::GsfTrackRef &ref) |
set gsftrack reference | |
void | setHcalEnergy (float ehRaw, float ehCorr) |
set corrected Hcal energy | |
void | setHoEnergy (float eoRaw, float eoCorr) |
set corrected Hcal energy | |
void | setMuonRef (const reco::MuonRef &ref) |
set muon reference | |
void | setParticleType (ParticleType type) |
set Particle Type | |
void | setPFElectronExtraRef (const reco::PFCandidateElectronExtraRef &ref) |
set the PF Electron Extra Ref | |
void | setPFPhotonExtraRef (const reco::PFCandidatePhotonExtraRef &ref) |
set the PF Photon Extra Ref | |
void | setPhotonRef (const reco::PhotonRef &phRef) |
set ref to the corresponding reco::Photon if any | |
void | setPositionAtECALEntrance (const math::XYZPointF &pos) |
set position at ECAL entrance | |
void | setPs1Energy (float e1) |
set corrected PS1 energy | |
void | setPs2Energy (float e2) |
set corrected PS2 energy | |
void | setSourceCandidatePtr (const PFCandidatePtr &ptr) |
void | setSuperClusterRef (const reco::SuperClusterRef &scRef) |
void | setTrackRef (const reco::TrackRef &ref) |
set track reference | |
void | setV0Ref (const reco::VertexCompositeCandidateRef &ref) |
set ref to original reco conversion | |
virtual void | setVertex (math::XYZPoint p) |
void | setVertexSource (PFVertexType vt) |
CandidatePtr | sourceCandidatePtr (size_type i) const |
reco::SuperClusterRef | superClusterRef () const |
return a reference to the corresponding SuperCluster if any | |
reco::TrackRef | trackRef () const |
ParticleType | translatePdgIdToType (int pdgid) const |
int | translateTypeToPdgId (ParticleType type) const |
reco::VertexCompositeCandidateRef | v0Ref () const |
return a reference to the original conversion | |
virtual const Point & | vertex () const |
vertex position | |
virtual double | vx () const |
x coordinate of vertex position | |
virtual double | vy () const |
y coordinate of vertex position | |
virtual double | vz () const |
z coordinate of vertex position | |
virtual | ~PFCandidate () |
destructor | |
Static Public Attributes | |
static const float | bigMva_ = -999. |
Private Member Functions | |
bool | flag (unsigned shift, unsigned flag) const |
bool | getRefInfo (unsigned int iMask, unsigned int iBit, edm::ProductID &oProdID, size_t &oIndex, size_t &aIndex) const |
virtual bool | overlap (const Candidate &) const |
Polymorphic overlap. | |
void | setFlag (unsigned shift, unsigned flag, bool value) |
void | storeRefInfo (unsigned int iMask, unsigned int iBit, bool iIsValid, const edm::RefCore &iCore, size_t iKey, const edm::EDProductGetter *) |
Private Attributes | |
Blocks | blocksStorage_ |
float | deltaP_ |
uncertainty on 3-momentum | |
float | ecalERatio_ |
corrected ECAL energy ratio (corrected/raw) | |
ElementsInBlocks | elementsInBlocks_ |
Elements | elementsStorage_ |
unsigned | flags_ |
all flags, packed (ecal regional, hcal regional, tracking) | |
const edm::EDProductGetter * | getter_ |
float | hcalERatio_ |
corrected HCAL energy ratio (corrected/raw) | |
float | hoERatio_ |
corrected HO energy ratio (corrected/raw) | |
float | mva_e_mu_ |
mva for electron-muon discrimination | |
float | mva_e_pi_ |
mva for electron-pion discrimination | |
float | mva_gamma_nh_ |
mva for neutral hadron - gamma discrimination | |
float | mva_nothing_gamma_ |
mva for gamma detection | |
float | mva_nothing_nh_ |
mva for neutral hadron detection | |
float | mva_pi_mu_ |
mva for pi-muon discrimination | |
math::XYZPointF | positionAtECALEntrance_ |
position at ECAL entrance, from the PFRecTrack | |
float | ps1Energy_ |
corrected PS1 energy | |
float | ps2Energy_ |
corrected PS2 energy | |
float | rawEcalEnergy_ |
raw ECAL energy | |
float | rawHcalEnergy_ |
raw HCAL energy | |
float | rawHoEnergy_ |
raw HO energy | |
std::vector< const void * > | refsCollectionCache_ |
std::vector< unsigned long long > | refsInfo_ |
PFCandidatePtr | sourcePtr_ |
reference to the source PFCandidate, if any | |
unsigned short | storedRefsBitPattern_ |
PFVertexType | vertexType_ |
Friends | |
std::ostream & | operator<< (std::ostream &out, const PFCandidate &c) |
Particle reconstructed by the particle flow algorithm.
particle candidate from particle flow
Definition at line 33 of file PFCandidate.h.
Definition at line 339 of file PFCandidate.h.
typedef std::pair<reco::PFBlockRef, unsigned> reco::PFCandidate::ElementInBlock |
return indices of elements used in the block
return elements return elements in blocks
Definition at line 336 of file PFCandidate.h.
typedef std::vector<unsigned> reco::PFCandidate::Elements |
Definition at line 340 of file PFCandidate.h.
typedef std::vector< ElementInBlock > reco::PFCandidate::ElementsInBlocks |
Definition at line 337 of file PFCandidate.h.
Definition at line 49 of file PFCandidate.h.
particle types
Definition at line 38 of file PFCandidate.h.
Definition at line 70 of file PFCandidate.h.
{ kCandVertex=0, kTrkVertex=1, kComMuonVertex=2, kSAMuonVertex=3, kTrkMuonVertex=4, kGSFVertex=5 };
PFCandidate::PFCandidate | ( | ) |
default constructor
Definition at line 30 of file PFCandidate.cc.
References refsInfo_, reco::LeafCandidate::setPdgId(), translateTypeToPdgId(), and X.
Referenced by clone().
: ecalERatio_(1.), hcalERatio_(1.), hoERatio_(1.), rawEcalEnergy_(0.), rawHcalEnergy_(0.), rawHoEnergy_(0.), ps1Energy_(0.), ps2Energy_(0.), flags_(0), deltaP_(0.), vertexType_(kCandVertex), mva_e_pi_(bigMva_), mva_e_mu_(bigMva_), mva_pi_mu_(bigMva_), mva_nothing_gamma_(bigMva_), mva_nothing_nh_(bigMva_), mva_gamma_nh_(bigMva_), getter_(0),storedRefsBitPattern_(0) { setPdgId( translateTypeToPdgId( X ) ); refsInfo_.reserve(3); }
PFCandidate::PFCandidate | ( | const PFCandidatePtr & | sourcePtr | ) |
constructor from a reference (keeps track of source relationship)
Definition at line 56 of file PFCandidate.cc.
References sourcePtr_.
{ *this = *sourcePtr; sourcePtr_ = sourcePtr; }
PFCandidate::PFCandidate | ( | Charge | q, |
const LorentzVector & | p4, | ||
ParticleType | particleId | ||
) |
Definition at line 62 of file PFCandidate.cc.
References blocksStorage_, e, elementsStorage_, Exception, h, mu, refsInfo_, edm::RefVector< C, T, F >::reserve(), reco::LeafCandidate::setPdgId(), and translateTypeToPdgId().
: CompositeCandidate(charge, p4), ecalERatio_(1.), hcalERatio_(1.), hoERatio_(1.), rawEcalEnergy_(0.), rawHcalEnergy_(0.), rawHoEnergy_(0.), ps1Energy_(0.), ps2Energy_(0.), flags_(0), deltaP_(0.), vertexType_(kCandVertex), mva_e_pi_(bigMva_), mva_e_mu_(bigMva_), mva_pi_mu_(bigMva_), mva_nothing_gamma_(bigMva_), mva_nothing_nh_(bigMva_), mva_gamma_nh_(bigMva_), getter_(0),storedRefsBitPattern_(0) { refsInfo_.reserve(3); blocksStorage_.reserve(10); elementsStorage_.reserve(10); // proceed with various consistency checks // charged candidate: track ref and charge must be non null if( partId == h || partId == e || partId == mu ) { if( charge == 0 ) { string err; err+="Attempt to construct a charged PFCandidate with a zero charge"; throw cms::Exception("InconsistentValue", err.c_str() ); } } else { if( charge ) { string err; err += "Attempt to construct a neutral PFCandidate "; err += "with a non-zero charge"; throw cms::Exception("InconsistentValue", err.c_str() ); } } setPdgId( translateTypeToPdgId( partId ) ); }
virtual reco::PFCandidate::~PFCandidate | ( | ) | [inline, virtual] |
void PFCandidate::addElementInBlock | ( | const reco::PFBlockRef & | blockref, |
unsigned | elementIndex | ||
) |
add an element to the current PFCandidate
add element in block
Definition at line 123 of file PFCandidate.cc.
References blocksStorage_, elementsStorage_, edm::Ref< C, T, F >::id(), edm::RefVector< C, T, F >::push_back(), and edm::RefVector< C, T, F >::size().
Referenced by PFPhotonAlgo::RunPFPhoton(), and PFElectronAlgo::SetCandidates().
{ //elementsInBlocks_.push_back( make_pair(blockref.key(), elementIndex) ); if (blocksStorage_.size()==0) blocksStorage_ =Blocks(blockref.id()); blocksStorage_.push_back(blockref); elementsStorage_.push_back(elementIndex); }
PFCandidate * PFCandidate::clone | ( | void | ) | const [virtual] |
return a clone
Reimplemented from reco::CompositeCandidate.
Reimplemented in reco::IsolatedPFCandidate, reco::PileUpPFCandidate, and pat::PFParticle.
Definition at line 118 of file PFCandidate.cc.
References PFCandidate().
{ return new PFCandidate( * this ); }
reco::ConversionRef PFCandidate::conversionRef | ( | ) | const |
return a reference to the original conversion
Definition at line 459 of file PFCandidate.cc.
References GETREF, kRefConversionBit, and kRefConversionMask.
double reco::PFCandidate::deltaP | ( | ) | const [inline] |
uncertainty on 3-momentum
Definition at line 260 of file PFCandidate.h.
References deltaP_.
Referenced by PFElectronTranslator::createGsfElectrons().
{ return deltaP_;}
reco::PFDisplacedVertexRef PFCandidate::displacedVertexRef | ( | Flags | type | ) | const |
return a reference to the corresponding displaced vertex, otherwise, return a null reference
Definition at line 424 of file PFCandidate.cc.
References GETREF, kRefDisplacedVertexDauBit, kRefDisplacedVertexDauMask, kRefDisplacedVertexMotBit, kRefDisplacedVertexMotMask, T_FROM_DISP, and T_TO_DISP.
Referenced by PFCandConnector::analyseNuclearWPrim(), PFCandConnector::isPrimaryNucl(), and PFCandConnector::isSecondaryNucl().
{ if (type == T_TO_DISP) { GETREF(reco::PFDisplacedVertex, kRefDisplacedVertexDauMask, kRefDisplacedVertexDauBit); } else if (type == T_FROM_DISP) { GETREF(reco::PFDisplacedVertex, kRefDisplacedVertexMotMask, kRefDisplacedVertexMotBit); } return reco::PFDisplacedVertexRef(); }
double reco::PFCandidate::ecalEnergy | ( | ) | const [inline] |
return corrected Ecal energy
Definition at line 189 of file PFCandidate.h.
References ecalERatio_, and rawEcalEnergy_.
Referenced by PFCandConnector::analyseNuclearWPrim(), and PFCandidateBenchmark::fillOne().
{ return ecalERatio_*rawEcalEnergy_;}
reco::PFCandidateElectronExtraRef PFCandidate::electronExtraRef | ( | ) | const |
return a reference to the electron extra
Definition at line 489 of file PFCandidate.cc.
References GETREF, kRefPFElectronExtraBit, and kRefPFElectronExtraMask.
Referenced by PFElectronTranslator::createGsfElectrons(), and PFElectronTranslator::produce().
const ElementsInBlocks& reco::PFCandidate::elementsInBlocks | ( | ) | const [inline] |
Definition at line 342 of file PFCandidate.h.
References blocksStorage_, elementsInBlocks_, elementsStorage_, and edm::RefVector< C, T, F >::size().
Referenced by PFElectronTranslator::correspondingDaughterCandidate(), PFPhotonTranslator::correspondingDaughterCandidate(), PFPhotonAlgo::EvaluateGCorrMVA(), PFPhotonAlgo::EvaluateResMVA(), PFCandidateBenchmark::fillOne(), reco::modules::HICaloCompatibleTrackSelector::matchPFCandToTrack(), PFRootEventManager::mcTruthMatching(), PFAlgo::postMuonCleaning(), PFCandidateChecker::printElementsInBlocks(), PFAlgoTestBenchElectrons::processBlock(), PFPhotonTranslator::produce(), and PFElectronTranslator::produce().
{ if (elementsInBlocks_.size()!=blocksStorage_.size()) { elementsInBlocks_.resize(blocksStorage_.size()); for(unsigned int icopy=0;icopy!=blocksStorage_.size();++icopy) elementsInBlocks_[icopy]=std::make_pair(blocksStorage_[icopy],elementsStorage_[icopy]); } return elementsInBlocks_; }
bool reco::PFCandidate::flag | ( | unsigned | shift, |
unsigned | flag | ||
) | const [private] |
bool PFCandidate::flag | ( | Flags | theFlag | ) | const |
return a given flag
Definition at line 205 of file PFCandidate.cc.
References flags_.
Referenced by PFCandConnector::isPrimaryNucl(), PFCandConnector::isSecondaryNucl(), setConversionRef(), and setDisplacedVertexRef().
{ return (flags_>>theFlag) & 1; }
bool PFCandidate::getRefInfo | ( | unsigned int | iMask, |
unsigned int | iBit, | ||
edm::ProductID & | oProdID, | ||
size_t & | oIndex, | ||
size_t & | aIndex | ||
) | const [private] |
Definition at line 307 of file PFCandidate.cc.
References refsInfo_, s_refsBefore, and storedRefsBitPattern_.
{ if( 0 == (iBit & storedRefsBitPattern_) ) { return false; } aIndex = s_refsBefore[storedRefsBitPattern_ & iMask]; unsigned long long bitPacked = refsInfo_[aIndex]; oIndex = bitPacked & 0xFFFFFFFFULL; //low 32 bits are the index unsigned short productIndex = (bitPacked & 0x0000FFFF00000000ULL)>>32; unsigned short processIndex = (bitPacked & 0xFFFF000000000000ULL)>>48; oProductID = edm::ProductID(processIndex,productIndex); return true; }
reco::GsfElectronRef PFCandidate::gsfElectronRef | ( | ) | const |
return a reference to the corresponding GsfElectron if any
Definition at line 479 of file PFCandidate.cc.
References GETREF, kRefGsfElectronBit, and kRefGsfElectronMask.
reco::GsfTrackRef PFCandidate::gsfTrackRef | ( | ) | const |
return a reference to the corresponding GSF track, if an electron. otherwise, return a null reference
Definition at line 376 of file PFCandidate.cc.
References GETREF, kRefGsfTrackBit, and kRefGsfTrackMask.
Referenced by PFElectronTranslator::fillMVAValueMap(), LeptonRecoSkim::filter(), reco::tau::getTrack(), PFLinker::produce(), PFElectronTranslator::produce(), and vertex().
double reco::PFCandidate::hcalEnergy | ( | ) | const [inline] |
return corrected Hcal energy
Definition at line 199 of file PFCandidate.h.
References hcalERatio_, and rawHcalEnergy_.
Referenced by PFCandConnector::analyseNuclearWPrim(), and PFCandidateBenchmark::fillOne().
{ return hcalERatio_*rawHcalEnergy_;}
double reco::PFCandidate::hoEnergy | ( | ) | const [inline] |
return corrected Hcal energy
Definition at line 209 of file PFCandidate.h.
References hoERatio_, and rawHoEnergy_.
{ return hoERatio_*rawHoEnergy_;}
reco::MuonRef PFCandidate::muonRef | ( | ) | const |
return a reference to the corresponding muon, if a muon. otherwise, return a null reference
Definition at line 355 of file PFCandidate.cc.
References GETREF, kRefMuonBit, and kRefMuonMask.
Referenced by PFAlgo::postMuonCleaning(), PFLinker::produce(), pat::PATMuonProducer::produce(), MuonProducer::produce(), and vertex().
{ GETREF(reco::Muon, kRefMuonMask, kRefMuonBit); }
float reco::PFCandidate::mva_e_mu | ( | ) | const [inline] |
mva for electron-muon discrimination
Definition at line 281 of file PFCandidate.h.
References mva_e_mu_.
{ return mva_e_mu_;}
float reco::PFCandidate::mva_e_pi | ( | ) | const [inline] |
mva for electron-pion discrimination
Definition at line 274 of file PFCandidate.h.
References mva_e_pi_.
Referenced by PFElectronTranslator::createGsfElectrons(), PFElectronTranslator::fillMVAValueMap(), PFCandidateBenchmark::fillOne(), and PFElectronTranslator::produce().
{ return mva_e_pi_;}
float reco::PFCandidate::mva_gamma_nh | ( | ) | const [inline] |
mva for neutral hadron - gamma discrimination
Definition at line 307 of file PFCandidate.h.
References mva_gamma_nh_.
{ return mva_gamma_nh_;}
float reco::PFCandidate::mva_nothing_gamma | ( | ) | const [inline] |
mva for gamma detection
Definition at line 294 of file PFCandidate.h.
References mva_nothing_gamma_.
Referenced by PFLinker::produce(), and PFPhotonTranslator::produce().
{ return mva_nothing_gamma_;}
float reco::PFCandidate::mva_nothing_nh | ( | ) | const [inline] |
mva for neutral hadron detection
Definition at line 300 of file PFCandidate.h.
References mva_nothing_nh_.
{ return mva_nothing_nh_;}
float reco::PFCandidate::mva_pi_mu | ( | ) | const [inline] |
mva for pi-muon discrimination
Definition at line 287 of file PFCandidate.h.
References mva_pi_mu_.
{ return mva_pi_mu_;}
size_t reco::PFCandidate::numberOfSourceCandidatePtrs | ( | ) | const [inline, virtual] |
return the number of source Candidates ( the candidates used to construct this Candidate)
Reimplemented from reco::LeafCandidate.
Definition at line 113 of file PFCandidate.h.
{
return 1;
}
bool PFCandidate::overlap | ( | const Candidate & | other | ) | const [private, virtual] |
Polymorphic overlap.
Reimplemented from reco::CompositeCandidate.
Definition at line 171 of file PFCandidate.cc.
References i, edm::Ptr< T >::isNonnull(), edm::Ptr< T >::isNull(), n, reco::Candidate::numberOfSourceCandidatePtrs(), reco::Candidate::sourceCandidatePtr(), sourceCandidatePtr(), and sourcePtr_.
{ CandidatePtr myPtr = sourceCandidatePtr(0); if (myPtr.isNull()) return false; for (size_t i = 0, n = other.numberOfSourceCandidatePtrs(); i < n; ++i) { CandidatePtr otherPtr = other.sourceCandidatePtr(i); if ((otherPtr == myPtr) || (sourcePtr_.isNonnull() && otherPtr.isNonnull() && sourcePtr_->overlap(*otherPtr))) { return true; } } return false; }
virtual ParticleType reco::PFCandidate::particleId | ( | ) | const [inline, virtual] |
particle identification code
Definition at line 324 of file PFCandidate.h.
References reco::LeafCandidate::pdgId_, and translatePdgIdToType().
Referenced by PFSpecificAlgo::addInfo(), PFTester::analyze(), metsig::SignAlgoResolutions::evalPF(), PFElectronTranslator::fillMVAValueMap(), PFCandidateBenchmark::fillOne(), PFRootEventManager::fillOutEventWithPFCandidates(), LeptonRecoSkim::filter(), PFRootEventManager::highPtPFCandidate(), reco::tau::RecoTauIsolationMasking::inCone(), JetMaker::makeSpecific(), reco::tau::qcuts::mapAndCutByType(), reco::modules::HICaloCompatibleTrackSelector::matchPFCandToTrack(), PFAlgo::postCleaning(), PFAlgo::postMuonCleaning(), PFPileUpAlgo::process(), pf2pat::PFMETAlgo::produce(), PFLinker::produce(), PFPhotonTranslator::produce(), Type0PFMETcorrInputProducer::produce(), PFElectronTranslator::produce(), reco::tau::RecoTauIsolationMasking::resolution(), pf2pat::PFIsoDepositAlgo::sameParticle(), setConversionRef(), setDisplacedVertexRef(), setPhotonRef(), setSuperClusterRef(), setTrackRef(), and PFRootEventManager::tauBenchmark().
{ return translatePdgIdToType(pdgId_);}
reco::PFCandidatePhotonExtraRef PFCandidate::photonExtraRef | ( | ) | const |
return a reference to the photon extra
Definition at line 498 of file PFCandidate.cc.
References GETREF, kRefPFPhotonExtraBit, and kRefPFPhotonExtraMask.
Referenced by PFPhotonTranslator::produce().
reco::PhotonRef PFCandidate::photonRef | ( | ) | const |
return a reference to the corresponding Photon if any
Definition at line 494 of file PFCandidate.cc.
References GETREF, kRefPhotonBit, and kRefPhotonMask.
const math::XYZPointF& reco::PFCandidate::positionAtECALEntrance | ( | ) | const [inline] |
Definition at line 318 of file PFCandidate.h.
References positionAtECALEntrance_.
Referenced by reco::tau::RecoTauIsolationMasking::inCone().
{ return positionAtECALEntrance_; }
double reco::PFCandidate::pS1Energy | ( | ) | const [inline] |
return corrected PS1 energy
Definition at line 239 of file PFCandidate.h.
References ps1Energy_.
{ return ps1Energy_;}
double reco::PFCandidate::pS2Energy | ( | ) | const [inline] |
return corrected PS2 energy
Definition at line 245 of file PFCandidate.h.
References ps2Energy_.
{ return ps2Energy_;}
double reco::PFCandidate::rawEcalEnergy | ( | ) | const [inline] |
return corrected Ecal energy
Definition at line 192 of file PFCandidate.h.
References rawEcalEnergy_.
Referenced by PFElectronTranslator::createBasicCluster(), and PFAlgo::postMuonCleaning().
{ return rawEcalEnergy_;}
double reco::PFCandidate::rawHcalEnergy | ( | ) | const [inline] |
return raw Hcal energy
Definition at line 202 of file PFCandidate.h.
References rawHcalEnergy_.
Referenced by PFAlgo::postMuonCleaning().
{ return rawHcalEnergy_;}
double reco::PFCandidate::rawHoEnergy | ( | ) | const [inline] |
return raw Hcal energy
Definition at line 212 of file PFCandidate.h.
References rawHoEnergy_.
{ return rawHoEnergy_;}
void PFCandidate::rescaleMomentum | ( | double | rescaleFactor | ) |
particle momentum *= rescaleFactor
Definition at line 188 of file PFCandidate.cc.
References reco::LeafCandidate::p4(), and reco::LeafCandidate::setP4().
{ LorentzVector rescaledp4 = p4(); rescaledp4 *= rescaleFactor; setP4( rescaledp4 ); }
void reco::PFCandidate::set_mva_e_mu | ( | float | mva | ) | [inline] |
set mva for electron-muon discrimination
Definition at line 278 of file PFCandidate.h.
References mva_e_mu_.
{ mva_e_mu_=mva;}
void reco::PFCandidate::set_mva_e_pi | ( | float | mva | ) | [inline] |
set mva for electron-pion discrimination. For charged particles, this variable is set to 0 for particles that are not preided to 1 otherwise For neutral particles, it is set to the default value
Definition at line 271 of file PFCandidate.h.
References mva_e_pi_.
Referenced by PFElectronAlgo::SetCandidates().
{ mva_e_pi_=mva;}
void reco::PFCandidate::set_mva_gamma_nh | ( | float | mva | ) | [inline] |
set mva for neutral hadron - gamma discrimination
Definition at line 304 of file PFCandidate.h.
References mva_gamma_nh_.
{ mva_gamma_nh_=mva;}
void reco::PFCandidate::set_mva_nothing_gamma | ( | float | mva | ) | [inline] |
set mva for gamma detection
Definition at line 291 of file PFCandidate.h.
References mva_nothing_gamma_.
Referenced by PFPhotonAlgo::RunPFPhoton().
{ mva_nothing_gamma_=mva;}
void reco::PFCandidate::set_mva_nothing_nh | ( | float | mva | ) | [inline] |
set mva for neutral hadron detection
Definition at line 297 of file PFCandidate.h.
References mva_nothing_nh_.
{ mva_nothing_nh_=mva;}
void reco::PFCandidate::set_mva_pi_mu | ( | float | mva | ) | [inline] |
set mva for pi-muon discrimination
Definition at line 284 of file PFCandidate.h.
References mva_pi_mu_.
{ mva_pi_mu_=mva;}
void PFCandidate::setConversionRef | ( | const reco::ConversionRef & | ref | ) |
set ref to original reco conversion
Definition at line 435 of file PFCandidate.cc.
References Exception, flag(), gamma, GAMMA_TO_GAMMACONV, edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefConversionBit, kRefConversionMask, particleId(), edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
{ if( particleId() != gamma ) { string err; err += "PFCandidate::setConversionRef: this is not a (converted) photon ! particleId_="; char num[4]; sprintf( num, "%d", particleId()); err += num; throw cms::Exception("InconsistentReference", err.c_str() ); } else if( !flag( GAMMA_TO_GAMMACONV ) ) { string err; err += "PFCandidate::setConversionRef: particule flag is not GAMMA_TO_GAMMACONV"; throw cms::Exception("InconsistentReference", err.c_str() ); } storeRefInfo(kRefConversionMask, kRefConversionBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void reco::PFCandidate::setDeltaP | ( | double | dp | ) | [inline] |
set uncertainty on momentum
Definition at line 257 of file PFCandidate.h.
References deltaP_.
{deltaP_ = dp;}
void PFCandidate::setDisplacedVertexRef | ( | const reco::PFDisplacedVertexRef & | ref, |
Flags | flag | ||
) |
set displaced vertex reference
Definition at line 380 of file PFCandidate.cc.
References Exception, flag(), h, edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefDisplacedVertexDauBit, kRefDisplacedVertexDauMask, kRefDisplacedVertexMotBit, kRefDisplacedVertexMotMask, particleId(), edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), storeRefInfo(), T_FROM_DISP, and T_TO_DISP.
{ if( particleId() != h ) { string err; err += "PFCandidate::setDisplacedVertexRef: this is not a hadron! particleId_="; char num[4]; sprintf( num, "%d", particleId()); err += num; throw cms::Exception("InconsistentReference", err.c_str() ); } else if( !flag( T_FROM_DISP ) && !flag( T_TO_DISP ) ) { string err; err += "PFCandidate::setDisplacedVertexRef: particule flag is neither T_FROM_DISP nor T_TO_DISP"; throw cms::Exception("InconsistentReference", err.c_str() ); } if (type == T_TO_DISP && flag( T_TO_DISP )) storeRefInfo(kRefDisplacedVertexDauMask, kRefDisplacedVertexDauBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); else if (type == T_FROM_DISP && flag( T_FROM_DISP )) storeRefInfo(kRefDisplacedVertexMotMask, kRefDisplacedVertexMotBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); else if ( (type == T_FROM_DISP && !flag( T_FROM_DISP )) || (type == T_TO_DISP && !flag( T_TO_DISP )) ){ string err; err += "PFCandidate::setDisplacedVertexRef: particule flag is not switched on"; throw cms::Exception("InconsistentReference", err.c_str() ); } }
void reco::PFCandidate::setEcalEnergy | ( | float | eeRaw, |
float | eeCorr | ||
) | [inline] |
set corrected Ecal energy
Definition at line 185 of file PFCandidate.h.
References abs, ecalERatio_, and rawEcalEnergy_.
Referenced by PFAlgoTestBenchElectrons::processBlock(), PFPhotonAlgo::RunPFPhoton(), and PFElectronAlgo::SetCandidates().
{ rawEcalEnergy_ = eeRaw; ecalERatio_= std::abs(eeRaw)<1.e-6 ? 1.0 : eeCorr/eeRaw;}
void reco::PFCandidate::setFlag | ( | unsigned | shift, |
unsigned | flag, | ||
bool | value | ||
) | [private] |
void PFCandidate::setFlag | ( | Flags | theFlag, |
bool | value | ||
) |
set a given flag
Definition at line 195 of file PFCandidate.cc.
References flags_.
Referenced by PFPhotonAlgo::RunPFPhoton().
void PFCandidate::setGsfElectronRef | ( | const reco::GsfElectronRef & | ref | ) |
set GsfElectronRef
Definition at line 474 of file PFCandidate.cc.
References edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefGsfElectronBit, kRefGsfElectronMask, edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
Referenced by PFLinker::produce().
{ storeRefInfo(kRefGsfElectronMask, kRefGsfElectronBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void PFCandidate::setGsfTrackRef | ( | const reco::GsfTrackRef & | ref | ) |
set gsftrack reference
Definition at line 359 of file PFCandidate.cc.
References edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefGsfTrackBit, kRefGsfTrackMask, edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
Referenced by PFElectronAlgo::SetCandidates().
{ // Removed by F. Beaudette. Would like to be able to save the GsfTrackRef even for charged pions // if( particleId() != e ) { // string err; // err += "PFCandidate::setGsfTrackRef: this is not an electron ! particleId_="; // char num[4]; // sprintf( num, "%d", particleId()); // err += num; // // throw cms::Exception("InconsistentReference", // err.c_str() ); // } storeRefInfo(kRefGsfTrackMask, kRefGsfTrackBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void reco::PFCandidate::setHcalEnergy | ( | float | ehRaw, |
float | ehCorr | ||
) | [inline] |
set corrected Hcal energy
Definition at line 195 of file PFCandidate.h.
References abs, hcalERatio_, and rawHcalEnergy_.
Referenced by PFAlgoTestBenchElectrons::processBlock(), PFPhotonAlgo::RunPFPhoton(), and PFElectronAlgo::SetCandidates().
{ rawHcalEnergy_ = ehRaw; hcalERatio_= std::abs(ehRaw)<1.e-6 ? 1.0 : ehCorr/ehRaw;}
void reco::PFCandidate::setHoEnergy | ( | float | eoRaw, |
float | eoCorr | ||
) | [inline] |
set corrected Hcal energy
Definition at line 205 of file PFCandidate.h.
References abs, hoERatio_, and rawHoEnergy_.
Referenced by PFAlgoTestBenchElectrons::processBlock().
{ rawHoEnergy_ = eoRaw; hoERatio_= std::abs(eoRaw)<1.e-6 ? 1.0 : eoCorr/eoRaw;}
void PFCandidate::setMuonRef | ( | const reco::MuonRef & | ref | ) |
set muon reference
Definition at line 342 of file PFCandidate.cc.
References Exception, edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefMuonBit, kRefMuonMask, edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), storeRefInfo(), and trackRef().
Referenced by PFLinker::produce().
{ if( trackRef() != iRef->track() ) { string err; err += "PFCandidate::setMuonRef: inconsistent track references!"; throw cms::Exception("InconsistentReference", err.c_str() ); } storeRefInfo(kRefMuonMask, kRefMuonBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void PFCandidate::setParticleType | ( | ParticleType | type | ) |
set Particle Type
Definition at line 166 of file PFCandidate.cc.
References reco::LeafCandidate::setPdgId(), and translateTypeToPdgId().
{ setPdgId( translateTypeToPdgId( type ) ); }
void PFCandidate::setPFElectronExtraRef | ( | const reco::PFCandidateElectronExtraRef & | ref | ) |
set the PF Electron Extra Ref
Definition at line 484 of file PFCandidate.cc.
References edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefPFElectronExtraBit, kRefPFElectronExtraMask, edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
{ storeRefInfo(kRefPFElectronExtraMask, kRefPFElectronExtraBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void PFCandidate::setPFPhotonExtraRef | ( | const reco::PFCandidatePhotonExtraRef & | ref | ) |
set the PF Photon Extra Ref
Definition at line 538 of file PFCandidate.cc.
References edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefPFPhotonExtraBit, kRefPFPhotonExtraMask, edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
{ storeRefInfo(kRefPFPhotonExtraMask, kRefPFPhotonExtraBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void PFCandidate::setPhotonRef | ( | const reco::PhotonRef & | phRef | ) |
set ref to the corresponding reco::Photon if any
Definition at line 506 of file PFCandidate.cc.
References e, Exception, gamma, edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefPhotonBit, kRefPhotonMask, particleId(), edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
Referenced by PFLinker::produce().
{ if( particleId() != gamma && particleId() != e) { string err; err += "PFCandidate::setSuperClusterRef: this is not an electron neither a photon ! particleId_="; char num[4]; sprintf( num, "%d", particleId()); err += num; throw cms::Exception("InconsistentReference", err.c_str() ); } storeRefInfo(kRefPhotonMask, kRefPhotonBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void reco::PFCandidate::setPositionAtECALEntrance | ( | const math::XYZPointF & | pos | ) | [inline] |
set position at ECAL entrance
Definition at line 310 of file PFCandidate.h.
References pos, and positionAtECALEntrance_.
Referenced by PFElectronAlgo::SetCandidates().
{ positionAtECALEntrance_ = pos; }
void reco::PFCandidate::setPs1Energy | ( | float | e1 | ) | [inline] |
set corrected PS1 energy
Definition at line 236 of file PFCandidate.h.
References ps1Energy_.
Referenced by PFPhotonAlgo::RunPFPhoton(), and PFElectronAlgo::SetCandidates().
{ps1Energy_ = e1;}
void reco::PFCandidate::setPs2Energy | ( | float | e2 | ) | [inline] |
set corrected PS2 energy
Definition at line 242 of file PFCandidate.h.
References ps2Energy_.
Referenced by PFPhotonAlgo::RunPFPhoton(), and PFElectronAlgo::SetCandidates().
{ps2Energy_ = e2;}
void reco::PFCandidate::setSourceCandidatePtr | ( | const PFCandidatePtr & | ptr | ) | [inline] |
Definition at line 111 of file PFCandidate.h.
References sourcePtr_.
Referenced by FFTJetPFPileupCleaner::produce().
{ sourcePtr_ = ptr; }
void PFCandidate::setSuperClusterRef | ( | const reco::SuperClusterRef & | scRef | ) |
Definition at line 522 of file PFCandidate.cc.
References e, Exception, gamma, edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefSuperClusterBit, kRefSuperClusterMask, particleId(), edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
Referenced by PFLinker::produce(), PFPhotonAlgo::RunPFPhoton(), and PFElectronAlgo::SetCandidates().
{ if( particleId() != gamma && particleId() != e) { string err; err += "PFCandidate::setSuperClusterRef: this is not an electron neither a photon ! particleId_="; char num[4]; sprintf( num, "%d", particleId()); err += num; throw cms::Exception("InconsistentReference", err.c_str() ); } storeRefInfo(kRefSuperClusterMask, kRefSuperClusterBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void PFCandidate::setTrackRef | ( | const reco::TrackRef & | ref | ) |
set track reference
Definition at line 322 of file PFCandidate.cc.
References reco::LeafCandidate::charge(), Exception, edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefTrackBit, kRefTrackMask, particleId(), edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
Referenced by PFCandidateMixer::produce(), and PFElectronAlgo::SetCandidates().
{ if(!charge()) { string err; err += "PFCandidate::setTrackRef: this is a neutral candidate! "; err += "particleId_="; char num[4]; sprintf( num, "%d", particleId()); err += num; throw cms::Exception("InconsistentReference", err.c_str() ); } storeRefInfo(kRefTrackMask, kRefTrackBit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
void PFCandidate::setV0Ref | ( | const reco::VertexCompositeCandidateRef & | ref | ) |
set ref to original reco conversion
Definition at line 464 of file PFCandidate.cc.
References edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), kRefV0Bit, kRefV0Mask, edm::Ref< C, T, F >::productGetter(), edm::Ref< C, T, F >::refCore(), and storeRefInfo().
{ storeRefInfo(kRefV0Mask, kRefV0Bit, iRef.isNonnull(), iRef.refCore(), iRef.key(),iRef.productGetter()); }
virtual void reco::PFCandidate::setVertex | ( | math::XYZPoint | p | ) | [inline, virtual] |
Definition at line 370 of file PFCandidate.h.
References kCandVertex, reco::LeafCandidate::p(), reco::LeafCandidate::vertex_, and vertexType_.
Referenced by PFConcretePFCandidateProducer::produce(), and PFPhotonAlgo::RunPFPhoton().
{ vertex_=p; vertexType_ = kCandVertex; }
void reco::PFCandidate::setVertexSource | ( | PFVertexType | vt | ) | [inline] |
Definition at line 368 of file PFCandidate.h.
References kCandVertex, reco::LeafCandidate::vertex_, and vertexType_.
Referenced by PFElectronAlgo::SetCandidates().
{ vertexType_=vt; if (vertexType_!=kCandVertex) vertex_=Point(0.,0.,0.);}
CandidatePtr reco::PFCandidate::sourceCandidatePtr | ( | size_type | i | ) | const [inline, virtual] |
return a Ptr to one of the source Candidates ( the candidates used to construct this Candidate)
Reimplemented from reco::LeafCandidate.
Definition at line 117 of file PFCandidate.h.
References sourcePtr_.
Referenced by overlap().
{ return sourcePtr_; }
void PFCandidate::storeRefInfo | ( | unsigned int | iMask, |
unsigned int | iBit, | ||
bool | iIsValid, | ||
const edm::RefCore & | iCore, | ||
size_t | iKey, | ||
const edm::EDProductGetter * | iGetter | ||
) | [private] |
Definition at line 271 of file PFCandidate.cc.
References bitPackRefInfo(), getter_, edm::RefCore::productPtr(), refsCollectionCache_, refsInfo_, s_refsBefore, and storedRefsBitPattern_.
Referenced by setConversionRef(), setDisplacedVertexRef(), setGsfElectronRef(), setGsfTrackRef(), setMuonRef(), setPFElectronExtraRef(), setPFPhotonExtraRef(), setPhotonRef(), setSuperClusterRef(), setTrackRef(), and setV0Ref().
{ size_t index = s_refsBefore[storedRefsBitPattern_ & iMask]; if ( 0 == getter_) { getter_ = iGetter; } if(iIsValid) { if(0 == (storedRefsBitPattern_ & iBit) ) { refsInfo_.insert(refsInfo_.begin()+index, bitPackRefInfo(iCore,iKey)); if (iGetter==0) refsCollectionCache_.insert(refsCollectionCache_.begin()+index,(void*)iCore.productPtr()); else refsCollectionCache_.insert(refsCollectionCache_.begin()+index,0); } else { assert(refsInfo_.size()>index); *(refsInfo_.begin()+index)=bitPackRefInfo(iCore,iKey); if (iGetter==0) *(refsCollectionCache_.begin()+index)=(void*)iCore.productPtr(); else *(refsCollectionCache_.begin()+index)=0; } storedRefsBitPattern_ |= iBit; } else{ if( storedRefsBitPattern_ & iBit) { refsInfo_.erase(refsInfo_.begin()+index); refsCollectionCache_.erase(refsCollectionCache_.begin()+index); storedRefsBitPattern_ ^= iBit; } } }
reco::SuperClusterRef PFCandidate::superClusterRef | ( | ) | const |
return a reference to the corresponding SuperCluster if any
Definition at line 502 of file PFCandidate.cc.
References GETREF, kRefSuperClusterBit, and kRefSuperClusterMask.
Referenced by PFCandWithSuperClusterExtractor::depositFromObject(), PFPhotonAlgo::EvaluateGCorrMVA(), PFPhotonAlgo::EvaluateResMVA(), PFLinker::produce(), and PFPhotonTranslator::produce().
reco::TrackRef PFCandidate::trackRef | ( | ) | const |
return a reference to the corresponding track, if charged. otherwise, return a null reference
Definition at line 339 of file PFCandidate.cc.
References GETREF, kRefTrackBit, and kRefTrackMask.
Referenced by PFPileUpAlgo::chargedHadronVertex(), metsig::SignAlgoResolutions::evalPF(), PFCandCommonVertexFitterBase::fill(), FFTJetPFPileupCleaner::findSomeVertex(), reco::tau::getTrack(), pat::helper::VertexingHelper::getTrack_(), reco::modules::HICaloCompatibleTrackSelector::matchPFCandToTrack(), PFAlgo::postMuonCleaning(), PFElectronTranslator::produce(), setMuonRef(), PFRecoTauDiscriminationByFlightPathSignificance::threeProngFlightPathSig(), and vertex().
{ GETREF(reco::Track, kRefTrackMask, kRefTrackBit); }
PFCandidate::ParticleType PFCandidate::translatePdgIdToType | ( | int | pdgid | ) | const |
int PFCandidate::translateTypeToPdgId | ( | ParticleType | type | ) | const |
returns the pdg id corresponding to the particle type. the particle type could be removed at some point to gain some space. low priority
Definition at line 148 of file PFCandidate.cc.
References reco::LeafCandidate::charge(), e, egamma_HF, gamma, h, h0, h_HF, mu, and X.
Referenced by PFCandidate(), and setParticleType().
{ int thecharge = charge(); switch( type ) { case h: return thecharge*211; // pi+ case e: return thecharge*(-11); case mu: return thecharge*(-13); case gamma: return 22; case h0: return 130; // K_L0 case h_HF: return 1; // dummy pdg code case egamma_HF: return 2; // dummy pdg code case X: default: return 0; } }
reco::VertexCompositeCandidateRef PFCandidate::v0Ref | ( | ) | const |
return a reference to the original conversion
Definition at line 469 of file PFCandidate.cc.
References GETREF, kRefV0Bit, and kRefV0Mask.
const math::XYZPoint & PFCandidate::vertex | ( | ) | const [virtual] |
vertex position
Reimplemented from reco::LeafCandidate.
Definition at line 546 of file PFCandidate.cc.
References gsfTrackRef(), kCandVertex, kComMuonVertex, kGSFVertex, kSAMuonVertex, kTrkMuonVertex, kTrkVertex, muonRef(), trackRef(), reco::LeafCandidate::vertex_, and vertexType_.
Referenced by FWPFCandidate3DProxyBuilder::build(), PFPileUpAlgo::chargedHadronVertex(), PFCandWithSuperClusterExtractor::depositFromObject(), FFTJetPFPileupCleaner::findSomeVertex(), PFConcretePFCandidateProducer::produce(), vx(), vy(), and vz().
{ switch (vertexType_) { case kCandVertex: return vertex_; break; case kTrkVertex: return trackRef()->vertex(); break; case kComMuonVertex: return muonRef()->combinedMuon()->vertex(); break; case kSAMuonVertex: return muonRef()->standAloneMuon()->vertex(); break; case kTrkMuonVertex: return muonRef()->track()->vertex(); break; case kGSFVertex: return gsfTrackRef()->vertex(); break; } return vertex_; }
virtual double reco::PFCandidate::vx | ( | ) | const [inline, virtual] |
x coordinate of vertex position
Reimplemented from reco::LeafCandidate.
Definition at line 375 of file PFCandidate.h.
References vertex().
Referenced by PFAlgo::postMuonCleaning().
{return vertex().x();}
virtual double reco::PFCandidate::vy | ( | ) | const [inline, virtual] |
y coordinate of vertex position
Reimplemented from reco::LeafCandidate.
Definition at line 376 of file PFCandidate.h.
References vertex().
Referenced by PFAlgo::postMuonCleaning().
{return vertex().y();}
virtual double reco::PFCandidate::vz | ( | ) | const [inline, virtual] |
z coordinate of vertex position
Reimplemented from reco::LeafCandidate.
Definition at line 377 of file PFCandidate.h.
References vertex().
Referenced by PFCandWithSuperClusterExtractor::depositFromObject().
{return vertex().z();}
std::ostream& operator<< | ( | std::ostream & | out, |
const PFCandidate & | c | ||
) | [friend] |
const float PFCandidate::bigMva_ = -999. [static] |
Definition at line 355 of file PFCandidate.h.
Blocks reco::PFCandidate::blocksStorage_ [private] |
Definition at line 389 of file PFCandidate.h.
Referenced by addElementInBlock(), elementsInBlocks(), and PFCandidate().
float reco::PFCandidate::deltaP_ [private] |
uncertainty on 3-momentum
Definition at line 425 of file PFCandidate.h.
Referenced by deltaP(), and setDeltaP().
float reco::PFCandidate::ecalERatio_ [private] |
corrected ECAL energy ratio (corrected/raw)
Definition at line 398 of file PFCandidate.h.
Referenced by ecalEnergy(), and setEcalEnergy().
ElementsInBlocks reco::PFCandidate::elementsInBlocks_ [mutable, private] |
Definition at line 388 of file PFCandidate.h.
Referenced by elementsInBlocks().
Elements reco::PFCandidate::elementsStorage_ [private] |
Definition at line 390 of file PFCandidate.h.
Referenced by addElementInBlock(), elementsInBlocks(), and PFCandidate().
unsigned reco::PFCandidate::flags_ [private] |
all flags, packed (ecal regional, hcal regional, tracking)
Definition at line 422 of file PFCandidate.h.
const edm::EDProductGetter* reco::PFCandidate::getter_ [private] |
Definition at line 459 of file PFCandidate.h.
Referenced by storeRefInfo().
float reco::PFCandidate::hcalERatio_ [private] |
corrected HCAL energy ratio (corrected/raw)
Definition at line 401 of file PFCandidate.h.
Referenced by hcalEnergy(), and setHcalEnergy().
float reco::PFCandidate::hoERatio_ [private] |
corrected HO energy ratio (corrected/raw)
Definition at line 404 of file PFCandidate.h.
Referenced by hoEnergy(), and setHoEnergy().
float reco::PFCandidate::mva_e_mu_ [private] |
mva for electron-muon discrimination
Definition at line 433 of file PFCandidate.h.
Referenced by mva_e_mu(), and set_mva_e_mu().
float reco::PFCandidate::mva_e_pi_ [private] |
mva for electron-pion discrimination
Definition at line 430 of file PFCandidate.h.
Referenced by mva_e_pi(), and set_mva_e_pi().
float reco::PFCandidate::mva_gamma_nh_ [private] |
mva for neutral hadron - gamma discrimination
Definition at line 445 of file PFCandidate.h.
Referenced by mva_gamma_nh(), and set_mva_gamma_nh().
float reco::PFCandidate::mva_nothing_gamma_ [private] |
mva for gamma detection
Definition at line 439 of file PFCandidate.h.
Referenced by mva_nothing_gamma(), and set_mva_nothing_gamma().
float reco::PFCandidate::mva_nothing_nh_ [private] |
mva for neutral hadron detection
Definition at line 442 of file PFCandidate.h.
Referenced by mva_nothing_nh(), and set_mva_nothing_nh().
float reco::PFCandidate::mva_pi_mu_ [private] |
mva for pi-muon discrimination
Definition at line 436 of file PFCandidate.h.
Referenced by mva_pi_mu(), and set_mva_pi_mu().
position at ECAL entrance, from the PFRecTrack
Definition at line 448 of file PFCandidate.h.
Referenced by positionAtECALEntrance(), and setPositionAtECALEntrance().
float reco::PFCandidate::ps1Energy_ [private] |
corrected PS1 energy
Definition at line 416 of file PFCandidate.h.
Referenced by pS1Energy(), and setPs1Energy().
float reco::PFCandidate::ps2Energy_ [private] |
corrected PS2 energy
Definition at line 419 of file PFCandidate.h.
Referenced by pS2Energy(), and setPs2Energy().
float reco::PFCandidate::rawEcalEnergy_ [private] |
raw ECAL energy
Definition at line 407 of file PFCandidate.h.
Referenced by ecalEnergy(), rawEcalEnergy(), and setEcalEnergy().
float reco::PFCandidate::rawHcalEnergy_ [private] |
raw HCAL energy
Definition at line 410 of file PFCandidate.h.
Referenced by hcalEnergy(), rawHcalEnergy(), and setHcalEnergy().
float reco::PFCandidate::rawHoEnergy_ [private] |
raw HO energy
Definition at line 413 of file PFCandidate.h.
Referenced by hoEnergy(), rawHoEnergy(), and setHoEnergy().
std::vector<const void *> reco::PFCandidate::refsCollectionCache_ [private] |
Definition at line 462 of file PFCandidate.h.
Referenced by storeRefInfo().
std::vector<unsigned long long> reco::PFCandidate::refsInfo_ [private] |
Definition at line 461 of file PFCandidate.h.
Referenced by getRefInfo(), PFCandidate(), and storeRefInfo().
PFCandidatePtr reco::PFCandidate::sourcePtr_ [private] |
reference to the source PFCandidate, if any
Definition at line 394 of file PFCandidate.h.
Referenced by overlap(), PFCandidate(), setSourceCandidatePtr(), and sourceCandidatePtr().
unsigned short reco::PFCandidate::storedRefsBitPattern_ [private] |
Definition at line 460 of file PFCandidate.h.
Referenced by getRefInfo(), and storeRefInfo().
PFVertexType reco::PFCandidate::vertexType_ [private] |
Definition at line 427 of file PFCandidate.h.
Referenced by setVertex(), setVertexSource(), and vertex().