Skip to content
Snippets Groups Projects
Commit 47fbcd0c authored by James Beacham's avatar James Beacham
Browse files

Merge branch 'cherry-pick-9c729a5a [formerly 16a29caa93]-21.0' into '21.0'

Sweeping !6968 from 21.2 to 21.0.
Fix container key name in TrigEgammaMatching for isolated photons

See merge request atlas/athena!7145

Former-commit-id: dc922c1e2d311ce67d0482f4484bca3c96683462
parents dceaae53 81e3a551
No related branches found
No related tags found
No related merge requests found
......@@ -152,11 +152,15 @@ namespace Trig {
}
}
else if(xAOD::EgammaHelpers::isPhoton(eg)){
std::string key = "egamma_Photons";
if(boost::contains(trigger,"icaloloose") || boost::contains(trigger,"icalovloose") || boost::contains(trigger,"icalotight")) key = "egamma_Iso_Photons";
//key="";
const xAOD::Photon* phOff =static_cast<const xAOD::Photon*> (eg);
#ifdef XAOD_ANALYSIS
const auto vec = fc.containerFeature<xAOD::PhotonContainer>("egamma_Photons");
const auto vec = fc.containerFeature<xAOD::PhotonContainer>(key);
#else
const auto vec = fc.get<xAOD::PhotonContainer>("egamma_Photons");
const auto vec = fc.get<xAOD::PhotonContainer>(key);
#endif // XAOD_ANALYSIS
for(const auto feat : vec){
const xAOD::PhotonContainer *cont = feat.cptr();
......@@ -184,11 +188,15 @@ namespace Trig {
ATH_MSG_DEBUG("Match HLT Photon");
// Get the container of online electrons associated to passed items
auto fc = (m_trigDecTool->features(trigger,TrigDefs::alsoDeactivateTEs));
std::string key = "egamma_Photons";
if(boost::contains(trigger,"iloose") || boost::contains(trigger,"ivloose") || boost::contains(trigger,"itight")) key = "egamma_Iso_Photons";
key="";
#ifdef XAOD_ANALYSIS
const auto vec = fc.containerFeature<xAOD::PhotonContainer>("",TrigDefs::alsoDeactivateTEs);
const auto vec = fc.containerFeature<xAOD::PhotonContainer>(key,TrigDefs::alsoDeactivateTEs);
#else
const auto vec = fc.get<xAOD::PhotonContainer>("",TrigDefs::alsoDeactivateTEs);
const auto vec = fc.get<xAOD::PhotonContainer>(key,TrigDefs::alsoDeactivateTEs);
#endif // XAOD_ANALYSIS
ATH_MSG_DEBUG("EF FC Size " << vec.size());
double deltaR=0.;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment