CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
FallbackLinearizationPointFinder Class Reference

#include <FallbackLinearizationPointFinder.h>

Inheritance diagram for FallbackLinearizationPointFinder:
LinearizationPointFinder

Public Member Functions

FallbackLinearizationPointFinderclone () const override
 
 FallbackLinearizationPointFinder (const ModeFinder3d &m=HsmModeFinder3d())
 
GlobalPoint getLinearizationPoint (const std::vector< reco::TransientTrack > &) const override
 
GlobalPoint getLinearizationPoint (const std::vector< FreeTrajectoryState > &) const override
 
- Public Member Functions inherited from LinearizationPointFinder
virtual ~LinearizationPointFinder ()
 

Private Attributes

ModeFinder3dtheModeFinder
 

Detailed Description

A fallback linearization point finder that is used if the 'actual' CrossingPtBasedLinPtFinder fails. Computes the mode based on innermost states.

Definition at line 13 of file FallbackLinearizationPointFinder.h.

Constructor & Destructor Documentation

◆ FallbackLinearizationPointFinder()

FallbackLinearizationPointFinder::FallbackLinearizationPointFinder ( const ModeFinder3d m = HsmModeFinder3d())

Member Function Documentation

◆ clone()

FallbackLinearizationPointFinder* FallbackLinearizationPointFinder::clone ( ) const
inlineoverridevirtual

Clone method

Implements LinearizationPointFinder.

Definition at line 19 of file FallbackLinearizationPointFinder.h.

19 { return new FallbackLinearizationPointFinder(*this); };
FallbackLinearizationPointFinder(const ModeFinder3d &m=HsmModeFinder3d())

◆ getLinearizationPoint() [1/2]

GlobalPoint FallbackLinearizationPointFinder::getLinearizationPoint ( const std::vector< reco::TransientTrack > &  ) const
overridevirtual

Virtual method returning the Initial Linearization Point as an object of type GlobalPoint

Implements LinearizationPointFinder.

Definition at line 13 of file FallbackLinearizationPointFinder.cc.

References mps_fire::i, theModeFinder, createJobs::tmp, and DiMuonV_cfg::tracks.

Referenced by CrossingPtBasedLinearizationPointFinder::getLinearizationPoint(), CrossingPtBasedLinearizationPointFinder::useAllTracks(), and CrossingPtBasedLinearizationPointFinder::useFullMatrix().

14  {
15  switch (tracks.size()) {
16  case 0:
17  return GlobalPoint(0., 0., 0.);
18  case 1:
19  return tracks.begin()->impactPointState().globalPosition();
20  default: {
21  std::vector<std::pair<GlobalPoint, float> > wtracks;
22  wtracks.reserve(tracks.size() - 1);
23  for (std::vector<reco::TransientTrack>::const_iterator i = tracks.begin(); i != tracks.end(); ++i) {
24  std::pair<GlobalPoint, float> tmp(i->impactPointState().globalPosition(), 1.);
25  wtracks.push_back(tmp);
26  }
27  return (*theModeFinder)(wtracks);
28  }
29  }
30  return GlobalPoint(0., 0., 0.);
31 }
Global3DPoint GlobalPoint
Definition: GlobalPoint.h:10
tmp
align.sh
Definition: createJobs.py:716

◆ getLinearizationPoint() [2/2]

GlobalPoint FallbackLinearizationPointFinder::getLinearizationPoint ( const std::vector< FreeTrajectoryState > &  tracks) const
overridevirtual

Reimplemented from LinearizationPointFinder.

Definition at line 8 of file FallbackLinearizationPointFinder.cc.

9  {
10  return GlobalPoint(0., 0., 0.);
11 }
Global3DPoint GlobalPoint
Definition: GlobalPoint.h:10

Member Data Documentation

◆ theModeFinder

ModeFinder3d* FallbackLinearizationPointFinder::theModeFinder
private

Definition at line 19 of file FallbackLinearizationPointFinder.h.

Referenced by getLinearizationPoint().