Loading [MathJax]/extensions/tex2jax.js
 |
ATLAS Offline Software
|
Go to the documentation of this file.
11 #include "Acts/Definitions/Units.hpp"
13 #include "Acts/AmbiguityResolution/GreedyAmbiguityResolution.hpp"
14 #include "Acts/EventData/MultiTrajectoryHelpers.hpp"
15 #include "Acts/EventData/VectorMultiTrajectory.hpp"
16 #include "Acts/EventData/VectorTrackContainer.hpp"
17 #include "Acts/Utilities/Logger.hpp"
26 std::size_t sourceLinkHash(
const Acts::SourceLink& slink) {
29 return uncalibMeas.identifier();
32 bool sourceLinkEquality(
const Acts::SourceLink&
a,
const Acts::SourceLink&
b) {
44 ISvcLocator *pSvcLocator)
52 Acts::GreedyAmbiguityResolution::Config
cfg;
65 return StatusCode::SUCCESS;
77 m_ambi->computeInitialState(*trackHandle, state, &sourceLinkHash,
82 ATH_MSG_DEBUG(
"Resolved to " << state.selectedTracks.size() <<
" tracks from "
83 << trackHandle->size());
86 solvedTracks.ensureDynamicColumns(*trackHandle);
91 std::size_t totalShared = 0;
92 for (
auto iTrack : state.selectedTracks) {
93 auto destProxy = solvedTracks.getTrack(solvedTracks.addTrack());
94 destProxy.copyFrom(trackHandle->getTrack(state.trackTips.at(iTrack)));
96 auto [nShared, nBadTrackMeasurements] = sharedHits.
computeSharedHitsDynamic(destProxy, solvedTracks, measurementIndex);
97 if (nBadTrackMeasurements > 0)
98 ATH_MSG_ERROR(
"computeSharedHits: " << nBadTrackMeasurements <<
" track measurements not found in input track");
99 totalShared += nShared;
103 ATH_MSG_DEBUG(
"total number of shared hits = " << totalShared);
109 if (resolvedTrackHandle.
record( std::move(outputTracks)).isFailure()) {
111 return StatusCode::FAILURE;
114 return StatusCode::SUCCESS;
DetectorIdentType identifier() const
Returns the full Identifier of the measurement.
Gaudi::Property< bool > m_countSharedHits
Group
Properties of a chain group.
std::unique_ptr< ActsTrk::TrackContainer > moveToConst(ActsTrk::MutableTrackContainer &&tc, const Acts::GeometryContext &geoContext, const EventContext &evtContext) const
produces ActsTrk::ConstTrackContainer with all backends stored in SG
Gaudi::Property< unsigned int > m_maximumIterations
std::string prefixFromTrackContainerName(const std::string &tracks)
Parse TrackContainer name to get the prefix for backends The name has to contain XYZTracks,...
ActsTrk::MutableTrackContainerHandlesHelper m_resolvedTracksBackendHandles
const std::string & key() const
Return the StoreGate ID for the referenced object.
StatusCode initialize(const std::string &prefix)
Sets up the handles.
def timer(name, disabled=False)
An algorithm that can be simultaneously executed in multiple threads.
std::unique_ptr< Acts::GreedyAmbiguityResolution > m_ambi
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
std::unique_ptr< const Acts::Logger > makeActsAthenaLogger(IMessageSvc *svc, const std::string &name, int level, std::optional< std::string > parent_name)
auto computeSharedHitsDynamic(typename track_container_t::TrackProxy &track, track_container_t &tracks, MeasurementIndex &measurementIndex) -> ReturnSharedAndBad
::StatusCode StatusCode
StatusCode definition for legacy code.
CalibratedSpacePoint::State State
Gaudi::Property< unsigned int > m_nMeasurementsMin
virtual StatusCode initialize() override
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
AmbiguityResolutionAlg(const std::string &name, ISvcLocator *pSvcLocator)
Header file to be included by clients of the Monitored infrastructure.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
ToolHandle< GenericMonitoringTool > m_monTool
Gaudi::Property< unsigned int > m_maximumSharedHits
const xAOD::UncalibratedMeasurement & getUncalibratedMeasurement(const ATLASUncalibSourceLink &source_link)
ToolHandle< IActsTrackingGeometryTool > m_trackingGeometryTool
SG::WriteHandleKey< ActsTrk::TrackContainer > m_resolvedTracksKey
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
The AlignStoreProviderAlg loads the rigid alignment corrections and pipes them through the readout ge...
SG::ReadHandleKey< ActsTrk::TrackContainer > m_tracksKey
virtual StatusCode execute(const EventContext &ctx) const override