12 bool setDetId,
bool removeApvShots,
float minGoodCharge)
13 : ChannelThreshold( chan ), SeedThreshold( seed ), ClusterThresholdSquared( cluster*cluster ),
14 MaxSequentialHoles( holes ), MaxSequentialBad( bad ), MaxAdjacentBad( adj ), RemoveApvShots(removeApvShots), minGoodCharge(minGoodCharge) {
24 template<
class digiDetSet>
29 if (!
setDetId( digis.detId() ))
return;
33 LogWarning(
"ThreeThresholdAlgorithm") <<
" id " << digis.detId() <<
" not usable???" << std::endl;
37 typename digiDetSet::const_iterator
38 scan( digis.begin() ),
46 while( scan !=
end ) {
56 uint16_t holes = testStrip -
lastStrip - 1;
57 return ( ( (!
ADCs.empty()) &
69 float Noise =
noise( strip );
77 ADCs.push_back( adc );
111 auto charge = int(
float(
adc)/
gain(strip++) + 0.5
f );
112 if(
adc < 254)
adc = ( charge > 1022 ? 255 :
113 ( charge > 253 ? 254 : charge ));
int adc(sample_type sample)
get the ADC sample (12 bits)
bool bad(const uint16_t &strip) const
uint16_t firstStrip() const
float ClusterThresholdSquared
bool isModuleBad(const uint32_t &id) const
float noise(const uint16_t &strip) const
void addToCandidate(const SiStripDigi &digi)
int bad(Items const &cont)
bool setDetId(const uint32_t)
bool candidateEnded(const uint16_t &) const
void stripByStripAdd(uint16_t strip, uint8_t adc, std::vector< SiStripCluster > &out)
SiStripApvShotCleaner ApvCleaner
ThreeThresholdAlgorithm(float, float, float, unsigned, unsigned, unsigned, std::string qualityLabel, bool setDetId, bool removeApvShots, float minGoodCharge)
bool stripByStripBegin(uint32_t id)
A Digi for the silicon strip detector, containing both strip and adc information, and suitable for st...
std::vector< uint8_t > ADCs
uint8_t MaxSequentialHoles
void stripByStripEnd(std::vector< SiStripCluster > &out)
bool isModuleUsable(const uint32_t &id) const
bool allBadBetween(uint16_t L, const uint16_t &R) const
void clusterizeDetUnit(const edm::DetSet< SiStripDigi > &, output_t::FastFiller &)
void appendBadNeighbors()
float gain(const uint16_t &strip) const
void clusterizeDetUnit_(const T &, output_t::FastFiller &)
bool clean(const edmNew::DetSet< SiStripDigi > &in, edmNew::DetSet< SiStripDigi >::const_iterator &scan, edmNew::DetSet< SiStripDigi >::const_iterator &end)
bool candidateAccepted() const
Power< A, B >::type pow(const A &a, const B &b)