ATLAS Offline Software
Classes | Public Types | Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
ActsTrk::HGTDTrackExtensionAlg Class Reference

#include <HGTDTrackExtensionAlg.h>

Inheritance diagram for ActsTrk::HGTDTrackExtensionAlg:
Collaboration diagram for ActsTrk::HGTDTrackExtensionAlg:

Classes

struct  TrackExtensionData
 Data structure to hold HGTD track extension results Contains information about hits, timing, and extrapolation for each HGTD layer. More...
 

Public Types

using CKFOptions = Acts::CombinatorialKalmanFilterOptions< detail::RecoTrackContainer >
 

Public Member Functions

virtual ~HGTDTrackExtensionAlg ()=default
 
virtual StatusCode initialize () override
 
virtual StatusCode execute (const EventContext &) const override
 
virtual StatusCode sysInitialize () override
 Override sysInitialize. More...
 
virtual bool isClonable () const override
 Specify if the algorithm is clonable. More...
 
virtual unsigned int cardinality () const override
 Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant. More...
 
virtual StatusCode sysExecute (const EventContext &ctx) override
 Execute an algorithm. More...
 
virtual const DataObjIDColl & extraOutputDeps () const override
 Return the list of extra output dependencies. More...
 
virtual bool filterPassed (const EventContext &ctx) const
 
virtual void setFilterPassed (bool state, const EventContext &ctx) const
 
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 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, V, H > &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
 

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

xAOD::TrackParticleCKFTrackExtension (const Acts::BoundTrackParameters *parameters)
 
const Acts::Logger & logger () const
 Private access to the logger. More...
 
StatusCode collectMeasurements (const EventContext &context, detail::TrackFindingMeasurements &measurements) const
 
TrackExtensionData processTrackExtension (const EventContext &ctx, const xAOD::TrackParticle *trackParticle, const detail::RecoTrackContainer::TrackProxy &trackProxy) const
 
std::pair< float, float > correctTOF (const xAOD::TrackParticle *trackParticle, const xAOD::HGTDCluster *cluster, float measuredTime, float measuredTimeErr, const Acts::TrackingGeometry *trackingGeometry, const Acts::GeometryContext &geoContext) const
 
const xAOD::HGTDClustergetHGTDClusterFromState (const ActsTrk::detail::RecoConstTrackStateContainerProxy &state) const
 
std::size_t getHGTDLayerIndex (const Acts::GeometryIdentifier &geoID) const
 
bool isHGTDSurface (const Acts::GeometryIdentifier &geoID) const
 
bool getExtrapolationPosition (const EventContext &ctx, const detail::RecoTrackContainer::TrackProxy &track, float &x, float &y, float &z) const
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

SG::ReadHandleKey< xAOD::TrackParticleContainerm_trackParticleContainerName {this, "TrackParticleContainerName", "", "Name of the TrackParticle container"}
 
SG::ReadHandleKey< xAOD::HGTDClusterContainerm_HGTDClusterContainerName {this, "HGTDClusterContainerName", "", "the HGTD clusters"}
 
SG::WriteDecorHandleKey< xAOD::TrackParticleContainerm_numHGTDHitsKey {this, "numHGTDHits", m_trackParticleContainerName, "numHGTDHits", "Number of HGTD hits on the track extension"}
 
SG::WriteDecorHandleKey< xAOD::TrackParticleContainerm_layerHasExtensionKey { this, "HGTD_has_extension", m_trackParticleContainerName, "HGTD_has_extension", "Decoration for layer extension" }
 
SG::WriteDecorHandleKey< xAOD::TrackParticleContainerm_layerExtensionChi2Key { this, "HGTD_extension_chi2", m_trackParticleContainerName, "HGTD_extension_chi2", "Decoration for chi2 of extension" }
 
SG::WriteDecorHandleKey< xAOD::TrackParticleContainerm_layerClusterRawTimeKey { this, "HGTD_cluster_raw_time", m_trackParticleContainerName, "HGTD_cluster_raw_time", "Decoration for raw time of cluster" }
 
SG::WriteDecorHandleKey< xAOD::TrackParticleContainerm_layerClusterTimeKey { this, "HGTD_cluster_time", m_trackParticleContainerName, "HGTD_cluster_time", "Decoration for cluster time" }
 
SG::WriteDecorHandleKey< xAOD::TrackParticleContainerm_extrapXKey { this, "HGTD_extrap_x", m_trackParticleContainerName, "HGTD_extrap_x", "Decoration for extrapolated X coordinate" }
 
SG::WriteDecorHandleKey< xAOD::TrackParticleContainerm_extrapYKey { this, "HGTD_extrap_y", m_trackParticleContainerName, "HGTD_extrap_y", "Decoration for extrapolated Y coordinate" }
 
SG::ReadDecorHandleKey< xAOD::TrackParticleContainerm_actsTrackLinkKey {this, "ActsTrackLink", m_trackParticleContainerName, "actsTrack", "Link to Acts track"}
 
Gaudi::Property< float > m_minEtaAcceptance {this, "MinEtaAcceptance", 2.38, "Minimum eta to consider a track for extension"}
 
Gaudi::Property< float > m_maxEtaAcceptance {this, "MaxEtaAcceptance", 4.00, "Maximum eta to consider a track for extension"}
 
ToolHandle< GenericMonitoringToolm_monTool {this, "MonTool", "", "Monitoring tool"}
 
PublicToolHandle< ActsTrk::ITrackingGeometryToolm_trackingGeometryTool {this, "TrackingGeometryTool", ""}
 
ToolHandle< IActsExtrapolationToolm_extrapolationTool {this, "ExtrapolationTool", ""}
 
ToolHandle< ActsTrk::IOnTrackCalibratorTool< detail::RecoTrackStateContainer > > m_pixelCalibTool {this, "PixelCalibrator", "", "Opt. pixel measurement calibrator"}
 
ToolHandle< ActsTrk::IOnTrackCalibratorTool< detail::RecoTrackStateContainer > > m_stripCalibTool {this, "StripCalibrator", "", "Opt. strip measurement calibrator"}
 
ToolHandle< ActsTrk::IOnTrackCalibratorTool< detail::RecoTrackStateContainer > > m_hgtdCalibTool {this, "HGTDCalibrator", "", "Opt. HGTD measurement calibrator"}
 
ToolHandle< ActsTrk::TrackStatePrinterToolm_trackStatePrinter {this, "TrackStatePrinter", "", "optional track state printer"}
 
ActsTrk::detail::xAODUncalibMeasSurfAcc m_surfAcc {}
 
SG::ReadHandleKey< xAOD::UncalibratedMeasurementContainerm_uncalibratedMeasurementContainerKey_HGTD {this, "UncalibratedMeasurementContainerKey_HGTD", "", "input cluster collections for HGTD"}
 
std::unique_ptr< const Acts::Logger > m_logger
 
std::unique_ptr< detail::CKF_configm_trackFinder
 
Acts::CalibrationContext m_calibrationContext
 
DataObjIDColl m_extendedExtraObjects
 Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks. 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 61 of file HGTDTrackExtensionAlg.h.

Member Typedef Documentation

◆ CKFOptions

using ActsTrk::HGTDTrackExtensionAlg::CKFOptions = Acts::CombinatorialKalmanFilterOptions<detail::RecoTrackContainer>

Definition at line 68 of file HGTDTrackExtensionAlg.h.

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ ~HGTDTrackExtensionAlg()

virtual ActsTrk::HGTDTrackExtensionAlg::~HGTDTrackExtensionAlg ( )
virtualdefault

Member Function Documentation

◆ cardinality()

unsigned int AthCommonReentrantAlgorithm< Gaudi::Algorithm >::cardinality
overridevirtualinherited

Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant.

Override this to return 0 for reentrant algorithms.

Override this to return 0 for reentrant algorithms.

Definition at line 75 of file AthCommonReentrantAlgorithm.cxx.

64 {
65  return 0;
66 }

◆ CKFTrackExtension()

xAOD::TrackParticle* ActsTrk::HGTDTrackExtensionAlg::CKFTrackExtension ( const Acts::BoundTrackParameters *  parameters)
private

◆ collectMeasurements()

StatusCode ActsTrk::HGTDTrackExtensionAlg::collectMeasurements ( const EventContext &  context,
detail::TrackFindingMeasurements measurements 
) const
private

Definition at line 348 of file HGTDTrackExtensionAlg.cxx.

349  {
350 
352  ATH_CHECK( HGTDClustersHandle.isValid() );
353  const xAOD::HGTDClusterContainer* HGTDClusters = HGTDClustersHandle.cptr();
354 
355  ATH_MSG_DEBUG("Measurements (HGTD only) size: " << HGTDClustersHandle->size());
356 
357  if (not m_monTool.empty()) {
358  {
359  auto mon_nclusters = Monitored::Scalar("n_hgtd_clusters", HGTDClusters->size());
360  auto mon = Monitored::Group(m_monTool, mon_nclusters);
361  }
362 
363  // Add cluster position to monitoring tool
364  for (const xAOD::HGTDCluster* cluster : *HGTDClustersHandle) {
365  const Acts::Surface* surface = m_surfAcc.get(cluster);
366  if (not surface) continue;
367 
368  Acts::Vector3 globalPos = surface->center(m_trackingGeometryTool->getGeometryContext(context).context());
369 
370  // Get the time from local position (3rd coordinate)
371  auto localPosition = cluster->localPosition<3>(); // Get 3D local position
372  double clusterTime = localPosition[2]; // Time is in the third coordinate
373 
374  ATH_MSG_DEBUG("HGTD Cluster: "<< Amg::toString(globalPos) );
375 
376  auto mon_cluster_x = Monitored::Scalar("cluster_x", globalPos.x());
377  auto mon_cluster_y = Monitored::Scalar("cluster_y", globalPos.y());
378  auto mon_cluster_z = Monitored::Scalar("cluster_z", globalPos.z());
379  auto mon_cluster_t = Monitored::Scalar("cluster_t", clusterTime);
381  mon_cluster_x, mon_cluster_y, mon_cluster_z,
382  mon_cluster_t);
383  }
384  } // MONITORING
385 
386  measurements.addMeasurements(0,
387  *HGTDClusters,
388  *m_trackingGeometryTool->surfaceIdMap());
389 
390  return StatusCode::SUCCESS;
391 }

◆ correctTOF()

std::pair< float, float > ActsTrk::HGTDTrackExtensionAlg::correctTOF ( const xAOD::TrackParticle trackParticle,
const xAOD::HGTDCluster cluster,
float  measuredTime,
float  measuredTimeErr,
const Acts::TrackingGeometry *  trackingGeometry,
const Acts::GeometryContext &  geoContext 
) const
private

Definition at line 733 of file HGTDTrackExtensionAlg.cxx.

739  {
740 
741  ATH_MSG_DEBUG("Correcting input time: " << measuredTime);
742 
743  if (!trackParticle || !cluster) {
744  ATH_MSG_WARNING("Null pointer provided to correctTOF");
745  return {measuredTime, measuredTimeErr}; // Return uncorrected values
746  }
747 
748  // Get the surface for this HGTD cluster
749  const Acts::Surface* surface = nullptr;
750  try {
751  surface = m_surfAcc.get(cluster);
752  } catch (const std::exception& e) {
753  ATH_MSG_WARNING("Exception getting surface: " << e.what());
754  return {measuredTime, measuredTimeErr}; // Return uncorrected values
755  }
756 
757  if (!surface) {
758  ATH_MSG_WARNING("Could not determine surface for HGTD cluster with id "
759  << cluster->identifier());
760  return {measuredTime, measuredTimeErr}; // Return uncorrected values
761  }
762 
763  // Get the global position of the hit
764  Acts::Vector3 globalHitPos;
765  try {
766  // Try to get the cluster's local position
767  auto localPos = cluster->localPosition<3>();
768  // Transform to global coordinates
769  globalHitPos = surface->localToGlobal(
770  geoContext,
771  Acts::Vector2(localPos[0], localPos[1]),
773  } catch (const std::exception& e) {
774  ATH_MSG_WARNING("Failed to transform position: " << e.what());
775  // Fall back to surface center
776  globalHitPos = surface->center(geoContext);
777  }
778 
779  // Get track origin (vertex position)
780  //option 1 - use beamspot
781  //Amg::Vector3D trackOrigin(trackParticle->vx(), trackParticle->vy(), trackParticle->vz());
782 
783  //option 2 - use perigee - this is what is done in legacy code: https://gitlab.cern.ch/atlas/athena/-/blob/main/HighGranularityTimingDetector/HGTD_Reconstruction/HGTD_RecTools/src/StraightLineTOFcorrectionTool.cxx
784  // Get track origin from perigee parameters instead of vertex
785  // In ACTS, this is the d0 and z0 parameter with reference to the beamline
786 
787  // Get the perigee position (the point of closest approach to the beamline)
788  double d0 = trackParticle->d0();
789  double z0 = trackParticle->z0();
790  double phi0 = trackParticle->phi0();
791 
792  Amg::Vector3D trackOrigin(-d0 * std::sin(phi0), d0 * std::cos(phi0), z0);
793  ATH_MSG_DEBUG("Track perigee: d0=" << d0 << ", z0=" << z0 << ", phi0=" << phi0);
794  ATH_MSG_DEBUG("Track origin (perigee): (" << trackOrigin.x() << ", "
795  << trackOrigin.y() << ", " << trackOrigin.z() << ")");
796 
797  // Calculate distance components
798  float dx = globalHitPos.x() - trackOrigin.x();
799  float dy = globalHitPos.y() - trackOrigin.y();
800  float dz = globalHitPos.z() - trackOrigin.z();
801 
802  // Calculate distance and time of flight
803  float distance = std::sqrt(dx*dx + dy*dy + dz*dz);
804  float tof = distance / Gaudi::Units::c_light;
805 
806  // Apply TOF correction
807  float correctedTime = measuredTime - tof;
808 
809  ATH_MSG_DEBUG("Track origin: (" << trackOrigin.x() << ", "
810  << trackOrigin.y() << ", " << trackOrigin.z() << ")");
811  ATH_MSG_DEBUG("Hit position: (" << globalHitPos.x() << ", "
812  << globalHitPos.y() << ", " << globalHitPos.z() << ")");
813  ATH_MSG_DEBUG("Distance = " << distance << " mm, TOF = " << tof
814  << " ns, Corrected time = " << correctedTime);
815 
816  return {correctedTime, measuredTimeErr};
817 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T, V, H > &  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< Gaudi::Algorithm > >::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  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T, V, H > &  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< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T, V, H > &  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< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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; }

◆ execute()

StatusCode ActsTrk::HGTDTrackExtensionAlg::execute ( const EventContext &  ctx) const
overridevirtual

Definition at line 120 of file HGTDTrackExtensionAlg.cxx.

121 {
122  ATH_MSG_DEBUG("Executing " << name() << "...");
123 
124  auto timer = Monitored::Timer<std::chrono::milliseconds>("TIME_execute");
125  auto mon_nTracks = Monitored::Scalar<int>("nTracks");
126  auto mon = Monitored::Group(m_monTool, timer, mon_nTracks);
127 
128  // ================================================== //
129  // ========= RETRIEVE TRACK PARTICLES =============== //
130  // ================================================== //
131 
132  const xAOD::TrackParticleContainer* trackParticles{nullptr};
133  ATH_CHECK(SG::get(trackParticles, m_trackParticleContainerName, ctx));
134 
135  ATH_MSG_DEBUG("Size of trackParticles collection " << trackParticles->size());
136 
137  // Create WriteDecorHandles for all decorations
145 
147  ATH_CHECK( actsTrackLink.isValid() );
148  // ================================================== //
149  // ============ RETRIEVE MEASUREMENTS =============== //
150  // ================================================== //
151 
152  ATH_MSG_DEBUG("Reading input collection with key " << m_uncalibratedMeasurementContainerKey_HGTD.key());
153 
154  const xAOD::UncalibratedMeasurementContainer* uncalibratedMeasurementContainer{nullptr};
155  ATH_CHECK(SG::get(uncalibratedMeasurementContainer ,m_uncalibratedMeasurementContainerKey_HGTD, ctx));
156  ATH_MSG_DEBUG("Retrieved " << uncalibratedMeasurementContainer->size()
157  << " input elements from key " << m_uncalibratedMeasurementContainerKey_HGTD.key());
158 
159  // Modern approach uses surface accessor instead of detector element map
160 
161  ATH_MSG_DEBUG("Investigating HGTD geometry structure");
162 
163  Acts::GeometryContext geoContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
164  Acts::MagneticFieldContext mfContext = m_extrapolationTool->getMagneticFieldContext(ctx);
165 
166 
167  // Get a list of all identifiers associated with HGTD clusters
168  if (msgLvl(MSG::DEBUG)) { // DEBUG
169  const xAOD::HGTDClusterContainer* hgtdInitHandle{nullptr};
170  ATH_CHECK(SG::get(hgtdInitHandle, m_HGTDClusterContainerName, ctx));
171 
172  std::unordered_set<uint32_t> hgtdVolumes {};
173  std::unordered_map<uint32_t, std::unordered_set<uint32_t>> hgtdLayers {}; // volume -> layers
174 
175  for (const xAOD::HGTDCluster* cluster : *hgtdInitHandle) {
176  const Acts::Surface* surface = m_surfAcc.get(cluster);
177 
178  if (surface) {
179  Acts::GeometryIdentifier geoID = surface->geometryId();
180  uint32_t vol = geoID.volume();
181  uint32_t layer = geoID.layer();
182 
183  hgtdVolumes.insert(vol);
184  hgtdLayers[vol].insert(layer);
185 
186  }
187  else {
188  ATH_MSG_ERROR("Failed to retrieve surface for cluster " << cluster->index());
189  return StatusCode::FAILURE;
190  }
191  }
192 
193  ATH_MSG_DEBUG("Found " << hgtdVolumes.size() << " different HGTD volumes");
194  for (std::uint32_t vol : hgtdVolumes) {
195  ATH_MSG_DEBUG("HGTD Volume " << vol << " has " << hgtdLayers[vol].size() << " layers:");
196  for (std::uint32_t lyr : hgtdLayers[vol]) {
197  ATH_MSG_DEBUG(" - Layer " << lyr);
198  }
199  }
200  } // DEBUG
201 
202  detail::TrackFindingMeasurements measurements(1ul); // only one measurement collection: HGTD clusters
203  ATH_CHECK( collectMeasurements(ctx, measurements) );
204 
205  using DefaultTrackStateCreator = Acts::TrackStateCreator<ActsTrk::detail::UncalibSourceLinkAccessor::Iterator,detail::RecoTrackContainer>;
206 
207  ActsTrk::detail::UncalibSourceLinkAccessor slAccessor(measurements.measurementRanges());
208  DefaultTrackStateCreator::SourceLinkAccessor slAccessorDelegate;
209  slAccessorDelegate.connect<&ActsTrk::detail::UncalibSourceLinkAccessor::range>(&slAccessor);
210 
211  // acts_tracking_geometry is already declared in processTrackExtension function
212 
213  ATH_MSG_DEBUG("Create " << uncalibratedMeasurementContainer->size()
214  << " source links from measurements in "
216 
217  if (m_trackStatePrinter.isSet()) {
218  m_trackStatePrinter->printMeasurements(ctx,
219  {uncalibratedMeasurementContainer}, //wrap in a braced initializer list to make a vector
220  measurements.measurementOffsets());
221  }
222 
223  Acts::PropagatorPlainOptions plainOptions(geoContext, mfContext);
224  plainOptions.direction = Acts::Direction::Forward();
225 
227  mfContext,
229  //slAccessorDelegate,
230  m_trackFinder->ckfExtensions,
231  plainOptions);
232 
233  auto calibrator = detail::OnTrackCalibrator<detail::RecoTrackStateContainer>(m_trackingGeometryTool.get(),
237 
238  DefaultTrackStateCreator defaultTrackStateCreator{};
239  defaultTrackStateCreator.sourceLinkAccessor = slAccessorDelegate;
240  defaultTrackStateCreator.calibrator.template connect<&detail::OnTrackCalibrator<detail::RecoTrackStateContainer>::calibrate>(&calibrator);
241 
242  options.extensions.createTrackStates.template connect<
243  &DefaultTrackStateCreator::createTrackStates>(&defaultTrackStateCreator);
244 
245  // ================================================== //
246  // ============ LOOP OVER TRACKPARTICLES ============ //
247  // ================================================== //
248 
249  // Loop over each track particle and decorate it with various information
250  for (const xAOD::TrackParticle* trackParticle : *trackParticles) {
251  // Default to empty track data
252  TrackExtensionData trackData;
253  // Check if the TrackParticle has a link to an ACTS track
254  ElementLink<ActsTrk::TrackContainer> link_to_track = actsTrackLink(*trackParticle);
255  if (!link_to_track.isValid()) {
256  ATH_MSG_ERROR("Invalid ACTS track link for TrackParticle " << trackParticle->index());
257  return StatusCode::FAILURE;
258  }
259 
260  std::optional<ActsTrk::TrackContainer::ConstTrackProxy> optional_track = *link_to_track;
261  if (!optional_track.has_value()) {
262  ATH_MSG_ERROR("No valid ACTS track associated with TrackParticle " << trackParticle->index());
263  return StatusCode::FAILURE;
264  }
265 
266  const ActsTrk::TrackContainer::ConstTrackProxy& track = optional_track.value();
267 
268  Acts::VectorTrackContainer trackBackend;
269  Acts::VectorMultiTrajectory trackStateBackend;
270  detail::RecoTrackContainer tracksContainerTemp(trackBackend, trackStateBackend);
271 
272  // Retrieve quantities for ACTS track
273  float trackEta = Acts::VectorHelpers::eta(track.momentum());
274 
275  // Check eta coverage first
276  if (std::abs(trackEta) < m_minEtaAcceptance or
277  std::abs(trackEta) > m_maxEtaAcceptance) {
278  ATH_MSG_DEBUG("!!!!! ------ Track eta " << trackEta
279  << " outside eta range [" << m_minEtaAcceptance.value() << ", " << m_maxEtaAcceptance.value()
280  << "], skipping extension ------ !!!!!");
281 
282  // set default values
283  layerHasExtensionHandle(*trackParticle) = trackData.hasClusterVec;
284  layerExtensionChi2Handle(*trackParticle) = trackData.chi2Vec;
285  layerClusterRawTimeHandle(*trackParticle) = trackData.rawTimeVec;
286  layerClusterTimeHandle(*trackParticle) = trackData.timeVec;
287  extrapXHandle(*trackParticle) = trackData.extrapX;
288  extrapYHandle(*trackParticle) = trackData.extrapY;
289  numHGTDHitsHandle(*trackParticle) = trackData.numHGTDHits;
290 
291  continue;
292  }
293 
294  float trackpT = track.transverseMomentum();
295  float trackPhi = track.phi();
296  float trackNmeasurements = track.nMeasurements();
297 
298  ATH_MSG_DEBUG("TrackParticle " << trackParticle->index() << " has ACTS track with eta: " << trackEta << ", phi = " << trackPhi << " pT: " << trackpT << " and nMeasurements: " << trackNmeasurements);
299 
300  // Parameters at last measurement state
301  const auto lastMeasurementState = Acts::findLastMeasurementState(track);
302  if (not lastMeasurementState.ok()) {
303  ATH_MSG_ERROR("Problem finding last measurement state for acts track");
304  return StatusCode::FAILURE;
305  }
306  const Acts::BoundTrackParameters lastMeasurementStateParameters = track.createParametersFromState(*lastMeasurementState);
307 
308  // Parameters at reference state of track - not necessarily a measurement state!!!
309  const Acts::Surface& refSurface = track.referenceSurface();
310  const Acts::BoundTrackParameters parametersAtRefSurface(refSurface.getSharedPtr(),
311  track.parameters(),
312  track.covariance(),
313  track.particleHypothesis());
314 
315  ATH_MSG_DEBUG("Initial track parameters for extension - lastMeasurementStateParameters:");
316  ATH_MSG_DEBUG(" - eta: " << -1 * log(tan(lastMeasurementStateParameters.theta() * 0.5)));
317  ATH_MSG_DEBUG(" - phi: " << lastMeasurementStateParameters.phi());
318  ATH_MSG_DEBUG(" - pT: " << std::abs(1./lastMeasurementStateParameters.qOverP() * std::sin(lastMeasurementStateParameters.theta())));
319  ATH_MSG_DEBUG(" - theta: " << lastMeasurementStateParameters.theta());
320  ATH_MSG_DEBUG(" - qOverP: " << lastMeasurementStateParameters.qOverP());
321  ATH_MSG_DEBUG(" - covariance exists: " << (lastMeasurementStateParameters.covariance().has_value() ? "yes" : "no"));
322 
323  // Now use the *last measurement parameters* parameters for the CKF
324  auto result = m_trackFinder->ckf.findTracks(lastMeasurementStateParameters, options,tracksContainerTemp);
325 
326  ATH_MSG_DEBUG("Built " << tracksContainerTemp.size() << " tracks from it");
327 
328  for (const detail::RecoTrackContainer::TrackProxy trackProxy : tracksContainerTemp) {
329  trackData = processTrackExtension(ctx, trackParticle, trackProxy);
330  }
331 
332  // Apply decorations from the track data
333  layerHasExtensionHandle(*trackParticle) = trackData.hasClusterVec;
334  layerExtensionChi2Handle(*trackParticle) = trackData.chi2Vec;
335  layerClusterRawTimeHandle(*trackParticle) = trackData.rawTimeVec;
336  layerClusterTimeHandle(*trackParticle) = trackData.timeVec;
337  extrapXHandle(*trackParticle) = trackData.extrapX;
338  extrapYHandle(*trackParticle) = trackData.extrapY;
339  numHGTDHitsHandle(*trackParticle) = trackData.numHGTDHits;
340  } // loop on tracks
341 
342 
343  return StatusCode::SUCCESS;
344 }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::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

◆ extraOutputDeps()

const DataObjIDColl & AthCommonReentrantAlgorithm< Gaudi::Algorithm >::extraOutputDeps
overridevirtualinherited

Return the list of extra output dependencies.

This list is extended to include symlinks implied by inheritance relations.

Definition at line 94 of file AthCommonReentrantAlgorithm.cxx.

90 {
91  // If we didn't find any symlinks to add, just return the collection
92  // from the base class. Otherwise, return the extended collection.
93  if (!m_extendedExtraObjects.empty()) {
95  }
96  return BaseAlg::extraOutputDeps();
97 }

◆ filterPassed()

virtual bool AthCommonReentrantAlgorithm< Gaudi::Algorithm >::filterPassed ( const EventContext &  ctx) const
inlinevirtualinherited

Definition at line 96 of file AthCommonReentrantAlgorithm.h.

96  {
97  return execState( ctx ).filterPassed();
98  }

◆ getExtrapolationPosition()

bool ActsTrk::HGTDTrackExtensionAlg::getExtrapolationPosition ( const EventContext &  ctx,
const detail::RecoTrackContainer::TrackProxy &  track,
float &  x,
float &  y,
float &  z 
) const
private

Definition at line 648 of file HGTDTrackExtensionAlg.cxx.

651  {
652 
653  // Default values
654  x = 0.0;
655  y = 0.0;
656  z = 0.0;
657 
658  // Get the position at the first HGTD layer
659  bool foundHGTDSurface = false;
660 
661  // Explicitly capture ctx and geoContext in the lambda
662  Acts::GeometryContext geoContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
663  track.container().trackStateContainer().visitBackwards(
664  track.tipIndex(),
665  [this, &foundHGTDSurface, &x, &y, &z, geoContext](const auto& state) {
666  // Skip if already found or no reference surface
667  if (foundHGTDSurface || !state.hasReferenceSurface()) {
668  return;
669  }
670 
671  const auto& surface = state.referenceSurface();
672  Acts::GeometryIdentifier geoID = surface.geometryId();
673 
674  // Check if this is an HGTD surface
675  if (isHGTDSurface(geoID)) {
676  // Instead of getting the surface center, use the predicted parameters
677  if (state.hasPredicted()) {
678  // Get the local predicted parameters
679  const auto& predicted = state.predicted();
680 
681  // Get the local predicted position (first two components of the predicted vector)
682  // Local coordinates: [loc0, loc1, phi, theta, q/p, time]
683  Acts::Vector2 localPos(predicted[Acts::eBoundLoc0], predicted[Acts::eBoundLoc1]);
684 
685  // Transform to global coordinates
686  Acts::Vector3 globalPos = surface.localToGlobal(
687  geoContext,
688  localPos,
689  Acts::Vector3::Zero()); // Direction doesn't matter for position
690 
691  // Store coordinates
692  x = globalPos.x();
693  y = globalPos.y();
694  z = globalPos.z();
695 
696  ATH_MSG_DEBUG("Predicted position on HGTD surface: (" << x << ", " << y << ", " << z << ")");
697  foundHGTDSurface = true;
698  } else {
699  // Fallback to surface center if predicted parameters not available
700  Acts::Vector3 globalPos = surface.center(geoContext);
701  x = globalPos.x();
702  y = globalPos.y();
703  z = globalPos.z();
704 
705  ATH_MSG_DEBUG("Fallback to surface center for HGTD: (" << x << ", " << y << ", " << z << ")");
706  foundHGTDSurface = true;
707  }
708  }
709  });
710 
711  return foundHGTDSurface;
712 }

◆ getHGTDClusterFromState()

const xAOD::HGTDCluster * ActsTrk::HGTDTrackExtensionAlg::getHGTDClusterFromState ( const ActsTrk::detail::RecoConstTrackStateContainerProxy state) const
private

Definition at line 819 of file HGTDTrackExtensionAlg.cxx.

819  {
820  if (state.hasUncalibratedSourceLink()) {
821  auto sl = state.getUncalibratedSourceLink().template get<ATLASUncalibSourceLink>();
822  assert( sl != nullptr);
823  const xAOD::UncalibratedMeasurement &uncalib_cluster = getUncalibratedMeasurement(sl);
824  xAOD::UncalibMeasType clusterType = uncalib_cluster.type();
825 
826  if (clusterType == xAOD::UncalibMeasType::HGTDClusterType) {
827  ATH_MSG_DEBUG("Found HGTD cluster in source link");
828  auto hgtdCluster = static_cast<const xAOD::HGTDCluster *>(&uncalib_cluster);
829  return hgtdCluster;
830  } else {
831  ATH_MSG_DEBUG("Source link contains non-HGTD measurement type: " << static_cast<int>(clusterType));
832  }
833 
834  // If we have a reference surface, try to match by position
835  if (state.hasReferenceSurface()) {
836  const auto& surface = state.referenceSurface();
837  Acts::GeometryIdentifier geoID = surface.geometryId();
838 
839  // Check if this is an HGTD surface
840  if (isHGTDSurface(geoID)) {
841  ATH_MSG_DEBUG("This is an HGTD surface with ID: " << geoID.volume() << ":" << geoID.layer());
842 
843  // Get the current context
844  EventContext ctx = Gaudi::Hive::currentContext();
845 
846  // Modern approach uses surface accessor instead of detector element map
847 
848  // Get the HGTD clusters
850  if (!hgtdClusters.isValid()) {
851  ATH_MSG_WARNING("Failed to retrieve HGTD clusters");
852  return nullptr;
853  }
854 
855  // Get global position of the state surface
856  const Acts::GeometryContext& geoContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
857  Acts::Vector3 statePos = surface.center(geoContext);
858 
859  // Find the closest cluster to this state position
860  const xAOD::HGTDCluster* closestCluster = nullptr;
861  double minDistance = 100.0; // Use a reasonable threshold (in mm)
862 
863  for (const xAOD::HGTDCluster* cluster : *hgtdClusters) {
864  // Get the cluster's surface
865  const Acts::Surface* clusterSurface = m_surfAcc.get(cluster);
866 
867  if (!clusterSurface) continue;
868 
869  // Check if it's on the same surface by comparing geometry IDs
870  Acts::GeometryIdentifier clusterGeoID = clusterSurface->geometryId();
871  if (clusterGeoID.volume() == geoID.volume() && clusterGeoID.layer() == geoID.layer()) {
872  // Get cluster position
873  Acts::Vector3 clusterPos = clusterSurface->center(geoContext);
874 
875  // Calculate 2D distance (x,y only, since z is fixed for a layer)
876  double dx = clusterPos.x() - statePos.x();
877  double dy = clusterPos.y() - statePos.y();
878  double distance = std::sqrt(dx*dx + dy*dy);
879 
880  // Update closest if this is better
881  if (distance < minDistance) {
882  minDistance = distance;
883  closestCluster = cluster;
884  ATH_MSG_DEBUG("Found possible cluster match at distance " << distance << " mm");
885  }
886  }
887  }
888 
889  if (closestCluster) {
890  ATH_MSG_DEBUG("Found closest cluster at distance " << minDistance << " mm");
891  return closestCluster;
892  } else {
893  ATH_MSG_DEBUG("No matching cluster found on this surface");
894  }
895  }
896  }
897  } else {
898  ATH_MSG_DEBUG("State doesn't have uncalibrated source link");
899  }
900 
901  return nullptr;
902 }

◆ getHGTDLayerIndex()

std::size_t ActsTrk::HGTDTrackExtensionAlg::getHGTDLayerIndex ( const Acts::GeometryIdentifier &  geoID) const
private

Definition at line 615 of file HGTDTrackExtensionAlg.cxx.

615  {
616  // Get volume and layer ID
617  std::uint32_t volume = geoID.volume();
618  std::uint32_t layer = geoID.layer();
619 
620  // Check if we're in the positive or negative endcap
621  bool isPositiveEndcap = (volume == 25);
622  bool isNegativeEndcap = (volume == 2);
623 
624  // Different mapping for different sides to maintain consistent physical ordering
625  if (isPositiveEndcap) {
626  // Mapping for positive endcap
627  switch(layer) {
628  case 2: return 0; // First HGTD layer (closest to IP)
629  case 4: return 1; // Second HGTD layer
630  case 6: return 2; // Third HGTD layer
631  case 8: return 3; // Fourth HGTD layer (farthest from IP)
632  default: return 99; // Invalid layer
633  }
634  } else if (isNegativeEndcap) {
635  // Mapping for negative endcap - potentially different ordering
636  switch(layer) {
637  case 2: return 3;
638  case 4: return 2;
639  case 6: return 1;
640  case 8: return 0;
641  default: return 99; // Invalid layer
642  }
643  } else {
644  return 99; // Not an HGTD volume
645  }
646 }

◆ initialize()

StatusCode ActsTrk::HGTDTrackExtensionAlg::initialize ( )
overridevirtual

Definition at line 42 of file HGTDTrackExtensionAlg.cxx.

43 {
44  ATH_MSG_DEBUG("Initializing " << name() << "...");
45 
48 
49  // Initialize all WriteDecorHandleKeys
57 
58  ATH_CHECK(m_actsTrackLinkKey.initialize());
59 
60  // Initialize HGTD-extension related keys
62 
63  // Checks for logger
65  ATH_CHECK(m_extrapolationTool.retrieve());
66 
67  ATH_CHECK(m_monTool.retrieve(EnableTool{not m_monTool.empty()}));
68  ATH_CHECK(m_trackStatePrinter.retrieve(EnableTool{not m_trackStatePrinter.empty()}));
69  ATH_CHECK(m_pixelCalibTool.retrieve(EnableTool{not m_pixelCalibTool.empty()}));
70  ATH_CHECK(m_stripCalibTool.retrieve(EnableTool{not m_stripCalibTool.empty()}));
71  ATH_CHECK(m_hgtdCalibTool.retrieve(EnableTool{not m_hgtdCalibTool.empty()}));
72 
73  //Initialize logger
74  m_logger = makeActsAthenaLogger(this, "Acts");
75 
76  // Initialize surface accessor
78 
79 
80  auto magneticField = std::make_unique<ATLASMagneticFieldWrapper>();
81  std::shared_ptr<const Acts::TrackingGeometry> trackingGeometry = m_trackingGeometryTool->trackingGeometry();
82 
83  detail::Stepper stepper(std::move(magneticField));
84  detail::Navigator::Config cfg{trackingGeometry};
85  cfg.resolvePassive = true;
86  cfg.resolveMaterial = true;
87  cfg.resolveSensitive = true;
88  detail::Navigator navigator(cfg, logger().cloneWithSuffix("Navigator"));
89  detail::Propagator propagator(std::move(stepper), std::move(navigator), logger().cloneWithSuffix("Prop"));
90 
91  // Using the CKF propagator as extrapolator
92  detail::Extrapolator extrapolator = propagator;
93 
94  // Configure track selector for extension
95  Acts::TrackSelector::EtaBinnedConfig trackSelectorCfg(std::vector<double>({0, 4})); //abs value here
96  trackSelectorCfg.cutSets[0].ptMin = 500;
97  trackSelectorCfg.cutSets[0].ptMax = 1000000;
98  trackSelectorCfg.cutSets[0].minMeasurements = 1;
99  trackSelectorCfg.cutSets[0].maxHoles = 4;
100  trackSelectorCfg.cutSets[0].maxOutliers = 4;
101  trackSelectorCfg.cutSets[0].maxHolesAndOutliers = 4;
102  trackSelectorCfg.cutSets[0].maxSharedHits = 4;
103  trackSelectorCfg.cutSets[0].maxChi2 = 10000000.0;
104 
105  ATH_MSG_DEBUG(trackSelectorCfg);
106 
107  detail::CKF_config ckfConfig{
108  std::move(extrapolator),
109  detail::CKF{std::move(propagator), logger().cloneWithSuffix("CKF")},
110  {},
111  Acts::TrackSelector{trackSelectorCfg}};
112 
113  m_trackFinder = std::make_unique<detail::CKF_config>(std::move(ckfConfig));
114 
115  return StatusCode::SUCCESS;
116 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::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.

◆ isClonable()

bool AthCommonReentrantAlgorithm< Gaudi::Algorithm >::isClonable
overridevirtualinherited

Specify if the algorithm is clonable.

Reentrant algorithms are clonable.

Definition at line 68 of file AthCommonReentrantAlgorithm.cxx.

52 {
53  // Reentrant algorithms are clonable.
54  return true;
55 }

◆ isHGTDSurface()

bool ActsTrk::HGTDTrackExtensionAlg::isHGTDSurface ( const Acts::GeometryIdentifier &  geoID) const
private

Definition at line 715 of file HGTDTrackExtensionAlg.cxx.

715  {
716  // Get volume and layer
717  std::uint32_t volume = geoID.volume();
718  std::uint32_t layer = geoID.layer();
719 
720  // Check if it's one of the known HGTD volumes
721  if (volume == 2 || volume == 25) {
722  // Check if it's one of the HGTD layers
723  if (layer == 2 || layer == 4 || layer == 6 || layer == 8) {
724  return true;
725  }
726  }
727 
728  return false;
729 }

◆ logger()

const Acts::Logger& ActsTrk::HGTDTrackExtensionAlg::logger ( ) const
inlineprivate

Private access to the logger.

Definition at line 73 of file HGTDTrackExtensionAlg.h.

73 { return *m_logger; }

◆ msg() [1/2]

MsgStream& AthCommonMsg< Gaudi::Algorithm >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

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

◆ msg() [2/2]

MsgStream& AthCommonMsg< Gaudi::Algorithm >::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< Gaudi::Algorithm >::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< Gaudi::Algorithm > >::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.

◆ processTrackExtension()

HGTDTrackExtensionAlg::TrackExtensionData ActsTrk::HGTDTrackExtensionAlg::processTrackExtension ( const EventContext &  ctx,
const xAOD::TrackParticle trackParticle,
const detail::RecoTrackContainer::TrackProxy &  trackProxy 
) const
private

Definition at line 393 of file HGTDTrackExtensionAlg.cxx.

396  {
397 
398  TrackExtensionData data;
399 
400  // Modern approach uses surface accessor instead of detector element map
401 
402  // Apply track smoothing before trying to access chi2 values
403  Acts::GeometryContext geoContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
404  const Acts::TrackingGeometry* acts_tracking_geometry = m_trackingGeometryTool->trackingGeometry().get();
405 
406 
407  // Count measurements, holes, and HGTD hits specifically
408  std::size_t nMeasurements = 0;
409  std::size_t nHoles = 0;
410  std::size_t nOutliers = 0;
411  std::size_t nHGTDHits = 0;
412 
413  std::vector<bool> hasHitInLayer = {false, false, false, false};
414  std::vector<float> chi2PerLayer = {0.0, 0.0, 0.0, 0.0};
415  std::vector<float> timePerLayer = {0.0, 0.0, 0.0, 0.0};
416  std::vector<float> rawTimePerLayer = {0.0, 0.0, 0.0, 0.0};
417 
418  std::vector<int> truthClassPerLayer = {-1, -1, -1, -1};
419  std::vector<bool> isShadowedPerLayer = {false, false, false, false};
420  std::vector<bool> isMergedPerLayer = {false, false, false, false};
421  std::vector<bool> primaryExpectedPerLayer = {false, false, false, false};
422 
423  // Extrapolated position - get the position at the first HGTD surface encountered
424  float extrapX = 0.0;
425  float extrapY = 0.0;
426  float extrapZ = 0.0;
427  bool foundExtrapolation = false;
428 
429  trackProxy.container().trackStateContainer().visitBackwards(
430  trackProxy.tipIndex(),
431  [&](const auto& state) {
432  auto flags = state.typeFlags();
433  if (flags.test(Acts::TrackStateFlag::HoleFlag)) {
434  nHoles++;
435  } else if (flags.test(Acts::TrackStateFlag::OutlierFlag)) {
436  nOutliers++;
437  } else if (flags.test(Acts::TrackStateFlag::MeasurementFlag)) {
438  nMeasurements++;
439 
440  // Check if this is an HGTD hit
441  if (state.hasReferenceSurface() && flags.test(Acts::TrackStateFlag::MeasurementFlag)) {
442  const auto& surface = state.referenceSurface();
443  Acts::GeometryIdentifier geoID = surface.geometryId();
444 
445  if (isHGTDSurface(geoID)) {
446  std::size_t layerIndex = getHGTDLayerIndex(geoID);
447 
448  const auto& calibrated = state.template calibrated<3>(); //x,y,time
449  const auto& predicted = state.predicted(); //6D
450  const auto& calibCov = state.template calibratedCovariance<3>(); // Full 3D covariance
451 
452 
453 
454  Eigen::Vector2d residual2d;
455  residual2d(0) = calibrated(0) - predicted(Acts::eBoundLoc0);
456  residual2d(1) = calibrated(1) - predicted(Acts::eBoundLoc1);
457 
458  // Extract the top-left 2x2 from the 3x3 measurement covariance
459  AmgSymMatrix(2) cov_2d{calibCov.template block<2,2>(0,0)};
460 
461  // Get the predicted covariance for residual calculation
462  const auto& predictedCov = state.predictedCovariance();
463  AmgSymMatrix(2) predicted_cov_2d{predictedCov.template block<2,2>(0,0)};
464 
465  // Total residual covariance is measurement + predicted covariances
466  AmgSymMatrix(2) residual_cov = cov_2d + predicted_cov_2d;
467 
468 
469 
470  double chi2=0.0;
471  double ndf = 2.0;
472  if (residual_cov.determinant() != 0)
473  {
474  chi2 = residual2d.transpose() * residual_cov.inverse() * residual2d;
475  }
476  else
477  {
478  chi2=-99.9;
479  }
480 
481  if (layerIndex < 4) {
482  nHGTDHits++;
483  hasHitInLayer[layerIndex] = true;
484  chi2PerLayer[layerIndex] =chi2/ndf; //state.chi2();
485 
486  // Get the measured time from the calibrated 3D measurement (local x, y, time)
487 
488  float rawTime = 0.0f;
489  float calibratedTime = 0.0f;
490 
491  if (state.hasCalibrated()) {
492  // Extract time from calibrated data
493  try {
494  const auto& calibrated = state.template calibrated<3>();
495  calibratedTime = static_cast<float>(calibrated(2));
496  ATH_MSG_DEBUG("Got time from calibrated<3>: " << calibratedTime);
497  } catch (const std::exception& e) {
498  ATH_MSG_WARNING("Failed to extract time from calibrated<3>: " << e.what());
499 
500  }
501  }
502 
503  // Extract raw time from HGTD clusters
504  const xAOD::HGTDCluster* cluster = getHGTDClusterFromState(state);
505 
506  if (cluster) {
507  auto localPos = cluster->localPosition<3>();
508  rawTime = static_cast<float>(localPos[2]);
509  ATH_MSG_DEBUG("Got raw time from cluster local position: " << rawTime);
510  } else {
511  ATH_MSG_WARNING("Could not get cluster from state");
512  }
513 
514  // Store the raw time
515  rawTimePerLayer[layerIndex] = rawTime;
516 
517 
518  if (cluster) {
519  auto [correctedTime, timeErr] = correctTOF(
520  trackParticle,
521  cluster,
522  calibratedTime,
523  0.0, // time error set to zero for now!
524  acts_tracking_geometry,
525  geoContext);
526  timePerLayer[layerIndex] = correctedTime;
527  ATH_MSG_DEBUG("Applied TOF correction: " << calibratedTime << " -> " << correctedTime);
528  } else {
529  // No cluster or time, use raw time
530  timePerLayer[layerIndex] = calibratedTime;
531  ATH_MSG_DEBUG("No cluster found for TOF correction, using calibrated time: " << calibratedTime);
532  }
533  }
534  else
535  {
536  ATH_MSG_DEBUG("State does not have calibrated data");
537  }
538 
539  // For extrapolation: use the first HGTD hit's surface position.
540  if (!foundExtrapolation) {
541  foundExtrapolation = true;
542  if (state.hasPredicted()) {
543  // Get the local predicted position
544  const auto& predicted = state.predicted();
545  Acts::Vector2 localPos(predicted[Acts::eBoundLoc0], predicted[Acts::eBoundLoc1]);
546 
547  // Transform to global coordinates
548  Acts::Vector3 globalPos = surface.localToGlobal(
549  geoContext,
550  localPos,
551  Acts::Vector3::Zero());
552 
553  extrapX = globalPos.x();
554  extrapY = globalPos.y();
555  extrapZ = globalPos.z();
556 
557  ATH_MSG_DEBUG("Extrapolated position (predicted) at HGTD: x=" << extrapX
558  << ", y=" << extrapY << ", z=" << extrapZ);
559  } else {
560  // Fallback to surface center
561  Acts::Vector3 globalPos = surface.center(geoContext);
562  extrapX = globalPos.x();
563  extrapY = globalPos.y();
564  extrapZ = globalPos.z();
565 
566  ATH_MSG_DEBUG("Extrapolated position (surface center) at HGTD: x=" << extrapX
567  << ", y=" << extrapY << ", z=" << extrapZ);
568  }
569  }
570 
571  ATH_MSG_DEBUG("Found HGTD hit on layer " << layerIndex
572  << ", chi2=" << chi2PerLayer[layerIndex]
573  << ", time=" << timePerLayer[layerIndex]);
574 
575 
576  }
577  }
578  }
579 
580  });
581 
582  // If we didn't find any HGTD hits but we still have a valid bestTrack,
583  // we should try to predict where the track would intersect HGTD
584  if (nHGTDHits == 0 && !foundExtrapolation) {
585 
586  // Try to calculate the extrapolation position using your existing method
587  if (getExtrapolationPosition(ctx, trackProxy, extrapX, extrapY, extrapZ)) {
588  ATH_MSG_DEBUG("!!! Didn't find any HGTD hits but calculated extrapolation position: x=" << extrapX
589  << ", y=" << extrapY << ", z=" << extrapZ);
590  foundExtrapolation = true;
591  }
592  }
593 
594  ATH_MSG_DEBUG("Track Statistics: "
595  << " nMeasurements=" << nMeasurements
596  << " nHGTDHits=" << nHGTDHits
597  << " nHoles=" << nHoles
598  << " nOutliers=" << nOutliers
599  << " extrapolation found: " << (foundExtrapolation ? "yes" : "no"));
600 
601 
602  // Fill the data structure with results
603  data.hasClusterVec = {hasHitInLayer[0], hasHitInLayer[1], hasHitInLayer[2], hasHitInLayer[3]};
604  data.chi2Vec = {chi2PerLayer[0], chi2PerLayer[1], chi2PerLayer[2], chi2PerLayer[3]};
605  data.timeVec = {timePerLayer[0], timePerLayer[1], timePerLayer[2], timePerLayer[3]};
606  data.rawTimeVec = {rawTimePerLayer[0], rawTimePerLayer[1], rawTimePerLayer[2], rawTimePerLayer[3]};
607  data.extrapX = extrapX;
608  data.extrapY = extrapY;
609  data.extrapZ = extrapZ;
610  data.numHGTDHits = nHGTDHits;
611 
612  return data;
613 }

◆ 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< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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  }

◆ setFilterPassed()

virtual void AthCommonReentrantAlgorithm< Gaudi::Algorithm >::setFilterPassed ( bool  state,
const EventContext &  ctx 
) const
inlinevirtualinherited

Definition at line 100 of file AthCommonReentrantAlgorithm.h.

100  {
101  execState( ctx ).setFilterPassed( state );
102  }

◆ sysExecute()

StatusCode AthCommonReentrantAlgorithm< Gaudi::Algorithm >::sysExecute ( const EventContext &  ctx)
overridevirtualinherited

Execute an algorithm.

We override this in order to work around an issue with the Algorithm base class storing the event context in a member variable that can cause crashes in MT jobs.

Definition at line 85 of file AthCommonReentrantAlgorithm.cxx.

77 {
78  return BaseAlg::sysExecute (ctx);
79 }

◆ sysInitialize()

StatusCode AthCommonReentrantAlgorithm< Gaudi::Algorithm >::sysInitialize
overridevirtualinherited

Override sysInitialize.

Override sysInitialize from the base class.

Loop through all output handles, and if they're WriteCondHandles, automatically register them and this Algorithm with the CondSvc

Scan through all outputHandles, and if they're WriteCondHandles, register them with the CondSvc

Reimplemented from AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >.

Reimplemented in InputMakerBase, and HypoBase.

Definition at line 61 of file AthCommonReentrantAlgorithm.cxx.

107  {
109 
110  if (sc.isFailure()) {
111  return sc;
112  }
113 
114  ServiceHandle<ICondSvc> cs("CondSvc",name());
115  for (auto h : outputHandles()) {
116  if (h->isCondition() && h->mode() == Gaudi::DataHandle::Writer) {
117  // do this inside the loop so we don't create the CondSvc until needed
118  if ( cs.retrieve().isFailure() ) {
119  ATH_MSG_WARNING("no CondSvc found: won't autoreg WriteCondHandles");
120  return StatusCode::SUCCESS;
121  }
122  if (cs->regHandle(this,*h).isFailure()) {
123  sc = StatusCode::FAILURE;
124  ATH_MSG_ERROR("unable to register WriteCondHandle " << h->fullKey()
125  << " with CondSvc");
126  }
127  }
128  }
129  return sc;
130 }

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::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< Gaudi::Algorithm > >::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_actsTrackLinkKey

SG::ReadDecorHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_actsTrackLinkKey {this, "ActsTrackLink", m_trackParticleContainerName, "actsTrack", "Link to Acts track"}
private

Definition at line 90 of file HGTDTrackExtensionAlg.h.

◆ m_calibrationContext

Acts::CalibrationContext ActsTrk::HGTDTrackExtensionAlg::m_calibrationContext
private

Definition at line 156 of file HGTDTrackExtensionAlg.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extendedExtraObjects

DataObjIDColl AthCommonReentrantAlgorithm< Gaudi::Algorithm >::m_extendedExtraObjects
privateinherited

Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.

Empty if no symlinks were found.

Definition at line 114 of file AthCommonReentrantAlgorithm.h.

◆ m_extrapolationTool

ToolHandle<IActsExtrapolationTool> ActsTrk::HGTDTrackExtensionAlg::m_extrapolationTool {this, "ExtrapolationTool", ""}
private

Definition at line 102 of file HGTDTrackExtensionAlg.h.

◆ m_extrapXKey

SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_extrapXKey { this, "HGTD_extrap_x", m_trackParticleContainerName, "HGTD_extrap_x", "Decoration for extrapolated X coordinate" }
private

Definition at line 86 of file HGTDTrackExtensionAlg.h.

◆ m_extrapYKey

SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_extrapYKey { this, "HGTD_extrap_y", m_trackParticleContainerName, "HGTD_extrap_y", "Decoration for extrapolated Y coordinate" }
private

Definition at line 87 of file HGTDTrackExtensionAlg.h.

◆ m_hgtdCalibTool

ToolHandle<ActsTrk::IOnTrackCalibratorTool<detail::RecoTrackStateContainer> > ActsTrk::HGTDTrackExtensionAlg::m_hgtdCalibTool {this, "HGTDCalibrator", "", "Opt. HGTD measurement calibrator"}
private

Definition at line 109 of file HGTDTrackExtensionAlg.h.

◆ m_HGTDClusterContainerName

SG::ReadHandleKey<xAOD::HGTDClusterContainer> ActsTrk::HGTDTrackExtensionAlg::m_HGTDClusterContainerName {this, "HGTDClusterContainerName", "", "the HGTD clusters"}
private

Definition at line 77 of file HGTDTrackExtensionAlg.h.

◆ m_layerClusterRawTimeKey

SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_layerClusterRawTimeKey { this, "HGTD_cluster_raw_time", m_trackParticleContainerName, "HGTD_cluster_raw_time", "Decoration for raw time of cluster" }
private

Definition at line 84 of file HGTDTrackExtensionAlg.h.

◆ m_layerClusterTimeKey

SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_layerClusterTimeKey { this, "HGTD_cluster_time", m_trackParticleContainerName, "HGTD_cluster_time", "Decoration for cluster time" }
private

Definition at line 85 of file HGTDTrackExtensionAlg.h.

◆ m_layerExtensionChi2Key

SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_layerExtensionChi2Key { this, "HGTD_extension_chi2", m_trackParticleContainerName, "HGTD_extension_chi2", "Decoration for chi2 of extension" }
private

Definition at line 83 of file HGTDTrackExtensionAlg.h.

◆ m_layerHasExtensionKey

SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_layerHasExtensionKey { this, "HGTD_has_extension", m_trackParticleContainerName, "HGTD_has_extension", "Decoration for layer extension" }
private

Definition at line 82 of file HGTDTrackExtensionAlg.h.

◆ m_logger

std::unique_ptr<const Acts::Logger> ActsTrk::HGTDTrackExtensionAlg::m_logger
private

Definition at line 121 of file HGTDTrackExtensionAlg.h.

◆ m_maxEtaAcceptance

Gaudi::Property<float> ActsTrk::HGTDTrackExtensionAlg::m_maxEtaAcceptance {this, "MaxEtaAcceptance", 4.00, "Maximum eta to consider a track for extension"}
private

Definition at line 94 of file HGTDTrackExtensionAlg.h.

◆ m_minEtaAcceptance

Gaudi::Property<float> ActsTrk::HGTDTrackExtensionAlg::m_minEtaAcceptance {this, "MinEtaAcceptance", 2.38, "Minimum eta to consider a track for extension"}
private

Definition at line 93 of file HGTDTrackExtensionAlg.h.

◆ m_monTool

ToolHandle<GenericMonitoringTool> ActsTrk::HGTDTrackExtensionAlg::m_monTool {this, "MonTool", "", "Monitoring tool"}
private

Definition at line 98 of file HGTDTrackExtensionAlg.h.

◆ m_numHGTDHitsKey

SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_numHGTDHitsKey {this, "numHGTDHits", m_trackParticleContainerName, "numHGTDHits", "Number of HGTD hits on the track extension"}
private

Definition at line 80 of file HGTDTrackExtensionAlg.h.

◆ m_pixelCalibTool

ToolHandle<ActsTrk::IOnTrackCalibratorTool<detail::RecoTrackStateContainer> > ActsTrk::HGTDTrackExtensionAlg::m_pixelCalibTool {this, "PixelCalibrator", "", "Opt. pixel measurement calibrator"}
private

Definition at line 105 of file HGTDTrackExtensionAlg.h.

◆ m_stripCalibTool

ToolHandle<ActsTrk::IOnTrackCalibratorTool<detail::RecoTrackStateContainer> > ActsTrk::HGTDTrackExtensionAlg::m_stripCalibTool {this, "StripCalibrator", "", "Opt. strip measurement calibrator"}
private

Definition at line 107 of file HGTDTrackExtensionAlg.h.

◆ m_surfAcc

ActsTrk::detail::xAODUncalibMeasSurfAcc ActsTrk::HGTDTrackExtensionAlg::m_surfAcc {}
private

Definition at line 114 of file HGTDTrackExtensionAlg.h.

◆ m_trackFinder

std::unique_ptr<detail::CKF_config> ActsTrk::HGTDTrackExtensionAlg::m_trackFinder
private

Definition at line 123 of file HGTDTrackExtensionAlg.h.

◆ m_trackingGeometryTool

PublicToolHandle<ActsTrk::ITrackingGeometryTool> ActsTrk::HGTDTrackExtensionAlg::m_trackingGeometryTool {this, "TrackingGeometryTool", ""}
private

Definition at line 100 of file HGTDTrackExtensionAlg.h.

◆ m_trackParticleContainerName

SG::ReadHandleKey<xAOD::TrackParticleContainer> ActsTrk::HGTDTrackExtensionAlg::m_trackParticleContainerName {this, "TrackParticleContainerName", "", "Name of the TrackParticle container"}
private

Definition at line 76 of file HGTDTrackExtensionAlg.h.

◆ m_trackStatePrinter

ToolHandle<ActsTrk::TrackStatePrinterTool> ActsTrk::HGTDTrackExtensionAlg::m_trackStatePrinter {this, "TrackStatePrinter", "", "optional track state printer"}
private

Definition at line 112 of file HGTDTrackExtensionAlg.h.

◆ m_uncalibratedMeasurementContainerKey_HGTD

SG::ReadHandleKey<xAOD::UncalibratedMeasurementContainer> ActsTrk::HGTDTrackExtensionAlg::m_uncalibratedMeasurementContainerKey_HGTD {this, "UncalibratedMeasurementContainerKey_HGTD", "", "input cluster collections for HGTD"}
private

Definition at line 117 of file HGTDTrackExtensionAlg.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

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

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files:
xAOD::UncalibratedMeasurement_v1::identifier
DetectorIdentType identifier() const
Returns the full Identifier of the measurement.
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
ActsTrk::detail::xAODUncalibMeasSurfAcc::get
const Acts::Surface * get(const xAOD::UncalibratedMeasurement *meas) const
Operator.
Definition: xAODUncalibMeasSurfAcc.cxx:19
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
ActsTrk::HGTDTrackExtensionAlg::m_trackStatePrinter
ToolHandle< ActsTrk::TrackStatePrinterTool > m_trackStatePrinter
Definition: HGTDTrackExtensionAlg.h:112
xAOD::UncalibMeasType::HGTDClusterType
@ HGTDClusterType
TrigDefs::Group
Group
Properties of a chain group.
Definition: GroupProperties.h:13
get_generator_info.result
result
Definition: get_generator_info.py:21
SG::ReadHandle::cptr
const_pointer_type cptr()
Dereference the pointer.
ActsTrk::HGTDTrackExtensionAlg::m_trackFinder
std::unique_ptr< detail::CKF_config > m_trackFinder
Definition: HGTDTrackExtensionAlg.h:123
ActsTrk::HGTDTrackExtensionAlg::m_layerClusterRawTimeKey
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_layerClusterRawTimeKey
Definition: HGTDTrackExtensionAlg.h:84
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
eta
Scalar eta() const
pseudorapidity method
Definition: AmgMatrixBasePlugin.h:83
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:67
ActsTrk::detail::Navigator
Acts::Navigator Navigator
Definition: Tracking/Acts/ActsTrackReconstruction/src/detail/Definitions.h:31
AthenaPoolTestRead.flags
flags
Definition: AthenaPoolTestRead.py:8
InDetAccessor::phi0
@ phi0
Definition: InDetAccessor.h:33
ActsTrk::detail::Extrapolator
Propagator Extrapolator
Definition: Tracking/Acts/ActsTrackReconstruction/src/detail/Definitions.h:34
fillPileUpNoiseLumi.connect
string connect
Definition: fillPileUpNoiseLumi.py:70
AthCommonDataStore::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 > renounce(T &h)
Definition: AthCommonDataStore.h:380
xAOD::TrackParticle_v1::z0
float z0() const
Returns the parameter.
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
ActsTrk::HGTDTrackExtensionAlg::m_pixelCalibTool
ToolHandle< ActsTrk::IOnTrackCalibratorTool< detail::RecoTrackStateContainer > > m_pixelCalibTool
Definition: HGTDTrackExtensionAlg.h:105
AthCommonMsg< Gaudi::Algorithm >::msgLvl
bool msgLvl(const MSG::Level lvl) const
Definition: AthCommonMsg.h:30
ActsTrk::HGTDTrackExtensionAlg::m_layerHasExtensionKey
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_layerHasExtensionKey
Definition: HGTDTrackExtensionAlg.h:82
xAOD::HGTDCluster_v1
Definition: HGTDCluster_v1.h:23
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
ActsTrk::detail::RecoTrackContainer
Acts::TrackContainer< Acts::VectorTrackContainer, Acts::VectorMultiTrajectory > RecoTrackContainer
Definition: Tracking/Acts/ActsTrackReconstruction/src/detail/Definitions.h:22
x
#define x
xAOD::TrackParticle_v1::d0
float d0() const
Returns the parameter.
python.utils.AtlRunQueryTimer.timer
def timer(name, disabled=False)
Definition: AtlRunQueryTimer.py:85
ActsTrk::HGTDTrackExtensionAlg::m_minEtaAcceptance
Gaudi::Property< float > m_minEtaAcceptance
Definition: HGTDTrackExtensionAlg.h:93
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
ActsTrk::HGTDTrackExtensionAlg::m_hgtdCalibTool
ToolHandle< ActsTrk::IOnTrackCalibratorTool< detail::RecoTrackStateContainer > > m_hgtdCalibTool
Definition: HGTDTrackExtensionAlg.h:109
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
ActsTrk::HGTDTrackExtensionAlg::m_extrapolationTool
ToolHandle< IActsExtrapolationTool > m_extrapolationTool
Definition: HGTDTrackExtensionAlg.h:102
SG::makeHandle
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
Definition: ReadCondHandle.h:274
makeActsAthenaLogger
std::unique_ptr< const Acts::Logger > makeActsAthenaLogger(IMessageSvc *svc, const std::string &name, int level, std::optional< std::string > parent_name)
Definition: Tracking/Acts/ActsInterop/src/Logger.cxx:64
ActsTrk::HGTDTrackExtensionAlg::getExtrapolationPosition
bool getExtrapolationPosition(const EventContext &ctx, const detail::RecoTrackContainer::TrackProxy &track, float &x, float &y, float &z) const
Definition: HGTDTrackExtensionAlg.cxx:648
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
AthCommonReentrantAlgorithm::extraOutputDeps
virtual const DataObjIDColl & extraOutputDeps() const override
Return the list of extra output dependencies.
Definition: AthCommonReentrantAlgorithm.cxx:89
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:209
xAOD::UncalibratedMeasurement_v1
Definition: UncalibratedMeasurement_v1.h:13
ActsTrk::HGTDTrackExtensionAlg::m_actsTrackLinkKey
SG::ReadDecorHandleKey< xAOD::TrackParticleContainer > m_actsTrackLinkKey
Definition: HGTDTrackExtensionAlg.h:90
AthCommonDataStore
Definition: AthCommonDataStore.h:52
Amg::toString
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
Definition: GeoPrimitivesToStringConverter.h:40
ActsTrk::HGTDTrackExtensionAlg::m_extrapXKey
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_extrapXKey
Definition: HGTDTrackExtensionAlg.h:86
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
SG::ReadDecorHandle
Handle class for reading a decoration on an object.
Definition: StoreGate/StoreGate/ReadDecorHandle.h:94
ActsTrk::detail::GenUncalibSourceLinkAccessor
Accessor for the above source link container.
Definition: AtlasUncalibSourceLinkAccessor.h:113
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::outputHandles
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
ActsTrk::HGTDTrackExtensionAlg::m_logger
std::unique_ptr< const Acts::Logger > m_logger
Definition: HGTDTrackExtensionAlg.h:121
xAOD::UncalibratedMeasurement_v1::type
virtual xAOD::UncalibMeasType type() const =0
Returns the type of the measurement type as a simple enumeration.
z
#define z
SG::get
const T * get(const ReadCondHandleKey< T > &key, const EventContext &ctx)
Convenience function to retrieve an object given a ReadCondHandleKey.
Definition: ReadCondHandle.h:287
ActsTrk::detail::GenUncalibSourceLinkAccessor::range
std::pair< Iterator, Iterator > range(const Acts::Surface &surface) const
Definition: AtlasUncalibSourceLinkAccessor.h:169
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
Definition: AthCommonDataStore.h:145
TRT::Hit::layer
@ layer
Definition: HitInfo.h:79
SG::WriteDecorHandle
Handle class for adding a decoration to an object.
Definition: StoreGate/StoreGate/WriteDecorHandle.h:100
ActsTrk::HGTDTrackExtensionAlg::m_trackParticleContainerName
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_trackParticleContainerName
Definition: HGTDTrackExtensionAlg.h:76
AthCommonReentrantAlgorithm::sysExecute
virtual StatusCode sysExecute(const EventContext &ctx) override
Execute an algorithm.
Definition: AthCommonReentrantAlgorithm.cxx:76
ActsTrk::HGTDTrackExtensionAlg::m_HGTDClusterContainerName
SG::ReadHandleKey< xAOD::HGTDClusterContainer > m_HGTDClusterContainerName
Definition: HGTDTrackExtensionAlg.h:77
calibdata.exception
exception
Definition: calibdata.py:495
TRT::Track::d0
@ d0
Definition: InnerDetector/InDetCalibEvent/TRT_CalibData/TRT_CalibData/TrackInfo.h:62
ActsTrk::HGTDTrackExtensionAlg::m_layerExtensionChi2Key
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_layerExtensionChi2Key
Definition: HGTDTrackExtensionAlg.h:83
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
python.AtlRunQueryLib.options
options
Definition: AtlRunQueryLib.py:378
drawFromPickle.tan
tan
Definition: drawFromPickle.py:36
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
detail::ul
unsigned long ul
Definition: PrimitiveHelpers.h:46
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
TRT::Track::z0
@ z0
Definition: InnerDetector/InDetCalibEvent/TRT_CalibData/TRT_CalibData/TrackInfo.h:63
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
ActsTrk::HGTDTrackExtensionAlg::m_maxEtaAcceptance
Gaudi::Property< float > m_maxEtaAcceptance
Definition: HGTDTrackExtensionAlg.h:94
xAOD::UncalibratedMeasurement_v1::localPosition
ConstVectorMap< N > localPosition() const
Returns the local position of the measurement.
SG::ReadHandle::isValid
virtual bool isValid() override final
Can the handle be successfully dereferenced?
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
ActsTrk::HGTDTrackExtensionAlg::collectMeasurements
StatusCode collectMeasurements(const EventContext &context, detail::TrackFindingMeasurements &measurements) const
Definition: HGTDTrackExtensionAlg.cxx:348
xAOD::TrackParticle_v1::phi0
float phi0() const
Returns the parameter, which has range to .
Definition: TrackParticle_v1.cxx:159
ActsTrk::HGTDTrackExtensionAlg::CKFOptions
Acts::CombinatorialKalmanFilterOptions< detail::RecoTrackContainer > CKFOptions
Definition: HGTDTrackExtensionAlg.h:68
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
ActsTrk::getUncalibratedMeasurement
const xAOD::UncalibratedMeasurement & getUncalibratedMeasurement(const ATLASUncalibSourceLink &source_link)
Definition: ATLASSourceLink.h:26
ActsTrk::HGTDTrackExtensionAlg::m_trackingGeometryTool
PublicToolHandle< ActsTrk::ITrackingGeometryTool > m_trackingGeometryTool
Definition: HGTDTrackExtensionAlg.h:100
WriteCaloSwCorrections.cfg
cfg
Definition: WriteCaloSwCorrections.py:23
python.PhysicalConstants.c_light
float c_light
Definition: PhysicalConstants.py:73
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
ActsTrk::detail::Stepper
Acts::SympyStepper Stepper
Adapted from Acts Examples/Algorithms/TrackFinding/src/TrackFindingAlgorithmFunction....
Definition: Tracking/Acts/ActsTrackReconstruction/src/detail/Definitions.h:30
ActsTrk::HGTDTrackExtensionAlg::processTrackExtension
TrackExtensionData processTrackExtension(const EventContext &ctx, const xAOD::TrackParticle *trackParticle, const detail::RecoTrackContainer::TrackProxy &trackProxy) const
Definition: HGTDTrackExtensionAlg.cxx:393
ActsTrk::HGTDTrackExtensionAlg::logger
const Acts::Logger & logger() const
Private access to the logger.
Definition: HGTDTrackExtensionAlg.h:73
makeTRTBarrelCans.dy
tuple dy
Definition: makeTRTBarrelCans.py:21
ActsTrk::HGTDTrackExtensionAlg::m_surfAcc
ActsTrk::detail::xAODUncalibMeasSurfAcc m_surfAcc
Definition: HGTDTrackExtensionAlg.h:114
ActsTrk::HGTDTrackExtensionAlg::m_monTool
ToolHandle< GenericMonitoringTool > m_monTool
Definition: HGTDTrackExtensionAlg.h:98
a
TList * a
Definition: liststreamerinfos.cxx:10
ActsTrk::HGTDTrackExtensionAlg::m_layerClusterTimeKey
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_layerClusterTimeKey
Definition: HGTDTrackExtensionAlg.h:85
ActsTrk::detail::Propagator
Acts::Propagator< Stepper, Navigator > Propagator
Definition: Tracking/Acts/ActsTrackReconstruction/src/detail/Definitions.h:32
y
#define y
SG::WriteDecorHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
h
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
ActsTrk::HGTDTrackExtensionAlg::m_uncalibratedMeasurementContainerKey_HGTD
SG::ReadHandleKey< xAOD::UncalibratedMeasurementContainer > m_uncalibratedMeasurementContainerKey_HGTD
Definition: HGTDTrackExtensionAlg.h:117
DEBUG
#define DEBUG
Definition: page_access.h:11
ActsTrk::HGTDTrackExtensionAlg::isHGTDSurface
bool isHGTDSurface(const Acts::GeometryIdentifier &geoID) const
Definition: HGTDTrackExtensionAlg.cxx:715
plotBeamSpotMon.mon
mon
Definition: plotBeamSpotMon.py:66
makeTRTBarrelCans.dx
tuple dx
Definition: makeTRTBarrelCans.py:20
xAOD::UncalibMeasType
UncalibMeasType
Define the type of the uncalibrated measurement.
Definition: MeasurementDefs.h:25
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
if
if(febId1==febId2)
Definition: LArRodBlockPhysicsV0.cxx:567
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:629
AthCommonReentrantAlgorithm< Gaudi::Algorithm >::sysInitialize
virtual StatusCode sysInitialize() override
Override sysInitialize.
Definition: AthCommonReentrantAlgorithm.cxx:107
ActsTrk::HGTDTrackExtensionAlg::m_calibrationContext
Acts::CalibrationContext m_calibrationContext
Definition: HGTDTrackExtensionAlg.h:156
TauGNNUtils::Variables::Track::trackPhi
bool trackPhi(const xAOD::TauJet &, const xAOD::TauTrack &track, double &out)
Definition: TauGNNUtils.cxx:493
ActsTrk::HGTDTrackExtensionAlg::m_extrapYKey
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_extrapYKey
Definition: HGTDTrackExtensionAlg.h:87
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:801
ActsTrk::detail::CKF
Acts::CombinatorialKalmanFilter< Propagator, RecoTrackContainer > CKF
Definition: Tracking/Acts/ActsTrackReconstruction/src/detail/Definitions.h:33
ActsTrk::detail::xAODUncalibMeasSurfAcc
Helper class to access the Acts::surface associated with an Uncalibrated xAOD measurement.
Definition: xAODUncalibMeasSurfAcc.h:22
xAOD::track
@ track
Definition: TrackingPrimitives.h:513
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
LHEF::Writer
Pythia8::Writer Writer
Definition: Prophecy4fMerger.cxx:12
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
Monitored::Scalar
Declare a monitored scalar variable.
Definition: MonitoredScalar.h:34
ActsTrk::HGTDTrackExtensionAlg::m_numHGTDHitsKey
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_numHGTDHitsKey
Definition: HGTDTrackExtensionAlg.h:80
AthCommonReentrantAlgorithm< Gaudi::Algorithm >::m_extendedExtraObjects
DataObjIDColl m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
Definition: AthCommonReentrantAlgorithm.h:114
Amg::distance
float distance(const Amg::Vector3D &p1, const Amg::Vector3D &p2)
calculates the distance between two point in 3D space
Definition: GeoPrimitivesHelpers.h:54
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
ActsTrk::DefaultTrackStateCreator
Acts::TrackStateCreator< ActsTrk::detail::UncalibSourceLinkAccessor::Iterator, detail::RecoTrackContainer > DefaultTrackStateCreator
Definition: TrackFindingAlg.h:44
ActsTrk::HGTDTrackExtensionAlg::m_stripCalibTool
ToolHandle< ActsTrk::IOnTrackCalibratorTool< detail::RecoTrackStateContainer > > m_stripCalibTool
Definition: HGTDTrackExtensionAlg.h:107
Monitored::Timer
A monitored timer.
Definition: MonitoredTimer.h:32
TauGNNUtils::Variables::Track::trackEta
bool trackEta(const xAOD::TauJet &, const xAOD::TauTrack &track, double &out)
Definition: TauGNNUtils.cxx:488
fitman.k
k
Definition: fitman.py:528
generate::Zero
void Zero(TH1D *hin)
Definition: generate.cxx:32
ServiceHandle< ICondSvc >