15#include <dqm/core/DQMHistAnalysis.h>
65 chid mychid =
nullptr;
66 double lastNHits = 0.0;
67 double lastNEvts = 0.0;
84 void event() override final;
89 void endRun() override final;
112 static T*
divide(T* num, T* den,
float scale = 1.0f, T* res =
nullptr)
115 TString name = TString(
"occu_from_") + num->GetName();
116 res = (T*)num->Clone(name);
118 for (
int i = 0; i < num->GetNcells(); i++) {
119 float n = num->GetBinContent(i), d = den->GetBinContent(i), e = num->GetBinError(i);
120 res->SetBinContent(i, d ? scale * n / d : 0.0f);
121 res->SetBinError(i, d ? scale * e / d : 0.0f);
161 std::vector<MyPV> m_myPVs;
162 double m_lastPVUpdate = -1.0;
163 chid m_timeSinceLastPVUpdateChan =
nullptr;
164 struct dbr_ctrl_enum m_stateCtrl;
165 chid m_stateChan =
nullptr;
The base class for the histogram analysis module.
static TH1 * findHist(const std::string &histname, bool onlyIfUpdated=false)
Get histogram from list (no other search).
The SVD dose-monitoring DQM analysis module.
void initialize() override final
Initializer.
std::vector< TCanvas * > m_c_occuLER
Canvases for the occu.
std::vector< TH2F * > m_h_occuHERAll
Histograms for the occu.
std::vector< TH1F * > m_h_occuLER1
Histograms for the 1D occu.
std::string m_deltaTPVSuffix
Suffix of the update-time monitoring PV.
std::vector< TCanvas * > m_c_occuHERAll
Canvases for the occu.
std::vector< TCanvas * > m_c_instOccu
Canvases for the instantaneous occupancy.
std::vector< TH2F * > m_h_occuLER
Histograms for the occ.
double m_epicsUpdateSeconds
Minimum interval between successive PV updates.
std::vector< TH2F * > m_h_occuLERAll
Histograms for the occu.
std::vector< TCanvas * > m_c_occuLER1
Canvases for the 1D occu.
std::string m_pvPrefix
Prefix for EPICS PVs.
std::vector< TH1F * > m_h_occuHER1All
Histograms for the 1D occu.
MonitoringObject * m_monObj
Monitoring object for MiraBelle.
std::vector< TCanvas * > m_c_occuLER1All
Canvases for the 1D occu.
void event() override final
This method is called for each event.
std::string m_statePVSuffix
Suffix of the state PV.
std::vector< TCanvas * > m_c_occuLERAll
Canvases for the occu.
std::vector< TCanvas * > m_c_occuHER
Canvases for the occu.
std::vector< TCanvas * > m_c_occuHER1All
Canvases for the 1D occu.
static void carryOverflowOver(TH1F *h)
Carries the content of the overflow bin into the last bin.
static const std::vector< SensorGroup > c_sensorGroups
List of sensors groups.
std::vector< TH1F * > m_h_occuLER1All
Histograms for the 1D occu.
void endRun() override final
This method is called if the current run ends.
void updateCanvases()
updated canvas
void beginRun() override final
Called when entering a new run.
T * findHistT(TString name)
Utility method.
std::vector< TH1F * > m_h_occuHER1
Histograms for the 1D occu.
std::vector< TCanvas * > m_c_instOccuAll
Canvases for the instantaneous occupancy.
static T * divide(T *num, T *den, float scale=1.0f, T *res=nullptr)
Divide two histograms, ignoring errors on the second histogram.
TPaveText * m_legend
Legend of the inst.
std::vector< TCanvas * > m_c_occuHER1
Canvases for the 1D occu.
std::vector< TH2F * > m_h_occuHER
Histograms for the occu.
std::string m_pvSuffix
Suffix for EPICS PVs.
MonitoringObject is a basic object to hold data for the run-dependency monitoring Run summary TCanvas...
Abstract base class for different kinds of events.
A struct to define the sensors group we average over.
const char * pvMiddle
Middle part of the PV name.
TString titleSuffix
Suffix for the title of the canvases.
TString nameSuffix
Suffix of the name of the histograms.
int nStrips
Total number of strips in the sensor group.