38 return StatusCode::SUCCESS;
51 std::pair< xAOD::ElectronContainer*, xAOD::ShallowAuxContainer* > electrons_shallowCopy =
xAOD::shallowCopyContainer( *electrons );
53 CHECK(
evtStore()->record( electrons_shallowCopy.first,
"ElectronCollectionCorr") );
54 CHECK(
evtStore()->record( electrons_shallowCopy.second,
"ElectronCollectionCorrAux.") );
59 std::vector<CP::SystematicSet> sysList;
61 sysList.emplace_back();
63 ATH_MSG_INFO(
"SIZE of the systematics set:" << recommendedSystematics.
size());
65 for(
const auto & recommendedSystematic : recommendedSystematics)
67 sysList.emplace_back();
68 sysList.back().insert(recommendedSystematic);
71 std::vector<CP::SystematicSet>::const_iterator sysListItr;
78 for (; el_it != el_it_last; ++el_it, ++i) {
81 ATH_MSG_INFO(
"xAOD/raw pt, eta, phi = " << el->pt() <<
", " << el->eta() <<
", " << el->phi());
90 for (sysListItr = sysList.begin(); sysListItr != sysList.end(); ++sysListItr)
95 ATH_MSG_ERROR(
"Cannot configure calibration tool for systematics");
98 TString syst_name = TString(sysListItr->name());
99 if(!syst_name.BeginsWith(
"EL") && !syst_name.BeginsWith(
"EG"))
continue;
105 ATH_MSG_INFO(
"Calibrated pt with systematic " << syst_name <<
" = " << el->pt());
112 for (; el_it != el_it_last; ++el_it, ++j) {
120 return StatusCode::SUCCESS;
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_WARNING(x)
#define CHECK(...)
Evaluate an expression and check for errors.
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
ServiceHandle< StoreGateSvc > & evtStore()
@ Ok
The correction was done successfully.
This module implements the central registry for handling systematic uncertainties with CP tools.
const SystematicSet & recommendedSystematics() const
returns: the recommended set of systematics
static SystematicRegistry & getInstance()
Get the singleton instance of the registry for the curren thread.
Class to wrap a set of SystematicVariations.
size_t size() const
returns: size of the set
DataModel_detail::iterator< DataVector > iterator
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
ElectronContainer_v1 ElectronContainer
Definition of the current "electron container version".
EventInfo_v1 EventInfo
Definition of the latest event info version.
std::pair< std::unique_ptr< T >, std::unique_ptr< ShallowAuxContainer > > shallowCopyContainer(const T &cont, const EventContext &ctx)
Function making a shallow copy of a constant container.
Electron_v1 Electron
Definition of the current "egamma version".