ATLAS Offline Software
JetParticleAssociation.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // author: cpollard@cern.ch
6 
7 #ifndef PARTICLEJETTOOLS_JETPARTICLEASSOCIATION_H
8 #define PARTICLEJETTOOLS_JETPARTICLEASSOCIATION_H
9 
10 #include "AsgTools/AsgTool.h"
13 #include "xAODJet/JetContainer.h"
16 
17 #include <vector>
18 #include <string>
19 
20 
22  virtual public IJetDecorator {
24 
25  public:
26 
27  JetParticleAssociation(const std::string& name);
28 
29  virtual StatusCode initialize() override;
30  virtual StatusCode decorate(const xAOD::JetContainer& jets) const override;
31 
32  // obvs to be provided by the deriving class
33  virtual const std::vector<std::vector<ElementLink<xAOD::IParticleContainer> > >*
35 
36  private:
37 
38  // note
39  // if m_particleKey is "", then an empty container will be written to the OutputDecoration.
40  Gaudi::Property<std::string> m_jetContainerName{this, "JetContainer", "", "Jet collection name"};
41  Gaudi::Property<float> m_ptMinimum{this, "MinimumJetPt", 0.0, "minimum pt to consider for association"};
42  SG::ReadHandleKey<xAOD::IParticleContainer> m_particleKey{this, "InputParticleContainer", "", "Input particle collection name"};
43  SG::WriteDecorHandleKey<xAOD::JetContainer> m_decKey{this, "OutputDecoration", "", "Output decoration name"};
44  SG::WriteDecorHandleKey<xAOD::JetContainer> m_passPtKey{this, "PassPtFlag", "", "Name for decoration indicating we passed pt threshold"};
45 };
46 
47 #endif
SG::WriteDecorHandleKey
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
Definition: StoreGate/StoreGate/WriteDecorHandleKey.h:89
asg::AsgTool
Base class for the dual-use tool implementation classes.
Definition: AsgTool.h:47
PropertyWrapper.h
JetParticleAssociation
Definition: JetParticleAssociation.h:22
IJetDecorator
Interface for adding a decoration to a jet container.
Definition: IJetDecorator.h:21
SG::ReadHandleKey
Property holding a SG store/key/clid from which a ReadHandle is made.
Definition: StoreGate/StoreGate/ReadHandleKey.h:39
IJetDecorator.h
JetParticleAssociation::match
virtual const std::vector< std::vector< ElementLink< xAOD::IParticleContainer > > > * match(const xAOD::JetContainer &, const xAOD::IParticleContainer &) const =0
JetParticleAssociation::decorate
virtual StatusCode decorate(const xAOD::JetContainer &jets) const override
Decorate a jet collection without otherwise modifying it.
Definition: JetParticleAssociation.cxx:36
JetParticleAssociation::m_particleKey
SG::ReadHandleKey< xAOD::IParticleContainer > m_particleKey
Definition: JetParticleAssociation.h:42
JetParticleAssociation::m_decKey
SG::WriteDecorHandleKey< xAOD::JetContainer > m_decKey
Definition: JetParticleAssociation.h:43
JetParticleAssociation::m_jetContainerName
Gaudi::Property< std::string > m_jetContainerName
Definition: JetParticleAssociation.h:40
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
IParticleContainer.h
DataVector
Derived DataVector<T>.
Definition: DataVector.h:581
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
JetParticleAssociation::m_passPtKey
SG::WriteDecorHandleKey< xAOD::JetContainer > m_passPtKey
Definition: JetParticleAssociation.h:44
JetParticleAssociation::JetParticleAssociation
JetParticleAssociation(const std::string &name)
Definition: JetParticleAssociation.cxx:11
JetParticleAssociation::m_ptMinimum
Gaudi::Property< float > m_ptMinimum
Definition: JetParticleAssociation.h:41
WriteDecorHandleKey.h
JetContainer.h
ASG_TOOL_CLASS
#define ASG_TOOL_CLASS(CLASSNAME, INT1)
Definition: AsgToolMacros.h:68
defineDB.jets
list jets
Definition: JetTagCalibration/share/defineDB.py:24
AsgTool.h
JetParticleAssociation::initialize
virtual StatusCode initialize() override
Dummy implementation of the initialisation function.
Definition: JetParticleAssociation.cxx:15