ATLAS Offline Software
IActsToTrkConverterTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef ACTSGEOMETRYINTERFACES_IActsToTrkConverterTool_H
6 #define ACTSGEOMETRYINTERFACES_IActsToTrkConverterTool_H
7 
8 // ATHENA
9 #include <memory>
10 
11 #include "GaudiKernel/IAlgTool.h"
12 #include "GaudiKernel/IInterface.h"
13 #include "StoreGate/WriteHandle.h"
14 #include "TrkParameters/TrackParameters.h" //typedef, cannot fwd declare
16 #include "xAODMeasurementBase/UncalibratedMeasurement.h" //typedef, cannot fwd declare
21 #include "Acts/EventData/TrackParameters.hpp"
22 #include "Acts/EventData/VectorTrackContainer.hpp"
24 
25 namespace Trk {
26  class Surface;
27  class Track;
28  class MeasurementBase;
29  class PrepRawData;
30 } // namespace Trk
31 
32 namespace Acts {
33 class Surface;
34 class SourceLink;
35 }
36 
37 namespace ActsTrk::detail {
38  enum class SourceLinkType;
39 }
40 
41 
42 namespace ActsTrk {
45 class IActsToTrkConverterTool : virtual public IAlgTool {
46  public:
53  virtual const Trk::Surface& actsSurfaceToTrkSurface(const Acts::Surface& actsSurface) const = 0;
58  virtual const Acts::Surface& trkSurfaceToActsSurface(const Trk::Surface& atlasSurface) const = 0;
59 
63  virtual std::vector<Acts::SourceLink> trkTrackToSourceLinks(const Trk::Track& track) const = 0;
68  virtual void toSourceLinks(const std::vector<const Trk::MeasurementBase*>& measSet,
69  std::vector<Acts::SourceLink>& links) const = 0;
74  virtual void toSourceLinks(const std::vector<const Trk::PrepRawData*>& prdSet,
75  std::vector<Acts::SourceLink>& links) const = 0;
80  virtual const Acts::BoundTrackParameters trkTrackParametersToActsParameters(
81  const Trk::TrackParameters& atlasParameter,
82  const Acts::GeometryContext& gctx,
83  Trk::ParticleHypothesis hypothesis = Trk::pion) const = 0;
84 
89  virtual std::unique_ptr<Trk::TrackParameters>
90  actsTrackParametersToTrkParameters(const Acts::BoundTrackParameters& actsParameter,
91  const Acts::GeometryContext& gctx) const = 0;
100  using TrackFitResult_t = Acts::Result<ActsTrk::MutableTrackContainer::TrackProxy, std::error_code>;
101  virtual std::unique_ptr<Trk::Track> convertFitResult(const EventContext& ctx,
103  TrackFitResult_t& fitResult,
104  const Trk::TrackInfo::TrackFitter fitAuthor,
105  const detail::SourceLinkType slType) const = 0;
106 
109  const TrackCollection& trackColl,
110  const Acts::GeometryContext& gctx) const = 0;
111 
112 };
113 } // namespace ActsTrk
114 
115 #endif
UncalibratedMeasurement.h
TrackParameters.h
Trk::Track
The ATLAS Track class.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/Track.h:73
ActsTrk::MutableTrackContainer
Acts::TrackContainer< MutableTrackBackend, MutableTrackStateBackend, Acts::detail::ValueHolder > MutableTrackContainer
Definition: TrackContainer.h:26
Surface
Definition: Trigger/TrigAccel/TrigCudaFitter/src/Surface.h:8
TrackParametersContainer.h
ActsTrk::IActsToTrkConverterTool::DeclareInterfaceID
DeclareInterfaceID(IActsToTrkConverterTool, 1, 0)
Trk::ParticleHypothesis
ParticleHypothesis
Definition: ParticleHypothesis.h:28
ActsTrk::IActsToTrkConverterTool::trkSurfaceToActsSurface
virtual const Acts::Surface & trkSurfaceToActsSurface(const Trk::Surface &atlasSurface) const =0
Translate the parsed Trk surface into an Acts surface.
TrackStateContainer.h
WriteHandle.h
Handle class for recording to StoreGate.
Trk::TrackInfo::TrackFitter
TrackFitter
enums to identify who created this track and what propertis does it have.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/TrackInfo.h:39
Acts
Definition: MuonSpectrometer/MuonPhaseII/Event/xAOD/xAODMuonPrepData/xAODMuonPrepData/UtilFunctions.h:17
DMTest::links
links
Definition: CLinks_v1.cxx:22
ActsTrk::IActsToTrkConverterTool::trkTrackToSourceLinks
virtual std::vector< Acts::SourceLink > trkTrackToSourceLinks(const Trk::Track &track) const =0
Converts the Trk measurement track states into a vector of Acts::Source links.
Trk::pion
@ pion
Definition: ParticleHypothesis.h:32
ActsTrk::IActsToTrkConverterTool
Conversion tool interface to translate surfaces & track parameters between the Acts & Trk realm.
Definition: IActsToTrkConverterTool.h:45
TrackCollection.h
ActsTrk::detail::SourceLinkType
SourceLinkType
Enumeration to distinguish between the ATLAS EDM -> Acts::SourceLink variants.
Definition: SourceLinkType.h:9
Trk::ParametersBase
Definition: ParametersBase.h:55
DataVector< Trk::Track >
ActsTrk::IActsToTrkConverterTool::toSourceLinks
virtual void toSourceLinks(const std::vector< const Trk::PrepRawData * > &prdSet, std::vector< Acts::SourceLink > &links) const =0
Converts a vector of Trk::PrepRawData states into a vector of Acts source links and appends the resul...
TrackJacobianContainer.h
ActsTrk::IActsToTrkConverterTool::actsTrackParametersToTrkParameters
virtual std::unique_ptr< Trk::TrackParameters > actsTrackParametersToTrkParameters(const Acts::BoundTrackParameters &actsParameter, const Acts::GeometryContext &gctx) const =0
Translates the bounded Acts track parameters to Trk parameters.
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
ActsTrk::IActsToTrkConverterTool::trkTrackParametersToActsParameters
virtual const Acts::BoundTrackParameters trkTrackParametersToActsParameters(const Trk::TrackParameters &atlasParameter, const Acts::GeometryContext &gctx, Trk::ParticleHypothesis hypothesis=Trk::pion) const =0
Translates the Trk track parameters into bound Acts track parameters with a particle hypothesis.
ActsTrk::IActsToTrkConverterTool::convertFitResult
virtual std::unique_ptr< Trk::Track > convertFitResult(const EventContext &ctx, ActsTrk::MutableTrackContainer &tracks, TrackFitResult_t &fitResult, const Trk::TrackInfo::TrackFitter fitAuthor, const detail::SourceLinkType slType) const =0
ActsTrk::IActsToTrkConverterTool::TrackFitResult_t
Acts::Result< ActsTrk::MutableTrackContainer::TrackProxy, std::error_code > TrackFitResult_t
Convert the Acts fit result into a Trk::Track object, if the fit was successful.
Definition: IActsToTrkConverterTool.h:100
Track
Definition: TriggerChamberClusterOnTrackCreator.h:21
ActsTrk
The AlignStoreProviderAlg loads the rigid alignment corrections and pipes them through the readout ge...
Definition: MSTrackingVolumeBuilder.cxx:24
ActsTrk::IActsToTrkConverterTool::actsSurfaceToTrkSurface
virtual const Trk::Surface & actsSurfaceToTrkSurface(const Acts::Surface &actsSurface) const =0
Translates the parsed Acts surface into a Trk::Surface via associated detector element.
xAOD::track
@ track
Definition: TrackingPrimitives.h:513
ActsTrk::detail
Athena definition of the Eigen plugin.
Definition: MeasurementCalibratorBase.h:19
Trk::Surface
Definition: Tracking/TrkDetDescr/TrkSurfaces/TrkSurfaces/Surface.h:79
ActsTrk::IActsToTrkConverterTool::trkTrackCollectionToActsTrackContainer
virtual void trkTrackCollectionToActsTrackContainer(ActsTrk::MutableTrackContainer &tc, const TrackCollection &trackColl, const Acts::GeometryContext &gctx) const =0
TrackContainer.h
TrackMeasurementContainer.h
ActsTrk::IActsToTrkConverterTool::toSourceLinks
virtual void toSourceLinks(const std::vector< const Trk::MeasurementBase * > &measSet, std::vector< Acts::SourceLink > &links) const =0
Converts a vector of Trk measurement states into a vector of Acts source links and appends the result...