All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
IRawDigitHistogramTool.h
Go to the documentation of this file.
1 #ifndef IRawDigitHistogramTool_H
2 #define IRawDigitHistogramTool_H
3 ////////////////////////////////////////////////////////////////////////
4 //
5 // Class: IRawDigitHistogramTool
6 // Module Type: tool
7 // File: IRawDigitHistogramTool.h
8 //
9 // This provides an interface for tools which do histogramming
10 // of various quantities associated to recob::Hit objects
11 //
12 // Created by Tracy Usher (usher@slac.stanford.edu) on October 16, 2017
13 //
14 ////////////////////////////////////////////////////////////////////////
15 
16 #include "fhiclcpp/ParameterSet.h"
17 #include "art/Framework/Services/Registry/ServiceHandle.h"
18 #include "art_root_io/TFileService.h"
19 #include "canvas/Persistency/Common/Ptr.h"
22 namespace detinfo {
23  class DetectorClocksData;
24  class DetectorPropertiesData;
25 }
26 
28 {
29 public:
30  /**
31  * @brief Virtual Destructor
32  */
33  virtual ~IRawDigitHistogramTool() noexcept = default;
34 
35  /**
36  * @brief Interface for configuring the particular algorithm tool
37  *
38  * @param ParameterSet The input set of parameters for configuration
39  */
40  virtual void configure(const fhicl::ParameterSet&) = 0;
41 
42  /**
43  * @brief Interface for initializing the histograms to be filled
44  *
45  * @param TFileService handle to the TFile service
46  * @param string subdirectory to store the hists in
47  */
48  virtual void initializeHists(detinfo::DetectorClocksData const& clockData,
50  art::ServiceHandle<art::TFileService>&, const std::string&) = 0;
51 
52  /**
53  * @brief Interface for method to executve at the end of run processing
54  *
55  * @param int number of events to use for normalization
56  */
57  virtual void endJob(int numEvents) = 0;
58 
59  /**
60  * @brief Interface for filling histograms
61  */
62  using RawDigitPtrVec = std::vector<art::Ptr<raw::RawDigit>>;
63  using SimChannelMap = std::map<raw::ChannelID_t, const sim::SimChannel*>;
64 
65  virtual void fillHistograms(const detinfo::DetectorClocksData&,
67  const RawDigitPtrVec&, const SimChannelMap&) const = 0;
68 };
69 
70 #endif
std::map< raw::ChannelID_t, const sim::SimChannel * > SimChannelMap
std::vector< art::Ptr< raw::RawDigit >> RawDigitPtrVec
Interface for filling histograms.
Definition of basic raw digits.
virtual void configure(const fhicl::ParameterSet &)=0
Interface for configuring the particular algorithm tool.
virtual ~IRawDigitHistogramTool() noexcept=default
Virtual Destructor.
virtual void fillHistograms(const detinfo::DetectorClocksData &, const detinfo::DetectorPropertiesData &, const RawDigitPtrVec &, const SimChannelMap &) const =0
Contains all timing reference information for the detector.
object containing MC truth information necessary for making RawDigits and doing back tracking ...
virtual void endJob(int numEvents)=0
Interface for method to executve at the end of run processing.
virtual void initializeHists(detinfo::DetectorClocksData const &clockData, detinfo::DetectorPropertiesData const &detProp, art::ServiceHandle< art::TFileService > &, const std::string &)=0
Interface for initializing the histograms to be filled.
auto const detProp