Loading [MathJax]/extensions/tex2jax.js
|
ATLAS Offline Software
|
#include <xAODVBFMjjIntervalFilter.h>
|
| xAODVBFMjjIntervalFilter (const std::string &name, ISvcLocator *pSvcLocator) |
|
virtual StatusCode | filterInitialize () |
|
virtual StatusCode | filterEvent () |
|
bool | ApplyMassDphi (ConstDataVector< xAOD::JetContainer > *jets) |
|
double | getEventWeight (ConstDataVector< xAOD::JetContainer > *jets) const |
|
virtual StatusCode | sysInitialize () override |
| Override sysInitialize. More...
|
|
virtual const DataObjIDColl & | extraOutputDeps () const override |
| Return the list of extra output dependencies. More...
|
|
ServiceHandle< StoreGateSvc > & | evtStore () |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | evtStore () const |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | detStore () const |
| The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
virtual StatusCode | sysStart () override |
| Handle START transition. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override |
| Return this algorithm's input handles. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override |
| Return this algorithm's output handles. More...
|
|
Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T > &t) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc="none") |
| Declare a new Gaudi property. More...
|
|
void | updateVHKA (Gaudi::Details::PropertyBase &) |
|
MsgStream & | msg () const |
|
MsgStream & | msg (const MSG::Level lvl) const |
|
bool | msgLvl (const MSG::Level lvl) const |
|
Definition at line 22 of file xAODVBFMjjIntervalFilter.h.
◆ StoreGateSvc_t
◆ xAODVBFMjjIntervalFilter()
xAODVBFMjjIntervalFilter::xAODVBFMjjIntervalFilter |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ ApplyMassDphi()
◆ ATLAS_NOT_CONST_THREAD_SAFE() [1/2]
HepMC::GenEvent* event GenBase::ATLAS_NOT_CONST_THREAD_SAFE |
( |
| ) |
|
|
inlineinherited |
Access the current signal event (first in the McEventCollection)
- Note
- This function will make a new McEventCollection if there is not already a valid one and MakeMcEvent=True.
Definition at line 76 of file GenBase.h.
78 ATH_MSG_ERROR(
"McEventCollection is empty during first event access");
79 return *(
events()->begin());
◆ ATLAS_NOT_CONST_THREAD_SAFE() [2/2]
◆ checkOverlap() [1/2]
◆ checkOverlap() [2/2]
bool xAODVBFMjjIntervalFilter::checkOverlap |
( |
double |
eta, |
|
|
double |
phi, |
|
|
const std::vector< TLorentzVector > & |
list |
|
) |
| |
|
private |
- Todo:
- Provide a helper function for this (and similar)
Definition at line 300 of file xAODVBFMjjIntervalFilter.cxx.
302 for (
size_t i = 0;
i <
list.size(); ++
i)
304 double pt =
list[
i].Vect().Perp();
309 double deta =
eta -
list[
i].Vect().PseudoRapidity();
318 double dr = std::sqrt(deta * deta + dphi * dphi);
◆ cmTomm()
void GenBase::cmTomm |
( |
HepMC::GenEvent * |
evt | ) |
|
|
protectedinherited |
Scale event lengths by x 10.
Definition at line 78 of file GenBase.cxx.
79 for (HepMC::GenEvent::vertex_iterator vtx =
evt->vertices_begin(); vtx !=
evt->vertices_end(); ++vtx) {
80 const HepMC::FourVector fv((*vtx)->position().x() * 10,
81 (*vtx)->position().y() * 10,
82 (*vtx)->position().z() * 10,
83 (*vtx)->position().t() * 10);
84 (*vtx)->set_position(fv);
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleBase
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 245 of file AthCommonDataStore.h.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
253 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleKey
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 221 of file AthCommonDataStore.h.
229 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This is the generic version, for types that do not derive from SG::VarHandleKey
. It just forwards to the base class version of declareProperty
.
Definition at line 333 of file AthCommonDataStore.h.
338 return PBASE::declareProperty(
name, property,
doc);
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This dispatches to either the generic declareProperty
or the one for VarHandle/Key/KeyArray.
Definition at line 352 of file AthCommonDataStore.h.
◆ declareProperty() [6/6]
◆ detStore()
◆ event_const()
const HepMC::GenEvent* GenBase::event_const |
( |
| ) |
const |
|
inlineinherited |
Access the current signal event (const)
Definition at line 83 of file GenBase.h.
85 ATH_MSG_ERROR(
"Const McEventCollection is empty during first event access");
◆ events_const() [1/2]
◆ events_const() [2/2]
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
StatusCode GenFilter::execute |
( |
| ) |
|
|
virtualinherited |
- Todo:
- Probably the filter should only look at the first event... right?
Reimplemented from GenBase.
Definition at line 29 of file GenFilter.cxx.
32 return StatusCode::FAILURE;
35 ATH_MSG_WARNING(
"More than one event in current McEventCollection -- which is valid?");
51 sc = StatusCode::FAILURE;
◆ extraDeps_update_handler()
Add StoreName to extra input/output deps as needed.
use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given
◆ extraOutputDeps()
const DataObjIDColl & AthAlgorithm::extraOutputDeps |
( |
| ) |
const |
|
overridevirtualinherited |
Return the list of extra output dependencies.
This list is extended to include symlinks implied by inheritance relations.
Definition at line 50 of file AthAlgorithm.cxx.
57 return Algorithm::extraOutputDeps();
◆ filterEvent()
StatusCode xAODVBFMjjIntervalFilter::filterEvent |
( |
| ) |
|
|
virtual |
Implements GenFilter.
Definition at line 63 of file xAODVBFMjjIntervalFilter.cxx.
66 const EventContext& ctx = Gaudi::Hive::currentContext();
70 ATH_MSG_ERROR(
"Failed to retrieve random number engine xAODVBFMjjIntervalFilter");
71 setFilterPassed(
false);
72 return StatusCode::SUCCESS;
82 setFilterPassed(
false);
83 return StatusCode::SUCCESS;
90 ATH_MSG_ERROR(
"No TruthParticle collection with name " <<
"TruthGen" <<
" found in StoreGate!");
91 return StatusCode::FAILURE;
96 std::vector<const xAOD::TruthParticle *> MCTruthPhotonList;
97 std::vector<const xAOD::TruthParticle *> MCTruthElectronList;
98 std::vector<TLorentzVector> MCTruthTauList;
101 unsigned int nPart = xTruthParticleContainer->
size();
102 for (
unsigned int iPart = 0; iPart < nPart; ++iPart) {
112 MCTruthPhotonList.push_back(pitr);
122 MCTruthElectronList.push_back(pitr);
132 for (
size_t thisChild_id = 0; thisChild_id < tau->decayVtx()->nOutgoingParticles(); thisChild_id++)
135 if (child->prodVtx() != tau->decayVtx())
137 if (std::abs(child->pdgId()) == MC::NU_E)
139 else if (std::abs(child->pdgId()) == MC::NU_MU)
141 else if (std::abs(child->pdgId()) == MC::TAU)
148 TLorentzVector tauvis = TLorentzVector(tau->px() - nutau.Px(),
149 tau->py() - nutau.Py(),
150 tau->pz() - nutau.Pz(),
151 tau->e() - nutau.E());
152 if (tauvis.Vect().Perp() >=
m_olapPt && std::abs(tauvis.Vect().PseudoRapidity()) <=
m_yMax)
154 MCTruthTauList.push_back(tauvis);
166 if (std::abs((*jitr)->rapidity()) <
m_yMax && (*jitr)->pt() >=
m_olapPt)
168 bool JetOverlapsWithPhoton =
false;
169 bool JetOverlapsWithElectron =
false;
170 bool JetOverlapsWithTau =
false;
174 JetOverlapsWithPhoton =
checkOverlap((*jitr)->rapidity(), (*jitr)->phi(), MCTruthPhotonList);
178 JetOverlapsWithElectron =
checkOverlap((*jitr)->rapidity(), (*jitr)->phi(), MCTruthElectronList);
182 JetOverlapsWithTau =
checkOverlap((*jitr)->rapidity(), (*jitr)->phi(), MCTruthTauList);
185 if (!JetOverlapsWithPhoton && !JetOverlapsWithElectron && !JetOverlapsWithTau)
187 filteredJets.push_back(*jitr);
196 double eventWeight = 1.0;
198 double rnd = rndm->flat();
199 if (1.0 / eventWeight < rnd)
201 setFilterPassed(
false);
202 ATH_MSG_DEBUG(
"Event failed weighting. Weight is " << eventWeight);
203 return StatusCode::SUCCESS;
210 setFilterPassed(
false);
211 ATH_MSG_ERROR(
"Could not retrieve MC Event Collection - weight might not work");
212 return StatusCode::SUCCESS;
217 for (
unsigned int i = 0;
i < mec->
size(); ++
i)
221 double existingWeight = (*mec)[
i]->weights().
size() > 0 ? (*mec)[
i]->weights()[0] : 1.;
222 if ((*mec)[
i]->weights().size() > 0)
224 for (
unsigned int iw = 0; iw < (*mec)[
i]->weights().size(); ++iw) {
225 double existWeight = (*mec)[
i]->weights()[iw];
226 (*mec)[
i]->weights()[iw] = existWeight * eventWeight *
m_norm;
233 (*mec)[
i]->weights().push_back(eventWeight *
m_norm * existingWeight);
237 (*mec)[
i]->add_attribute(
"filterWeight", std::make_shared<HepMC3::DoubleAttribute>(eventWeight*
m_norm));
248 setFilterPassed(
false);
250 return StatusCode::SUCCESS;
256 setFilterPassed(
false);
257 return StatusCode::SUCCESS;
263 setFilterPassed(
false);
264 return StatusCode::SUCCESS;
270 setFilterPassed(
true);
271 return StatusCode::SUCCESS;
◆ filterFinalize()
virtual StatusCode GenFilter::filterFinalize |
( |
| ) |
|
|
inlinevirtualinherited |
Reimplemented in xAODM4MuIntervalFilter, xAODParticleDecayFilter, MuDstarFilter, BoostedHadTopAndTopPair, xAODDecaysFinalStateFilter, xAODBSignalFilter, xAODLeptonFilter, TrimuMassRangeFilter, xAODLeptonPairFilter, LeptonFilter, BSignalFilter, DecaysFinalStateFilter, LeptonPairFilter, xAODHTFilter, MultiParticleFilter, xAODHeavyFlavorHadronFilter, DiBjetFilter, FourLeptonInvMassFilter, ParentChildwStatusFilter, xAODTauFilter, xAODXtoVVDecayFilterExtended, VBFHbbEtaSortingFilter, xAODTTbarWithJpsimumuFilter, ParticleDecayFilter, xAODChargedTracksWeightFilter, xAODDiLeptonMassFilter, xAODMultiBjetFilter, xAODMultiCjetFilter, HeavyFlavorHadronFilter, TauFilter, TTbarPlusHeavyFlavorFilter, MultiBjetFilter, XtoVVDecayFilterExtended, ChargedTracksWeightFilter, TTbarWithJpsimumuFilter, DiLeptonMassFilter, HTFilter, QCDTruthJetFilter, QCDTruthMultiJetFilter, M4MuIntervalFilter, and MultiCjetFilter.
Definition at line 47 of file GenFilter.h.
47 {
return StatusCode::SUCCESS; }
◆ filterInitialize()
StatusCode xAODVBFMjjIntervalFilter::filterInitialize |
( |
| ) |
|
|
virtual |
◆ finalize()
StatusCode GenFilter::finalize |
( |
| ) |
|
|
inherited |
Definition at line 56 of file GenFilter.cxx.
59 return StatusCode::SUCCESS;
◆ getEventWeight()
◆ getRandomEngine()
CLHEP::HepRandomEngine * xAODVBFMjjIntervalFilter::getRandomEngine |
( |
const std::string & |
streamName, |
|
|
const EventContext & |
ctx |
|
) |
| const |
|
private |
◆ GeVToMeV()
void GenBase::GeVToMeV |
( |
HepMC::GenEvent * |
evt | ) |
|
|
protectedinherited |
Scale event energies/momenta by x 1000.
- Todo:
- Add HepMC units awareness and do it differently when HepMC provides this functionality directly (and reference-based FourVector accessors)
Definition at line 58 of file GenBase.cxx.
59 for (HepMC::GenEvent::particle_iterator
p =
evt->particles_begin();
p !=
evt->particles_end(); ++
p) {
60 const HepMC::FourVector fv((*p)->momentum().px() * 1000,
61 (*p)->momentum().py() * 1000,
62 (*p)->momentum().pz() * 1000,
63 (*p)->momentum().e() * 1000);
64 (*p)->set_momentum(fv);
65 (*p)->set_generated_mass(1000 * (*p)->generated_mass());
◆ initialize()
StatusCode GenFilter::initialize |
( |
| ) |
|
|
virtualinherited |
◆ inputHandles()
Return this algorithm's input handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ MeVToGeV()
void GenBase::MeVToGeV |
( |
HepMC::GenEvent * |
evt | ) |
|
|
protectedinherited |
Scale event energies/momenta by x 1/1000.
Definition at line 68 of file GenBase.cxx.
69 for (HepMC::GenEvent::particle_iterator
p =
evt->particles_begin();
p !=
evt->particles_end(); ++
p) {
70 const HepMC::FourVector fv((*p)->momentum().px() / 1000,
71 (*p)->momentum().py() / 1000,
72 (*p)->momentum().pz() / 1000,
73 (*p)->momentum().e() / 1000);
74 (*p)->set_momentum(fv);
75 (*p)->set_generated_mass((*p)->generated_mass() / 1000);
◆ mmTocm()
void GenBase::mmTocm |
( |
HepMC::GenEvent * |
evt | ) |
|
|
protectedinherited |
Scale event lengths by x 1/10.
Definition at line 87 of file GenBase.cxx.
88 for (HepMC::GenEvent::vertex_iterator vtx =
evt->vertices_begin(); vtx !=
evt->vertices_end(); ++vtx) {
89 const HepMC::FourVector fv((*vtx)->position().x() / 10,
90 (*vtx)->position().y() / 10,
91 (*vtx)->position().z() / 10,
92 (*vtx)->position().t() / 10);
93 (*vtx)->set_position(fv);
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ nFailed()
int GenFilter::nFailed |
( |
| ) |
const |
|
inlineinherited |
◆ nNeeded()
int GenFilter::nNeeded |
( |
| ) |
const |
|
inlineinherited |
◆ nPassed()
int GenFilter::nPassed |
( |
| ) |
const |
|
inlineinherited |
◆ outputHandles()
Return this algorithm's output handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ particleData()
const HepPDT::ParticleData* GenBase::particleData |
( |
int |
pid | ) |
const |
|
inlineinherited |
Access an element in the particle data table.
Definition at line 126 of file GenBase.h.
◆ particleTable()
const HepPDT::ParticleDataTable& GenBase::particleTable |
( |
| ) |
const |
|
inlineinherited |
Get a particle data table.
Definition at line 118 of file GenBase.h.
◆ partPropSvc()
Access the particle property service.
Definition at line 113 of file GenBase.h.
◆ pdt()
const HepPDT::ParticleDataTable& GenBase::pdt |
( |
| ) |
const |
|
inlineinherited |
Shorter alias to get a particle data table.
Definition at line 123 of file GenBase.h.
◆ renounce()
◆ renounceArray()
◆ sumDaughterNeutrinos()
Definition at line 391 of file xAODVBFMjjIntervalFilter.cxx.
393 TLorentzVector nu(0, 0, 0, 0);
397 nu.SetPx(
part->px());
398 nu.SetPy(
part->py());
399 nu.SetPz(
part->pz());
404 if (!
part->decayVtx())
407 for (
size_t thisChild_id = 0; thisChild_id <
part->decayVtx()->nOutgoingParticles(); thisChild_id++)
409 auto daughterparticle =
part->decayVtx()->outgoingParticle(thisChild_id);
◆ sysInitialize()
StatusCode AthAlgorithm::sysInitialize |
( |
| ) |
|
|
overridevirtualinherited |
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ updateVHKA()
◆ m_alpha
double xAODVBFMjjIntervalFilter::m_alpha |
|
private |
◆ m_applyDphi
bool xAODVBFMjjIntervalFilter::m_applyDphi |
|
private |
◆ m_ApplyNjet
bool xAODVBFMjjIntervalFilter::m_ApplyNjet |
|
private |
◆ m_ApplyWeighting
bool xAODVBFMjjIntervalFilter::m_ApplyWeighting |
|
private |
◆ m_detStore
◆ m_dphijj
double xAODVBFMjjIntervalFilter::m_dphijj |
|
private |
◆ m_electronjetoverlap
bool xAODVBFMjjIntervalFilter::m_electronjetoverlap |
|
private |
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_mcEventKey
std::string GenBase::m_mcEventKey {} |
|
protectedinherited |
StoreGate key for the MC event collection (defaults to GEN_EVENT)
Definition at line 137 of file GenBase.h.
◆ m_mcevents_const
Const handle to the MC event collection.
Definition at line 163 of file GenBase.h.
◆ m_mjjhigh
double xAODVBFMjjIntervalFilter::m_mjjhigh |
|
private |
◆ m_mjjlow
double xAODVBFMjjIntervalFilter::m_mjjlow |
|
private |
◆ m_mkMcEvent
BooleanProperty GenBase::m_mkMcEvent {this, "MakeMcEvent", false, "Create a new MC event collection if it doesn't exist"} |
|
protectedinherited |
Flag to determine if a new MC event collection should be made if it doesn't exist.
Definition at line 139 of file GenBase.h.
◆ m_nFail
◆ m_NJetsMax
unsigned int xAODVBFMjjIntervalFilter::m_NJetsMax |
|
private |
◆ m_NJetsMin
unsigned int xAODVBFMjjIntervalFilter::m_NJetsMin |
|
private |
◆ m_nNeeded
◆ m_norm
double xAODVBFMjjIntervalFilter::m_norm |
|
private |
◆ m_nPass
◆ m_olapPt
double xAODVBFMjjIntervalFilter::m_olapPt |
|
private |
◆ m_photonjetoverlap
bool xAODVBFMjjIntervalFilter::m_photonjetoverlap |
|
private |
◆ m_ppSvc
ServiceHandle<IPartPropSvc> GenBase::m_ppSvc {this, "PartPropSvc", "PartPropSvc"} |
|
privateinherited |
Handle on the particle property service.
Definition at line 160 of file GenBase.h.
◆ m_prob0
double xAODVBFMjjIntervalFilter::m_prob0 |
|
private |
◆ m_prob1
double xAODVBFMjjIntervalFilter::m_prob1 |
|
private |
◆ m_prob2high
double xAODVBFMjjIntervalFilter::m_prob2high |
|
private |
◆ m_prob2low
double xAODVBFMjjIntervalFilter::m_prob2low |
|
private |
◆ m_pTavgMin
double xAODVBFMjjIntervalFilter::m_pTavgMin |
|
private |
◆ m_rndmSvc
◆ m_taujetoverlap
bool xAODVBFMjjIntervalFilter::m_taujetoverlap |
|
private |
◆ m_truncatehighmjj
bool xAODVBFMjjIntervalFilter::m_truncatehighmjj |
|
private |
◆ m_truncatelowmjj
bool xAODVBFMjjIntervalFilter::m_truncatelowmjj |
|
private |
◆ m_TruthJetContainerName
std::string xAODVBFMjjIntervalFilter::m_TruthJetContainerName |
|
private |
◆ m_varHandleArraysDeclared
◆ m_vhka
◆ m_yMax
double xAODVBFMjjIntervalFilter::m_yMax |
|
private |
The documentation for this class was generated from the following files:
def retrieve(aClass, aKey=None)
void setSeed(const std::string &algName, const EventContext &ctx)
Set the random seed using a string (e.g.
ServiceHandle< IAthRNGSvc > m_rndmSvc
double getEventWeight(ConstDataVector< xAOD::JetContainer > *jets) const
Const iterator class for DataVector/DataList.
Scalar phi() const
phi method
const_pointer_type cptr()
Dereference the pointer.
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
Scalar eta() const
pseudorapidity method
const McEventCollection * events_const() const
Access the current event's McEventCollection (const)
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
virtual StatusCode filterEvent()=0
const std::string & key() const
Return the StoreGate ID for the referenced object.
virtual StatusCode filterInitialize()
std::string m_TruthJetContainerName
virtual void setOwner(IDataHandleHolder *o)=0
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
bool isPhysical(const T &p)
Identify if the particle is physical, i.e. is stable or decayed.
ServiceHandle< IPartPropSvc > m_ppSvc
Handle on the particle property service.
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysInitialize() override
Override sysInitialize.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
TLorentzVector sumDaughterNeutrinos(const xAOD::TruthParticle *)
::StatusCode StatusCode
StatusCode definition for legacy code.
bool isElectron(const xAOD::Egamma *eg)
is the object an electron (not Fwd)
SG::ReadHandleKey< McEventCollection > m_mcevents_const
Const handle to the MC event collection.
CLHEP::HepRandomEngine * getRandomEngine(const std::string &streamName, const EventContext &ctx) const
Class describing a truth particle in the MC record.
#define CHECK(...)
Evaluate an expression and check for errors.
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
This defines the McEventCollection, which is really just an ObjectVector of McEvent objects.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
virtual void renounce()=0
const HepPDT::ParticleDataTable & particleTable() const
Get a particle data table.
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
const TruthVertex_v1 * decayVtx() const
The decay vertex of this particle.
bool m_electronjetoverlap
A wrapper class for event-slot-local random engines.
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
virtual StatusCode filterFinalize()
CLHEP::HepRandomEngine * getEngine(const EventContext &ctx) const
Retrieve the random engine corresponding to the provided EventContext.
bool ApplyMassDphi(ConstDataVector< xAOD::JetContainer > *jets)
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
DataObjIDColl m_extendedExtraObjects
bool isStable(const T &p)
Identify if the particle is stable, i.e. has not decayed.
#define ATH_MSG_WARNING(x)
DataVector adapter that acts like it holds const pointers.
bool isPhoton(const xAOD::Egamma *eg)
is the object a photon
const HepPDT::ParticleDataTable & pdt() const
Shorter alias to get a particle data table.
bool isSMNeutrino(const T &p)
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
virtual double pt() const override final
The transverse momentum ( ) of the particle.
filterPassed
now, add a sequencer: it will only execute seqalg1 and 2 and never 3
GenFilter(const std::string &name, ISvcLocator *pSvcLocator)
bool checkOverlap(double, double, const std::vector< const xAOD::TruthParticle * > &)
constexpr int pow(int base, int exp) noexcept
size_type size() const noexcept
Returns the number of elements in the collection.
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
const TruthParticle_v1 * outgoingParticle(size_t index) const
Get one of the outgoing particles.
virtual StatusCode initialize() override
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.