27 EcalDAQTowerStatusSummaryPlot() :
32 bool fill(
const std::vector<std::tuple<cond::Time_t, cond::Hash> >& iovs)
override {
34 auto iov = iovs.front();
36 unsigned int run = std::get < 0 > (iov);
44 align =
new TH2F(
"Ecal DAQ Tower Status Summary",
"EB/EE bit 0 -> towers excluded from the DAQ",NbColumns, 0, NbColumns, NbRows, 0, NbRows);
49 long unsigned int ebTotal=(payload->barrelItems()).
size();
50 long unsigned int eeTotal=(payload->endcapItems()).
size();
52 getSummary(payload->barrelItems(),ebVals,ebTotal);
53 getSummary(payload->endcapItems(),eeVals,eeTotal);
56 double row = NbRows - 0.5;
59 align->Fill(0.5, row, 1);
60 align->Fill(1.5, row, ebVals);
61 align->Fill(2.5, row, ebTotal);
65 align->Fill(0.5, row, 2);
66 align->Fill(1.5, row, eeVals);
67 align->Fill(2.5, row, eeTotal);
73 gStyle->SetPalette(1);
74 gStyle->SetOptStat(0);
75 TCanvas
canvas(
"CC map",
"CC map", 1000, 1000);
81 t1.DrawLatex(0.5, 0.96,Form(
"Ecal DAQTower Status Summary, IOV %i", run));
84 TPad* pad =
new TPad(
"pad",
"pad", 0.0, 0.0, 1.0, 0.94);
91 align->GetXaxis()->SetTickLength(0.);
92 align->GetXaxis()->SetLabelSize(0.);
93 align->GetYaxis()->SetTickLength(0.);
94 align->GetYaxis()->SetLabelSize(0.);
97 canvas.SaveAs(ImageName.c_str());
101 void getSummary(std::vector<EcalDAQStatusCode> vItems,
float &
vals,
long unsigned int &
total){
103 for(std::vector<EcalDAQStatusCode>::const_iterator iItems = vItems.begin(); iItems != vItems.end(); ++iItems){
105 if(iItems->getStatusCode()>0)
std::shared_ptr< PayloadType > fetchPayload(const cond::Hash &payloadHash)
#define PAYLOAD_INSPECTOR_CLASS(CLASS_NAME)
virtual bool fill(const std::vector< std::tuple< cond::Time_t, cond::Hash > > &iovs)=0
#define PAYLOAD_INSPECTOR_MODULE(PAYLOAD_TYPENAME)
void setSingleIov(bool flag)
void drawTable(int nbRows, int nbColumns)