ATLAS Offline Software
Loading...
Searching...
No Matches
egammaTransformerSvc.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef EGAMMATRANSFORMERCALIB_EGAMMATRANSFORMERSVC_H
6#define EGAMMATRANSFORMERCALIB_EGAMMATRANSFORMERSVC_H
7
11// Framework includes
14
16
17
18#include <string>
19
20
21class egammaTransformerSvc : public extends<asg::AsgService, IegammaMVASvc>
22{
23public:
24 using extends::extends; // base class constructor
25
26 virtual ~egammaTransformerSvc() override {};
27 virtual StatusCode initialize() override;
28
30 // Note for both egammaTransformerSvc::getEnergy overloads below:
31 // zero-response handling is delegated to the underlying calibration tools
32 // (m_mvaElectron/m_mvaFwdElectron/m_mvaConvertedPhoton/m_mvaUnconvertedPhoton).
33 // By default their property useClusterIf0 (m_clusterEif0) is true, so a zero
34 // model response returns the uncalibrated cluster energy instead of 0.
35 // Therefore mvaE is not expected to be 0 by default unless the user
36 // explicitly changes that tool property in the calibration configuration.
37 StatusCode getEnergy(const xAOD::CaloCluster& cluster,
38 const xAOD::Egamma& eg,
39 double& mvaE,
41
43 StatusCode getEnergy(const xAOD::CaloCluster& cluster,
44 const xAOD::EgammaParameters::EgammaType egType,
45 double& mvaE,
46 const egammaMVACalib::GlobalEventInfo& gei = egammaMVACalib::GlobalEventInfo()) const override final;
47
53 StatusCode execute(xAOD::CaloCluster& cluster,
54 const xAOD::Egamma& eg,
55 const egammaMVACalib::GlobalEventInfo& gei = egammaMVACalib::GlobalEventInfo()) const override final;
56
61 StatusCode execute(xAOD::CaloCluster& cluster,
62 const xAOD::EgammaParameters::EgammaType egType,
63 const egammaMVACalib::GlobalEventInfo& gei = egammaMVACalib::GlobalEventInfo()) const override final;
64
65
67
70 "ElectronTool", "", "Tool to handle MVA trees for electrons"};
71
73 ToolHandle<IegammaMVACalibTool> m_mvaFwdElectron {this,
74 "FwdElectronTool", "", "Tool to handle MVA trees for forward electrons"};
75
77 ToolHandle<IegammaMVACalibTool> m_mvaUnconvertedPhoton {this,
78 "UnconvertedPhotonTool", "", "Tool to handle MVA trees for unconverted photons"};
79
81 ToolHandle<IegammaMVACalibTool> m_mvaConvertedPhoton {this,
82 "ConvertedPhotonTool", "", "Tool to handle MVA trees for converted photons"};
83
84 Gaudi::Property<float> m_maxConvR {this,
85 "MaxConvRadius", 800.0,
86 "The maximum conversion radius for a photon to be considered converted"};
87
88 Gaudi::Property<int> m_removeTRTConvBarrel {this,
89 "RemoveTRTConvBarrel", -1,
90 "Remove TRT converted photons in the barrel: no=0, yes=1, automatic=-1"};
91
92 Gaudi::Property<std::string> m_folder {this,
93 "folder", "", "folder for weight files"};
94
95
99 bool isConvCalib(const xAOD::Photon& ph) const;
100
101 StatusCode resolve_flags();
102
103
104};
105
106#endif
Principal data class for CaloCell clusters.
A tool used by the egammaMVASvc to help manage the MVAs.
ToolHandle< IegammaMVACalibTool > m_mvaElectron
MVA tool for electron.
virtual ~egammaTransformerSvc() override
Gaudi::Property< int > m_removeTRTConvBarrel
ToolHandle< IegammaMVACalibTool > m_mvaFwdElectron
MVA tool for forward electron.
virtual StatusCode initialize() override
bool isConvCalib(const xAOD::Photon &ph) const
Decide if the photon is converted or not.
Gaudi::Property< std::string > m_folder
ToolHandle< IegammaMVACalibTool > m_mvaConvertedPhoton
MVA tool for converted photon.
StatusCode getEnergy(const xAOD::CaloCluster &cluster, const xAOD::Egamma &eg, double &mvaE, const egammaMVACalib::GlobalEventInfo &gei=egammaMVACalib::GlobalEventInfo()) const override final
Compute the calibrated energy.
ToolHandle< IegammaMVACalibTool > m_mvaUnconvertedPhoton
MVA tool for unconverted photon.
Gaudi::Property< float > m_maxConvR
StatusCode execute(xAOD::CaloCluster &cluster, const xAOD::Egamma &eg, const egammaMVACalib::GlobalEventInfo &gei=egammaMVACalib::GlobalEventInfo()) const override final
Main execute.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
CaloCluster_v1 CaloCluster
Define the latest version of the calorimeter cluster class.
Egamma_v1 Egamma
Definition of the current "egamma version".
Definition Egamma.h:17
Photon_v1 Photon
Definition of the current "egamma version".
A structure holding some global event information.
#define private