17#ifndef XAOD_STANDALONE
18 declareInterface<IJetConstituentModifier>(
this);
33 <<
", but received " << cont->
front()->type());
34 return StatusCode::FAILURE;
39 return StatusCode::SUCCESS;
58 return StatusCode::FAILURE;
60 return StatusCode::SUCCESS;
97 if( tcc->
taste() != 0) {
105 return StatusCode::FAILURE;
107 return StatusCode::SUCCESS;
127 pfo->
setP4(p4.pt(),p4.eta(),p4.phi(),p4.mass());
136 pfo->
setP4(p4.pt(),p4.eta(),p4.phi(),p4.mass());
143 if( tcc->
taste() != 0) {
152 return StatusCode::FAILURE;
154 return StatusCode::SUCCESS;
164 factor = clus->
calE() > 0. ? corrected_energy / clus->
calE() : 0.;
170 factor = pfo->
pt() > 0. ? corrected_pt / pfo->
pt() : 0.;
176 factor = pfo->
pt() > 0. ? corrected_pt / pfo->
pt() : 0.;
182 factor = tcc->
pt() > 0. ? corrected_pt / tcc->
pt() : 0.;
197 weight = clus->
calE() > 0. ? corrected_p4.e() / clus->
calE() : 0.;
205 weight = pfo->
pt() > 0. ? corrected_p4.pt() / pfo->
pt() : 0.;
213 weight = pfo->
pt() > 0. ? corrected_p4.pt() / pfo->
pt() : 0.;
220 if( tcc->
taste() != 0) {
221 weight = tcc->
pt() > 0. ? corrected_p4.pt() / tcc->
pt() : 0.;
227 throw std::runtime_error(
"No specialisation for object type " + std::to_string(
m_inputType));
Scalar eta() const
pseudorapidity method
Scalar phi() const
phi method
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_ERROR(x,...)
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
const T * front() const
Access the first element in the collection as an rvalue.
bool empty() const noexcept
Returns true if the collection is empty.
float getCorrectionFactor(xAOD::IParticle *obj, const float &corrected_energy, const float &corrected_pt) const
StatusCode setEnergyPt(xAOD::IParticle *obj, float e, float pt) const
JetConstituentModifierBase(const std::string &name)
StatusCode setEtaPhi(xAOD::IParticle *obj, float eta, float phi) const
virtual StatusCode process_impl(xAOD::IParticleContainer *, const EventContext &) const
StatusCode setP4(xAOD::IParticle *obj, const xAOD::JetFourMom_t &p4) const
StatusCode process(xAOD::IParticleContainer *cont, const EventContext &ctx) const override final
void setCalPhi(flt_t)
Set for signal state CALIBRATED.
void setCalEta(flt_t)
Set for signal state CALIBRATED.
flt_t calE() const
Geet Energy in signal state CALIBRATED.
void setCalE(flt_t)
Set Energy for signal state CALIBRATED.
virtual double pt() const override
void setP4(float pt, float eta, float phi, float m)
virtual double phi() const override
The azimuthal angle ( ) of the particle.
virtual double eta() const override
The pseudorapidity ( ) of the particle.
Class providing the definition of the 4-vector interface.
bool isCharged() const
is a charged PFO
void setP4(const FourMom_t &vec)
set the 4-vec
virtual double eta() const
The pseudorapidity ( ) of the particle.
virtual double phi() const
The azimuthal angle ( ) of the particle.
virtual double pt() const
The transverse momentum ( ) of the particle.
virtual double m() const
The invariant mass of the particle..
virtual double phi() const
The azimuthal angle ( ) of the particle (has range to .).
virtual int taste() const
The taste of the particle.
Taste
Type of TrackCaloCluster - Charged - Neutral - Combined.
const ElementLink< xAOD::TrackParticleContainer > & trackParticleLink() const
virtual double pt() const
The transverse momentum ( ) of the particle.
virtual double eta() const
The pseudorapidity ( ) of the particle.
const std::vector< ElementLink< xAOD::CaloClusterContainer > > & caloClusterLinks() const
Returns a vector to the links (which can be invalid) to the xAOD::CaloClusters associated with this T...
void setParameters(float pt, float eta, float phi, float m, TrackCaloCluster_v1::Taste taste, const ElementLink< xAOD::TrackParticleContainer > &particle, const std::vector< ElementLink< xAOD::CaloClusterContainer > > &clusters)
@ ParticleFlow
The object is a particle-flow object.
@ FlowElement
The object is a track-calo-cluster.
@ CaloCluster
The object is a calorimeter cluster.
@ TrackCaloCluster
The object is a track-calo-cluster.
PFO_v1 PFO
Definition of the current "pfo version".
CaloCluster_v1 CaloCluster
Define the latest version of the calorimeter cluster class.
FlowElement_v1 FlowElement
Definition of the current "pfo version".
TrackCaloCluster_v1 TrackCaloCluster
Reference the current persistent version:
DataVector< IParticle > IParticleContainer
Simple convenience declaration of IParticleContainer.
ROOT::Math::LorentzVector< ROOT::Math::PtEtaPhiM4D< double > > JetFourMom_t
Base 4 Momentum type for Jet.