ATLAS Offline Software
Loading...
Searching...
No Matches
EMShowerBuilder.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef EGAMMATOOLS_EMSHOWERBUILDER_H
6#define EGAMMATOOLS_EMSHOWERBUILDER_H
27
28// INCLUDE HEADER FILES:
29
33
35#include "GaudiKernel/AlgTool.h"
36#include "GaudiKernel/Algorithm.h"
37#include "GaudiKernel/ToolHandle.h"
39
45
46class StoreGateSvc;
48class IChronoStatSvc;
50
51class EMShowerBuilder final
52 : public AthAlgTool
53 , virtual public IEMShowerBuilder
54{
55public:
57 EMShowerBuilder(const std::string& type,
58 const std::string& name,
59 const IInterface* parent);
60
62 ~EMShowerBuilder() = default;
63
65 virtual StatusCode initialize() override final;
67 virtual StatusCode execute(const EventContext& ctx,
69 xAOD::Egamma*) const override final;
70
71 virtual StatusCode executeWithCells(const CaloCellContainer* cellcoll,
73 xAOD::Egamma*) const override final;
75 virtual StatusCode finalize() override;
76
79 template <typename T> StatusCode RetrieveTool(ToolHandle<T> &tool, bool tool_requested);
81 StatusCode CalcShowerShape(xAOD::Egamma* eg,
83 const CaloCellContainer* cellcoll) const;
85 StatusCode CalcHadronicLeakage(xAOD::Egamma* eg,
87 const xAOD::CaloCluster* clus,
88 const CaloCellContainer* cellcoll) const;
90 StatusCode FillEMShowerShape(xAOD::Egamma* eg,
91 const IegammaShowerShape::Info& info) const;
92
95 this,
96 "CellsName",
97 "AllCalo",
98 "Names of containers which contain cells"
99 };
100
102 Gaudi::Property<std::vector<int>> m_caloNums{ this,
103 "CaloNums",
104 {},
105 "list of calo to treat" };
106
108 ToolHandle<IegammaShowerShape> m_ShowerShapeTool{
109 this,
110 "ShowerShapeTool",
111 "egammaShowerShape/egammashowershape",
112 "Handle of instance of egammaShowerShape Tool to be run"
113 };
114
116 ToolHandle<IegammaIso> m_HadronicLeakageTool{
117 this,
118 "HadronicLeakageTool",
119 "egammaIso",
120 "Handle of the EMCaloIsolationTool for Hadronic leakage"
121 };
122
124 Gaudi::Property<bool> m_Print{ this,
125 "Print",
126 false,
127 "in case of extra prints" };
128
131 Gaudi::Property<bool> m_UseShowerShapeTool{
132 this,
133 "UseShowerShapeTool",
134 true,
135 "Boolean to call shower shape calculation and filling"
136 };
137
140 Gaudi::Property<bool> m_UseCaloIsoTool{
141 this,
142 "UseCaloIsoTool",
143 true,
144 "Boolean to call hadronic leakage calculation and filling"
145 };
146
148 Gaudi::Property<bool> m_isCosmics{ this,
149 "isCosmics",
150 false,
151 "Boolean for use of cosmics" };
152};
153
154#endif
Property holding a SG store/key/clid from which a ReadHandle is made.
AthAlgTool(const std::string &type, const std::string &name, const IInterface *parent)
Constructor with parameters:
Container class for CaloCell.
Principal data class for CaloCell clusters.
This class provides the client interface for accessing the detector description information common to...
virtual StatusCode executeWithCells(const CaloCellContainer *cellcoll, const CaloDetDescrManager &cmgr, xAOD::Egamma *) const override final
@Execute passing the cells explicitly
StatusCode CalcShowerShape(xAOD::Egamma *eg, const CaloDetDescrManager &cmgr, const CaloCellContainer *cellcoll) const
calculate shower shapes
virtual StatusCode initialize() override final
initialize method
Gaudi::Property< bool > m_Print
boolean to print results
Gaudi::Property< std::vector< int > > m_caloNums
Obsolete enum on the layers to use for the HadLeakage variables.
StatusCode CalcHadronicLeakage(xAOD::Egamma *eg, const CaloDetDescrManager &cmgr, const xAOD::CaloCluster *clus, const CaloCellContainer *cellcoll) const
calculate Hadronic leakage
virtual StatusCode execute(const EventContext &ctx, const CaloDetDescrManager &cmgr, xAOD::Egamma *) const override final
standard execute method
StatusCode RetrieveTool(ToolHandle< T > &tool, bool tool_requested)
Wraps tool retrieval to ensure it is has a name.
Gaudi::Property< bool > m_UseShowerShapeTool
Boolean to call shower shape calculation and filling (NB: this could be important when redoing calcul...
ToolHandle< IegammaIso > m_HadronicLeakageTool
Tool for hadronic leakage calculation.
Gaudi::Property< bool > m_isCosmics
boolean to know if we are looking at cosmic data
virtual StatusCode finalize() override
finalize method
~EMShowerBuilder()=default
Destructor.
ToolHandle< IegammaShowerShape > m_ShowerShapeTool
Tool for shower shape calculation.
StatusCode FillEMShowerShape(xAOD::Egamma *eg, const IegammaShowerShape::Info &info) const
fill shower detail from shower shape calculation
SG::ReadHandleKey< CaloCellContainer > m_cellsKey
Cell container.
Gaudi::Property< bool > m_UseCaloIsoTool
Boolean to call calo isolation variables calculation and filling (NB: this could be important when re...
EMShowerBuilder(const std::string &type, const std::string &name, const IInterface *parent)
Default constructor.
Interface for the Reconstruction/egamma/egammaRec/EMShowerBuilder.
Interface for the Reconstruction/egamma/egammaCaloTools/egammaShowerShape.
The Athena Transient Store API.
Forward declaration.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
#define private