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

#include <KalmanFitter.h>

Inheritance diagram for ActsTrk::KalmanFitter:
Collaboration diagram for ActsTrk::KalmanFitter:

Public Member Functions

 KalmanFitter (const std::string &, const std::string &, const IInterface *)
 
virtual ~KalmanFitter ()=default
 
virtual StatusCode initialize () override
 
virtual std::unique_ptr< Trk::Trackfit (const EventContext &ctx, const Trk::Track &, const Trk::RunOutlierRemoval runOutlier=false, const Trk::ParticleHypothesis matEffects=Trk::nonInteracting) const override
 refit a track More...
 
virtual std::unique_ptr< Trk::Trackfit (const EventContext &ctx, const Trk::PrepRawDataSet &, const Trk::TrackParameters &, const Trk::RunOutlierRemoval runOutlier=false, const Trk::ParticleHypothesis matEffects=Trk::nonInteracting) const override
 fit a set of PrepRawData objects More...
 
virtual std::unique_ptr< Trk::Trackfit (const EventContext &ctx, const Trk::MeasurementSet &, const Trk::TrackParameters &, const Trk::RunOutlierRemoval runOutlier=false, const Trk::ParticleHypothesis matEffects=Trk::nonInteracting) const override
 fit a set of MeasurementBase objects More...
 
virtual std::unique_ptr< Trk::Trackfit (const EventContext &ctx, const Trk::Track &, const Trk::PrepRawDataSet &, const Trk::RunOutlierRemoval runOutlier=false, const Trk::ParticleHypothesis matEffects=Trk::nonInteracting) const override
 extend a track fit including a new set of PrepRawData objects More...
 
virtual std::unique_ptr< ActsTrk::MutableTrackContainerfit (const EventContext &ctx, const std::vector< ActsTrk::ATLASUncalibSourceLink > &clusterList, const Acts::BoundTrackParameters &initialParams, const Acts::GeometryContext &tgContext, const Acts::MagneticFieldContext &mfContext, const Acts::CalibrationContext &calContext, const DetectorElementToActsGeometryIdMap &detectorElementToGeometryIdMap, const Acts::Surface *targetSurface=nullptr) const override
 fit a set of xAOD uncalibrated Measurements More...
 
virtual std::unique_ptr< Trk::Trackfit (const EventContext &ctx, const Trk::Track &, const Trk::MeasurementSet &, const Trk::RunOutlierRemoval runOutlier=false, const Trk::ParticleHypothesis matEffects=Trk::nonInteracting) const override
 extend a track fit including a new set of MeasurementBase objects More...
 
virtual std::unique_ptr< Trk::Trackfit (const EventContext &ctx, const Trk::Track &intrk1, const Trk::Track &intrk2, const Trk::RunOutlierRemoval runOutlier=false, const Trk::ParticleHypothesis matEffects=Trk::nonInteracting) const override
 combined track fit More...
 
virtual std::unique_ptr< ActsTrk::MutableTrackContainerfit (const EventContext &ctx, const ActsTrk::Seed &seed, const Acts::BoundTrackParameters &initialParams, const Acts::GeometryContext &tgContext, const Acts::MagneticFieldContext &mfContext, const Acts::CalibrationContext &calContext, const DetectorElementToActsGeometryIdMap &detectorElementToGeometryIdMap) const override
 Acts seed fit. More...
 

Private Types

using Fitter = Acts::KalmanFitter< Acts::Propagator< Acts::SympyStepper, Acts::Navigator >, ActsTrk::MutableTrackStateBackend >
 Type erased track fitter function. More...
 
using DirectFitter = Acts::KalmanFitter< Acts::Propagator< Acts::SympyStepper, Acts::DirectNavigator >, ActsTrk::MutableTrackStateBackend >
 

Private Member Functions

std::unique_ptr< Trk::TrackmakeTrack (const EventContext &ctx, Acts::GeometryContext &tgContext, ActsTrk::MutableTrackContainer &tracks, Acts::Result< ActsTrk::MutableTrackContainer::TrackProxy, std::error_code > &fitResult, bool SourceLinkType=false) const
 
const Acts::Logger & logger () const
 Private access to the logger. More...
 

Private Attributes

ToolHandle< IActsExtrapolationToolm_extrapolationTool {this, "ExtrapolationTool", ""}
 
ToolHandle< IActsTrackingGeometryToolm_trackingGeometryTool {this, "TrackingGeometryTool", ""}
 
ToolHandle< ActsTrk::IActsToTrkConverterToolm_ATLASConverterTool {this, "ATLASConverterTool", ""}
 
ToolHandle< Trk::IExtendedTrackSummaryToolm_trkSummaryTool {this, "SummaryTool", "", "ToolHandle for track summary tool"}
 
ToolHandle< Trk::IBoundaryCheckToolm_boundaryCheckTool
 
Gaudi::Property< double > m_option_outlierChi2Cut
 
Gaudi::Property< double > m_option_ReverseFilteringPt
 
Gaudi::Property< int > m_option_maxPropagationStep
 
Gaudi::Property< double > m_option_seedCovarianceScale
 
std::unique_ptr< TrkMeasurementCalibratorm_calibrator
 
std::unique_ptr< Fitterm_fitter {nullptr}
 
std::unique_ptr< DirectFitterm_directFitter {nullptr}
 
Acts::KalmanFitterExtensions< ActsTrk::MutableTrackStateBackendm_kfExtensions
 
ActsTrk::detail::FitterHelperFunctions::ATLASOutlierFinder m_outlierFinder {0}
 
ActsTrk::detail::FitterHelperFunctions::ReverseFilteringLogic m_reverseFilteringLogic {0}
 
std::unique_ptr< const Acts::Logger > m_logger
 logging instance More...
 
ToolHandle< Trk::IRIO_OnTrackCreatorm_broadROTcreator {this, "BroadRotCreatorTool", ""}
 
ToolHandle< Trk::IRIO_OnTrackCreatorm_ROTcreator {this, "RotCreatorTool", ""}
 
Gaudi::Property< bool > m_doReFitFromPRD {this, "DoReFitFromPRD", false, "Do Refit From PRD instead of ROT"}
 

Detailed Description

Definition at line 87 of file KalmanFitter.h.

Member Typedef Documentation

◆ DirectFitter

using ActsTrk::KalmanFitter::DirectFitter = Acts::KalmanFitter<Acts::Propagator<Acts::SympyStepper, Acts::DirectNavigator>, ActsTrk::MutableTrackStateBackend>
private

Definition at line 205 of file KalmanFitter.h.

◆ Fitter

using ActsTrk::KalmanFitter::Fitter = Acts::KalmanFitter<Acts::Propagator<Acts::SympyStepper, Acts::Navigator>, ActsTrk::MutableTrackStateBackend>
private

Type erased track fitter function.

Definition at line 202 of file KalmanFitter.h.

Constructor & Destructor Documentation

◆ KalmanFitter()

ActsTrk::KalmanFitter::KalmanFitter ( const std::string &  t,
const std::string &  n,
const IInterface *  p 
)

Definition at line 169 of file KalmanFitter.cxx.

170  :
171  base_class(t,n,p)
172 {}

◆ ~KalmanFitter()

virtual ActsTrk::KalmanFitter::~KalmanFitter ( )
virtualdefault

Member Function Documentation

◆ fit() [1/8]

std::unique_ptr< ActsTrk::MutableTrackContainer > ActsTrk::KalmanFitter::fit ( const EventContext &  ctx,
const ActsTrk::Seed seed,
const Acts::BoundTrackParameters &  initialParams,
const Acts::GeometryContext &  tgContext,
const Acts::MagneticFieldContext &  mfContext,
const Acts::CalibrationContext &  calContext,
const DetectorElementToActsGeometryIdMap detectorElementToGeometryIdMap 
) const
overridevirtual

Acts seed fit.

Definition at line 878 of file KalmanFitter.cxx.

885 {
886  const Acts::TrackingGeometry *
887  actsTrackingGeometry = m_trackingGeometryTool->trackingGeometry().get();
888  if (!actsTrackingGeometry) {
889  throw std::runtime_error("No Acts tracking geometry.");
890  }
891 
892  std::vector<ActsTrk::ATLASUncalibSourceLink> sourceLinks;
893  sourceLinks.reserve(6);
894 
895  std::vector<const Acts::Surface*> surfaces;
896  surfaces.reserve(6);
897 
898  const auto& sps = seed.sp();
899  for (const xAOD::SpacePoint* sp : sps) {
900  const auto& measurements = sp->measurements();
901  for (const xAOD::UncalibratedMeasurement *umeas : measurements) {
903  sourceLinks.emplace_back( el );
904  surfaces.push_back(ActsTrk::getSurfaceOfMeasurement(*actsTrackingGeometry, detectorElementToGeometryIdMap, *umeas));
905  }
906  }
907  return fit(ctx, sourceLinks, initialParams, tgContext, mfContext, calContext, detectorElementToGeometryIdMap, surfaces.front());
908 }

◆ fit() [2/8]

std::unique_ptr< ActsTrk::MutableTrackContainer > ActsTrk::KalmanFitter::fit ( const EventContext &  ctx,
const std::vector< ActsTrk::ATLASUncalibSourceLink > &  clusterList,
const Acts::BoundTrackParameters &  initialParams,
const Acts::GeometryContext &  tgContext,
const Acts::MagneticFieldContext &  mfContext,
const Acts::CalibrationContext &  calContext,
const DetectorElementToActsGeometryIdMap detectorElementToGeometryIdMap,
const Acts::Surface *  targetSurface = nullptr 
) const
overridevirtual

fit a set of xAOD uncalibrated Measurements

Definition at line 445 of file KalmanFitter.cxx.

452  {
453  ATH_MSG_DEBUG("--> entering KalmanFitter::fit(xAODMeasure...things,TP,)");
454 
455  std::vector<Acts::SourceLink> sourceLinks;
456  sourceLinks.reserve(clusterList.size());
457 
458  std::vector<const Acts::Surface*> surfaces;
459  surfaces.reserve(clusterList.size());
460 
461  const Acts::TrackingGeometry *
462  actsTrackingGeometry = m_trackingGeometryTool->trackingGeometry().get();
463  if (!actsTrackingGeometry) {
464  throw std::runtime_error("No Acts tracking geometry.");
465  }
466 
467  for (const ActsTrk::ATLASUncalibSourceLink& el : clusterList) {
468  sourceLinks.emplace_back( el );
469  surfaces.push_back(ActsTrk::getSurfaceOfMeasurement(*actsTrackingGeometry, detectorElementToGeometryIdMap, getUncalibratedMeasurement(el) ));
470  }
471 
472  Acts::KalmanFitterExtensions<ActsTrk::MutableTrackStateBackend> kfExtensions = m_kfExtensions;
473 
474  ActsTrk::ATLASUncalibSourceLinkSurfaceAccessor surfaceAccessor( *actsTrackingGeometry, detectorElementToGeometryIdMap);
475  kfExtensions.surfaceAccessor.connect<&ActsTrk::ATLASUncalibSourceLinkSurfaceAccessor::operator()>(&surfaceAccessor);
476 
477  detail::OnTrackCalibrator calibrator = detail::OnTrackCalibrator<ActsTrk::MutableTrackStateBackend>
478  ::NoCalibration(*actsTrackingGeometry, detectorElementToGeometryIdMap);
479 
480  kfExtensions.calibrator.connect<&detail::OnTrackCalibrator<ActsTrk::MutableTrackStateBackend>::calibrate>(&calibrator);
481 
482  Acts::PropagatorPlainOptions propagationOption(tgContext, mfContext);
483  propagationOption.maxSteps = m_option_maxPropagationStep;
484 
485  // Construct a perigee surface as the target surface if none is provided
486  std::shared_ptr<Acts::Surface> pSurface{nullptr};
487  if (!targetSurface){
488  pSurface = Acts::Surface::makeShared<Acts::PerigeeSurface>(Acts::Vector3{0., 0., 0.});
489  targetSurface = pSurface.get();
490  }
491 
492  // Set the KalmanFitter options
493  Acts::KalmanFitterOptions<ActsTrk::MutableTrackStateBackend>
494  kfOptions(tgContext, mfContext, calContext,
495  kfExtensions,
496  propagationOption,
497  targetSurface);
498 
499  std::unique_ptr< ActsTrk::MutableTrackContainer > tracks = std::make_unique< ActsTrk::MutableTrackContainer >();
500 
501 
502  auto result = m_directFitter->fit(sourceLinks.begin(),
503  sourceLinks.end(),
504  initialParams,
505  kfOptions,
506  surfaces,
507  *tracks.get());
508 
509  if (not result.ok()) {
510  ATH_MSG_VERBOSE("Kalman Fitter on Seed has failed");
511  return nullptr;
512  }
513  return tracks;
514 }

◆ fit() [3/8]

std::unique_ptr< Trk::Track > ActsTrk::KalmanFitter::fit ( const EventContext &  ctx,
const Trk::MeasurementSet inputMeasSet,
const Trk::TrackParameters estimatedStartParameters,
const Trk::RunOutlierRemoval  runOutlier = false,
const Trk::ParticleHypothesis  matEffects = Trk::nonInteracting 
) const
overridevirtual

fit a set of MeasurementBase objects

Definition at line 310 of file KalmanFitter.cxx.

315 {
316  std::unique_ptr<Trk::Track> track = nullptr;
317 
318  // protection against not having measurements on the input track
319  if (inputMeasSet.size() < 2) {
320  ATH_MSG_DEBUG("called to refit empty measurement set or a measurement set with too little information, reject fit");
321  return nullptr;
322  }
323 
324  // Construct a perigee surface as the target surface
325  auto pSurface = Acts::Surface::makeShared<Acts::PerigeeSurface>(
326  Acts::Vector3{0., 0., 0.});
327 
328  Acts::GeometryContext tgContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
329  Acts::MagneticFieldContext mfContext = m_extrapolationTool->getMagneticFieldContext(ctx);
330  // CalibrationContext converter not implemented yet.
331  Acts::CalibrationContext calContext = Acts::CalibrationContext();
332 
333  Acts::KalmanFitterExtensions<ActsTrk::MutableTrackStateBackend> kfExtensions = m_kfExtensions;
334 
335  ATLASSourceLinkSurfaceAccessor surfaceAccessor{&(*m_ATLASConverterTool)};
336  kfExtensions.surfaceAccessor.connect<&ATLASSourceLinkSurfaceAccessor::operator()>(&surfaceAccessor);
337 
338  Acts::PropagatorPlainOptions propagationOption(tgContext, mfContext);
339  propagationOption.maxSteps = m_option_maxPropagationStep;
340  // Set the KalmanFitter options
341  Acts::KalmanFitterOptions
342  kfOptions(tgContext, mfContext, calContext,
343  kfExtensions,
344  propagationOption,
345  &(*pSurface));
346 
347  std::vector<Acts::SourceLink> trackSourceLinks;
348  trackSourceLinks.reserve(inputMeasSet.size());
349 
350  for (auto it = inputMeasSet.begin(); it != inputMeasSet.end(); ++it){
351  trackSourceLinks.push_back(m_ATLASConverterTool->trkMeasurementToSourceLink(tgContext, **it));
352  }
353  // protection against error in the conversion from Atlas masurement to Acts source link
354  if (trackSourceLinks.empty()) {
355  ATH_MSG_DEBUG("input contain measurement but no source link created, probable issue with the converter, reject fit ");
356  return track;
357  }
358 
359  const auto& initialParams = m_ATLASConverterTool->trkTrackParametersToActsParameters(estimatedStartParameters, tgContext);
360 
362 
363  // Perform the fit
364  auto result = m_fitter->fit(trackSourceLinks.begin(), trackSourceLinks.end(),
365  initialParams, kfOptions, tracks);
366  if (result.ok()) {
367  track = makeTrack(ctx, tgContext, tracks, result);
368  }
369  return track;
370 }

◆ fit() [4/8]

std::unique_ptr< Trk::Track > ActsTrk::KalmanFitter::fit ( const EventContext &  ctx,
const Trk::PrepRawDataSet inputPRDColl,
const Trk::TrackParameters estimatedStartParameters,
const Trk::RunOutlierRemoval  runOutlier = false,
const Trk::ParticleHypothesis  matEffects = Trk::nonInteracting 
) const
overridevirtual

fit a set of PrepRawData objects

Definition at line 375 of file KalmanFitter.cxx.

380 {
381  ATH_MSG_DEBUG("--> entering KalmanFitter::fit(PRDS,TP,)");
382 
383 
384  std::unique_ptr<Trk::Track> track = nullptr;
385 
386  // Construct a perigee surface as the target surface
387  auto pSurface = Acts::Surface::makeShared<Acts::PerigeeSurface>(
388  Acts::Vector3{0., 0., 0.});
389 
390  Acts::GeometryContext tgContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
391  Acts::MagneticFieldContext mfContext = m_extrapolationTool->getMagneticFieldContext(ctx);
392  // CalibrationContext converter not implemented yet.
393  Acts::CalibrationContext calContext = Acts::CalibrationContext();
394 
395  Acts::KalmanFitterExtensions<ActsTrk::MutableTrackStateBackend> kfExtensions = m_kfExtensions;
396 
397  PRDSourceLinkCalibrator calibrator{}; // @TODO: Set tool pointers
398  calibrator.rotCreator =m_ROTcreator.get();
399  calibrator.broadRotCreator = m_broadROTcreator.get();
400  calibrator.converterTool = m_ATLASConverterTool.get();
401  kfExtensions.calibrator.connect<&PRDSourceLinkCalibrator::calibrate<ActsTrk::MutableTrackStateBackend>>(&calibrator);
402 
403  PRDSourceLinkSurfaceAccessor surfaceAccessor{m_ATLASConverterTool.get()};
404  kfExtensions.surfaceAccessor.connect<&PRDSourceLinkSurfaceAccessor::operator()>(&surfaceAccessor);
405 
406  Acts::PropagatorPlainOptions propagationOption(tgContext, mfContext);
407  propagationOption.maxSteps = m_option_maxPropagationStep;
408  // Set the KalmanFitter options
409  Acts::KalmanFitterOptions
410  kfOptions(tgContext, mfContext, calContext,
411  kfExtensions,
412  propagationOption,
413  &(*pSurface));
414 
415 
416  std::vector<Acts::SourceLink> trackSourceLinks;
417  trackSourceLinks.reserve(inputPRDColl.size());
418 
419  for(const Trk::PrepRawData* prd : inputPRDColl) {
420  trackSourceLinks.push_back(Acts::SourceLink{PRDSourceLink{prd}});
421  }
422  // protection against error in the conversion from Atlas masurement to Acts source link
423  if (trackSourceLinks.empty()) {
424  ATH_MSG_WARNING("input contain measurement but no source link created, probable issue with the converter, reject fit ");
425  return track;
426  }
427  //
428 
429  const auto& initialParams = m_ATLASConverterTool->trkTrackParametersToActsParameters(estimatedStartParameters, tgContext);
430 
431 
433  // Perform the fit
434  auto result = m_fitter->fit(trackSourceLinks.begin(), trackSourceLinks.end(),
435  initialParams, kfOptions, tracks);
436  if (result.ok()) {
437  track = makeTrack(ctx, tgContext, tracks, result, true);
438  }
439  return track;
440 }

◆ fit() [5/8]

std::unique_ptr< Trk::Track > ActsTrk::KalmanFitter::fit ( const EventContext &  ctx,
const Trk::Track inputTrack,
const Trk::MeasurementSet addMeasColl,
const Trk::RunOutlierRemoval  runOutlier = false,
const Trk::ParticleHypothesis  matEffects = Trk::nonInteracting 
) const
overridevirtual

extend a track fit including a new set of MeasurementBase objects

Definition at line 521 of file KalmanFitter.cxx.

526 {
527  ATH_MSG_VERBOSE ("--> enter KalmanFitter::fit(Track,Meas'BaseSet,,)");
528  ATH_MSG_VERBOSE (" with Track from author = " << inputTrack.info().dumpInfo());
529 
530  // protection, if empty MeasurementSet
531  if (addMeasColl.empty()) {
532  ATH_MSG_DEBUG( "client tries to add an empty MeasurementSet to the track fit." );
533  return fit(ctx,inputTrack);
534  }
535 
536  // protection against not having measurements on the input track
537  if (!inputTrack.measurementsOnTrack() || (inputTrack.measurementsOnTrack()->size() < 2 && addMeasColl.empty())) {
538  ATH_MSG_DEBUG("called to refit empty track or track with too little information, reject fit");
539  return nullptr;
540  }
541 
542  // protection against not having track parameters on the input track
543  if (!inputTrack.trackParameters() || inputTrack.trackParameters()->empty()) {
544  ATH_MSG_DEBUG("input fails to provide track parameters for seeding the KF, reject fit");
545  return nullptr;
546  }
547 
548  std::unique_ptr<Trk::Track> track = nullptr;
549 
550  // Construct a perigee surface as the target surface
551  auto pSurface = Acts::Surface::makeShared<Acts::PerigeeSurface>(
552  Acts::Vector3{0., 0., 0.});
553 
554  Acts::GeometryContext tgContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
555  Acts::MagneticFieldContext mfContext = m_extrapolationTool->getMagneticFieldContext(ctx);
556  // CalibrationContext converter not implemented yet.
557  Acts::CalibrationContext calContext = Acts::CalibrationContext();
558 
559  Acts::KalmanFitterExtensions<ActsTrk::MutableTrackStateBackend> kfExtensions = m_kfExtensions;
560 
561  Acts::PropagatorPlainOptions propagationOption(tgContext, mfContext);
562  propagationOption.maxSteps = m_option_maxPropagationStep;
563  // Set the KalmanFitter options
564  Acts::KalmanFitterOptions
565  kfOptions(tgContext, mfContext, calContext,
566  kfExtensions,
567  propagationOption,
568  &(*pSurface));
569 
570  std::vector<Acts::SourceLink> trackSourceLinks = m_ATLASConverterTool->trkTrackToSourceLinks(tgContext, inputTrack);
571  const auto& initialParams = m_ATLASConverterTool->trkTrackParametersToActsParameters(*(inputTrack.perigeeParameters()), tgContext);
572 
573  for (auto it = addMeasColl.begin(); it != addMeasColl.end(); ++it)
574  {
575  trackSourceLinks.push_back(m_ATLASConverterTool->trkMeasurementToSourceLink(tgContext, **it));
576  }
577  // protection against error in the conversion from Atlas masurement to Acts source link
578  if (trackSourceLinks.empty()) {
579  ATH_MSG_DEBUG("input contain measurement but no source link created, probable issue with the converter, reject fit ");
580  return track;
581  }
582 
584  // Perform the fit
585  auto result = m_fitter->fit(trackSourceLinks.begin(), trackSourceLinks.end(),
586  initialParams, kfOptions, tracks);
587  if (result.ok()) {
588  track = makeTrack(ctx, tgContext, tracks, result);
589  }
590  return track;
591 }

◆ fit() [6/8]

std::unique_ptr< Trk::Track > ActsTrk::KalmanFitter::fit ( const EventContext &  ctx,
const Trk::Track ,
const Trk::PrepRawDataSet ,
const Trk::RunOutlierRemoval  runOutlier = false,
const Trk::ParticleHypothesis  matEffects = Trk::nonInteracting 
) const
overridevirtual

extend a track fit including a new set of PrepRawData objects

Definition at line 596 of file KalmanFitter.cxx.

601 {
602  ATH_MSG_DEBUG("Fit of Track with additional PrepRawDataSet not yet implemented");
603  return nullptr;
604 }

◆ fit() [7/8]

std::unique_ptr< Trk::Track > ActsTrk::KalmanFitter::fit ( const EventContext &  ctx,
const Trk::Track inputTrack,
const Trk::RunOutlierRemoval  runOutlier = false,
const Trk::ParticleHypothesis  matEffects = Trk::nonInteracting 
) const
overridevirtual

refit a track

Definition at line 227 of file KalmanFitter.cxx.

231 {
232  std::unique_ptr<Trk::Track> track = nullptr;
233  ATH_MSG_VERBOSE ("--> enter KalmanFitter::fit(Track,,) with Track from author = "
234  << inputTrack.info().dumpInfo());
235 
236  // protection against not having measurements on the input track
237  if (!inputTrack.measurementsOnTrack() || inputTrack.measurementsOnTrack()->size() < 2) {
238  ATH_MSG_DEBUG("called to refit empty track or track with too little information, reject fit");
239  return nullptr;
240  }
241 
242  // protection against not having track parameters on the input track
243  if (!inputTrack.trackParameters() || inputTrack.trackParameters()->empty()) {
244  ATH_MSG_DEBUG("input fails to provide track parameters for seeding the KF, reject fit");
245  return nullptr;
246  }
247 
248  // Construct a perigee surface as the target surface
249  auto pSurface = Acts::Surface::makeShared<Acts::PerigeeSurface>(
250  Acts::Vector3{0., 0., 0.});
251 
252  Acts::GeometryContext tgContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
253  Acts::MagneticFieldContext mfContext = m_extrapolationTool->getMagneticFieldContext(ctx);
254  // CalibrationContext converter not implemented yet.
255  Acts::CalibrationContext calContext = Acts::CalibrationContext();
256 
257  Acts::KalmanFitterExtensions<ActsTrk::MutableTrackStateBackend> kfExtensions = m_kfExtensions;
258 
259  ATLASSourceLinkSurfaceAccessor surfaceAccessor{&(*m_ATLASConverterTool)};
260  kfExtensions.surfaceAccessor.connect<&ATLASSourceLinkSurfaceAccessor::operator()>(&surfaceAccessor);
261 
262  Acts::PropagatorPlainOptions propagationOption(tgContext, mfContext);
263  propagationOption.maxSteps = m_option_maxPropagationStep;
264  // Set the KalmanFitter options
265  Acts::KalmanFitterOptions
266  kfOptions(tgContext, mfContext, calContext,
267  kfExtensions,
268  propagationOption,
269  &(*pSurface));
270 
271  std::vector<Acts::SourceLink> trackSourceLinks = m_ATLASConverterTool->trkTrackToSourceLinks(tgContext,inputTrack);
272  // protection against error in the conversion from Atlas masurement to Acts source link
273  if (trackSourceLinks.empty()) {
274  ATH_MSG_DEBUG("input contain measurement but no source link created, probable issue with the converter, reject fit ");
275  return track;
276  }
277 
278  const auto& initialParams = m_ATLASConverterTool->trkTrackParametersToActsParameters((*inputTrack.perigeeParameters()), tgContext);
279 
280  // The covariance from already fitted track are too small and would result an incorect smoothing.
281  // We scale up the input covaraiance to avoid this.
282  Acts::BoundSquareMatrix scaledCov = Acts::BoundSquareMatrix::Identity();
283  for (int i=0; i<6; ++i) {
285  (scaledCov)(i,i) = scale * initialParams.covariance().value()(i,i);
286  }
287 
288  // @TODO: Synchronize with prtHypothesis
290 
291  const Acts::BoundTrackParameters scaledInitialParams(initialParams.referenceSurface().getSharedPtr(),
292  initialParams.parameters(),
293  scaledCov,
294  hypothesis);
295 
297 
298  // Perform the fit
299  auto result = m_fitter->fit(trackSourceLinks.begin(), trackSourceLinks.end(),
300  scaledInitialParams, kfOptions, tracks);
301  if (result.ok()) {
302  track = makeTrack(ctx, tgContext, tracks, result);
303  }
304  return track;
305 }

◆ fit() [8/8]

std::unique_ptr< Trk::Track > ActsTrk::KalmanFitter::fit ( const EventContext &  ctx,
const Trk::Track intrk1,
const Trk::Track intrk2,
const Trk::RunOutlierRemoval  runOutlier = false,
const Trk::ParticleHypothesis  matEffects = Trk::nonInteracting 
) const
overridevirtual

combined track fit

Definition at line 609 of file KalmanFitter.cxx.

614 {
615  ATH_MSG_VERBOSE ("--> enter KalmanFitter::fit(Track,Track,)");
616  ATH_MSG_VERBOSE (" with Tracks from #1 = " << intrk1.info().dumpInfo()
617  << " and #2 = " << intrk2.info().dumpInfo());
618 
619  // protection, if empty track2
620  if (!intrk2.measurementsOnTrack()) {
621  ATH_MSG_DEBUG( "input #2 is empty try to fit track 1 alone" );
622  return fit(ctx,intrk1);
623  }
624 
625  // protection, if empty track1
626  if (!intrk1.measurementsOnTrack()) {
627  ATH_MSG_DEBUG( "input #1 is empty try to fit track 2 alone" );
628  return fit(ctx,intrk2);
629  }
630 
631  // protection against not having track parameters on the input track
632  if (!intrk1.trackParameters() || intrk1.trackParameters()->empty()) {
633  ATH_MSG_DEBUG("input #1 fails to provide track parameters for seeding the KF, reject fit");
634  return nullptr;
635  }
636 
637  std::unique_ptr<Trk::Track> track = nullptr;
638 
639  // Construct a perigee surface as the target surface
640  auto pSurface = Acts::Surface::makeShared<Acts::PerigeeSurface>(
641  Acts::Vector3{0., 0., 0.});
642 
643  Acts::GeometryContext tgContext = m_trackingGeometryTool->getGeometryContext(ctx).context();
644  Acts::MagneticFieldContext mfContext = m_extrapolationTool->getMagneticFieldContext(ctx);
645  // CalibrationContext converter not implemented yet.
646  Acts::CalibrationContext calContext = Acts::CalibrationContext();
647 
648  Acts::KalmanFitterExtensions<ActsTrk::MutableTrackStateBackend> kfExtensions = m_kfExtensions;
649 
650  Acts::PropagatorPlainOptions propagationOption(tgContext, mfContext);
651  propagationOption.maxSteps = m_option_maxPropagationStep;
652  // Set the KalmanFitter options
653  Acts::KalmanFitterOptions
654  kfOptions(tgContext, mfContext, calContext,
655  kfExtensions,
656  propagationOption,
657  &(*pSurface));
658 
659  std::vector<Acts::SourceLink> trackSourceLinks = m_ATLASConverterTool->trkTrackToSourceLinks(tgContext, intrk1);
660  std::vector<Acts::SourceLink> trackSourceLinks2 = m_ATLASConverterTool->trkTrackToSourceLinks(tgContext, intrk2);
661  trackSourceLinks.insert(trackSourceLinks.end(), trackSourceLinks2.begin(), trackSourceLinks2.end());
662  // protection against error in the conversion from Atlas masurement to Acts source link
663  if (trackSourceLinks.empty()) {
664  ATH_MSG_DEBUG("input contain measurement but no source link created, probable issue with the converter, reject fit ");
665  return track;
666  }
667 
668  const auto &initialParams = m_ATLASConverterTool->trkTrackParametersToActsParameters(*(intrk1.perigeeParameters()), tgContext);
669 
670  // The covariance from already fitted track are too small and would result an incorect smoothing.
671  // We scale up the input covaraiance to avoid this.
672  Acts::BoundSquareMatrix scaledCov = Acts::BoundSquareMatrix::Identity();
673  for (int i=0; i<6; ++i) {
675  (scaledCov)(i,i) = scale * initialParams.covariance().value()(i,i);
676  }
677 
678  const Acts::BoundTrackParameters scaledInitialParams(initialParams.referenceSurface().getSharedPtr(),
679  initialParams.parameters(),
680  scaledCov,
682 
683 
685  // Perform the fit
686  auto result = m_fitter->fit(trackSourceLinks.begin(), trackSourceLinks.end(),
687  scaledInitialParams, kfOptions, tracks);
688  if (result.ok()) {
689  track = makeTrack(ctx, tgContext, tracks, result);
690  }
691  return track;
692 }

◆ initialize()

StatusCode ActsTrk::KalmanFitter::initialize ( )
overridevirtual

Definition at line 174 of file KalmanFitter.cxx.

174  {
175 
176  ATH_MSG_DEBUG(name() << "::" << __FUNCTION__);
177  ATH_CHECK(m_trackingGeometryTool.retrieve());
178  ATH_CHECK(m_extrapolationTool.retrieve());
179  ATH_CHECK(m_ATLASConverterTool.retrieve());
180  ATH_CHECK(m_trkSummaryTool.retrieve());
181  if(m_doReFitFromPRD){
182  ATH_CHECK(m_ROTcreator.retrieve());
183  ATH_CHECK(m_broadROTcreator.retrieve());
184  }
185 
186  m_logger = makeActsAthenaLogger(this, "KalmanRefit");
187 
188  auto field = std::make_shared<ATLASMagneticFieldWrapper>();
189 
190  // Fitter
191  Acts::SympyStepper stepper(field);
192  Acts::Navigator navigator( Acts::Navigator::Config{ m_trackingGeometryTool->trackingGeometry() },
193  logger().cloneWithSuffix("Navigator"));
194  Acts::Propagator<Acts::SympyStepper, Acts::Navigator> propagator(stepper,
195  std::move(navigator),
196  logger().cloneWithSuffix("Prop"));
197 
198  m_fitter = std::make_unique<Fitter>(std::move(propagator),
199  logger().cloneWithSuffix("KalmanFitter"));
200 
201  // Direct Fitter
202  Acts::DirectNavigator directNavigator( logger().cloneWithSuffix("DirectNavigator") );
203  Acts::Propagator<Acts::SympyStepper, Acts::DirectNavigator> directPropagator(std::move(stepper),
204  std::move(directNavigator),
205  logger().cloneWithSuffix("DirectPropagator"));
206 
207  m_directFitter = std::make_unique<DirectFitter>(std::move(directPropagator),
208  logger().cloneWithSuffix("DirectKalmanFitter"));
209 
211  m_calibrator = std::make_unique<TrkMeasurementCalibrator>(*m_ATLASConverterTool);
214 
215  m_kfExtensions.outlierFinder.connect<&ActsTrk::detail::FitterHelperFunctions::ATLASOutlierFinder::operator()<ActsTrk::MutableTrackStateBackend>>(&m_outlierFinder);
216  m_kfExtensions.reverseFilteringLogic.connect<&ActsTrk::detail::FitterHelperFunctions::ReverseFilteringLogic::operator()<ActsTrk::MutableTrackStateBackend>>(&m_reverseFilteringLogic);
217  m_kfExtensions.updater.connect<&ActsTrk::detail::FitterHelperFunctions::gainMatrixUpdate<ActsTrk::MutableTrackStateBackend>>();
218  m_kfExtensions.smoother.connect<&ActsTrk::detail::FitterHelperFunctions::mbfSmoother<ActsTrk::MutableTrackStateBackend>>();
219  m_kfExtensions.calibrator.connect<&TrkMeasurementCalibrator::calibrate<ActsTrk::MutableTrackStateBackend>>(m_calibrator.get());
220 
221  return StatusCode::SUCCESS;
222 }

◆ logger()

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

Private access to the logger.

Definition at line 214 of file KalmanFitter.h.

214  {
215  return *m_logger;
216  }

◆ makeTrack()

std::unique_ptr< Trk::Track > ActsTrk::KalmanFitter::makeTrack ( const EventContext &  ctx,
Acts::GeometryContext &  tgContext,
ActsTrk::MutableTrackContainer tracks,
Acts::Result< ActsTrk::MutableTrackContainer::TrackProxy, std::error_code > &  fitResult,
bool  SourceLinkType = false 
) const
private

Definition at line 695 of file KalmanFitter.cxx.

698  {
699 
700  if (not fitResult.ok())
701  return nullptr;
702 
703  std::unique_ptr<Trk::Track> newtrack = nullptr;
704  // Get the fit output object
705  const auto& acts_track = fitResult.value();
706  auto finalTrajectory = std::make_unique<Trk::TrackStates>();
707  // initialise the number of dead Pixel and Acts strip
708  int numberOfDeadPixel = 0;
709  int numberOfDeadSCT = 0;
710 
711  std::vector<std::unique_ptr<const Acts::BoundTrackParameters>> actsSmoothedParam;
712  // Loop over all the output state to create track state
713  tracks.trackStateContainer().visitBackwards(acts_track.tipIndex(),
714  [&] (const auto &state) -> void
715  {
716  // First only concider state with an associated detector element not in the TRT
717  auto flag = state.typeFlags();
718  const auto* associatedDetEl = state.referenceSurface().associatedDetectorElement();
719  if (not associatedDetEl)
720  return;
721 
722  const auto* actsElement = dynamic_cast<const ActsDetectorElement*>(associatedDetEl);
723  if (not actsElement)
724  return;
725 
726  const auto* upstreamDetEl = actsElement->upstreamDetectorElement();
727  if (not upstreamDetEl)
728  return;
729 
730  ATH_MSG_VERBOSE("Try casting to TRT for if");
731  if (dynamic_cast<const InDetDD::TRT_BaseElement*>(upstreamDetEl))
732  return;
733 
734  const auto* trkDetElem = dynamic_cast<const Trk::TrkDetElementBase*>(upstreamDetEl);
735  if (not trkDetElem)
736  return;
737 
738  ATH_MSG_VERBOSE("trkDetElem type: " << static_cast<std::underlying_type_t<Trk::DetectorElemType>>(trkDetElem->detectorType()));
739 
740  ATH_MSG_VERBOSE("Try casting to SiDetectorElement");
741  const auto* detElem = dynamic_cast<const InDetDD::SiDetectorElement*>(upstreamDetEl);
742  if (not detElem)
743  return;
744  ATH_MSG_VERBOSE("detElem = " << detElem);
745 
746  // We need to determine the type of state
747  std::bitset<Trk::TrackStateOnSurface::NumberOfTrackStateOnSurfaceTypes> typePattern;
748  std::unique_ptr<Trk::TrackParameters> parm;
749 
750  // State is a hole (no associated measurement), use predicted parameters
751  if (flag.test(Acts::TrackStateFlag::HoleFlag)){
752  ATH_MSG_VERBOSE("State is a hole (no associated measurement), use predicted parameters");
753  const Acts::BoundTrackParameters actsParam(state.referenceSurface().getSharedPtr(),
754  state.predicted(),
755  state.predictedCovariance(),
756  acts_track.particleHypothesis());
757  parm = m_ATLASConverterTool->actsTrackParametersToTrkParameters(actsParam, tgContext);
758  auto boundaryCheck = m_boundaryCheckTool->boundaryCheck(*parm);
759 
760  // Check if this is a hole, a dead sensors or a state outside the sensor boundary
761  ATH_MSG_VERBOSE("Check if this is a hole, a dead sensors or a state outside the sensor boundary");
762  if(boundaryCheck == Trk::BoundaryCheckResult::DeadElement){
763  if (detElem->isPixel()) {
764  ++numberOfDeadPixel;
765  }
766  else if (detElem->isSCT()) {
767  ++numberOfDeadSCT;
768  }
769  // Dead sensors states are not stored
770  return;
771  } else if (boundaryCheck != Trk::BoundaryCheckResult::Candidate){
772  // States outside the sensor boundary are ignored
773  return;
774  }
775  typePattern.set(Trk::TrackStateOnSurface::Hole);
776  }
777  // The state was tagged as an outlier or was missed in the reverse filtering, use filtered parameters
778  else if (flag.test(Acts::TrackStateFlag::OutlierFlag) or !state.hasSmoothed()) {
779  ATH_MSG_VERBOSE("The state was tagged as an outlier or was missed in the reverse filtering, use filtered parameters");
780  const Acts::BoundTrackParameters actsParam(state.referenceSurface().getSharedPtr(),
781  state.filtered(),
782  state.filteredCovariance(),
783  acts_track.particleHypothesis());
784  parm = m_ATLASConverterTool->actsTrackParametersToTrkParameters(actsParam, tgContext);
785  typePattern.set(Trk::TrackStateOnSurface::Outlier);
786  }
787  // The state is a measurement state, use smoothed parameters
788  else{
789  ATH_MSG_VERBOSE("The state is a measurement state, use smoothed parameters");
790 
791  const Acts::BoundTrackParameters actsParam(state.referenceSurface().getSharedPtr(),
792  state.smoothed(),
793  state.smoothedCovariance(),
794  acts_track.particleHypothesis());
795 
796  actsSmoothedParam.push_back(std::make_unique<const Acts::BoundTrackParameters>(Acts::BoundTrackParameters(actsParam)));
797  parm = m_ATLASConverterTool->actsTrackParametersToTrkParameters(actsParam, tgContext);
798  typePattern.set(Trk::TrackStateOnSurface::Measurement);
799  }
800  std::unique_ptr<Trk::MeasurementBase> measState;
801  if (state.hasUncalibratedSourceLink() && !SourceLinkType){
802  auto sl = state.getUncalibratedSourceLink().template get<ATLASSourceLink>();
803  assert(sl);
804  measState = sl->uniqueClone();
805  }
806  else if (state.hasUncalibratedSourceLink() && SourceLinkType){ //If the SourceLink is of type PRDSourceLink, we need to create the RIO_OnTrack here.
807  auto sl = state.getUncalibratedSourceLink().template get<PRDSourceLink>().prd;
808 
809  //ROT creation
810  const IdentifierHash idHash = sl->detectorElement()->identifyHash();
811  int dim = state.calibratedSize();
812  std::unique_ptr<Trk::RIO_OnTrack> rot;
813  if (dim == 1) {
814  const InDet::SCT_Cluster* sct_Cluster = dynamic_cast<const InDet::SCT_Cluster*>(sl);
815  if(!sct_Cluster){
816  ATH_MSG_ERROR("ERROR could not cast PRD to SCT_Cluster");
817  return;
818  }
819  rot = std::make_unique<InDet::SCT_ClusterOnTrack>(sct_Cluster,Trk::LocalParameters(Trk::DefinedParameter(state.template calibrated<1>()[0], Trk::loc1)), state.template calibratedCovariance<1>(),idHash);
820  }
821  else if (dim == 2) {
822  const InDet::PixelCluster* pixelCluster = dynamic_cast<const InDet::PixelCluster*>(sl);
823  if(!pixelCluster){
824  //sometimes even with dim=2, only the SCT_Cluster implementation work for RIO_OnTrack creation
825  ATH_MSG_VERBOSE("Dimension is 2 but we need SCT_Cluster for this measurment");
826  const InDet::SCT_Cluster* sct_Cluster = dynamic_cast<const InDet::SCT_Cluster*>(sl);
827  rot = std::make_unique<InDet::SCT_ClusterOnTrack>(sct_Cluster,Trk::LocalParameters(Trk::DefinedParameter(state.template calibrated<1>()[0], Trk::loc1)), state.template calibratedCovariance<1>(),idHash);
828  }
829  else{
830  rot = std::make_unique<InDet::PixelClusterOnTrack>(pixelCluster,Trk::LocalParameters(state.template calibrated<2>()),state.template calibratedCovariance<2>(),idHash);
831  }
832  }
833  else {
834  throw std::domain_error("Cannot handle measurement dim>2");
835  }
836  measState = rot->uniqueClone();
837  }
838  double nDoF = state.calibratedSize();
839  auto quality =Trk::FitQualityOnSurface(state.chi2(), nDoF);
840  const Trk::TrackStateOnSurface *perState = new Trk::TrackStateOnSurface(quality, std::move(measState), std::move(parm), nullptr, typePattern);
841  // If a state was succesfully created add it to the trajectory
842  if (perState) {
843  ATH_MSG_VERBOSE("State succesfully creates, adding it to the trajectory");
844  finalTrajectory->insert(finalTrajectory->begin(), perState);
845  }
846  });
847  // Convert the perigee state and add it to the trajectory
848  const Acts::BoundTrackParameters actsPer(acts_track.referenceSurface().getSharedPtr(),
849  acts_track.parameters(),
850  acts_track.covariance(),
851  acts_track.particleHypothesis());
852  std::unique_ptr<Trk::TrackParameters> per = m_ATLASConverterTool->actsTrackParametersToTrkParameters(actsPer, tgContext);
853  std::bitset<Trk::TrackStateOnSurface::NumberOfTrackStateOnSurfaceTypes> typePattern;
854  typePattern.set(Trk::TrackStateOnSurface::Perigee);
855  const Trk::TrackStateOnSurface *perState = new Trk::TrackStateOnSurface(nullptr, std::move(per), nullptr, typePattern);
856  if (perState) finalTrajectory->insert(finalTrajectory->begin(), perState);
857 
858  // Create the track using the states
860  newInfo.setTrackFitter(Trk::TrackInfo::TrackFitter::KalmanFitter); //Mark the fitter as KalmanFitter
861  newtrack = std::make_unique<Trk::Track>(newInfo, std::move(finalTrajectory), nullptr);
862  if (newtrack) {
863  // Create the track summary and update the holes information
864  if (!newtrack->trackSummary()) {
865  newtrack->setTrackSummary(std::make_unique<Trk::TrackSummary>());
867  newtrack->trackSummary()->update(Trk::numberOfSCTHoles, 0);
868  newtrack->trackSummary()->update(Trk::numberOfTRTHoles, 0);
869  newtrack->trackSummary()->update(Trk::numberOfPixelDeadSensors, numberOfDeadPixel);
870  newtrack->trackSummary()->update(Trk::numberOfSCTDeadSensors, numberOfDeadSCT);
871  }
872  m_trkSummaryTool->updateTrackSummary(ctx, *newtrack, true);
873  }
874  return newtrack;
875 }

Member Data Documentation

◆ m_ATLASConverterTool

ToolHandle<ActsTrk::IActsToTrkConverterTool> ActsTrk::KalmanFitter::m_ATLASConverterTool {this, "ATLASConverterTool", ""}
private

Definition at line 183 of file KalmanFitter.h.

◆ m_boundaryCheckTool

ToolHandle<Trk::IBoundaryCheckTool> ActsTrk::KalmanFitter::m_boundaryCheckTool
private
Initial value:
{this,
"BoundaryCheckTool",
"",
"Boundary checking tool for detector sensitivities"}

Definition at line 185 of file KalmanFitter.h.

◆ m_broadROTcreator

ToolHandle<Trk::IRIO_OnTrackCreator> ActsTrk::KalmanFitter::m_broadROTcreator {this, "BroadRotCreatorTool", ""}
private

Definition at line 221 of file KalmanFitter.h.

◆ m_calibrator

std::unique_ptr<TrkMeasurementCalibrator> ActsTrk::KalmanFitter::m_calibrator
private

Definition at line 199 of file KalmanFitter.h.

◆ m_directFitter

std::unique_ptr<DirectFitter> ActsTrk::KalmanFitter::m_directFitter {nullptr}
private

Definition at line 206 of file KalmanFitter.h.

◆ m_doReFitFromPRD

Gaudi::Property<bool> ActsTrk::KalmanFitter::m_doReFitFromPRD {this, "DoReFitFromPRD", false, "Do Refit From PRD instead of ROT"}
private

Definition at line 224 of file KalmanFitter.h.

◆ m_extrapolationTool

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

Definition at line 181 of file KalmanFitter.h.

◆ m_fitter

std::unique_ptr<Fitter> ActsTrk::KalmanFitter::m_fitter {nullptr}
private

Definition at line 203 of file KalmanFitter.h.

◆ m_kfExtensions

Acts::KalmanFitterExtensions<ActsTrk::MutableTrackStateBackend> ActsTrk::KalmanFitter::m_kfExtensions
private

Definition at line 208 of file KalmanFitter.h.

◆ m_logger

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

logging instance

Definition at line 219 of file KalmanFitter.h.

◆ m_option_maxPropagationStep

Gaudi::Property< int > ActsTrk::KalmanFitter::m_option_maxPropagationStep
private
Initial value:
{this, "MaxPropagationStep", 5000,
"Maximum number of steps for one propagate call"}

Definition at line 194 of file KalmanFitter.h.

◆ m_option_outlierChi2Cut

Gaudi::Property< double > ActsTrk::KalmanFitter::m_option_outlierChi2Cut
private
Initial value:
{this, "OutlierChi2Cut", 12.5,
"Chi2 cut used by the outlier finder" }

Definition at line 190 of file KalmanFitter.h.

◆ m_option_ReverseFilteringPt

Gaudi::Property< double > ActsTrk::KalmanFitter::m_option_ReverseFilteringPt
private
Initial value:
{this, "ReverseFilteringPt", 1.0 * Acts::UnitConstants::GeV,
"Pt cut used for the ReverseFiltering logic"}

Definition at line 192 of file KalmanFitter.h.

◆ m_option_seedCovarianceScale

Gaudi::Property< double > ActsTrk::KalmanFitter::m_option_seedCovarianceScale
private
Initial value:
{this, "SeedCovarianceScale", 100.,
"Scale factor for the input seed covariance when doing refitting"}

Definition at line 196 of file KalmanFitter.h.

◆ m_outlierFinder

ActsTrk::detail::FitterHelperFunctions::ATLASOutlierFinder ActsTrk::KalmanFitter::m_outlierFinder {0}
private

Definition at line 210 of file KalmanFitter.h.

◆ m_reverseFilteringLogic

ActsTrk::detail::FitterHelperFunctions::ReverseFilteringLogic ActsTrk::KalmanFitter::m_reverseFilteringLogic {0}
private

Definition at line 211 of file KalmanFitter.h.

◆ m_ROTcreator

ToolHandle<Trk::IRIO_OnTrackCreator> ActsTrk::KalmanFitter::m_ROTcreator {this, "RotCreatorTool", ""}
private

Definition at line 222 of file KalmanFitter.h.

◆ m_trackingGeometryTool

ToolHandle<IActsTrackingGeometryTool> ActsTrk::KalmanFitter::m_trackingGeometryTool {this, "TrackingGeometryTool", ""}
private

Definition at line 182 of file KalmanFitter.h.

◆ m_trkSummaryTool

ToolHandle<Trk::IExtendedTrackSummaryTool> ActsTrk::KalmanFitter::m_trkSummaryTool {this, "SummaryTool", "", "ToolHandle for track summary tool"}
private

Definition at line 184 of file KalmanFitter.h.


The documentation for this class was generated from the following files:
Trk::noHypothesis
@ noHypothesis
Definition: ParticleHypothesis.h:37
Trk::LocalParameters
Definition: LocalParameters.h:98
Trk::TrackInfo
Contains information about the 'fitter' of this track.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/TrackInfo.h:32
Trk::TrackStateOnSurface::Perigee
@ Perigee
This represents a perigee, and so will contain a Perigee object only.
Definition: TrackStateOnSurface.h:117
ActsTrk::KalmanFitter::m_option_seedCovarianceScale
Gaudi::Property< double > m_option_seedCovarianceScale
Definition: KalmanFitter.h:196
ActsTrk::KalmanFitter::m_trackingGeometryTool
ToolHandle< IActsTrackingGeometryTool > m_trackingGeometryTool
Definition: KalmanFitter.h:182
GeV
#define GeV
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/Root/HelperFunctions.cxx:17
yodamerge_tmp.dim
dim
Definition: yodamerge_tmp.py:239
get_generator_info.result
result
Definition: get_generator_info.py:21
ActsTrk::detail::Navigator
Acts::Navigator Navigator
Definition: Tracking/Acts/ActsTrackReconstruction/src/detail/Definitions.h:31
ActsTrk::KalmanFitter::m_directFitter
std::unique_ptr< DirectFitter > m_directFitter
Definition: KalmanFitter.h:206
ActsTrk::KalmanFitter::m_option_maxPropagationStep
Gaudi::Property< int > m_option_maxPropagationStep
Definition: KalmanFitter.h:194
Trk::numberOfSCTDeadSensors
@ numberOfSCTDeadSensors
number of TRT hits
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:76
Trk::Track::info
const TrackInfo & info() const
Returns a const ref to info of a const tracks.
ActsTrk::KalmanFitter::m_broadROTcreator
ToolHandle< Trk::IRIO_OnTrackCreator > m_broadROTcreator
Definition: KalmanFitter.h:221
ActsTrk::KalmanFitter::m_reverseFilteringLogic
ActsTrk::detail::FitterHelperFunctions::ReverseFilteringLogic m_reverseFilteringLogic
Definition: KalmanFitter.h:211
skel.it
it
Definition: skel.GENtoEVGEN.py:396
xAOD::pion
@ pion
Definition: TrackingPrimitives.h:196
xAOD::SpacePoint_v1
Definition: SpacePoint_v1.h:29
ReadOfcFromCool.field
field
Definition: ReadOfcFromCool.py:48
ActsTrk::detail::FitterHelperFunctions::ReverseFilteringLogic::momentumMax
double momentumMax
Definition: FitterHelperFunctions.h:90
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
yodamerge_tmp.scale
scale
Definition: yodamerge_tmp.py:138
Trk::numberOfSCTHoles
@ numberOfSCTHoles
number of Holes in both sides of a SCT module
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:73
Trk::numberOfTRTHoles
@ numberOfTRTHoles
number of TRT hits which pass the high threshold (only xenon counted) total number of TRT hits which ...
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:83
Trk::TrackSummary::update
bool update(Trk::SummaryType type, int new_value)
Update unset summary information.
ActsTrk::KalmanFitter::m_extrapolationTool
ToolHandle< IActsExtrapolationTool > m_extrapolationTool
Definition: KalmanFitter.h:181
Trk::DefinedParameter
std::pair< double, ParamDefs > DefinedParameter
Definition: DefinedParameter.h:27
ActsTrk::getSurfaceOfMeasurement
const Acts::Surface * getSurfaceOfMeasurement(const Acts::TrackingGeometry &tracking_geometry, const DetectorElementToActsGeometryIdMap &detector_element_to_geoid, const xAOD::UncalibratedMeasurement &measurement)
Definition: SurfaceOfMeasurementUtil.h:13
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
Trk::FitQualityOnSurface
Definition: FitQualityOnSurface.h:19
ActsTrk::MutableMultiTrajectory
Athena implementation of ACTS::MultiTrajectory (ReadWrite version) The data is stored in 4 external b...
Definition: MultiTrajectory.h:81
ActsTrk::KalmanFitter::m_doReFitFromPRD
Gaudi::Property< bool > m_doReFitFromPRD
Definition: KalmanFitter.h:224
ActsTrk::KalmanFitter::m_logger
std::unique_ptr< const Acts::Logger > m_logger
logging instance
Definition: KalmanFitter.h:219
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
xAOD::UncalibratedMeasurement_v1
Definition: UncalibratedMeasurement_v1.h:13
ActsTrk::makeATLASUncalibSourceLink
ATLASUncalibSourceLink makeATLASUncalibSourceLink(const xAOD::UncalibratedMeasurementContainer *container, std::size_t index, [[maybe_unused]] const EventContext &ctx)
Definition: ATLASSourceLink.h:30
Generate_dsid_ranseed.seed
seed
Definition: Generate_dsid_ranseed.py:10
ActsTrk::detail::OnTrackCalibrator::calibrate
void calibrate(const Acts::GeometryContext &geoctx, const Acts::CalibrationContext &cctx, const Acts::SourceLink &link, TrackStateProxy state) const
lumiFormat.i
int i
Definition: lumiFormat.py:85
ActsTrk::KalmanFitter::m_calibrator
std::unique_ptr< TrkMeasurementCalibrator > m_calibrator
Definition: KalmanFitter.h:199
beamspotman.n
n
Definition: beamspotman.py:731
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
Trk::numberOfPixelDeadSensors
@ numberOfPixelDeadSensors
number of pixel hits with broad errors (width/sqrt(12))
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:65
master.flag
bool flag
Definition: master.py:29
ActsTrk::KalmanFitter::m_ROTcreator
ToolHandle< Trk::IRIO_OnTrackCreator > m_ROTcreator
Definition: KalmanFitter.h:222
plotIsoValidation.el
el
Definition: plotIsoValidation.py:197
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
ActsTrk::KalmanFitter::m_option_ReverseFilteringPt
Gaudi::Property< double > m_option_ReverseFilteringPt
Definition: KalmanFitter.h:192
InDet::SCT_Cluster
Definition: InnerDetector/InDetRecEvent/InDetPrepRawData/InDetPrepRawData/SCT_Cluster.h:34
ActsTrk::KalmanFitter::m_kfExtensions
Acts::KalmanFitterExtensions< ActsTrk::MutableTrackStateBackend > m_kfExtensions
Definition: KalmanFitter.h:208
ActsTrk::KalmanFitter::m_outlierFinder
ActsTrk::detail::FitterHelperFunctions::ATLASOutlierFinder m_outlierFinder
Definition: KalmanFitter.h:210
Trk::numberOfPixelHoles
@ numberOfPixelHoles
number of pixels which have a ganged ambiguity.
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:59
Trk::PrepRawData
Definition: PrepRawData.h:62
Trk::Track::trackParameters
const DataVector< const TrackParameters > * trackParameters() const
Return a pointer to a vector of TrackParameters.
Definition: Tracking/TrkEvent/TrkTrack/src/Track.cxx:97
Trk::Track::perigeeParameters
const Perigee * perigeeParameters() const
return Perigee.
Definition: Tracking/TrkEvent/TrkTrack/src/Track.cxx:163
xAOD::KalmanFitter
@ KalmanFitter
tracks produced by the Kalman Fitter
Definition: TrackingPrimitives.h:47
Trk::TrackStateOnSurface
represents the track state (measurement, material, fit parameters and quality) at a surface.
Definition: TrackStateOnSurface.h:71
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
ActsTrk::KalmanFitter::m_ATLASConverterTool
ToolHandle< ActsTrk::IActsToTrkConverterTool > m_ATLASConverterTool
Definition: KalmanFitter.h:183
ActsTrk::KalmanFitter::m_trkSummaryTool
ToolHandle< Trk::IExtendedTrackSummaryTool > m_trkSummaryTool
Definition: KalmanFitter.h:184
ActsTrk::getUncalibratedMeasurement
const xAOD::UncalibratedMeasurement & getUncalibratedMeasurement(const ATLASUncalibSourceLink &source_link)
Definition: ATLASSourceLink.h:26
Trk::TrackInfo::dumpInfo
std::string dumpInfo() const
Returns a string with the name of the fitter of this track (i.e.
Definition: Tracking/TrkEvent/TrkTrack/src/TrackInfo.cxx:45
ActsTrk::KalmanFitter::m_fitter
std::unique_ptr< Fitter > m_fitter
Definition: KalmanFitter.h:203
xAOD::ParticleHypothesis
ParticleHypothesis
Definition: TrackingPrimitives.h:192
InDet::PixelCluster
Definition: InnerDetector/InDetRecEvent/InDetPrepRawData/InDetPrepRawData/PixelCluster.h:49
Trk::Track::measurementsOnTrack
const DataVector< const MeasurementBase > * measurementsOnTrack() const
return a pointer to a vector of MeasurementBase (NOT including any that come from outliers).
Definition: Tracking/TrkEvent/TrkTrack/src/Track.cxx:178
Trk::pixelCluster
@ pixelCluster
Definition: MeasurementType.h:22
ActsTrk::KalmanFitter::m_option_outlierChi2Cut
Gaudi::Property< double > m_option_outlierChi2Cut
Definition: KalmanFitter.h:190
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
Trk::Track::trackSummary
const Trk::TrackSummary * trackSummary() const
Returns a pointer to the const Trk::TrackSummary owned by this const track (could be nullptr)
ActsTrk::detail::FitterHelperFunctions::ATLASOutlierFinder::StateChiSquaredPerNumberDoFCut
double StateChiSquaredPerNumberDoFCut
Definition: FitterHelperFunctions.h:50
if
if(febId1==febId2)
Definition: LArRodBlockPhysicsV0.cxx:567
Trk::Track::setTrackSummary
void setTrackSummary(std::unique_ptr< Trk::TrackSummary > input)
Set the track summary.
ActsTrk::KalmanFitter::logger
const Acts::Logger & logger() const
Private access to the logger.
Definition: KalmanFitter.h:214
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
ActsTrk::ATLASUncalibSourceLinkSurfaceAccessor
Definition: ATLASSourceLinkSurfaceAccessor.h:26
Trk::loc1
@ loc1
Definition: ParamDefs.h:34
ActsTrk::MutableTrackContainer
Definition: TrackContainer.h:122
ActsTrk::KalmanFitter::makeTrack
std::unique_ptr< Trk::Track > makeTrack(const EventContext &ctx, Acts::GeometryContext &tgContext, ActsTrk::MutableTrackContainer &tracks, Acts::Result< ActsTrk::MutableTrackContainer::TrackProxy, std::error_code > &fitResult, bool SourceLinkType=false) const
Definition: KalmanFitter.cxx:695
ActsTrk::detail::OnTrackCalibrator::NoCalibration
static OnTrackCalibrator NoCalibration(const Acts::TrackingGeometry &trackingGeometry, const ActsTrk::DetectorElementToActsGeometryIdMap &detectorElementToGeoId)
ActsTrk::KalmanFitter::fit
virtual std::unique_ptr< Trk::Track > fit(const EventContext &ctx, const Trk::Track &, const Trk::RunOutlierRemoval runOutlier=false, const Trk::ParticleHypothesis matEffects=Trk::nonInteracting) const override
refit a track
Definition: KalmanFitter.cxx:227