test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
GroupedCkfTrajectoryBuilder.h
Go to the documentation of this file.
1 #ifndef GroupedCkfTrajectoryBuilder_H
2 #define GroupedCkfTrajectoryBuilder_H
3 
7 
10 
12 
13 #include <vector>
14 
15 
17 
18 
25 
26  public:
29 
32 
34  // virtual void setEvent(const edm::Event& event) const;
35 
37  TrajectoryContainer trajectories(const TrajectorySeed&) const;
38 
40  void trajectories(const TrajectorySeed&, TrajectoryContainer &ret) const;
41 
43  TrajectoryContainer trajectories(const TrajectorySeed&, const TrackingRegion&) const;
44 
46  void trajectories(const TrajectorySeed&, TrajectoryContainer &ret, const TrackingRegion&) const;
47 
49  // also new interface returning the start Trajectory...
51  TrajectoryContainer &ret,
52  const TrajectoryFilter*) const;
53 
54 
55 
63  TrajectoryContainer& result) const ;
64 
65  // same as above using the precomputed startingTraj..
66  void rebuildTrajectories(TempTrajectory const & startingTraj, const TrajectorySeed&,
67  TrajectoryContainer& result) const ;
68 
69 
70  // Access to lower level components
71  const TrajectoryStateUpdator& updator() const {return *theUpdator;}
73 
74  // PropagationDirection direction() const {return theDirection;}
75 
77  double chiSquareCut() {return theChiSquareCut;}
78 
80  int maxCand() {return theMaxCand;}
81 
82 
84  float lostHitPenalty() {return theLostHitPenalty;}
85 
86  // /** Tells whether an intermediary cleaning stage should take place during TB. */
87  // bool intermediateCleaning() {return theIntermediateCleaning;}
88 
90  double ptCut() {return theptCut;}
91 
93  double mass() {return theMass;}
94 
95 protected:
96  void setEvent_(const edm::Event& iEvent, const edm::EventSetup& iSetup) override;
97 
98  virtual void analyseSeed(const TrajectorySeed& seed) const{}
99 
100  virtual void analyseMeasurements( const std::vector<TM>& meas,
101  const Trajectory& traj) const{}
102  virtual void analyseResult( const TrajectoryContainer& result) const {}
103 
104 private :
105 // /// no copy constructor
106 // GroupedCkfTrajectoryBuilder (const GroupedCkfTrajectoryBuilder&) = default;
107 //
108 // /// no assignment operator
109 // GroupedCkfTrajectoryBuilder& operator= (const GroupedCkfTrajectoryBuilder&) dso_internal;
110 
111 
112  inline bool tkxor(bool a, bool b) const dso_internal {return (a||b) && !(a&&b);}
113  // to be ported later
114 
115  bool advanceOneLayer( const TrajectorySeed& seed,
116  TempTrajectory& traj,
117  const TrajectoryFilter* regionalCondition,
118  const Propagator* propagator,
119  bool inOut,
120  TempTrajectoryContainer& newCand,
121  TempTrajectoryContainer& result) const dso_internal;
122 
123  void groupedLimitedCandidates( const TrajectorySeed& seed,
124  TempTrajectory const& startingTraj,
125  const TrajectoryFilter* regionalCondition,
126  const Propagator* propagator,
127  bool inOut,
128  TempTrajectoryContainer& result) const dso_internal;
129 
132  TempTrajectory const& startingTraj,
133  TempTrajectoryContainer& result) const dso_internal;
134 
135  //** try to find additional hits in seeding region for a candidate
136  //* (returns number of trajectories added) *
138  const std::vector<const TrackingRecHit*>& seedHits,
139  TempTrajectory& candidate,
140  TempTrajectoryContainer& result) const dso_internal;
141 
142  // ** Backward fit of trajectory candidate except seed. Fit result is returned. invalid if fit failed
143  // * remaining hits are returned remainingHits.
144  TempTrajectory backwardFit (TempTrajectory& candidate, unsigned int nSeed,
145  const TrajectoryFitter& fitter,
146  std::vector<const TrackingRecHit*>& remainingHits) const dso_internal;
147 
149  bool verifyHits (TempTrajectory::DataContainer::const_iterator rbegin,
150  size_t maxDepth,
151  const std::vector<const TrackingRecHit*>& hits) const dso_internal;
152 
154  void groupedIntermediaryClean(TempTrajectoryContainer& theTrajectories) const dso_internal;
155 
156 
159  if ( dir==alongMomentum ) return oppositeToMomentum;
160  if ( dir==oppositeToMomentum ) return alongMomentum;
161  return dir;
162  }
163 
164 
165 private:
167 
168  // typedef deque< const TrajectoryFilter*> StopCondContainer;
169  // StopCondContainer theStopConditions;
170 
173  double theptCut;
175  double theMass;
186 
187  bool theLockHits;
203 
205 
206 // mutable TempTrajectoryContainer work_; // Better here than alloc every time
207  enum work_MaxSize_Size_ { work_MaxSize_ = 50 }; // if it grows above this number, it is forced to resize to half this amount when cleared
208 };
209 
210 #endif
virtual void analyseMeasurements(const std::vector< TM > &meas, const Trajectory &traj) const
tuple ret
prodAgent to be discontinued
virtual void rebuildSeedingRegion(const TrajectorySeed &, TrajectoryContainer &result) const
const TrajectoryStateUpdator * theUpdator
virtual void analyseSeed(const TrajectorySeed &seed) const
double mass()
Mass hypothesis used for propagation.
PropagationDirection
tuple result
Definition: mps_fire.py:83
virtual void setEvent_(const edm::Event &iEvent, const edm::EventSetup &iSetup)=0
int iEvent
Definition: GenABIO.cc:230
virtual void analyseResult(const TrajectoryContainer &result) const
static PropagationDirection oppositeDirection(PropagationDirection dir)
change of propagation direction
virtual void rebuildTrajectories(TempTrajectory const &startingTraj, const TrajectorySeed &seed, TrajectoryContainer &result) const
const Chi2MeasurementEstimatorBase & estimator() const
virtual TempTrajectory buildTrajectories(const TrajectorySeed &seed, TrajectoryContainer &ret, const TrajectoryFilter *) const
virtual TrajectoryContainer trajectories(const TrajectorySeed &) const =0
virtual ~GroupedCkfTrajectoryBuilder()
destructor
double b
Definition: hdecay.h:120
const TrajectoryStateUpdator & updator() const
#define dso_internal
double a
Definition: hdecay.h:121
bool tkxor(bool a, bool b) const
dbl *** dir
Definition: mlp_gen.cc:35
std::vector< Trajectory > TrajectoryContainer
const Chi2MeasurementEstimatorBase * theEstimator