CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ThreeThresholdAlgorithm.h
Go to the documentation of this file.
1 #ifndef RecoLocalTracker_SiStripClusterizer_ThreeThresholdAlgorithm_h
2 #define RecoLocalTracker_SiStripClusterizer_ThreeThresholdAlgorithm_h
5 
8 
9 public:
14 
15  // LazyGetter interface
16  void stripByStripAdd(State& state, uint16_t strip, uint8_t adc, std::vector<SiStripCluster>& out) const override;
17  void stripByStripEnd(State& state, std::vector<SiStripCluster>& out) const override;
18 
19  void stripByStripAdd(State& state, uint16_t strip, uint8_t adc, output_t::TSFastFiller& out) const override {
20  if (candidateEnded(state, strip))
21  endCandidate(state, out);
22  addToCandidate(state, strip, adc);
23  }
24 
25  void stripByStripEnd(State& state, output_t::TSFastFiller& out) const override { endCandidate(state, out); }
26 
27 private:
28  template <class T>
29  void clusterizeDetUnit_(const T&, output_t::TSFastFiller&) const;
30 
32  float,
33  float,
34  float,
35  unsigned,
36  unsigned,
37  unsigned,
38  bool removeApvShots,
39  float minGoodCharge);
40 
41  //constant methods with state information
42  uint16_t firstStrip(State const& state) const { return state.lastStrip - state.ADCs.size() + 1; }
43  bool candidateEnded(State const& state, const uint16_t&) const;
44  bool candidateAccepted(State const& state) const;
45 
46  //state modification methods
47  template <class T>
48  void endCandidate(State& state, T&) const;
49  void clearCandidate(State& state) const {
50  state.candidateLacksSeed = true;
51  state.noiseSquared = 0;
52  state.ADCs.clear();
53  }
54  void addToCandidate(State& state, const SiStripDigi& digi) const { addToCandidate(state, digi.strip(), digi.adc()); }
55  void addToCandidate(State& state, uint16_t strip, uint8_t adc) const;
56  void appendBadNeighbors(State& state) const;
57  void applyGains(State& state) const;
58 
63 };
64 
65 #endif
SiStripClusterizerConditions::Det Det
void stripByStripEnd(State &state, std::vector< SiStripCluster > &out) const override
void stripByStripEnd(State &state, output_t::TSFastFiller &out) const override
void stripByStripAdd(State &state, uint16_t strip, uint8_t adc, std::vector< SiStripCluster > &out) const override
bool candidateAccepted(State const &state) const
friend class TSFastFiller
void endCandidate(State &state, T &) const
void clearCandidate(State &state) const
void appendBadNeighbors(State &state) const
const uint16_t & strip() const
Definition: SiStripDigi.h:33
void stripByStripAdd(State &state, uint16_t strip, uint8_t adc, output_t::TSFastFiller &out) const override
A Digi for the silicon strip detector, containing both strip and adc information, and suitable for st...
Definition: SiStripDigi.h:12
bool candidateEnded(State const &state, const uint16_t &) const
void clusterizeDetUnit(const edm::DetSet< SiStripDigi > &, output_t::TSFastFiller &) const override
void addToCandidate(State &state, const SiStripDigi &digi) const
void applyGains(State &state) const
ThreeThresholdAlgorithm(const edm::ESGetToken< SiStripClusterizerConditions, SiStripClusterizerConditionsRcd > &, float, float, float, unsigned, unsigned, unsigned, bool removeApvShots, float minGoodCharge)
const uint16_t & adc() const
Definition: SiStripDigi.h:34
long double T
uint16_t firstStrip(State const &state) const
uint16_t *__restrict__ uint16_t const *__restrict__ adc
void clusterizeDetUnit_(const T &, output_t::TSFastFiller &) const