Belle II Software development
SVDLocalCalibrationsMonitorModule.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#pragma once
10
11#include <framework/core/Module.h>
12
13#include <svd/dbobjects/SVDLocalConfigParameters.h>
14#include <svd/dbobjects/SVDGlobalConfigParameters.h>
15#include <svd/calibration/SVDFADCMaskedStrips.h>
16#include <svd/calibration/SVDPulseShapeCalibrations.h>
17#include <svd/calibration/SVDNoiseCalibrations.h>
18#include <svd/calibration/SVDPedestalCalibrations.h>
19//#include <svd/calibration/SVDOccupancyCalibrations.h>
20#include <svd/calibration/SVDHotStripsCalibrations.h>
21
22#include <svd/dataobjects/SVDHistograms.h>
23#include <svd/dataobjects/SVDSummaryPlots.h>
24
25#include <string>
26#include <TFile.h>
27#include <TTree.h>
28#include <TBranch.h>
29#include <TH1F.h>
30#include <TH2F.h>
31
32namespace Belle2 {
41
42 public:
43
48
50 virtual void beginRun() override;
51
53 virtual void event() override;
54
56 virtual void endRun() override;
57
58 /* ROOT file related parameters */
59 TFile* m_rootFilePtr = nullptr;
60 TTree* m_tree = nullptr;
61 TTree* m_treeDetailed = nullptr;
63 //branches
64 TBranch* b_exp = nullptr;
65 TBranch* b_run = nullptr;
66 TBranch* b_date = nullptr;
67 TBranch* b_hv = nullptr;
68 TBranch* b_ladder = nullptr;
69 TBranch* b_layer = nullptr;
70 TBranch* b_sensor = nullptr;
71 TBranch* b_side = nullptr;
72 TBranch* b_strip = nullptr;
73 TBranch* b_occupancy = nullptr;
74 TBranch* b_mask = nullptr;
75 TBranch* b_maskAVE = nullptr;
76 TBranch* b_hotstrips = nullptr;
77 TBranch* b_hotstripsAVE = nullptr;
78 TBranch* b_pedestal = nullptr;
79 TBranch* b_pedestalAVE = nullptr;
80 TBranch* b_pedestalRMS = nullptr;
81 TBranch* b_gain = nullptr;
82 TBranch* b_gainAVE = nullptr;
83 TBranch* b_gainRMS = nullptr;
84 TBranch* b_noise = nullptr;
85 TBranch* b_noiseEl = nullptr;
86 TBranch* b_noiseAVE = nullptr;
87 TBranch* b_noiseRMS = nullptr;
88 TBranch* b_noiseElAVE = nullptr;
89 TBranch* b_noiseElRMS = nullptr;
90 TBranch* b_occupancyAVE = nullptr;
91 TBranch* b_occupancyRMS = nullptr;
92 TBranch* b_calPeakADC = nullptr;
93 TBranch* b_calPeakADCAVE = nullptr;
94 TBranch* b_calPeakADCRMS = nullptr;
95 TBranch* b_calPeakTime = nullptr;
96 TBranch* b_calPeakTimeAVE = nullptr;
97 TBranch* b_calPeakTimeRMS = nullptr;
98 TBranch* b_pulseWidth = nullptr;
99 TBranch* b_pulseWidthAVE = nullptr;
100 TBranch* b_pulseWidthRMS = nullptr;
102 //branch variables
103 int m_exp = -1;
104 int m_run = -1;
105 char m_date[11] = "";
106 float m_hv = -1;
107 int m_layer = -1;
108 int m_ladder = -1;
109 int m_sensor = -1;
110 int m_side = -1;
111 int m_strip = -1;
112 float m_mask = -1;
113 float m_maskAVE = -1;
114 float m_hotstrips = -1;
115 float m_hotstripsAVE = -1;
116 float m_occupancy = -1;
117 float m_noise = -1;
118 float m_noiseEl = -1;
119 float m_occupancyAVE = -1;
120 float m_occupancyRMS = -1;
121 float m_noiseAVE = -1;
122 float m_noiseRMS = -1;
123 float m_noiseElAVE = -1;
124 float m_noiseElRMS = -1;
125 float m_pedestal = -1;
126 float m_pedestalAVE = -1;
127 float m_pedestalRMS = -1;
128 float m_gain = -1;
129 float m_gainAVE = -1;
130 float m_gainRMS = -1;
131 float m_calPeakADC = -1;
132 float m_calPeakADCAVE = -1;
133 float m_calPeakADCRMS = -1;
134 float m_calPeakTime = -1;
135 float m_calPeakTimeAVE = -1;
136 float m_calPeakTimeRMS = -1;
137 float m_pulseWidth = -1;
138 float m_pulseWidthAVE = -1;
139 float m_pulseWidthRMS = -1;
141 std::string m_rootFileName = "SVDLocalCalibrationMonitor_output.root";
143 private:
152 // SVDOccupancyCalibrations m_OccupancyCal; /**< occupancy payload*/
153 // SVDHotStripsCalibrations m_HotStripsCal; /**< hot strips calibration*/
154
158 // SVDHistograms<TProfile>* m_pMask = nullptr; /**< masked strips profile */
159
160 //NOISE
166 //PEDESTAL
170 //GAIN
174 //PEAKTIME
178 //PEAKADC
182 //PULSEWIDTH
186 //OCCUPANCY
190 //HOT STRIPS
194 nullptr;
195 };
197}
198
Class for accessing objects in the database.
Definition: DBObjPtr.h:21
Base class for Modules.
Definition: Module.h:72
This class defines the dbobject and the method to access strips which are masked at FADC level.
template class for SVd histograms
Definition: SVDHistograms.h:24
Module to produce a list of histogram showing the uploaded local calibration constants.
SVDHistograms< TH2F > * m_h2Pedestal
pedestal (ADC) VS strip 2D histo
SVDHistograms< TH2F > * m_h2CalPeakADC
calPeakADC (ns) VS strip 2D histo
SVDFADCMaskedStrips m_MaskedStr
FADC masked strip payload.
SVDHistograms< TH2F > * m_h2Noise
noise (ADC) VS strip 2D histo
SVDLocalCalibrationsMonitorModule()
Constructor: Sets the description, the properties and the parameters of the module.
TTree * m_tree
pointer at tree containing the mean and RMS of calibration constants
TBranch * b_date
date of the noise local run in yyyy-mm-dd format
SVDHistograms< TH2F > * m_h2CalPeakTime
calPeakTime (ns) VS strip 2D histo
TTree * m_treeDetailed
pointer at tree containing the calibration constants of each strip
SVDHistograms< TH1F > * hm_hot_strips
hot strips per sensor
virtual void event() override
fill trees and histograms
SVDHistograms< TH1F > * m_hGain
gain (e-/ADC) histo
virtual void endRun() override
print the payloads uniqueID and write trees and histograms to the rootfile
SVDSummaryPlots * m_hHotStripsSummary
hot strip summary histo
SVDHistograms< TH1F > * m_hCalPeakTime
calPeakTime (ns) histo
SVDHistograms< TH2F > * m_h2Mask
mask VS strip 2D histo
SVDPulseShapeCalibrations m_PulseShapeCal
pulse shape payload
SVDHistograms< TH1F > * m_hNoiseEl
noise in e- histo
virtual void beginRun() override
initialize the TTrees and check validities of payloads
SVDHistograms< TH2F > * m_h2NoiseEl
noise in e- VS strip 2D histo
DBObjPtr< SVDLocalConfigParameters > m_svdLocalConfig
SVD Local Configuration payload.
char m_date[11]
date of the noise local run in yyyy-mm-dd format
SVDHistograms< TH1F > * m_hHotstrips
hot strips histo
SVDHistograms< TH1F > * m_hNoise
noise (ADC) histo
DBObjPtr< SVDGlobalConfigParameters > m_svdGlobalConfig
SVD Global Configuration payload.
SVDHistograms< TH1F > * m_hPulseWidth
calPeakTime (ns) histo
SVDHistograms< TH1F > * m_hCalPeakADC
calPeakADC (ns) histo
SVDHistograms< TH2F > * m_h2PulseWidth
calPeakTime (ns) VS strip 2D histo
SVDHistograms< TH1F > * m_hPedestal
pedestal (ADC) histo
SVDHistograms< TH2F > * m_h2Occupancy
occupancy (hits/evt) VS strip 2D histo
TBranch * b_occupancyAVE
sensor occupancy average (ADC)
TFile * m_rootFilePtr
pointer at root file used for storing histograms
SVDPedestalCalibrations m_PedestalCal
pedestal payload
SVDHistograms< TH2F > * m_h2Gain
gain (e-/ADC) VS strip 2D histo
SVDHistograms< TH2F > * m_h2Hotstrips
hotstrips VS strip 2D histo
SVDHistograms< TH1F > * m_hOccupancy
occupancy (hits/evt) histo
This class defines the dbobject and the method to access SVD calibrations from the noise local runs.
This class defines the dbobject and the method to access SVD calibrations from the noise local runs.
This class defines the dbobject and the methods to access the SVD calibrations from the local runs pr...
class to summarize SVD quantities per sensor and side
Abstract base class for different kinds of events.