ATLAS Offline Software
Classes | Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
egammaTrkRefitterTool Class Referencefinal

#include <egammaTrkRefitterTool.h>

Inheritance diagram for egammaTrkRefitterTool:
Collaboration diagram for egammaTrkRefitterTool:

Classes

struct  MeasurementsAndTrash
 

Public Types

typedef IegammaTrkRefitterTool::Cache Cache
 

Public Member Functions

 egammaTrkRefitterTool (const std::string &, const std::string &, const IInterface *)
 Constructor with AlgTool parameters. More...
 
virtual ~egammaTrkRefitterTool ()=default
 Destructor. More...
 
virtual StatusCode initialize () override
 AlgTool initialise method. More...
 
virtual StatusCode finalize () override
 AlgTool finalise method. More...
 
virtual StatusCode refitTrack (const EventContext &ctx, const Trk::Track *, Cache &cache) const override final
 Refit a track. More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Static Public Member Functions

static const InterfaceID & interfaceID ()
 Alg tool and IAlgTool interface method. More...
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
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. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

std::vector< const Trk::MeasurementBase * > getIDHits (const Trk::Track *track) const
 Get the hits from the Inner Detector. More...
 
MeasurementsAndTrash addPointsToTrack (const EventContext &ctx, const Trk::Track *track, const xAOD::Electron *eg=nullptr) const
 Adds a beam spot to the Measurements passed to the track refitter. More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

ToolHandle< Trk::ITrackFitterm_ITrackFitter
 The track refitter. More...
 
ToolHandle< ICaloCluster_OnTrackBuilderm_CCOTBuilder { this, "CCOTBuilder", "CaloCluster_OnTrackBuilder", "" }
 
Gaudi::Property< int > m_matEffects
 type of material interaction in extrapolation More...
 
Trk::ParticleHypothesis m_ParticleHypothesis
 Particle Hypothesis. More...
 
const AtlasDetectorIDm_idHelper
 
Gaudi::Property< bool > m_useClusterPosition
 
Gaudi::Property< bool > m_RemoveTRT
 Option to remove TRT hits from track. More...
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Definition at line 35 of file egammaTrkRefitterTool.h.

Member Typedef Documentation

◆ Cache

Definition at line 55 of file egammaTrkRefitterTool.h.

◆ StoreGateSvc_t

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

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ egammaTrkRefitterTool()

egammaTrkRefitterTool::egammaTrkRefitterTool ( const std::string &  type,
const std::string &  name,
const IInterface *  parent 
)

Constructor with AlgTool parameters.

Definition at line 26 of file egammaTrkRefitterTool.cxx.

31  , m_idHelper(nullptr)
32 {
33  declareInterface<IegammaTrkRefitterTool>(this);
34 }

◆ ~egammaTrkRefitterTool()

virtual egammaTrkRefitterTool::~egammaTrkRefitterTool ( )
virtualdefault

Destructor.

Member Function Documentation

◆ addPointsToTrack()

egammaTrkRefitterTool::MeasurementsAndTrash egammaTrkRefitterTool::addPointsToTrack ( const EventContext &  ctx,
const Trk::Track track,
const xAOD::Electron eg = nullptr 
) const
private

Adds a beam spot to the Measurements passed to the track refitter.

Definition at line 135 of file egammaTrkRefitterTool.cxx.

138 {
140  /* The issue here is that some of the returned measurements are owned by
141  * storegate some not. For the ones that are not put them in a vector of
142  * unique_ptr which we will also return to the caller*/
143  if (m_useClusterPosition && eg->caloCluster()) {
144  int charge(0);
145  if (track->perigeeParameters()) {
146  charge = (int)track->perigeeParameters()->charge();
147  }
148  std::unique_ptr<const Trk::CaloCluster_OnTrack> ccot(
149  m_CCOTBuilder->buildClusterOnTrack(ctx, eg->caloCluster(), charge));
150  if (ccot != nullptr) {
151  collect.m_trash.push_back(std::move(ccot));
152  collect.m_measurements.push_back(collect.m_trash.back().get());
153  }
154  }
155  std::vector<const Trk::MeasurementBase*> vecIDHits = getIDHits(track);
156  std::vector<const Trk::MeasurementBase*>::const_iterator it =
157  vecIDHits.begin();
158  std::vector<const Trk::MeasurementBase*>::const_iterator itend =
159  vecIDHits.end();
160  // Fill the track , these are not trash
161  for (; it != itend; ++it) {
162  collect.m_measurements.push_back(*it);
163  }
164  return collect;
165 }

◆ declareGaudiProperty() [1/4]

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

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

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

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

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

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

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

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

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

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

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ 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.

95 { return m_detStore; }

◆ evtStore() [1/2]

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.

85 { return m_evtStore; }

◆ evtStore() [2/2]

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

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

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ 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 egammaTrkRefitterTool::finalize ( )
overridevirtual

AlgTool finalise method.

Definition at line 56 of file egammaTrkRefitterTool.cxx.

57 {
58  return StatusCode::SUCCESS;
59 }

◆ getIDHits()

std::vector< const Trk::MeasurementBase * > egammaTrkRefitterTool::getIDHits ( const Trk::Track track) const
private

Get the hits from the Inner Detector.

Definition at line 168 of file egammaTrkRefitterTool.cxx.

169 {
170 
171  //store measurement to fit in the measurementSet
172  std::vector<const Trk::MeasurementBase*> measurementSet;
173  measurementSet.reserve(track->trackStateOnSurfaces()->size());
174 
175  for (const auto* tsos : *(track->trackStateOnSurfaces())) {
176  if (!tsos) {
178  "This track contains an empty TrackStateOnSurface "
179  "that won't be included in the fit");
180  continue;
181  }
182  if (tsos->type(Trk::TrackStateOnSurface::Measurement) ||
183  tsos->type(Trk::TrackStateOnSurface::Outlier)) {
184 
185  const auto* meas = tsos->measurementOnTrack();
186  if (meas) {
187  const Trk::RIO_OnTrack* rio = nullptr;
188  if (meas->type(Trk::MeasurementBaseType::RIO_OnTrack)) {
189  rio = static_cast<const Trk::RIO_OnTrack*>(meas);
190  }
191  if (rio != nullptr) {
192  const Identifier& surfaceID = (rio->identify());
193  if (m_idHelper->is_sct(surfaceID) ||
194  m_idHelper->is_pixel(surfaceID) ||
195  (!m_RemoveTRT && m_idHelper->is_trt(surfaceID))) {
196  measurementSet.push_back(meas);
197  }
198  }
199  }
200  }
201  }
202  return measurementSet;
203 }

◆ initialize()

StatusCode egammaTrkRefitterTool::initialize ( )
overridevirtual

AlgTool initialise method.

Definition at line 37 of file egammaTrkRefitterTool.cxx.

38 {
39  // Retrieve fitter
40  ATH_CHECK(m_ITrackFitter.retrieve());
41 
42  ATH_CHECK(detStore()->retrieve(m_idHelper, "AtlasID"));
43 
44  // configure calo cluster on track builder (only if used)
46  ATH_CHECK(m_CCOTBuilder.retrieve());
47  } else {
48  m_CCOTBuilder.disable();
49  }
50  // Set the particle hypothesis to match the material effects
52  return StatusCode::SUCCESS;
53 }

◆ 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.

◆ interfaceID()

static const InterfaceID& IegammaTrkRefitterTool::interfaceID ( )
inlinestaticinherited

Alg tool and IAlgTool interface method.

Definition at line 34 of file IegammaTrkRefitterTool.h.

35  { return IID_egammaTrkRefitterTool; };

◆ msg() [1/2]

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

Definition at line 24 of file AthCommonMsg.h.

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

◆ msg() [2/2]

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

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ 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.

◆ refitTrack()

StatusCode egammaTrkRefitterTool::refitTrack ( const EventContext &  ctx,
const Trk::Track track,
Cache cache 
) const
finaloverridevirtual

Refit a track.

Implements IegammaTrkRefitterTool.

Definition at line 62 of file egammaTrkRefitterTool.cxx.

65 {
66  cache.refittedTrack = nullptr;
67  cache.refittedTrackPerigee = nullptr;
68  cache.originalTrack = nullptr;
69  cache.originalTrackPerigee = nullptr;
70  if (!track) {
71  return StatusCode::FAILURE;
72  }
73  // Set the pointer to the track
74  cache.originalTrack = track;
75 
76  // Set pointer to the original perigee
77  cache.originalTrackPerigee = cache.originalTrack->perigeeParameters();
78 
79  if (cache.originalTrackPerigee != nullptr) {
80  double od0 = cache.originalTrackPerigee->parameters()[Trk::d0];
81  double oz0 = cache.originalTrackPerigee->parameters()[Trk::z0];
82  double ophi0 = cache.originalTrackPerigee->parameters()[Trk::phi0];
83  double otheta = cache.originalTrackPerigee->parameters()[Trk::theta];
84  double oqOverP = cache.originalTrackPerigee->parameters()[Trk::qOverP];
85  ATH_MSG_DEBUG("Original parameters " << od0 << " " << oz0 << " " << ophi0
86  << " " << otheta << " " << oqOverP
87  << " " << 1 / oqOverP);
88  } else {
89  ATH_MSG_WARNING("Could not get Trk::Perigee of original track");
90  }
91 
92  // Refit the track with the beam spot if desired otherwise just refit the
93  // original track
96  addPointsToTrack(ctx, cache.originalTrack, cache.electron);
97  if (collect.m_measurements.size() > 4) {
98  cache.refittedTrack =
99  m_ITrackFitter->fit(ctx,
100  collect.m_measurements,
101  *cache.originalTrack->perigeeParameters(),
102  false,
104  } else {
105  cache.refittedTrack = nullptr;
106  }
107  } else {
108  std::vector<const Trk::MeasurementBase*> measurements =
109  getIDHits(cache.originalTrack);
110  if (measurements.size() > 4) {
111  cache.refittedTrack =
112  m_ITrackFitter->fit(ctx,
113  measurements,
114  *cache.originalTrack->perigeeParameters(),
115  false,
117  } else {
118  cache.refittedTrack = nullptr;
119  }
120  }
121 
122  // Store refitted perigee pointers
123  if (cache.refittedTrack) {
124  cache.refittedTrackPerigee = cache.refittedTrack->perigeeParameters();
125  if (cache.refittedTrackPerigee == nullptr) {
126  ATH_MSG_WARNING("Could not get refitted Trk::Perigee");
127  return StatusCode::FAILURE;
128  }
129  return StatusCode::SUCCESS;
130  }
131  return StatusCode::FAILURE;
132 }

◆ 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();
383  PBASE::renounce (h);
384  }

◆ 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  {
365  handlesArray.renounce();
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 DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ 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) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_CCOTBuilder

ToolHandle<ICaloCluster_OnTrackBuilder> egammaTrkRefitterTool::m_CCOTBuilder { this, "CCOTBuilder", "CaloCluster_OnTrackBuilder", "" }
private

Definition at line 92 of file egammaTrkRefitterTool.h.

◆ 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_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_idHelper

const AtlasDetectorID* egammaTrkRefitterTool::m_idHelper
private

Definition at line 105 of file egammaTrkRefitterTool.h.

◆ m_ITrackFitter

ToolHandle<Trk::ITrackFitter> egammaTrkRefitterTool::m_ITrackFitter
private
Initial value:
{
this,
"FitterTool",
"Trk__GaussianSumFitter/GSFTrackFitter",
"ToolHandle for track fitter implementation"
}

The track refitter.

Definition at line 84 of file egammaTrkRefitterTool.h.

◆ m_matEffects

Gaudi::Property<int> egammaTrkRefitterTool::m_matEffects
private
Initial value:
{
this,
"matEffects",
1,
"Type of material interaction in extrapolation (Default Electron)"
}

type of material interaction in extrapolation

Definition at line 95 of file egammaTrkRefitterTool.h.

◆ m_ParticleHypothesis

Trk::ParticleHypothesis egammaTrkRefitterTool::m_ParticleHypothesis
private

Particle Hypothesis.

Definition at line 103 of file egammaTrkRefitterTool.h.

◆ m_RemoveTRT

Gaudi::Property<bool> egammaTrkRefitterTool::m_RemoveTRT
private
Initial value:
{ this,
"RemoveTRTHits",
false,
"RemoveTRT Hits" }

Option to remove TRT hits from track.

Definition at line 115 of file egammaTrkRefitterTool.h.

◆ m_useClusterPosition

Gaudi::Property<bool> egammaTrkRefitterTool::m_useClusterPosition
private
Initial value:
{
this,
"useClusterPosition",
false,
"Switch to control use of Cluster position measurement"
}

Definition at line 107 of file egammaTrkRefitterTool.h.

◆ 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.


The documentation for this class was generated from the following files:
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
AtlasDetectorID::is_pixel
bool is_pixel(Identifier id) const
Definition: AtlasDetectorID.h:760
Trk::ParticleSwitcher::particle
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
Definition: ParticleHypothesis.h:76
egammaTrkRefitterTool::MeasurementsAndTrash
Definition: egammaTrkRefitterTool.h:68
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
ParticleTest.eg
eg
Definition: ParticleTest.py:29
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
AtlasDetectorID::is_sct
bool is_sct(Identifier id) const
Definition: AtlasDetectorID.h:770
egammaTrkRefitterTool::m_CCOTBuilder
ToolHandle< ICaloCluster_OnTrackBuilder > m_CCOTBuilder
Definition: egammaTrkRefitterTool.h:92
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
skel.it
it
Definition: skel.GENtoEVGEN.py:423
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
Trk::z0
@ z0
Definition: ParamDefs.h:70
Trk::RIO_OnTrack
Definition: RIO_OnTrack.h:70
AtlasDetectorID::is_trt
bool is_trt(Identifier id) const
Definition: AtlasDetectorID.h:782
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:95
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
Trk::TrackStateOnSurface::Outlier
@ Outlier
This TSoS contains an outlier, that is, it contains a MeasurementBase/RIO_OnTrack which was not used ...
Definition: TrackStateOnSurface.h:122
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
egammaTrkRefitterTool::m_matEffects
Gaudi::Property< int > m_matEffects
type of material interaction in extrapolation
Definition: egammaTrkRefitterTool.h:95
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
Trk::theta
@ theta
Definition: ParamDefs.h:72
Trk::electron
@ electron
Definition: ParticleHypothesis.h:27
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
egammaTrkRefitterTool::addPointsToTrack
MeasurementsAndTrash addPointsToTrack(const EventContext &ctx, const Trk::Track *track, const xAOD::Electron *eg=nullptr) const
Adds a beam spot to the Measurements passed to the track refitter.
Definition: egammaTrkRefitterTool.cxx:135
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
egammaTrkRefitterTool::m_RemoveTRT
Gaudi::Property< bool > m_RemoveTRT
Option to remove TRT hits from track.
Definition: egammaTrkRefitterTool.h:115
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
Trk::d0
@ d0
Definition: ParamDefs.h:69
egammaTrkRefitterTool::m_idHelper
const AtlasDetectorID * m_idHelper
Definition: egammaTrkRefitterTool.h:105
charge
double charge(const T &p)
Definition: AtlasPID.h:494
Trk::MeasurementBaseType::RIO_OnTrack
@ RIO_OnTrack
Definition: MeasurementBase.h:49
egammaTrkRefitterTool::m_ITrackFitter
ToolHandle< Trk::ITrackFitter > m_ITrackFitter
The track refitter.
Definition: egammaTrkRefitterTool.h:84
a
TList * a
Definition: liststreamerinfos.cxx:10
h
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
Trk::qOverP
@ qOverP
perigee
Definition: ParamDefs.h:73
Trk::RIO_OnTrack::identify
virtual Identifier identify() const final
return the identifier -extends MeasurementBase
Definition: RIO_OnTrack.h:155
Trig::FeatureAccessImpl::collect
void collect(const HLT::TriggerElement *te, std::vector< Trig::Feature< T > > &data, const std::string &label, unsigned int condition, const std::string &teName, const HLT::TrigNavStructure *navstructure)
actual feature acceess implementation It has (thanks to the ClassTraits) functionality to flatten con...
Definition: FeatureCollectAthena.h:299
egammaTrkRefitterTool::m_ParticleHypothesis
Trk::ParticleHypothesis m_ParticleHypothesis
Particle Hypothesis.
Definition: egammaTrkRefitterTool.h:103
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:616
declareProperty
#define declareProperty(n, p, h)
Definition: BaseFakeBkgTool.cxx:15
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:790
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
Trk::phi0
@ phi0
Definition: ParamDefs.h:71
Trk::TrackStateOnSurface::Measurement
@ Measurement
This is a measurement, and will at least contain a Trk::MeasurementBase.
Definition: TrackStateOnSurface.h:101
egammaTrkRefitterTool::getIDHits
std::vector< const Trk::MeasurementBase * > getIDHits(const Trk::Track *track) const
Get the hits from the Inner Detector.
Definition: egammaTrkRefitterTool.cxx:168
fitman.k
k
Definition: fitman.py:528
egammaTrkRefitterTool::m_useClusterPosition
Gaudi::Property< bool > m_useClusterPosition
Definition: egammaTrkRefitterTool.h:107