RdChannelSpectrumAverager.h
Go to the documentation of this file.
1 
9 #ifndef _RdChannelSpectrumAverager_h_
10 #define _RdChannelSpectrumAverager_h_
11 
12 #include <fwk/VModule.h>
13 #include <utl/Trace.h>
14 
15 // you should assign your module to a namespace
16 
17 namespace RdChannelSpectrumAverager {
18 
29 
30  public:
31  // If you define a constructor, you MUST provide an implementation
32  // for it, otherwise the REGISTER_MODULE macro will not register
33  // your module. (Here, implementation is in RdChannelSpectrumAverager.cc)
36 
40 
41  private:
43  std::map< std::pair<int,int>, utl::Trace<double> > fMeanAmplitude;
44 
46  std::map< std::pair<int,int>, unsigned long int > fCounter;
47 
48  // The REGISTER_MODULE macro makes the framework aware of your module.
49  // You need to put this macro at the very end of your module class definition.
50  // Give your module a name (first argument) and specify its
51  // class name (second argument). In the ModuleSequenceExample.xml file,
52  // you can see this module being refered to by the name we give it here.
53 
54  REGISTER_MODULE("RdChannelSpectrumAverager", RdChannelSpectrumAverager);
55  };
56 
57 }
58 
59 
60 #endif
61 
62 // Configure (x)emacs for this file ...
63 // Local Variables:
64 // mode:c++
65 // compile-command: "make -k"
66 // End:
REGISTER_MODULE("RdChannelSpectrumAverager", RdChannelSpectrumAverager)
std::map< std::pair< int, int >, utl::Trace< double > > fMeanAmplitude
mean amplitude spectrum for each station and channel ID
std::map< std::pair< int, int >, unsigned long int > fCounter
Counts the number of events processed for each station and channel ID.
fwk::VModule::ResultFlag Init()
Initialize: invoked at beginning of run (NOT beginning of event)
Module interface.
Definition: VModule.h:53
ResultFlag
Flag returned by module methods to the RunController.
Definition: VModule.h:60
fwk::VModule::ResultFlag Finish()
Finish: invoked at end of the run (NOT end of the event)
Replaces the amplitude spectrum by the mean of all ampltiude spectra processed so far...
fwk::VModule::ResultFlag Run(evt::Event &event)
Run: invoked once per event.

, generated on Tue Sep 26 2023.