From 3d3c37f4a22fd51e37f837383059833434e63fb9 Mon Sep 17 00:00:00 2001 From: Andreas Stefl Date: Sat, 6 Apr 2024 15:21:33 +0200 Subject: [PATCH] restore first track --- .../include/Acts/TrackFinding/CombinatorialKalmanFilter.hpp | 3 ++- .../Algorithms/TrackFinding/src/TrackFindingAlgorithm.cpp | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Core/include/Acts/TrackFinding/CombinatorialKalmanFilter.hpp b/Core/include/Acts/TrackFinding/CombinatorialKalmanFilter.hpp index 5af216c62eb..f7383d31cdb 100644 --- a/Core/include/Acts/TrackFinding/CombinatorialKalmanFilter.hpp +++ b/Core/include/Acts/TrackFinding/CombinatorialKalmanFilter.hpp @@ -671,7 +671,8 @@ class CombinatorialKalmanFilter { // TrackState. No storage allocation for uncalibrated/calibrated // measurement and filtered parameter auto stateMask = - ~(TrackStatePropMask::Calibrated | TrackStatePropMask::Filtered); + ~(TrackStatePropMask::Calibrated | TrackStatePropMask::Filtered | + TrackStatePropMask::Smoothed); // Increment of number of processed states tipState.nStates++; diff --git a/Examples/Algorithms/TrackFinding/src/TrackFindingAlgorithm.cpp b/Examples/Algorithms/TrackFinding/src/TrackFindingAlgorithm.cpp index 5bed74a77b8..62d469e6323 100644 --- a/Examples/Algorithms/TrackFinding/src/TrackFindingAlgorithm.cpp +++ b/Examples/Algorithms/TrackFinding/src/TrackFindingAlgorithm.cpp @@ -257,6 +257,9 @@ ActsExamples::ProcessCode ActsExamples::TrackFindingAlgorithm::execute( extrapolationOptions, m_cfg.extrapolationStrategy, logger()); if (!secondExtrapolationResult.ok()) { + // restore first track + (*firstFirstState).previous() = Acts::kTrackIndexInvalid; + m_nFailedExtrapolation++; ACTS_ERROR("Second extrapolation for seed " << iSeed << " and track " << secondTrack.index() @@ -271,6 +274,9 @@ ActsExamples::ProcessCode ActsExamples::TrackFindingAlgorithm::execute( destProxy.copyFrom(secondTrack, true); } + // restore first track + (*firstFirstState).previous() = Acts::kTrackIndexInvalid; + ++nSecond; } }