Belle II Software  release-08-01-10
DQMHistAnalysisPXDTrackCharge.h
1 /**************************************************************************
2  * basf2 (Belle II Analysis Software Framework) *
3  * Author: The Belle II Collaboration *
4  * *
5  * See git log for contributors and copyright holders. *
6  * This file is licensed under LGPL-3.0, see LICENSE.md. *
7  **************************************************************************/
8 //+
9 // File : DQMHistAnalysisPXDTrackCharge.h
10 // Description : DQM Analysis for PXD Tracked Cluster Charges
11 //-
12 
13 #pragma once
14 
15 #include <dqm/core/DQMHistAnalysis.h>
16 
17 #include <vxd/dataobjects/VxdID.h>
18 
19 #include <TFile.h>
20 #include <TH2.h>
21 #include <TF1.h>
22 #include <TLine.h>
23 #include <TGraphErrors.h>
24 
25 #include <RooRealVar.h>
26 #include <RooWorkspace.h>
27 
28 namespace Belle2 {
36 
37  // Public functions
38  public:
39 
44 
49 
53  void initialize(void) override final;
54 
58  void beginRun(void) override final;
59 
63  void event(void) override final;
64 
68  void endRun(void) override final;
69 
73  void terminate(void) override final;
74 
75  private:
76  // Data members
77 
81  double m_rangeLow;
83  double m_rangeHigh;
85  std::vector<int> m_excluded;
86 
88  std::vector<VxdID> m_PXDModules;
89 
91  RooWorkspace* m_rfws{};
93  RooRealVar* m_x{};
94 
96  TF1* m_fMean = nullptr;
98  TGraphErrors* m_gCharge = nullptr;
100  TCanvas* m_cCharge = nullptr;
102  std::map<VxdID, TCanvas*> m_cChargeMod {};
104  std::map<VxdID, std::array<std::array<TCanvas*, 4>, 6>> m_cChargeModASIC {};
106  TH1F* m_hTrackedClusters = nullptr;
108  TCanvas* m_cTrackedClusters = nullptr;
110  std::map<VxdID, TH2F*> m_hChargeModASIC2d {};
112  std::map<VxdID, TCanvas*> m_cChargeModASIC2d {};
113 
115  TLine* m_line_up{};
117  TLine* m_line_mean{};
119  TLine* m_line_low{};
120 
122  std::string m_refFileName;
124  TFile* m_refFile = nullptr;
126  bool m_color = true;
127 
130 
131  };
133 } // end namespace Belle2
134 
The base class for the histogram analysis module.
DQM Histogram Analysis for PXD Cluster Charge.
void terminate(void) override final
This method is called at the end of the event processing.
std::string m_refFileName
Reference Histogram Root file name.
bool m_color
Whether to use the color code for warnings and errors.
std::map< VxdID, std::array< std::array< TCanvas *, 4 >, 6 > > m_cChargeModASIC
Final Canvases for Fit and Ref per ASIC.
std::map< VxdID, TH2F * > m_hChargeModASIC2d
Final Canvas Fit and Ref per ASIC.
void initialize(void) override final
Initializer.
void endRun(void) override final
This method is called if the current run ends.
TLine * m_line_up
TLine object for upper limit of track cluster charge.
TGraphErrors * m_gCharge
Graph covering all modules.
std::vector< VxdID > m_PXDModules
IDs of all PXD Modules to iterate over.
std::string m_histogramDirectoryName
name of histogram directory
TLine * m_line_mean
TLine object for mean of track cluster charge.
TLine * m_line_low
TLine object for lower limit of track cluster charge.
std::vector< int > m_excluded
Indizes of excluded PXD Modules.
TH1F * m_hTrackedClusters
Histogram for TrackedClusters.
TCanvas * m_cTrackedClusters
Final Canvas for TrackedClusters.
std::map< VxdID, TCanvas * > m_cChargeMod
Final Canvases for Fit and Ref.
void beginRun(void) override final
Called when entering a new run.
void event(void) override final
This method is called for each event.
std::map< VxdID, TCanvas * > m_cChargeModASIC2d
Final Canvas Fit and Ref per ASIC.
TFile * m_refFile
The pointer to the reference file.
MonitoringObject is a basic object to hold data for the run-dependency monitoring Run summary TCanvas...
Abstract base class for different kinds of events.