AdcRangeSampleScaler.h
Go to the documentation of this file.
1 // AdcRangeSampleScaler.h
2 //
3 // David Adams
4 // Augest 2020
5 //
6 // Tool to scale the samples in AdcSampleData according to channel range.
7 //
8 // Configuration:
9 // LogLevel: 0=silent, 1=init, 2=each event, >2=more
10 // RangeLimits: Channel limits
11 // ScaleFactors: Factor by which samples are scaled.
12 //
13 // All samples for channel ICHA are scaled by ScaleFactors[IRAN] where
14 // IRAN is the first range for which ICHA < Rangelimits[IRAN].
15 // If RangeModulus > 0, then ICHA%RangeModulus is used in place of ICHA.
16 
17 #ifndef AdcRangeSampleScaler_H
18 #define AdcRangeSampleScaler_H
19 
21 #include "fhiclcpp/ParameterSet.h"
23 
25 
26 public:
27 
29 
30  ~AdcRangeSampleScaler() override =default;
31 
32  DataMap update(AdcChannelData& acd) const override;
33 
34 private:
35 
36  using Index = unsigned int;
37  using IndexVector = std::vector<Index>;
38  using FloatVector = std::vector<float>;
39 
40  // Configuration data.
45 
46 };
47 
48 
49 #endif
unsigned int Index
DataMap update(AdcChannelData &acd) const override
AdcRangeSampleScaler(fhicl::ParameterSet const &ps)
static constexpr double ps
Definition: Units.h:99
std::vector< Index > IndexVector
std::vector< float > FloatVector
~AdcRangeSampleScaler() override=default