MdPatternFinder.h
Go to the documentation of this file.
1 #ifndef _MdPatternFinderAG_MdPatternFinder_h_
2 #define _MdPatternFinderAG_MdPatternFinder_h_
3 
4 #include <utl/config.h> // before all
5 
6 #include <fwk/VModule.h>
7 #include <mevt/MEvent.h>
8 #include <mevt/Module.h>
9 #include <mdet/Module.h>
10 #include <evt/ShowerRecData.h>
11 
12 #include <utl/Trace-fwd.h>
13 #include <utl/MessageLoggerConfig.h>
14 #include <utl/UnitsConfig.h>
15 
16 #include <string>
17 #include <iostream>
18 #include <memory>
19 
20 #include <boost/utility.hpp>
21 
22 
23 namespace MdPatternFinderAG {
24 
26  class VPatternFinderFunctor;
27 
40  class MdPatternFinder : public boost::noncopyable, public fwk::VModule {
41 
42  public:
44  enum Strategy {
45  eConsecutive, //< Check consecutiveness of 1s.
46  };
48  static const char* const kStrategyTags[];
49 
52  VModule::ResultFlag Init();
53  VModule::ResultFlag Run(evt::Event& e);
54  VModule::ResultFlag Finish();
55 
56  private:
59 
61  unsigned int fWindowSize;
62 
64  unsigned int fNOnes;
65 
68 
70  std::unique_ptr<VPatternFinderFunctor> fFinder;
71 
74 
76  unsigned int FillChannelRecData(mevt::Channel& ch, const mdet::Module& m);
77 
78  std::string PrintPatternMatchBins(const mevt::Channel& c) const;
79 
80  REGISTER_MODULE("MdPatternFinder", MdPatternFinder);
81 
82  };
83 
84 }
85 
86 
87 #endif
Helper class for configuration of units: value and name.
Definition: UnitsConfig.h:22
REGISTER_MODULE("MdPatternFinder", MdPatternFinder)
utl::UnitsConfig fUnits
Units configuration.
Strategy
Kind of possible counting criteria to be used.
unsigned int fNOnes
Number of 1s required.
static const char *const kStrategyTags[]
Tags for the types of strategy.
VModule::ResultFlag Run(evt::Event &e)
Run: invoked once per event.
Wraps a message to logger (received as parameter or created here), its access and configuration...
VModule::ResultFlag Init()
Initialize: invoked at beginning of run (NOT beginning of event)
Array of Scintillator.
unsigned int FillChannelRecData(mevt::Channel &ch, const mdet::Module &m)
Fill the data reconstructed for a channel.
Module interface.
Definition: VModule.h:53
std::unique_ptr< VPatternFinderFunctor > fFinder
Object performing the pattern identification on individuals channels.
std::string PrintPatternMatchBins(const mevt::Channel &c) const
Channel level event data.
VModule::ResultFlag Finish()
Finish: invoked at end of the run (NOT end of the event)
utl::MessageLoggerConfig fLog
Output messages handler.
constexpr double m
Definition: AugerUnits.h:121
unsigned int fWindowSize
The number of bins in the inhibition (veto) window.
Mudole to identify patterns in the binary channel traces according to a given strategy.
Strategy fStrategy
Counting stategy to be performed.

, generated on Tue Sep 26 2023.