ATLAS Offline Software
CompactHardTruth.h
Go to the documentation of this file.
1 
3 /*
4  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 // CompactHardTruth.h
8 // Header file for class CompactHardTruth
9 // Author: Frank Paige <paige@bnl.gov>
10 //
11 // Algorithm to construct small, consistent hard-scattering HepMC truth
12 // record from GEN_EVENT. Only final partons have physical momenta, so
13 // must recluster them. Main steps:
14 // (1) Identify hadronization vertices with partons in, hadrons out.
15 // (2) Detach their incoming partons and delete their descendants.
16 // (3) Iteratively recombine 1->2 branchings of final partons with
17 // mass M < Mcut. Split 2->1 nonperturbative color recombinations.
18 // (4) Remove partons not connected to hard process. May make apparent
19 // anomalies, e.g., dropping soft q from incoming g -> g q.
20 //
21 // New final partons have correct momenta and ancestors/descendants.
22 // CompactHardTruth changes particles/vertices, so it cannot be used directly
23 // with thinning, but it can be used in parallel.
24 //
26 #ifndef DERIVATIONFRAMEWORK_COMPACTHARDTRUTH_H
27 #define DERIVATIONFRAMEWORK_COMPACTHARDTRUTH_H 1
28 
29 // STL includes
30 #include <string>
31 
32 // FrameWork includes
34 #include "AtlasHepMC/GenVertex_fwd.h" //HepMC::ConstGenVertexPtr
35 #include "AtlasHepMC/SimpleVector.h" //HepMC::FourVector typedef
36 
37 
38 namespace DerivationFramework {
39 
41  : public ::AthAlgorithm
42 {
43 
45  // Public methods:
47  public:
48 
50  CompactHardTruth( const std::string& name, ISvcLocator* pSvcLocator );
51 
53  virtual ~CompactHardTruth();
54 
55  // Athena algorithm Hooks
56  virtual StatusCode initialize();
57  virtual StatusCode execute();
58  virtual StatusCode finalize();
59 
60  // Total in/out FourVector for vertex
61  virtual HepMC::FourVector vtxInMom(HepMC::ConstGenVertexPtr);
62  virtual HepMC::FourVector vtxOutMom(HepMC::ConstGenVertexPtr);
63 
64  private:
65 
68 
70  std::string m_mcEventsName;
71  std::string m_thinnedMcEventsName;
72 
73  // Variables
74  int m_evtCount = 0;
75  int m_missCount = 0;
76  float m_partonCut{};
77  float m_hardCut{};
78 
79  int m_dangleFound = 0;
80  int m_dangleRemoved = 0;
81  float m_danglePtMax = 0.0F;
82  float m_danglePtCut{};
83 
84  int m_maxCount{};
85 
86  int m_thinParticles = 0;
87  int m_thinVertices = 0;
88 
89 };
90 
91 
92 } //> end namespace DerivationFramework
93 #endif //> !DERIVATIONFRAMEWORK_COMPACTHARDTRUTH_H
DerivationFramework::CompactHardTruth::m_maxCount
int m_maxCount
Definition: CompactHardTruth.h:84
DerivationFramework::CompactHardTruth::m_missCount
int m_missCount
Definition: CompactHardTruth.h:75
DerivationFramework::CompactHardTruth::execute
virtual StatusCode execute()
Definition: CompactHardTruth.cxx:104
DerivationFramework::CompactHardTruth
Definition: CompactHardTruth.h:42
DerivationFramework::CompactHardTruth::m_dangleFound
int m_dangleFound
Definition: CompactHardTruth.h:79
AthAlgorithm.h
DerivationFramework::CompactHardTruth::m_danglePtCut
float m_danglePtCut
Definition: CompactHardTruth.h:82
SimpleVector.h
DerivationFramework::CompactHardTruth::initialize
virtual StatusCode initialize()
Definition: CompactHardTruth.cxx:64
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
GenVertex_fwd.h
DerivationFramework
THE reconstruction tool.
Definition: ParticleSortingAlg.h:24
DerivationFramework::CompactHardTruth::~CompactHardTruth
virtual ~CompactHardTruth()
Destructor:
Definition: CompactHardTruth.cxx:60
AthAlgorithm
Definition: AthAlgorithm.h:47
DerivationFramework::CompactHardTruth::finalize
virtual StatusCode finalize()
Definition: CompactHardTruth.cxx:88
DerivationFramework::CompactHardTruth::m_thinVertices
int m_thinVertices
Definition: CompactHardTruth.h:87
DerivationFramework::CompactHardTruth::m_mcEventsName
std::string m_mcEventsName
Containers.
Definition: CompactHardTruth.h:70
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
DerivationFramework::CompactHardTruth::m_partonCut
float m_partonCut
Definition: CompactHardTruth.h:76
DerivationFramework::CompactHardTruth::m_hardCut
float m_hardCut
Definition: CompactHardTruth.h:77
DerivationFramework::CompactHardTruth::vtxInMom
virtual HepMC::FourVector vtxInMom(HepMC::ConstGenVertexPtr)
Definition: CompactHardTruth.cxx:1380
DerivationFramework::CompactHardTruth::m_danglePtMax
float m_danglePtMax
Definition: CompactHardTruth.h:81
DerivationFramework::CompactHardTruth::m_evtCount
int m_evtCount
Definition: CompactHardTruth.h:74
DerivationFramework::CompactHardTruth::m_thinnedMcEventsName
std::string m_thinnedMcEventsName
Definition: CompactHardTruth.h:71
DerivationFramework::CompactHardTruth::CompactHardTruth
CompactHardTruth()
Default constructor:
HepMC::ConstGenVertexPtr
const HepMC::GenVertex * ConstGenVertexPtr
Definition: GenVertex.h:60
DerivationFramework::CompactHardTruth::m_dangleRemoved
int m_dangleRemoved
Definition: CompactHardTruth.h:80
DerivationFramework::CompactHardTruth::vtxOutMom
virtual HepMC::FourVector vtxOutMom(HepMC::ConstGenVertexPtr)
Definition: CompactHardTruth.cxx:1402
DerivationFramework::CompactHardTruth::m_thinParticles
int m_thinParticles
Definition: CompactHardTruth.h:86