|
ATLAS Offline Software
|
Go to the documentation of this file.
29 m_JetMatchingTool_Tool(
""),
30 m_HFClassification_tool(
""),
31 m_HadronOriginClassifier_Tool(
"")
33 declareInterface<DerivationFramework::IAugmentationTool>(
this);
73 return StatusCode::FAILURE;
78 return StatusCode::FAILURE;
83 return StatusCode::FAILURE;
86 return StatusCode::SUCCESS;
90 return StatusCode::SUCCESS;
102 const EventContext& ctx = Gaudi::Hive::currentContext();
106 if (!truthParticlesHandle.
isValid()) {
107 ATH_MSG_ERROR (
"Could not retrieve TruthParticleContainer " << truthParticlesHandle.
key());
108 return StatusCode::FAILURE;
114 if (!jetInputHandle.
isValid()) {
116 return StatusCode::FAILURE;
121 std::map<const xAOD::TruthParticle*, DerivationFramework::HadronOriginClassifier::HF_id> hadronMap =
m_HadronOriginClassifier_Tool->GetOriginMap();
124 std::map<const xAOD::Jet*, std::vector<xAOD::TruthParticleContainer::const_iterator>> particleMatch =
m_JetMatchingTool_Tool->matchHadronsToJets(xTruthParticleContainer,
JetCollection);
135 if (!eventInfoHandle.
isValid()) {
137 return StatusCode::FAILURE;
143 decorator_HFClassification(*
EventInfo) = hfclassif;
146 decorator_SimpleHFClassification(*
EventInfo) = simpleclassif;
148 return StatusCode::SUCCESS;
SG::WriteDecorHandleKey< xAOD::EventInfo > m_SimplehfDecorKey
virtual StatusCode addBranches() const override
Pass the thinning service
~ClassifyAndCalculateHFAugmentation()
const_pointer_type cptr()
Dereference the pointer.
ToolHandle< DerivationFramework::JetMatchingTool > m_JetMatchingTool_Tool
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
virtual StatusCode assign(const std::string &sgkey) override
Change the key of the object to which we're referring.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
ClassifyAndCalculateHFAugmentation(const std::string &t, const std::string &n, const IInterface *p)
ToolHandle< DerivationFramework::ClassifyAndCalculateHFTool > m_HFClassification_tool
ToolHandle< DerivationFramework::HadronOriginClassifier > m_HadronOriginClassifier_Tool
const std::string & key() const
Return the StoreGate ID for the referenced object.
::StatusCode StatusCode
StatusCode definition for legacy code.
SG::ReadHandleKey< xAOD::JetContainer > m_jetCollectionKey
Gaudi::Property< std::string > m_hfDecorationName
Handle class for adding a decoration to an object.
Handle class for adding a decoration to an object.
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
virtual StatusCode finalize() override
This class provides general information about an event. Event information is provided by the accessor...
virtual const std::string & key() const override final
Return the StoreGate ID for the referenced object.
Class describing the basic event information.
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Gaudi::Property< std::string > m_SimplehfDecorationName
Handle class for reading from StoreGate.
SG::ReadHandleKey< xAOD::TruthParticleContainer > m_truthParticlesKey
SG::WriteDecorHandleKey< xAOD::EventInfo > m_hfDecorKey
virtual StatusCode initialize() override