CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
KalmanSmoothedVertexChi2Estimator< N > Class Template Reference

#include <KalmanSmoothedVertexChi2Estimator.h>

Inheritance diagram for KalmanSmoothedVertexChi2Estimator< N >:
VertexSmoothedChiSquaredEstimator< N >

Public Types

typedef std::pair< bool, double > BDpair
 
- Public Types inherited from VertexSmoothedChiSquaredEstimator< N >
typedef std::pair< bool, double > BDpair
 
typedef CachingVertex< N >::RefCountedVertexTrack RefCountedVertexTrack
 

Public Member Functions

KalmanSmoothedVertexChi2Estimatorclone () const override
 
BDpair estimate (const CachingVertex< N > &vertex) const override
 
 ~KalmanSmoothedVertexChi2Estimator () override
 
- Public Member Functions inherited from VertexSmoothedChiSquaredEstimator< N >
 VertexSmoothedChiSquaredEstimator ()
 
virtual ~VertexSmoothedChiSquaredEstimator ()
 

Private Attributes

KVFHelper< Nhelper
 

Detailed Description

template<unsigned int N>
class KalmanSmoothedVertexChi2Estimator< N >

Class to calculate the smoothed chi**2 of the vertex using the Kalman filter algorithms after the vertex has been fit and the tracks refit.

Definition at line 14 of file KalmanSmoothedVertexChi2Estimator.h.

Member Typedef Documentation

◆ BDpair

template<unsigned int N>
typedef std::pair<bool, double> KalmanSmoothedVertexChi2Estimator< N >::BDpair

Definition at line 16 of file KalmanSmoothedVertexChi2Estimator.h.

Constructor & Destructor Documentation

◆ ~KalmanSmoothedVertexChi2Estimator()

template<unsigned int N>
KalmanSmoothedVertexChi2Estimator< N >::~KalmanSmoothedVertexChi2Estimator ( )
inlineoverride

Definition at line 18 of file KalmanSmoothedVertexChi2Estimator.h.

18 {}

Member Function Documentation

◆ clone()

template<unsigned int N>
KalmanSmoothedVertexChi2Estimator* KalmanSmoothedVertexChi2Estimator< N >::clone ( void  ) const
inlineoverridevirtual

Implements VertexSmoothedChiSquaredEstimator< N >.

Definition at line 27 of file KalmanSmoothedVertexChi2Estimator.h.

27 { return new KalmanSmoothedVertexChi2Estimator(*this); }

◆ estimate()

template<unsigned int N>
KalmanSmoothedVertexChi2Estimator< N >::BDpair KalmanSmoothedVertexChi2Estimator< N >::estimate ( const CachingVertex< N > &  vertex) const
overridevirtual

Methode which calculates the smoothed vertex chi**2.

Parameters
vertexis the final estimate of the vertex, with the refited tracks
Returns
the smoothed vertex chi**2

Implements VertexSmoothedChiSquaredEstimator< N >.

Definition at line 5 of file KalmanSmoothedVertexChi2Estimator.cc.

6  {
7  //initial vertex part
8  float v_part = 0.;
9  float returnChi = 0.;
10 
11  if (vertex.hasPrior()) {
12  v_part = helper.vertexChi2(vertex.priorVertexState(), vertex.vertexState());
13  }
14 
15  //vector of tracks part
17  std::vector<RefCountedVertexTrack> tracks = vertex.tracks();
18  float sum = 0.;
19  bool success = true;
20  for (typename std::vector<RefCountedVertexTrack>::iterator i = tracks.begin(); i != tracks.end(); i++) {
21  BDpair result = helper.trackParameterChi2((*i)->linearizedTrack(), (*i)->refittedState());
22  success = success && result.first;
23  sum += (*i)->weight() * result.second;
24  }
25  returnChi = v_part + sum;
26  return BDpair(success, returnChi);
27 }

Member Data Documentation

◆ helper

template<unsigned int N>
KVFHelper<N> KalmanSmoothedVertexChi2Estimator< N >::helper
private

Definition at line 30 of file KalmanSmoothedVertexChi2Estimator.h.

mps_fire.i
i
Definition: mps_fire.py:428
ReferenceCountingPointer
Definition: ReferenceCounted.h:60
KalmanSmoothedVertexChi2Estimator
Definition: KalmanSmoothedVertexChi2Estimator.h:14
summarizeEdmComparisonLogfiles.success
success
Definition: summarizeEdmComparisonLogfiles.py:115
VertexSmoothedChiSquaredEstimator::RefCountedVertexTrack
CachingVertex< N >::RefCountedVertexTrack RefCountedVertexTrack
Definition: VertexSmoothedChiSquaredEstimator.h:16
bphysicsOniaDQM_cfi.vertex
vertex
Definition: bphysicsOniaDQM_cfi.py:7
tracks
const uint32_t *__restrict__ const HitContainer *__restrict__ TkSoA *__restrict__ tracks
Definition: CAHitNtupletGeneratorKernelsImpl.h:159
helper
Definition: helper.py:1
KalmanSmoothedVertexChi2Estimator::BDpair
std::pair< bool, double > BDpair
Definition: KalmanSmoothedVertexChi2Estimator.h:16
mps_fire.result
result
Definition: mps_fire.py:311