MedianPedestalService.h
Go to the documentation of this file.
1 // MedianPedestalService.h
2 //
3 // David Adams
4 // June 2016
5 // Updated Jan 2017 to add UseMean.
6 //
7 // Implementation of service that evluates a pedestal as the median of
8 // an input ADC signal vector.
9 //
10 // Configuration:
11 // LogLevel - Message logging level: 0=none, 1=initialization, 2+=every event
12 // UseMean - Evaluate pedestal with mean instead of median.
13 // SkipFlaggedSamples - Exclude ticks for which flag != AdcGood
14 // SkipSignals - Exclude ticks identified as signal
15 
16 #ifndef MedianPedestalService_H
17 #define MedianPedestalService_H
18 
21 
22 namespace geo {
23  class Geometry;
24 }
25 
26 namespace lbne {
27  class ChannelMapService;
28 }
29 
31 
32 public:
33 
35 
36  int evaluate(const AdcChannelData& data,
37  AdcSignal* pped =nullptr, AdcSignal* prms =nullptr,
38  AdcSignal* ppederr =nullptr, AdcSignal* prmserr =nullptr) const;
39 
40  std::ostream& print(std::ostream& out =std::cout, std::string prefix ="") const;
41 
42 private:
43 
44  // Configuration parameters.
46  bool m_UseMean;
49 
50  // Services.
51  //const geo::Geometry* m_pGeometry; // unused
52  //const lbne::ChannelMapService* m_pChannelMap; // unused
53 
54  // List of channels for each orientation and group.
55  std::vector<std::vector<AdcChannelVector>> m_GroupChannels;
56 
57 };
58 
60 
61 #endif
std::string string
Definition: nybbler.cc:12
float AdcSignal
Definition: AdcTypes.h:21
DECLARE_ART_SERVICE_INTERFACE_IMPL(MySharedService, art::test::MyServiceInterface, SHARED) DEFINE_ART_SERVICE_INTERFACE_IMPL(MySharedService
std::vector< std::vector< AdcChannelVector > > m_GroupChannels
LArSoft geometry interface.
Definition: ChannelGeo.h:16