CMS 3D CMS Logo

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

#include <GroupedCkfTrajectoryBuilder.h>

Inheritance diagram for GroupedCkfTrajectoryBuilder:
BaseCkfTrajectoryBuilder TrajectoryBuilder

Public Member Functions

TempTrajectory buildTrajectories (const TrajectorySeed &seed, TrajectoryContainer &ret, const TrajectoryFilter *) const
 common part of both public trajectory building methods More...
 
double chiSquareCut ()
 
const
Chi2MeasurementEstimatorBase
estimator () const
 
 GroupedCkfTrajectoryBuilder (const edm::ParameterSet &conf, edm::ConsumesCollector &iC)
 constructor from ParameterSet More...
 
float lostHitPenalty ()
 
double mass ()
 Mass hypothesis used for propagation. More...
 
int maxCand ()
 
double ptCut ()
 Pt cut. More...
 
void rebuildSeedingRegion (const TrajectorySeed &, TrajectoryContainer &result) const
 
void rebuildTrajectories (TempTrajectory const &startingTraj, const TrajectorySeed &, TrajectoryContainer &result) const
 
TrajectoryContainer trajectories (const TrajectorySeed &) const
 set Event for the internal MeasurementTracker data member More...
 
void trajectories (const TrajectorySeed &, TrajectoryContainer &ret) const
 trajectories building starting from a seed, return in an already allocated vector More...
 
TrajectoryContainer trajectories (const TrajectorySeed &, const TrackingRegion &) const
 trajectories building starting from a seed with a region More...
 
void trajectories (const TrajectorySeed &, TrajectoryContainer &ret, const TrackingRegion &) const
 trajectories building starting from a seed with a region More...
 
const TrajectoryStateUpdatorupdator () const
 
virtual ~GroupedCkfTrajectoryBuilder ()
 destructor More...
 
- Public Member Functions inherited from BaseCkfTrajectoryBuilder
 BaseCkfTrajectoryBuilder (const edm::ParameterSet &conf, TrajectoryFilter *filter, TrajectoryFilter *inOutFilter=0)
 
 BaseCkfTrajectoryBuilder (const BaseCkfTrajectoryBuilder &)=delete
 
const
TransientTrackingRecHitBuilder
hitBuilder () const
 
BaseCkfTrajectoryBuilderoperator= (const BaseCkfTrajectoryBuilder &)=delete
 
virtual void setDebugger (CkfDebugger *dbg) const
 
virtual void setEvent (const edm::Event &event) const
 
void setEvent (const edm::Event &iEvent, const edm::EventSetup &iSetup, const MeasurementTrackerEvent *data)
 
void setNavigationSchool (NavigationSchool const *nv)
 
virtual void unset () const
 
virtual ~BaseCkfTrajectoryBuilder ()
 
- Public Member Functions inherited from TrajectoryBuilder
virtual ~TrajectoryBuilder ()
 

Protected Member Functions

virtual void analyseMeasurements (const std::vector< TM > &meas, const Trajectory &traj) const
 
virtual void analyseResult (const TrajectoryContainer &result) const
 
virtual void analyseSeed (const TrajectorySeed &seed) const
 
void setEvent_ (const edm::Event &iEvent, const edm::EventSetup &iSetup) override
 
- Protected Member Functions inherited from BaseCkfTrajectoryBuilder
void addToResult (boost::shared_ptr< const TrajectorySeed > const &seed, TempTrajectory &traj, TrajectoryContainer &result, bool inOut=false) const
 
void addToResult (TempTrajectory const &traj, TempTrajectoryContainer &result, bool inOut=false) const
 
virtual bool analyzeMeasurementsDebugger (Trajectory &traj, const std::vector< TrajectoryMeasurement > &meas, const MeasurementTrackerEvent *theMeasurementTracker, const Propagator *theForwardPropagator, const Chi2MeasurementEstimatorBase *theEstimator, const TransientTrackingRecHitBuilder *theTTRHBuilder) const
 
virtual bool analyzeMeasurementsDebugger (TempTrajectory &traj, const std::vector< TrajectoryMeasurement > &meas, const MeasurementTrackerEvent *theMeasurementTracker, const Propagator *theForwardPropagator, const Chi2MeasurementEstimatorBase *theEstimator, const TransientTrackingRecHitBuilder *theTTRHBuilder) const
 
const PropagatorbackwardPropagator (const TrajectorySeed &seed) const
 
TempTrajectory createStartingTrajectory (const TrajectorySeed &seed) const
 
virtual void fillSeedHistoDebugger (std::vector< TrajectoryMeasurement >::iterator begin, std::vector< TrajectoryMeasurement >::iterator end) const
 
StateAndLayers findStateAndLayers (const TrajectorySeed &seed, const TempTrajectory &traj) const
 
StateAndLayers findStateAndLayers (const TempTrajectory &traj) const
 
const PropagatorforwardPropagator (const TrajectorySeed &seed) const
 
void moveToResult (TempTrajectory &&traj, TempTrajectoryContainer &result, bool inOut=false) const
 
bool qualityFilter (const TempTrajectory &traj, bool inOut=false) const
 
void setData (const MeasurementTrackerEvent *data)
 
bool toBeContinued (TempTrajectory &traj, bool inOut=false) const
 

Private Types

enum  work_MaxSize_Size_ { work_MaxSize_ = 50 }
 

Private Member Functions

bool advanceOneLayer (const TrajectorySeed &seed, TempTrajectory &traj, const TrajectoryFilter *regionalCondition, const Propagator *propagator, bool inOut, TempTrajectoryContainer &newCand, TempTrajectoryContainer &result) const
 
TempTrajectory backwardFit (TempTrajectory &candidate, unsigned int nSeed, const TrajectoryFitter &fitter, std::vector< const TrackingRecHit * > &remainingHits) const
 
void groupedIntermediaryClean (TempTrajectoryContainer &theTrajectories) const
 intermediate cleaning in the case of grouped measurements More...
 
void groupedLimitedCandidates (const TrajectorySeed &seed, TempTrajectory const &startingTraj, const TrajectoryFilter *regionalCondition, const Propagator *propagator, bool inOut, TempTrajectoryContainer &result) const
 
void rebuildSeedingRegion (const TrajectorySeed &seed, TempTrajectory const &startingTraj, TempTrajectoryContainer &result) const
 try to find additional hits in seeding region More...
 
int rebuildSeedingRegion (const TrajectorySeed &seed, const std::vector< const TrackingRecHit * > &seedHits, TempTrajectory &candidate, TempTrajectoryContainer &result) const
 
bool tkxor (bool a, bool b) const
 
bool verifyHits (TempTrajectory::DataContainer::const_iterator rbegin, size_t maxDepth, const std::vector< const TrackingRecHit * > &hits) const
 Verifies presence of a RecHits in a range of TrajectoryMeasurements. More...
 

Static Private Member Functions

static PropagationDirection oppositeDirection (PropagationDirection dir)
 change of propagation direction More...
 

Private Attributes

float maxDPhiForLooperReconstruction
 
float maxPt2ForLooperReconstruction
 
bool theAlwaysUseInvalid
 
bool theBestHitOnly
 
double theChiSquareCut
 
TrajectoryFiltertheConfigurableCondition
 
float theFoundHitBonus
 
bool theIntermediateCleaning
 
bool theKeepOriginalIfRebuildFails
 
bool theLockHits
 
float theLostHitPenalty
 
double theMass
 
int theMaxCand
 
unsigned int theMinNrOf2dHitsForRebuild
 
unsigned int theMinNrOfHitsForRebuild
 
double theptCut
 
bool theRequireSeedHitsInRebuild
 

Additional Inherited Members

- Public Types inherited from BaseCkfTrajectoryBuilder
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
 
- Protected Types inherited from BaseCkfTrajectoryBuilder
typedef TrackingComponentsRecord Chi2MeasurementEstimatorRecord
 
typedef FreeTrajectoryState FTS
 
typedef std::pair< TSOS,
std::vector< const DetLayer * > > 
StateAndLayers
 
typedef TrajectoryMeasurement TM
 
typedef TrajectoryStateOnSurface TSOS
 
- Static Protected Member Functions inherited from BaseCkfTrajectoryBuilder
static TrajectoryFiltercreateTrajectoryFilter (const edm::ParameterSet &pset, edm::ConsumesCollector &iC)
 
- Protected Attributes inherited from BaseCkfTrajectoryBuilder
const
Chi2MeasurementEstimatorBase
theEstimator
 
const MeasurementTrackerEventtheMeasurementTracker
 
const NavigationSchooltheNavigationSchool = 0
 
const PropagatorthePropagatorAlong
 
const PropagatorthePropagatorOpposite
 
const
TransientTrackingRecHitBuilder
theTTRHBuilder
 
const TrajectoryStateUpdatortheUpdator
 

Detailed Description

A highly configurable trajectory builder that allows full exploration of the combinatorial tree of possible continuations, and provides efficient ways of trimming the combinatorial tree.

Definition at line 24 of file GroupedCkfTrajectoryBuilder.h.

Member Enumeration Documentation

Enumerator
work_MaxSize_ 

Definition at line 207 of file GroupedCkfTrajectoryBuilder.h.

207 { work_MaxSize_ = 50 }; // if it grows above this number, it is forced to resize to half this amount when cleared

Constructor & Destructor Documentation

GroupedCkfTrajectoryBuilder::GroupedCkfTrajectoryBuilder ( const edm::ParameterSet conf,
edm::ConsumesCollector iC 
)

constructor from ParameterSet

Definition at line 123 of file GroupedCkfTrajectoryBuilder.cc.

References edm::ParameterSet::existsAs(), edm::ParameterSet::getParameter(), bookConverter::max, maxDPhiForLooperReconstruction, maxPt2ForLooperReconstruction, theAlwaysUseInvalid, theBestHitOnly, theFoundHitBonus, theIntermediateCleaning, theKeepOriginalIfRebuildFails, theLockHits, theLostHitPenalty, theMaxCand, theMinNrOf2dHitsForRebuild, theMinNrOfHitsForRebuild, and theRequireSeedHitsInRebuild.

123  :
126  conf.getParameter<bool>("useSameTrajFilter") ?
129  )
130 {
131  // fill data members from parameters (eventually data members could be dropped)
132  //
133  theMaxCand = conf.getParameter<int>("maxCand");
134 
135  theLostHitPenalty = conf.getParameter<double>("lostHitPenalty");
136  theFoundHitBonus = conf.getParameter<double>("foundHitBonus");
137  theIntermediateCleaning = conf.getParameter<bool>("intermediateCleaning");
138  theAlwaysUseInvalid = conf.getParameter<bool>("alwaysUseInvalidHits");
139  theLockHits = conf.getParameter<bool>("lockHits");
140  theBestHitOnly = conf.getParameter<bool>("bestHitOnly");
142  theRequireSeedHitsInRebuild = conf.getParameter<bool>("requireSeedHitsInRebuild");
143  theKeepOriginalIfRebuildFails = conf.getParameter<bool>("keepOriginalIfRebuildFails");
144  theMinNrOfHitsForRebuild = max(0,conf.getParameter<int>("minNrOfHitsForRebuild"));
145  maxPt2ForLooperReconstruction = conf.existsAs<double>("maxPtForLooperReconstruction") ?
146  conf.getParameter<double>("maxPtForLooperReconstruction") : 0;
148  maxDPhiForLooperReconstruction = conf.existsAs<double>("maxDPhiForLooperReconstruction") ?
149  conf.getParameter<double>("maxDPhiForLooperReconstruction") : 2.0;
150 
151 
152  /* ======= B.M. to be ported layer ===========
153  bool setOK = thePropagator->setMaxDirectionChange(1.6);
154  if (!setOK)
155  cout << "GroupedCkfTrajectoryBuilder WARNING: "
156  << "propagator does not support setMaxDirectionChange"
157  << endl;
158  // addStopCondition(theMinPtStopCondition);
159 
160  theConfigurableCondition = createAlgo<TrajectoryFilter>(componentConfig("StopCondition"));
161  ===================================== */
162 
163 }
T getParameter(std::string const &) const
bool existsAs(std::string const &parameterName, bool trackiness=true) const
checks if a parameter exists as a given type
Definition: ParameterSet.h:186
static TrajectoryFilter * createTrajectoryFilter(const edm::ParameterSet &pset, edm::ConsumesCollector &iC)
BaseCkfTrajectoryBuilder(const edm::ParameterSet &conf, TrajectoryFilter *filter, TrajectoryFilter *inOutFilter=0)
virtual GroupedCkfTrajectoryBuilder::~GroupedCkfTrajectoryBuilder ( )
inlinevirtual

destructor

Definition at line 31 of file GroupedCkfTrajectoryBuilder.h.

31 {}

Member Function Documentation

bool GroupedCkfTrajectoryBuilder::advanceOneLayer ( const TrajectorySeed seed,
TempTrajectory traj,
const TrajectoryFilter regionalCondition,
const Propagator propagator,
bool  inOut,
TempTrajectoryContainer newCand,
TempTrajectoryContainer result 
) const
private

Definition at line 457 of file GroupedCkfTrajectoryBuilder.cc.

References funct::abs(), BaseCkfTrajectoryBuilder::addToResult(), PV3DBase< T, PVType, FrameType >::basicVector(), gather_cfg::cout, PV3DBase< T, PVType, FrameType >::eta(), TransverseImpactPointExtrapolator::extrapolate(), f, BaseCkfTrajectoryBuilder::findStateAndLayers(), BaseCkfTrajectoryBuilder::forwardPropagator(), TempTrajectory::foundHits(), TrajectoryStateOnSurface::globalMomentum(), TrajectoryStateOnSurface::globalPosition(), TempTrajectory::incrementLoops(), TrajectoryStateOnSurface::isValid(), TempTrajectory::join(), TempTrajectory::lastLayer(), TempTrajectory::lastMeasurement(), Bounds::length(), DetLayer::location(), LogDebug, TempTrajectory::lostHits(), maxDPhiForLooperReconstruction, maxPt2ForLooperReconstruction, TempTrajectory::measurements(), TrackingRecHit::missing, eostools::move(), BaseCkfTrajectoryBuilder::moveToResult(), NO_SEGMENTS_FOR_VALID_LAYERS, NOT_STOPPED, PV3DBase< T, PVType, FrameType >::perp(), PV3DBase< T, PVType, FrameType >::phi(), Propagator::propagationDirection(), cmsutils::bqueue< T >::rbegin(), rejected(), cmsutils::bqueue< T >::rend(), TempTrajectory::setDPhiCacheForLoopersReconstruction(), TempTrajectory::setStopReason(), BarrelDetLayer::specificSurface(), filterCSVwithJSON::target, theAlwaysUseInvalid, theBestHitOnly, BaseCkfTrajectoryBuilder::theEstimator, theLockHits, theMaxCand, BaseCkfTrajectoryBuilder::theMeasurementTracker, BaseCkfTrajectoryBuilder::theUpdator, BaseCkfTrajectoryBuilder::toBeContinued(), TrajectoryStateOnSurface::transverseCurvature(), unlikely, TrajectoryMeasurement::updatedState(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by groupedLimitedCandidates().

464 {
465  std::pair<TSOS,std::vector<const DetLayer*> > && stateAndLayers = findStateAndLayers(traj);
466 
467 
469  if(
470  //stateAndLayers.second.size()==0 &&
471  traj.lastLayer()->location()==0) {
472  float pt2 = stateAndLayers.first.globalMomentum().perp2();
474  pt2>(0.3f*0.3f)
475  )
476  stateAndLayers.second.push_back(traj.lastLayer());
477  }
478  }
479 
480  auto layerBegin = stateAndLayers.second.begin();
481  auto layerEnd = stateAndLayers.second.end();
482 
483  // if (nl.empty()) {
484  // addToResult(traj,result,inOut);
485  // return false;
486  // }
487 
488 #ifdef EDM_ML_DEBUG
489  LogDebug("CkfPattern")<<whatIsTheNextStep(traj, stateAndLayers);
490 #endif
491 
492  bool foundSegments(false);
493  bool foundNewCandidates(false);
494  for ( auto il=layerBegin; il!=layerEnd; il++) {
495 
496  TSOS stateToUse = stateAndLayers.first;
497 
498  double dPhiCacheForLoopersReconstruction(0);
499  if unlikely((*il)==traj.lastLayer()){
500 
502  // ------ For loopers reconstruction
503  //cout<<" self propagating in advanceOneLayer (for loopers) \n";
504  const BarrelDetLayer* sbdl = dynamic_cast<const BarrelDetLayer*>(traj.lastLayer());
505  if(sbdl){
506  HelixBarrelCylinderCrossing cylinderCrossing(stateToUse.globalPosition(),
507  stateToUse.globalMomentum(),
508  stateToUse.transverseCurvature(),
509  propagator->propagationDirection(),
510  sbdl->specificSurface());
511  if(!cylinderCrossing.hasSolution()) continue;
512  GlobalPoint starting = stateToUse.globalPosition();
513  GlobalPoint target1 = cylinderCrossing.position1();
514  GlobalPoint target2 = cylinderCrossing.position2();
515 
516  GlobalPoint farther = fabs(starting.phi()-target1.phi()) > fabs(starting.phi()-target2.phi()) ?
517  target1 : target2;
518 
519  const Bounds& bounds( sbdl->specificSurface().bounds());
520  float length = 0.5f*bounds.length();
521 
522  /*
523  cout << "starting: " << starting << endl;
524  cout << "target1: " << target1 << endl;
525  cout << "target2: " << target2 << endl;
526  cout << "dphi: " << (target1.phi()-target2.phi()) << endl;
527  cout << "length: " << length << endl;
528  */
529 
530  /*
531  float deltaZ = bounds.thickness()/2.f/fabs(tan(stateToUse.globalDirection().theta()) ) ;
532  if(stateToUse.hasError())
533  deltaZ += 3*sqrt(stateToUse.cartesianError().position().czz());
534  if( fabs(farther.z()) > length + deltaZ ) continue;
535  */
536  if(fabs(farther.z())*0.95f>length) continue;
537 
538  Geom::Phi<float> tmpDphi = target1.phi()-target2.phi();
539  if(std::abs(tmpDphi)>maxDPhiForLooperReconstruction) continue;
540  GlobalPoint target(0.5f*(target1.basicVector()+target2.basicVector()));
541  //cout << "target: " << target << endl;
542 
543 
544 
546  stateToUse = extrapolator.extrapolate(stateToUse, target, *propagator);
547  if (!stateToUse.isValid()) continue; //SK: consider trying the original? probably not
548 
549  //dPhiCacheForLoopersReconstruction = fabs(target1.phi()-target2.phi())*2.;
550  dPhiCacheForLoopersReconstruction = std::abs(tmpDphi);
551  traj.incrementLoops();
552  }else{ // not barrel
553  continue;
554  }
555  }else{ // loopers not requested (why else???)
556  // ------ For cosmics reconstruction
557  LogDebug("CkfPattern")<<" self propagating in advanceOneLayer.\n from: \n"<<stateToUse;
558  //self navigation case
559  // go to a middle point first
561  GlobalPoint center(0,0,0);
562  stateToUse = middle.extrapolate(stateToUse, center, *(forwardPropagator(seed)));
563 
564  if (!stateToUse.isValid()) continue;
565  LogDebug("CkfPattern")<<"to: "<<stateToUse;
566  }
567  } // last layer...
568 
569  //unsigned int maxCandidates = theMaxCand > 21 ? theMaxCand*2 : 42; //limit the number of returned segments
570  LayerMeasurements layerMeasurements(theMeasurementTracker->measurementTracker(), *theMeasurementTracker);
571  TrajectorySegmentBuilder layerBuilder(&layerMeasurements,
572  **il,*propagator,
575 
576 #ifdef EDM_ML_DEBUG
577  LogDebug("CkfPattern")<<whatIsTheStateToUse(stateAndLayers.first,stateToUse,*il);
578 #endif
579 
580  auto && segments= layerBuilder.segments(stateToUse);
581 
582  LogDebug("CkfPattern")<< "GCTB: number of segments = " << segments.size();
583 
584  if ( !segments.empty() ) foundSegments = true;
585 
586  for (auto is=segments.begin(); is!=segments.end(); is++ ) {
587  //
588  // assume "invalid hit only" segment is last in list
589  //
590  auto const & measurements = is->measurements();
591  if ( !theAlwaysUseInvalid && is!=segments.begin() && measurements.size()==1 &&
592  (measurements.front().recHit()->getType() == TrackingRecHit::missing) ) break;
593 
594 
595  //---- avoid to add the same hits more than once in the trajectory ----
596  bool toBeRejected(false);
597  for(auto revIt = measurements.rbegin(); revIt!=measurements.rend(); --revIt){
598  // int tmpCounter(0);
599  for(auto newTrajMeasIt = traj.measurements().rbegin();
600  newTrajMeasIt != traj.measurements().rend(); --newTrajMeasIt){
601  //if(tmpCounter==2) break;
602  if(revIt->recHitR().geographicalId()==newTrajMeasIt->recHitR().geographicalId()
603  && (revIt->recHitR().geographicalId() != DetId(0)) ){
604  toBeRejected=true;
605  goto rejected; //break; // see http://stackoverflow.com/questions/1257744/can-i-use-break-to-exit-multiple-nested-for-loops
606  }
607  // tmpCounter++;
608  }
609  }
610 
611  rejected:; // http://xkcd.com/292/
612  if(toBeRejected){
613 #ifdef VI_DEBUG
614  cout << "WARNING: neglect candidate because it contains the same hit twice \n";
615  cout << "-- discarded track's pt,eta,#found/lost: "
616  << traj.lastMeasurement().updatedState().globalMomentum().perp() << " , "
617  << traj.lastMeasurement().updatedState().globalMomentum().eta() << " , "
618  << traj.foundHits() << '/' << traj.lostHits() << "\n";
619 #endif
620  traj.setDPhiCacheForLoopersReconstruction(dPhiCacheForLoopersReconstruction);
621  continue; //Are we sure about this????
622  }
623  // ------------------------
624 
625  //
626  // create new candidate
627  //
628  TempTrajectory newTraj(traj);
629  traj.setDPhiCacheForLoopersReconstruction(dPhiCacheForLoopersReconstruction);
630  newTraj.join(*is);
631 
632  //std::cout << "DEBUG: newTraj after push found,lost: "
633  // << newTraj.foundHits() << " , "
634  // << newTraj.lostHits() << " , "
635  // << newTraj.measurements().size() << std::endl;
636 
637 
638 
639  //GIO// for ( vector<TM>::const_iterator im=measurements.begin();
640  //GIO// im!=measurements.end(); im++ ) newTraj.push(*im);
641  //if ( toBeContinued(newTraj,regionalCondition) ) { TOBE FIXED
642  if ( toBeContinued(newTraj, inOut) ) {
643  // Have added one more hit to track candidate
644 
645  LogDebug("CkfPattern")<<"GCTB: adding updated trajectory to candidates: inOut="<<inOut<<" hits="<<newTraj.foundHits();
646 
647  newTraj.setStopReason(StopReason::NOT_STOPPED);
648  newCand.push_back(std::move(newTraj));
649  foundNewCandidates = true;
650  }
651  else {
652  // Have finished building this track. Check if it passes cuts.
653 
654  LogDebug("CkfPattern")<< "GCTB: adding completed trajectory to results if passes cuts: inOut="<<inOut<<" hits="<<newTraj.foundHits();
655  moveToResult(std::move(newTraj), result, inOut);
656  }
657  } // loop over segs
658  } // loop over layers
659 
660  if ( !foundSegments ){
661  LogDebug("CkfPattern")<< "GCTB: adding input trajectory to result";
662  if (stateAndLayers.second.size() > 0)
664  addToResult(traj, result, inOut);
665  }
666  return foundNewCandidates;
667 }
#define LogDebug(id)
const_iterator rend() const
Definition: bqueue.h:164
virtual float length() const =0
T perp() const
Definition: PV3DBase.h:72
virtual Location location() const =0
Which part of the detector (barrel, endcap)
const Propagator * forwardPropagator(const TrajectorySeed &seed) const
const DataContainer & measurements() const
Geom::Phi< T > phi() const
Definition: PV3DBase.h:69
const TrajectoryStateUpdator * theUpdator
GlobalPoint globalPosition() const
virtual PropagationDirection propagationDirection() const final
Definition: Propagator.h:151
int foundHits() const
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is rejected(acceptEvent retursns false).There are 3 relevant cases of types of criteria
tuple result
Definition: mps_fire.py:84
const TrajectoryMeasurement & lastMeasurement() const
#define unlikely(x)
void setDPhiCacheForLoopersReconstruction(float dphi)
T z() const
Definition: PV3DBase.h:64
def move
Definition: eostools.py:510
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
double f[11][100]
void addToResult(boost::shared_ptr< const TrajectorySeed > const &seed, TempTrajectory &traj, TrajectoryContainer &result, bool inOut=false) const
const_iterator rbegin() const
Definition: bqueue.h:163
StateAndLayers findStateAndLayers(const TrajectorySeed &seed, const TempTrajectory &traj) const
const MeasurementTrackerEvent * theMeasurementTracker
Definition: DetId.h:18
virtual const BoundCylinder & specificSurface() const final
Extension of the interface.
void moveToResult(TempTrajectory &&traj, TempTrajectoryContainer &result, bool inOut=false) const
T eta() const
Definition: PV3DBase.h:76
TrajectoryStateOnSurface extrapolate(const FreeTrajectoryState &fts, const GlobalPoint &vtx) const
extrapolation with default (=geometrical) propagator
GlobalVector globalMomentum() const
bool toBeContinued(TempTrajectory &traj, bool inOut=false) const
void setStopReason(StopReason s)
tuple cout
Definition: gather_cfg.py:145
TrajectoryStateOnSurface const & updatedState() const
Definition: Bounds.h:22
const DetLayer * lastLayer() const
Redundant method, returns the layer of lastMeasurement() .
const BasicVectorType & basicVector() const
Definition: PV3DBase.h:56
const Chi2MeasurementEstimatorBase * theEstimator
int lostHits() const
virtual void GroupedCkfTrajectoryBuilder::analyseMeasurements ( const std::vector< TM > &  meas,
const Trajectory traj 
) const
inlineprotectedvirtual

Definition at line 100 of file GroupedCkfTrajectoryBuilder.h.

101  {}
virtual void GroupedCkfTrajectoryBuilder::analyseResult ( const TrajectoryContainer result) const
inlineprotectedvirtual

Definition at line 102 of file GroupedCkfTrajectoryBuilder.h.

Referenced by buildTrajectories().

102 {}
virtual void GroupedCkfTrajectoryBuilder::analyseSeed ( const TrajectorySeed seed) const
inlineprotectedvirtual

Definition at line 98 of file GroupedCkfTrajectoryBuilder.h.

Referenced by buildTrajectories().

98 {}
TempTrajectory GroupedCkfTrajectoryBuilder::backwardFit ( TempTrajectory candidate,
unsigned int  nSeed,
const TrajectoryFitter fitter,
std::vector< const TrackingRecHit * > &  remainingHits 
) const
private

Definition at line 1017 of file GroupedCkfTrajectoryBuilder.cc.

References TempTrajectory::direction(), Trajectory::direction(), PrintoutHelper::dumpMeasurement(), PrintoutHelper::dumpMeasurements(), Trajectory::firstMeasurement(), TrajectoryFitter::fitOne(), TempTrajectory::foundHits(), TrackingRecHit::isValid(), Trajectory::isValid(), likely, LogDebug, bookConverter::max, TempTrajectory::measurements(), Trajectory::measurements(), TempTrajectory::nLoops(), Trajectory::nLoops(), oppositeDirection(), Trajectory::push(), Trajectory::recHits(), TrajectoryStateOnSurface::rescaleError(), Trajectory::setNLoops(), cmsutils::bqueue< T >::size(), theMinNrOfHitsForRebuild, unlikely, and TrajectoryMeasurement::updatedState().

Referenced by rebuildSeedingRegion().

1020 {
1021  //
1022  // clear array of non-fitted hits
1023  //
1024  remainingHits.clear();
1025  //
1026  // skip candidates which are not exceeding the seed size
1027  // (e.g. Because no Tracker layers exist outside seeding region)
1028  //
1029  if unlikely( candidate.measurements().size()<=nSeed ) return TempTrajectory();
1030 
1031  LogDebug("CkfPattern")<<"nSeed " << nSeed << endl
1032  << "Old traj direction = " << candidate.direction() << endl
1034 
1035  //
1036  // backward fit trajectory.
1037  // (Will try to fit only hits outside the seeding region. However,
1038  // if there are not enough of these, it will also use the seeding hits).
1039  //
1040  // const unsigned int nHitAllMin(5);
1041  // const unsigned int nHit2dMin(2);
1042  unsigned int nHit(0); // number of valid hits after seeding region
1043  //unsigned int nHit2d(0); // number of valid hits after seeding region with 2D info
1044  // use all hits except the first n (from seed), but require minimum
1045  // specified in configuration.
1046  // Swapped over next two lines.
1047  unsigned int nHitMin = std::max(candidate.foundHits()-nSeed,theMinNrOfHitsForRebuild);
1048  // unsigned int nHitMin = oldMeasurements.size()-nSeed;
1049  // we want to rebuild only if the number of VALID measurements excluding the seed measurements is higher than the cut
1051 
1052  LogDebug("CkfPattern")/* << "nHitMin " << nHitMin*/ <<"Sizes: " << candidate.measurements().size() << " / ";
1053  //
1054  // create input trajectory for backward fit
1055  //
1056  Trajectory fwdTraj(oppositeDirection(candidate.direction()));
1057  fwdTraj.setNLoops(candidate.nLoops());
1058  //const TrajectorySeed seed = TrajectorySeed(PTrajectoryStateOnDet(), TrajectorySeed::recHitContainer(), oppositeDirection(candidate.direction()));
1059  //Trajectory fwdTraj(seed, oppositeDirection(candidate.direction()));
1060 
1061  const DetLayer* bwdDetLayer[candidate.measurements().size()];
1062  int nl=0;
1063  for ( auto const & tm : candidate.measurements() ) {
1064  const TrackingRecHit* hit = tm.recHitR().hit();
1065  //
1066  // add hits until required number is reached
1067  //
1068  if ( nHit<nHitMin ){//|| nHit2d<theMinNrOf2dHitsForRebuild ) {
1069  fwdTraj.push(tm);
1070  bwdDetLayer[nl++]=tm.layer();
1071  //
1072  // count valid / 2D hits
1073  //
1074  if likely( hit->isValid() ) {
1075  nHit++;
1076  //if ( hit.isMatched() ||
1077  // hit.det().detUnits().front()->type().module()==pixel )
1078  //nHit2d++;
1079  }
1080  }
1081  //if (nHit==nHitMin) lastBwdDetLayer=im->layer();
1082  //
1083  // keep remaining (valid) hits for verification
1084  //
1085  else if ( hit->isValid() ) {
1086  //std::cout << "Adding a remaining hit" << std::endl;
1087  remainingHits.push_back(hit);
1088  }
1089  }
1090  //
1091  // Fit only if required number of valid hits can be used
1092  //
1093  if unlikely( nHit<nHitMin ) return TempTrajectory();
1094 
1095  //
1096  // Do the backward fit (important: start from scaled, not random cov. matrix!)
1097  //
1098  TrajectoryStateOnSurface firstTsos(fwdTraj.firstMeasurement().updatedState());
1099  //cout << "firstTsos "<< firstTsos << endl;
1100  firstTsos.rescaleError(10.);
1101  //TrajectoryContainer bwdFitted(fitter.fit(fwdTraj.seed(),fwdTraj.recHits(),firstTsos));
1102  Trajectory && bwdFitted = fitter.fitOne(TrajectorySeed(PTrajectoryStateOnDet(), TrajectorySeed::recHitContainer(), oppositeDirection(candidate.direction())),
1103  fwdTraj.recHits(),firstTsos);
1104  if unlikely(!bwdFitted.isValid()) return TempTrajectory();
1105 
1106 
1107  LogDebug("CkfPattern")<<"Obtained bwdFitted trajectory with measurement size " << bwdFitted.measurements().size();
1108  TempTrajectory fitted(fwdTraj.direction(),nSeed);
1109  fitted.setNLoops(fwdTraj.nLoops());
1110  vector<TM> const & tmsbf = bwdFitted.measurements();
1111  int iDetLayer=0;
1112  //this is ugly but the TM in the fitted track do not contain the DetLayer.
1113  //So we have to cache the detLayer pointers and replug them in.
1114  //For the backward building it would be enaugh to cache the last DetLayer,
1115  //but for the intermediary cleaning we need all
1116  for ( vector<TM>::const_iterator im=tmsbf.begin();im!=tmsbf.end(); im++ ) {
1117  fitted.emplace( (*im).forwardPredictedState(),
1118  (*im).backwardPredictedState(),
1119  (*im).updatedState(),
1120  (*im).recHit(),
1121  (*im).estimate(),
1122  bwdDetLayer[iDetLayer]
1123  );
1124 
1125  LogDebug("CkfPattern")<<PrintoutHelper::dumpMeasurement(*im);
1126  iDetLayer++;
1127  }
1128  /*
1129  TM lastMeas = bwdFitted.front().lastMeasurement();
1130  fitted.pop();
1131  fitted.push(TM(lastMeas.forwardPredictedState(),
1132  lastMeas.backwardPredictedState(),
1133  lastMeas.updatedState(),
1134  lastMeas.recHit(),
1135  lastMeas.estimate(),
1136  lastBwdDetLayer));
1137  */
1138 
1139 
1140  return fitted;
1141 }
#define LogDebug(id)
const DataContainer & measurements() const
int foundHits() const
static std::string dumpMeasurement(const TrajectoryMeasurement &tm)
static std::string dumpMeasurements(const std::vector< TrajectoryMeasurement > &v)
#define unlikely(x)
PropagationDirection direction() const
#define likely(x)
static PropagationDirection oppositeDirection(PropagationDirection dir)
change of propagation direction
#define end
Definition: vmac.h:37
bool isValid() const
string const
Definition: compareJSON.py:14
return(e1-e2)*(e1-e2)+dp *dp
#define begin
Definition: vmac.h:30
if(dp >Float(M_PI)) dp-
size_type size() const
Definition: bqueue.h:167
for(const auto &isodef:isoDefs)
tuple size
Write out results.
TempTrajectory GroupedCkfTrajectoryBuilder::buildTrajectories ( const TrajectorySeed seed,
GroupedCkfTrajectoryBuilder::TrajectoryContainer result,
const TrajectoryFilter regionalCondition 
) const
virtual

common part of both public trajectory building methods

Reimplemented from BaseCkfTrajectoryBuilder.

Definition at line 253 of file GroupedCkfTrajectoryBuilder.cc.

References analyseResult(), analyseSeed(), EnergyCorrector::c, compareJSON::const, gather_cfg::cout, BaseCkfTrajectoryBuilder::createStartingTrajectory(), Exception, BaseCkfTrajectoryBuilder::forwardPropagator(), groupedLimitedCandidates(), trackerHitRTTI::isUndef(), LogDebug, BaseCkfTrajectoryBuilder::theMeasurementTracker, and work_MaxSize_.

Referenced by trajectories().

256 {
257  if (theMeasurementTracker == 0) {
258  throw cms::Exception("LogicError") << "Asking to create trajectories to an un-initialized GroupedCkfTrajectoryBuilder.\nYou have to call clone(const MeasurementTrackerEvent *data) and then call trajectories on it instead.\n";
259  }
260 
261  statCount.seed();
262  //
263  // Build trajectory outwards from seed
264  //
265 
266  analyseSeed( seed);
267 
268  TempTrajectory const & startingTraj = createStartingTrajectory( seed);
269 
270  work_.clear();
271  const bool inOut = true;
272  groupedLimitedCandidates(seed, startingTraj, regionalCondition, forwardPropagator(seed), inOut, work_);
273  if ( work_.empty() ) return startingTraj;
274 
275  /* rebuilding is de-coupled from standard building
276  //
277  // try to additional hits in the seeding region
278  //
279  if ( theMinNrOfHitsForRebuild>0 ) {
280  // reverse direction
281  //thePropagator->setPropagationDirection(oppositeDirection(seed.direction()));
282  // rebuild part of the trajectory
283  rebuildSeedingRegion(startingTraj,work);
284  }
285 
286  */
287 
288  boost::shared_ptr<const TrajectorySeed> pseed(new TrajectorySeed(seed));
289  result.reserve(work_.size());
290  for (TempTrajectoryContainer::const_iterator it = work_.begin(), ed = work_.end(); it != ed; ++it) {
291  result.push_back( it->toTrajectory() ); result.back().setSharedSeed(pseed);
292  }
293 
294  work_.clear();
295  if (work_.capacity() > work_MaxSize_) { TempTrajectoryContainer().swap(work_); work_.reserve(work_MaxSize_/2); }
296 
298 
299  LogDebug("CkfPattern")<< "GroupedCkfTrajectoryBuilder: returning result of size " << result.size();
300  statCount.traj(result.size());
301 
302 #ifdef VI_DEBUG
303  int kt=0;
304  for (auto const & traj : result) {
305 int chit[7]={};
306 for (auto const & tm : traj.measurements()) {
307  auto const & hit = tm.recHitR();
308  if (!hit.isValid()) ++chit[0];
309  if (hit.det()==nullptr) ++chit[1];
310  if ( trackerHitRTTI::isUndef(hit) ) continue;
311  if ( hit.dimension()!=2 ) {
312  ++chit[2];
313  } else {
314  auto const & thit = static_cast<BaseTrackerRecHit const&>(hit);
315  auto const & clus = thit.firstClusterRef();
316  if (clus.isPixel()) ++chit[3];
317  else if (thit.isMatched()) {
318  ++chit[4];
319  } else if (thit.isProjected()) {
320  ++chit[5];
321  } else {
322  ++chit[6];
323  }
324  }
325  }
326 
327 std::cout << "ckf " << kt++ << ": "; for (auto c:chit) std::cout << c <<'/'; std::cout<< std::endl;
328 }
329 #endif
330 
331  return startingTraj;
332 
333 }
#define LogDebug(id)
const Propagator * forwardPropagator(const TrajectorySeed &seed) const
virtual void analyseSeed(const TrajectorySeed &seed) const
tuple result
Definition: mps_fire.py:84
virtual void analyseResult(const TrajectoryContainer &result) const
void groupedLimitedCandidates(const TrajectorySeed &seed, TempTrajectory const &startingTraj, const TrajectoryFilter *regionalCondition, const Propagator *propagator, bool inOut, TempTrajectoryContainer &result) const
const MeasurementTrackerEvent * theMeasurementTracker
std::vector< TempTrajectory > TempTrajectoryContainer
string const
Definition: compareJSON.py:14
bool isUndef(TrackingRecHit const &hit)
tuple cout
Definition: gather_cfg.py:145
TempTrajectory createStartingTrajectory(const TrajectorySeed &seed) const
double GroupedCkfTrajectoryBuilder::chiSquareCut ( )
inline

Chi**2 Cut on the new Trajectory Measurements to consider

Definition at line 77 of file GroupedCkfTrajectoryBuilder.h.

const Chi2MeasurementEstimatorBase& GroupedCkfTrajectoryBuilder::estimator ( void  ) const
inline

Definition at line 72 of file GroupedCkfTrajectoryBuilder.h.

References BaseCkfTrajectoryBuilder::theEstimator.

Referenced by rebuildSeedingRegion().

72 {return *theEstimator;}
const Chi2MeasurementEstimatorBase * theEstimator
void GroupedCkfTrajectoryBuilder::groupedIntermediaryClean ( TempTrajectoryContainer theTrajectories) const
private

intermediate cleaning in the case of grouped measurements

im1->recHit()->hit()->sharesInput(im2->recHit()->hit(), TrackingRecHit::all) ) {

im1->recHit()->hit()->sharesInput(im2->recHit()->hit(), TrackingRecHit::all) ) {

Definition at line 702 of file GroupedCkfTrajectoryBuilder.cc.

References lumiContext::fill, align_cfg::firstValid, TempTrajectory::isValid(), TempTrajectory::lastMeasurement(), LayerTriplets::layers(), cmsutils::bqueue< T >::rbegin(), TrajectoryMeasurement::recHitR(), cmsutils::bqueue< T >::rend(), TrackingRecHit::some, and tkxor().

Referenced by groupedLimitedCandidates().

703 {
704  //if (theTrajectories.empty()) return TrajectoryContainer();
705  //TrajectoryContainer result;
706  if (theTrajectories.empty()) return;
707  //RecHitEqualByChannels recHitEqualByChannels(false, false);
708  LayersInTraj layers[theTrajectories.size()];
709  int ntraj=0;
710  for ( auto & t : theTrajectories) {
711  if ( t.isValid() && t.lastMeasurement().recHitR().isValid() )
712  layers[ntraj++].fill(t);
713  }
714 
715  if (ntraj<2) return;
716 
717  for (int ifirst=0; ifirst!=ntraj-1; ++ifirst) {
718  auto firstTraj = layers[ifirst].traj;
719  if (!firstTraj->isValid()) continue;
720  const TempTrajectory::DataContainer & firstMeasurements = firstTraj->measurements();
721 
722  int firstLayerSize = layers[ifirst].tot;
723  if ( firstLayerSize<4 ) continue;
724  auto const & firstLayers = layers[ifirst].layers;
725 
726  for (int isecond= ifirst+1; isecond!=ntraj; ++isecond) {
727  auto secondTraj = layers[isecond].traj;
728  if (!secondTraj->isValid()) continue;
729 
730  const TempTrajectory::DataContainer & secondMeasurements = secondTraj->measurements();
731 
732  int secondLayerSize = layers[isecond].tot;
733  //
734  // only candidates using the same last 3 layers are compared
735  //
736  if ( firstLayerSize!=secondLayerSize ) continue; // V.I. why equal???
737  auto const & secondLayers = layers[isecond].layers;
738  if ( firstLayers[0]!=secondLayers[0] ||
739  firstLayers[1]!=secondLayers[1] ||
740  firstLayers[2]!=secondLayers[2] ) continue;
741 
742  TempTrajectory::DataContainer::const_iterator im1 = firstMeasurements.rbegin();
743  TempTrajectory::DataContainer::const_iterator im2 = secondMeasurements.rbegin();
744  //
745  // check for identical hits in the last layer
746  //
747  bool unequal(false);
748  const DetLayer* layerPtr = firstLayers[0];
749  while ( im1!=firstMeasurements.rend()&&im2!=secondMeasurements.rend() ) {
750  if ( im1->layer()!=layerPtr || im2->layer()!=layerPtr ) break;
751  if ( !(im1->recHit()->isValid()) || !(im2->recHit()->isValid()) ||
752  !im1->recHit()->hit()->sharesInput(im2->recHit()->hit(), TrackingRecHit::some) ) {
754  unequal = true;
755  break;
756  }
757  --im1;
758  --im2;
759  }
760  if ( im1==firstMeasurements.rend() || im2==secondMeasurements.rend() ||
761  im1->layer()==layerPtr || im2->layer()==layerPtr || unequal ) continue;
762  //
763  // check for invalid hits in the layer -2
764  // compare only candidates with invalid / valid combination
765  //
766  layerPtr = firstLayers[1];
767  bool firstValid(true);
768  while ( im1!=firstMeasurements.rend()&&im1->layer()==layerPtr ) {
769  if ( !im1->recHit()->isValid() ) firstValid = false;
770  --im1;
771  }
772  bool secondValid(true);
773  while ( im2!=secondMeasurements.rend()&&im2->layer()==layerPtr ) {
774  if ( !im2->recHit()->isValid() ) secondValid = false;
775  --im2;
776  }
777  if ( !tkxor(firstValid,secondValid) ) continue;
778  //
779  // ask for identical hits in layer -3
780  //
781  unequal = false;
782  layerPtr = firstLayers[2];
783  while ( im1!=firstMeasurements.rend()&&im2!=secondMeasurements.rend() ) {
784  if ( im1->layer()!=layerPtr || im2->layer()!=layerPtr ) break;
785  if ( !(im1->recHit()->isValid()) || !(im2->recHit()->isValid()) ||
786  !im1->recHit()->hit()->sharesInput(im2->recHit()->hit(), TrackingRecHit::some) ) {
788  unequal = true;
789  break;
790  }
791  --im1;
792  --im2;
793  }
794  if ( im1==firstMeasurements.rend() || im2==secondMeasurements.rend() ||
795  im1->layer()==layerPtr || im2->layer()==layerPtr || unequal ) continue;
796 
797  if ( !firstValid ) {
798  firstTraj->invalidate();
799  break;
800  }
801  else {
802  secondTraj->invalidate(); // V.I. why break?
803  break;
804  }
805  } // second
806  } // first
807 /*
808  for (TempTrajectoryContainer::const_iterator it = theTrajectories.begin();
809  it != theTrajectories.end(); it++) {
810  if(it->isValid()) result.push_back( *it);
811  }
812 
813  return result;
814 */
815  theTrajectories.erase(std::remove_if( theTrajectories.begin(),theTrajectories.end(),
816  std::not1(std::mem_fun_ref(&TempTrajectory::isValid))),
817  // boost::bind(&TempTrajectory::isValid,_1)),
818  theTrajectories.end());
819 }
const_iterator rend() const
Definition: bqueue.h:164
string fill
Definition: lumiContext.py:319
std::vector< LayerSetAndLayers > layers(const SeedingLayerSetsHits &sets)
Definition: LayerTriplets.cc:4
const_iterator rbegin() const
Definition: bqueue.h:163
bool isValid() const
bool tkxor(bool a, bool b) const
tuple firstValid
Definition: align_cfg.py:68
void GroupedCkfTrajectoryBuilder::groupedLimitedCandidates ( const TrajectorySeed seed,
TempTrajectory const &  startingTraj,
const TrajectoryFilter regionalCondition,
const Propagator propagator,
bool  inOut,
TempTrajectoryContainer result 
) const
private

Definition at line 337 of file GroupedCkfTrajectoryBuilder.cc.

References advanceOneLayer(), objects.IsoTrackAnalyzer::candidates, IntermediateTrajectoryCleaner::clean(), PrintoutHelper::dumpCandidates(), groupedIntermediaryClean(), LogDebug, theFoundHitBonus, theIntermediateCleaning, theLostHitPenalty, and theMaxCand.

Referenced by buildTrajectories(), and rebuildSeedingRegion().

343 {
344  unsigned int nIter=1;
346  TempTrajectoryContainer newCand;
347  candidates.push_back( startingTraj);
348 
349  while ( !candidates.empty()) {
350 
351  newCand.clear();
352  for (TempTrajectoryContainer::iterator traj=candidates.begin();
353  traj!=candidates.end(); traj++) {
354  if ( !advanceOneLayer(seed, *traj, regionalCondition, propagator, inOut, newCand, result) ) {
355  LogDebug("CkfPattern")<< "GCTB: terminating after advanceOneLayer==false";
356  continue;
357  }
358 
359  LogDebug("CkfPattern")<<"newCand(1): after advanced one layer:\n"<<PrintoutHelper::dumpCandidates(newCand);
360 
361  if ((int)newCand.size() > theMaxCand) {
362  //ShowCand()(newCand);
363 
364  std::nth_element( newCand.begin(), newCand.begin()+theMaxCand, newCand.end(), GroupedTrajCandLess(theLostHitPenalty,theFoundHitBonus));
365  newCand.erase( newCand.begin()+theMaxCand, newCand.end());
366  }
367  LogDebug("CkfPattern")<<"newCand(2): after removing extra candidates.\n"<<PrintoutHelper::dumpCandidates(newCand);
368  }
369 
370  LogDebug("CkfPattern") << "newCand.size() at end = " << newCand.size();
371 /*
372  if (theIntermediateCleaning) {
373  candidates.clear();
374  candidates = groupedIntermediaryClean(newCand);
375  } else {
376  candidates.swap(newCand);
377  }
378 */
380 #ifdef STANDARD_INTERMEDIARYCLEAN
382 #else
383  groupedIntermediaryClean(newCand);
384 #endif
385 
386  }
387  candidates.swap(newCand);
388 
389  LogDebug("CkfPattern") <<"candidates(3): "<<result.size()<<" candidates after "<<nIter++<<" groupedCKF iteration: \n"
391  <<"\n "<<candidates.size()<<" running candidates are: \n"
392  <<PrintoutHelper::dumpCandidates(candidates);
393  }
394 }
#define LogDebug(id)
static std::string dumpCandidates(collection &candidates)
static void clean(TempTrajectoryContainer &tracks)
tuple result
Definition: mps_fire.py:84
void groupedIntermediaryClean(TempTrajectoryContainer &theTrajectories) const
intermediate cleaning in the case of grouped measurements
bool advanceOneLayer(const TrajectorySeed &seed, TempTrajectory &traj, const TrajectoryFilter *regionalCondition, const Propagator *propagator, bool inOut, TempTrajectoryContainer &newCand, TempTrajectoryContainer &result) const
std::vector< TempTrajectory > TempTrajectoryContainer
float GroupedCkfTrajectoryBuilder::lostHitPenalty ( )
inline

Chi**2 Penalty for each lost hit.

Definition at line 84 of file GroupedCkfTrajectoryBuilder.h.

double GroupedCkfTrajectoryBuilder::mass ( )
inline

Mass hypothesis used for propagation.

Definition at line 93 of file GroupedCkfTrajectoryBuilder.h.

Referenced by Particle.Particle::__str__(), and DiObject.DiMuon::__str__().

int GroupedCkfTrajectoryBuilder::maxCand ( )
inline

Maximum number of trajectory candidates to propagate to the next layer.

Definition at line 80 of file GroupedCkfTrajectoryBuilder.h.

static PropagationDirection GroupedCkfTrajectoryBuilder::oppositeDirection ( PropagationDirection  dir)
inlinestaticprivate

change of propagation direction

Definition at line 158 of file GroupedCkfTrajectoryBuilder.h.

References alongMomentum, dir, and oppositeToMomentum.

Referenced by backwardFit().

158  {
159  if ( dir==alongMomentum ) return oppositeToMomentum;
160  if ( dir==oppositeToMomentum ) return alongMomentum;
161  return dir;
162  }
dbl *** dir
Definition: mlp_gen.cc:35
double GroupedCkfTrajectoryBuilder::ptCut ( )
inline

Pt cut.

Tells whether an intermediary cleaning stage should take place during TB.

Definition at line 90 of file GroupedCkfTrajectoryBuilder.h.

void GroupedCkfTrajectoryBuilder::rebuildSeedingRegion ( const TrajectorySeed seed,
TrajectoryContainer result 
) const
virtual

trajectories re-building in the seeding region. It looks for additional measurements in the seeding region of the intial trajectories. Only valid trajectories are returned. Invalid ones are dropped from the input collection.

Reimplemented from TrajectoryBuilder.

Definition at line 211 of file GroupedCkfTrajectoryBuilder.cc.

References BaseCkfTrajectoryBuilder::createStartingTrajectory(), and rebuildTrajectories().

Referenced by rebuildSeedingRegion(), and rebuildTrajectories().

212  {
213  TempTrajectory const & startingTraj = createStartingTrajectory( seed);
214  rebuildTrajectories(startingTraj,seed,result);
215 
216 }
tuple result
Definition: mps_fire.py:84
void rebuildTrajectories(TempTrajectory const &startingTraj, const TrajectorySeed &, TrajectoryContainer &result) const
TempTrajectory createStartingTrajectory(const TrajectorySeed &seed) const
void GroupedCkfTrajectoryBuilder::rebuildSeedingRegion ( const TrajectorySeed seed,
TempTrajectory const &  startingTraj,
TempTrajectoryContainer result 
) const
private

try to find additional hits in seeding region

Definition at line 823 of file GroupedCkfTrajectoryBuilder.cc.

References backwardFit(), BaseCkfTrajectoryBuilder::backwardPropagator(), HLT_25ns10e33_v2_cff::cloner, estimator(), BaseCkfTrajectoryBuilder::hitBuilder(), i, TempTrajectory::isValid(), LogDebug, TempTrajectory::measurements(), eostools::move(), rebuildSeedingRegion(), TrajectorySeed::recHits(), cmsutils::bqueue< T >::size(), theKeepOriginalIfRebuildFails, unlikely, and updator().

826 {
827  //
828  // Rebuilding of trajectories. Candidates are taken from result,
829  // which will be replaced with the solutions after rebuild
830  // (assume vector::swap is more efficient than building new container)
831  //
832  LogDebug("CkfPattern")<< "Starting to rebuild " << result.size() << " tracks";
833  //
834  // Fitter (need to create it here since the propagation direction
835  // might change between different starting trajectories)
836  //
837  auto hitCloner = static_cast<TkTransientTrackingRecHitBuilder const *>(hitBuilder())->cloner();
838  KFTrajectoryFitter fitter(backwardPropagator(seed),&updator(),&estimator(),3,nullptr,&hitCloner);
839  //
840  TrajectorySeed::range rseedHits = seed.recHits();
841  std::vector<const TrackingRecHit*> seedHits;
842  //seedHits.insert(seedHits.end(), rseedHits.first, rseedHits.second);
843  //for (TrajectorySeed::recHitContainer::const_iterator iter = rseedHits.first; iter != rseedHits.second; iter++){
844  // seedHits.push_back(&*iter);
845  //}
846 
847  //unsigned int nSeed(seedHits.size());
848  unsigned int nSeed(rseedHits.second-rseedHits.first);
849  //seedHits.reserve(nSeed);
850  TempTrajectoryContainer rebuiltTrajectories;
851 
852  for ( TempTrajectoryContainer::iterator it=result.begin();
853  it!=result.end(); it++ ) {
854  //
855  // skip candidates which are not exceeding the seed size
856  // (e.g. because no Tracker layers outside seeding region)
857  //
858 
859  if ( it->measurements().size()<=startingTraj.measurements().size() ) {
860  rebuiltTrajectories.push_back(std::move(*it));
861  LogDebug("CkfPattern")<< "RebuildSeedingRegion skipped as in-out trajectory does not exceed seed size.";
862  continue;
863  }
864  //
865  // Refit - keep existing trajectory in case fit is not possible
866  // or fails
867  //
868 
869  auto && reFitted = backwardFit(*it,nSeed,fitter,seedHits);
870  if unlikely( !reFitted.isValid() ) {
871  rebuiltTrajectories.push_back(std::move(*it));
872  LogDebug("CkfPattern")<< "RebuildSeedingRegion skipped as backward fit failed";
873  // << "after reFitted.size() " << reFitted.size();
874  continue;
875  }
876  //LogDebug("CkfPattern")<<"after reFitted.size() " << reFitted.size();
877  //
878  // Rebuild seeding part. In case it fails: keep initial trajectory
879  // (better to drop it??)
880  //
881  int nRebuilt =
882  rebuildSeedingRegion (seed, seedHits,reFitted,rebuiltTrajectories);
883  // Loop over the last nRebuilt trajectories and propagate back the
884  // real cause that stopped the original in-out trajectory, since
885  // that's the one we want to monitor
886  for (size_t i = rebuiltTrajectories.size() - 1; i < rebuiltTrajectories.size() - nRebuilt - 1; --i) {
887  rebuiltTrajectories[i].setStopReason(it->stopReason());
888  }
889 
890  if ( nRebuilt==0 && !theKeepOriginalIfRebuildFails ) it->invalidate(); // won't use original in-out track
891 
892  if ( nRebuilt<0 ) rebuiltTrajectories.push_back(std::move(*it));
893  }
894  //
895  // Replace input trajectories with new ones
896  //
897  result.swap(rebuiltTrajectories);
898  result.erase(std::remove_if( result.begin(),result.end(),
899  std::not1(std::mem_fun_ref(&TempTrajectory::isValid))),
900  result.end());
901 }
#define LogDebug(id)
int i
Definition: DBlmapReader.cc:9
tuple result
Definition: mps_fire.py:84
#define unlikely(x)
const TransientTrackingRecHitBuilder * hitBuilder() const
def move
Definition: eostools.py:510
const Chi2MeasurementEstimatorBase & estimator() const
std::pair< const_iterator, const_iterator > range
TempTrajectory backwardFit(TempTrajectory &candidate, unsigned int nSeed, const TrajectoryFitter &fitter, std::vector< const TrackingRecHit * > &remainingHits) const
void rebuildSeedingRegion(const TrajectorySeed &, TrajectoryContainer &result) const
bool isValid() const
std::vector< TempTrajectory > TempTrajectoryContainer
range recHits() const
const TrajectoryStateUpdator & updator() const
const Propagator * backwardPropagator(const TrajectorySeed &seed) const
int GroupedCkfTrajectoryBuilder::rebuildSeedingRegion ( const TrajectorySeed seed,
const std::vector< const TrackingRecHit * > &  seedHits,
TempTrajectory candidate,
TempTrajectoryContainer result 
) const
private

Definition at line 904 of file GroupedCkfTrajectoryBuilder.cc.

References BaseCkfTrajectoryBuilder::backwardPropagator(), gather_cfg::cout, TrajectorySeed::direction(), TempTrajectory::direction(), PrintoutHelper::dumpCandidates(), PrintoutHelper::dumpMeasurements(), groupedLimitedCandidates(), LogDebug, TempTrajectory::measurements(), TrajectorySeed::nHits(), TempTrajectory::push(), TempTrajectory::setNLoops(), cmsutils::bqueue< T >::size(), theRequireSeedHitsInRebuild, and verifyHits().

908 {
909  //
910  // Starting from track found by in-out tracking phase, extrapolate it inwards through
911  // the seeding region if possible in towards smaller Tracker radii, searching for additional
912  // hits.
913  // The resulting trajectories are returned in result,
914  // the count is the return value.
915  //
916  TempTrajectoryContainer rebuiltTrajectories;
917 #ifdef DBG2_GCTB
918 /* const LayerFinderByDet layerFinder;
919  if ( !seedHits.empty() && seedHits.front().isValid() ) {
920  DetLayer* seedLayer = layerFinder(seedHits.front().det());
921  cout << "Seed hit at " << seedHits.front().globalPosition()
922  << " " << seedLayer << endl;
923  cout << "Started from "
924  << candidate.lastMeasurement().updatedState().globalPosition().perp() << " "
925  << candidate.lastMeasurement().updatedState().globalPosition().z() << endl;
926  pair<bool,TrajectoryStateOnSurface> layerComp(false,TrajectoryStateOnSurface());
927  if ( seedLayer ) layerComp =
928  seedLayer->compatible(candidate.lastMeasurement().updatedState(),
929  propagator(),estimator());
930  pair<bool,TrajectoryStateOnSurface> detComp =
931  seedHits.front().det().compatible(candidate.lastMeasurement().updatedState(),
932  propagator(),estimator());
933  cout << " layer compatibility = " << layerComp.first;
934  cout << " det compatibility = " << detComp.first;
935  if ( detComp.first ) {
936  cout << " estimate = "
937  << estimator().estimate(detComp.second,seedHits.front()).second ;
938  }
939  cout << endl;
940  }*/
941  cout << "Before backward building: #measurements = "
942  << candidate.measurements().size() ; //<< endl;;
943 #endif
944  //
945  // Use standard building with standard cuts. Maybe better to use different
946  // cuts from "forward" building (e.g. no check on nr. of invalid hits)?
947  //
948  const bool inOut = false;
949  groupedLimitedCandidates(seed, candidate, nullptr, backwardPropagator(seed), inOut, rebuiltTrajectories);
950 
951  LogDebug("CkfPattern")<<" After backward building: "<<PrintoutHelper::dumpCandidates(rebuiltTrajectories);
952 
953  //
954  // Check & count resulting candidates
955  //
956  int nrOfTrajectories(0);
957  bool orig_ok = false;
958  //const RecHitEqualByChannels recHitEqual(false,false);
959  //vector<TM> oldMeasurements(candidate.measurements());
960  for ( TempTrajectoryContainer::iterator it=rebuiltTrajectories.begin();
961  it!=rebuiltTrajectories.end(); it++ ) {
962 
963  TempTrajectory::DataContainer newMeasurements(it->measurements());
964  //
965  // Verify presence of seeding hits?
966  //
968  orig_ok = true;
969  // no hits found (and possibly some invalid hits discarded): drop track
970  if ( newMeasurements.size()<=candidate.measurements().size() ){
971  LogDebug("CkfPattern") << "newMeasurements.size()<=candidate.measurements().size()";
972  continue;
973  }
974  // verify presence of hits
975  //GIO//if ( !verifyHits(newMeasurements.begin()+candidate.measurements().size(),
976  //GIO// newMeasurements.end(),seedHits) ){
977  if ( !verifyHits(newMeasurements.rbegin(),
978  newMeasurements.size() - candidate.measurements().size(),
979  seedHits) ){
980  LogDebug("CkfPattern")<< "seed hits not found in rebuild";
981  continue;
982  }
983  }
984  //
985  // construct final trajectory in the right order
986  //
987  // save & count result
988  nrOfTrajectories++;
989  result.emplace_back(seed.direction(),seed.nHits());
990  TempTrajectory & reversedTrajectory = result.back();
991  reversedTrajectory.setNLoops(it->nLoops());
992  for (TempTrajectory::DataContainer::const_iterator im=newMeasurements.rbegin(), ed = newMeasurements.rend();
993  im != ed; --im ) {
994  reversedTrajectory.push(*im);
995  }
996 
997  LogDebug("CkgPattern")<<"New traj direction = " << reversedTrajectory.direction()<<"\n"
998  <<PrintoutHelper::dumpMeasurements(reversedTrajectory.measurements());
999  } // rebuiltTrajectories
1000 
1001  // If nrOfTrajectories = 0 and orig_ok = true, this means that a track was actually found on the
1002  // out-in step (meeting those requirements) but did not have the seed hits in it.
1003  // In this case when we return we will go ahead and use the original in-out track.
1004 
1005  // If nrOfTrajectories = 0 and orig_ok = false, this means that the out-in step failed to
1006  // find any track. Two cases are a technical failure in fitting the original seed hits or
1007  // because the track did not meet the out-in criteria (which may be stronger than the out-in
1008  // criteria). In this case we will NOT allow the original in-out track to be used.
1009 
1010  if ( (nrOfTrajectories == 0) && orig_ok ) {
1011  nrOfTrajectories = -1;
1012  }
1013  return nrOfTrajectories;
1014 }
#define LogDebug(id)
PropagationDirection direction() const
static std::string dumpCandidates(collection &candidates)
const DataContainer & measurements() const
void setNLoops(signed char value)
static std::string dumpMeasurements(const std::vector< TrajectoryMeasurement > &v)
tuple result
Definition: mps_fire.py:84
PropagationDirection direction() const
bool verifyHits(TempTrajectory::DataContainer::const_iterator rbegin, size_t maxDepth, const std::vector< const TrackingRecHit * > &hits) const
Verifies presence of a RecHits in a range of TrajectoryMeasurements.
void groupedLimitedCandidates(const TrajectorySeed &seed, TempTrajectory const &startingTraj, const TrajectoryFilter *regionalCondition, const Propagator *propagator, bool inOut, TempTrajectoryContainer &result) const
std::vector< TempTrajectory > TempTrajectoryContainer
unsigned int nHits() const
const Propagator * backwardPropagator(const TrajectorySeed &seed) const
tuple cout
Definition: gather_cfg.py:145
size_type size() const
Definition: bqueue.h:167
void push(const TrajectoryMeasurement &tm)
void GroupedCkfTrajectoryBuilder::rebuildTrajectories ( TempTrajectory const &  startingTraj,
const TrajectorySeed seed,
TrajectoryContainer result 
) const
virtual

Reimplemented from BaseCkfTrajectoryBuilder.

Definition at line 219 of file GroupedCkfTrajectoryBuilder.cc.

References eostools::move(), rebuildSeedingRegion(), and edmIntegrityCheck::work().

Referenced by rebuildSeedingRegion().

220  {
222 
223  TrajectoryContainer final;
224 
225  work.reserve(result.size());
226  for (TrajectoryContainer::iterator traj=result.begin();
227  traj!=result.end(); ++traj) {
228  if(traj->isValid()) work.push_back(TempTrajectory(std::move(*traj)));
229  }
230 
231  rebuildSeedingRegion(seed,startingTraj,work);
232  final.reserve(work.size());
233 
234  // better the seed to be always the same...
235  boost::shared_ptr<const TrajectorySeed> sharedSeed;
236  if (result.empty())
237  sharedSeed.reset(new TrajectorySeed(seed));
238  else sharedSeed = result.front().sharedSeed();
239 
240 
241  for (TempTrajectoryContainer::iterator traj=work.begin();
242  traj!=work.end(); ++traj) {
243  final.push_back(traj->toTrajectory()); final.back().setSharedSeed(sharedSeed);
244  }
245 
246  result.swap(final);
247 
248  statCount.rebuilt(result.size());
249 
250 }
tuple result
Definition: mps_fire.py:84
def move
Definition: eostools.py:510
void rebuildSeedingRegion(const TrajectorySeed &, TrajectoryContainer &result) const
std::vector< TempTrajectory > TempTrajectoryContainer
std::vector< Trajectory > TrajectoryContainer
void GroupedCkfTrajectoryBuilder::setEvent_ ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
overrideprotectedvirtual

Implements BaseCkfTrajectoryBuilder.

Definition at line 172 of file GroupedCkfTrajectoryBuilder.cc.

172  {
173 }
bool GroupedCkfTrajectoryBuilder::tkxor ( bool  a,
bool  b 
) const
inlineprivate

Definition at line 112 of file GroupedCkfTrajectoryBuilder.h.

References a, and b.

Referenced by groupedIntermediaryClean().

112 {return (a||b) && !(a&&b);}
double b
Definition: hdecay.h:120
double a
Definition: hdecay.h:121
GroupedCkfTrajectoryBuilder::TrajectoryContainer GroupedCkfTrajectoryBuilder::trajectories ( const TrajectorySeed seed) const
virtual

set Event for the internal MeasurementTracker data member

trajectories building starting from a seed

Implements TrajectoryBuilder.

Definition at line 176 of file GroupedCkfTrajectoryBuilder.cc.

References buildTrajectories(), and runTheMatrix::ret.

177 {
179  ret.reserve(10);
180  buildTrajectories(seed, ret, 0);
181  return ret;
182 }
tuple ret
prodAgent to be discontinued
TempTrajectory buildTrajectories(const TrajectorySeed &seed, TrajectoryContainer &ret, const TrajectoryFilter *) const
common part of both public trajectory building methods
std::vector< Trajectory > TrajectoryContainer
void GroupedCkfTrajectoryBuilder::trajectories ( const TrajectorySeed seed,
GroupedCkfTrajectoryBuilder::TrajectoryContainer ret 
) const
virtual

trajectories building starting from a seed, return in an already allocated vector

Reimplemented from TrajectoryBuilder.

Definition at line 196 of file GroupedCkfTrajectoryBuilder.cc.

References buildTrajectories().

197 {
198  buildTrajectories(seed,ret,0);
199 }
tuple ret
prodAgent to be discontinued
TempTrajectory buildTrajectories(const TrajectorySeed &seed, TrajectoryContainer &ret, const TrajectoryFilter *) const
common part of both public trajectory building methods
GroupedCkfTrajectoryBuilder::TrajectoryContainer GroupedCkfTrajectoryBuilder::trajectories ( const TrajectorySeed seed,
const TrackingRegion region 
) const

trajectories building starting from a seed with a region

Definition at line 185 of file GroupedCkfTrajectoryBuilder.cc.

References buildTrajectories(), and runTheMatrix::ret.

187 {
189  ret.reserve(10);
190  RegionalTrajectoryFilter regionalCondition(region);
191  buildTrajectories(seed, ret, &regionalCondition);
192  return ret;
193 }
tuple ret
prodAgent to be discontinued
TempTrajectory buildTrajectories(const TrajectorySeed &seed, TrajectoryContainer &ret, const TrajectoryFilter *) const
common part of both public trajectory building methods
std::vector< Trajectory > TrajectoryContainer
void GroupedCkfTrajectoryBuilder::trajectories ( const TrajectorySeed seed,
GroupedCkfTrajectoryBuilder::TrajectoryContainer ret,
const TrackingRegion region 
) const

trajectories building starting from a seed with a region

Definition at line 202 of file GroupedCkfTrajectoryBuilder.cc.

References buildTrajectories().

205 {
206  RegionalTrajectoryFilter regionalCondition(region);
207  buildTrajectories(seed,ret,&regionalCondition);
208 }
tuple ret
prodAgent to be discontinued
TempTrajectory buildTrajectories(const TrajectorySeed &seed, TrajectoryContainer &ret, const TrajectoryFilter *) const
common part of both public trajectory building methods
const TrajectoryStateUpdator& GroupedCkfTrajectoryBuilder::updator ( ) const
inline

Definition at line 71 of file GroupedCkfTrajectoryBuilder.h.

References BaseCkfTrajectoryBuilder::theUpdator.

Referenced by rebuildSeedingRegion().

71 {return *theUpdator;}
const TrajectoryStateUpdator * theUpdator
bool GroupedCkfTrajectoryBuilder::verifyHits ( TempTrajectory::DataContainer::const_iterator  rbegin,
size_t  maxDepth,
const std::vector< const TrackingRecHit * > &  hits 
) const
private

Verifies presence of a RecHits in a range of TrajectoryMeasurements.

Definition at line 1144 of file GroupedCkfTrajectoryBuilder.cc.

References LogDebug, HLT_25ns10e33_v2_cff::maxDepth, and TrackingRecHit::some.

Referenced by rebuildSeedingRegion().

1147 {
1148  //
1149  // verify presence of the seeding hits
1150  //
1151  LogDebug("CkfPattern")<<"Checking for " << hits.size() << " hits in "
1152  << maxDepth << " measurements" << endl;
1153 
1154  auto rend = rbegin;
1155  while (maxDepth > 0) { --maxDepth; --rend; }
1156  for ( auto ir=hits.begin(); ir!=hits.end(); ir++ ) {
1157  // assume that all seeding hits are valid!
1158  bool foundHit(false);
1159  for ( auto im=rbegin; im!=rend; --im ) {
1160  if ( im->recHit()->isValid() && (*ir)->sharesInput(im->recHit()->hit(), TrackingRecHit::some) ) {
1161  foundHit = true;
1162  break;
1163  }
1164  }
1165  if ( !foundHit ) return false;
1166  }
1167  return true;
1168 }
#define LogDebug(id)

Member Data Documentation

float GroupedCkfTrajectoryBuilder::maxDPhiForLooperReconstruction
private

Definition at line 204 of file GroupedCkfTrajectoryBuilder.h.

Referenced by advanceOneLayer(), and GroupedCkfTrajectoryBuilder().

float GroupedCkfTrajectoryBuilder::maxPt2ForLooperReconstruction
private

If the value is greater than zero, the reconstructions for looper is turned on for candidates with pt greater than maxPtForLooperReconstruction

Definition at line 202 of file GroupedCkfTrajectoryBuilder.h.

Referenced by advanceOneLayer(), and GroupedCkfTrajectoryBuilder().

bool GroupedCkfTrajectoryBuilder::theAlwaysUseInvalid
private

Definition at line 185 of file GroupedCkfTrajectoryBuilder.h.

Referenced by advanceOneLayer(), and GroupedCkfTrajectoryBuilder().

bool GroupedCkfTrajectoryBuilder::theBestHitOnly
private

Use only best hit / group when building segments

Definition at line 188 of file GroupedCkfTrajectoryBuilder.h.

Referenced by advanceOneLayer(), and GroupedCkfTrajectoryBuilder().

double GroupedCkfTrajectoryBuilder::theChiSquareCut
private

Chi**2 Cut on the new Trajectory Measurements to consider

Definition at line 171 of file GroupedCkfTrajectoryBuilder.h.

TrajectoryFilter* GroupedCkfTrajectoryBuilder::theConfigurableCondition
private

Definition at line 166 of file GroupedCkfTrajectoryBuilder.h.

float GroupedCkfTrajectoryBuilder::theFoundHitBonus
private
            Chi**2 bonus for each found hit (favours candidates with

more measurements)

Definition at line 180 of file GroupedCkfTrajectoryBuilder.h.

Referenced by GroupedCkfTrajectoryBuilder(), and groupedLimitedCandidates().

bool GroupedCkfTrajectoryBuilder::theIntermediateCleaning
private

Tells whether an intermediary cleaning stage should take place during TB.

Definition at line 182 of file GroupedCkfTrajectoryBuilder.h.

Referenced by GroupedCkfTrajectoryBuilder(), and groupedLimitedCandidates().

bool GroupedCkfTrajectoryBuilder::theKeepOriginalIfRebuildFails
private

Keep original trajectory if rebuilding fails.

Definition at line 197 of file GroupedCkfTrajectoryBuilder.h.

Referenced by GroupedCkfTrajectoryBuilder(), and rebuildSeedingRegion().

bool GroupedCkfTrajectoryBuilder::theLockHits
private

Lock hits when building segments in a layer

Definition at line 187 of file GroupedCkfTrajectoryBuilder.h.

Referenced by advanceOneLayer(), and GroupedCkfTrajectoryBuilder().

float GroupedCkfTrajectoryBuilder::theLostHitPenalty
private

Chi**2 Penalty for each lost hit.

Definition at line 179 of file GroupedCkfTrajectoryBuilder.h.

Referenced by GroupedCkfTrajectoryBuilder(), and groupedLimitedCandidates().

double GroupedCkfTrajectoryBuilder::theMass
private

Mass hypothesis used for propagation

Definition at line 175 of file GroupedCkfTrajectoryBuilder.h.

int GroupedCkfTrajectoryBuilder::theMaxCand
private
    Maximum number of trajectory candidates 

to propagate to the next layer.

Definition at line 177 of file GroupedCkfTrajectoryBuilder.h.

Referenced by advanceOneLayer(), GroupedCkfTrajectoryBuilder(), and groupedLimitedCandidates().

unsigned int GroupedCkfTrajectoryBuilder::theMinNrOf2dHitsForRebuild
private

Minimum nr. of non-seed 2D hits required for rebuild.

Definition at line 195 of file GroupedCkfTrajectoryBuilder.h.

Referenced by GroupedCkfTrajectoryBuilder().

unsigned int GroupedCkfTrajectoryBuilder::theMinNrOfHitsForRebuild
private

Minimum nr. of non-seed hits required for rebuild. If ==0 the seeding part will remain untouched.

Definition at line 192 of file GroupedCkfTrajectoryBuilder.h.

Referenced by backwardFit(), and GroupedCkfTrajectoryBuilder().

double GroupedCkfTrajectoryBuilder::theptCut
private

ptCut

Definition at line 173 of file GroupedCkfTrajectoryBuilder.h.

bool GroupedCkfTrajectoryBuilder::theRequireSeedHitsInRebuild
private

Only accept rebuilt trajectories if they contain the seed hits.

Definition at line 190 of file GroupedCkfTrajectoryBuilder.h.

Referenced by GroupedCkfTrajectoryBuilder(), and rebuildSeedingRegion().