CMS 3D CMS Logo

TkPhase2OTMeasurementDet.h
Go to the documentation of this file.
1 #ifndef TkPhase2OTMeasurementDet_H
2 #define TkPhase2OTMeasurementDet_H
3 
12 
13 class TrackingRecHit;
15 
17 public:
18 
20 
24 
25  TkPhase2OTMeasurementDet( const GeomDet* gdet,
26  Phase2OTMeasurementConditionSet & conditionSet );
27 
28  void update(Phase2OTMeasurementDetSet &data, const detset & detSet ) {
29  data.update(index(), detSet);
30  data.setActiveThisEvent(index(), true);
31  }
32 
34  bool isEmpty(const Phase2OTMeasurementDetSet & data) const {return data.empty(index());}
35 
37 
38  RecHitContainer recHits( const TrajectoryStateOnSurface&, const MeasurementTrackerEvent & dat ) const override;
39  bool recHits( const TrajectoryStateOnSurface& stateOnThisDet, const MeasurementEstimator&, const MeasurementTrackerEvent & data,
40  RecHitContainer & result, std::vector<float> &) const override;
41 
42 
43 
44  // simple hits
45  bool recHits(SimpleHitContainer & result,
46  const TrajectoryStateOnSurface& stateOnThisDet, const MeasurementEstimator&, const MeasurementTrackerEvent & data) const override {
47  assert("not implemented for Pixel yet"==nullptr);
48  }
49 
50 
51 
52  bool measurements( const TrajectoryStateOnSurface& stateOnThisDet,
53  const MeasurementEstimator& est, const MeasurementTrackerEvent & dat,
54  TempMeasurements & result) const override;
55 
56 
57  const PixelGeomDetUnit& specificGeomDet() const {return static_cast<PixelGeomDetUnit const &>(fastGeomDet());}
58 
60  buildRecHit( const Phase2TrackerCluster1DRef & cluster,
61  const LocalTrajectoryParameters & ltp) const;
62 
64  void setActive(bool active) { conditionSet().setActive(index(), active); }
67  void setActiveThisEvent(Phase2OTMeasurementDetSet & data, bool active) const { data.setActiveThisEvent(index(), active); }
69  bool isActive(const MeasurementTrackerEvent & data) const override { return data.phase2OTData().isActive(index()); }
70 
71  bool hasBadComponents( const TrajectoryStateOnSurface &tsos, const MeasurementTrackerEvent & dat ) const override ;
72 
73  //FIXME:just temporary solution for phase2!
75  // void setBadRocPositions(std::vector< LocalPoint > & positions) { badRocPositions_.swap(positions); }
77  // void clearBadRocPositions() { badRocPositions_.clear(); }
78 
79  int index() const { return index_; }
80  void setIndex(int i) { index_ = i; }
81 
82 private:
83  unsigned int id_;
84  // std::vector< LocalPoint > badRocPositions_;
85 
86  int index_;
88  Phase2OTMeasurementConditionSet & conditionSet() { return *theDetConditions; }
89  const Phase2OTMeasurementConditionSet & conditionSet() const { return *theDetConditions; }
90 
91  const ClusterParameterEstimator<Phase2TrackerCluster1D>* cpe() const { return conditionSet().cpe(); }
92 
93 };
94 
95 #endif
bool isEmpty(const Phase2OTMeasurementDetSet &data) const
bool recHits(SimpleHitContainer &result, const TrajectoryStateOnSurface &stateOnThisDet, const MeasurementEstimator &, const MeasurementTrackerEvent &data) const override
const Phase2OTMeasurementDetSet & phase2OTData() const
edm::Ref< edmNew::DetSetVector< Phase2TrackerCluster1D >, Phase2TrackerCluster1D > Phase2TrackerCluster1DRef
data_type const * const_iterator
Definition: DetSetNew.h:30
const PixelGeomDetUnit & specificGeomDet() const
edmNew::DetSet< Phase2TrackerCluster1D > detset
const Phase2OTMeasurementConditionSet & conditionSet() const
virtual RecHitContainer recHits(const TrajectoryStateOnSurface &, const MeasurementTrackerEvent &) const =0
const GeomDet & fastGeomDet() const
int index() const
Sets the list of bad ROCs, identified by the positions of their centers in the local coordinate frame...
virtual bool hasBadComponents(const TrajectoryStateOnSurface &tsos, const MeasurementTrackerEvent &data) const =0
const ClusterParameterEstimator< Phase2TrackerCluster1D > * cpe() const
std::shared_ptr< TrackingRecHit const > RecHitPointer
ClusterParameterEstimator< Phase2TrackerCluster1D >::LocalValues LocalValues
Phase2OTMeasurementConditionSet * theDetConditions
#define dso_hidden
Definition: Visibility.h:12
Phase2OTMeasurementConditionSet & conditionSet()
void setEmpty(Phase2OTMeasurementDetSet &data)
bool isActive(const MeasurementTrackerEvent &data) const override
Is this module active in reconstruction? It must be both &#39;setActiveThisEvent&#39; and &#39;setActive&#39;...
TrackingRecHit::ConstRecHitContainer RecHitContainer
std::vector< BaseTrackerRecHit * > SimpleHitContainer
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
void setActiveThisEvent(Phase2OTMeasurementDetSet &data, bool active) const
Turn on/off the module for reconstruction for one events. This per-event flag is cleared by any call ...
void setActive(bool active)
Turn on/off the module for reconstruction, for the full run or lumi (using info from DB...
virtual bool measurements(const TrajectoryStateOnSurface &stateOnThisDet, const MeasurementEstimator &est, const MeasurementTrackerEvent &data, TempMeasurements &result) const =0
void setActiveThisEvent(bool active)
void update(int i, const Phase2DetSet &detSet)
detset::const_iterator const_iterator
void update(Phase2OTMeasurementDetSet &data, const detset &detSet)