AdcToRoi2d.h
Go to the documentation of this file.
1 // AdcToRoi2d.h
2 //
3 // David Adams
4 // February 2021
5 //
6 // Tool to convert maps of ADC channel data into 2D ROIs.
7 //
8 // Configuration:
9 // LogLevel - Logging level: 0=none, 1=init, 2=call, ...
10 // Option - Action to take:
11 // 0 - none except logging
12 // 1 - One ROI for each channel map
13 // 2 - All channel maps merged into a single ROI.
14 // InputAdcMaps - Indices of the ADC maps that should be processed.
15 // If empty, all maps are processed.
16 // OutputNames - Names for the subdirectories where the 2D ROIs are written.
17 // If blank, they are written into the top level.
18 // Otherwise there should be one name for each entry in the ADC vector.
19 // Returned data map:
20 // a2r_nroi - # ROIS created
21 // a2r_nsams - # samples for each ROI
22 
23 #ifndef AdcToRoi2d_H
24 #define AdcToRoi2d_H
25 
27 #include "fhiclcpp/ParameterSet.h"
32 #include <iostream>
33 
35 
36 public:
37 
38  using Index = unsigned int;
39  using IndexVector = std::vector<Index>;
40  using Name = std::string;
41  using NameVector = std::vector<Name>;
42 
44 
45  ~AdcToRoi2d() override;
46 
47  // TpcDataTool methods.
48  DataMap updateTpcData(TpcData& tpd) const override;
49 
50 private:
51 
52  // Configuration data.
57 
58 };
59 
60 
61 #endif
int m_LogLevel
Definition: AdcToRoi2d.h:53
DataMap updateTpcData(TpcData &tpd) const override
unsigned int Index
std::string string
Definition: nybbler.cc:12
Index m_Option
Definition: AdcToRoi2d.h:54
NameVector m_OutputNames
Definition: AdcToRoi2d.h:56
std::vector< Name > NameVector
Definition: AdcToRoi2d.h:41
std::string Name
Definition: AdcToRoi2d.h:40
~AdcToRoi2d() override
static constexpr double ps
Definition: Units.h:99
AdcToRoi2d(fhicl::ParameterSet const &ps)
std::vector< Index > IndexVector
Definition: AdcToRoi2d.h:39
IndexVector m_InputAdcMaps
Definition: AdcToRoi2d.h:55