CMS 3D CMS Logo

SequentialVertexFitter.h
Go to the documentation of this file.
1 #ifndef SequentialVertexFitter_H
2 #define SequentialVertexFitter_H
3 
12 #include <cmath>
13 // #include "TrackingTools/TransientTrack/interface/TransientTrack.h"
14 // #include "Vertex/VertexPrimitives/interface/VertexSeedFactory.h"
15 
34 template <unsigned int N>
36 
37 public:
38 
42 
43 
51  const VertexUpdator<N> & updator, const VertexSmoother<N> & smoother,
52  const AbstractLTSFactory<N> & ltsf);
53 
59  const LinearizationPointFinder & linP,
60  const VertexUpdator<N> & updator, const VertexSmoother<N> & smoother,
61  const AbstractLTSFactory<N> & ltsf);
62 
68 
69 
70  ~SequentialVertexFitter() override;
71 
72 
80 
81 
88 
96  CachingVertex<N> vertex(const std::vector<reco::TransientTrack> & tracks) const override;
97 
107  CachingVertex<N> vertex(const std::vector<RefCountedVertexTrack> & tracks) const override;
108 
112  CachingVertex<N> vertex(const std::vector<RefCountedVertexTrack> & tracks, const reco::BeamSpot & spot ) const override;
113 
114 
117  CachingVertex<N> vertex(const std::vector<reco::TransientTrack> & tracks,
118  const GlobalPoint& linPoint) const override;
119 
124  CachingVertex<N> vertex(const std::vector<reco::TransientTrack> & tracks,
125  const reco::BeamSpot& beamSpot) const override;
126 
127 
133  CachingVertex<N> vertex(const std::vector<reco::TransientTrack> & tracks,
134  const GlobalPoint& priorPos,
135  const GlobalError& priorError) const override;
136 
141  CachingVertex<N> vertex(const std::vector<RefCountedVertexTrack> & tracks,
142  const GlobalPoint& priorPos,
143  const GlobalError& priorError) const override;
144 
145 
146 
157 // virtual CachingVertex<N> vertex(const RefCountedVertexSeed seed) const;
158 
163  {return theLinP;}
164 
166  {return theUpdator;}
167 
169  {return theSmoother;}
170 
171  const float maxShift() const
172  {return theMaxShift;}
173 
174  const int maxStep() const
175  {return theMaxStep;}
176 
178  {return thePSet;}
179 
180  SequentialVertexFitter * clone() const override {
181  return new SequentialVertexFitter(* this);
182  }
183 
185  { return theLTrackFactory;}
186 
187 protected:
188 
194 
195 private:
196 
206  CachingVertex<N> fit(const std::vector<RefCountedVertexTrack> & tracks,
207  const VertexState priorVertex, bool withPrior) const;
208 
216  std::vector<RefCountedVertexTrack> linearizeTracks(const std::vector<reco::TransientTrack> & tracks,
217  const VertexState state) const;
218 
229  std::vector<RefCountedVertexTrack> reLinearizeTracks(
230  const std::vector<RefCountedVertexTrack> & tracks,
231  const VertexState state) const;
232 
233 
238  void readParameters();
239  void setDefaultParameters();
240 
244  inline bool hasNan(const GlobalPoint& point) const {
245  using namespace std;
246  return (edm::isNotFinite(point.x())|| edm::isNotFinite(point.y()) || edm::isNotFinite(point.z()));
247  }
248 
249 
250  float theMaxShift;
252 
258 // LinearizedTrackStateFactoryAbstractLTSFactory theLTrackFactory;
260 
261  // VertexSeedFactory theVSeedFactory;
262 };
263 
264 #endif
std::vector< RefCountedVertexTrack > reLinearizeTracks(const std::vector< RefCountedVertexTrack > &tracks, const VertexState state) const
LinearizationPointFinder * theLinP
constexpr bool isNotFinite(T x)
Definition: isFinite.h:9
const VertexUpdator< N > * vertexUpdator() const
CachingVertex< N > fit(const std::vector< RefCountedVertexTrack > &tracks, const VertexState priorVertex, bool withPrior) const
VertexUpdator< N > * theUpdator
VertexTrackFactory< N > theVTrackFactory
T y() const
Definition: PV3DBase.h:63
const AbstractLTSFactory< N > * theLTrackFactory
const AbstractLTSFactory< N > * linearizedTrackStateFactory() const
ReferenceCountingPointer< RefittedTrackState< N > > RefCountedRefittedTrackState
SequentialVertexFitter * clone() const override
ReferenceCountingPointer< VertexTrack< N > > RefCountedVertexTrack
const VertexSmoother< N > * vertexSmoother() const
void setMaximumNumberOfIterations(int maxIterations)
T z() const
Definition: PV3DBase.h:64
const edm::ParameterSet parameterSet() const
bool hasNan(const GlobalPoint &point) const
std::vector< RefCountedVertexTrack > linearizeTracks(const std::vector< reco::TransientTrack > &tracks, const VertexState state) const
T x() const
Definition: PV3DBase.h:62
ReferenceCountingPointer< LinearizedTrackState< N > > RefCountedLinearizedTrackState
const float maxShift() const
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point
Definition: invegas.h:5
VertexSmoother< N > * theSmoother
const LinearizationPointFinder * linearizationPointFinder() const
CachingVertex< N > vertex(const std::vector< reco::TransientTrack > &tracks) const override
void setMaximumDistance(float maxShift)