#include <SiStripAPVRestorer.h>
Public Types | |
using | baselinemap_t = std::map< uint16_t, digivector_t > |
using | digi_t = int16_t |
using | digimap_t = std::map< uint16_t, digi_t > |
using | digivector_t = std::vector< digi_t > |
using | medians_t = std::vector< std::pair< short, float >> |
Public Member Functions | |
const std::vector< bool > & | getAPVFlags () const |
const baselinemap_t & | getBaselineMap () const |
const std::map< uint16_t, digimap_t > & | getSmoothedPoints () const |
void | init (const edm::EventSetup &es) |
uint16_t | inspect (uint32_t detId, uint16_t firstAPV, const digivector_t &digis, const medians_t &vmedians) |
uint16_t | inspectAndRestore (uint32_t detId, uint16_t firstAPV, const digivector_t &rawDigisPedSubtracted, digivector_t &processedRawDigi, const medians_t &vmedians) |
void | loadMeanCMMap (const edm::Event &) |
void | restore (uint16_t firstAPV, digivector_t &digis) |
virtual | ~SiStripAPVRestorer () |
Protected Member Functions | |
SiStripAPVRestorer (const edm::ParameterSet &conf, edm::ConsumesCollector) | |
Private Types | |
using | CMMap = std::map< uint32_t, std::vector< float >> |
Private Member Functions | |
uint16_t | abnormalBaselineInspect (uint16_t firstAPV, const digivector_t &digis) |
uint16_t | baselineAndSaturationInspect (uint16_t firstAPV, const digivector_t &digis) |
void | baselineCleaner (const digivector_t &adcs, digimap_t &smoothedpoints, uint16_t apvN) |
void | baselineFollower (const digimap_t &, digivector_t &baseline, float median) |
uint16_t | baselineFollowerInspect (uint16_t firstAPV, const digivector_t &digis) |
void | baselineFollowerRestore (uint16_t apvN, uint16_t firstAPV, float median, digivector_t &digis) |
bool | checkBaseline (const std::vector< int16_t > &baseline) const |
void | cleaner_HighSlopeChecker (digimap_t &smoothedpoints) |
void | cleaner_LocalMinimumAdder (const digivector_t &adcs, digimap_t &smoothedpoints, uint16_t apvN) |
void | cleaner_MonotonyChecker (digimap_t &smoothedpoints) |
void | createCMMapCMstored (const edm::DetSetVector< SiStripProcessedRawDigi > &input) |
void | createCMMapRealPed (const edm::DetSetVector< SiStripRawDigi > &input) |
void | derivativeFollowerRestore (uint16_t apvN, uint16_t firstAPV, digivector_t &digis) |
bool | flatRegionsFinder (const digivector_t &adcs, digimap_t &smoothedpoints, uint16_t apvN) |
void | flatRestore (uint16_t apvN, uint16_t firstAPV, digivector_t &digis) |
uint16_t | forceRestoreInspect (uint16_t firstAPV, const digivector_t &digis) |
uint16_t | hybridEmulationInspect (uint16_t firstAPV, const digivector_t &digis) |
uint16_t | hybridFormatInspect (uint16_t firstAPV, const digivector_t &digis) |
uint16_t | nullInspect (uint16_t firstAPV, const digivector_t &digis) |
Static Private Attributes | |
static constexpr uint16_t | nTotStripsPerAPV = 128 |
Friends | |
class | SiStripRawProcessingFactory |
Definition at line 25 of file SiStripAPVRestorer.h.
using SiStripAPVRestorer::baselinemap_t = std::map<uint16_t, digivector_t> |
Definition at line 38 of file SiStripAPVRestorer.h.
|
private |
Definition at line 58 of file SiStripAPVRestorer.h.
using SiStripAPVRestorer::digi_t = int16_t |
Definition at line 34 of file SiStripAPVRestorer.h.
using SiStripAPVRestorer::digimap_t = std::map<uint16_t, digi_t> |
Definition at line 36 of file SiStripAPVRestorer.h.
using SiStripAPVRestorer::digivector_t = std::vector<digi_t> |
Definition at line 35 of file SiStripAPVRestorer.h.
using SiStripAPVRestorer::medians_t = std::vector<std::pair<short, float>> |
Definition at line 37 of file SiStripAPVRestorer.h.
|
protected |
Definition at line 10 of file SiStripAPVRestorer.cc.
References Exception, inspectAlgo_, and restoreAlgo_.
|
inlinevirtual |
Definition at line 32 of file SiStripAPVRestorer.h.
|
inlineprivate |
Definition at line 258 of file SiStripAPVRestorer.cc.
References funct::abs(), apvFlags_, badAPVs_, detId_, deviation_, dataset::end, for(), fraction_, compareTotals::fs, SiStripBadStrip::getRange(), SiStripQuality::IsStripBad(), meanCM_, meanCMmap_, SiStripPI::min, nTotStripsPerAPV, qualityHandle, restoreAlgo_, and useRealMeanCM_.
Referenced by inspect().
|
inlineprivate |
Definition at line 223 of file SiStripAPVRestorer.cc.
References funct::abs(), apvFlags_, badAPVs_, deltaCMThreshold_, detId_, dataset::end, meanCM_, meanCMmap_, median_, nSaturatedStrip_, nTotStripsPerAPV, restoreAlgo_, digitizers_cfi::strip, and useRealMeanCM_.
Referenced by inspect().
|
inlineprivate |
Definition at line 485 of file SiStripAPVRestorer.cc.
References cleaner_HighSlopeChecker(), cleaner_LocalMinimumAdder(), cleaner_MonotonyChecker(), and cleaningSequence_.
Referenced by flatRegionsFinder().
|
inlineprivate |
Definition at line 626 of file SiStripAPVRestorer.cc.
References visualization-live-secondInstance_cfg::m, median(), minStripsToFit_, and nTotStripsPerAPV.
Referenced by baselineFollowerRestore().
|
inlineprivate |
Definition at line 178 of file SiStripAPVRestorer.cc.
References funct::abs(), apvFlags_, badAPVs_, SplitLinear::begin, deltaCMThreshold_, detId_, dataset::end, flatRegionsFinder(), meanCM_, meanCMmap_, median_, eostools::move(), nTotStripsPerAPV, restoreAlgo_, smoothedMaps_, and useRealMeanCM_.
Referenced by inspect().
|
inlineprivate |
Definition at line 342 of file SiStripAPVRestorer.cc.
References applyBaselineRejection_, apvFlagsBoolOverride_, baselineFollower(), baselineMap_, SplitLinear::begin, checkBaseline(), flatRegionsFinder(), eostools::move(), nTotStripsPerAPV, and smoothedMaps_.
Referenced by restore().
|
private |
Definition at line 672 of file SiStripAPVRestorer.cc.
References EcnaPython_AdcPeg12_S1_10_R170298_1_0_150_Dee0::cerr, ztail::d, filteredBaselineDerivativeSumSquare_, filteredBaselineMax_, mps_fire::i, dqmiolumiharvest::j, SiStripPI::max, nTotStripsPerAPV, and ctpps_dqm_sourceclient-live_cfg::test.
Referenced by baselineFollowerRestore().
|
inlineprivate |
Definition at line 593 of file SiStripAPVRestorer.cc.
References visualization-live-secondInstance_cfg::m.
Referenced by baselineCleaner().
|
inlineprivate |
Definition at line 526 of file SiStripAPVRestorer.cc.
References funct::abs(), gpuClustering::adc, detId_, first, SiStripNoises::getNoiseFast(), SiStripNoises::getRange(), visualization-live-secondInstance_cfg::m, gpuVertexFinder::noise, noiseHandle, nTotStripsPerAPV, edm::second(), slopeX_, slopeY_, and digitizers_cfi::strip.
Referenced by baselineCleaner().
|
inlineprivate |
Definition at line 504 of file SiStripAPVRestorer.cc.
References hitStripThreshold_, and edm::second().
Referenced by baselineCleaner().
|
private |
Definition at line 1002 of file SiStripAPVRestorer.cc.
References SiStripProcessedRawDigi::adc(), SplitLinear::begin, dataset::end, meanCMmap_, eostools::move(), and HcalDetIdTransform::transform().
Referenced by loadMeanCMMap().
|
private |
Definition at line 983 of file SiStripAPVRestorer.cc.
References SiStripPedestals::getPed(), SiStripPedestals::getRange(), meanCMmap_, eostools::move(), nTotStripsPerAPV, pedestalHandle, and digitizers_cfi::strip.
Referenced by loadMeanCMMap().
|
private |
Definition at line 1017 of file SiStripAPVRestorer.cc.
References funct::abs(), gradient_threshold_, last_gradient_, nTotStripsPerAPV, size_window_, and digitizers_cfi::strip.
Referenced by restore().
|
inlineprivate |
Definition at line 389 of file SiStripAPVRestorer.cc.
References gpuClustering::adc, applyBaselineCleaner_, baselineCleaner(), consecThreshold_, detId_, distortionThreshold_, SiStripNoises::getNoiseFast(), SiStripNoises::getRange(), SiStripPI::max, dqmiodumpmetadata::n, noiseHandle, nSigmaNoiseDerTh_, nSmooth_, and nTotStripsPerAPV.
Referenced by baselineFollowerInspect(), baselineFollowerRestore(), and hybridFormatInspect().
|
inlineprivate |
Definition at line 377 of file SiStripAPVRestorer.cc.
References baselineMap_, eostools::move(), and nTotStripsPerAPV.
Referenced by restore().
|
inlineprivate |
Definition at line 212 of file SiStripAPVRestorer.cc.
References apvFlags_, badAPVs_, nTotStripsPerAPV, and restoreAlgo_.
Referenced by inspect().
|
inline |
Definition at line 55 of file SiStripAPVRestorer.h.
References apvFlagsBool_.
|
inline |
|
inline |
Definition at line 54 of file SiStripAPVRestorer.h.
References smoothedMaps_.
|
inlineprivate |
Definition at line 317 of file SiStripAPVRestorer.cc.
References funct::abs(), apvFlags_, badAPVs_, deltaCMThreshold_, detId_, dataset::end, meanCM_, meanCMmap_, median_, nTotStripsPerAPV, and useRealMeanCM_.
Referenced by inspect().
|
inlineprivate |
Definition at line 150 of file SiStripAPVRestorer.cc.
References gpuClustering::adc, apvFlags_, badAPVs_, flatRegionsFinder(), eostools::move(), nTotStripsPerAPV, restoreAlgo_, smoothedMaps_, and digitizers_cfi::strip.
Referenced by inspect().
void SiStripAPVRestorer::init | ( | const edm::EventSetup & | es | ) |
Definition at line 58 of file SiStripAPVRestorer.cc.
References edm::ESWatcher< T >::check(), edm::EventSetup::getData(), noiseHandle, noiseToken_, noiseWatcher_, pedestalHandle, pedestalToken_, pedestalWatcher_, qualityHandle, qualityToken_, and qualityWatcher_.
uint16_t SiStripAPVRestorer::inspect | ( | uint32_t | detId, |
uint16_t | firstAPV, | ||
const digivector_t & | digis, | ||
const medians_t & | vmedians | ||
) |
Definition at line 80 of file SiStripAPVRestorer.cc.
References abnormalBaselineInspect(), apvFlags_, apvFlagsBool_, apvFlagsBoolOverride_, badAPVs_, baselineAndSaturationInspect(), baselineFollowerInspect(), baselineMap_, detId_, relativeConstraints::empty, Exception, forceRestoreInspect(), hybridEmulationInspect(), hybridFormatInspect(), mps_fire::i, inspectAlgo_, SiStripQuality::IsApvBad(), median_, nullInspect(), qualityHandle, and smoothedMaps_.
Referenced by inspectAndRestore().
uint16_t SiStripAPVRestorer::inspectAndRestore | ( | uint32_t | detId, |
uint16_t | firstAPV, | ||
const digivector_t & | rawDigisPedSubtracted, | ||
digivector_t & | processedRawDigi, | ||
const medians_t & | vmedians | ||
) |
Definition at line 70 of file SiStripAPVRestorer.cc.
References inspect(), and restore().
void SiStripAPVRestorer::loadMeanCMMap | ( | const edm::Event & | iEvent | ) |
Definition at line 972 of file SiStripAPVRestorer.cc.
References createCMMapCMstored(), createCMMapRealPed(), edm::Event::getByToken(), input, siStripProcessedRawDigiToken_, siStripRawDigiToken_, and useRealMeanCM_.
|
inlineprivate |
Definition at line 293 of file SiStripAPVRestorer.cc.
References apvFlags_, badAPVs_, detId_, compareTotals::fs, SiStripBadStrip::getRange(), SiStripQuality::IsStripBad(), nTotStripsPerAPV, qualityHandle, restoreAlgo_, and restoreThreshold_.
Referenced by inspect().
void SiStripAPVRestorer::restore | ( | uint16_t | firstAPV, |
digivector_t & | digis | ||
) |
Definition at line 127 of file SiStripAPVRestorer.cc.
References apvFlags_, baselineFollowerRestore(), derivativeFollowerRestore(), Exception, flatRestore(), forceNoRestore_, median_, and nTotStripsPerAPV.
Referenced by inspectAndRestore().
|
friend |
Definition at line 26 of file SiStripAPVRestorer.h.
|
private |
Definition at line 128 of file SiStripAPVRestorer.h.
Referenced by flatRegionsFinder().
|
private |
Definition at line 134 of file SiStripAPVRestorer.h.
Referenced by baselineFollowerRestore().
|
private |
Definition at line 103 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), baselineAndSaturationInspect(), baselineFollowerInspect(), forceRestoreInspect(), hybridEmulationInspect(), hybridFormatInspect(), inspect(), nullInspect(), and restore().
|
private |
Definition at line 104 of file SiStripAPVRestorer.h.
Referenced by getAPVFlags(), and inspect().
|
private |
Definition at line 105 of file SiStripAPVRestorer.h.
Referenced by baselineFollowerRestore(), and inspect().
|
private |
Definition at line 107 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), baselineAndSaturationInspect(), baselineFollowerInspect(), forceRestoreInspect(), hybridEmulationInspect(), hybridFormatInspect(), inspect(), and nullInspect().
|
private |
Definition at line 109 of file SiStripAPVRestorer.h.
Referenced by baselineFollowerRestore(), flatRestore(), getBaselineMap(), and inspect().
|
private |
Definition at line 129 of file SiStripAPVRestorer.h.
Referenced by baselineCleaner().
|
private |
Definition at line 125 of file SiStripAPVRestorer.h.
Referenced by flatRegionsFinder().
|
private |
Definition at line 119 of file SiStripAPVRestorer.h.
Referenced by baselineAndSaturationInspect(), baselineFollowerInspect(), and hybridEmulationInspect().
|
private |
Definition at line 102 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), baselineAndSaturationInspect(), baselineFollowerInspect(), cleaner_LocalMinimumAdder(), flatRegionsFinder(), hybridEmulationInspect(), inspect(), and nullInspect().
|
private |
Definition at line 121 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect().
|
private |
Definition at line 127 of file SiStripAPVRestorer.h.
Referenced by flatRegionsFinder().
|
private |
Definition at line 136 of file SiStripAPVRestorer.h.
Referenced by checkBaseline().
|
private |
Definition at line 135 of file SiStripAPVRestorer.h.
Referenced by checkBaseline().
|
private |
Definition at line 114 of file SiStripAPVRestorer.h.
Referenced by restore().
|
private |
Definition at line 120 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect().
|
private |
Definition at line 137 of file SiStripAPVRestorer.h.
Referenced by derivativeFollowerRestore().
|
private |
Definition at line 132 of file SiStripAPVRestorer.h.
Referenced by cleaner_MonotonyChecker().
|
private |
Definition at line 115 of file SiStripAPVRestorer.h.
Referenced by inspect(), and SiStripAPVRestorer().
|
private |
Definition at line 138 of file SiStripAPVRestorer.h.
Referenced by derivativeFollowerRestore().
|
private |
Definition at line 118 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), baselineAndSaturationInspect(), baselineFollowerInspect(), and hybridEmulationInspect().
|
private |
Definition at line 100 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), baselineAndSaturationInspect(), baselineFollowerInspect(), createCMMapCMstored(), createCMMapRealPed(), and hybridEmulationInspect().
|
private |
Definition at line 106 of file SiStripAPVRestorer.h.
Referenced by baselineAndSaturationInspect(), baselineFollowerInspect(), hybridEmulationInspect(), inspect(), and restore().
|
private |
Definition at line 133 of file SiStripAPVRestorer.h.
Referenced by baselineFollower().
|
private |
Definition at line 93 of file SiStripAPVRestorer.h.
Referenced by cleaner_LocalMinimumAdder(), flatRegionsFinder(), and init().
|
private |
Definition at line 90 of file SiStripAPVRestorer.h.
Referenced by init().
|
private |
Definition at line 96 of file SiStripAPVRestorer.h.
Referenced by init().
|
private |
Definition at line 123 of file SiStripAPVRestorer.h.
Referenced by baselineAndSaturationInspect().
|
private |
Definition at line 124 of file SiStripAPVRestorer.h.
Referenced by flatRegionsFinder().
|
private |
Definition at line 126 of file SiStripAPVRestorer.h.
Referenced by flatRegionsFinder().
|
staticprivate |
Definition at line 59 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), baselineAndSaturationInspect(), baselineFollower(), baselineFollowerInspect(), baselineFollowerRestore(), checkBaseline(), cleaner_LocalMinimumAdder(), createCMMapRealPed(), derivativeFollowerRestore(), flatRegionsFinder(), flatRestore(), forceRestoreInspect(), hybridEmulationInspect(), hybridFormatInspect(), nullInspect(), and restore().
|
private |
Definition at line 94 of file SiStripAPVRestorer.h.
Referenced by createCMMapRealPed(), and init().
|
private |
Definition at line 91 of file SiStripAPVRestorer.h.
Referenced by init().
|
private |
Definition at line 97 of file SiStripAPVRestorer.h.
Referenced by init().
|
private |
Definition at line 92 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), init(), inspect(), and nullInspect().
|
private |
Definition at line 89 of file SiStripAPVRestorer.h.
Referenced by init().
|
private |
Definition at line 95 of file SiStripAPVRestorer.h.
Referenced by init().
|
private |
Definition at line 116 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), baselineAndSaturationInspect(), baselineFollowerInspect(), forceRestoreInspect(), hybridFormatInspect(), nullInspect(), and SiStripAPVRestorer().
|
private |
Definition at line 122 of file SiStripAPVRestorer.h.
Referenced by nullInspect().
|
private |
Definition at line 87 of file SiStripAPVRestorer.h.
Referenced by loadMeanCMMap().
|
private |
Definition at line 86 of file SiStripAPVRestorer.h.
Referenced by loadMeanCMMap().
|
private |
Definition at line 139 of file SiStripAPVRestorer.h.
Referenced by derivativeFollowerRestore().
|
private |
Definition at line 130 of file SiStripAPVRestorer.h.
Referenced by cleaner_LocalMinimumAdder().
|
private |
Definition at line 131 of file SiStripAPVRestorer.h.
Referenced by cleaner_LocalMinimumAdder().
|
private |
Definition at line 108 of file SiStripAPVRestorer.h.
Referenced by baselineFollowerInspect(), baselineFollowerRestore(), getSmoothedPoints(), hybridFormatInspect(), and inspect().
|
private |
Definition at line 117 of file SiStripAPVRestorer.h.
Referenced by abnormalBaselineInspect(), baselineAndSaturationInspect(), baselineFollowerInspect(), hybridEmulationInspect(), and loadMeanCMMap().
|
private |
Definition at line 140 of file SiStripAPVRestorer.h.