  | 
  
    ATLAS Offline Software
    
   | 
 
 
 
 
Go to the documentation of this file.
   27 #ifndef XAOD_STANDALONE // For now metadata is Athena-only 
   37     return StatusCode::FAILURE;
 
   40   if (
m_isPHYSLITE && photonkey.find(
"AnalysisPhotons")==std::string::npos){
 
   41     ATH_MSG_ERROR(
"You are running on PHYSLITE derivation. Please change the Photons container to 'AnalysisPhotons'");
 
   42     return StatusCode::FAILURE;
 
   47     if (containerToBeCopied != 
nullptr) {
 
   48       photons = containerToBeCopied;
 
   54     copy = shallowcopy.first;
 
   55     copyaux = shallowcopy.second;
 
   58       ATH_MSG_WARNING(
"Failed to set original object links on " << photonkey);
 
   61     ATH_MSG_DEBUG(
"Not retrieving photon collecton, using existing one provided by user");
 
   74   return StatusCode::SUCCESS;
 
   80   ATH_MSG_VERBOSE( 
"Starting FillPhoton on ph with pre-calibration pt=" << input.pt() );
 
   82   if ( !input.caloCluster() ) {
 
   83      ATH_MSG_WARNING( 
"FillPhoton: no caloCluster found: " << input.caloCluster() );
 
   84      return StatusCode::SUCCESS;
 
   93     ATH_MSG_INFO( 
"PHOTON cl eta: " << input.caloCluster()->eta() );
 
   94     ATH_MSG_INFO( 
"PHOTON cl phi: " << input.caloCluster()->phi() );
 
   95     ATH_MSG_INFO( 
"PHOTON cl e: " << input.caloCluster()->e() );
 
   98     ATH_MSG_INFO( 
"PHOTON deadHVTools: " << pass_deadHVTool );
 
  101   dec_baseline(input) = 
false;
 
  102   dec_selected(input) = 0;
 
  103   dec_isol(input) = 
false;
 
  106   if (!pass_deadHVTool) 
return StatusCode::SUCCESS; 
 
  110     return StatusCode::SUCCESS;
 
  113   if (std::abs(input.caloCluster()->etaBE(2)) >= etacut) 
return StatusCode::SUCCESS;
 
  116     if  ( std::abs( input.caloCluster()->etaBE(2) ) >1.37 &&  std::abs( input.caloCluster()->etaBE(2) ) <1.52) {
 
  117       return StatusCode::SUCCESS;
 
  122     ATH_MSG_ERROR(
"FillPhoton: EgammaCalibTool applyCorrection failed");
 
  125     ATH_MSG_ERROR(
"FillPhoton: IsolationCorrectionTool applyCorrection failed");
 
  129   if (input.pt() < 
ptcut) 
return StatusCode::SUCCESS;
 
  133     return StatusCode::SUCCESS;
 
  136   bool passPhCleaning = 
false;
 
  137   if (acc_passPhCleaning.isAvailable(input) && acc_passPhCleaningNoTime.isAvailable(input)) {
 
  144   if (!passPhCleaning) 
return StatusCode::SUCCESS;
 
  147   bool passBaseID = 
false;
 
  153   if (!passBaseID) 
return StatusCode::SUCCESS;
 
  158   dec_baseline(input) = 
true;
 
  159   dec_selected(input) = 2;
 
  163   return StatusCode::SUCCESS;
 
  169   dec_signal(input) = 
false;
 
  171   if ( !acc_baseline(input) ) 
return false;
 
  175   if ( input.pt() < 
ptcut ) 
return false;
 
  176   if ( etacut==DUMMYDEF ){
 
  177     if(std::abs(input.caloCluster()->etaBE(2)) > 
m_photonEta ) 
return false;
 
  179   else if ( std::abs(input.caloCluster()->etaBE(2)) > etacut ) 
return false;
 
  182     if  ( std::abs( input.caloCluster()->etaBE(2) ) >1.37 &&  std::abs( input.caloCluster()->etaBE(2) ) <1.52) {
 
  195     ATH_MSG_VERBOSE (
"DFCommonPhotonsIsEMxxx variables are not found. Calculating the ID from Photon ID tool..");
 
  198   if ( !passID ) 
return false;
 
  200   dec_signal(input) = 
true;
 
  232     double sf_trigger = 1.;
 
  242   dec_effscalefact(ph) = 
sf;
 
  253   if (ret != StatusCode::SUCCESS) {
 
  254     ATH_MSG_ERROR(
"Cannot configure AsgPhotonEfficiencyCorrectionTool (reco) for systematic var. " << systConfig.
name() );
 
  258   if (ret != StatusCode::SUCCESS) {
 
  259     ATH_MSG_ERROR(
"Cannot configure AsgPhotonEfficiencyCorrectionTool (iso) for systematic var. " << systConfig.
name() );
 
  263   if (ret != StatusCode::SUCCESS) {
 
  264     ATH_MSG_ERROR(
"Cannot configure AsgPhotonEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.
name() );
 
  289     double sf_trigger = 1.;
 
  299   if (ret != StatusCode::SUCCESS) {
 
  300     ATH_MSG_ERROR(
"Cannot configure AsgPhotonEfficiencyCorrectionTool back to default.");
 
  304   if (ret != StatusCode::SUCCESS) {
 
  305     ATH_MSG_ERROR(
"Cannot configure AsgPhotonEfficiencyCorrectionTool (iso) for systematic var. " << systConfig.
name() );
 
  309   if (ret != StatusCode::SUCCESS) {
 
  310     ATH_MSG_ERROR(
"Cannot configure AsgPhotonEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.
name() );
 
  315   dec_effscalefact(ph) = 
sf;
 
  
def retrieve(aClass, aKey=None)
 
SG::ConstAccessor< char > m_acc_photonIdBaseline
 
double m_photonBaselinePt
 
asg::AnaToolHandle< IAsgDeadHVCellRemovalTool > m_deadHVTool
 
asg::AnaToolHandle< CP::IEgammaCalibrationAndSmearingTool > m_egammaCalibTool
Combined electron collection.
 
double GetTotalPhotonSFsys(const xAOD::PhotonContainer &photons, const CP::SystematicSet &systConfig, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) override final
 
bool m_photonBaselineCrackVeto
 
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > m_photonTriggerSFTool
 
asg::AnaToolHandle< CP::IIsolationSelectionTool > m_isoBaselineTool
 
Class creating a shallow copy of an existing auxiliary container.
 
Class to wrap a set of SystematicVariations.
 
std::string m_photonIso_WP
 
std::string name() const
returns: the systematics joined into a single string.
 
bool IsSignalPhoton(const xAOD::Photon &input, const float ptcut, const float etacut=DUMMYDEF) const override final
 
#define ATH_MSG_VERBOSE(x)
 
double GetSignalPhotonSFsys(const xAOD::Photon &ph, const CP::SystematicSet &systConfig, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) override final
 
double m_photonBaselineEta
 
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > m_photonEfficiencySFTool
 
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
 
bool passOQquality(const xAOD::Photon &ph)
Helper to ease the implemmantation of the pass Quality requirements.
 
@ OutOfValidityRange
Input object is out of validity range.
 
virtual asg::AcceptData accept(const xAOD::IParticle *part) const =0
accept with pointer to IParticle so as to not hide the IAsgSelectionTool one
 
const uint16_t AuthorAmbiguous
Object Reconstructed by standard cluster-based algorithm.
 
::StatusCode StatusCode
StatusCode definition for legacy code.
 
std::pair< std::vector< unsigned int >, bool > res
 
asg::AnaToolHandle< IAsgPhotonIsEMSelector > m_photonSelIsEM
 
std::string m_photonBaselineIso_WP
 
double GetTotalPhotonSF(const xAOD::PhotonContainer &photons, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) const override final
 
double GetSignalPhotonSF(const xAOD::Photon &ph, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) const override final
 
std::pair< std::unique_ptr< T >, std::unique_ptr< ShallowAuxContainer > > shallowCopyContainer(const T &cont, [[maybe_unused]] const EventContext &ctx)
Function making a shallow copy of a constant container.
 
StatusCode FillPhoton(xAOD::Photon &input, const float ptcut, const float etacut) override final
 
const uint32_t BADCLUSPHOTON
 
@ Ok
The correction was done successfully.
 
StatusCode GetPhotons(xAOD::PhotonContainer *©, xAOD::ShallowAuxContainer *©aux, const bool recordSG=true, const std::string &photonkey="Photons", const xAOD::PhotonContainer *containerToBeCopied=nullptr) override final
 
#define ATH_MSG_WARNING(x)
 
asg::AnaToolHandle< IAsgPhotonIsEMSelector > m_photonSelIsEMBaseline
 
bool setOriginalObjectLink(const IParticle &original, IParticle ©)
This function should be used by CP tools when they make a deep copy of an object in their correctedCo...
 
Return value from object correction CP tools.
 
CP::SystematicSet m_currentSyst
 
const uint16_t AuthorPhoton
Object Reconstructed by standard cluster-based algorithm.
 
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
 
bool passOQqualityDelayed(const xAOD::Photon &ph)
Helpers to ease the implementation of the pass Quality requirements.
 
setBGCode setTAP setLVL2ErrorBits bool
 
asg::AnaToolHandle< CP::IIsolationCorrectionTool > m_isoCorrTool
 
SG::ConstAccessor< char > m_acc_photonId
 
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > m_photonIsolationSFTool
 
asg::AnaToolHandle< IEGammaAmbiguityTool > m_egammaAmbiguityTool
 
asg::AnaToolHandle< CP::IIsolationSelectionTool > m_isoTool