CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes
BaseCkfTrajectoryBuilder Class Referenceabstract

#include <BaseCkfTrajectoryBuilder.h>

Inheritance diagram for BaseCkfTrajectoryBuilder:
TrajectoryBuilder CkfTrajectoryBuilder GroupedCkfTrajectoryBuilder HICTrajectoryBuilder CkfDebugTrajectoryBuilder MuonCkfTrajectoryBuilder

Public Types

typedef std::vector
< TempTrajectory
TempTrajectoryContainer
 
typedef std::vector< TrajectoryTrajectoryContainer
 
typedef
TrajectoryContainer::iterator 
TrajectoryIterator
 
- Public Types inherited from TrajectoryBuilder
typedef std::vector< TrajectoryTrajectoryContainer
 
typedef
TrajectoryContainer::iterator 
TrajectoryIterator
 

Public Member Functions

 BaseCkfTrajectoryBuilder (const edm::ParameterSet &conf, const TrajectoryStateUpdator *updator, const Propagator *propagatorAlong, const Propagator *propagatorOpposite, const Chi2MeasurementEstimatorBase *estimator, const TransientTrackingRecHitBuilder *RecHitBuilder, const MeasurementTracker *measurementTracker, const TrajectoryFilter *filter, const TrajectoryFilter *inOutFilter=0)
 
virtual void setDebugger (CkfDebugger *dbg) const
 
virtual void setEvent (const edm::Event &event) const
 
virtual TrajectoryContainer trajectories (const TrajectorySeed &) const =0
 
virtual void unset () const
 
virtual ~BaseCkfTrajectoryBuilder ()
 
- Public Member Functions inherited from TrajectoryBuilder
virtual void rebuildSeedingRegion (const TrajectorySeed &, TrajectoryContainer &result) const
 
virtual void trajectories (const TrajectorySeed &seed, TrajectoryContainer &out) const
 
virtual ~TrajectoryBuilder ()
 

Protected Types

typedef FreeTrajectoryState FTS
 
typedef std::pair< TSOS,
std::vector< const DetLayer * > > 
StateAndLayers
 
typedef TrajectoryMeasurement TM
 
typedef TrajectoryStateOnSurface TSOS
 

Protected Member Functions

void addToResult (TempTrajectory &traj, TrajectoryContainer &result, bool inOut=false) const
 
void addToResult (TempTrajectory &traj, TempTrajectoryContainer &result, bool inOut=false) const
 
virtual bool analyzeMeasurementsDebugger (Trajectory &traj, std::vector< TrajectoryMeasurement > meas, const MeasurementTracker *theMeasurementTracker, const Propagator *theForwardPropagator, const Chi2MeasurementEstimatorBase *theEstimator, const TransientTrackingRecHitBuilder *theTTRHBuilder) const
 
virtual bool analyzeMeasurementsDebugger (TempTrajectory &traj, std::vector< TrajectoryMeasurement > meas, const MeasurementTracker *theMeasurementTracker, const Propagator *theForwardPropagator, const Chi2MeasurementEstimatorBase *theEstimator, const TransientTrackingRecHitBuilder *theTTRHBuilder) const
 
TempTrajectory createStartingTrajectory (const TrajectorySeed &seed) const
 
virtual void fillSeedHistoDebugger (std::vector< TrajectoryMeasurement >::iterator begin, std::vector< TrajectoryMeasurement >::iterator end) const
 
StateAndLayers findStateAndLayers (const TempTrajectory &traj) const
 
bool qualityFilter (const TempTrajectory &traj, bool inOut=false) const
 
bool toBeContinued (TempTrajectory &traj, bool inOut=false) const
 

Protected Attributes

const PropagatortheBackwardPropagator
 
const
Chi2MeasurementEstimatorBase
theEstimator
 
const PropagatortheForwardPropagator
 
const LayerMeasurementstheLayerMeasurements
 
const MeasurementTrackertheMeasurementTracker
 
const PropagatorthePropagatorAlong
 
const PropagatorthePropagatorOpposite
 
const
TransientTrackingRecHitBuilder
theTTRHBuilder
 
const TrajectoryStateUpdatortheUpdator
 

Private Member Functions

void seedMeasurements (const TrajectorySeed &seed, std::vector< TrajectoryMeasurement > &result) const
 

Private Attributes

edm::InputTag clustersToSkip_
 
bool skipClusters_
 
const TrajectoryFiltertheFilter
 
const TrajectoryFiltertheInOutFilter
 

Detailed Description

The component of track reconstruction that, strating from a seed, reconstructs all possible trajectories. The resulting trajectories may be mutually exclusive and require cleaning by a TrajectoryCleaner. The Trajectories are normally not smoothed.

Definition at line 43 of file BaseCkfTrajectoryBuilder.h.

Member Typedef Documentation

Definition at line 46 of file BaseCkfTrajectoryBuilder.h.

typedef std::pair<TSOS,std::vector<const DetLayer*> > BaseCkfTrajectoryBuilder::StateAndLayers
protected

Definition at line 49 of file BaseCkfTrajectoryBuilder.h.

Definition at line 54 of file BaseCkfTrajectoryBuilder.h.

Definition at line 48 of file BaseCkfTrajectoryBuilder.h.

Definition at line 53 of file BaseCkfTrajectoryBuilder.h.

typedef TrajectoryContainer::iterator BaseCkfTrajectoryBuilder::TrajectoryIterator

Definition at line 55 of file BaseCkfTrajectoryBuilder.h.

Definition at line 47 of file BaseCkfTrajectoryBuilder.h.

Constructor & Destructor Documentation

BaseCkfTrajectoryBuilder::BaseCkfTrajectoryBuilder ( const edm::ParameterSet conf,
const TrajectoryStateUpdator updator,
const Propagator propagatorAlong,
const Propagator propagatorOpposite,
const Chi2MeasurementEstimatorBase estimator,
const TransientTrackingRecHitBuilder RecHitBuilder,
const MeasurementTracker measurementTracker,
const TrajectoryFilter filter,
const TrajectoryFilter inOutFilter = 0 
)

Definition at line 24 of file BaseCkfTrajectoryBuilder.cc.

References clustersToSkip_, edm::ParameterSet::exists(), edm::ParameterSet::getParameter(), and skipClusters_.

32  :
33  theUpdator(updator),
34  thePropagatorAlong(propagatorAlong),thePropagatorOpposite(propagatorOpposite),
35  theEstimator(estimator),theTTRHBuilder(recHitBuilder),
36  theMeasurementTracker(measurementTracker),
39  theFilter(filter),
40  theInOutFilter(inOutFilter)
41 {
42  if (conf.exists("clustersToSkip")){
43  skipClusters_=true;
44  clustersToSkip_=conf.getParameter<edm::InputTag>("clustersToSkip");
45  }
46  else
47  skipClusters_=false;
48 }
T getParameter(std::string const &) const
const Propagator * theBackwardPropagator
bool exists(std::string const &parameterName) const
checks if a parameter exists
const TrajectoryStateUpdator * theUpdator
const TrajectoryFilter * theFilter
const LayerMeasurements * theLayerMeasurements
const TransientTrackingRecHitBuilder * theTTRHBuilder
const MeasurementTracker * theMeasurementTracker
const Propagator * thePropagatorOpposite
const TrajectoryFilter * theInOutFilter
const Chi2MeasurementEstimatorBase * theEstimator
const Propagator * theForwardPropagator
BaseCkfTrajectoryBuilder::~BaseCkfTrajectoryBuilder ( )
virtual

Definition at line 50 of file BaseCkfTrajectoryBuilder.cc.

References theLayerMeasurements.

50  {
51  delete theLayerMeasurements;
52 }
const LayerMeasurements * theLayerMeasurements

Member Function Documentation

void BaseCkfTrajectoryBuilder::addToResult ( TempTrajectory traj,
TrajectoryContainer result,
bool  inOut = false 
) const
protected

Definition at line 166 of file BaseCkfTrajectoryBuilder.cc.

References Trajectory::empty(), Trajectory::foundHits(), Trajectory::lastMeasurement(), LogDebug, Trajectory::lostHits(), Trajectory::measurements(), TempTrajectory::measurements(), Trajectory::pop(), qualityFilter(), TrajectoryMeasurement::recHit(), cmsutils::bqueue< T >::size(), and TempTrajectory::toTrajectory().

Referenced by GroupedCkfTrajectoryBuilder::advanceOneLayer(), and CkfTrajectoryBuilder::limitedCandidates().

169 {
170  // quality check
171  if ( !qualityFilter(tmptraj, inOut) ) return;
172  Trajectory traj = tmptraj.toTrajectory();
173  // discard latest dummy measurements
174  while (!traj.empty() && !traj.lastMeasurement().recHit()->isValid()) traj.pop();
175  LogDebug("CkfPattern")<<inOut<<"=inOut option. pushing a Trajectory with: "<<traj.foundHits()<<" found hits. "<<traj.lostHits()
176  <<" lost hits. Popped :"<<(tmptraj.measurements().size())-(traj.measurements().size())<<" hits.";
177  result.push_back( traj);
178 }
#define LogDebug(id)
bool empty() const
True if trajectory has no measurements.
Definition: Trajectory.h:234
int foundHits() const
Definition: Trajectory.h:224
int lostHits() const
Definition: Trajectory.h:231
ConstRecHitPointer recHit() const
bool qualityFilter(const TempTrajectory &traj, bool inOut=false) const
DataContainer const & measurements() const
Definition: Trajectory.h:203
Trajectory toTrajectory() const
Convert to a standard Trajectory.
TrajectoryMeasurement const & lastMeasurement() const
Definition: Trajectory.h:181
tuple result
Definition: query.py:137
void pop()
Definition: Trajectory.cc:17
void BaseCkfTrajectoryBuilder::addToResult ( TempTrajectory traj,
TempTrajectoryContainer result,
bool  inOut = false 
) const
protected

Definition at line 180 of file BaseCkfTrajectoryBuilder.cc.

References TempTrajectory::empty(), TempTrajectory::foundHits(), TempTrajectory::lastMeasurement(), LogDebug, TempTrajectory::lostHits(), TempTrajectory::measurements(), TempTrajectory::pop(), qualityFilter(), TrajectoryMeasurement::recHit(), and cmsutils::bqueue< T >::size().

183 {
184  // quality check
185  if ( !qualityFilter(tmptraj, inOut) ) return;
186  // discard latest dummy measurements
187  TempTrajectory traj = tmptraj;
188  while (!traj.empty() && !traj.lastMeasurement().recHit()->isValid()) traj.pop();
189  LogDebug("CkfPattern")<<inOut<<"=inOut option. pushing a TempTrajectory with: "<<traj.foundHits()<<" found hits. "<<traj.lostHits()
190  <<" lost hits. Popped :"<<(tmptraj.measurements().size())-(traj.measurements().size())<<" hits.";
191  result.push_back( traj );
192 }
#define LogDebug(id)
bool empty() const
True if trajectory has no measurements.
const DataContainer & measurements() const
ConstRecHitPointer recHit() const
int foundHits() const
obsolete name, use measurements() instead.
const TrajectoryMeasurement & lastMeasurement() const
bool qualityFilter(const TempTrajectory &traj, bool inOut=false) const
tuple result
Definition: query.py:137
size_type size() const
Definition: bqueue.h:146
int lostHits() const
virtual bool BaseCkfTrajectoryBuilder::analyzeMeasurementsDebugger ( Trajectory traj,
std::vector< TrajectoryMeasurement meas,
const MeasurementTracker theMeasurementTracker,
const Propagator theForwardPropagator,
const Chi2MeasurementEstimatorBase theEstimator,
const TransientTrackingRecHitBuilder theTTRHBuilder 
) const
inlineprotectedvirtual

Maximum number of lost hits per trajectory candidate. Maximum number of consecutive lost hits per trajectory candidate.

Reimplemented in CkfDebugTrajectoryBuilder.

Definition at line 84 of file BaseCkfTrajectoryBuilder.h.

Referenced by CkfTrajectoryBuilder::limitedCandidates().

88  {return true;}
virtual bool BaseCkfTrajectoryBuilder::analyzeMeasurementsDebugger ( TempTrajectory traj,
std::vector< TrajectoryMeasurement meas,
const MeasurementTracker theMeasurementTracker,
const Propagator theForwardPropagator,
const Chi2MeasurementEstimatorBase theEstimator,
const TransientTrackingRecHitBuilder theTTRHBuilder 
) const
inlineprotectedvirtual

Reimplemented in CkfDebugTrajectoryBuilder.

Definition at line 89 of file BaseCkfTrajectoryBuilder.h.

93  {return true;}
TempTrajectory BaseCkfTrajectoryBuilder::createStartingTrajectory ( const TrajectorySeed seed) const
protected

Definition at line 106 of file BaseCkfTrajectoryBuilder.cc.

References alongMomentum, TrajectorySeed::direction(), PrintoutHelper::dumpCandidate(), i, LogDebug, query::result, seedMeasurements(), theBackwardPropagator, and theForwardPropagator.

Referenced by GroupedCkfTrajectoryBuilder::buildTrajectories(), GroupedCkfTrajectoryBuilder::rebuildSeedingRegion(), and CkfTrajectoryBuilder::trajectories().

107 {
108  TempTrajectory result( seed, seed.direction());
109  if ( seed.direction() == alongMomentum) {
110  theForwardPropagator = &(*thePropagatorAlong);
111  theBackwardPropagator = &(*thePropagatorOpposite);
112  }
113  else {
114  theForwardPropagator = &(*thePropagatorOpposite);
115  theBackwardPropagator = &(*thePropagatorAlong);
116  }
117 
118  std::vector<TM> seedMeas;
119  seedMeasurements(seed, seedMeas);
120  for (std::vector<TM>::const_iterator i=seedMeas.begin(); i!=seedMeas.end(); i++)
121  result.push(*i);
122 
123  LogDebug("CkfPattern")
124  <<" initial trajectory from the seed: "<<PrintoutHelper::dumpCandidate(result,true);
125 
126  return result;
127 }
#define LogDebug(id)
PropagationDirection direction() const
int i
Definition: DBlmapReader.cc:9
const Propagator * theBackwardPropagator
void seedMeasurements(const TrajectorySeed &seed, std::vector< TrajectoryMeasurement > &result) const
tuple result
Definition: query.py:137
static std::string dumpCandidate(const Candidate &candidate, bool showErrors=false)
const Propagator * theForwardPropagator
virtual void BaseCkfTrajectoryBuilder::fillSeedHistoDebugger ( std::vector< TrajectoryMeasurement >::iterator  begin,
std::vector< TrajectoryMeasurement >::iterator  end 
) const
inlineprotectedvirtual

Reimplemented in CkfDebugTrajectoryBuilder.

Definition at line 94 of file BaseCkfTrajectoryBuilder.h.

Referenced by seedMeasurements().

95  {;}
BaseCkfTrajectoryBuilder::StateAndLayers BaseCkfTrajectoryBuilder::findStateAndLayers ( const TempTrajectory traj) const
protected

Definition at line 197 of file BaseCkfTrajectoryBuilder.cc.

References PTrajectoryStateOnDet::detId(), GeometricSearchTracker::detLayer(), TempTrajectory::direction(), TempTrajectory::empty(), TrajectoryStateOnSurface::freeState(), g, MeasurementTracker::geometricSearchTracker(), MeasurementTracker::geomTracker(), errorMatrix2Lands_multiChannel::id, TrackingGeometry::idToDet(), TempTrajectory::lastLayer(), TempTrajectory::lastMeasurement(), Propagator::magneticField(), DetLayer::nextLayers(), TempTrajectory::seed(), TrajectorySeed::startingState(), theForwardPropagator, theMeasurementTracker, trajectoryStateTransform::transientState(), and TrajectoryMeasurement::updatedState().

Referenced by GroupedCkfTrajectoryBuilder::advanceOneLayer(), and CkfTrajectoryBuilder::findCompatibleMeasurements().

198 {
199  if (traj.empty())
200  {
201  //set the currentState to be the one from the trajectory seed starting point
202  PTrajectoryStateOnDet ptod = traj.seed().startingState();
203  DetId id(ptod.detId());
205  const Surface * surface=&g->surface();
206 
207 
210  return StateAndLayers(currentState,lastLayer->nextLayers( *currentState.freeState(), traj.direction()) );
211  }
212  else
213  {
214  TSOS currentState = traj.lastMeasurement().updatedState();
215  return StateAndLayers(currentState,traj.lastLayer()->nextLayers( *currentState.freeState(), traj.direction()) );
216  }
217 }
const TrajectorySeed & seed() const
Access to the seed used to reconstruct the Trajectory.
bool empty() const
True if trajectory has no measurements.
virtual std::vector< const DetLayer * > nextLayers(NavigationDirection direction) const
Definition: DetLayer.cc:35
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e g
Definition: Activities.doc:4
const TrajectoryMeasurement & lastMeasurement() const
PropagationDirection direction() const
FreeTrajectoryState * freeState(bool withErrors=true) const
const DetLayer * detLayer(const DetId &id) const
obsolete method. Use idToLayer() instead.
const TrackingGeometry * geomTracker() const
unsigned int detId() const
TrajectoryStateOnSurface updatedState() const
Definition: DetId.h:20
const MeasurementTracker * theMeasurementTracker
PTrajectoryStateOnDet const & startingState() const
TrajectoryStateOnSurface transientState(const PTrajectoryStateOnDet &ts, const Surface *surface, const MagneticField *field)
virtual const GeomDet * idToDet(DetId) const =0
virtual const MagneticField * magneticField() const =0
std::pair< TSOS, std::vector< const DetLayer * > > StateAndLayers
const DetLayer * lastLayer() const
Redundant method, returns the layer of lastMeasurement() .
const GeometricSearchTracker * geometricSearchTracker() const
const Propagator * theForwardPropagator
bool BaseCkfTrajectoryBuilder::qualityFilter ( const TempTrajectory traj,
bool  inOut = false 
) const
protected

Called at end of track building, to see if track should be kept

Definition at line 152 of file BaseCkfTrajectoryBuilder.cc.

References TrajectoryFilter::qualityFilter(), theFilter, and theInOutFilter.

Referenced by addToResult(), and CkfTrajectoryBuilder::limitedCandidates().

153 {
154  // Called after building a trajectory is completed, to see if it is good enough
155  // to keep.
156  if (inOut) {
157  if (theInOutFilter == 0) edm::LogError("CkfPattern") << "CkfTrajectoryBuilder error: trying to use dedicated filter for in-out tracking phase, when none specified";
158  return theInOutFilter->qualityFilter(traj);
159  } else {
160  return theFilter->qualityFilter(traj);
161  }
162 }
const TrajectoryFilter * theFilter
virtual bool qualityFilter(const TempTrajectory &) const =0
const TrajectoryFilter * theInOutFilter
void BaseCkfTrajectoryBuilder::seedMeasurements ( const TrajectorySeed seed,
std::vector< TrajectoryMeasurement > &  result 
) const
private

Definition at line 56 of file BaseCkfTrajectoryBuilder.cc.

References TransientTrackingRecHitBuilder::build(), GeometricSearchTracker::detLayer(), fillSeedHistoDebugger(), MeasurementTracker::geometricSearchTracker(), MeasurementTracker::geomTracker(), TrackingGeometry::idToDet(), Propagator::magneticField(), Propagator::propagate(), TrajectorySeed::recHits(), TrajectorySeed::startingState(), GeomDet::surface(), theBackwardPropagator, theForwardPropagator, theMeasurementTracker, theTTRHBuilder, theUpdator, trajectoryStateTransform::transientState(), and TrajectoryStateUpdator::update().

Referenced by createStartingTrajectory().

57 {
58 
59 
60  TrajectorySeed::range hitRange = seed.recHits();
61  for (TrajectorySeed::const_iterator ihit = hitRange.first;
62  ihit != hitRange.second; ihit++) {
64  const GeomDet* hitGeomDet =
65  theMeasurementTracker->geomTracker()->idToDet( ihit->geographicalId());
66 
67  const DetLayer* hitLayer =
68  theMeasurementTracker->geometricSearchTracker()->detLayer(ihit->geographicalId());
69 
70  TSOS invalidState( new BasicSingleTrajectoryState( hitGeomDet->surface()));
71  if (ihit == hitRange.second - 1) {
72  // the seed trajectory state should correspond to this hit
73  PTrajectoryStateOnDet pState( seed.startingState());
74  const GeomDet* gdet = theMeasurementTracker->geomTracker()->idToDet( DetId(pState.detId()));
75  if (&gdet->surface() != &hitGeomDet->surface()) {
76  edm::LogError("CkfPattern") << "CkfTrajectoryBuilder error: the seed state is not on the surface of the detector of the last seed hit";
77  return; // FIXME: should throw exception
78  }
79 
80  TSOS updatedState = trajectoryStateTransform::transientState( pState, &(gdet->surface()),
82  result.push_back(TM( invalidState, updatedState, recHit, 0, hitLayer));
83  }
84  else {
85  PTrajectoryStateOnDet pState( seed.startingState());
86 
89  (hitRange.second - 1)->geographicalId()))->surface()),
91  TSOS innerState = theBackwardPropagator->propagate(outerState,hitGeomDet->surface());
92  if(innerState.isValid()) {
93  TSOS innerUpdated = theUpdator->update(innerState,*recHit);
94  result.push_back(TM( invalidState, innerUpdated, recHit, 0, hitLayer));
95  }
96  }
97  }
98 
99  // method for debugging
100  fillSeedHistoDebugger(result.begin(),result.end());
101 
102 }
const Propagator * theBackwardPropagator
virtual TrajectoryStateOnSurface update(const TrajectoryStateOnSurface &, const TransientTrackingRecHit &) const =0
const TrajectoryStateUpdator * theUpdator
recHitContainer::const_iterator const_iterator
virtual RecHitPointer build(const TrackingRecHit *p) const =0
build a tracking rechit from an existing rechit
const TransientTrackingRecHitBuilder * theTTRHBuilder
tuple result
Definition: query.py:137
const DetLayer * detLayer(const DetId &id) const
obsolete method. Use idToLayer() instead.
std::pair< const_iterator, const_iterator > range
const TrackingGeometry * geomTracker() const
virtual TrajectoryStateOnSurface propagate(const FreeTrajectoryState &, const Surface &) const
Definition: Propagator.cc:12
Definition: DetId.h:20
const MeasurementTracker * theMeasurementTracker
PTrajectoryStateOnDet const & startingState() const
TrajectoryStateOnSurface transientState(const PTrajectoryStateOnDet &ts, const Surface *surface, const MagneticField *field)
virtual const GeomDet * idToDet(DetId) const =0
range recHits() const
virtual const MagneticField * magneticField() const =0
const BoundPlane & surface() const
The nominal surface of the GeomDet.
Definition: GeomDet.h:35
const GeometricSearchTracker * geometricSearchTracker() const
virtual void fillSeedHistoDebugger(std::vector< TrajectoryMeasurement >::iterator begin, std::vector< TrajectoryMeasurement >::iterator end) const
const Propagator * theForwardPropagator
virtual void BaseCkfTrajectoryBuilder::setDebugger ( CkfDebugger dbg) const
inlinevirtual

Reimplemented in CkfDebugTrajectoryBuilder.

Definition at line 74 of file BaseCkfTrajectoryBuilder.h.

74 {;}
void BaseCkfTrajectoryBuilder::setEvent ( const edm::Event event) const
virtual

Implements TrajectoryBuilder.

Reimplemented in HICTrajectoryBuilder.

Definition at line 219 of file BaseCkfTrajectoryBuilder.cc.

References clustersToSkip_, MeasurementTracker::setClusterToSkip(), skipClusters_, theMeasurementTracker, and MeasurementTracker::update().

220  {
222  if (skipClusters_)
224  }
virtual void update(const edm::Event &) const =0
virtual void setClusterToSkip(const edm::InputTag &cluster, const edm::Event &event) const =0
const MeasurementTracker * theMeasurementTracker
bool BaseCkfTrajectoryBuilder::toBeContinued ( TempTrajectory traj,
bool  inOut = false 
) const
protected

Called after each new hit is added to the trajectory, to see if building this track should be continued

Definition at line 130 of file BaseCkfTrajectoryBuilder.cc.

References TempTrajectory::foundHits(), TempTrajectory::lastLayer(), TempTrajectory::lastMeasurement(), LogTrace, TempTrajectory::lostHits(), TempTrajectory::measurements(), TrajectoryMeasurement::predictedState(), cmsutils::bqueue< T >::size(), DetLayer::subDetector(), theFilter, theInOutFilter, and TrajectoryFilter::toBeContinued().

Referenced by GroupedCkfTrajectoryBuilder::advanceOneLayer(), and CkfTrajectoryBuilder::limitedCandidates().

131 {
132  if (traj.measurements().size() > 400) {
133  edm::LogError("BaseCkfTrajectoryBuilder_InfiniteLoop");
134  LogTrace("BaseCkfTrajectoryBuilder_InfiniteLoop") <<
135  "Cropping Track After 400 Measurements:\n" <<
136  " Last predicted state: " << traj.lastMeasurement().predictedState() << "\n" <<
137  " Last layer subdetector: " << (traj.lastLayer() ? traj.lastLayer()->subDetector() : -1) << "\n" <<
138  " Found hits: " << traj.foundHits() << ", lost hits: " << traj.lostHits() << "\n\n";
139  return false;
140  }
141  // Called after each new hit is added to the trajectory, to see if it is
142  // worth continuing to build this track candidate.
143  if (inOut) {
144  if (theInOutFilter == 0) edm::LogError("CkfPattern") << "CkfTrajectoryBuilder error: trying to use dedicated filter for in-out tracking phase, when none specified";
145  return theInOutFilter->toBeContinued(traj);
146  } else {
147  return theFilter->toBeContinued(traj);
148  }
149 }
const DataContainer & measurements() const
virtual SubDetector subDetector() const =0
The type of detector (PixelBarrel, PixelEndcap, TIB, TOB, TID, TEC, CSC, DT, RPCBarrel, RPCEndcap)
int foundHits() const
obsolete name, use measurements() instead.
const TrajectoryFilter * theFilter
const TrajectoryMeasurement & lastMeasurement() const
TrajectoryStateOnSurface predictedState() const
#define LogTrace(id)
virtual bool toBeContinued(TempTrajectory &) const =0
size_type size() const
Definition: bqueue.h:146
const TrajectoryFilter * theInOutFilter
const DetLayer * lastLayer() const
Redundant method, returns the layer of lastMeasurement() .
int lostHits() const
virtual TrajectoryContainer BaseCkfTrajectoryBuilder::trajectories ( const TrajectorySeed ) const
pure virtual
void BaseCkfTrajectoryBuilder::unset ( ) const
virtual

Reimplemented from TrajectoryBuilder.

Definition at line 226 of file BaseCkfTrajectoryBuilder.cc.

References skipClusters_, theMeasurementTracker, and MeasurementTracker::unsetClusterToSkip().

227 {
228  if (skipClusters_)
230 }
virtual void unsetClusterToSkip() const =0
const MeasurementTracker * theMeasurementTracker

Member Data Documentation

edm::InputTag BaseCkfTrajectoryBuilder::clustersToSkip_
private

Definition at line 145 of file BaseCkfTrajectoryBuilder.h.

Referenced by BaseCkfTrajectoryBuilder(), and setEvent().

bool BaseCkfTrajectoryBuilder::skipClusters_
private

Filter used at end of in-out tracking

Definition at line 144 of file BaseCkfTrajectoryBuilder.h.

Referenced by BaseCkfTrajectoryBuilder(), setEvent(), and unset().

const Propagator* BaseCkfTrajectoryBuilder::theBackwardPropagator
mutableprotected
const Chi2MeasurementEstimatorBase* BaseCkfTrajectoryBuilder::theEstimator
protected
const TrajectoryFilter* BaseCkfTrajectoryBuilder::theFilter
private

Definition at line 141 of file BaseCkfTrajectoryBuilder.h.

Referenced by qualityFilter(), and toBeContinued().

const Propagator* BaseCkfTrajectoryBuilder::theForwardPropagator
mutableprotected
const TrajectoryFilter* BaseCkfTrajectoryBuilder::theInOutFilter
private

Filter used at end of complete tracking

Definition at line 142 of file BaseCkfTrajectoryBuilder.h.

Referenced by qualityFilter(), and toBeContinued().

const LayerMeasurements* BaseCkfTrajectoryBuilder::theLayerMeasurements
protected
const MeasurementTracker* BaseCkfTrajectoryBuilder::theMeasurementTracker
protected
const Propagator* BaseCkfTrajectoryBuilder::thePropagatorAlong
protected

Definition at line 121 of file BaseCkfTrajectoryBuilder.h.

const Propagator* BaseCkfTrajectoryBuilder::thePropagatorOpposite
protected

Definition at line 122 of file BaseCkfTrajectoryBuilder.h.

const TransientTrackingRecHitBuilder* BaseCkfTrajectoryBuilder::theTTRHBuilder
protected
const TrajectoryStateUpdator* BaseCkfTrajectoryBuilder::theUpdator
protected