ATLAS Offline Software
Loading...
Searching...
No Matches
xAODEgammaBuilder.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef EGAMMAALGS_XAODEGAMMABUILDER_H
6#define EGAMMAALGS_XAODEGAMMABUILDER_H
59
61#include "GaudiKernel/ToolHandle.h"
62
66
68
74
82
83#include <memory>
84
85class egammaRec;
86
88{
89public:
90
91 xAODEgammaBuilder(const std::string& name, ISvcLocator* pSvcLocator);
92
93 StatusCode initialize() override final;
94 StatusCode finalize() override final;
95 StatusCode execute(const EventContext& ctx) const override final;
96
97private:
102 const unsigned int author, const uint8_t type) const;
103
108 const unsigned int author, uint8_t type) const;
109
111 template <typename T>
112 StatusCode CallTool(const EventContext& ctx,
113 const ToolHandle<IegammaBaseTool>& tool,
114 DataVector<T> *container) const;
115
117 ToolHandleArray<IegammaBaseTool> m_electronTools {this,
118 "ElectronTools", {}, "Tools for dressing ONLY electrons"};
119
121 ToolHandleArray<IegammaBaseTool> m_photonTools {this,
122 "PhotonTools", {}, "Tools for dressing ONLY photons"};
123
125 ToolHandle<IEMClusterTool> m_clusterTool {this,
126 "EMClusterTool", "egammaTools/EMClusterTool",
127 "Tool that does electron/photon final cluster building"};
128
130 ToolHandle<IEMShowerBuilder> m_ShowerTool {this,
131 "EMShowerTool", "egammaTools/EMShowerBuilder",
132 "Tool that does electron/photon shower shape building"};
133
135 ToolHandle<IEGammaAmbiguityTool> m_ambiguityTool {this,
136 "AmbiguityTool", "EGammaAmbiguityTool/egammaambiguitytool",
137 "Tool that does electron/photon ambiguity resolution"};
138
140 ToolHandle<IegammaOQFlagsBuilder> m_egammaOQTool {this,
141 "ObjectQualityTool", {},
142 "Tool that adds electron/photon Object Quality info"};
143
144 // Read/Write handlers
145
148 "ElectronOutputName", "ElectronContainer",
149 "Name of Electron Container to be created"};
150
153 "PhotonOutputName", "PhotonContainer",
154 "Name of Photon Container to be created"};
155
158 "InputElectronRecCollectionName",
159 "ElectronSuperRecCollection",
160 "Input container for electron Super Cluster egammaRec objects"};
161
164 "InputPhotonRecCollectionName",
165 "PhotonSuperRecCollection",
166 "Input container for electron Super Cluster egammaRec objects"};
167
169 this,
170 "CaloDetDescrManager",
171 "CaloDetDescrManager",
172 "SG Key for CaloDetDescrManager in the Condition Store"
173 };
174
177 "DummyElectronOutputName", "",
178 "Name of Dummy Electron Container to be created"};
179
180 //
181 // Other properties.
183 Gaudi::Property<bool> m_isTruth {this, "isTruth", false, "is truth"};
184 Gaudi::Property<bool> m_doPhotons {this, "doPhotons", true, "Run the Photon reconstruction"};
185 Gaudi::Property<bool> m_doElectrons {this, "doElectrons", true, "Run the Electron reconstruction"};
186 std::unique_ptr<electronPearShapeAlignmentCorrection> m_deltaEta1Pear;
188 bool m_doOQ{};
189 bool m_doDummyElectrons = false;
190};
191
192#endif
Definition of CaloDetDescrManager.
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid from which a WriteHandle is made.
xAOD::ElectronContainer * electronContainer
xAOD::PhotonContainer * photonContainer
An algorithm that can be simultaneously executed in multiple threads.
Derived DataVector<T>.
Definition DataVector.h:795
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid from which a WriteHandle is made.
Represent an egamma object for internal egamma usage during reconstruction.
Definition egammaRec.h:31
xAODEgammaBuilder(const std::string &name, ISvcLocator *pSvcLocator)
SG::ReadCondHandleKey< CaloDetDescrManager > m_caloDetDescrMgrKey
ToolHandleArray< IegammaBaseTool > m_photonTools
Vector of tools for dressing ONLY photons.
SG::WriteHandleKey< xAOD::PhotonContainer > m_photonOutputKey
Name of the photon output collection.
Gaudi::Property< bool > m_doElectrons
StatusCode initialize() override final
bool getPhoton(const egammaRec *egRec, xAOD::PhotonContainer *photonContainer, const unsigned int author, uint8_t type) const
Given an egammaRec object, a pointer to the photon container and the author, create and dress a photo...
StatusCode finalize() override final
ToolHandle< IEMShowerBuilder > m_ShowerTool
Tool to compute shower shapes.
std::unique_ptr< electronPearShapeAlignmentCorrection > m_deltaEta1Pear
ToolHandle< IEGammaAmbiguityTool > m_ambiguityTool
Tool to resolve electron/photon ambiguity.
SG::WriteHandleKey< xAOD::ElectronContainer > m_electronOutputKey
Name of the electron output collection.
Gaudi::Property< bool > m_isTruth
Option to do truth.
SG::WriteHandleKey< xAOD::ElectronContainer > m_dummyElectronOutputKey
Name of the dummy electron output collection.
StatusCode CallTool(const EventContext &ctx, const ToolHandle< IegammaBaseTool > &tool, DataVector< T > *container) const
Call a tool using contExecute and an electron or photon container.
SG::ReadHandleKey< EgammaRecContainer > m_electronClusterRecContainerKey
Name of input super cluster electron egammaRec container.
ToolHandle< IEMClusterTool > m_clusterTool
Tool to do the final electron/photon cluster building.
bool getElectron(const egammaRec *egRec, xAOD::ElectronContainer *electronContainer, const unsigned int author, const uint8_t type) const
Given an egammaRec object, a pointer to the electron container and the author, create and dress an el...
SG::ReadHandleKey< EgammaRecContainer > m_photonClusterRecContainerKey
Name of input super cluster photon egammaRec container.
ToolHandleArray< IegammaBaseTool > m_electronTools
Vector of tools for dressing ONLY electrons.
Gaudi::Property< bool > m_doPhotons
StatusCode execute(const EventContext &ctx) const override final
ToolHandle< IegammaOQFlagsBuilder > m_egammaOQTool
Tool to add electron/photon Object Quality info.
PhotonContainer_v1 PhotonContainer
Definition of the current "photon container version".
ElectronContainer_v1 ElectronContainer
Definition of the current "electron container version".