1 #ifndef RECOLOCALTRACKER_SISTRIPZEROSUPPRESSION_SISTRIPAPVRESTORER_H
2 #define RECOLOCALTRACKER_SISTRIPZEROSUPPRESSION_SISTRIPAPVRESTORER_H
37 using medians_t = std::vector<std::pair<short, float>>;
58 using CMMap = std::map<uint32_t, std::vector<float>>;
70 bool checkBaseline(
const std::vector<int16_t>& baseline)
const;
edm::ESWatcher< SiStripQualityRcd > qualityWatcher_
SiStripAPVRestorer(const edm::ParameterSet &conf, edm::ConsumesCollector)
bool checkBaseline(const std::vector< int16_t > &baseline) const
uint32_t nSaturatedStrip_
void init(const edm::EventSetup &es)
uint32_t cleaningSequence_
const baselinemap_t & getBaselineMap() const
uint32_t deltaCMThreshold_
void baselineFollowerRestore(uint16_t apvN, uint16_t firstAPV, float median, digivector_t &digis)
bool applyBaselineRejection_
uint16_t baselineAndSaturationInspect(uint16_t firstAPV, const digivector_t &digis)
virtual ~SiStripAPVRestorer()
std::map< uint32_t, std::vector< float >> CMMap
const SiStripPedestals * pedestalHandle
std::map< uint16_t, digimap_t > smoothedMaps_
uint16_t baselineFollowerInspect(uint16_t firstAPV, const digivector_t &digis)
double filteredBaselineDerivativeSumSquare_
uint32_t nSigmaNoiseDerTh_
void flatRestore(uint16_t apvN, uint16_t firstAPV, digivector_t &digis)
edm::ESGetToken< SiStripQuality, SiStripQualityRcd > qualityToken_
static std::string const input
edm::ESWatcher< SiStripNoisesRcd > noiseWatcher_
void baselineFollower(const digimap_t &, digivector_t &baseline, float median)
const std::vector< bool > & getAPVFlags() const
void loadMeanCMMap(const edm::Event &)
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > siStripRawDigiToken_
uint16_t hybridEmulationInspect(uint16_t firstAPV, const digivector_t &digis)
std::vector< std::string > apvFlags_
baselinemap_t baselineMap_
const SiStripQuality * qualityHandle
std::map< uint16_t, digivector_t > baselinemap_t
void baselineCleaner(const digivector_t &adcs, digimap_t &smoothedpoints, uint16_t apvN)
const std::map< uint16_t, digimap_t > & getSmoothedPoints() const
void cleaner_LocalMinimumAdder(const digivector_t &adcs, digimap_t &smoothedpoints, uint16_t apvN)
std::vector< std::pair< short, float >> medians_t
double filteredBaselineMax_
void cleaner_HighSlopeChecker(digimap_t &smoothedpoints)
const SiStripNoises * noiseHandle
edm::EDGetTokenT< edm::DetSetVector< SiStripProcessedRawDigi > > siStripProcessedRawDigiToken_
bool flatRegionsFinder(const digivector_t &adcs, digimap_t &smoothedpoints, uint16_t apvN)
void cleaner_MonotonyChecker(digimap_t &smoothedpoints)
uint16_t inspectAndRestore(uint32_t detId, uint16_t firstAPV, const digivector_t &rawDigisPedSubtracted, digivector_t &processedRawDigi, const medians_t &vmedians)
void derivativeFollowerRestore(uint16_t apvN, uint16_t firstAPV, digivector_t &digis)
void createCMMapCMstored(const edm::DetSetVector< SiStripProcessedRawDigi > &input)
edm::ESGetToken< SiStripPedestals, SiStripPedestalsRcd > pedestalToken_
uint32_t consecThreshold_
uint16_t hybridFormatInspect(uint16_t firstAPV, const digivector_t &digis)
edm::ESWatcher< SiStripPedestalsRcd > pedestalWatcher_
std::vector< bool > apvFlagsBoolOverride_
std::map< uint16_t, digi_t > digimap_t
edm::ESGetToken< SiStripNoises, SiStripNoisesRcd > noiseToken_
uint16_t nullInspect(uint16_t firstAPV, const digivector_t &digis)
std::vector< bool > badAPVs_
std::vector< bool > apvFlagsBool_
uint16_t abnormalBaselineInspect(uint16_t firstAPV, const digivector_t &digis)
std::vector< digi_t > digivector_t
bool applyBaselineCleaner_
std::vector< float > median_
uint32_t distortionThreshold_
void restore(uint16_t firstAPV, digivector_t &digis)
uint16_t forceRestoreInspect(uint16_t firstAPV, const digivector_t &digis)
uint32_t hitStripThreshold_
static constexpr uint16_t nTotStripsPerAPV
void createCMMapRealPed(const edm::DetSetVector< SiStripRawDigi > &input)
uint16_t inspect(uint32_t detId, uint16_t firstAPV, const digivector_t &digis, const medians_t &vmedians)