ATLAS Offline Software
Loading...
Searching...
No Matches
RunPartonHistoryAlg.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
6
8
10
11namespace CP {
13 ISvcLocator* pSvcLocator)
14 : EL::AnaAlgorithm(name, pSvcLocator) {
15}
16
18 ANA_MSG_INFO("Initializing PartonHistory " << name());
19 ANA_MSG_INFO(" - partonScheme: " << m_PartonScheme);
20
21 // Look up scheme configuration from the registry
22 try {
24 m_PartonHistory = std::make_unique<CalcPartonHistory>(
25 name() + "_CalcPartonHistory", cfg.truthCollections);
26 m_PartonHistory->configure(cfg);
27 } catch (const std::runtime_error& e) {
28 ANA_MSG_ERROR(" ==> PartonScheme " << m_PartonScheme
29 << " is not recognised! aborting.");
30 return StatusCode::FAILURE;
31 }
32 ANA_CHECK(m_PartonHistory->setProperty("prefix", m_PartonScheme));
33 ANA_CHECK(m_PartonHistory->setProperty("symbolFCNC", m_SymbolFCNC));
34 ANA_CHECK(m_PartonHistory->initialize());
35 return StatusCode::SUCCESS;
36}
37
38StatusCode RunPartonHistoryAlg::execute(const EventContext& /*ctx*/) {
39 ANA_CHECK(m_PartonHistory->execute());
40 return StatusCode::SUCCESS;
41}
42
43} // namespace CP
#define ANA_MSG_ERROR(xmsg,...)
Macro printing error messages.
#define ANA_MSG_INFO(xmsg,...)
Macro printing info messages.
#define ANA_CHECK(EXP)
check whether the given expression was successful
virtual StatusCode initialize() override
Gaudi::Property< std::string > m_SymbolFCNC
std::unique_ptr< CalcPartonHistory > m_PartonHistory
Gaudi::Property< std::string > m_PartonScheme
RunPartonHistoryAlg(const std::string &name, ISvcLocator *pSvcLocator)
AnaAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
constructor with parameters
virtual::StatusCode execute()
execute this algorithm
Select isolated Photons, Electrons and Muons.
const PartonSchemeConfig & getSchemeConfig(const std::string &schemeName)
Returns the configuration for a given scheme name.
This module defines the arguments passed from the BATCH driver to the BATCH worker.
Top-level configuration for a named parton history scheme.