ATLAS Offline Software
FixHepMC.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef XAOD_ANALYSIS
6 
7 #ifndef FIX_HEPMC
8 #define FIX_HEPMC
9 
11 #include "AtlasHepMC/GenParticle.h"
12 #include "TruthUtils/Loops.h"
13 #include <set>
14 #include <memory>
15 
16 
31 class FixHepMC : public GenBase {
32 public:
33 
34  FixHepMC(const std::string& name, ISvcLocator* pSvcLocator);
37 
38 
39 private:
40 
42 
43  bool isPID0(const HepMC::ConstGenParticlePtr& p) const;
45  bool isSimpleLoop(const HepMC::ConstGenParticlePtr& p) const;
46  bool fromDecay(const HepMC::ConstGenParticlePtr& p, std::shared_ptr<std::set<int> >& storage) const;
48 
50 
51  bool m_killLoops; // Kill loops?
52  bool m_killPDG0; // Kill PDG0 particles?
53  bool m_cleanDecays; // Clean decays?
55 
57 
64 
65  std::map<int,int> m_pidmap;
66 
67 
69 
70 
71 };
72 
73 
74 #endif
75 
76 #endif
FixHepMC::m_replacedPIDs
long m_replacedPIDs
Definition: FixHepMC.h:62
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
FixHepMC::finalize
StatusCode finalize()
Definition: FixHepMC.cxx:482
FixHepMC::m_pdg0Killed
long m_pdg0Killed
Definition: FixHepMC.h:59
FixHepMC::m_cleanDecays
bool m_cleanDecays
Definition: FixHepMC.h:53
FixHepMC::execute
StatusCode execute()
Definition: FixHepMC.cxx:91
GenParticle.h
GenBase
Base class for common behaviour of MC truth algorithms.
Definition: GenBase.h:47
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
FixHepMC
A "fix-up" algorithm to correct weird event records.
Definition: FixHepMC.h:31
FixHepMC::m_decayCleaned
long m_decayCleaned
Definition: FixHepMC.h:60
FixHepMC::fromDecay
bool fromDecay(const HepMC::ConstGenParticlePtr &p, std::shared_ptr< std::set< int > > &storage) const
Definition: FixHepMC.cxx:500
Loops.h
FixHepMC::m_totalSeen
long m_totalSeen
Definition: FixHepMC.h:61
FixHepMC::m_looper
MC::Loops< HepMC::GenEvent, HepMC::ConstGenParticlePtr, HepMC::ConstGenVertexPtr > m_looper
member to detect loops
Definition: FixHepMC.h:68
HepMC::ConstGenParticlePtr
const GenParticle * ConstGenParticlePtr
Definition: GenParticle.h:38
GenBase.h
FixHepMC::isSimpleLoop
bool isSimpleLoop(const HepMC::ConstGenParticlePtr &p) const
Definition: FixHepMC.cxx:533
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
FixHepMC::isNonTransportableInDecayChain
bool isNonTransportableInDecayChain(const HepMC::ConstGenParticlePtr &p) const
Definition: FixHepMC.cxx:527
MC::Loops< HepMC::GenEvent, HepMC::ConstGenParticlePtr, HepMC::ConstGenVertexPtr >
FixHepMC::isPID0
bool isPID0(const HepMC::ConstGenParticlePtr &p) const
Definition: FixHepMC.cxx:495
FixHepMC::m_killLoops
bool m_killLoops
Definition: FixHepMC.h:51
FixHepMC::m_loopKilled
long m_loopKilled
Definition: FixHepMC.h:58
FixHepMC::m_killPDG0
bool m_killPDG0
Definition: FixHepMC.h:52
FixHepMC::m_pidmap
std::map< int, int > m_pidmap
map of pids to change.
Definition: FixHepMC.h:65
FixHepMC::FixHepMC
FixHepMC(const std::string &name, ISvcLocator *pSvcLocator)
Definition: FixHepMC.cxx:14