File indexing completed on 2025-01-18 09:11:41
0001
0002
0003
0004
0005
0006
0007
0008
0009 #include "ActsExamples/TrackFitting/RefittingCalibrator.hpp"
0010
0011 #include "Acts/Definitions/Algebra.hpp"
0012 #include "Acts/EventData/MeasurementHelpers.hpp"
0013 #include "Acts/EventData/SourceLink.hpp"
0014 #include "Acts/Utilities/CalibrationContext.hpp"
0015
0016 namespace ActsExamples {
0017
0018 void RefittingCalibrator::calibrate(const Acts::GeometryContext& ,
0019 const Acts::CalibrationContext& ,
0020 const Acts::SourceLink& sourceLink,
0021 Proxy trackState) const {
0022 const auto sl = sourceLink.get<RefittingSourceLink>();
0023
0024
0025 trackState.setUncalibratedSourceLink(sl.state.getUncalibratedSourceLink());
0026
0027
0028
0029 Acts::visit_measurement(sl.state.calibratedSize(), [&](auto N) {
0030 using namespace Acts;
0031 constexpr int Size = decltype(N)::value;
0032
0033 trackState.allocateCalibrated(
0034 sl.state.template calibrated<Size>().eval(),
0035 sl.state.template calibratedCovariance<Size>().eval());
0036 });
0037
0038 trackState.setProjectorSubspaceIndices(sl.state.projectorSubspaceIndices());
0039 }
0040
0041 }