Loading [MathJax]/extensions/tex2jax.js
ATLAS Offline Software
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
Classes | Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
CP::EgammaCalibrationAndSmearingTool Class Referenceabstract

#include <EgammaCalibrationAndSmearingTool.h>

Inheritance diagram for CP::EgammaCalibrationAndSmearingTool:
Collaboration diagram for CP::EgammaCalibrationAndSmearingTool:

Classes

struct  AbsEtaCaloPredicate
 
struct  DoubleOrAbsEtaCaloPredicate
 
struct  EtaCaloPredicate
 
struct  SysInfo
 

Public Member Functions

virtual double getEnergy (xAOD::Egamma *, const xAOD::EventInfo *)
 
virtual double getElectronMomentum (const xAOD::Electron *, const xAOD::EventInfo *)
 
double getResolution (const xAOD::Egamma &particle, bool withCT=true) const override
 
double intermodule_correction (double Ecl, double phi, double eta) const
 
double correction_phi_unif (double eta, double phi) const
 
virtual void print () const =0
 Print the state of the tool. More...
 
virtual StatusCode sysInitialize ()
 Function initialising the tool in the correct way in Athena. More...
 
virtual void print () const
 Print the state of the tool. More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

enum  ResolutionDecorrelation { ResolutionDecorrelation::FULL, ResolutionDecorrelation::ONENP }
 
typedef unsigned int RandomNumber
 
typedef std::function< int(const EgammaCalibrationAndSmearingTool &, const xAOD::Egamma &, const xAOD::EventInfo &)> IdFunction
 
typedef std::function< bool(const xAOD::Egamma &)> EgammaPredicate
 
typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

 EgammaCalibrationAndSmearingTool (const std::string &name)
 
 ~EgammaCalibrationAndSmearingTool ()
 
StatusCode initialize () override
 
virtual CP::CorrectionCode applyCorrection (xAOD::Egamma &) const override
 
virtual CP::CorrectionCode applyCorrection (xAOD::Egamma &input, const xAOD::EventInfo &event_info) const
 
virtual CP::CorrectionCode correctedCopy (const xAOD::Electron &, xAOD::Electron *&) const override
 
virtual CP::CorrectionCode correctedCopy (const xAOD::Photon &, xAOD::Photon *&) const override
 
double getEnergy (const xAOD::Photon &) const
 
double getEnergy (const xAOD::Electron &) const
 
virtual CP::SystematicSet affectingSystematics () const override
 the list of all systematics this tool can be affected by More...
 
virtual bool isAffectedBySystematic (const CP::SystematicVariation &systematic) const override
 Declare the interface that this class provides. More...
 
virtual CP::SystematicSet recommendedSystematics () const override
 the list of all systematics this tool recommends to use More...
 
virtual StatusCode applySystematicVariation (const CP::SystematicSet &systConfig) override
 effects: configure this tool for the given list of systematic variations. More...
 
virtual void setRandomSeedFunction (const IdFunction &&function)
 
const IdFunction getRandomSeedFunction () const
 
virtual double resolution (double energy, double cl_eta, double cl_etaCalo, PATCore::ParticleType::Type ptype=PATCore::ParticleType::Electron, bool withCT=false) const override
 
void setupSystematics ()
 
const EgammaPredicate EtaCaloPredicateFactory (double eta_min, double eta_max) const
 
const EgammaPredicate AbsEtaCaloPredicateFactory (double eta_min, double eta_max) const
 
const EgammaPredicate AbsEtaCaloPredicateFactory (std::pair< double, double > edges) const
 
const std::vector< EgammaPredicateAbsEtaCaloPredicatesFactory (const std::vector< std::pair< double, double >> &edges) const
 
const std::vector< EgammaPredicateAbsEtaCaloPredicatesFactory (const std::vector< double > &edges) const
 
const EgammaPredicate DoubleOrAbsEtaCaloPredicateFactory (double eta1_min, double eta1_max, double eta2_min, double eta2_max) const
 
PATCore::ParticleType::Type xAOD2ptype (const xAOD::Egamma &particle) const
 
egEnergyCorr::Scale::Variation oldtool_scale_flag_this_event (const xAOD::Egamma &p, const xAOD::EventInfo &event_info) const
 
egEnergyCorr::Resolution::Variation oldtool_resolution_flag_this_event (const xAOD::Egamma &p, const xAOD::EventInfo &event_info) const
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

std::string m_ESModel
 
std::string m_decorrelation_model_name
 
std::string m_decorrelation_model_scale_name
 
std::string m_decorrelation_model_resolution_name
 
ScaleDecorrelation m_decorrelation_model_scale = ScaleDecorrelation::FULL
 
ResolutionDecorrelation m_decorrelation_model_resolution
 
egEnergyCorr::ESModel m_TESModel
 
int m_doScaleCorrection
 
int m_doSmearing
 
double m_varSF
 
std::string m_ResolutionType
 
egEnergyCorr::Resolution::resolutionType m_TResolutionType
 
int m_useFastSim
 
int m_use_AFII
 
PATCore::ParticleDataType::DataType m_simulation
 
int m_useIntermoduleCorrection
 
int m_usePhiUniformCorrection
 
int m_useCaloDistPhiUnifCorrection
 
int m_useGainCorrection
 
int m_doADCLinearityCorrection
 
int m_doLeakageCorrection
 
bool m_use_ep_combination
 
int m_use_mva_calibration
 
bool m_use_full_statistical_error
 
int m_use_temp_correction201215
 
int m_use_uA2MeV_2015_first2weeks_correction
 
bool m_use_mapping_correction
 
int m_user_random_run_number
 
int m_useGainInterpolation
 
int m_useLayerCorrection
 
int m_usePSCorrection
 
int m_useS12Correction
 
int m_useSaccCorrection
 
bool m_decorateEmva
 
std::unique_ptr< TH2 > m_caloDistPhiUnifCorr
 
Gaudi::Property< bool > m_fixForMissingCells
 
ServiceHandle< IegammaMVASvcm_MVACalibSvc
 
std::unique_ptr< egGain::GainUncertaintym_gain_tool_run2
 
std::shared_ptr< LinearityADCm_ADCLinearity_tool
 
egGain::GainToolm_gain_tool = nullptr
 
egammaLayerRecalibToolm_layer_recalibration_tool = nullptr
 
std::string m_layer_recalibration_tune
 
std::unique_ptr< AtlasRoot::egammaEnergyCorrectionToolm_rootTool
 
std::string m_MVAfolder
 
std::map< CP::SystematicVariation, SysInfom_syst_description
 
std::map< CP::SystematicVariation, egEnergyCorr::Resolution::Variationm_syst_description_resolution
 
egEnergyCorr::Scale::Variation m_currentScaleVariation_MC
 
egEnergyCorr::Scale::Variation m_currentScaleVariation_data
 
egEnergyCorr::Resolution::Variation m_currentResolutionVariation_MC
 
egEnergyCorr::Resolution::Variation m_currentResolutionVariation_data
 
EgammaPredicate m_currentScalePredicate
 
IdFunction m_set_seed_function
 
MetaStore_t m_inputMetaStore
 Object accessing the input metadata store. More...
 
MetaStore_t m_outputMetaStore
 Object accessing the output metadata store. More...
 
bool m_beginInputFileCalled
 Flag helping to discover when the tool misses the opening of the first input file. More...
 
bool m_useIncidents
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Static Private Attributes

static const int AUTO = 2
 
static const unsigned int m_Run2Run3runNumberTransition = 400000
 

Callback functions helping in metadata reading/writing

void setUseIncidents (const bool flag)
 
virtual void handle (const Incident &inc)
 Function receiving incidents from IncidentSvc/TEvent. More...
 
virtual StatusCode beginInputFile ()
 Function called when a new input file is opened. More...
 
virtual StatusCode endInputFile ()
 Function called when the currently open input file got completely processed. More...
 
virtual StatusCode beginEvent ()
 Function called when a new events is loaded. More...
 
virtual StatusCode metaDataStop ()
 Function called when the tool should write out its metadata. More...
 

Detailed Description

Definition at line 89 of file EgammaCalibrationAndSmearingTool.h.

Member Typedef Documentation

◆ EgammaPredicate

Definition at line 111 of file EgammaCalibrationAndSmearingTool.h.

◆ IdFunction

Definition at line 110 of file EgammaCalibrationAndSmearingTool.h.

◆ MetaStore_t

Type of the metadata store object in Athena.

Definition at line 66 of file AsgMetadataTool.h.

◆ MetaStorePtr_t

Type of the metadata store pointer in standalone mode.

Definition at line 68 of file AsgMetadataTool.h.

◆ RandomNumber

Definition at line 107 of file EgammaCalibrationAndSmearingTool.h.

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Member Enumeration Documentation

◆ ResolutionDecorrelation

Enumerator
FULL 
ONENP 

Definition at line 104 of file EgammaCalibrationAndSmearingTool.h.

104 { FULL, ONENP };

Constructor & Destructor Documentation

◆ EgammaCalibrationAndSmearingTool()

CP::EgammaCalibrationAndSmearingTool::EgammaCalibrationAndSmearingTool ( const std::string &  name)
private

Definition at line 278 of file EgammaCalibrationAndSmearingTool.cxx.

289  const xAOD::Egamma& egamma,
290  const xAOD::EventInfo& ei) {
291  // avoid 0 as result, see
292  // https://root.cern.ch/root/html/TRandom3.html#TRandom3:SetSeed
293  return 1 + static_cast<RandomNumber>(
294  std::abs(egamma.caloCluster()->phi()) * 1E6 +
295  std::abs(egamma.caloCluster()->eta()) * 1E3 +
296  ei.eventNumber());
297  }) {
298 
299  declareProperty("ESModel", m_ESModel = "");
300  declareProperty("decorrelationModel", m_decorrelation_model_name = "");
301  declareProperty("decorrelationModelScale",
303  declareProperty("decorrelationModelResolution",
305  declareProperty("ResolutionType", m_ResolutionType = "SigmaEff90");
306  declareProperty("varSF", m_varSF = 1.0);
307  declareProperty("doScaleCorrection", m_doScaleCorrection = AUTO);
308  declareProperty("doSmearing", m_doSmearing = AUTO);
309  declareProperty("useLayerCorrection", m_useLayerCorrection = AUTO);
310  declareProperty("usePSCorrection", m_usePSCorrection = AUTO);
311  declareProperty("useS12Correction", m_useS12Correction = AUTO);
312  declareProperty("useSaccCorrection", m_useSaccCorrection = AUTO);
313  declareProperty("useIntermoduleCorrection",
315  declareProperty("usePhiUniformCorrection", m_usePhiUniformCorrection = AUTO);
316  declareProperty("useCaloDistPhiUnifCorrection",
318  declareProperty("useGainCorrection", m_useGainCorrection = AUTO);
319  declareProperty("useGainInterpolation", m_useGainInterpolation = AUTO);
320  declareProperty("doADCLinearityCorrection",
322  declareProperty("doLeakageCorrection", m_doLeakageCorrection = AUTO);
323  declareProperty("MVAfolder", m_MVAfolder = "");
324  declareProperty("layerRecalibrationTune", m_layer_recalibration_tune = "");
325  declareProperty("useEPCombination", m_use_ep_combination = false);
326  declareProperty("useMVACalibration", m_use_mva_calibration = AUTO);
327  declareProperty("use_full_statistical_error",
329  declareProperty("use_temp_correction201215",
331  declareProperty("use_uA2MeV_2015_first2weeks_correction",
333  declareProperty("randomRunNumber", m_user_random_run_number = 0);
334  // this is the user input, it is never changed by the tool. The tool uses
335  // m_simulation.
336  declareProperty("useFastSim", m_useFastSim = -1,
337  "This should be explicitly set by the user depending on the "
338  "data type (int)0=full sim, (int)1=fast sim");
340  "useAFII", m_use_AFII = -1,
341  "This is now deprecated. Kept for explicit error message for now");
342  declareProperty("decorateEmva", m_decorateEmva = false, "whether to decorate the eMVA value");
343 }

◆ ~EgammaCalibrationAndSmearingTool()

CP::EgammaCalibrationAndSmearingTool::~EgammaCalibrationAndSmearingTool ( )
private

Definition at line 345 of file EgammaCalibrationAndSmearingTool.cxx.

345  {
346  ATH_MSG_DEBUG("destructor");
348  delete m_gain_tool;
349 }

Member Function Documentation

◆ AbsEtaCaloPredicateFactory() [1/2]

const EgammaPredicate CP::EgammaCalibrationAndSmearingTool::AbsEtaCaloPredicateFactory ( double  eta_min,
double  eta_max 
) const
inlineprivate

Definition at line 237 of file EgammaCalibrationAndSmearingTool.h.

238  {
239  /*return [eta_min, eta_max](const xAOD::Egamma& p) {
240  const double aeta = std::abs(xAOD::get_eta_calo(*p.caloCluster()));
241  return (aeta >= eta_min and aeta < eta_max); };*/
242  return AbsEtaCaloPredicate(eta_min, eta_max);
243  }

◆ AbsEtaCaloPredicateFactory() [2/2]

const EgammaPredicate CP::EgammaCalibrationAndSmearingTool::AbsEtaCaloPredicateFactory ( std::pair< double, double >  edges) const
inlineprivate

Definition at line 245 of file EgammaCalibrationAndSmearingTool.h.

246  {
247  return AbsEtaCaloPredicateFactory(edges.first, edges.second);
248  }

◆ AbsEtaCaloPredicatesFactory() [1/2]

const std::vector<EgammaPredicate> CP::EgammaCalibrationAndSmearingTool::AbsEtaCaloPredicatesFactory ( const std::vector< double > &  edges) const
inlineprivate

Definition at line 260 of file EgammaCalibrationAndSmearingTool.h.

261  {
262  std::vector<EgammaPredicate> result;
263  result.reserve(edges.size() - 1);
264  auto it2 = edges.begin();
265  auto it = it2++;
266  for (; it2 != edges.end(); ++it, ++it2) {
267  result.push_back(AbsEtaCaloPredicateFactory(*it, *it2));
268  }
269  return result;
270  }

◆ AbsEtaCaloPredicatesFactory() [2/2]

const std::vector<EgammaPredicate> CP::EgammaCalibrationAndSmearingTool::AbsEtaCaloPredicatesFactory ( const std::vector< std::pair< double, double >> &  edges) const
inlineprivate

Definition at line 250 of file EgammaCalibrationAndSmearingTool.h.

251  {
252  std::vector<EgammaPredicate> result;
253  result.reserve(edges.size());
254  for (const auto& it : edges) {
255  result.push_back(AbsEtaCaloPredicateFactory(it.first, it.second));
256  }
257  return result;
258  }

◆ affectingSystematics()

CP::SystematicSet CP::EgammaCalibrationAndSmearingTool::affectingSystematics ( ) const
overrideprivatevirtual

the list of all systematics this tool can be affected by

Implements CP::IReentrantSystematicsTool.

Definition at line 1193 of file EgammaCalibrationAndSmearingTool.cxx.

1194  {
1195  CP::SystematicSet affecting_systematics;
1196  for (const auto& it : m_syst_description) {
1197  affecting_systematics.insert(it.first);
1198  }
1199  for (const auto& it : m_syst_description_resolution) {
1200  affecting_systematics.insert(it.first);
1201  }
1202 
1203  return affecting_systematics;
1204 }

◆ applyCorrection() [1/2]

CP::CorrectionCode CP::EgammaCalibrationAndSmearingTool::applyCorrection ( xAOD::Egamma input) const
overrideprivatevirtual

Implements CP::IEgammaCalibrationAndSmearingTool.

Definition at line 857 of file EgammaCalibrationAndSmearingTool.cxx.

858  {
859  // Retrieve the event information:
860  const xAOD::EventInfo* event_info = nullptr;
861  if (evtStore()->retrieve(event_info, "EventInfo").isFailure()) {
862  ATH_MSG_ERROR("No EventInfo object could be retrieved");
864  }
865  return applyCorrection(input, *event_info);
866 }

◆ applyCorrection() [2/2]

CP::CorrectionCode CP::EgammaCalibrationAndSmearingTool::applyCorrection ( xAOD::Egamma input,
const xAOD::EventInfo event_info 
) const
privatevirtual

Definition at line 912 of file EgammaCalibrationAndSmearingTool.cxx.

913  {
914 
915  // only used in simulation (for the smearing)
916  RandomNumber seed = m_set_seed_function(*this, input, event_info);
917 
918  static const SG::ConstAccessor<double> Es0Acc("correctedcl_Es0");
919  static const SG::ConstAccessor<double> Es1Acc("correctedcl_Es1");
920  static const SG::ConstAccessor<double> Es2Acc("correctedcl_Es2");
921  static const SG::ConstAccessor<double> Es3Acc("correctedcl_Es3");
922 
924  ATH_MSG_DEBUG("applying energy recalibration before E0|E1|E2|E3 = "
925  << input.caloCluster()->energyBE(0) << "|"
926  << input.caloCluster()->energyBE(1) << "|"
927  << input.caloCluster()->energyBE(2) << "|"
928  << input.caloCluster()->energyBE(3));
929  const CP::CorrectionCode status_layer_recalibration =
930  m_layer_recalibration_tool->applyCorrection(input, event_info);
931  if (status_layer_recalibration == CP::CorrectionCode::Error) {
933  }
934  ATH_MSG_DEBUG("eta|phi = " << input.eta() << "|" << input.phi());
935  if (status_layer_recalibration == CP::CorrectionCode::Ok) {
936  ATH_MSG_DEBUG("decoration E0|E1|E2|E3 = "
937  << Es0Acc(*input.caloCluster()) << "|"
938  << Es1Acc(*input.caloCluster()) << "|"
939  << Es2Acc(*input.caloCluster()) << "|"
940  << Es3Acc(*input.caloCluster()) << "|");
941  if (Es2Acc(*input.caloCluster()) == 0 and
942  Es1Acc(*input.caloCluster()) == 0 and
943  Es3Acc(*input.caloCluster()) == 0 and
944  Es0Acc(*input.caloCluster()) == 0 and
945  (std::abs(input.eta()) < 1.37 or
946  (std::abs(input.eta()) > 1.55 and std::abs(input.eta()) < 2.47))) {
947  ATH_MSG_WARNING("all layer energies are zero");
948  }
949  }
950  }
951 
952  double energy = 0.;
953  // apply MVA calibration
954  if (!m_MVACalibSvc.empty()) {
955  if (input.author() !=
956  xAOD::EgammaParameters::AuthorFwdElectron) { // do not apply MVA
957  // calibration to fwd
958  // electrons
959  m_MVACalibSvc->getEnergy(*input.caloCluster(), input, energy)
960  .ignore(); // TODO check StatusCode
961  } else {
962  energy = input.e();
963  }
964  ATH_MSG_DEBUG("energy after MVA calibration = " << std::format("{:.2f}", energy));
965  } else {
966  energy = input.e();
967  }
968  if (m_decorateEmva)
969  {
970  static const SG::AuxElement::Decorator<float> decEmva("E_mva_only");
971  decEmva(input) = energy;
972  }
973 
975  // Crack calibation correction for es2011c (calibration hits calibration)
976  const auto ptype = xAOD2ptype(input);
977  const double etaden =
979  ? static_cast<xAOD::Electron&>(input).trackParticle()->eta()
980  : input.caloCluster()->eta();
981  energy *= m_rootTool->applyMCCalibration(input.caloCluster()->eta(),
982  energy / cosh(etaden), ptype);
983  ATH_MSG_DEBUG("energy after crack calibration es2011c = "
984  << std::format("{:.2f}", energy));
985  }
986 
987  /*
988  * Here we check for each event the kind of data DATA vs FullSim
989  * The m_simulation flavour has already been configured
990  */
993  ? m_simulation
995 
996  unsigned int runNumber_for_tool = 0;
997 
998  // apply uniformity corrections to data
1000  // Get run number
1001  runNumber_for_tool = event_info.runNumber();
1002  // Get etaCalo, phiCalo
1003  const auto cl_eta = input.caloCluster()->eta();
1004  double etaCalo = 0, phiCalo = 0;
1006  etaCalo = xAOD::get_eta_calo(*input.caloCluster(), input.author(), false);
1008  phiCalo =
1009  xAOD::get_phi_calo(*input.caloCluster(), input.author(), false);
1010  }
1011  }
1012 
1013  // Intermodule
1015  energy =
1016  intermodule_correction(energy, input.caloCluster()->phi(), cl_eta);
1017  ATH_MSG_DEBUG("energy after intermodule correction = "
1018  << std::format("{:.2f}", energy));
1019  }
1020 
1021  // Calo distortion
1024  double etaC = input.caloCluster()->eta();
1025  double phiC = input.caloCluster()->phi();
1026  int ieta = m_caloDistPhiUnifCorr->GetXaxis()->FindBin(etaC);
1027  ieta = ieta == 0 ? 1
1028  : (ieta > m_caloDistPhiUnifCorr->GetNbinsX()
1029  ? m_caloDistPhiUnifCorr->GetNbinsX()
1030  : ieta);
1031  int iphi = m_caloDistPhiUnifCorr->GetYaxis()->FindBin(phiC);
1032  iphi = iphi == 0 ? 1
1033  : (iphi > m_caloDistPhiUnifCorr->GetNbinsY()
1034  ? m_caloDistPhiUnifCorr->GetNbinsY()
1035  : iphi);
1036  energy *= m_caloDistPhiUnifCorr->GetBinContent(ieta, iphi);
1037  ATH_MSG_DEBUG(
1038  "energy after phi uniformity correction (for calo distortion) = "
1039  << std::format("{:.2f}", energy));
1040  }
1041 
1042  // Phi
1044  energy *= correction_phi_unif(etaCalo, phiCalo);
1045  ATH_MSG_DEBUG("energy after uniformity correction = "
1046  << std::format("{:.2f}", energy));
1047  }
1048 
1049  // ADC
1050  if (m_ADCLinearity_tool) {
1051  double et = energy / std::cosh(cl_eta);
1052  double corr =
1053  m_ADCLinearity_tool->getCorr(etaCalo, et, xAOD2ptype(input));
1054  energy *= corr;
1055  ATH_MSG_DEBUG("energy after ADC linearity correction = "
1056  << std::format("{:.2f}", energy));
1057  }
1058 
1059  // Gain
1060  if (m_gain_tool) {
1061  const auto es2 = Es2Acc.isAvailable(*input.caloCluster())
1062  ? Es2Acc(*input.caloCluster())
1063  : input.caloCluster()->energyBE(2);
1064  if (!(std::abs(cl_eta) < 1.52 and std::abs(cl_eta) > 1.37) and
1065  std::abs(cl_eta) < 2.4)
1067  cl_eta, energy / GeV, es2 / GeV,
1068  xAOD2ptype(input)); // cl_eta ok, TODO: check corrected E2
1069  } else if (m_gain_tool_run2) {
1070  double et = energy / std::cosh(cl_eta);
1071  double corr = m_gain_tool_run2->getUncertainty(etaCalo, et,
1072  xAOD2ptype(input), true);
1073  energy /= (1 + corr);
1074  }
1075  ATH_MSG_DEBUG("energy after gain correction = " << std::format("{:.2f}", energy));
1076  } else {
1077  if (m_user_random_run_number == 0) {
1079  randomrunnumber_getter("RandomRunNumber");
1080  if (randomrunnumber_getter.isAvailable(event_info)) {
1081  runNumber_for_tool = randomrunnumber_getter(event_info);
1082  } else {
1083  ATH_MSG_ERROR(
1084  "Pileup tool not run before using "
1085  "ElectronPhotonFourMomentumCorrection! Assuming it is 2016. If you "
1086  "want to force a specific period set the property randomRunNumber "
1087  "of the tool, e.g. in the job option: "
1088  "tool.randomRunNumber = 123456 or "
1089  "tool.randomRunNumber = "
1090  "EgammaCalibrationAndSmearingToolRunNumbersExample.run_2016");
1091  runNumber_for_tool = EgammaCalibPeriodRunNumbersExample::run_2016;
1092  }
1093  } else {
1094  runNumber_for_tool = m_user_random_run_number;
1095  }
1096  }
1097 
1098  const double eraw = ((Es0Acc.isAvailable(*input.caloCluster())
1099  ? Es0Acc(*input.caloCluster())
1100  : input.caloCluster()->energyBE(0)) +
1101  (Es1Acc.isAvailable(*input.caloCluster())
1102  ? Es1Acc(*input.caloCluster())
1103  : input.caloCluster()->energyBE(1)) +
1104  (Es2Acc.isAvailable(*input.caloCluster())
1105  ? Es2Acc(*input.caloCluster())
1106  : input.caloCluster()->energyBE(2)) +
1107  (Es3Acc.isAvailable(*input.caloCluster())
1108  ? Es3Acc(*input.caloCluster())
1109  : input.caloCluster()->energyBE(3)));
1110 
1111 
1113  ATH_MSG_DEBUG("is fast");
1115  ATH_MSG_DEBUG("is full");
1117  ATH_MSG_DEBUG("is data");
1118 
1119  // apply scale factors or systematics
1120  energy = m_rootTool->getCorrectedEnergy(
1121  runNumber_for_tool, dataType, xAOD2ptype(input),
1122  input.caloCluster()->eta(),
1123  input.caloCluster()->etaBE(2),
1124  xAOD::get_eta_calo(*input.caloCluster(), input.author(), false), energy,
1125  Es2Acc.isAvailable(*input.caloCluster())
1126  ? Es2Acc(*input.caloCluster())
1127  : input.caloCluster()->energyBE(2),
1128  eraw, seed, oldtool_scale_flag_this_event(input, event_info),
1130  m_varSF);
1131 
1132  ATH_MSG_DEBUG("energy after scale/systematic correction = " << std::format("{:.2f}", energy));
1133 
1134  // TODO: this check should be done before systematics variations
1135  const double new_energy2 = energy * energy;
1136  const double m2 = input.m() * input.m();
1137  const double p2 = new_energy2 > m2 ? new_energy2 - m2 : 0.;
1138  input.setPt(sqrt(p2) / cosh(input.eta()));
1139  ATH_MSG_DEBUG("after setting pt, energy = " << input.e());
1140  return CP::CorrectionCode::Ok;
1141 }

◆ applySystematicVariation()

StatusCode CP::EgammaCalibrationAndSmearingTool::applySystematicVariation ( const CP::SystematicSet systConfig)
overrideprivatevirtual

effects: configure this tool for the given list of systematic variations.

any requested systematics that are not affecting this tool will be silently ignored (unless they cause other errors). failures: systematic unknown failures: requesting multiple variations on the same systematic (e.g. up & down) failures: requesting an unsupported variation on an otherwise supported systematic (e.g. a 2 sigma variation and the tool only supports 1 sigma variations) failures: unsupported combination of supported systematic failures: other tool specific errors

Implements CP::ISystematicsTool.

Definition at line 1985 of file EgammaCalibrationAndSmearingTool.cxx.

1986  {
1987 
1988  // set the nominal one (no systematics)
1997  m_currentScalePredicate = [](const xAOD::Egamma&) { return true; };
1998 
1999  if (systConfig.empty())
2000  return StatusCode::SUCCESS;
2001 
2002  // the following code allows only ONE systematic variation at a time (1 for
2003  // scale, 1 for resolution)
2004 
2005  bool first_scale = true;
2006  bool first_resolution = true;
2007  for (const auto& it : systConfig) {
2008  const auto found_scale = m_syst_description.find(it);
2009  if (found_scale != m_syst_description.end()) {
2010  if (not first_scale) {
2011  ATH_MSG_ERROR("multiple scale variations not supported");
2012  throw std::runtime_error("multiple scale variations not supported");
2013  }
2014  first_scale = false;
2015  m_currentScaleVariation_MC = found_scale->second.effect;
2016  m_currentScalePredicate = found_scale->second.predicate;
2017  }
2018 
2019  const auto found_resolution = m_syst_description_resolution.find(it);
2020  if (found_resolution != m_syst_description_resolution.end()) {
2021  if (not first_resolution) {
2022  ATH_MSG_ERROR("multiple resolution variations not supported");
2023  throw std::runtime_error(
2024  "multiple resolution variations not supported");
2025  }
2026  first_resolution = false;
2027  m_currentResolutionVariation_MC = found_resolution->second;
2028  }
2029  }
2030 
2031  return StatusCode::SUCCESS;
2032 }

◆ beginEvent()

StatusCode asg::AsgMetadataTool::beginEvent ( )
protectedvirtualinherited

Function called when a new events is loaded.

Dummy implementation that can be overridden by the derived tool.

Reimplemented in AsgElectronEfficiencyCorrectionTool, TrigConf::xAODConfigTool, TauAnalysisTools::TauSelectionTool, TauAnalysisTools::DiTauSelectionTool, TauAnalysisTools::CommonSmearingTool, TauAnalysisTools::DiTauEfficiencyCorrectionsTool, Trig::TrigDecisionTool, TauAnalysisTools::TauEfficiencyCorrectionsTool, Trig::TrigConfBunchCrossingTool, xAODMaker::TriggerMenuMetaDataTool, and Trig::xAODBunchCrossingTool.

Definition at line 196 of file AsgMetadataTool.cxx.

196  {
197 
198  // Return gracefully:
199  return StatusCode::SUCCESS;
200  }

◆ beginInputFile()

StatusCode asg::AsgMetadataTool::beginInputFile ( )
protectedvirtualinherited

Function called when a new input file is opened.

Dummy implementation that can be overridden by the derived tool.

Reimplemented in AsgElectronEfficiencyCorrectionTool, TrigConf::xAODConfigTool, PMGTools::PMGTruthWeightTool, BookkeeperTool, xAODMaker::FileMetaDataTool, BookkeeperDumperTool, Trig::TrigDecisionTool, xAODMaker::TriggerMenuMetaDataTool, xAODMaker::TruthMetaDataTool, Trig::xAODBunchCrossingTool, TauAnalysisTools::TauEfficiencyCorrectionsTool, and TauAnalysisTools::TauSmearingTool.

Definition at line 180 of file AsgMetadataTool.cxx.

180  {
181 
182  // Return gracefully:
183  return StatusCode::SUCCESS;
184  }

◆ correctedCopy() [1/2]

CP::CorrectionCode CP::EgammaCalibrationAndSmearingTool::correctedCopy ( const xAOD::Electron input,
xAOD::Electron *&  output 
) const
overrideprivatevirtual

Implements CP::IEgammaCalibrationAndSmearingTool.

Definition at line 868 of file EgammaCalibrationAndSmearingTool.cxx.

869  {
870  // A sanity check:
871  if (output)
873  "Non-null pointer received. "
874  "There's a possible memory leak!");
875 
876  output = new xAOD::Electron();
877  output->makePrivateStore(input);
878  return applyCorrection(*output);
879 }

◆ correctedCopy() [2/2]

CP::CorrectionCode CP::EgammaCalibrationAndSmearingTool::correctedCopy ( const xAOD::Photon input,
xAOD::Photon *&  output 
) const
overrideprivatevirtual

Implements CP::IEgammaCalibrationAndSmearingTool.

Definition at line 881 of file EgammaCalibrationAndSmearingTool.cxx.

882  {
883  // A sanity check:
884  if (output)
886  "Non-null pointer received. "
887  "There's a possible memory leak!");
888 
889  output = new xAOD::Photon();
890  output->makePrivateStore(input);
891  return applyCorrection(*output);
892 }

◆ correction_phi_unif()

double CP::EgammaCalibrationAndSmearingTool::correction_phi_unif ( double  eta,
double  phi 
) const

Definition at line 2222 of file EgammaCalibrationAndSmearingTool.cxx.

2223  {
2224  constexpr double PI = M_PI;
2225  double Fcorr = 1.0;
2226 
2228  // wrong mapping HV -> sectors in run1
2229  if (eta < -0.4 && eta > -0.6) {
2230  if (phi < (14 * PI / 32.) && phi > (13 * PI / 32.)) {
2231  Fcorr += 0.035;
2232  } else if (phi < (13 * PI / 32.) && phi > (12 * PI / 32.)) {
2233  Fcorr -= 0.035;
2234  }
2235  }
2236  }
2237 
2249 
2250  if (eta < 0.2 && eta > 0.) {
2251  if (phi < (-7 * 2 * PI / 32.) && phi > (-8 * 2 * PI / 32.)) {
2252  Fcorr = 1.016314;
2253  }
2254  }
2255 
2256  else if (eta < 0.6 && eta > 0.4) {
2257  if (phi < 0 && phi > (-2 * PI / 32.)) {
2258  Fcorr = 1.041591;
2259  } else if (phi < (-4 * 2 * PI / 32.) && phi > (-5 * 2 * PI / 32.)) {
2260  Fcorr = 1.067346;
2261  }
2262  }
2263 
2264  else if (eta < 0.8 && eta > 0.6) {
2265  if (phi < (7 * 2 * PI / 32.) && phi > (6 * 2 * PI / 32.)) {
2266  Fcorr = 1.027980;
2267  }
2268  }
2269 
2270  else if (eta < 1.4 && eta > 1.2) {
2271  if (phi < (-9 * 2 * PI / 32.) && phi > (-10 * 2 * PI / 32.)) {
2272  Fcorr = 1.020299;
2273  } else if (phi < (-11 * 2 * PI / 32.) && phi > (-12 * 2 * PI / 32.)) {
2274  Fcorr = 1.051426;
2275  }
2276  }
2277 
2278  else if (eta < 2.3 && eta > 2.1) {
2279  if (phi < (-12 * 2 * PI / 32.) && phi > (-13 * 2 * PI / 32.)) {
2280  Fcorr = 1.071695;
2281  }
2282  }
2283 
2284  else if (eta < 0. && eta > -0.2) {
2285  if (phi < (-12 * 2 * PI / 32.) && phi > (-13 * 2 * PI / 32.)) {
2286  Fcorr = 1.008227;
2287  } else if (phi < (-8 * 2 * PI / 32.) && phi > (-9 * 2 * PI / 32.)) {
2288  Fcorr = 1.013929;
2289  }
2290  }
2291 
2292  else if (eta < -0.2 && eta > -0.4) {
2293  if (phi < (-9 * 2 * PI / 32.) && phi > (-10 * 2 * PI / 32.)) {
2294  Fcorr = 1.015749;
2295  }
2296  }
2297 
2298  else if (eta < -1.2 && eta > -1.4) {
2299  if (phi < (-6 * 2 * PI / 32.) && phi > (-7 * 2 * PI / 32.)) {
2300  Fcorr = 1.064954;
2301  }
2302  }
2303 
2304  else if (eta < -1.6 && eta > -1.8) {
2305  if (phi < (9 * 2 * PI / 32.) && phi > (8 * 2 * PI / 32.)) {
2306  Fcorr = 1.027448;
2307  }
2308  }
2309 
2310  else if (eta < -2.3 && eta > -2.5) {
2311  if (phi < (-8 * 2 * PI / 32.) && phi > (-9 * 2 * PI / 32.)) {
2312  Fcorr = 1.025882;
2313  } else if (phi < (5 * 2 * PI / 32.) && phi > (4 * 2 * PI / 32.)) {
2314  Fcorr = 1.036616;
2315  } else if (phi < (9 * 2 * PI / 32.) && phi > (8 * 2 * PI / 32.)) {
2316  Fcorr = 1.053838;
2317  } else if (phi < (10 * 2 * PI / 32.) && phi > (9 * 2 * PI / 32.)) {
2318  Fcorr = 1.026856;
2319  } else if (phi < (11 * 2 * PI / 32.) && phi > (10 * 2 * PI / 32.)) {
2320  Fcorr = 0.994382;
2321  }
2322  }
2323 
2324  } // es2017_summer_improved end
2325 
2326  else {
2327  if (eta < 0.6 && eta > 0.4) {
2328  if (phi < 0 && phi > (-2 * PI / 32.)) {
2329  Fcorr = 1.028;
2330  } else if (phi < (-4 * 2 * PI / 32.) && phi > (-5 * 2 * PI / 32.)) {
2331  Fcorr = 1.044;
2332  }
2333  }
2334 
2335  else if (eta < 0.8 && eta > 0.6) {
2336  if (phi < (7 * 2 * PI / 32.) && phi > (6 * 2 * PI / 32.)) {
2337  Fcorr = 1.022;
2338  }
2339  }
2340 
2341  else if (eta < 1.4 && eta > 1.2) {
2342  if (phi < (-11 * 2 * PI / 32.) && phi > (-12 * 2 * PI / 32.)) {
2343  Fcorr = 1.038;
2344  }
2345  }
2346 
2347  else if (eta < 2.0 && eta > 1.9) {
2348  if (phi < (10 * 2 * PI / 32.) && phi > (9 * 2 * PI / 32.)) {
2349  Fcorr = 1.029;
2350  }
2351  }
2352 
2353  else if (eta < -1.2 && eta > -1.4) {
2354  if (phi < (-4 * 2 * PI / 32.) && phi > (-5 * 2 * PI / 32.)) {
2355  Fcorr = 1.048;
2356  } else if (phi < (-6 * 2 * PI / 32.) && phi > (-7 * 2 * PI / 32.)) {
2357  Fcorr = 1.048;
2358  }
2359  }
2360 
2361  else if (eta < -1.6 && eta > -1.8) {
2362  if (phi < (9 * 2 * PI / 32.) && phi > (8 * 2 * PI / 32.)) {
2363  Fcorr = 1.024;
2364  }
2365  }
2366 
2367  else if (eta < -2.3 && eta > -2.5) {
2368  if (phi < (-8 * 2 * PI / 32.) && phi > (-9 * 2 * PI / 32.)) {
2369  Fcorr = 1.037;
2370  } else if (phi < (5 * 2 * PI / 32.) && phi > (4 * 2 * PI / 32.)) {
2371  Fcorr = 1.031;
2372  } else if (phi < (9 * 2 * PI / 32.) && phi > (8 * 2 * PI / 32.)) {
2373  Fcorr = 1.040;
2374  } else if (phi < (10 * 2 * PI / 32.) && phi > (9 * 2 * PI / 32.)) {
2375  Fcorr = 1.030;
2376  } else if (phi < (11 * 2 * PI / 32.) && phi > (10 * 2 * PI / 32.)) {
2377  Fcorr = 1.020;
2378  }
2379  }
2380  }
2381 
2382  return Fcorr;
2383 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ DoubleOrAbsEtaCaloPredicateFactory()

const EgammaPredicate CP::EgammaCalibrationAndSmearingTool::DoubleOrAbsEtaCaloPredicateFactory ( double  eta1_min,
double  eta1_max,
double  eta2_min,
double  eta2_max 
) const
inlineprivate

Definition at line 291 of file EgammaCalibrationAndSmearingTool.h.

293  {
294  return DoubleOrAbsEtaCaloPredicate(eta1_min, eta1_max, eta2_min, eta2_max);
295  }

◆ endInputFile()

StatusCode asg::AsgMetadataTool::endInputFile ( )
protectedvirtualinherited

Function called when the currently open input file got completely processed.

Dummy implementation that can be overridden by the derived tool.

Reimplemented in BookkeeperTool, xAODMaker::FileMetaDataTool, BookkeeperDumperTool, xAODMaker::TriggerMenuMetaDataTool, and xAODMaker::TruthMetaDataTool.

Definition at line 188 of file AsgMetadataTool.cxx.

188  {
189 
190  // Return gracefully:
191  return StatusCode::SUCCESS;
192  }

◆ EtaCaloPredicateFactory()

const EgammaPredicate CP::EgammaCalibrationAndSmearingTool::EtaCaloPredicateFactory ( double  eta_min,
double  eta_max 
) const
inlineprivate

Definition at line 217 of file EgammaCalibrationAndSmearingTool.h.

218  {
219  return EtaCaloPredicate(eta_min, eta_max);
220  }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ getElectronMomentum()

double CP::EgammaCalibrationAndSmearingTool::getElectronMomentum ( const xAOD::Electron el,
const xAOD::EventInfo event_info 
)
virtual

Definition at line 1169 of file EgammaCalibrationAndSmearingTool.cxx.

1170  {
1173  ? m_simulation
1175 
1176  const xAOD::TrackParticle* eTrack = el->trackParticle();
1177 
1178  // track momentum and eta
1179  const float el_tracketa = eTrack->eta();
1180  const float el_trackmomentum = eTrack->pt() * cosh(el->eta());
1181 
1182  return m_rootTool->getCorrectedMomentum(
1183  dataType, PATCore::ParticleType::Electron, el_trackmomentum, el_tracketa,
1184  oldtool_scale_flag_this_event(*el, *event_info), m_varSF);
1185 }

◆ getEnergy() [1/3]

double CP::EgammaCalibrationAndSmearingTool::getEnergy ( const xAOD::Electron input) const
private

Definition at line 903 of file EgammaCalibrationAndSmearingTool.cxx.

904  {
905  xAOD::Electron* new_particle = nullptr;
906  ANA_CHECK_THROW(correctedCopy(input, new_particle));
907  const double e = new_particle->e();
908  delete new_particle;
909  return e;
910 }

◆ getEnergy() [2/3]

double CP::EgammaCalibrationAndSmearingTool::getEnergy ( const xAOD::Photon input) const
private

Definition at line 894 of file EgammaCalibrationAndSmearingTool.cxx.

895  {
896  xAOD::Photon* new_particle = nullptr;
897  ANA_CHECK_THROW(correctedCopy(input, new_particle));
898  const double e = new_particle->e();
899  delete new_particle;
900  return e;
901 }

◆ getEnergy() [3/3]

double CP::EgammaCalibrationAndSmearingTool::getEnergy ( xAOD::Egamma p,
const xAOD::EventInfo event_info 
)
virtual

Definition at line 1143 of file EgammaCalibrationAndSmearingTool.cxx.

1144  {
1145  ANA_CHECK_THROW(applyCorrection(*p, *event_info));
1146  ATH_MSG_DEBUG("returning " << p->e());
1147  return p->e();
1148 }

◆ getKey()

SG::sgkey_t asg::AsgTool::getKey ( const void *  ptr) const
inherited

Get the (hashed) key of an object that is in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the SG::sgkey_t key for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getName
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The hashed key of the object in the store. If not found, an invalid (zero) key.

Definition at line 119 of file AsgTool.cxx.

119  {
120 
121 #ifdef XAOD_STANDALONE
122  // In case we use @c xAOD::TEvent, we have a direct function call
123  // for this.
124  return evtStore()->event()->getKey( ptr );
125 #else
126  const SG::DataProxy* proxy = evtStore()->proxy( ptr );
127  return ( proxy == nullptr ? 0 : proxy->sgkey() );
128 #endif // XAOD_STANDALONE
129  }

◆ getName()

const std::string & asg::AsgTool::getName ( const void *  ptr) const
inherited

Get the name of an object that is / should be in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the std::string name for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getKey
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The string name of the object in the store. If not found, an empty string.

Definition at line 106 of file AsgTool.cxx.

106  {
107 
108 #ifdef XAOD_STANDALONE
109  // In case we use @c xAOD::TEvent, we have a direct function call
110  // for this.
111  return evtStore()->event()->getName( ptr );
112 #else
113  const SG::DataProxy* proxy = evtStore()->proxy( ptr );
114  static const std::string dummy = "";
115  return ( proxy == nullptr ? dummy : proxy->name() );
116 #endif // XAOD_STANDALONE
117  }

◆ getProperty()

template<class T >
const T* asg::AsgTool::getProperty ( const std::string &  name) const
inherited

Get one of the tool's properties.

◆ getRandomSeedFunction()

const IdFunction CP::EgammaCalibrationAndSmearingTool::getRandomSeedFunction ( ) const
inlineprivate

Definition at line 147 of file EgammaCalibrationAndSmearingTool.h.

147 { return m_set_seed_function; }

◆ getResolution()

double CP::EgammaCalibrationAndSmearingTool::getResolution ( const xAOD::Egamma particle,
bool  withCT = true 
) const
overridevirtual

Implements CP::IEgammaCalibrationAndSmearingTool.

Definition at line 839 of file EgammaCalibrationAndSmearingTool.cxx.

840  {
841  const auto ptype = xAOD2ptype(particle);
842  const auto cl_etaCalo =
843  xAOD::get_eta_calo(*particle.caloCluster(), particle.author());
844 
845  return m_rootTool->resolution(particle.e(), particle.caloCluster()->eta(),
846  cl_etaCalo, ptype, withCT,
847  false); // TODO: always for full simulation
848 }

◆ handle()

void asg::AsgMetadataTool::handle ( const Incident &  inc)
protectedvirtualinherited

Function receiving incidents from IncidentSvc/TEvent.

Reimplemented in Trig::TrigDecisionTool.

Definition at line 130 of file AsgMetadataTool.cxx.

130  {
131 
132  // Tell the user what's happening:
133  ATH_MSG_VERBOSE( "Callback received with incident: " << inc.type() );
134 
135  // Call the appropriate member function:
136  if( inc.type() == IncidentType::BeginInputFile ) {
137  m_beginInputFileCalled = true;
138  if( beginInputFile().isFailure() ) {
139  ATH_MSG_FATAL( "Failed to call beginInputFile()" );
140  throw std::runtime_error( "Couldn't call beginInputFile()" );
141  }
142  } else if( inc.type() == IncidentType::EndInputFile ) {
143  if( endInputFile().isFailure() ) {
144  ATH_MSG_FATAL( "Failed to call endInputFile()" );
145  throw std::runtime_error( "Couldn't call endInputFile()" );
146  }
147  } else if( inc.type() == IncidentType::BeginEvent ) {
148  // If the tool didn't catch the begin input file incident for the
149  // first input file of the job, then call the appropriate function
150  // now.
151  if( ! m_beginInputFileCalled ) {
152  m_beginInputFileCalled = true;
153  if( beginInputFile().isFailure() ) {
154  ATH_MSG_FATAL( "Failed to call beginInputFile()" );
155  throw std::runtime_error( "Couldn't call beginInputFile()" );
156  }
157  }
158  if( beginEvent().isFailure() ) {
159  ATH_MSG_FATAL( "Failed to call beginEvent()" );
160  throw std::runtime_error( "Couldn't call beginEvent()" );
161  }
162 
163  #ifdef XAOD_STANDALONE
164  } else if( inc.type() == IncidentType::MetaDataStop ) {
165  if( metaDataStop().isFailure() ) {
166  ATH_MSG_FATAL( "Failed to call metaDataStop()" );
167  throw std::runtime_error( "Couldn't call metaDataStop()" );
168  }
169 
170  #endif // XAOD_STANDALONE
171  } else {
172  ATH_MSG_WARNING( "Unknown incident type received in AsgMetaDataTool: " << inc.type() );
173  }
174 
175  return;
176  }

◆ initialize()

StatusCode CP::EgammaCalibrationAndSmearingTool::initialize ( )
overrideprivatevirtual

Implements CP::IEgammaCalibrationAndSmearingTool.

Definition at line 351 of file EgammaCalibrationAndSmearingTool.cxx.

351  {
352  ATH_MSG_INFO("Initialization");
353 
354  if (m_ESModel == "es2015XX") {
355  ATH_MSG_ERROR("es2015XX is deprecated. Use es2015PRE");
356  }
357 
358  if (m_ESModel == "es2010") {
360  } // legacy
361  else if (m_ESModel == "es2011c") {
363  } // mc11c : faulty G4; old geometry
364  else if (m_ESModel == "es2011d") {
366  } // mc11d : corrected G4; new geometry == final Run1 scheme
367  else if (m_ESModel == "es2012a") {
369  } // mc12a : "crude" G4 fix; old geometry
370  else if (m_ESModel == "es2012c") {
372  } // mc12c : corrected G4; new geometry == final Run1 scheme
373  else if (m_ESModel == "es2012XX") {
375  } else if (m_ESModel == "es2015PRE") {
377  } else if (m_ESModel == "es2015PRE_res_improved") {
379  } else if (m_ESModel == "es2015cPRE") {
381  } else if (m_ESModel == "es2015cPRE_res_improved") {
383  } else if (m_ESModel == "es2015c_summer") {
385  } else if (m_ESModel == "es2016PRE") {
387  } else if (m_ESModel == "es2016data_mc15c") {
389  } else if (m_ESModel == "es2016data_mc15c_summer") {
391  } else if (m_ESModel == "es2016data_mc15c_summer_improved") {
393  } else if (m_ESModel == "es2016data_mc15c_final") {
395  } else if (m_ESModel == "es2015_5TeV") {
397  } else if (m_ESModel == "es2017_R21_PRE") {
399  } else if (m_ESModel == "es2017_R21_v0") {
401  } else if (m_ESModel == "es2017_R21_v1") {
403  } else if (m_ESModel == "es2017_R21_ofc0_v1") {
405  } else if (m_ESModel == "es2018_R21_v0") {
407  } else if (m_ESModel == "es2018_R21_v1") {
409  } else if (m_ESModel == "es2022_R22_PRE") {
411  } else if (m_ESModel == "es2023_R22_Run2_v0") {
413  } else if (m_ESModel == "es2023_R22_Run2_v1") {
415  } else if (m_ESModel == "es2024_Run3_ofc0_v0") {
417  } else if (m_ESModel.empty()) {
418  ATH_MSG_ERROR("you must set ESModel property");
419  return StatusCode::FAILURE;
420  } else {
421  ATH_MSG_ERROR("Cannot understand model " << m_ESModel);
422  return StatusCode::FAILURE;
423  }
424 
425  if (m_ResolutionType == "Gaussian") {
427  } else if (m_ResolutionType == "SigmaEff80") {
429  } else if (m_ResolutionType == "SigmaEff90") {
431  } else {
432  ATH_MSG_ERROR("Cannot understand resolution " << m_ResolutionType);
433  return StatusCode::FAILURE;
434  }
435 
436  if (m_use_AFII != -1) {
438  "Property useAFII is deprecated. It is now replaced with useFastSim, "
439  "which should be explicitly configured");
440  return StatusCode::FAILURE;
441  }
442 
443  if (m_useFastSim == 1) {
445  } else if (m_useFastSim == 0) {
447  } else {
448  ATH_MSG_ERROR("Property useFastSim should be explicitly configured");
449  return StatusCode::FAILURE;
450  }
451 
455  "Sample is FastSim but no AF3 calibration is available yet with "
456  "MC23 recommendations. Please get in touch with the EGamma "
457  "CP group in case you are using this");
458  return StatusCode::FAILURE;
459  }
460 
461  // configure decorrelation model, translate string property to internal class
462  // enum
463  /* S R SR
464  0. 0 0 0 WARNING Full, Full (this is the default without configuration)
465  1. 0 0 1 SR
466  2. 0 1 0 FATAL
467  3. 0 1 1 WARNING SR then R
468  4. 1 0 0 FATAL
469  5. 1 0 1 WARNING SR then S
470  6. 1 1 0 S, R
471  7. 1 1 1 FATAL
472  */
473  if (m_decorrelation_model_name.empty() and
476  // case 0
477  ATH_MSG_WARNING("no decorrelation model specified, assuming full model");
480  m_decorrelation_model_name = "FULL_v1";
481  } else if (not m_decorrelation_model_name.empty() and
482  not m_decorrelation_model_scale_name.empty() and
484  // case 7
485  ATH_MSG_FATAL("too many flags for the decorrelation model");
486  return StatusCode::FAILURE;
487  } else {
488  // set scale decorrelation model
489  if (not m_decorrelation_model_scale_name.empty()) { // case 4, 5, 6, (7)
490  if (not m_decorrelation_model_name.empty()) {
492  "flag decorrelation model ignored for scale decorrelation model");
493  } // case 5
494  if (m_decorrelation_model_scale_name == "1NP_v1")
495  m_decorrelation_model_scale = ScaleDecorrelation::ONENP;
496  else if (m_decorrelation_model_scale_name == "FULL_ETACORRELATED_v1")
497  m_decorrelation_model_scale = ScaleDecorrelation::FULL_ETA_CORRELATED;
498  else if (m_decorrelation_model_scale_name == "1NPCOR_PLUS_UNCOR")
499  m_decorrelation_model_scale = ScaleDecorrelation::ONENP_PLUS_UNCONR;
500  else if (m_decorrelation_model_scale_name == "FULL_v1")
502  else {
503  ATH_MSG_FATAL("cannot understand the scale decorrelation model '"
504  << m_decorrelation_model_scale_name << "'(typo?)");
505  return StatusCode::FAILURE;
506  }
507  } else if (not m_decorrelation_model_name.empty()) { // case 1, 3
508  if (m_decorrelation_model_name == "1NP_v1")
509  m_decorrelation_model_scale = ScaleDecorrelation::ONENP;
510  else if (m_decorrelation_model_name == "FULL_ETACORRELATED_v1")
511  m_decorrelation_model_scale = ScaleDecorrelation::FULL_ETA_CORRELATED;
512  else if (m_decorrelation_model_name == "1NPCOR_PLUS_UNCOR")
513  m_decorrelation_model_scale = ScaleDecorrelation::ONENP_PLUS_UNCONR;
514  else if (m_decorrelation_model_name == "FULL_v1")
516  else {
517  ATH_MSG_FATAL("cannot understand the decorrelation model '"
518  << m_decorrelation_model_name << "'(typo?)");
519  return StatusCode::FAILURE;
520  }
521  } else { // case 2, (7)
523  "not information how to initialize the scale decorrelation model");
524  return StatusCode::FAILURE;
525  }
526 
527  // set resolution decorralation model
529  .empty()) { // case 2, 3, 6, (7)
530  if (not m_decorrelation_model_name.empty()) {
532  "flag decorrelation model ignored for resolution decorrelation "
533  "model");
534  } // case 3
537  else if (m_decorrelation_model_resolution_name == "FULL_v1")
539  else {
540  ATH_MSG_FATAL("cannot understand the resolution decorrelation model '"
541  << m_decorrelation_model_resolution_name << "'(typo?)");
542  return StatusCode::FAILURE;
543  }
544  } else if (not m_decorrelation_model_name.empty()) { // case 1, 5
545  if (m_decorrelation_model_name == "1NP_v1")
547  else if (m_decorrelation_model_name == "FULL_ETACORRELATED_v1")
549  else if (m_decorrelation_model_name == "1NPCOR_PLUS_UNCOR")
551  else if (m_decorrelation_model_name == "FULL_v1")
553  else {
554  ATH_MSG_FATAL("cannot understand the decorrelation model '"
555  << m_decorrelation_model_name << "'(typo?)");
556  return StatusCode::FAILURE;
557  }
558  }
559  }
560 
561  // create correction tool
562  ATH_MSG_DEBUG("creating internal correction tool");
563  m_rootTool = std::make_unique<AtlasRoot::egammaEnergyCorrectionTool>();
564  if (!m_rootTool) {
565  ATH_MSG_ERROR("Cannot initialize underlying tool");
566  return StatusCode::FAILURE;
567  }
568  m_rootTool->setESModel(m_TESModel);
569 
573  "Using linear interpolation in the gain tool (uncertainties only)");
575  m_rootTool->setApplyL2GainInterpolation();
576  }
577  m_rootTool->msg().setLevel(this->msg().level());
578  m_rootTool->initialize();
579 
580  // configure MVA calibration
581  if (m_use_mva_calibration != 0) {
582  ATH_MSG_DEBUG("creating MVA calibration tool (if needed)");
583  if (m_MVAfolder.empty()) { // automatically configure MVA tool
585  }
586 
587  if (not m_MVAfolder.empty()) {
588 
589  // electron MVA tool
590  asg::AsgToolConfig config_mva_electron(
591  "egammaMVACalibTool/tool_mva_electron");
592  config_mva_electron.setPropertyFromString("folder", m_MVAfolder);
593  ATH_CHECK(config_mva_electron.setProperty("use_layer_corrected", true));
594  ;
595  ATH_CHECK(config_mva_electron.setProperty(
596  "ParticleType", xAOD::EgammaParameters::electron));
597 
598  // unconverted photon MVA tool
599  asg::AsgToolConfig config_mva_unconverted(
600  "egammaMVACalibTool/tool_mva_unconverted");
601  config_mva_unconverted.setPropertyFromString("folder", m_MVAfolder);
602  ATH_CHECK(
603  config_mva_unconverted.setProperty("use_layer_corrected", true));
604  ATH_CHECK(config_mva_unconverted.setProperty(
606 
607  // converted photon MVA tool
608  asg::AsgToolConfig config_mva_converted(
609  "egammaMVACalibTool/tool_mva_converted");
610  config_mva_converted.setPropertyFromString("folder", m_MVAfolder);
611  ATH_CHECK(config_mva_converted.setProperty("use_layer_corrected", true));
612  ATH_CHECK(config_mva_converted.setProperty(
613  "ParticleType", xAOD::EgammaParameters::convertedPhoton));
614 
615  // initialize the ServiceHandler egammaMVASvc
616  // make the name unique
617  std::ostringstream mva_service_name;
618  mva_service_name << "egammaMVASvc/service_mva_egamma_id"
619  << (void const*)this;
620  asg::AsgServiceConfig config_mva_service(mva_service_name.str());
621  ATH_CHECK(config_mva_service.addPrivateTool("ElectronTool",
622  config_mva_electron));
623  ATH_CHECK(config_mva_service.addPrivateTool("UnconvertedPhotonTool",
624  config_mva_unconverted));
625  ATH_CHECK(config_mva_service.addPrivateTool("ConvertedPhotonTool",
626  config_mva_converted));
627  config_mva_service.setPropertyFromString("folder", m_MVAfolder);
628  ATH_CHECK(
629  config_mva_service.setProperty("OutputLevel", this->msg().level()));
630  ATH_CHECK(config_mva_service.makeService(m_MVACalibSvc));
631  } else {
632  m_use_mva_calibration = false;
633  }
634  }
635 
636  // configure layer recalibration tool
637  // For now: layer recalibration not applied to PRE release 21 (using run 1
638  // based calibration applied at reco level)
639  // for following R21 recommendations, need to apply the run2/run1 layer
640  // calibration ratio
641  if (m_ESModel == "es2017_R21_PRE") {
642  ATH_MSG_INFO("Layer recalibration already applied at cell level");
643  m_useLayerCorrection = false;
644  } else if (!m_useLayerCorrection) {
645  ATH_MSG_INFO("Layer corrections disabled!");
646  } else {
647  ATH_MSG_DEBUG("initializing layer recalibration tool (if needed)");
649  .empty()) { // automatically configure layer recalibration tool
652  .release();
654  ATH_MSG_INFO("not using layer recalibration");
655  }
656  } else {
659  }
661  m_layer_recalibration_tool->msg().setLevel(this->msg().level());
663  if (!m_usePSCorrection) {
664  ATH_MSG_INFO("PS corrections disabled!");
666  }
667  if (!m_useS12Correction) {
668  ATH_MSG_INFO("S12 corrections disabled!");
670  }
671  if (!m_useSaccCorrection) {
672  ATH_MSG_INFO("Sacc corrections disabled!");
674  }
675  }
676  }
677 
679  m_rootTool->use_temp_correction201215(m_use_temp_correction201215);
681  m_rootTool->use_uA2MeV_2015_first2weeks_correction(
683  if (not m_use_full_statistical_error and
685  m_rootTool->useStatErrorScaling(true);
686  }
687 
688  if (m_use_ep_combination) {
689  ATH_MSG_ERROR("ep combination not supported yet");
690  throw std::runtime_error("ep combination not supported yet");
691  }
692 
695  }
698  }
700 
701  if (m_useGainCorrection == AUTO) {
705  }
706  else {
707  ATH_MSG_DEBUG("initializing gain tool");
710  }
711  }
712  else if (m_useGainCorrection == 1) {
717  "cannot instantiate gain tool for this model (you can only disable "
718  "the gain tool, but not enable it)");
719  } else {
720  ATH_MSG_INFO(
721  "initializing gain tool for run2 final precision recommendations");
723  "Gain corrections required but Zee scales are derived without Gain, "
724  "will cause inconsistency!");
725  std::string gain_tool_run_2_filename = PathResolverFindCalibFile(
726  "ElectronPhotonFourMomentumCorrection/v29/"
727  "gain_uncertainty_specialRun.root");
729  gain_tool_run_2_filename, false, "GainCorrection",
731  m_gain_tool_run2->msg().setLevel(this->msg().level());
732  }
733  }
734 
737  // ADC non linearity correction
740  std::string adcLinearityCorr_filename = PathResolverFindCalibFile(
741  "ElectronPhotonFourMomentumCorrection/v25/linearity_ADC.root");
742  m_ADCLinearity_tool.reset(new LinearityADC(adcLinearityCorr_filename));
743  m_ADCLinearity_tool->msg().setLevel(this->msg().level());
744  m_rootTool->setADCTool(m_ADCLinearity_tool);
745  } else {
747  m_ESModel + " recommendations use ADC corrections for scale "
748  "derivation. Disabling the ADCLinearity flag will create "
749  "inconsistency!");
750  }
751 
754  m_rootTool->setApplyLeakageCorrection(true);
755  }
756 
757  // Calo distortion phi unif correction
761  std::string phiUnifCorrfileName = PathResolverFindCalibFile(
762  "ElectronPhotonFourMomentumCorrection/v33/"
763  "egammaEnergyCorrectionData.root");
764  std::unique_ptr<TFile> fCorr(
765  TFile::Open(phiUnifCorrfileName.c_str(), "READ"));
766  m_caloDistPhiUnifCorr.reset(
767  dynamic_cast<TH2*>(fCorr->Get("CaloDistortionPhiUniformityCorrection/"
768  "es2023_R22_Run2_v0/h2DcorrPhiUnif")));
769  m_caloDistPhiUnifCorr->SetDirectory(nullptr);
770  } else {
772  m_ESModel + " recommendations use CaloDistPhiUnif for scale "
773  "derivation. Disabling the CaloDistPhiUnif flag will create "
774  "inconsistency!");
775  }
776  }
777 
778  // No scale correction for release 21 ==> obsolete
779  /*if (m_ESModel == "es2017_R21_PRE"){
780  m_doScaleCorrection = 0;
781  }
782  */
783 
784  ATH_MSG_INFO("ESModel: " << m_ESModel);
785  ATH_MSG_INFO("ResolutionType: " << m_ResolutionType);
786  ATH_MSG_INFO("decorrelation Model: " << m_decorrelation_model_name);
787  ATH_MSG_DEBUG("layer correction = " << m_useLayerCorrection);
788  ATH_MSG_DEBUG("PS correction = " << m_usePSCorrection);
789  ATH_MSG_DEBUG("S12 correction = " << m_useS12Correction);
790  ATH_MSG_DEBUG("Sacc correction = " << m_useSaccCorrection);
791  ATH_MSG_DEBUG("intermodule correction = " << m_useIntermoduleCorrection);
792  ATH_MSG_DEBUG("phi uniformity correction = " << m_usePhiUniformCorrection);
793  ATH_MSG_DEBUG("distorted calo phi uniformity correction = "
795  ATH_MSG_DEBUG("gain correction = " << m_useGainCorrection);
796  ATH_MSG_DEBUG("ADC non-linearity correction = " << m_doADCLinearityCorrection);
797  ATH_MSG_DEBUG("leakage correction for photons = " << m_doLeakageCorrection);
798  ATH_MSG_DEBUG("smearing = " << m_doSmearing);
799  ATH_MSG_DEBUG("insitu scales = " << m_doScaleCorrection);
800  ATH_MSG_DEBUG("ep combination = " << m_use_ep_combination);
801  ATH_MSG_DEBUG("use MVA calibration = " << m_use_mva_calibration);
803  "use temperature correction 2015 = " << m_use_temp_correction201215);
804  ATH_MSG_DEBUG("use uA2MeV correction 2015 1/2 week = "
806 
808 
810  .ignore(); // this set the flags for the internal tool without
811  // systematics
813  if (registry.registerSystematics(*this) != StatusCode::SUCCESS)
814  return StatusCode::FAILURE;
815 
816  return StatusCode::SUCCESS;
817 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ inputMetaStore()

AsgMetadataTool::MetaStorePtr_t asg::AsgMetadataTool::inputMetaStore ( ) const
inherited

Accessor for the input metadata store.

Definition at line 88 of file AsgMetadataTool.cxx.

88  {
89 
90 #ifdef XAOD_STANDALONE
91  return &m_inputMetaStore;
92 #else // XAOD_STANDALONE
93  return m_inputMetaStore;
94 #endif // XAOD_STANDALONE
95  }

◆ intermodule_correction()

double CP::EgammaCalibrationAndSmearingTool::intermodule_correction ( double  Ecl,
double  phi,
double  eta 
) const

Definition at line 2034 of file EgammaCalibrationAndSmearingTool.cxx.

2035  {
2036 
2037  // Intermodule Widening Correction: E_corr = E / (a' - b' * ((1 / (1 +
2038  // exp((phi_mod - 2 * pi / 32) * c))) * (1 / (1 + exp((phi_mod - 2 * pi / 32)
2039  // * (d)))))) (phi_min, phi_max) : [a' = a / a, b' = b / a, c, d]
2040 
2041  double Ecl_corr = 0.;
2042  int DivInt = 0;
2043  double pi = M_PI;
2044 
2056 
2057  double phi_mod = 0;
2058  if (phi < 0)
2059  phi_mod = fmod(phi, 2 * pi / 16.) + pi / 8.;
2060  else
2061  phi_mod = fmod(phi, 2 * pi / 16.);
2062 
2063  // The correction concerns only the barrel
2064  if (std::abs(eta) <= 1.37) {
2065 
2066  if (phi < (-7 * pi / 8) && phi > (-1 * pi))
2067  Ecl_corr =
2068  Ecl /
2069  (1 - 0.1086 *
2070  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 175.2759))) *
2071  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-189.3612))))));
2072  if (phi < (-6 * pi / 8) && phi > (-7 * pi / 8))
2073  Ecl_corr =
2074  Ecl /
2075  (1 - 0.0596 *
2076  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 170.8305))) *
2077  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-233.3782))))));
2078  if (phi < (-5 * pi / 8) && phi > (-6 * pi / 8))
2079  Ecl_corr =
2080  Ecl /
2081  (1 - 0.0596 *
2082  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 147.1451))) *
2083  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-139.3386))))));
2084  if (phi < (-4 * pi / 8) && phi > (-5 * pi / 8))
2085  Ecl_corr =
2086  Ecl /
2087  (1 - 0.0583 *
2088  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 168.4644))) *
2089  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-246.2897))))));
2090  if (phi < (-3 * pi / 8) && phi > (-4 * pi / 8))
2091  Ecl_corr =
2092  Ecl /
2093  (1 - 0.0530 *
2094  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 177.6703))) *
2095  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-198.3227))))));
2096  if (phi < (-2 * pi / 8) && phi > (-3 * pi / 8))
2097  Ecl_corr =
2098  Ecl /
2099  (1 - 0.0672 *
2100  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 145.0693))) *
2101  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-242.1771))))));
2102  if (phi < (-1 * pi / 8) && phi > (-2 * pi / 8))
2103  Ecl_corr =
2104  Ecl /
2105  (1 - 0.0871 *
2106  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 132.3303))) *
2107  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-166.1833))))));
2108  if (phi < (0 * pi / 8) && phi > (-1 * pi / 8))
2109  Ecl_corr =
2110  Ecl /
2111  (1 - 0.0948 *
2112  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 127.6780))) *
2113  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-150.0700))))));
2114  if (phi < (1 * pi / 8) && phi > (0 * pi / 8))
2115  Ecl_corr =
2116  Ecl /
2117  (1 - 0.1166 *
2118  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 172.0679))) *
2119  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-235.3293))))));
2120  if (phi < (2 * pi / 8) && phi > (1 * pi / 8))
2121  Ecl_corr =
2122  Ecl /
2123  (1 - 0.1172 *
2124  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 190.3524))) *
2125  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-198.9400))))));
2126  if (phi < (3 * pi / 8) && phi > (2 * pi / 8))
2127  Ecl_corr =
2128  Ecl /
2129  (1 - 0.1292 *
2130  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 158.0540))) *
2131  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-165.3893))))));
2132  if (phi < (4 * pi / 8) && phi > (3 * pi / 8))
2133  Ecl_corr =
2134  Ecl /
2135  (1 - 0.1557 *
2136  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 162.2793))) *
2137  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-133.5131))))));
2138  if (phi < (5 * pi / 8) && phi > (4 * pi / 8))
2139  Ecl_corr =
2140  Ecl /
2141  (1 - 0.1659 *
2142  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 180.5270))) *
2143  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-168.5074))))));
2144  if (phi < (6 * pi / 8) && phi > (5 * pi / 8))
2145  Ecl_corr =
2146  Ecl /
2147  (1 - 0.1123 *
2148  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 128.2277))) *
2149  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-154.4455))))));
2150  if (phi < (7 * pi / 8) && phi > (6 * pi / 8))
2151  Ecl_corr =
2152  Ecl /
2153  (1 - 0.1394 *
2154  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 192.1216))) *
2155  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-198.0727))))));
2156  if (phi < (8 * pi / 8) && phi > (7 * pi / 8))
2157  Ecl_corr =
2158  Ecl /
2159  (1 - 0.1001 *
2160  ((1 / (1 + exp((phi_mod - 2 * pi / 32.) * 199.1735))) *
2161  (1 / (1 + exp((phi_mod - 2 * pi / 32.) * (-176.4056))))));
2162  }
2163 
2164  // No correction for the EC
2165  else {
2166  Ecl_corr = Ecl;
2167  }
2168 
2169  }
2170 
2171  else {
2172 
2173  // Definitions of module folding into four quarters (top, left, bottom and
2174  // right)
2175 
2176  DivInt = (int)(phi / ((2 * pi) / 16.));
2177  double phi_mod = phi - DivInt * (2 * pi / 16.);
2178 
2179  // Centring on the intermodule --> phi_mod will now be in [0,0.4]
2180  if (phi_mod < 0)
2181  phi_mod += pi / 8.;
2182 
2183  // The correction concerns only the barrel
2184  if (std::abs(eta) <= 1.4) {
2185 
2186  // Top quarter
2187  if (phi < (3 * pi) / 4. && phi >= pi / 4.) {
2188  Ecl_corr =
2189  Ecl / (1 - 0.131 * ((1 / (1 + exp((phi_mod - 0.2) * 199.08))) *
2190  (1 / (1 + exp((phi_mod - 0.2) * (-130.36))))));
2191  }
2192 
2193  // Right quarter
2194  if (phi < pi / 4. && phi >= -pi / 4.) {
2195  Ecl_corr =
2196  Ecl / (1 - 0.0879 * ((1 / (1 + exp((phi_mod - 0.2) * 221.01))) *
2197  (1 / (1 + exp((phi_mod - 0.2) * (-149.51))))));
2198  }
2199  // Bottom quarter
2200  if (phi < -pi / 4. && phi >= (-3 * pi) / 4.) {
2201  Ecl_corr =
2202  Ecl / (1 - 0.0605 * ((1 / (1 + exp((phi_mod - 0.2) * 281.37))) *
2203  (1 / (1 + exp((phi_mod - 0.2) * (-170.29))))));
2204  }
2205  // Left quarter
2206  if ((phi < (-3 * pi) / 4.) || (phi >= (3 * pi) / 4.)) {
2207  Ecl_corr =
2208  Ecl / (1 - 0.102 * ((1 / (1 + exp((phi_mod - 0.2) * 235.37))) *
2209  (1 / (1 + exp((phi_mod - 0.2) * (-219.04))))));
2210  }
2211  }
2212 
2213  // No correction for the EC
2214  else {
2215  Ecl_corr = Ecl;
2216  }
2217  }
2218 
2219  return Ecl_corr;
2220 }

◆ isAffectedBySystematic()

bool CP::EgammaCalibrationAndSmearingTool::isAffectedBySystematic ( const CP::SystematicVariation systematic) const
overrideprivatevirtual

Declare the interface that this class provides.

returns: whether this tool is affected by the given systematics

Implements CP::ISystematicsTool.

Definition at line 1187 of file EgammaCalibrationAndSmearingTool.cxx.

1188  {
1190  return sys.find(systematic) != sys.end();
1191 }

◆ metaDataStop()

StatusCode asg::AsgMetadataTool::metaDataStop ( )
protectedvirtualinherited

Function called when the tool should write out its metadata.

Dummy implementation that can be overridden by the derived tool.

Reimplemented in xAODMaker::FileMetaDataTool, BookkeeperTool, BookkeeperDumperTool, xAODMaker::TriggerMenuMetaDataTool, and xAODMaker::TruthMetaDataTool.

Definition at line 204 of file AsgMetadataTool.cxx.

204  {
205 
206  // Return gracefully:
207  return StatusCode::SUCCESS;
208  }

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msg_level_name()

const std::string & asg::AsgTool::msg_level_name ( ) const
inherited

A deprecated function for getting the message level's name.

Instead of using this, weirdly named function, user code should get the string name of the current minimum message level (in case they really need it...), with:

MSG::name( msg().level() )

This function's name doesn't follow the ATLAS coding rules, and as such will be removed in the not too distant future.

Returns
The string name of the current minimum message level that's printed

Definition at line 101 of file AsgTool.cxx.

101  {
102 
103  return MSG::name( msg().level() );
104  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ oldtool_resolution_flag_this_event()

egEnergyCorr::Resolution::Variation CP::EgammaCalibrationAndSmearingTool::oldtool_resolution_flag_this_event ( const xAOD::Egamma p,
const xAOD::EventInfo event_info 
) const
inlineprivate

Definition at line 1162 of file EgammaCalibrationAndSmearingTool.cxx.

◆ oldtool_scale_flag_this_event()

egEnergyCorr::Scale::Variation CP::EgammaCalibrationAndSmearingTool::oldtool_scale_flag_this_event ( const xAOD::Egamma p,
const xAOD::EventInfo event_info 
) const
inlineprivate

Definition at line 1151 of file EgammaCalibrationAndSmearingTool.cxx.

1152  {
1153  if (!event_info.eventType(xAOD::EventInfo::IS_SIMULATION))
1157  else
1159 }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ outputMetaStore()

AsgMetadataTool::MetaStorePtr_t asg::AsgMetadataTool::outputMetaStore ( ) const
inherited

Accessor for the output metadata store.

Definition at line 97 of file AsgMetadataTool.cxx.

97  {
98 
99 #ifdef XAOD_STANDALONE
100  return &m_outputMetaStore;
101 #else // XAOD_STANDALONE
102  return m_outputMetaStore;
103 #endif // XAOD_STANDALONE
104  }

◆ print() [1/2]

void asg::AsgTool::print ( ) const
virtualinherited

◆ print() [2/2]

virtual void asg::IAsgTool::print ( ) const
pure virtualinherited

◆ recommendedSystematics()

CP::SystematicSet CP::EgammaCalibrationAndSmearingTool::recommendedSystematics ( ) const
overrideprivatevirtual

the list of all systematics this tool recommends to use

Implements CP::IReentrantSystematicsTool.

Definition at line 1980 of file EgammaCalibrationAndSmearingTool.cxx.

1981  {
1982  return affectingSystematics();
1983 }

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ resolution()

double CP::EgammaCalibrationAndSmearingTool::resolution ( double  energy,
double  cl_eta,
double  cl_etaCalo,
PATCore::ParticleType::Type  ptype = PATCore::ParticleType::Electron,
bool  withCT = false 
) const
overrideprivatevirtual

Implements CP::IEgammaCalibrationAndSmearingTool.

Definition at line 850 of file EgammaCalibrationAndSmearingTool.cxx.

852  {
853  return m_rootTool->resolution(energy, cl_eta, cl_etaCalo, ptype, withCT,
854  false);
855 }

◆ setRandomSeedFunction()

virtual void CP::EgammaCalibrationAndSmearingTool::setRandomSeedFunction ( const IdFunction &&  function)
inlineprivatevirtual

Definition at line 144 of file EgammaCalibrationAndSmearingTool.h.

144  {
145  m_set_seed_function = function;
146  }

◆ setupSystematics()

void CP::EgammaCalibrationAndSmearingTool::setupSystematics ( )
private

Definition at line 1206 of file EgammaCalibrationAndSmearingTool.cxx.

1206  {
1207  const EgammaPredicate always = [](const xAOD::Egamma&) { return true; };
1208 
1209  // Try to simplify a bit for the ones that are fully correlate in eta,
1210  // whatever the model and that are not included in the macros including
1211  // - ADC non linearity
1212  // - L2Gain
1213  // - Leakage
1214  // - Conversion related
1215  // - TopoCluster threshold
1216  // - AF2
1217  // - PS_BARREL_B12
1218  // - S12EXTRALASTETABINRUN2
1219  // - ZEESTAT
1220  // - Run3 pre OFC + EXTRA
1221  if (m_decorrelation_model_scale == ScaleDecorrelation::FULL_ETA_CORRELATED ||
1223  // Electron leakage, ADCLin, convReco only in final run2 recommendations
1226  // systematic related to ADC non linearity correction. Before 2022, there
1227  // was not correction, nor related systematic
1229  m_syst_description[CP::SystematicVariation("EG_SCALE_ADCLIN", +1)] =
1230  SysInfo{always, egEnergyCorr::Scale::ADCLinUp};
1231  m_syst_description[CP::SystematicVariation("EG_SCALE_ADCLIN", -1)] =
1232  SysInfo{always, egEnergyCorr::Scale::ADCLinDown};
1233  }
1234  // Gain splitted uncertainty
1235  m_syst_description[CP::SystematicVariation("EG_SCALE_L2MEDIUMGAIN", +1)] =
1236  SysInfo{always, egEnergyCorr::Scale::L2MediumGainUp};
1237  m_syst_description[CP::SystematicVariation("EG_SCALE_L2MEDIUMGAIN", -1)] =
1238  SysInfo{always, egEnergyCorr::Scale::L2MediumGainDown};
1239  m_syst_description[CP::SystematicVariation("EG_SCALE_L2LOWGAIN", +1)] =
1240  SysInfo{always, egEnergyCorr::Scale::L2LowGainUp};
1241  m_syst_description[CP::SystematicVariation("EG_SCALE_L2LOWGAIN", -1)] =
1242  SysInfo{always, egEnergyCorr::Scale::L2LowGainDown};
1243 
1244  // Electron leakage
1245  m_syst_description[CP::SystematicVariation("EG_SCALE_LEAKAGEELEC", +1)] =
1246  SysInfo{always, egEnergyCorr::Scale::LeakageElecUp};
1247  m_syst_description[CP::SystematicVariation("EG_SCALE_LEAKAGEELEC", -1)] =
1248  SysInfo{always, egEnergyCorr::Scale::LeakageElecDown};
1249 
1250  // Conversion related
1251  m_syst_description[CP::SystematicVariation("PH_SCALE_CONVRECO", +1)] =
1252  SysInfo{always, egEnergyCorr::Scale::ConvRecoUp};
1253  m_syst_description[CP::SystematicVariation("PH_SCALE_CONVRECO", -1)] =
1254  SysInfo{always, egEnergyCorr::Scale::ConvRecoDown};
1255  }
1256  // The equivalent of convReco (convefficiency and convfakerate) for other
1257  // models
1258  else {
1259  m_syst_description[CP::SystematicVariation("PH_SCALE_CONVEFFICIENCY",
1260  +1)] =
1261  SysInfo{always, egEnergyCorr::Scale::ConvEfficiencyUp};
1262  m_syst_description[CP::SystematicVariation("PH_SCALE_CONVEFFICIENCY",
1263  -1)] =
1264  SysInfo{always, egEnergyCorr::Scale::ConvEfficiencyDown};
1265  m_syst_description[CP::SystematicVariation("PH_SCALE_CONVFAKERATE", +1)] =
1266  SysInfo{always, egEnergyCorr::Scale::ConvFakeRateUp};
1267  m_syst_description[CP::SystematicVariation("PH_SCALE_CONVFAKERATE", -1)] =
1268  SysInfo{always, egEnergyCorr::Scale::ConvFakeRateDown};
1269  }
1270 
1271  // additional systematics for R22 OFC and MC21 pre and bulk
1273  m_syst_description[CP::SystematicVariation("EG_SCALE_OFC", +1)] =
1274  SysInfo{always, egEnergyCorr::Scale::OFCUp};
1275  m_syst_description[CP::SystematicVariation("EG_SCALE_OFC", -1)] =
1276  SysInfo{always, egEnergyCorr::Scale::OFCDown};
1277 
1278  m_syst_description[CP::SystematicVariation("EG_SCALE_EXTRARUN3PRE", +1)] =
1279  SysInfo{always, egEnergyCorr::Scale::EXTRARUN3PREUp};
1280  m_syst_description[CP::SystematicVariation("EG_SCALE_EXTRARUN3PRE", -1)] =
1281  SysInfo{always, egEnergyCorr::Scale::EXTRARUN3PREDown};
1282  }
1283 
1293 
1294  // topo clustr threshold systematics aded to release 21 recommendations
1295  m_syst_description[CP::SystematicVariation("EG_SCALE_TOPOCLUSTER_THRES",
1296  +1)] =
1297  SysInfo{always, egEnergyCorr::Scale::topoClusterThresUp};
1298  m_syst_description[CP::SystematicVariation("EG_SCALE_TOPOCLUSTER_THRES",
1299  -1)] =
1301 
1302  // AF3 for run3 models: es2022_R22_PRE and esmodel >= es2023_R22_Run2_v1
1304  m_syst_description[CP::SystematicVariation("EG_SCALE_AF3", +1)] =
1305  SysInfo{always, egEnergyCorr::Scale::afUp};
1306  m_syst_description[CP::SystematicVariation("EG_SCALE_AF3", -1)] =
1307  SysInfo{always, egEnergyCorr::Scale::afDown};
1308  }
1309  else {
1310  // and extra AF2 systematics for release 21 recommendations - Moriond 2018
1311  // - pending proper AF2 to FullSim correction with release 21
1312  m_syst_description[CP::SystematicVariation("EG_SCALE_AF2", +1)] =
1313  SysInfo{always, egEnergyCorr::Scale::afUp};
1314  m_syst_description[CP::SystematicVariation("EG_SCALE_AF2", -1)] =
1315  SysInfo{always, egEnergyCorr::Scale::afDown};
1316  }
1317  }
1318 
1319  // PS correlated barrel uncertainty
1328  m_syst_description[CP::SystematicVariation("EG_SCALE_PS_BARREL_B12",
1329  +1)] =
1330  SysInfo{always, egEnergyCorr::Scale::PSb12Up};
1331  m_syst_description[CP::SystematicVariation("EG_SCALE_PS_BARREL_B12",
1332  -1)] =
1333  SysInfo{always, egEnergyCorr::Scale::PSb12Down};
1334  }
1335 
1336  // additional systematic for S12 last eta bin run2
1342  "EG_SCALE_S12EXTRALASTETABINRUN2", +1)] =
1345  "EG_SCALE_S12EXTRALASTETABINRUN2", -1)] =
1347  }
1348 
1349  // Zee stat, if for FULL we do not ask for m_use_full_statistical_error
1351  ScaleDecorrelation::FULL_ETA_CORRELATED or
1353  // return 1 variation only, fully correlated in eta, equal to the correct
1354  // value but scaled by sqrt(number of bins) the scaling is done by the old
1355  // tool
1356  m_syst_description[CP::SystematicVariation("EG_SCALE_ZEESTAT", +1)] =
1357  SysInfo{always, egEnergyCorr::Scale::ZeeStatUp};
1358  m_syst_description[CP::SystematicVariation("EG_SCALE_ZEESTAT", -1)] =
1359  SysInfo{always, egEnergyCorr::Scale::ZeeStatDown};
1360  }
1361  }
1362  if (m_decorrelation_model_scale == ScaleDecorrelation::ONENP) {
1363  // TODO: independet implementation of ALL UP looping on all the variations
1364  m_syst_description[CP::SystematicVariation("EG_SCALE_ALL", +1)] =
1365  SysInfo{always, egEnergyCorr::Scale::AllUp};
1366  m_syst_description[CP::SystematicVariation("EG_SCALE_ALL", -1)] =
1367  SysInfo{always, egEnergyCorr::Scale::AllDown};
1368 
1370  // extra AF2 systematics in addition to the 1NP
1377  m_syst_description[CP::SystematicVariation("EG_SCALE_AF2", +1)] =
1378  SysInfo{always, egEnergyCorr::Scale::afUp};
1379  m_syst_description[CP::SystematicVariation("EG_SCALE_AF2", -1)] =
1380  SysInfo{always, egEnergyCorr::Scale::afDown};
1381  }
1383  m_syst_description[CP::SystematicVariation("EG_SCALE_AF3", +1)] =
1384  SysInfo{always, egEnergyCorr::Scale::afUp};
1385  m_syst_description[CP::SystematicVariation("EG_SCALE_AF3", -1)] =
1386  SysInfo{always, egEnergyCorr::Scale::afDown};
1387  }
1388  }
1389  }
1390  else if (m_decorrelation_model_scale ==
1391  ScaleDecorrelation::FULL_ETA_CORRELATED) {
1392 // all the physical effects separately, considered as fully correlated in eta
1393 
1394 // common systematics for all the esmodels
1395 #define SYSMACRO(name, fullcorrelated, decorrelation, flagup, flagdown) \
1396  m_syst_description[CP::SystematicVariation(#name, +1)] = \
1397  SysInfo{always, flagup}; \
1398  m_syst_description[CP::SystematicVariation(#name, -1)] = \
1399  SysInfo{always, flagdown};
1400 #include "ElectronPhotonFourMomentumCorrection/systematics_S12_2022.def"
1401 #undef SYSMACRO
1402 
1405  m_syst_description[CP::SystematicVariation("EG_SCALE_LARCALIB", +1)] =
1406  SysInfo{always, egEnergyCorr::Scale::LArCalibUp};
1407  m_syst_description[CP::SystematicVariation("EG_SCALE_LARCALIB", -1)] =
1408  SysInfo{always, egEnergyCorr::Scale::LArCalibDown};
1409  m_syst_description[CP::SystematicVariation("EG_SCALE_L2GAIN", +1)] =
1410  SysInfo{always, egEnergyCorr::Scale::L2GainUp};
1411  m_syst_description[CP::SystematicVariation("EG_SCALE_L2GAIN", -1)] =
1412  SysInfo{always, egEnergyCorr::Scale::L2GainDown};
1413  }
1414 
1415  // additional systematics for S12 run2
1426  "EG_SCALE_LARCALIB_EXTRA2015PRE", +1)] =
1429  "EG_SCALE_LARCALIB_EXTRA2015PRE", -1)] =
1431  }
1432 
1433  // additional systematics for temperature run1->run2
1440  "EG_SCALE_LARTEMPERATURE_EXTRA2015PRE", +1)] =
1443  "EG_SCALE_LARTEMPERATURE_EXTRA2015PRE", -1)] =
1445  }
1446 
1447  // additional systematic for temperature 2015->2016
1450  "EG_SCALE_LARTEMPERATURE_EXTRA2016PRE", +1)] =
1453  "EG_SCALE_LARTEMPERATURE_EXTRA2016PRE", -1)] =
1455  }
1456 
1457  // additional systematic for PP0 region
1472  m_syst_description[CP::SystematicVariation("EG_SCALE_MATPP0", +1)] =
1473  SysInfo{always, egEnergyCorr::Scale::MatPP0Up};
1474  m_syst_description[CP::SystematicVariation("EG_SCALE_MATPP0", -1)] =
1475  SysInfo{always, egEnergyCorr::Scale::MatPP0Down};
1476  }
1477 
1478  // systematic related to wtots1
1493  m_syst_description[CP::SystematicVariation("EG_SCALE_WTOTS1", +1)] =
1494  SysInfo{always, egEnergyCorr::Scale::Wtots1Up};
1495  m_syst_description[CP::SystematicVariation("EG_SCALE_WTOTS1", -1)] =
1496  SysInfo{always, egEnergyCorr::Scale::Wtots1Down};
1497  }
1498 
1499  // systematic for the scintillators
1517  // scintillator systematics
1518  m_syst_description[CP::SystematicVariation("EG_SCALE_E4SCINTILLATOR",
1519  +1)] =
1520  SysInfo{always, egEnergyCorr::Scale::E4ScintillatorUp};
1521  m_syst_description[CP::SystematicVariation("EG_SCALE_E4SCINTILLATOR",
1522  -1)] =
1523  SysInfo{always, egEnergyCorr::Scale::E4ScintillatorDown};
1524  }
1525 
1526  } else if (m_decorrelation_model_scale ==
1527  ScaleDecorrelation::ONENP_PLUS_UNCONR) {
1528 // qsum of all variations correlated 8/13 TeV + uncorrelated (additional
1529 // systematics for 2015PRE or 2016) all the physical effects separately,
1530 // considered as fully correlated in eta
1531 // TODO: fix for es2017
1532 #define SYSMACRO(name, fullcorrelated, decorrelation, flagup, flagdown) \
1533  m_syst_description[CP::SystematicVariation(#name, +1)] = \
1534  SysInfo{always, flagup}; \
1535  m_syst_description[CP::SystematicVariation(#name, -1)] = \
1536  SysInfo{always, flagdown};
1537 #include "ElectronPhotonFourMomentumCorrection/systematics_1NPCOR_PLUS_UNCOR.def"
1538 #undef SYSMACRO
1539 
1540  // additional systematic for S12 last eta bin run2 - not needed anymore for
1541  // last 20.7 model since it is part of bin per bin E1/E2 uncertainty in root
1542  // file
1547  "EG_SCALE_S12EXTRALASTETABINRUN2", +1)] =
1550  "EG_SCALE_S12EXTRALASTETABINRUN2", -1)] =
1552  }
1553 
1555  using pairvector = std::vector<std::pair<double, double>>;
1556  const pairvector decorrelation_bins_BE = {{0., 1.45}, {1.52, 2.5}};
1557  const std::vector<double> decorrelation_edges_TWELVE = {
1558  0., 0.2, 0.4, 0.6, 0.8, 1.0, 1.2, 1.4, 1.6, 1.8, 2.0, 2.2, 2.4};
1559  std::vector<double> decorrelation_edges_MODULE = {
1560  0., 0.2, 0.4, 0.6, 0.8, 1.0, 1.2, 1.37, 1.52, 1.8};
1561  const std::vector<double> decorrelation_edges_MATERIAL = {0.0, 1.1, 1.5,
1562  2.1, 2.5};
1563 
1564  std::vector<double> decorrelation_edges_S12;
1565  // for es2018_R21_v1 : 4 eta bins for muon E1/E2 uncertainty correlation
1567  decorrelation_edges_S12.resize(5);
1568  decorrelation_edges_S12 = {0., 1.35, 1.5, 2.4, 2.5};
1571  decorrelation_edges_S12.resize(8);
1572  decorrelation_edges_S12 = {0., 0.6, 1.0, 1.35, 1.5, 1.8, 2.4, 2.5};
1573  //
1574  // PS scale from muons, so "crack" is a bit different
1575  decorrelation_edges_MODULE[7] = 1.4;
1576  decorrelation_edges_MODULE[8] = 1.5;
1577  }
1578  // for previous run 2 muon calibration with 20.7, 5 eta bins for E1/E2
1579  // uncertainty correlation
1580  else {
1581  decorrelation_edges_S12.resize(6);
1582  decorrelation_edges_S12 = {0., 0.6, 1.4, 1.5, 2.4, 2.5};
1583  }
1584 
1595 #define SYSMACRO(name, fullcorrelated, decorrelation, flagup, flagdown) \
1596  if (bool(fullcorrelated)) { \
1597  m_syst_description[CP::SystematicVariation(#name, +1)] = \
1598  SysInfo{always, flagup}; \
1599  m_syst_description[CP::SystematicVariation(#name, -1)] = \
1600  SysInfo{always, flagdown}; \
1601  } else { \
1602  int i = 0; \
1603  for (const auto& p : AbsEtaCaloPredicatesFactory(decorrelation)) { \
1604  m_syst_description[CP::SystematicVariation( \
1605  #name "__ETABIN" + std::to_string(i), +1)] = SysInfo{p, flagup}; \
1606  m_syst_description[CP::SystematicVariation( \
1607  #name "__ETABIN" + std::to_string(i), -1)] = SysInfo{p, flagdown}; \
1608  i += 1; \
1609  } \
1610  }
1611 #include "ElectronPhotonFourMomentumCorrection/systematics.def"
1612 #undef SYSMACRO
1615 #define SYSMACRO(name, fullcorrelated, decorrelation, flagup, flagdown) \
1616  if (bool(fullcorrelated)) { \
1617  m_syst_description[CP::SystematicVariation(#name, +1)] = \
1618  SysInfo{always, flagup}; \
1619  m_syst_description[CP::SystematicVariation(#name, -1)] = \
1620  SysInfo{always, flagdown}; \
1621  } else { \
1622  int i = 0; \
1623  for (const auto& p : AbsEtaCaloPredicatesFactory(decorrelation)) { \
1624  m_syst_description[CP::SystematicVariation( \
1625  #name "__ETABIN" + std::to_string(i), +1)] = SysInfo{p, flagup}; \
1626  m_syst_description[CP::SystematicVariation( \
1627  #name "__ETABIN" + std::to_string(i), -1)] = SysInfo{p, flagdown}; \
1628  i += 1; \
1629  } \
1630  }
1631 #include "ElectronPhotonFourMomentumCorrection/systematics_S12_2022.def"
1632 #undef SYSMACRO
1633  } else {
1634 #define SYSMACRO(name, fullcorrelated, decorrelation, flagup, flagdown) \
1635  if (bool(fullcorrelated)) { \
1636  m_syst_description[CP::SystematicVariation(#name, +1)] = \
1637  SysInfo{always, flagup}; \
1638  m_syst_description[CP::SystematicVariation(#name, -1)] = \
1639  SysInfo{always, flagdown}; \
1640  } else { \
1641  int i = 0; \
1642  for (const auto& p : AbsEtaCaloPredicatesFactory(decorrelation)) { \
1643  m_syst_description[CP::SystematicVariation( \
1644  #name "__ETABIN" + std::to_string(i), +1)] = SysInfo{p, flagup}; \
1645  m_syst_description[CP::SystematicVariation( \
1646  #name "__ETABIN" + std::to_string(i), -1)] = SysInfo{p, flagdown}; \
1647  i += 1; \
1648  } \
1649  }
1650 #include "ElectronPhotonFourMomentumCorrection/systematics_S12.def"
1651 #undef SYSMACRO
1652  } // else
1653 
1655  // statistical error, decorrelate in *all* the bins
1656  int i = 0;
1657  const TAxis& axis_statistical_error(m_rootTool->get_ZeeStat_eta_axis());
1658  for (int ibin = 1; ibin <= axis_statistical_error.GetNbins(); ++ibin) {
1659  auto p = EtaCaloPredicateFactory(
1660  axis_statistical_error.GetBinLowEdge(ibin),
1661  axis_statistical_error.GetBinLowEdge(ibin + 1));
1663  "EG_SCALE_ZEESTAT__ETABIN" + std::to_string(i), +1)] =
1666  "EG_SCALE_ZEESTAT__ETABIN" + std::to_string(i), -1)] =
1668  ++i;
1669  }
1670  }
1671 
1672  // additional systematics for S12 run2
1683  "EG_SCALE_LARCALIB_EXTRA2015PRE__ETABIN0", +1)] =
1684  SysInfo{AbsEtaCaloPredicateFactory({0, 1.45}),
1687  "EG_SCALE_LARCALIB_EXTRA2015PRE__ETABIN0", -1)] =
1688  SysInfo{AbsEtaCaloPredicateFactory({0, 1.45}),
1691  "EG_SCALE_LARCALIB_EXTRA2015PRE__ETABIN1", +1)] =
1692  SysInfo{AbsEtaCaloPredicateFactory({1.45, 2.47}),
1695  "EG_SCALE_LARCALIB_EXTRA2015PRE__ETABIN1", -1)] =
1696  SysInfo{AbsEtaCaloPredicateFactory({1.45, 2.47}),
1699  "EG_SCALE_LARCALIB_EXTRA2015PRE__ETABIN2", +1)] =
1700  SysInfo{AbsEtaCaloPredicateFactory({2.47, 3.2}),
1703  "EG_SCALE_LARCALIB_EXTRA2015PRE__ETABIN2", -1)] =
1704  SysInfo{AbsEtaCaloPredicateFactory({2.47, 3.2}),
1706  }
1707 
1708  // additional systematics for temperature run1->run2
1715  "EG_SCALE_LARTEMPERATURE_EXTRA2015PRE__ETABIN0", +1)] =
1716  SysInfo{AbsEtaCaloPredicateFactory(decorrelation_bins_BE[0]),
1719  "EG_SCALE_LARTEMPERATURE_EXTRA2015PRE__ETABIN0", -1)] =
1720  SysInfo{AbsEtaCaloPredicateFactory(decorrelation_bins_BE[0]),
1723  "EG_SCALE_LARTEMPERATURE_EXTRA2015PRE__ETABIN1", +1)] =
1724  SysInfo{AbsEtaCaloPredicateFactory(decorrelation_bins_BE[1]),
1727  "EG_SCALE_LARTEMPERATURE_EXTRA2015PRE__ETABIN1", -1)] =
1728  SysInfo{AbsEtaCaloPredicateFactory(decorrelation_bins_BE[1]),
1730  }
1731 
1732  // additional systematic for temperature 2015->2016
1735  "EG_SCALE_LARTEMPERATURE_EXTRA2016PRE__ETABIN0", +1)] =
1736  SysInfo{AbsEtaCaloPredicateFactory(decorrelation_bins_BE[0]),
1739  "EG_SCALE_LARTEMPERATURE_EXTRA2016PRE__ETABIN1", +1)] =
1740  SysInfo{AbsEtaCaloPredicateFactory(decorrelation_bins_BE[1]),
1743  "EG_SCALE_LARTEMPERATURE_EXTRA2016PRE__ETABIN0", -1)] =
1744  SysInfo{AbsEtaCaloPredicateFactory(decorrelation_bins_BE[0]),
1747  "EG_SCALE_LARTEMPERATURE_EXTRA2016PRE__ETABIN1", -1)] =
1748  SysInfo{AbsEtaCaloPredicateFactory(decorrelation_bins_BE[1]),
1750  }
1751 
1752  // additional systematic for PP0 region
1767  m_syst_description[CP::SystematicVariation("EG_SCALE_MATPP0__ETABIN0",
1768  +1)] = SysInfo{
1770  m_syst_description[CP::SystematicVariation("EG_SCALE_MATPP0__ETABIN1",
1771  +1)] = SysInfo{
1773  m_syst_description[CP::SystematicVariation("EG_SCALE_MATPP0__ETABIN0",
1774  -1)] = SysInfo{
1776  m_syst_description[CP::SystematicVariation("EG_SCALE_MATPP0__ETABIN1",
1777  -1)] =
1778  SysInfo{AbsEtaCaloPredicateFactory(1.5, 2.5),
1780  }
1781 
1782  // systematic related to wtots1
1795  m_syst_description[CP::SystematicVariation("EG_SCALE_WTOTS1", +1)] =
1796  SysInfo{always, egEnergyCorr::Scale::Wtots1Up};
1797  m_syst_description[CP::SystematicVariation("EG_SCALE_WTOTS1", -1)] =
1798  SysInfo{always, egEnergyCorr::Scale::Wtots1Down};
1799  }
1800 
1801  // systematic related to wtots1, decorrelate eta bin [1.52,1.82] from rest
1804  m_syst_description[CP::SystematicVariation("EG_SCALE_WTOTS1__ETABIN0",
1805  +1)] =
1806  SysInfo{DoubleOrAbsEtaCaloPredicate(0, 1.52, 1.82, 2.47),
1808  m_syst_description[CP::SystematicVariation("EG_SCALE_WTOTS1__ETABIN0",
1809  -1)] =
1810  SysInfo{DoubleOrAbsEtaCaloPredicate(0, 1.52, 1.82, 2.47),
1812  m_syst_description[CP::SystematicVariation("EG_SCALE_WTOTS1__ETABIN1",
1813  +1)] =
1814  SysInfo{AbsEtaCaloPredicateFactory({1.52, 1.82}),
1816  m_syst_description[CP::SystematicVariation("EG_SCALE_WTOTS1__ETABIN1",
1817  -1)] =
1818  SysInfo{AbsEtaCaloPredicateFactory({1.52, 1.82}),
1820  }
1821 
1822  // systematic for the scintillators
1841  "EG_SCALE_E4SCINTILLATOR__ETABIN0", +1)] =
1842  SysInfo{AbsEtaCaloPredicateFactory(1.4, 1.46),
1845  "EG_SCALE_E4SCINTILLATOR__ETABIN1", +1)] =
1846  SysInfo{AbsEtaCaloPredicateFactory(1.46, 1.52),
1849  "EG_SCALE_E4SCINTILLATOR__ETABIN2", +1)] =
1850  SysInfo{AbsEtaCaloPredicateFactory(1.52, 1.6),
1853  "EG_SCALE_E4SCINTILLATOR__ETABIN0", -1)] =
1854  SysInfo{AbsEtaCaloPredicateFactory(1.4, 1.46),
1857  "EG_SCALE_E4SCINTILLATOR__ETABIN1", -1)] =
1858  SysInfo{AbsEtaCaloPredicateFactory(1.46, 1.52),
1861  "EG_SCALE_E4SCINTILLATOR__ETABIN2", -1)] =
1862  SysInfo{AbsEtaCaloPredicateFactory(1.52, 1.6),
1864  }
1865  } else {
1866  ATH_MSG_FATAL("scale decorrelation model invalid");
1867  }
1868 
1869  // resolution systematics
1872  "EG_RESOLUTION_ALL", +1)] = egEnergyCorr::Resolution::AllUp;
1874  "EG_RESOLUTION_ALL", -1)] = egEnergyCorr::Resolution::AllDown;
1875  } else if (m_decorrelation_model_resolution ==
1878  "EG_RESOLUTION_ZSMEARING", +1)] = egEnergyCorr::Resolution::ZSmearingUp;
1880  "EG_RESOLUTION_ZSMEARING", -1)] =
1883  "EG_RESOLUTION_SAMPLINGTERM", +1)] =
1886  "EG_RESOLUTION_SAMPLINGTERM", -1)] =
1889  "EG_RESOLUTION_MATERIALID", +1)] =
1892  "EG_RESOLUTION_MATERIALID", -1)] =
1895  "EG_RESOLUTION_MATERIALCALO", +1)] =
1898  "EG_RESOLUTION_MATERIALCALO", -1)] =
1901  "EG_RESOLUTION_MATERIALGAP", +1)] =
1904  "EG_RESOLUTION_MATERIALGAP", -1)] =
1907  "EG_RESOLUTION_MATERIALCRYO", +1)] =
1910  "EG_RESOLUTION_MATERIALCRYO", -1)] =
1913  "EG_RESOLUTION_PILEUP", +1)] = egEnergyCorr::Resolution::PileUpUp;
1915  "EG_RESOLUTION_PILEUP", -1)] = egEnergyCorr::Resolution::PileUpDown;
1931  "EG_RESOLUTION_MATERIALIBL", +1)] =
1934  "EG_RESOLUTION_MATERIALIBL", -1)] =
1937  "EG_RESOLUTION_MATERIALPP0", +1)] =
1940  "EG_RESOLUTION_MATERIALPP0", -1)] =
1942 
1948  "EG_RESOLUTION_AF2", +1)] = egEnergyCorr::Resolution::afUp;
1950  "EG_RESOLUTION_AF2", -1)] = egEnergyCorr::Resolution::afDown;
1951  }
1954  "EG_RESOLUTION_AF3", +1)] = egEnergyCorr::Resolution::afUp;
1956  "EG_RESOLUTION_AF3", -1)] = egEnergyCorr::Resolution::afDown;
1957  }
1958 
1959  if (m_TESModel == egEnergyCorr::es2022_R22_PRE) { // exta sys. for Run-3
1960  // pre-recommendations
1962  "EG_RESOLUTION_OFC", +1)] = egEnergyCorr::Resolution::OFCUp;
1964  "EG_RESOLUTION_OFC", -1)] = egEnergyCorr::Resolution::OFCDown;
1965  }
1966  }
1967  } else {
1968  ATH_MSG_FATAL("resolution decorrelation model invalid");
1969  }
1970 
1971  // ep combination systematics
1972  if (m_use_ep_combination) {
1973  m_syst_description[CP::SystematicVariation("EL_SCALE_MOMENTUM", +1)] =
1974  SysInfo{always, egEnergyCorr::Scale::MomentumUp};
1975  m_syst_description[CP::SystematicVariation("EL_SCALE_MOMENTUM", -1)] =
1976  SysInfo{always, egEnergyCorr::Scale::MomentumDown};
1977  }
1978 }

◆ setUseIncidents()

void asg::AsgMetadataTool::setUseIncidents ( const bool  flag)
inlineprotectedinherited

Definition at line 132 of file AsgMetadataTool.h.

133  {
135  }

◆ sysInitialize()

StatusCode asg::AsgMetadataTool::sysInitialize ( )
virtualinherited

Function initialising the tool in the correct way in Athena.

This function is used to set up the callbacks from IncidentSvc in Athena at the right time during initialisation, without the user having to do anything special in his/her code.

Reimplemented from AthCommonDataStore< AthCommonMsg< AlgTool > >.

Definition at line 110 of file AsgMetadataTool.cxx.

110  {
111 
112 #ifndef XAOD_STANDALONE
113  if (m_useIncidents) {
114  // Connect to the IncidentSvc:
115  ServiceHandle< IIncidentSvc > incSvc( "IncidentSvc", name() );
116  ATH_CHECK( incSvc.retrieve() );
117 
118  // Set up the right callbacks: don't rethrow exceptions, any failure and we should end
119  incSvc->addListener( this, IncidentType::BeginEvent, 0, false );
120  }
121  // Let the base class do its thing:
122  ATH_CHECK( AlgTool::sysInitialize() );
123 
124 #endif // not XAOD_STANDALONE
125 
126  // Return gracefully:
127  return StatusCode::SUCCESS;
128  }

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

◆ xAOD2ptype()

PATCore::ParticleType::Type CP::EgammaCalibrationAndSmearingTool::xAOD2ptype ( const xAOD::Egamma particle) const
private

Definition at line 819 of file EgammaCalibrationAndSmearingTool.cxx.

820  {
821  auto ptype = PATCore::ParticleType::Electron;
822  // no ForwardElectron ptype: consider them as Electron
823  if (xAOD::EgammaHelpers::isElectron(&particle) ||
826  } else if (xAOD::EgammaHelpers::isPhoton(&particle)) {
829  } else {
831  }
832  } else {
833  ATH_MSG_ERROR("particle is not electron of photon");
834  throw std::runtime_error("particle is not electron or photon");
835  }
836  return ptype;
837 }

Member Data Documentation

◆ AUTO

const int CP::EgammaCalibrationAndSmearingTool::AUTO = 2
staticprivate

Definition at line 105 of file EgammaCalibrationAndSmearingTool.h.

◆ m_ADCLinearity_tool

std::shared_ptr<LinearityADC> CP::EgammaCalibrationAndSmearingTool::m_ADCLinearity_tool
private

Definition at line 312 of file EgammaCalibrationAndSmearingTool.h.

◆ m_beginInputFileCalled

bool asg::AsgMetadataTool::m_beginInputFileCalled
privateinherited

Flag helping to discover when the tool misses the opening of the first input file.

Definition at line 126 of file AsgMetadataTool.h.

◆ m_caloDistPhiUnifCorr

std::unique_ptr<TH2> CP::EgammaCalibrationAndSmearingTool::m_caloDistPhiUnifCorr
private

Definition at line 197 of file EgammaCalibrationAndSmearingTool.h.

◆ m_currentResolutionVariation_data

egEnergyCorr::Resolution::Variation CP::EgammaCalibrationAndSmearingTool::m_currentResolutionVariation_data
private

Definition at line 334 of file EgammaCalibrationAndSmearingTool.h.

◆ m_currentResolutionVariation_MC

egEnergyCorr::Resolution::Variation CP::EgammaCalibrationAndSmearingTool::m_currentResolutionVariation_MC
private

Definition at line 333 of file EgammaCalibrationAndSmearingTool.h.

◆ m_currentScalePredicate

EgammaPredicate CP::EgammaCalibrationAndSmearingTool::m_currentScalePredicate
private

Definition at line 336 of file EgammaCalibrationAndSmearingTool.h.

◆ m_currentScaleVariation_data

egEnergyCorr::Scale::Variation CP::EgammaCalibrationAndSmearingTool::m_currentScaleVariation_data
private

Definition at line 332 of file EgammaCalibrationAndSmearingTool.h.

◆ m_currentScaleVariation_MC

egEnergyCorr::Scale::Variation CP::EgammaCalibrationAndSmearingTool::m_currentScaleVariation_MC
private

Definition at line 331 of file EgammaCalibrationAndSmearingTool.h.

◆ m_decorateEmva

bool CP::EgammaCalibrationAndSmearingTool::m_decorateEmva
private

Definition at line 193 of file EgammaCalibrationAndSmearingTool.h.

◆ m_decorrelation_model_name

std::string CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_name
private

Definition at line 158 of file EgammaCalibrationAndSmearingTool.h.

◆ m_decorrelation_model_resolution

ResolutionDecorrelation CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_resolution
private
Initial value:

Definition at line 162 of file EgammaCalibrationAndSmearingTool.h.

◆ m_decorrelation_model_resolution_name

std::string CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_resolution_name
private

Definition at line 160 of file EgammaCalibrationAndSmearingTool.h.

◆ m_decorrelation_model_scale

ScaleDecorrelation CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_scale = ScaleDecorrelation::FULL
private

Definition at line 161 of file EgammaCalibrationAndSmearingTool.h.

◆ m_decorrelation_model_scale_name

std::string CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_scale_name
private

Definition at line 159 of file EgammaCalibrationAndSmearingTool.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doADCLinearityCorrection

int CP::EgammaCalibrationAndSmearingTool::m_doADCLinearityCorrection
private

Definition at line 179 of file EgammaCalibrationAndSmearingTool.h.

◆ m_doLeakageCorrection

int CP::EgammaCalibrationAndSmearingTool::m_doLeakageCorrection
private

Definition at line 180 of file EgammaCalibrationAndSmearingTool.h.

◆ m_doScaleCorrection

int CP::EgammaCalibrationAndSmearingTool::m_doScaleCorrection
private

Definition at line 165 of file EgammaCalibrationAndSmearingTool.h.

◆ m_doSmearing

int CP::EgammaCalibrationAndSmearingTool::m_doSmearing
private

Definition at line 166 of file EgammaCalibrationAndSmearingTool.h.

◆ m_ESModel

std::string CP::EgammaCalibrationAndSmearingTool::m_ESModel
private

Definition at line 157 of file EgammaCalibrationAndSmearingTool.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_fixForMissingCells

Gaudi::Property<bool> CP::EgammaCalibrationAndSmearingTool::m_fixForMissingCells
private
Initial value:
{
this, "FixForMissingCells", true,
"AOD fix for cell recovery in core egamma cluster"}

Definition at line 199 of file EgammaCalibrationAndSmearingTool.h.

◆ m_gain_tool

egGain::GainTool* CP::EgammaCalibrationAndSmearingTool::m_gain_tool = nullptr
private

Definition at line 313 of file EgammaCalibrationAndSmearingTool.h.

◆ m_gain_tool_run2

std::unique_ptr<egGain::GainUncertainty> CP::EgammaCalibrationAndSmearingTool::m_gain_tool_run2
private

Definition at line 311 of file EgammaCalibrationAndSmearingTool.h.

◆ m_inputMetaStore

MetaStore_t asg::AsgMetadataTool::m_inputMetaStore
privateinherited

Object accessing the input metadata store.

Definition at line 119 of file AsgMetadataTool.h.

◆ m_layer_recalibration_tool

egammaLayerRecalibTool* CP::EgammaCalibrationAndSmearingTool::m_layer_recalibration_tool = nullptr
private

Definition at line 314 of file EgammaCalibrationAndSmearingTool.h.

◆ m_layer_recalibration_tune

std::string CP::EgammaCalibrationAndSmearingTool::m_layer_recalibration_tune
private

Definition at line 315 of file EgammaCalibrationAndSmearingTool.h.

◆ m_MVACalibSvc

ServiceHandle<IegammaMVASvc> CP::EgammaCalibrationAndSmearingTool::m_MVACalibSvc
private
Initial value:
{this, "MVACalibSvc", "",
"calibration service"}

Definition at line 309 of file EgammaCalibrationAndSmearingTool.h.

◆ m_MVAfolder

std::string CP::EgammaCalibrationAndSmearingTool::m_MVAfolder
private

Definition at line 319 of file EgammaCalibrationAndSmearingTool.h.

◆ m_outputMetaStore

MetaStore_t asg::AsgMetadataTool::m_outputMetaStore
privateinherited

Object accessing the output metadata store.

Definition at line 121 of file AsgMetadataTool.h.

◆ m_ResolutionType

std::string CP::EgammaCalibrationAndSmearingTool::m_ResolutionType
private

Definition at line 168 of file EgammaCalibrationAndSmearingTool.h.

◆ m_rootTool

std::unique_ptr<AtlasRoot::egammaEnergyCorrectionTool> CP::EgammaCalibrationAndSmearingTool::m_rootTool
private

Definition at line 318 of file EgammaCalibrationAndSmearingTool.h.

◆ m_Run2Run3runNumberTransition

const unsigned int CP::EgammaCalibrationAndSmearingTool::m_Run2Run3runNumberTransition = 400000
staticprivate

Definition at line 155 of file EgammaCalibrationAndSmearingTool.h.

◆ m_set_seed_function

IdFunction CP::EgammaCalibrationAndSmearingTool::m_set_seed_function
private

Definition at line 338 of file EgammaCalibrationAndSmearingTool.h.

◆ m_simulation

PATCore::ParticleDataType::DataType CP::EgammaCalibrationAndSmearingTool::m_simulation
private
Initial value:

Definition at line 172 of file EgammaCalibrationAndSmearingTool.h.

◆ m_syst_description

std::map<CP::SystematicVariation, SysInfo> CP::EgammaCalibrationAndSmearingTool::m_syst_description
private

Definition at line 326 of file EgammaCalibrationAndSmearingTool.h.

◆ m_syst_description_resolution

std::map<CP::SystematicVariation, egEnergyCorr::Resolution::Variation> CP::EgammaCalibrationAndSmearingTool::m_syst_description_resolution
private

Definition at line 328 of file EgammaCalibrationAndSmearingTool.h.

◆ m_TESModel

egEnergyCorr::ESModel CP::EgammaCalibrationAndSmearingTool::m_TESModel
private

Definition at line 164 of file EgammaCalibrationAndSmearingTool.h.

◆ m_TResolutionType

egEnergyCorr::Resolution::resolutionType CP::EgammaCalibrationAndSmearingTool::m_TResolutionType
private

Definition at line 169 of file EgammaCalibrationAndSmearingTool.h.

◆ m_use_AFII

int CP::EgammaCalibrationAndSmearingTool::m_use_AFII
private

Definition at line 171 of file EgammaCalibrationAndSmearingTool.h.

◆ m_use_ep_combination

bool CP::EgammaCalibrationAndSmearingTool::m_use_ep_combination
private

Definition at line 181 of file EgammaCalibrationAndSmearingTool.h.

◆ m_use_full_statistical_error

bool CP::EgammaCalibrationAndSmearingTool::m_use_full_statistical_error
private

Definition at line 183 of file EgammaCalibrationAndSmearingTool.h.

◆ m_use_mapping_correction

bool CP::EgammaCalibrationAndSmearingTool::m_use_mapping_correction
private

Definition at line 186 of file EgammaCalibrationAndSmearingTool.h.

◆ m_use_mva_calibration

int CP::EgammaCalibrationAndSmearingTool::m_use_mva_calibration
private

Definition at line 182 of file EgammaCalibrationAndSmearingTool.h.

◆ m_use_temp_correction201215

int CP::EgammaCalibrationAndSmearingTool::m_use_temp_correction201215
private

Definition at line 184 of file EgammaCalibrationAndSmearingTool.h.

◆ m_use_uA2MeV_2015_first2weeks_correction

int CP::EgammaCalibrationAndSmearingTool::m_use_uA2MeV_2015_first2weeks_correction
private

Definition at line 185 of file EgammaCalibrationAndSmearingTool.h.

◆ m_useCaloDistPhiUnifCorrection

int CP::EgammaCalibrationAndSmearingTool::m_useCaloDistPhiUnifCorrection
private

Definition at line 177 of file EgammaCalibrationAndSmearingTool.h.

◆ m_useFastSim

int CP::EgammaCalibrationAndSmearingTool::m_useFastSim
private

Definition at line 170 of file EgammaCalibrationAndSmearingTool.h.

◆ m_useGainCorrection

int CP::EgammaCalibrationAndSmearingTool::m_useGainCorrection
private

Definition at line 178 of file EgammaCalibrationAndSmearingTool.h.

◆ m_useGainInterpolation

int CP::EgammaCalibrationAndSmearingTool::m_useGainInterpolation
private

Definition at line 188 of file EgammaCalibrationAndSmearingTool.h.

◆ m_useIncidents

bool asg::AsgMetadataTool::m_useIncidents
privateinherited

Definition at line 128 of file AsgMetadataTool.h.

◆ m_useIntermoduleCorrection

int CP::EgammaCalibrationAndSmearingTool::m_useIntermoduleCorrection
private

Definition at line 175 of file EgammaCalibrationAndSmearingTool.h.

◆ m_useLayerCorrection

int CP::EgammaCalibrationAndSmearingTool::m_useLayerCorrection
private

Definition at line 189 of file EgammaCalibrationAndSmearingTool.h.

◆ m_usePhiUniformCorrection

int CP::EgammaCalibrationAndSmearingTool::m_usePhiUniformCorrection
private

Definition at line 176 of file EgammaCalibrationAndSmearingTool.h.

◆ m_usePSCorrection

int CP::EgammaCalibrationAndSmearingTool::m_usePSCorrection
private

Definition at line 190 of file EgammaCalibrationAndSmearingTool.h.

◆ m_user_random_run_number

int CP::EgammaCalibrationAndSmearingTool::m_user_random_run_number
private

Definition at line 187 of file EgammaCalibrationAndSmearingTool.h.

◆ m_useS12Correction

int CP::EgammaCalibrationAndSmearingTool::m_useS12Correction
private

Definition at line 191 of file EgammaCalibrationAndSmearingTool.h.

◆ m_useSaccCorrection

int CP::EgammaCalibrationAndSmearingTool::m_useSaccCorrection
private

Definition at line 192 of file EgammaCalibrationAndSmearingTool.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_varSF

double CP::EgammaCalibrationAndSmearingTool::m_varSF
private

Definition at line 167 of file EgammaCalibrationAndSmearingTool.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files:
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
python.Dso.registry
registry
Definition: Control/AthenaServices/python/Dso.py:159
CP::EgammaCalibrationAndSmearingTool::m_useFastSim
int m_useFastSim
Definition: EgammaCalibrationAndSmearingTool.h:170
xAOD::TrackParticle_v1::pt
virtual double pt() const override final
The transverse momentum ( ) of the particle.
Definition: TrackParticle_v1.cxx:73
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
egEnergyCorr::Resolution::MaterialPP0Up
@ MaterialPP0Up
Definition: egammaEnergyCorrectionTool.h:93
egEnergyCorr::Scale::OFCDown
@ OFCDown
Definition: egammaEnergyCorrectionTool.h:266
CP::EgammaCalibrationAndSmearingTool::m_doADCLinearityCorrection
int m_doADCLinearityCorrection
Definition: EgammaCalibrationAndSmearingTool.h:179
PATCore::ParticleType::UnconvertedPhoton
@ UnconvertedPhoton
Definition: PATCoreEnums.h:38
et
Extra patterns decribing particle interation process.
egEnergyCorr::Resolution::SamplingTermUp
@ SamplingTermUp
Definition: egammaEnergyCorrectionTool.h:74
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
egEnergyCorr::es2011c
@ es2011c
Definition: egammaEnergyCorrectionTool.h:289
Trk::ParticleSwitcher::particle
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
Definition: ParticleHypothesis.h:76
egEnergyCorr::Scale::LArCalibExtra2015PreDown
@ LArCalibExtra2015PreDown
Definition: egammaEnergyCorrectionTool.h:166
xAOD::Electron
Electron_v1 Electron
Definition of the current "egamma version".
Definition: Event/xAOD/xAODEgamma/xAODEgamma/Electron.h:17
xAOD::EgammaParameters::convertedPhoton
@ convertedPhoton
Definition: EgammaEnums.h:20
asg::AsgMetadataTool::beginEvent
virtual StatusCode beginEvent()
Function called when a new events is loaded.
Definition: AsgMetadataTool.cxx:196
get_generator_info.result
result
Definition: get_generator_info.py:21
python.SystemOfUnits.m2
int m2
Definition: SystemOfUnits.py:92
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:392
egEnergyCorr::es2011d
@ es2011d
Definition: egammaEnergyCorrectionTool.h:291
CP::EgammaCalibrationAndSmearingTool::affectingSystematics
virtual CP::SystematicSet affectingSystematics() const override
the list of all systematics this tool can be affected by
Definition: EgammaCalibrationAndSmearingTool.cxx:1193
egEnergyCorr::Scale::OFCUp
@ OFCUp
Definition: egammaEnergyCorrectionTool.h:265
CP::EgammaCalibrationAndSmearingTool::m_ResolutionType
std::string m_ResolutionType
Definition: EgammaCalibrationAndSmearingTool.h:168
vtune_athena.format
format
Definition: vtune_athena.py:14
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
xAOD::EventInfo_v1::eventNumber
uint64_t eventNumber() const
The current event's event number.
CP::EgammaCalibrationAndSmearingTool::EgammaCalibrationAndSmearingTool
EgammaCalibrationAndSmearingTool(const std::string &name)
Definition: EgammaCalibrationAndSmearingTool.cxx:278
correlationModel::FULL
@ FULL
Definition: AsgElectronEfficiencyCorrectionTool.cxx:49
egEnergyCorr::Scale::afUp
@ afUp
Definition: egammaEnergyCorrectionTool.h:245
SG::Accessor
Helper class to provide type-safe access to aux data.
Definition: Control/AthContainers/AthContainers/Accessor.h:68
egEnergyCorr::Scale::LArTemperature2016PreUp
@ LArTemperature2016PreUp
Definition: egammaEnergyCorrectionTool.h:171
CP::EgammaCalibrationAndSmearingTool::m_use_ep_combination
bool m_use_ep_combination
Definition: EgammaCalibrationAndSmearingTool.h:181
CP::EgammaCalibrationAndSmearingTool::m_caloDistPhiUnifCorr
std::unique_ptr< TH2 > m_caloDistPhiUnifCorr
Definition: EgammaCalibrationAndSmearingTool.h:197
egEnergyCorr::Scale::ConvFakeRateDown
@ ConvFakeRateDown
Definition: egammaEnergyCorrectionTool.h:255
egEnergyCorr::Resolution::ZSmearingUp
@ ZSmearingUp
Definition: egammaEnergyCorrectionTool.h:70
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
egEnergyCorr::Scale::AllDown
@ AllDown
Definition: egammaEnergyCorrectionTool.h:273
xAOD::Egamma_v1::e
virtual double e() const override final
The total energy of the particle.
Definition: Egamma_v1.cxx:90
xAOD::TrackParticle_v1::eta
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
Definition: TrackParticle_v1.cxx:77
egEnergyCorr::Scale::L2GainDown
@ L2GainDown
Definition: egammaEnergyCorrectionTool.h:226
egEnergyCorr::Resolution::SigmaEff90
@ SigmaEff90
Definition: egammaEnergyCorrectionTool.h:116
CP::SystematicSet::empty
bool empty() const
returns: whether the set is empty
Definition: SystematicSet.h:67
egEnergyCorr::Scale::LArTemperature2015PreDown
@ LArTemperature2015PreDown
Definition: egammaEnergyCorrectionTool.h:168
PATCore::ParticleDataType::Fast
@ Fast
Definition: PATCoreEnums.h:22
CP::EgammaCalibrationAndSmearingTool::m_currentScaleVariation_data
egEnergyCorr::Scale::Variation m_currentScaleVariation_data
Definition: EgammaCalibrationAndSmearingTool.h:332
egEnergyCorr::es2017_R21_v1
@ es2017_R21_v1
Definition: egammaEnergyCorrectionTool.h:320
egEnergyCorr::Scale::LeakageElecUp
@ LeakageElecUp
Definition: egammaEnergyCorrectionTool.h:197
CP::EgammaCalibrationAndSmearingTool::m_useSaccCorrection
int m_useSaccCorrection
Definition: EgammaCalibrationAndSmearingTool.h:192
CP::EgammaCalibrationAndSmearingTool::ResolutionDecorrelation::ONENP
@ ONENP
CP::EgammaCalibrationAndSmearingTool::correctedCopy
virtual CP::CorrectionCode correctedCopy(const xAOD::Electron &, xAOD::Electron *&) const override
Definition: EgammaCalibrationAndSmearingTool.cxx:868
CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_name
std::string m_decorrelation_model_name
Definition: EgammaCalibrationAndSmearingTool.h:158
egEnergyCorr::Scale::MatPP0Down
@ MatPP0Down
Definition: egammaEnergyCorrectionTool.h:242
skel.it
it
Definition: skel.GENtoEVGEN.py:407
CP::use_intermodule_correction
bool use_intermodule_correction(egEnergyCorr::ESModel model)
Definition: EgammaCalibrationAndSmearingTool.cxx:188
egEnergyCorr::es2015PRE_res_improved
@ es2015PRE_res_improved
Definition: egammaEnergyCorrectionTool.h:304
CP::EgammaCalibrationAndSmearingTool::m_currentScalePredicate
EgammaPredicate m_currentScalePredicate
Definition: EgammaCalibrationAndSmearingTool.h:336
CP::SystematicSet
Class to wrap a set of SystematicVariations.
Definition: SystematicSet.h:31
M_PI
#define M_PI
Definition: ActiveFraction.h:11
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
egEnergyCorr::Scale::Nominal
@ Nominal
Definition: egammaEnergyCorrectionTool.h:132
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
downloadSingle.dataType
string dataType
Definition: downloadSingle.py:18
egEnergyCorr::Resolution::Gaussian
@ Gaussian
Definition: egammaEnergyCorrectionTool.h:112
CP::EgammaCalibrationAndSmearingTool::m_gain_tool
egGain::GainTool * m_gain_tool
Definition: EgammaCalibrationAndSmearingTool.h:313
CP::EgammaCalibrationAndSmearingTool::m_doScaleCorrection
int m_doScaleCorrection
Definition: EgammaCalibrationAndSmearingTool.h:165
egEnergyCorr::Scale::EXTRARUN3PREDown
@ EXTRARUN3PREDown
Definition: egammaEnergyCorrectionTool.h:270
egEnergyCorr::Scale::L2LowGainDown
@ L2LowGainDown
Definition: egammaEnergyCorrectionTool.h:229
CP::EgammaCalibrationAndSmearingTool::m_doLeakageCorrection
int m_doLeakageCorrection
Definition: EgammaCalibrationAndSmearingTool.h:180
egEnergyCorr::Scale::ZeeStatUp
@ ZeeStatUp
Definition: egammaEnergyCorrectionTool.h:144
PI
const float PI
Definition: test_isolaitonTool.cxx:61
CP::EgammaCalibrationAndSmearingTool::m_simulation
PATCore::ParticleDataType::DataType m_simulation
Definition: EgammaCalibrationAndSmearingTool.h:172
xAOD::Egamma_v1
Definition: Egamma_v1.h:56
CP::egammaMVAToolFolder
std::string egammaMVAToolFolder(egEnergyCorr::ESModel model)
Definition: EgammaCalibrationAndSmearingTool.cxx:84
egammaLayerRecalibTool::disable_S12Corrections
void disable_S12Corrections()
Definition: egammaLayerRecalibTool.h:359
asg::AsgMetadataTool::m_beginInputFileCalled
bool m_beginInputFileCalled
Flag helping to discover when the tool misses the opening of the first input file.
Definition: AsgMetadataTool.h:126
SG::ConstAccessor< double >
egammaLayerRecalibTool::applyCorrection
CP::CorrectionCode applyCorrection(xAOD::Egamma &, const xAOD::EventInfo &event_info) const
Definition: egammaLayerRecalibTool.cxx:979
asg::AsgMetadataTool::endInputFile
virtual StatusCode endInputFile()
Function called when the currently open input file got completely processed.
Definition: AsgMetadataTool.cxx:188
egEnergyCorr::Resolution::afDown
@ afDown
Definition: egammaEnergyCorrectionTool.h:98
CP::EgammaCalibrationAndSmearingTool::m_use_mva_calibration
int m_use_mva_calibration
Definition: EgammaCalibrationAndSmearingTool.h:182
egEnergyCorr::Scale::Wtots1Up
@ Wtots1Up
Definition: egammaEnergyCorrectionTool.h:237
CP::EgammaCalibrationAndSmearingTool::RandomNumber
unsigned int RandomNumber
Definition: EgammaCalibrationAndSmearingTool.h:107
asg::AsgMetadataTool::m_outputMetaStore
MetaStore_t m_outputMetaStore
Object accessing the output metadata store.
Definition: AsgMetadataTool.h:121
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
CP::EgammaCalibrationAndSmearingTool::m_use_temp_correction201215
int m_use_temp_correction201215
Definition: EgammaCalibrationAndSmearingTool.h:184
xAOD::EgammaParameters::AuthorFwdElectron
const uint16_t AuthorFwdElectron
Electron reconstructed by the Forward cluster-based algorithm.
Definition: EgammaDefs.h:30
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
dbg::ptr
void * ptr(T *p)
Definition: SGImplSvc.cxx:74
CP::SystematicVariation
Definition: SystematicVariation.h:47
CP::EgammaCalibrationAndSmearingTool::m_useGainCorrection
int m_useGainCorrection
Definition: EgammaCalibrationAndSmearingTool.h:178
egEnergyCorr::es2023_R22_Run2_v1
@ es2023_R22_Run2_v1
Definition: egammaEnergyCorrectionTool.h:330
egEnergyCorr::Scale::ConvRecoDown
@ ConvRecoDown
Definition: egammaEnergyCorrectionTool.h:262
drawFromPickle.exp
exp
Definition: drawFromPickle.py:36
CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_scale_name
std::string m_decorrelation_model_scale_name
Definition: EgammaCalibrationAndSmearingTool.h:159
xAOD::EventInfo_v1::IS_SIMULATION
@ IS_SIMULATION
true: simulation, false: data
Definition: EventInfo_v1.h:151
egEnergyCorr::Resolution::PileUpUp
@ PileUpUp
Definition: egammaEnergyCorrectionTool.h:88
PATCore::ParticleDataType::Data
@ Data
Definition: PATCoreEnums.h:22
mapkey::sys
@ sys
Definition: TElectronEfficiencyCorrectionTool.cxx:42
xAOD::EventInfo_v1::runNumber
uint32_t runNumber() const
The current event's run number.
pi
#define pi
Definition: TileMuonFitter.cxx:65
egEnergyCorr::Scale::L2GainUp
@ L2GainUp
Definition: egammaEnergyCorrectionTool.h:225
PATCore::ParticleDataType::DataType
DataType
Definition: PATCoreEnums.h:22
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
egEnergyCorr::Resolution::MaterialGapUp
@ MaterialGapUp
Definition: egammaEnergyCorrectionTool.h:82
egEnergyCorr::es2017_R21_v0
@ es2017_R21_v0
Definition: egammaEnergyCorrectionTool.h:318
egamma
Definition: egamma.h:58
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
egEnergyCorr::Scale::LeakageElecDown
@ LeakageElecDown
Definition: egammaEnergyCorrectionTool.h:198
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
xAOD::phi
setEt phi
Definition: TrigEMCluster_v1.cxx:29
egEnergyCorr::Scale::L2LowGainUp
@ L2LowGainUp
Definition: egammaEnergyCorrectionTool.h:230
ANA_CHECK_THROW
#define ANA_CHECK_THROW(EXP)
check whether the given expression was successful, throwing an exception on failure
Definition: Control/AthToolSupport/AsgMessaging/AsgMessaging/MessageCheck.h:339
CP::EgammaCalibrationAndSmearingTool::m_use_full_statistical_error
bool m_use_full_statistical_error
Definition: EgammaCalibrationAndSmearingTool.h:183
CP::EgammaCalibrationAndSmearingTool::oldtool_scale_flag_this_event
egEnergyCorr::Scale::Variation oldtool_scale_flag_this_event(const xAOD::Egamma &p, const xAOD::EventInfo &event_info) const
Definition: EgammaCalibrationAndSmearingTool.cxx:1151
egEnergyCorr::Scale::MomentumUp
@ MomentumUp
Definition: egammaEnergyCorrectionTool.h:137
PATCore::ParticleDataType::Full
@ Full
Definition: PATCoreEnums.h:22
PATCore::ParticleType::ConvertedPhoton
@ ConvertedPhoton
Definition: PATCoreEnums.h:39
egEnergyCorr::es2015cPRE
@ es2015cPRE
Definition: egammaEnergyCorrectionTool.h:305
CP::EgammaCalibrationAndSmearingTool::m_usePhiUniformCorrection
int m_usePhiUniformCorrection
Definition: EgammaCalibrationAndSmearingTool.h:176
AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
egEnergyCorr::Scale::LArTemperature2015PreUp
@ LArTemperature2015PreUp
Definition: egammaEnergyCorrectionTool.h:167
CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_resolution
ResolutionDecorrelation m_decorrelation_model_resolution
Definition: EgammaCalibrationAndSmearingTool.h:162
TRTCalib_cfilter.p2
p2
Definition: TRTCalib_cfilter.py:131
egGain::GainUncertainty
Definition: GainUncertainty.h:17
CP::EgammaCalibrationAndSmearingTool::m_user_random_run_number
int m_user_random_run_number
Definition: EgammaCalibrationAndSmearingTool.h:187
CP::EgammaCalibrationAndSmearingTool::m_useIntermoduleCorrection
int m_useIntermoduleCorrection
Definition: EgammaCalibrationAndSmearingTool.h:175
egEnergyCorr::Scale::AllUp
@ AllUp
Definition: egammaEnergyCorrectionTool.h:272
CP::EgammaCalibrationAndSmearingTool::m_currentResolutionVariation_MC
egEnergyCorr::Resolution::Variation m_currentResolutionVariation_MC
Definition: EgammaCalibrationAndSmearingTool.h:333
CP::CorrectionCode::Error
@ Error
Some error happened during the object correction.
Definition: CorrectionCode.h:36
egEnergyCorr::Resolution::ZSmearingDown
@ ZSmearingDown
Definition: egammaEnergyCorrectionTool.h:69
CP::EgammaCalibrationAndSmearingTool::EgammaPredicate
std::function< bool(const xAOD::Egamma &)> EgammaPredicate
Definition: EgammaCalibrationAndSmearingTool.h:111
CP::EgammaCalibrationAndSmearingTool::m_MVACalibSvc
ServiceHandle< IegammaMVASvc > m_MVACalibSvc
Definition: EgammaCalibrationAndSmearingTool.h:309
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
egEnergyCorr::Scale::LArCalibUp
@ LArCalibUp
Definition: egammaEnergyCorrectionTool.h:155
egEnergyCorr::Resolution::MaterialPP0Down
@ MaterialPP0Down
Definition: egammaEnergyCorrectionTool.h:94
egEnergyCorr::es2010
@ es2010
Definition: egammaEnergyCorrectionTool.h:287
CP::EgammaCalibrationAndSmearingTool::m_currentScaleVariation_MC
egEnergyCorr::Scale::Variation m_currentScaleVariation_MC
Definition: EgammaCalibrationAndSmearingTool.h:331
CP::EgammaCalibrationAndSmearingTool::m_ESModel
std::string m_ESModel
Definition: EgammaCalibrationAndSmearingTool.h:157
xAOD::EgammaHelpers::isConvertedPhoton
bool isConvertedPhoton(const xAOD::Egamma *eg, bool excludeTRT=false)
is the object a converted photon
Definition: EgammaxAODHelpers.cxx:25
AthCommonDataStore
Definition: AthCommonDataStore.h:52
Generate_dsid_ranseed.seed
seed
Definition: Generate_dsid_ranseed.py:10
CP::EgammaCalibrationAndSmearingTool::m_decorateEmva
bool m_decorateEmva
Definition: EgammaCalibrationAndSmearingTool.h:193
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
asg::AsgToolConfig
an object that can create a AsgTool
Definition: AsgToolConfig.h:22
ParticleGun_FastCalo_ChargeFlip_Config.energy
energy
Definition: ParticleGun_FastCalo_ChargeFlip_Config.py:78
egEnergyCorr::Resolution::MaterialCryoUp
@ MaterialCryoUp
Definition: egammaEnergyCorrectionTool.h:84
egEnergyCorr::es2017_R21_PRE
@ es2017_R21_PRE
Definition: egammaEnergyCorrectionTool.h:316
SG::Decorator
Helper class to provide type-safe access to aux data.
Definition: Decorator.h:59
CP::EgammaCalibrationAndSmearingTool::AbsEtaCaloPredicateFactory
const EgammaPredicate AbsEtaCaloPredicateFactory(double eta_min, double eta_max) const
Definition: EgammaCalibrationAndSmearingTool.h:237
egEnergyCorr::es2015cPRE_res_improved
@ es2015cPRE_res_improved
Definition: egammaEnergyCorrectionTool.h:306
lumiFormat.i
int i
Definition: lumiFormat.py:85
egEnergyCorr::Scale::topoClusterThresUp
@ topoClusterThresUp
Definition: egammaEnergyCorrectionTool.h:207
egEnergyCorr::Scale::ConvEfficiencyDown
@ ConvEfficiencyDown
Definition: egammaEnergyCorrectionTool.h:253
CP::EgammaCalibrationAndSmearingTool::applySystematicVariation
virtual StatusCode applySystematicVariation(const CP::SystematicSet &systConfig) override
effects: configure this tool for the given list of systematic variations.
Definition: EgammaCalibrationAndSmearingTool.cxx:1985
CP::EgammaCalibrationAndSmearingTool::m_currentResolutionVariation_data
egEnergyCorr::Resolution::Variation m_currentResolutionVariation_data
Definition: EgammaCalibrationAndSmearingTool.h:334
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
xAOD::EgammaHelpers::isElectron
bool isElectron(const xAOD::Egamma *eg)
is the object an electron (not Fwd)
Definition: EgammaxAODHelpers.cxx:12
CP::EgammaCalibrationAndSmearingTool::m_TESModel
egEnergyCorr::ESModel m_TESModel
Definition: EgammaCalibrationAndSmearingTool.h:164
LinearityADC
parameterization of correction for ADC non linearity
Definition: LinearityADC.h:25
python.LArMinBiasAlgConfig.int
int
Definition: LArMinBiasAlgConfig.py:59
egEnergyCorr::Resolution::afUp
@ afUp
Definition: egammaEnergyCorrectionTool.h:97
egEnergyCorr::Scale::MomentumDown
@ MomentumDown
Definition: egammaEnergyCorrectionTool.h:138
asg::AsgMetadataTool::beginInputFile
virtual StatusCode beginInputFile()
Function called when a new input file is opened.
Definition: AsgMetadataTool.cxx:180
egEnergyCorr::Scale::ConvRecoUp
@ ConvRecoUp
Definition: egammaEnergyCorrectionTool.h:261
master.flag
bool flag
Definition: master.py:29
PlotPulseshapeFromCool.input
input
Definition: PlotPulseshapeFromCool.py:106
egEnergyCorr::Resolution::Nominal
@ Nominal
Definition: egammaEnergyCorrectionTool.h:62
CP::EgammaCalibrationAndSmearingTool::m_varSF
double m_varSF
Definition: EgammaCalibrationAndSmearingTool.h:167
asg::AsgMessaging::msg
MsgStream & msg() const
The standard message stream.
Definition: AsgMessaging.cxx:49
egEnergyCorr::es2012a
@ es2012a
Definition: egammaEnergyCorrectionTool.h:295
CP::EgammaCalibrationAndSmearingTool::m_useGainInterpolation
int m_useGainInterpolation
Definition: EgammaCalibrationAndSmearingTool.h:188
egammaLayerRecalibTool::disable_PSCorrections
void disable_PSCorrections()
Definition: egammaLayerRecalibTool.h:358
asg::AsgMetadataTool::metaDataStop
virtual StatusCode metaDataStop()
Function called when the tool should write out its metadata.
Definition: AsgMetadataTool.cxx:204
plotIsoValidation.el
el
Definition: plotIsoValidation.py:197
ParticleImpl::phi
virtual double phi() const
phi in [-pi,pi[
Definition: ParticleImpl.h:524
egEnergyCorr::es2017_summer
@ es2017_summer
Definition: egammaEnergyCorrectionTool.h:310
python.xAODType.dummy
dummy
Definition: xAODType.py:4
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
egEnergyCorr::es2015c_summer
@ es2015c_summer
Definition: egammaEnergyCorrectionTool.h:307
MSG::name
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
Definition: MsgLevel.cxx:19
CP::EgammaCalibrationAndSmearingTool::m_usePSCorrection
int m_usePSCorrection
Definition: EgammaCalibrationAndSmearingTool.h:190
egEnergyCorr::Scale::L2MediumGainUp
@ L2MediumGainUp
Definition: egammaEnergyCorrectionTool.h:228
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
ParticleImpl::eta
virtual double eta() const
pseudo rapidity
Definition: ParticleImpl.h:514
CP::EgammaCalibrationAndSmearingTool::m_use_mapping_correction
bool m_use_mapping_correction
Definition: EgammaCalibrationAndSmearingTool.h:186
egEnergyCorr::Scale::None
@ None
Definition: egammaEnergyCorrectionTool.h:129
CP::EgammaCalibrationAndSmearingTool::EtaCaloPredicateFactory
const EgammaPredicate EtaCaloPredicateFactory(double eta_min, double eta_max) const
Definition: EgammaCalibrationAndSmearingTool.h:217
egEnergyCorr::Resolution::MaterialCryoDown
@ MaterialCryoDown
Definition: egammaEnergyCorrectionTool.h:83
egEnergyCorr::UNDEFINED
@ UNDEFINED
Definition: egammaEnergyCorrectionTool.h:334
CP::EgammaCalibrationAndSmearingTool::m_ADCLinearity_tool
std::shared_ptr< LinearityADC > m_ADCLinearity_tool
Definition: EgammaCalibrationAndSmearingTool.h:312
CP::EgammaCalibrationAndSmearingTool::m_TResolutionType
egEnergyCorr::Resolution::resolutionType m_TResolutionType
Definition: EgammaCalibrationAndSmearingTool.h:169
CP::EgammaCalibrationAndSmearingTool::m_gain_tool_run2
std::unique_ptr< egGain::GainUncertainty > m_gain_tool_run2
Definition: EgammaCalibrationAndSmearingTool.h:311
egGain::GainTool::CorrectionGainTool
double CorrectionGainTool(double eta_input, double energy_input, double energy_layer2_input, PATCore::ParticleType::Type ptype=PATCore::ParticleType::Electron) const
Definition: GainTool.cxx:139
CP::EgammaCalibrationAndSmearingTool::oldtool_resolution_flag_this_event
egEnergyCorr::Resolution::Variation oldtool_resolution_flag_this_event(const xAOD::Egamma &p, const xAOD::EventInfo &event_info) const
Definition: EgammaCalibrationAndSmearingTool.cxx:1162
egEnergyCorr::Scale::ZeeStatDown
@ ZeeStatDown
Definition: egammaEnergyCorrectionTool.h:145
CP::EgammaCalibrationAndSmearingTool::correction_phi_unif
double correction_phi_unif(double eta, double phi) const
Definition: EgammaCalibrationAndSmearingTool.cxx:2222
CP::GeV
const double GeV
Definition: EgammaCalibrationAndSmearingTool.cxx:42
CP::EgammaCalibrationAndSmearingTool::m_doSmearing
int m_doSmearing
Definition: EgammaCalibrationAndSmearingTool.h:166
CP::EgammaCalibrationAndSmearingTool::ResolutionDecorrelation::FULL
@ FULL
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
CP::EgammaCalibrationAndSmearingTool::AUTO
static const int AUTO
Definition: EgammaCalibrationAndSmearingTool.h:105
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
egEnergyCorr::Resolution::None
@ None
Definition: egammaEnergyCorrectionTool.h:59
merge.output
output
Definition: merge.py:17
CP::EgammaCalibrationAndSmearingTool::m_use_AFII
int m_use_AFII
Definition: EgammaCalibrationAndSmearingTool.h:171
CP::EgammaCalibrationAndSmearingTool::m_rootTool
std::unique_ptr< AtlasRoot::egammaEnergyCorrectionTool > m_rootTool
Definition: EgammaCalibrationAndSmearingTool.h:318
egEnergyCorr::Resolution::PileUpDown
@ PileUpDown
Definition: egammaEnergyCorrectionTool.h:87
egEnergyCorr::Scale::E4ScintillatorUp
@ E4ScintillatorUp
Definition: egammaEnergyCorrectionTool.h:179
CP::EgammaCalibrationAndSmearingTool::setupSystematics
void setupSystematics()
Definition: EgammaCalibrationAndSmearingTool.cxx:1206
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
asg::AsgMetadataTool::m_inputMetaStore
MetaStore_t m_inputMetaStore
Object accessing the input metadata store.
Definition: AsgMetadataTool.h:119
egEnergyCorr::Scale::LArCalibExtra2015PreUp
@ LArCalibExtra2015PreUp
Definition: egammaEnergyCorrectionTool.h:165
CP::SystematicSet::insert
void insert(const SystematicVariation &systematic)
description: insert a systematic into the set
Definition: SystematicSet.cxx:88
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
egEnergyCorr::Resolution::MaterialIBLUp
@ MaterialIBLUp
Definition: egammaEnergyCorrectionTool.h:91
ActsTrk::to_string
std::string to_string(const DetectorType &type)
Definition: GeometryDefs.h:34
egEnergyCorr::es2016PRE
@ es2016PRE
Definition: egammaEnergyCorrectionTool.h:308
egEnergyCorr::es2017_summer_final
@ es2017_summer_final
Definition: egammaEnergyCorrectionTool.h:312
CP::EgammaCalibrationAndSmearingTool::xAOD2ptype
PATCore::ParticleType::Type xAOD2ptype(const xAOD::Egamma &particle) const
Definition: EgammaCalibrationAndSmearingTool.cxx:819
xAOD::get_phi_calo
float get_phi_calo(const xAOD::CaloCluster &cluster, int author, bool do_throw=false)
Definition: EgammaCalibrationAndSmearingTool.h:41
egEnergyCorr::Scale::ADCLinUp
@ ADCLinUp
Definition: egammaEnergyCorrectionTool.h:193
asg::AsgServiceConfig
an object that can create a AsgService
Definition: AsgServiceConfig.h:25
egEnergyCorr::Resolution::OFCUp
@ OFCUp
Definition: egammaEnergyCorrectionTool.h:101
CP::EgammaCalibrationAndSmearingTool::m_MVAfolder
std::string m_MVAfolder
Definition: EgammaCalibrationAndSmearingTool.h:319
CP::is_after_run1
bool is_after_run1(egEnergyCorr::ESModel model)
Definition: EgammaCalibrationAndSmearingTool.cxx:235
egEnergyCorr::Scale::MatPP0Up
@ MatPP0Up
Definition: egammaEnergyCorrectionTool.h:241
egEnergyCorr::es2012XX
@ es2012XX
Definition: egammaEnergyCorrectionTool.h:302
egEnergyCorr::Scale::ADCLinDown
@ ADCLinDown
Definition: egammaEnergyCorrectionTool.h:194
xAOD::Electron_v1
Definition: Electron_v1.h:34
egEnergyCorr::Scale::S12ExtraLastEtaBinRun2Down
@ S12ExtraLastEtaBinRun2Down
Definition: egammaEnergyCorrectionTool.h:212
egEnergyCorr::es2023_R22_Run2_v0
@ es2023_R22_Run2_v0
Definition: egammaEnergyCorrectionTool.h:329
egEnergyCorr::es2012c
@ es2012c
Definition: egammaEnergyCorrectionTool.h:297
egEnergyCorr::Resolution::OFCDown
@ OFCDown
Definition: egammaEnergyCorrectionTool.h:102
egEnergyCorr::Scale::PSb12Down
@ PSb12Down
Definition: egammaEnergyCorrectionTool.h:190
xAOD::EventInfo_v1
Class describing the basic event information.
Definition: EventInfo_v1.h:43
CP::EgammaCalibrationAndSmearingTool::m_syst_description
std::map< CP::SystematicVariation, SysInfo > m_syst_description
Definition: EgammaCalibrationAndSmearingTool.h:326
egEnergyCorr::es2017
@ es2017
Definition: egammaEnergyCorrectionTool.h:309
xAOD::Photon
Photon_v1 Photon
Definition of the current "egamma version".
Definition: Event/xAOD/xAODEgamma/xAODEgamma/Photon.h:17
egEnergyCorr::es2018_R21_v1
@ es2018_R21_v1
Definition: egammaEnergyCorrectionTool.h:325
PathResolverFindCalibFile
std::string PathResolverFindCalibFile(const std::string &logical_file_name)
Definition: PathResolver.cxx:431
CP::EgammaCalibrationAndSmearingTool::intermodule_correction
double intermodule_correction(double Ecl, double phi, double eta) const
Definition: EgammaCalibrationAndSmearingTool.cxx:2034
egEnergyCorr::Resolution::SigmaEff80
@ SigmaEff80
Definition: egammaEnergyCorrectionTool.h:114
egEnergyCorr::Scale::ConvEfficiencyUp
@ ConvEfficiencyUp
Definition: egammaEnergyCorrectionTool.h:252
CP::EgammaCalibrationAndSmearingTool::m_set_seed_function
IdFunction m_set_seed_function
Definition: EgammaCalibrationAndSmearingTool.h:338
egEnergyCorr::Scale::PSb12Up
@ PSb12Up
Definition: egammaEnergyCorrectionTool.h:189
egammaLayerRecalibTool
Definition: egammaLayerRecalibTool.h:317
egEnergyCorr::Scale::E4ScintillatorDown
@ E4ScintillatorDown
Definition: egammaEnergyCorrectionTool.h:180
columnar::isAvailable
bool isAvailable(ObjectId< OT, CM > id) const noexcept
Definition: ColumnAccessor.h:183
CP::CorrectionCode::Ok
@ Ok
The correction was done successfully.
Definition: CorrectionCode.h:38
egEnergyCorr::Resolution::MaterialIDDown
@ MaterialIDDown
Definition: egammaEnergyCorrectionTool.h:77
CP::EgammaCalibrationAndSmearingTool::m_useLayerCorrection
int m_useLayerCorrection
Definition: EgammaCalibrationAndSmearingTool.h:189
egEnergyCorr::Scale::ConvFakeRateUp
@ ConvFakeRateUp
Definition: egammaEnergyCorrectionTool.h:254
a
TList * a
Definition: liststreamerinfos.cxx:10
columnar::empty
bool empty() const noexcept
Definition: ObjectRange.h:129
egEnergyCorr::Resolution::MaterialIDUp
@ MaterialIDUp
Definition: egammaEnergyCorrectionTool.h:78
egEnergyCorr::Scale::Wtots1Down
@ Wtots1Down
Definition: egammaEnergyCorrectionTool.h:238
h
egEnergyCorr::es2017_summer_improved
@ es2017_summer_improved
Definition: egammaEnergyCorrectionTool.h:311
xAOD::Photon_v1
Definition: Photon_v1.h:37
asg::AsgMetadataTool
Base class for dual-use tools that provide file metadata access.
Definition: AsgMetadataTool.h:48
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
CP::SystematicRegistry
This module implements the central registry for handling systematic uncertainties with CP tools.
Definition: SystematicRegistry.h:25
xAOD::EgammaHelpers::isPhoton
bool isPhoton(const xAOD::Egamma *eg)
is the object a photon
Definition: EgammaxAODHelpers.cxx:21
egEnergyCorr::es2024_Run3_ofc0_v0
@ es2024_Run3_ofc0_v0
Definition: egammaEnergyCorrectionTool.h:331
egEnergyCorr::Resolution::MaterialCaloUp
@ MaterialCaloUp
Definition: egammaEnergyCorrectionTool.h:80
egEnergyCorr::Resolution::SamplingTermDown
@ SamplingTermDown
Definition: egammaEnergyCorrectionTool.h:73
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition: AthCommonMsg.h:24
CP::EgammaCalibrationAndSmearingTool::m_layer_recalibration_tool
egammaLayerRecalibTool * m_layer_recalibration_tool
Definition: EgammaCalibrationAndSmearingTool.h:314
CP::CorrectionCode
Return value from object correction CP tools.
Definition: CorrectionCode.h:31
xAOD::EgammaParameters::electron
@ electron
Definition: EgammaEnums.h:18
CP::use_phi_uniform_correction
bool use_phi_uniform_correction(egEnergyCorr::ESModel model)
Definition: EgammaCalibrationAndSmearingTool.cxx:231
xAOD::get_eta_calo
float get_eta_calo(const xAOD::CaloCluster &cluster, int author, bool do_throw=false)
Definition: EgammaCalibrationAndSmearingTool.h:64
egEnergyCorr::Scale::afDown
@ afDown
Definition: egammaEnergyCorrectionTool.h:246
CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_resolution_name
std::string m_decorrelation_model_resolution_name
Definition: EgammaCalibrationAndSmearingTool.h:160
egEnergyCorr::Scale::L2MediumGainDown
@ L2MediumGainDown
Definition: egammaEnergyCorrectionTool.h:227
egEnergyCorr::Resolution::MaterialGapDown
@ MaterialGapDown
Definition: egammaEnergyCorrectionTool.h:81
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
EgammaCalibPeriodRunNumbersExample::run_2016
const int run_2016
Definition: Interfaces/EgammaAnalysisInterfaces/EgammaAnalysisInterfaces/IEgammaCalibrationAndSmearingTool.h:21
egEnergyCorr::es2017_R21_ofc0_v1
@ es2017_R21_ofc0_v1
Definition: egammaEnergyCorrectionTool.h:322
egEnergyCorr::Scale::EXTRARUN3PREUp
@ EXTRARUN3PREUp
Definition: egammaEnergyCorrectionTool.h:269
CP::gainToolFactory
std::unique_ptr< egGain::GainTool > gainToolFactory(egEnergyCorr::ESModel model)
Definition: EgammaCalibrationAndSmearingTool.cxx:44
egEnergyCorr::Scale::LArTemperature2016PreDown
@ LArTemperature2016PreDown
Definition: egammaEnergyCorrectionTool.h:172
egEnergyCorr::es2022_R22_PRE
@ es2022_R22_PRE
Definition: egammaEnergyCorrectionTool.h:328
xAOD::Egamma_v1::eta
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
Definition: Egamma_v1.cxx:70
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
egEnergyCorr::Scale::LArCalibDown
@ LArCalibDown
Definition: egammaEnergyCorrectionTool.h:156
PATCore::ParticleType::Electron
@ Electron
Definition: PATCoreEnums.h:40
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
egammaLayerRecalibTool::fixForMissingCells
void fixForMissingCells(bool fix=true)
Definition: egammaLayerRecalibTool.h:356
CP::egammaLayerRecalibToolFactory
std::unique_ptr< egammaLayerRecalibTool > egammaLayerRecalibToolFactory(egEnergyCorr::ESModel model, int enableSacc)
Definition: EgammaCalibrationAndSmearingTool.cxx:135
egammaLayerRecalibTool::disable_SaccCorrections
void disable_SaccCorrections()
Definition: egammaLayerRecalibTool.h:360
CP::EgammaCalibrationAndSmearingTool::applyCorrection
virtual CP::CorrectionCode applyCorrection(xAOD::Egamma &) const override
Definition: EgammaCalibrationAndSmearingTool.cxx:857
SG::DataProxy
Definition: DataProxy.h:45
xAOD::bool
setBGCode setTAP setLVL2ErrorBits bool
Definition: TrigDecision_v1.cxx:60
CP::EgammaCalibrationAndSmearingTool::m_syst_description_resolution
std::map< CP::SystematicVariation, egEnergyCorr::Resolution::Variation > m_syst_description_resolution
Definition: EgammaCalibrationAndSmearingTool.h:328
egEnergyCorr::es2015_5TeV
@ es2015_5TeV
Definition: egammaEnergyCorrectionTool.h:314
egEnergyCorr::Resolution::AllUp
@ AllUp
Definition: egammaEnergyCorrectionTool.h:66
egEnergyCorr::Resolution::MaterialCaloDown
@ MaterialCaloDown
Definition: egammaEnergyCorrectionTool.h:79
egEnergyCorr::Scale::S12ExtraLastEtaBinRun2Up
@ S12ExtraLastEtaBinRun2Up
Definition: egammaEnergyCorrectionTool.h:211
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
CP::EgammaCalibrationAndSmearingTool::m_decorrelation_model_scale
ScaleDecorrelation m_decorrelation_model_scale
Definition: EgammaCalibrationAndSmearingTool.h:161
egEnergyCorr::es2018_R21_v0
@ es2018_R21_v0
Definition: egammaEnergyCorrectionTool.h:324
CP::EgammaCalibrationAndSmearingTool::m_useS12Correction
int m_useS12Correction
Definition: EgammaCalibrationAndSmearingTool.h:191
egEnergyCorr::es2015PRE
@ es2015PRE
Definition: egammaEnergyCorrectionTool.h:303
CP::EgammaCalibrationAndSmearingTool::m_layer_recalibration_tune
std::string m_layer_recalibration_tune
Definition: EgammaCalibrationAndSmearingTool.h:315
CP::EgammaCalibrationAndSmearingTool::m_useCaloDistPhiUnifCorrection
int m_useCaloDistPhiUnifCorrection
Definition: EgammaCalibrationAndSmearingTool.h:177
fitman.k
k
Definition: fitman.py:528
xAOD::EventInfo_v1::eventType
bool eventType(EventType type) const
Check for one particular bitmask value.
CP::SystematicRegistry::getInstance
static SystematicRegistry & getInstance()
Get the singleton instance of the registry for the curren thread.
Definition: SystematicRegistry.cxx:25
CP::EgammaCalibrationAndSmearingTool::m_use_uA2MeV_2015_first2weeks_correction
int m_use_uA2MeV_2015_first2weeks_correction
Definition: EgammaCalibrationAndSmearingTool.h:185
egEnergyCorr::Scale::topoClusterThresDown
@ topoClusterThresDown
Definition: egammaEnergyCorrectionTool.h:208
CP::EgammaCalibrationAndSmearingTool::m_fixForMissingCells
Gaudi::Property< bool > m_fixForMissingCells
Definition: EgammaCalibrationAndSmearingTool.h:199
ServiceHandle< IIncidentSvc >
egEnergyCorr::Resolution::MaterialIBLDown
@ MaterialIBLDown
Definition: egammaEnergyCorrectionTool.h:92
asg::AsgMetadataTool::m_useIncidents
bool m_useIncidents
Definition: AsgMetadataTool.h:128
xAOD::EgammaParameters::unconvertedPhoton
@ unconvertedPhoton
Definition: EgammaEnums.h:19
egEnergyCorr::Resolution::AllDown
@ AllDown
Definition: egammaEnergyCorrectionTool.h:65