#include <CaloParticle.h>
Public Types | |
typedef int | Charge |
electric charge type More... | |
typedef std::vector< SimTrack >::const_iterator | g4t_iterator |
typedef reco::GenParticleRefVector::iterator | genp_iterator |
reference to reco::GenParticle More... | |
typedef math::XYZTLorentzVectorD | LorentzVector |
Lorentz vector. More... | |
typedef math::XYZPointD | Point |
point in the space More... | |
typedef math::PtEtaPhiMLorentzVector | PolarLorentzVector |
Lorentz vector. More... | |
typedef SimClusterRefVector::iterator | sc_iterator |
typedef math::XYZVectorD | Vector |
point in the space More... | |
Public Member Functions | |
void | addG4Track (const SimTrack &t) |
void | addGenParticle (const reco::GenParticleRef &ref) |
void | addRecHitAndFraction (uint32_t hit, float fraction) |
add rechit with fraction More... | |
void | addSimCluster (const SimClusterRef &ref) |
void | addSimHit (const PCaloHit &hit) |
add simhit's energy to cluster More... | |
math::XYZVectorF | boostToCM () const |
Vector to boost to the particle centre of mass frame. More... | |
CaloParticle () | |
CaloParticle (const SimTrack &simtrk) | |
CaloParticle (EncodedEventId eventID, uint32_t particleID) | |
float | charge () const |
Electric charge. Note this is taken from the first SimTrack only. More... | |
void | clearSimClusters () |
float | energy () const |
Energy. Note this is taken from the first SimTrack only. More... | |
float | et () const |
Transverse energy. Note this is taken from the first SimTrack only. More... | |
float | eta () const |
Momentum pseudorapidity. Note this is taken from the simtrack before the calorimeter. More... | |
EncodedEventId | eventId () const |
Signal source, crossing number. More... | |
g4t_iterator | g4Track_begin () const |
g4t_iterator | g4Track_end () const |
const std::vector< SimTrack > & | g4Tracks () const |
genp_iterator | genParticle_begin () const |
iterators More... | |
genp_iterator | genParticle_end () const |
const reco::GenParticleRefVector & | genParticles () const |
std::vector< std::pair< uint32_t, float > > | hits_and_fractions () const |
Returns list of rechit IDs and fractions for this CaloParticle. More... | |
bool | longLived () const |
is long lived? More... | |
float | mass () const |
Mass. Note this is taken from the first SimTrack only. More... | |
float | massSqr () const |
Mass squared. Note this is taken from the first SimTrack only. More... | |
math::XYZVectorF | momentum () const |
spatial momentum vector More... | |
float | mt () const |
Transverse mass. Note this is taken from the first SimTrack only. More... | |
float | mtSqr () const |
Transverse mass squared. Note this is taken from the first SimTrack only. More... | |
int | numberOfRecHits () const |
Gives the total number of SimHits, in the cluster. More... | |
int | numberOfSimHits () const |
Gives the total number of SimHits, in the cluster. More... | |
float | p () const |
Magnitude of momentum vector. Note this is taken from the first SimTrack only. More... | |
const math::XYZTLorentzVectorF & | p4 () const |
Four-momentum Lorentz vector. Note this is taken from the first SimTrack only. More... | |
uint64_t | particleId () const |
int | pdgId () const |
PDG ID. More... | |
float | phi () const |
Momentum azimuthal angle. Note this is taken from the first SimTrack only. More... | |
float | pt () const |
Transverse momentum. Note this is taken from the first SimTrack only. More... | |
float | px () const |
x coordinate of momentum vector. Note this is taken from the first SimTrack only. More... | |
float | py () const |
y coordinate of momentum vector. Note this is taken from the first SimTrack only. More... | |
float | pz () const |
z coordinate of momentum vector. Note this is taken from the first SimTrack only. More... | |
float | rapidity () const |
Rapidity. Note this is taken from the simtrack before the calorimeter. More... | |
sc_iterator | simCluster_begin () const |
sc_iterator | simCluster_end () const |
const SimClusterRefVector & | simClusters () const |
float | simEnergy () const |
returns the accumulated sim energy in the cluster More... | |
int | status () const |
Status word. More... | |
float | theta () const |
Momentum polar angle. Note this is taken from the first SimTrack only. More... | |
int | threeCharge () const |
Gives charge in unit of quark charge (should be 3 times "charge()") More... | |
float | y () const |
Same as rapidity(). More... | |
~CaloParticle () | |
Static Public Attributes | |
static const unsigned int | longLivedTag = 65536 |
long lived flag More... | |
Private Attributes | |
EncodedEventId | event_ |
std::vector< float > | fractions_ |
std::vector< SimTrack > | g4Tracks_ |
references to G4 and reco::GenParticle tracks More... | |
reco::GenParticleRefVector | genParticles_ |
std::vector< uint32_t > | hits_ |
uint64_t | nsimhits_ {0} |
uint32_t | particleId_ {0} |
SimClusterRefVector | simClusters_ |
float | simhit_energy_ {0.f} |
math::XYZTLorentzVectorF | theMomentum_ |
Friends | |
std::ostream & | operator<< (std::ostream &s, CaloParticle const &tp) |
Definition at line 16 of file CaloParticle.h.
typedef int CaloParticle::Charge |
electric charge type
Definition at line 20 of file CaloParticle.h.
typedef std::vector<SimTrack>::const_iterator CaloParticle::g4t_iterator |
Definition at line 28 of file CaloParticle.h.
reference to reco::GenParticle
Definition at line 27 of file CaloParticle.h.
Lorentz vector.
Definition at line 21 of file CaloParticle.h.
typedef math::XYZPointD CaloParticle::Point |
point in the space
Definition at line 23 of file CaloParticle.h.
Lorentz vector.
Definition at line 22 of file CaloParticle.h.
Definition at line 29 of file CaloParticle.h.
typedef math::XYZVectorD CaloParticle::Vector |
point in the space
Definition at line 24 of file CaloParticle.h.
CaloParticle::CaloParticle | ( | ) |
Definition at line 11 of file CaloParticle.cc.
CaloParticle::CaloParticle | ( | const SimTrack & | simtrk | ) |
Definition at line 15 of file CaloParticle.cc.
References addG4Track(), event_, CoreSimTrack::eventId(), CoreSimTrack::momentum(), particleId_, theMomentum_, and CoreSimTrack::trackId().
CaloParticle::CaloParticle | ( | EncodedEventId | eventID, |
uint32_t | particleID | ||
) |
Definition at line 23 of file CaloParticle.cc.
References event_, EgammaObjectsElectrons_cfi::particleID, and particleId_.
CaloParticle::~CaloParticle | ( | ) |
Definition at line 28 of file CaloParticle.cc.
|
inline |
Definition at line 61 of file CaloParticle.h.
References g4Tracks_, and submitPVValidationJobs::t.
Referenced by CaloParticle().
|
inline |
Definition at line 59 of file CaloParticle.h.
References genParticles_, and edm::RefVector< C, T, F >::push_back().
|
inline |
add rechit with fraction
Definition at line 169 of file CaloParticle.h.
References HLT_2022v11_cff::fraction, fractions_, and hits_.
|
inline |
Definition at line 60 of file CaloParticle.h.
References edm::RefVector< C, T, F >::push_back(), and simClusters_.
|
inline |
add simhit's energy to cluster
Definition at line 187 of file CaloParticle.h.
References nsimhits_, and simhit_energy_.
|
inline |
Vector to boost to the particle centre of mass frame.
Definition at line 91 of file CaloParticle.h.
References p4().
|
inline |
Electric charge. Note this is taken from the first SimTrack only.
Definition at line 79 of file CaloParticle.h.
References g4Tracks_.
Referenced by threeCharge().
|
inline |
Definition at line 76 of file CaloParticle.h.
References edm::RefVector< C, T, F >::clear(), and simClusters_.
|
inline |
Energy. Note this is taken from the first SimTrack only.
Definition at line 98 of file CaloParticle.h.
References p4().
Referenced by HGVHistoProducerAlgo::fill_caloparticle_histos(), and Jet.Jet::rawEnergy().
|
inline |
Transverse energy. Note this is taken from the first SimTrack only.
Definition at line 101 of file CaloParticle.h.
References p4().
|
inline |
Momentum pseudorapidity. Note this is taken from the simtrack before the calorimeter.
Definition at line 142 of file CaloParticle.h.
References p4().
Referenced by Particle.Particle::__str__(), HGVHistoProducerAlgo::fill_caloparticle_histos(), Jet.Jet::jetID(), and Jet.Jet::puJetId().
|
inline |
Signal source, crossing number.
Note this is taken from the first SimTrack only, but there shouldn't be any SimTracks from different crossings in the CaloParticle.
Definition at line 54 of file CaloParticle.h.
References event_.
Referenced by ntupleDataFormat.Event::eventIdStr().
|
inline |
Definition at line 65 of file CaloParticle.h.
References g4Tracks_.
|
inline |
Definition at line 66 of file CaloParticle.h.
References g4Tracks_.
|
inline |
Definition at line 74 of file CaloParticle.h.
References g4Tracks_.
Referenced by HGVHistoProducerAlgo::fill_caloparticle_histos().
|
inline |
iterators
Definition at line 63 of file CaloParticle.h.
References edm::RefVector< C, T, F >::begin(), and genParticles_.
|
inline |
Definition at line 64 of file CaloParticle.h.
References edm::RefVector< C, T, F >::end(), and genParticles_.
|
inline |
|
inline |
Returns list of rechit IDs and fractions for this CaloParticle.
Definition at line 175 of file CaloParticle.h.
References fractions_, hits_, mps_fire::i, and mps_fire::result.
|
inline |
is long lived?
Definition at line 160 of file CaloParticle.h.
References longLivedTag, and status().
|
inline |
Mass. Note this is taken from the first SimTrack only.
Definition at line 104 of file CaloParticle.h.
References p4().
Referenced by Particle.Particle::__str__(), DiObject.DiMuon::__str__(), and massSqr().
|
inline |
Mass squared. Note this is taken from the first SimTrack only.
Definition at line 107 of file CaloParticle.h.
References mass(), and funct::pow().
|
inline |
spatial momentum vector
Definition at line 88 of file CaloParticle.h.
References p4().
|
inline |
Transverse mass. Note this is taken from the first SimTrack only.
Definition at line 110 of file CaloParticle.h.
References p4().
|
inline |
Transverse mass squared. Note this is taken from the first SimTrack only.
Definition at line 114 of file CaloParticle.h.
References p4().
|
inline |
Gives the total number of SimHits, in the cluster.
Definition at line 166 of file CaloParticle.h.
References hits_.
|
inline |
Gives the total number of SimHits, in the cluster.
Definition at line 163 of file CaloParticle.h.
References nsimhits_.
|
inline |
Magnitude of momentum vector. Note this is taken from the first SimTrack only.
Definition at line 95 of file CaloParticle.h.
References p4().
Referenced by Electron.Electron::ptErr().
|
inline |
Four-momentum Lorentz vector. Note this is taken from the first SimTrack only.
Definition at line 85 of file CaloParticle.h.
References theMomentum_.
Referenced by boostToCM(), Tau.Tau::dxy_approx(), Tau.Tau::dz(), energy(), et(), eta(), mass(), momentum(), mt(), mtSqr(), p(), Lepton.Lepton::p4WithFSR(), phi(), pt(), px(), py(), pz(), rapidity(), and theta().
|
inline |
|
inline |
PDG ID.
Returns the PDG ID of the first associated gen particle. If there are no gen particles associated then it returns type() from the first SimTrack.
Definition at line 43 of file CaloParticle.h.
References edm::RefVector< C, T, F >::begin(), edm::RefVector< C, T, F >::empty(), g4Tracks_, and genParticles_.
Referenced by Particle.Particle::__str__().
|
inline |
Momentum azimuthal angle. Note this is taken from the first SimTrack only.
Definition at line 134 of file CaloParticle.h.
References p4().
Referenced by Particle.Particle::__str__(), HGVHistoProducerAlgo::fill_caloparticle_histos(), and ntupleDataFormat.Track::phiPull().
|
inline |
Transverse momentum. Note this is taken from the first SimTrack only.
Definition at line 130 of file CaloParticle.h.
References p4().
Referenced by Particle.Particle::__str__(), DiObject.DiMuon::__str__(), Photon.Photon::calScaledIsoValueExp(), Photon.Photon::calScaledIsoValueLin(), Photon.Photon::calScaledIsoValueQuadr(), HGVHistoProducerAlgo::fill_caloparticle_histos(), Electron.Electron::mvaIDLoose(), Electron.Electron::mvaIDRun2(), Electron.Electron::mvaIDTight(), Electron.Electron::ptErr(), ntupleDataFormat.Track::ptPull(), Lepton.Lepton::relIso(), Lepton.Lepton::relIsoFromEA(), Lepton.Lepton::relIsoR(), and Jet.Jet::setCorrP4().
|
inline |
x coordinate of momentum vector. Note this is taken from the first SimTrack only.
Definition at line 118 of file CaloParticle.h.
References p4().
|
inline |
y coordinate of momentum vector. Note this is taken from the first SimTrack only.
Definition at line 122 of file CaloParticle.h.
References p4().
|
inline |
z coordinate of momentum vector. Note this is taken from the first SimTrack only.
Definition at line 126 of file CaloParticle.h.
References p4().
|
inline |
Rapidity. Note this is taken from the simtrack before the calorimeter.
Definition at line 146 of file CaloParticle.h.
References p4().
Referenced by y().
|
inline |
Definition at line 67 of file CaloParticle.h.
References edm::RefVector< C, T, F >::begin(), and simClusters_.
|
inline |
Definition at line 68 of file CaloParticle.h.
References edm::RefVector< C, T, F >::end(), and simClusters_.
|
inline |
Definition at line 72 of file CaloParticle.h.
References simClusters_.
Referenced by FWECaloParticleProxyBuilder::build(), FWCaloParticleProxyBuilder::build(), and HGVHistoProducerAlgo::fill_caloparticle_histos().
|
inline |
returns the accumulated sim energy in the cluster
Definition at line 184 of file CaloParticle.h.
References simhit_energy_.
|
inline |
Status word.
Returns status() from the first gen particle, or -99 if there are no gen particles attached.
Definition at line 155 of file CaloParticle.h.
References edm::RefVector< C, T, F >::empty(), genParticles_, and status().
Referenced by longLived(), and status().
|
inline |
Momentum polar angle. Note this is taken from the first SimTrack only.
Definition at line 138 of file CaloParticle.h.
References p4().
Referenced by Tau.Tau::zImpact().
|
inline |
Gives charge in unit of quark charge (should be 3 times "charge()")
Definition at line 81 of file CaloParticle.h.
|
inline |
Same as rapidity().
Definition at line 149 of file CaloParticle.h.
References rapidity().
Referenced by svgfig.Ellipse::__repr__(), geometryXMLparser.Alignable::pos(), ntupleDataFormat._HitObject::r(), and ntupleDataFormat._HitObject::r3D().
|
friend |
Definition at line 30 of file CaloParticle.cc.
|
private |
Definition at line 194 of file CaloParticle.h.
Referenced by CaloParticle(), and eventId().
|
private |
Definition at line 199 of file CaloParticle.h.
Referenced by addRecHitAndFraction(), and hits_and_fractions().
|
private |
references to G4 and reco::GenParticle tracks
Definition at line 204 of file CaloParticle.h.
Referenced by addG4Track(), charge(), g4Track_begin(), g4Track_end(), g4Tracks(), and pdgId().
|
private |
Definition at line 205 of file CaloParticle.h.
Referenced by addGenParticle(), genParticle_begin(), genParticle_end(), genParticles(), pdgId(), and status().
|
private |
Definition at line 198 of file CaloParticle.h.
Referenced by addRecHitAndFraction(), hits_and_fractions(), and numberOfRecHits().
|
static |
|
private |
Definition at line 193 of file CaloParticle.h.
Referenced by addSimHit(), and numberOfSimHits().
|
private |
Definition at line 196 of file CaloParticle.h.
Referenced by CaloParticle(), and particleId().
|
private |
Definition at line 207 of file CaloParticle.h.
Referenced by addSimCluster(), clearSimClusters(), simCluster_begin(), simCluster_end(), and simClusters().
|
private |
Definition at line 197 of file CaloParticle.h.
Referenced by addSimHit(), and simEnergy().
|
private |
Definition at line 201 of file CaloParticle.h.
Referenced by CaloParticle(), and p4().