CMS 3D CMS Logo

SiTrackerMultiRecHit.h
Go to the documentation of this file.
1 #ifndef SiTrackerMultiRecHit_H
2 #define SiTrackerMultiRecHit_H
3 
6 #include <vector>
7 #include <map>
8 /*
9 A rechit type suitable for tracking algorithm that use soft hit-to-track assignement,
10 such as the Deterministic Annealing Filter (DAF) or the Multi Track Filter (MTF).
11 it contains an OwnVector with the component rechits and a vector of weights
12 */
14 public:
17  ~SiTrackerMultiRecHit() override {}
18 
20  const LocalError&,
21  GeomDet const& idet,
22  const std::vector<std::pair<const TrackingRecHit*, float> >&,
23  double);
24 
25  SiTrackerMultiRecHit* clone() const override { return new SiTrackerMultiRecHit(*this); }
26 #ifdef NO_DICT
27  RecHitPointer cloneSH() const override { return std::make_shared<SiTrackerMultiRecHit>(*this); }
28 #endif
29 
30  // virtual int dimension() const {return 2;}
31  int dimension() const override;
32  void getKfComponents(KfComponentsHolder& holder) const override;
33 
34  // at the momement nobody care of MultiHit!!!
35  // used by trackMerger (to be improved)
36  OmniClusterRef const& firstClusterRef() const override {
37  return static_cast<BaseTrackerRecHit const&>(theHits.front()).firstClusterRef();
38  }
39 
41  std::vector<const TrackingRecHit*> recHits() const override;
42 
44  std::vector<TrackingRecHit*> recHits() override;
45 
46  //vector of weights
47  std::vector<float> const& weights() const { return theWeights; }
48  std::vector<float>& weights() { return theWeights; }
49 
50  //returns the weight for the i component
52  float weight(unsigned int i) const { return theWeights[i]; }
53  float& weight(unsigned int i) { return theWeights[i]; }
54 
55  //get the annealing
56  virtual double getAnnealingFactor() const { return annealing_; }
57 
58  bool sharesInput(const TrackingRecHit* other, SharedInputType what) const override;
59 
60 private:
62  std::vector<float> theWeights;
63  double annealing_;
64 };
65 
66 // Comparison operators
68  if (one.geographicalId() < other.geographicalId()) {
69  return true;
70  } else {
71  return false;
72  }
73 }
74 
75 #endif
mps_fire.i
i
Definition: mps_fire.py:428
SiPixelPI::one
Definition: SiPixelPayloadInspectorHelper.h:39
SiTrackerMultiRecHit::annealing_
double annealing_
Definition: SiTrackerMultiRecHit.h:63
GeomDet
Definition: GeomDet.h:27
SiTrackerMultiRecHit::recHits
std::vector< const TrackingRecHit * > recHits() const override
Access to component RecHits (if any)
Definition: SiTrackerMultiRecHit.cc:59
TrackingRecHitFwd.h
TrackingRecHit::RecHitPointer
std::shared_ptr< TrackingRecHit const > RecHitPointer
Definition: TrackingRecHit.h:24
OmniClusterRef
Definition: OmniClusterRef.h:12
SiTrackerMultiRecHit::~SiTrackerMultiRecHit
~SiTrackerMultiRecHit() override
Definition: SiTrackerMultiRecHit.h:17
SiTrackerMultiRecHit::weight
float & weight(unsigned int i)
Definition: SiTrackerMultiRecHit.h:53
TrackingRecHit::SharedInputType
SharedInputType
definition of equality via shared input
Definition: TrackingRecHit.h:59
SiTrackerMultiRecHit::sharesInput
bool sharesInput(const TrackingRecHit *other, SharedInputType what) const override
Definition: SiTrackerMultiRecHit.cc:21
BaseTrackerRecHit
Definition: BaseTrackerRecHit.h:15
SiTrackerMultiRecHit::weight
float weight(unsigned int i) const
Definition: SiTrackerMultiRecHit.h:52
trackingPlots.other
other
Definition: trackingPlots.py:1460
SiTrackerMultiRecHit::weights
std::vector< float > & weights()
Definition: SiTrackerMultiRecHit.h:48
Point3DBase< float, LocalTag >
edm::OwnVector::front
reference front()
Definition: OwnVector.h:459
TrackingRecHit::weight
virtual float weight() const
Definition: TrackingRecHit.h:137
SiTrackerMultiRecHit::getAnnealingFactor
virtual double getAnnealingFactor() const
Definition: SiTrackerMultiRecHit.h:56
SiTrackerMultiRecHit::weights
std::vector< float > const & weights() const
Definition: SiTrackerMultiRecHit.h:47
LocalError
Definition: LocalError.h:12
trackerHitRTTI::vector
Definition: trackerHitRTTI.h:21
operator<
bool operator<(const SiTrackerMultiRecHit &one, const SiTrackerMultiRecHit &other)
Definition: SiTrackerMultiRecHit.h:67
KfComponentsHolder
Definition: KfComponentsHolder.h:13
SiTrackerMultiRecHit::getKfComponents
void getKfComponents(KfComponentsHolder &holder) const override
Definition: SiTrackerMultiRecHit.cc:81
TrackingRecHit
Definition: TrackingRecHit.h:21
BaseTrackerRecHit.h
SiTrackerMultiRecHit::theHits
edm::OwnVector< TrackingRecHit > theHits
Definition: SiTrackerMultiRecHit.h:61
SiTrackerMultiRecHit::Base
BaseTrackerRecHit Base
Definition: SiTrackerMultiRecHit.h:15
TrackingRecHit::cloneSH
virtual RecHitPointer cloneSH() const
Definition: TrackingRecHit.h:80
SiTrackerMultiRecHit::SiTrackerMultiRecHit
SiTrackerMultiRecHit()
Definition: SiTrackerMultiRecHit.h:16
SiTrackerMultiRecHit::clone
SiTrackerMultiRecHit * clone() const override
Definition: SiTrackerMultiRecHit.h:25
SiTrackerMultiRecHit::theWeights
std::vector< float > theWeights
Definition: SiTrackerMultiRecHit.h:62
SiTrackerMultiRecHit::firstClusterRef
OmniClusterRef const & firstClusterRef() const override
Definition: SiTrackerMultiRecHit.h:36
SiTrackerMultiRecHit::dimension
int dimension() const override
Definition: SiTrackerMultiRecHit.cc:69
SiTrackerMultiRecHit
Definition: SiTrackerMultiRecHit.h:13
edm::OwnVector< TrackingRecHit >