CMS 3D CMS Logo

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

#include <GroupedTrajCandLess.h>

Public Member Functions

 GroupedTrajCandLess (float p=5, float b=0)
 
template<typename T >
bool operator() (const T &a, const T &b) const
 

Private Member Functions

template<typename T >
float looperPenalty (const T &t) const
 
template<typename T >
float score (const T &t) const
 

Private Attributes

float bonus
 
float penalty
 

Detailed Description

Defines an ordering of Trajectories in terms of "goodness" The comparison is done in terms of total chi**2 / ndf plus a penalty for "lost" hits.

Definition at line 13 of file GroupedTrajCandLess.h.

Constructor & Destructor Documentation

GroupedTrajCandLess::GroupedTrajCandLess ( float  p = 5,
float  b = 0 
)
inline

Member Function Documentation

template<typename T >
float GroupedTrajCandLess::looperPenalty ( const T t) const
inlineprivate

Definition at line 26 of file GroupedTrajCandLess.h.

References funct::cos(), and f.

26  {
27  return (t.dPhiCacheForLoopersReconstruction()==0) ? 0.f :
28  0.5f*(1.f-std::cos(t.dPhiCacheForLoopersReconstruction()))*penalty;
29  }
Cos< T >::type cos(const T &t)
Definition: Cos.h:22
double f[11][100]
template<typename T >
bool GroupedTrajCandLess::operator() ( const T a,
const T b 
) const
inline

Definition at line 20 of file GroupedTrajCandLess.h.

References offlineSlimmedPrimaryVertices_cfi::score.

20  {
21  return score(a) < score(b);
22  }
float score(const T &t) const
double b
Definition: hdecay.h:120
double a
Definition: hdecay.h:121
template<typename T >
float GroupedTrajCandLess::score ( const T t) const
inlineprivate

Definition at line 32 of file GroupedTrajCandLess.h.

References f.

33  {
34  auto bb = (t.dPhiCacheForLoopersReconstruction()==0 && t.foundHits()>8) ? 2*bonus : bonus; //extra bonus for long tracks not loopers
35  if ( t.lastMeasurement().updatedState().globalMomentum().perp2() < 0.81f ) bb*=0.5f;
36  return t.chiSquared()-t.foundHits()*bb+t.lostHits()*penalty
37  + looperPenalty(t);
38  }
double f[11][100]
float looperPenalty(const T &t) const

Member Data Documentation

float GroupedTrajCandLess::bonus
private

Definition at line 43 of file GroupedTrajCandLess.h.

float GroupedTrajCandLess::penalty
private

Definition at line 42 of file GroupedTrajCandLess.h.