ATLAS Offline Software
Loading...
Searching...
No Matches
InDet::InDetHardScatterSelectionTool Class Reference

Implementation of the hardscatter selection tool. More...

#include <InDetHardScatterSelectionTool.h>

Inheritance diagram for InDet::InDetHardScatterSelectionTool:
Collaboration diagram for InDet::InDetHardScatterSelectionTool:

Classes

class  Sum

Public Types

Running mode(s) for hardscatter determination
enum  Mode { SumPt2 = 0 , SumPt = 1 , SumPtw = 2 , HSGN2 = 3 }

Public Member Functions

virtual void print () const
 Print the state of the tool.
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm.
virtual StatusCode sysStart () override
 Handle START transition.
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles.
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles.
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T, V, H > &t)
void updateVHKA (Gaudi::Details::PropertyBase &)
MsgStream & msg () const
bool msgLvl (const MSG::Level lvl) const
Constructor(s)/destructor(s)
 InDetHardScatterSelectionTool (const std::string &name)
 Constructor.
 ~InDetHardScatterSelectionTool ()
 Destructor.
Function(s) implementing the asg::IAsgTool interface
virtual StatusCode initialize () override
 Function initialising the tool.
virtual StatusCode finalize () override
 Function finalizing the tool.
Function(s) implementing the IInDetHardScatterSelectionTool interface
const xAOD::VertexgetHardScatter (const xAOD::VertexContainer *vtxCont) const override
 Function for returning the hardscatter vertex.
const xAOD::VertexgetHardScatter () const override
ElementLink< xAOD::VertexContainergetHardScatterLink (const xAOD::VertexContainer *vtxCont) const override
 Function for returning the hardscatter vertex link.
ElementLink< xAOD::VertexContainergetHardScatterLink () const override
Additional helper functions, not directly mimicking Athena
template<class T>
const T * getProperty (const std::string &name) const
 Get one of the tool's properties.
const std::string & msg_level_name () const __attribute__((deprecated))
 A deprecated function for getting the message level's name.
const std::string & getName (const void *ptr) const
 Get the name of an object that is / should be in the event store.
SG::sgkey_t getKey (const void *ptr) const
 Get the (hashed) key of an object that is in the event store.

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed.

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t

Private Member Functions

Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey>

Private Attributes

StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default)
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
bool m_varHandleArraysDeclared
Truly private internal data members
std::unique_ptr< Summ_sum
 A helper class which either sums pt2 or pt or ptw.
bool m_doTrkSelection = false
 A flag which will be true if an InDetTrackSelectionTool was provided.
SG::ReadHandleKey< xAOD::EventInfom_evtInfoKey {this, "EventInfo", "EventInfo", "EventInfo key"}
 xAOD::EventInfo ReadHandleKey
SG::ReadHandleKey< xAOD::VertexContainerm_vtxContKey {this, "VertexContainer", "PrimaryVertices", "Name of the primary vertex container"}
SG::ReadHandleKey< xAOD::JetContainerm_jetContKey { this, "JetContainer", "AntiKt4EMTopoJets", "Name of the jet container" }
BooleanProperty m_redoHardScatter { this, "RedoHardScatter", false, "If true, redo the hardscatter selection using sumpt2 or sumpt or sumptw"}
IntegerProperty m_mode { this, "SelectionMode", InDet::InDetHardScatterSelectionTool::Mode::SumPt2, "Mode for selecting the hardscatter: sumpt2[0] or sumpt[1] or sumptw[2]"}
ToolHandle< InDet::IInDetTrackSelectionToolm_trkSelectTool {this, "TrackSelectionTool", "InDet::InDetTrackSelectionTool/TrackSelectionTool", "Track selection tool to use"}
BooleanProperty m_returnDeco { this, "ReturnDeco", false, "If true, return the hardscatter as the vertex decorated with some boolean"}
SG::ReadDecorHandleKey< xAOD::EventInfom_hardScatterDecoKey {this, "HardScatterLinkDeco", m_evtInfoKey, "hardScatterVertexLink", "The decoration name of the ElementLink to the hardscatter vertex (applied to xAOD::EventInfo)"}
FloatProperty m_jetMinPt {this, "jetMinPt", 15000.0, "minimum jet pt"}
FloatProperty m_jetTrkMaxDr {this, "jetTrkMaxDr", 0.8, "max dR between jet & Trk"}
FloatProperty m_trkMaxPt {this, "trkMaxPt", 10045000, "max track pt"}
SG::ReadDecorHandleKey< xAOD::VertexContainerm_gnnScoreKey {this, "GNNKey", m_vtxContKey, "HSGN2_phsvertex", "Name of the hard-scatter GNN decoration"}
 xAOD::EventInfo ReadDecorHandleKey

Detailed Description

Implementation of the hardscatter selection tool.

Definition at line 45 of file InDetHardScatterSelectionTool.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Member Enumeration Documentation

◆ Mode

Constructor & Destructor Documentation

◆ InDetHardScatterSelectionTool()

InDet::InDetHardScatterSelectionTool::InDetHardScatterSelectionTool ( const std::string & name)

Constructor.

Definition at line 45 of file InDetHardScatterSelectionTool.cxx.

45 :
46 asg::AsgTool(name)
47{}

◆ ~InDetHardScatterSelectionTool()

InDet::InDetHardScatterSelectionTool::~InDetHardScatterSelectionTool ( )
default

Destructor.

Member Function Documentation

◆ declareGaudiProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T, V, H > & hndl,
const SG::VarHandleKeyType &  )
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158 {
160 hndl.value(),
161 hndl.documentation());
162
163 }
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)

◆ declareProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T, V, H > & t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145 {
146 typedef typename SG::HandleClassifier<T>::type htype;
148 }
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>

◆ detStore()

const ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

◆ evtStore()

ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase & ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ finalize()

StatusCode InDet::InDetHardScatterSelectionTool::finalize ( )
overridevirtual

Function finalizing the tool.

Definition at line 123 of file InDetHardScatterSelectionTool.cxx.

124{
125 ATH_MSG_DEBUG("Finalizing " << name() << "...");
126
127 // Release our tool
129
130 return StatusCode::SUCCESS;
131}
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_DEBUG(x)
ToolHandle< InDet::IInDetTrackSelectionTool > m_trkSelectTool

◆ getHardScatter() [1/2]

const xAOD::Vertex * InDet::InDetHardScatterSelectionTool::getHardScatter ( ) const
overridevirtual

Implements InDet::IInDetHardScatterSelectionTool.

Definition at line 231 of file InDetHardScatterSelectionTool.cxx.

232{
233 const EventContext& ctx = Gaudi::Hive::currentContext();
234 SG::ReadHandle<xAOD::VertexContainer> vtxCont(m_vtxContKey, ctx);
235 if (!vtxCont.isValid()) {
236 ATH_MSG_ERROR("Could not open primary vertex container, returning nullptr!");
237 return nullptr;
238 }
239 return getHardScatter(vtxCont.get());
240}
#define ATH_MSG_ERROR(x)
const xAOD::Vertex * getHardScatter() const override
SG::ReadHandleKey< xAOD::VertexContainer > m_vtxContKey

◆ getHardScatter() [2/2]

const xAOD::Vertex * InDet::InDetHardScatterSelectionTool::getHardScatter ( const xAOD::VertexContainer * vtxCont) const
overridevirtual

Function for returning the hardscatter vertex.

Implements InDet::IInDetHardScatterSelectionTool.

Definition at line 133 of file InDetHardScatterSelectionTool.cxx.

134{
135 ATH_MSG_DEBUG("In getHardScatter(...) for " << name() << "...");
136
137 const EventContext& ctx = Gaudi::Hive::currentContext();
138
139 // If we are simply returning a decoration on the EventInfo:
140 if (m_returnDeco) {
141 SG::ReadHandle<xAOD::EventInfo> evtInfo(m_evtInfoKey, ctx);
142 if (!evtInfo.isValid()) {
143 ATH_MSG_ERROR("Could not open event info, returning nullptr!");
144 return nullptr;
145 }
146 SG::ReadDecorHandle<xAOD::EventInfo, ElementLink<xAOD::VertexContainer>> hardScatterDeco(m_hardScatterDecoKey, ctx);
147 const ElementLink<xAOD::VertexContainer>& vtxLink = hardScatterDeco(*evtInfo);
148 if (!vtxLink.isValid()) {
149 ATH_MSG_ERROR("Hardscatter vertex link is not valid, returning nullptr!");
150 return nullptr;
151 }
152 return *vtxLink;
153 }
154 //::get the jet container if the mode of HS selection is sumptw
155 const xAOD::JetContainer* jetCont{nullptr};
157 //::First get the jet containers
158 SG::ReadHandle<xAOD::JetContainer> jetContHandle(m_jetContKey, ctx);
159 if (!jetContHandle.isValid()){
160 ATH_MSG_ERROR ("HardScatterSelectionTool configured to use jet collection "<<m_jetContKey.key()<<", but collection is not found!");
161 }
162 jetCont = jetContHandle.cptr();
163 }
164
165 float maxsum = -999.0;
166 float max_gnn_score = -999.0;
167 const xAOD::Vertex* hardscatter = nullptr;
168 for (const auto *const vtx : *vtxCont) {
169 float sum = 0.;
170 // If we are redoing the hardscatter determination:
171 if (m_redoHardScatter) {
173 for (const auto& trkLink : vtx->trackParticleLinks()) {
174 if (!trkLink.isValid()) continue;
175 if (m_doTrkSelection && !static_cast<bool>(m_trkSelectTool->accept(**trkLink, vtx))) continue;
176 if ( (*trkLink)->pt() >m_trkMaxPt) continue;
177 float jetPt=0.0;
178 float minDr=10.0;
179
180 for (const xAOD::Jet* jet : *jetCont) {
181 if (jet->pt() < m_jetMinPt) {continue;} //skip jets below pT threshold
182 float DR = xAOD::P4Helpers::deltaR(*trkLink, jet);
183 if(DR<minDr) {
184 minDr = DR;
185 jetPt = jet->pt();
186 }
187 }
188 if(minDr <= m_jetTrkMaxDr){//check if jet is within dR 1.
189 sum = m_sum->add(sum, (*trkLink)->pt(),jetPt,minDr );
190 }
191 }
192 if (sum > maxsum) {
193 maxsum = sum;
194 hardscatter = vtx;
195 }
196 }
198 SG::ReadDecorHandle<xAOD::VertexContainer, float> acc_gnn(m_gnnScoreKey, ctx);
199 float gnn_score = acc_gnn(*vtx);
200 if (gnn_score > max_gnn_score) {
201 max_gnn_score = gnn_score;
202 hardscatter = vtx;
203 }
204 }
205 //::keeping Matt's (old) method for sumpt & sumpt2
206 else {
207 for (const auto& trkLink : vtx->trackParticleLinks()) {
208 if (trkLink.isValid()) {
209 if (m_doTrkSelection && !static_cast<bool>(m_trkSelectTool->accept(**trkLink, vtx))) continue;
210 sum = m_sum->add(sum, (*trkLink)->pt(),0.,0.);
211 }
212 }
213 if (sum > maxsum) {
214 maxsum = sum;
215 hardscatter = vtx;
216 }
217 }
218 }
219 // Else, return the PV:
220 else {
221 if (vtx->vertexType() == xAOD::VxType::PriVtx) {
222 hardscatter = vtx;
223 break;
224 }
225 }
226 }
227
228 return hardscatter;
229}
SG::ReadHandleKey< xAOD::JetContainer > m_jetContKey
SG::ReadDecorHandleKey< xAOD::VertexContainer > m_gnnScoreKey
xAOD::EventInfo ReadDecorHandleKey
bool m_doTrkSelection
A flag which will be true if an InDetTrackSelectionTool was provided.
SG::ReadHandleKey< xAOD::EventInfo > m_evtInfoKey
xAOD::EventInfo ReadHandleKey
SG::ReadDecorHandleKey< xAOD::EventInfo > m_hardScatterDecoKey
std::unique_ptr< Sum > m_sum
A helper class which either sums pt2 or pt or ptw.
double deltaR(double rapidity1, double phi1, double rapidity2, double phi2)
from bare bare rapidity,phi
@ PriVtx
Primary vertex.
Jet_v1 Jet
Definition of the current "jet version".
Vertex_v1 Vertex
Define the latest version of the vertex class.
JetContainer_v1 JetContainer
Definition of the current "jet container version".

◆ getHardScatterLink() [1/2]

ElementLink< xAOD::VertexContainer > InDet::InDetHardScatterSelectionTool::getHardScatterLink ( ) const
overridevirtual

Implements InDet::IInDetHardScatterSelectionTool.

Definition at line 260 of file InDetHardScatterSelectionTool.cxx.

261{
262 const EventContext& ctx = Gaudi::Hive::currentContext();
263 SG::ReadHandle<xAOD::VertexContainer> vtxCont(m_vtxContKey, ctx);
264 if (!vtxCont.isValid()) {
265 ATH_MSG_ERROR("Could not open primary vertex container, returning empty ElementLink!");
266 return {};
267 }
268 return getHardScatterLink(vtxCont.get());
269}
ElementLink< xAOD::VertexContainer > getHardScatterLink() const override

◆ getHardScatterLink() [2/2]

ElementLink< xAOD::VertexContainer > InDet::InDetHardScatterSelectionTool::getHardScatterLink ( const xAOD::VertexContainer * vtxCont) const
overridevirtual

Function for returning the hardscatter vertex link.

Implements InDet::IInDetHardScatterSelectionTool.

Definition at line 242 of file InDetHardScatterSelectionTool.cxx.

243{
244 ATH_MSG_DEBUG("In getHardScatterLink(...) for " << name() << "...");
245
246 const EventContext& ctx = Gaudi::Hive::currentContext();
247
248 // Get our hardscatter vertex
249 const xAOD::Vertex* hardscatter = getHardScatter(vtxCont);
250
251 // Create our element link
252 ElementLink<xAOD::VertexContainer> hardscatterLink;
253 if (hardscatter) {
254 hardscatterLink.toContainedElement(*vtxCont, hardscatter, ctx);
255 }
256
257 return hardscatterLink;
258}

◆ getKey()

SG::sgkey_t asg::AsgTool::getKey ( const void * ptr) const
inherited

Get the (hashed) key of an object that is in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the SG::sgkey_t key for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getName
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The hashed key of the object in the store. If not found, an invalid (zero) key.

Definition at line 119 of file AsgTool.cxx.

119 {
120
121#ifdef XAOD_STANDALONE
122 // In case we use @c xAOD::TEvent, we have a direct function call
123 // for this.
124 return evtStore()->event()->getKey( ptr );
125#else
126 const SG::DataProxy* proxy = evtStore()->proxy( ptr );
127 return ( proxy == nullptr ? 0 : proxy->sgkey() );
128#endif // XAOD_STANDALONE
129 }
ServiceHandle< StoreGateSvc > & evtStore()

◆ getName()

const std::string & asg::AsgTool::getName ( const void * ptr) const
inherited

Get the name of an object that is / should be in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the std::string name for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getKey
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The string name of the object in the store. If not found, an empty string.

Definition at line 106 of file AsgTool.cxx.

106 {
107
108#ifdef XAOD_STANDALONE
109 // In case we use @c xAOD::TEvent, we have a direct function call
110 // for this.
111 return evtStore()->event()->getName( ptr );
112#else
113 const SG::DataProxy* proxy = evtStore()->proxy( ptr );
114 static const std::string dummy = "";
115 return ( proxy == nullptr ? dummy : proxy->name() );
116#endif // XAOD_STANDALONE
117 }

◆ getProperty()

template<class T>
const T * asg::AsgTool::getProperty ( const std::string & name) const
inherited

Get one of the tool's properties.

◆ initialize()

StatusCode InDet::InDetHardScatterSelectionTool::initialize ( void )
overridevirtual

Function initialising the tool.

Reimplemented from asg::AsgTool.

Definition at line 54 of file InDetHardScatterSelectionTool.cxx.

55{
56 // Print configuration
57 ATH_MSG_DEBUG("Initializing " << name() << "...");
58 ATH_MSG_DEBUG("Using RedoHardScatter: " << m_redoHardScatter);
59 ATH_MSG_DEBUG("Using SelectionMode: " << m_mode);
60 ATH_MSG_DEBUG("Using TrackSelectionTool: " << m_trkSelectTool);
61 ATH_MSG_DEBUG("Using ReturnDeco: " << m_returnDeco);
62 ATH_MSG_DEBUG("Using HardScatterLinkDeco: " << m_hardScatterDecoKey);
63 ATH_MSG_DEBUG("Using VertexContainer: " << m_vtxContKey);
64 ATH_MSG_DEBUG("Using JetContainer: " << m_jetContKey);
65
67 ATH_MSG_ERROR("RedoHardScatter and ReturnDeco cannot both be set to true.");
68 return StatusCode::FAILURE;
69 }
70
71 // If we are re-doing the hardscatter
73 ATH_MSG_DEBUG("Setting the hard scatter strategy to: " << m_mode);
74
75 // Determine how we will sum the track pt
76 switch (m_mode) {
78 m_sum = std::make_unique<::SumPt2>();
79 break;
80 }
82 m_sum = std::make_unique<::SumPt>();
83 break;
84 }
86 m_sum = std::make_unique<::SumPtw>();
87 break;
88 }
90 break;
91 }
92 default: {
93 ATH_MSG_ERROR("Unknown running mode : " << m_mode);
94 return StatusCode::FAILURE;
95 }
96 }
97
98 // Fetch our InDetTrackSelectionTool
99 if (m_redoHardScatter && !m_trkSelectTool.empty()) {
100 m_doTrkSelection = true;
101 ATH_CHECK(m_trkSelectTool.retrieve());
102 }
103
104 }
105
106 // Initialize our EventInfo container and decoration reads
107 ATH_CHECK(m_evtInfoKey.initialize());
109
110 // Initialize our vertex container read
111 ATH_CHECK(m_vtxContKey.initialize());
112
113 // Initialize our jet container read if it is non empty
114 ATH_CHECK(m_jetContKey.initialize(!m_jetContKey.empty()));
115
116 // Initialize the GNN score handle if relevant mode is selected
118
119 return StatusCode::SUCCESS;
120}

◆ inputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ msg()

MsgStream & AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24 {
25 return this->msgStream();
26 }

◆ msg_level_name()

const std::string & asg::AsgTool::msg_level_name ( ) const
inherited

A deprecated function for getting the message level's name.

Instead of using this, weirdly named function, user code should get the string name of the current minimum message level (in case they really need it...), with:

MSG::name( msg().level() )

This function's name doesn't follow the ATLAS coding rules, and as such will be removed in the not too distant future.

Returns
The string name of the current minimum message level that's printed

Definition at line 101 of file AsgTool.cxx.

101 {
102
103 return MSG::name( msg().level() );
104 }
MsgStream & msg() const
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
Definition MsgLevel.cxx:19

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30 {
31 return this->msgLevel(lvl);
32 }

◆ outputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ print()

void asg::AsgTool::print ( ) const
virtualinherited

◆ renounce()

std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T & h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381 {
382 h.renounce();
384 }
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray & handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364 {
366 }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in asg::AsgMetadataTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and DerivationFramework::CfAthAlgTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase & )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308 {
309 // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310 // << " size: " << m_vhka.size() << endmsg;
311 for (auto &a : m_vhka) {
313 for (auto k : keys) {
314 k->setOwner(this);
315 }
316 }
317 }
std::vector< SG::VarHandleKeyArray * > m_vhka

Member Data Documentation

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doTrkSelection

bool InDet::InDetHardScatterSelectionTool::m_doTrkSelection = false
private

A flag which will be true if an InDetTrackSelectionTool was provided.

Definition at line 131 of file InDetHardScatterSelectionTool.h.

◆ m_evtInfoKey

SG::ReadHandleKey<xAOD::EventInfo> InDet::InDetHardScatterSelectionTool::m_evtInfoKey {this, "EventInfo", "EventInfo", "EventInfo key"}
private

xAOD::EventInfo ReadHandleKey

Definition at line 134 of file InDetHardScatterSelectionTool.h.

134{this, "EventInfo", "EventInfo", "EventInfo key"};

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_gnnScoreKey

SG::ReadDecorHandleKey<xAOD::VertexContainer> InDet::InDetHardScatterSelectionTool::m_gnnScoreKey {this, "GNNKey", m_vtxContKey, "HSGN2_phsvertex", "Name of the hard-scatter GNN decoration"}
private

xAOD::EventInfo ReadDecorHandleKey

Definition at line 148 of file InDetHardScatterSelectionTool.h.

148{this, "GNNKey", m_vtxContKey, "HSGN2_phsvertex", "Name of the hard-scatter GNN decoration"};

◆ m_hardScatterDecoKey

SG::ReadDecorHandleKey<xAOD::EventInfo> InDet::InDetHardScatterSelectionTool::m_hardScatterDecoKey {this, "HardScatterLinkDeco", m_evtInfoKey, "hardScatterVertexLink", "The decoration name of the ElementLink to the hardscatter vertex (applied to xAOD::EventInfo)"}
private

Definition at line 142 of file InDetHardScatterSelectionTool.h.

142{this, "HardScatterLinkDeco", m_evtInfoKey, "hardScatterVertexLink", "The decoration name of the ElementLink to the hardscatter vertex (applied to xAOD::EventInfo)"};

◆ m_jetContKey

SG::ReadHandleKey<xAOD::JetContainer> InDet::InDetHardScatterSelectionTool::m_jetContKey { this, "JetContainer", "AntiKt4EMTopoJets", "Name of the jet container" }
private

Definition at line 136 of file InDetHardScatterSelectionTool.h.

136{ this, "JetContainer", "AntiKt4EMTopoJets", "Name of the jet container" };

◆ m_jetMinPt

FloatProperty InDet::InDetHardScatterSelectionTool::m_jetMinPt {this, "jetMinPt", 15000.0, "minimum jet pt"}
private

Definition at line 143 of file InDetHardScatterSelectionTool.h.

143{this, "jetMinPt", 15000.0, "minimum jet pt"};

◆ m_jetTrkMaxDr

FloatProperty InDet::InDetHardScatterSelectionTool::m_jetTrkMaxDr {this, "jetTrkMaxDr", 0.8, "max dR between jet & Trk"}
private

Definition at line 144 of file InDetHardScatterSelectionTool.h.

144{this, "jetTrkMaxDr", 0.8, "max dR between jet & Trk"};

◆ m_mode

IntegerProperty InDet::InDetHardScatterSelectionTool::m_mode { this, "SelectionMode", InDet::InDetHardScatterSelectionTool::Mode::SumPt2, "Mode for selecting the hardscatter: sumpt2[0] or sumpt[1] or sumptw[2]"}
private

Definition at line 139 of file InDetHardScatterSelectionTool.h.

139{ this, "SelectionMode", InDet::InDetHardScatterSelectionTool::Mode::SumPt2, "Mode for selecting the hardscatter: sumpt2[0] or sumpt[1] or sumptw[2]"};

◆ m_redoHardScatter

BooleanProperty InDet::InDetHardScatterSelectionTool::m_redoHardScatter { this, "RedoHardScatter", false, "If true, redo the hardscatter selection using sumpt2 or sumpt or sumptw"}
private

Definition at line 138 of file InDetHardScatterSelectionTool.h.

138{ this, "RedoHardScatter", false, "If true, redo the hardscatter selection using sumpt2 or sumpt or sumptw"};

◆ m_returnDeco

BooleanProperty InDet::InDetHardScatterSelectionTool::m_returnDeco { this, "ReturnDeco", false, "If true, return the hardscatter as the vertex decorated with some boolean"}
private

Definition at line 141 of file InDetHardScatterSelectionTool.h.

141{ this, "ReturnDeco", false, "If true, return the hardscatter as the vertex decorated with some boolean"};

◆ m_sum

std::unique_ptr<Sum> InDet::InDetHardScatterSelectionTool::m_sum
private

A helper class which either sums pt2 or pt or ptw.

Definition at line 128 of file InDetHardScatterSelectionTool.h.

◆ m_trkMaxPt

FloatProperty InDet::InDetHardScatterSelectionTool::m_trkMaxPt {this, "trkMaxPt", 10045000, "max track pt"}
private

Definition at line 145 of file InDetHardScatterSelectionTool.h.

145{this, "trkMaxPt", 10045000, "max track pt"};

◆ m_trkSelectTool

ToolHandle<InDet::IInDetTrackSelectionTool> InDet::InDetHardScatterSelectionTool::m_trkSelectTool {this, "TrackSelectionTool", "InDet::InDetTrackSelectionTool/TrackSelectionTool", "Track selection tool to use"}
private

Definition at line 140 of file InDetHardScatterSelectionTool.h.

140{this, "TrackSelectionTool", "InDet::InDetTrackSelectionTool/TrackSelectionTool", "Track selection tool to use"};

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.

◆ m_vtxContKey

SG::ReadHandleKey<xAOD::VertexContainer> InDet::InDetHardScatterSelectionTool::m_vtxContKey {this, "VertexContainer", "PrimaryVertices", "Name of the primary vertex container"}
private

Definition at line 135 of file InDetHardScatterSelectionTool.h.

135{this, "VertexContainer", "PrimaryVertices", "Name of the primary vertex container"};

The documentation for this class was generated from the following files: