File indexing completed on 2024-04-06 12:02:38
0001 #ifndef CondFormats_SiStripObjects_DaqScopeModeAnalysis_H
0002 #define CondFormats_SiStripObjects_DaqScopeModeAnalysis_H
0003
0004 #include "CondFormats/SiStripObjects/interface/CommissioningAnalysis.h"
0005 #include "DataFormats/SiStripCommon/interface/SiStripConstants.h"
0006 #include <sstream>
0007 #include <vector>
0008 #include <cstdint>
0009
0010
0011
0012
0013
0014
0015
0016 class DaqScopeModeAnalysis : public CommissioningAnalysis {
0017 public:
0018 DaqScopeModeAnalysis(const uint32_t& key);
0019
0020 DaqScopeModeAnalysis();
0021
0022 ~DaqScopeModeAnalysis() override { ; }
0023
0024 friend class DaqScopeModeAlgorithm;
0025
0026
0027 bool isValid() const override;
0028
0029 bool foundTickMark() const;
0030
0031 uint16_t frameFindingThreshold() const;
0032
0033
0034 inline const VVFloat& peds() const;
0035 inline const VVFloat& noise() const;
0036 inline const VVFloat& raw() const;
0037
0038
0039 inline const VVInt& dead() const;
0040 inline const VVInt& noisy() const;
0041
0042
0043 inline const VFloat& pedsMean() const;
0044 inline const VFloat& pedsSpread() const;
0045 inline const VFloat& noiseMean() const;
0046 inline const VFloat& noiseSpread() const;
0047 inline const VFloat& rawMean() const;
0048 inline const VFloat& rawSpread() const;
0049
0050
0051 inline const VFloat& pedsMax() const;
0052 inline const VFloat& pedsMin() const;
0053 inline const VFloat& noiseMax() const;
0054 inline const VFloat& noiseMin() const;
0055 inline const VFloat& rawMax() const;
0056 inline const VFloat& rawMin() const;
0057
0058
0059 inline const float& height() const;
0060
0061 inline const float& base() const;
0062
0063 inline const float& peak() const;
0064
0065
0066 void print(std::stringstream&, uint32_t apv_number = 0) override;
0067
0068
0069 inline void addErrorCode(const std::string& error) override;
0070
0071
0072 void summary(std::stringstream&) const override;
0073
0074
0075 void reset() override;
0076
0077
0078 static const float tickMarkHeightThreshold_;
0079
0080
0081 static const float frameFindingThreshold_;
0082
0083 private:
0084
0085 float height_;
0086
0087 float base_;
0088
0089 float peak_;
0090
0091
0092 VVFloat peds_;
0093
0094 VVFloat noise_;
0095
0096 VVFloat raw_;
0097
0098
0099 VVInt dead_;
0100
0101 VVInt noisy_;
0102
0103
0104 VFloat pedsMean_;
0105
0106 VFloat pedsSpread_;
0107
0108 VFloat noiseMean_;
0109
0110 VFloat noiseSpread_;
0111
0112 VFloat rawMean_;
0113
0114 VFloat rawSpread_;
0115
0116
0117 VFloat pedsMax_;
0118
0119 VFloat pedsMin_;
0120
0121
0122 VFloat noiseMax_;
0123
0124 VFloat noiseMin_;
0125
0126 VFloat rawMax_;
0127
0128 VFloat rawMin_;
0129
0130 bool legacy_;
0131 };
0132
0133 const DaqScopeModeAnalysis::VVFloat& DaqScopeModeAnalysis::peds() const { return peds_; }
0134 const DaqScopeModeAnalysis::VVFloat& DaqScopeModeAnalysis::noise() const { return noise_; }
0135 const DaqScopeModeAnalysis::VVFloat& DaqScopeModeAnalysis::raw() const { return raw_; }
0136
0137 const DaqScopeModeAnalysis::VVInt& DaqScopeModeAnalysis::dead() const { return dead_; }
0138 const DaqScopeModeAnalysis::VVInt& DaqScopeModeAnalysis::noisy() const { return noisy_; }
0139
0140 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::pedsMean() const { return pedsMean_; }
0141 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::pedsSpread() const { return pedsSpread_; }
0142 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::noiseMean() const { return noiseMean_; }
0143 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::noiseSpread() const { return noiseSpread_; }
0144 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::rawMean() const { return rawMean_; }
0145 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::rawSpread() const { return rawSpread_; }
0146
0147 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::pedsMax() const { return pedsMax_; }
0148 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::pedsMin() const { return pedsMin_; }
0149 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::noiseMax() const { return noiseMax_; }
0150 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::noiseMin() const { return noiseMin_; }
0151 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::rawMax() const { return rawMax_; }
0152 const DaqScopeModeAnalysis::VFloat& DaqScopeModeAnalysis::rawMin() const { return rawMin_; }
0153
0154 const float& DaqScopeModeAnalysis::height() const { return height_; }
0155 const float& DaqScopeModeAnalysis::base() const { return base_; }
0156 const float& DaqScopeModeAnalysis::peak() const { return peak_; }
0157 void DaqScopeModeAnalysis::addErrorCode(const std::string& error) { CommissioningAnalysis::addErrorCode(error); }
0158
0159 #endif