#include <RecoTracker/SingleTrackPattern/interface/CosmicTrackFinder.h>
Public Member Functions | |
void | AnalHits (std::vector< ConstReferenceCountingPointer< TransientTrackingRecHit > > hits) |
bool | operator() (Trajectory *t1, Trajectory *t2) |
Private Attributes | |
bool | ltib1 |
bool | ltib2 |
bool | ltob1 |
bool | ltob2 |
uint | nlay |
Definition at line 22 of file CosmicTrackFinder.h.
void cms::CompareTrajLay::AnalHits | ( | std::vector< ConstReferenceCountingPointer< TransientTrackingRecHit > > | hits | ) | [inline] |
Definition at line 37 of file CosmicTrackFinder.h.
References ltib1, ltib2, ltob1, ltob2, and nlay.
Referenced by operator()().
00037 { 00038 ltob1=false; ltob2=false; ltib1=false; ltib2=false; 00039 std::vector< ConstReferenceCountingPointer< TransientTrackingRecHit> >::const_iterator hit; 00040 // ConstRecHitIterator hit; 00041 for(hit=hits.begin();hit!=hits.end();hit++){ 00042 uint iid=(*hit)->hit()->geographicalId().rawId(); 00043 00044 int sub=(iid>>25)&0x7 ; 00045 int lay=(iid>>16) & 0xF; 00046 if ((lay==1)&&(sub==3)) ltib1=true; 00047 if ((lay==2)&&(sub==3)) ltib2=true; 00048 if ((lay==1)&&(sub==5)) ltob1=true; 00049 if ((lay==2)&&(sub==5)) ltob2=true; 00050 } 00051 nlay=ltib1+ltib2+ltob1+ltob2; 00052 00053 }
bool cms::CompareTrajLay::operator() | ( | Trajectory * | t1, | |
Trajectory * | t2 | |||
) | [inline] |
Definition at line 24 of file CosmicTrackFinder.h.
References AnalHits(), Trajectory::chiSquared(), Trajectory::foundHits(), nlay, and Trajectory::recHits().
00025 { 00026 AnalHits(t1->recHits()); 00027 uint alay=nlay; 00028 AnalHits(t2->recHits()); 00029 uint blay=nlay; 00030 if (alay!=blay) return alay > blay; 00031 if (t1->foundHits() != t2->foundHits()) 00032 return t1->foundHits()> t2->foundHits(); 00033 return t1->chiSquared()< t2->chiSquared(); 00034 // std::cout<<"chi "<<t1.chiSquared()<<" "<<t2.chiSquared()<<std::endl; 00035 // return false; 00036 }
bool cms::CompareTrajLay::ltib1 [private] |
bool cms::CompareTrajLay::ltib2 [private] |
bool cms::CompareTrajLay::ltob1 [private] |
bool cms::CompareTrajLay::ltob2 [private] |
uint cms::CompareTrajLay::nlay [private] |