ReplaceCompressService.h
Go to the documentation of this file.
1 // ReplaceCompressService.h
2 //
3 // David Adams
4 // November 2015
5 //
6 // Utility/service to compress an ADC vector by replacing filtered out values
7 // with a configurable zero value plus a passed offset (pedestal).
8 //
9 // FCL parameters
10 // Zero [0] - replacement value
11 
12 #ifndef ReplaceCompressService_H
13 #define ReplaceCompressService_H
14 
16 
17 namespace fhicl {
18 class ParameterSet;
19 }
20 namespace art {
21 class ActivityRegistry;
22 }
23 
25 
26 public:
27 
28  // Ctor from parameters that characterize the algorithm.
30 
31  // Ctor from fcl.
33 
34  // Compress a vector of signals.
35  // Suppressed signals are replaced with the value of offset + (FCL parameter) Zero.
36  int compress(AdcCountVector& sigs,
37  const AdcFilterVector& keep,
38  AdcCount offset,
39  raw::Compress_t& comp) const;
40 
41  // Return the value assigned to suppressed channels.
42  AdcCount zero() const;
43 
44  // Print the configuration.
45  std::ostream& print(std::ostream& out =std::cout, std::string prefix =" ") const;
46 
47 private:
48 
50 
51 };
52 
54 
55 #endif
std::vector< AdcCount > AdcCountVector
Definition: AdcTypes.h:19
enum raw::_compress Compress_t
std::string string
Definition: nybbler.cc:12
DECLARE_ART_SERVICE_INTERFACE_IMPL(MySharedService, art::test::MyServiceInterface, SHARED) DEFINE_ART_SERVICE_INTERFACE_IMPL(MySharedService
std::vector< bool > AdcFilterVector
Definition: AdcTypes.h:27
short AdcCount
Definition: AdcTypes.h:18