20#include <unordered_set>
28 StatusCode SysListHandle ::
33 ANA_MSG_ERROR (
"trying to add/initialize data handle after initializing SysListHandle");
34 return StatusCode::FAILURE;
39 return StatusCode::FAILURE;
42 return StatusCode::SUCCESS;
47 StatusCode SysListHandle ::
54 return StatusCode::SUCCESS;
59 StatusCode SysListHandle ::
63 tool.affectingSystematics());
68 ::StatusCode SysListHandle ::
78 for (
auto& sys : affecting)
80 if (!std::regex_match (sys.basename(), filter))
90 return StatusCode::SUCCESS;
95 const std::vector<CP::SystematicSet>& SysListHandle ::
96 systematicsVector ()
const
104 StatusCode SysListHandle ::
105 fillSystematicsVector ()
109 std::unordered_set<CP::SystematicSet> knownSys;
115 if (knownSys.find (filtered) == knownSys.end())
118 knownSys.insert (std::move(filtered));
121 return StatusCode::SUCCESS;
a basic interface for all systematics handles
virtual bool empty() const noexcept=0
whether this is an empty handle
StatusCode addSystematics(const CP::SystematicSet &recommended, const CP::SystematicSet &affecting)
register a set of affecting variables for the current algorithm (usually obtained from an CP::ISystem...
StatusCode fillSystematicsVector()
CP::SystematicSet m_affecting
this set of affecting systematics
std::vector< ISysHandleBase * > m_sysHandles
the list of systematics handles we have
std::vector< CP::SystematicSet > m_systematicsVector
the value of systematicsVector
bool isInitialized() const noexcept
whether initialize has been called successfully
bool m_isInitialized
the value of isInitialized
ServiceHandle< ISystematicsSvc > m_systematicsService
the handle for the systematics service
std::string m_affectingFilter
an (optional) filter to remove affecting systematics
Class to wrap a set of SystematicVariations.
static StatusCode filterForAffectingSystematics(const SystematicSet &systConfig, const SystematicSet &affectingSystematics, SystematicSet &filteredSystematics)
description: filter the systematics for the affected systematics returns: success guarantee: strong f...
Select isolated Photons, Electrons and Muons.