ATLAS Offline Software
VGammaORAlg.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
10 
11 namespace CP {
12 
14 
19 
20  return StatusCode::SUCCESS;
21  }
22 
24 
25  // the event-level filter
27 
28  for (const auto &sys : m_systematicsList.systematicsVector()) {
29  // the per-systematic filter
30  CP::SysFilterReporter filter(filterCombiner, sys);
31 
32  const xAOD::EventInfo *evtInfo = nullptr;
33  ANA_CHECK(m_eventInfoHandle.retrieve(evtInfo, sys));
34 
35  bool in_vgamma_overlap;
36  ANA_CHECK(m_vgammaORTool->inOverlap(in_vgamma_overlap));
37  m_inOverlapHandle.set(*evtInfo, in_vgamma_overlap, sys);
38 
39  if (!m_noFilter.value()) {
40  if (m_keepOverlap)
41  filter.setPassed( in_vgamma_overlap );
42  else
43  filter.setPassed( !in_vgamma_overlap );
44  }
45  }
46 
47  return StatusCode::SUCCESS;
48  }
49 
51 
53  return StatusCode::SUCCESS;
54  }
55 } // namespace
CP::SysFilterReporterCombiner
a reporter class that combines the filter decisions for all systematics
Definition: SysFilterReporterCombiner.h:34
CP::SysWriteDecorHandle::set
void set(const SG::AuxElement &object, const T &value, const CP::SystematicSet &sys) const
set the object decoration for the given systematic
VGammaORAlg.h
CP::VGammaORAlg::m_vgammaORTool
ToolHandle< IVGammaORTool > m_vgammaORTool
the overlap removal tool
Definition: VGammaORAlg.h:36
CP::VGammaORAlg::m_keepOverlap
Gaudi::Property< bool > m_keepOverlap
which way to run the event filter
Definition: VGammaORAlg.h:61
ANA_CHECK
#define ANA_CHECK(EXP)
check whether the given expression was successful
Definition: Control/AthToolSupport/AsgMessaging/AsgMessaging/MessageCheck.h:324
CP::VGammaORAlg::m_inOverlapHandle
CP::SysWriteDecorHandle< bool > m_inOverlapHandle
the decoration for the tool decision
Definition: VGammaORAlg.h:46
CP::SysListHandle::systematicsVector
const std::vector< CP::SystematicSet > & systematicsVector() const
the list of systematics to loop over
Definition: SysListHandle.cxx:96
CP
Select isolated Photons, Electrons and Muons.
Definition: Control/xAODRootAccess/xAODRootAccess/TEvent.h:48
CP::SysFilterReporterParams::finalize
StatusCode finalize()
do anything we need to do in finalize
Definition: SysFilterReporterParams.cxx:63
mapkey::sys
@ sys
Definition: TElectronEfficiencyCorrectionTool.cxx:42
SysFilterReporter.h
covarianceTool.filter
filter
Definition: covarianceTool.py:514
CP::SysListHandle::initialize
::StatusCode initialize()
intialize this property
Definition: SysListHandle.cxx:69
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
CP::SysWriteDecorHandle::initialize
StatusCode initialize(SysListHandle &sysListHandle, const ISysHandleBase &objectHandle)
initialize this handle
CP::SysFilterReporter
a systematics aware filter reporter
Definition: SysFilterReporter.h:44
CP::VGammaORAlg::m_noFilter
Gaudi::Property< bool > m_noFilter
whether to not apply an event filter
Definition: VGammaORAlg.h:56
SysFilterReporterCombiner.h
CP::VGammaORAlg::execute
virtual StatusCode execute() override
Definition: VGammaORAlg.cxx:23
CP::VGammaORAlg::initialize
virtual StatusCode initialize() override
Definition: VGammaORAlg.cxx:13
CP::SysFilterReporterParams::initialize
StatusCode initialize(SysListHandle &sysListHandle)
do anything we need to do in initialize
Definition: SysFilterReporterParams.cxx:25
CP::VGammaORAlg::m_systematicsList
CP::SysListHandle m_systematicsList
the systematics
Definition: VGammaORAlg.h:33
CP::VGammaORAlg::m_eventInfoHandle
CP::SysReadHandle< xAOD::EventInfo > m_eventInfoHandle
the event info handle
Definition: VGammaORAlg.h:41
xAOD::EventInfo_v1
Class describing the basic event information.
Definition: EventInfo_v1.h:43
CP::VGammaORAlg::m_filterParams
CP::SysFilterReporterParams m_filterParams
the event filter for the tool decision
Definition: VGammaORAlg.h:51
CP::VGammaORAlg::finalize
virtual StatusCode finalize() override
Definition: VGammaORAlg.cxx:50