37 cout <<
"File not specified!" << endl;
40 FairLogger::GetLogger()->SetLogToScreen(
true);
41 FairLogger::GetLogger()->SetLogScreenLevel(
"info");
43 const vector<string> evt_tr_names{
"BT",
"MBT",
"CCT1",
"CCT2",
"RC_Trig_Cand",
44 "DAQ_RO_Trig",
"pBT",
"BC1L",
"NiT",
"BT&nBUSY"};
48 if (file->
IsOpen() ==
false) {
50 LOG(error) <<
"Cannot open file " << fileName <<
" !" << endl;
57 LOG(error) <<
"No run header!" << endl;
60 printf(
"Run Header content:\n");
63 printf(
"\tPeriod: %u Run: %u\n", PeriodId, RunId);
66 printf(
"\tSTART : %s\n", RunStartTime.
AsString());
67 printf(
"\tFINISH : %s\n", RunEndTime.
AsString());
69 map<SysPoint, BmnSpillInfo>& fSpillMap = rh->
GetSpillMap();
82 vector<unique_ptr<TH1I>> evt_tr_hist;
86 auto can{make_unique<TCanvas>(name, name, 1920, 1080)};
87 can->Divide(1, trigCount);
88 Double_t left_time(0), right_time(128);
89 const int32_t nbinsX = 128 + 1;
90 const int32_t nbinsY = 250;
95 unique_ptr<TH2I> hist = make_unique<TH2I>(name, name, nbinsY, 0, 12e9, nbinsX + 1, 0, nbinsX);
96 hist->SetLineWidth(3);
97 hist->GetXaxis()->SetTitle(
"time");
98 hist->GetYaxis()->SetTitle(
"X");
99 hist->GetXaxis()->SetLabelSize(0.03);
100 hist->GetYaxis()->SetLabelSize(0.03);
102 hist->GetXaxis()->SetLabelOffset(0.028);
103 hist->GetYaxis()->SetLabelOffset(0.015);
105 if (fSpillMap.size() < 2) {
106 printf(
"No Spill in the map!");
111 TString file_names =
"./bmn_run9362_ev*_p*_digi.root";
113 chain.
Add(file_names);
116 map<SysPoint, int64_t> ts2event;
129 for (
auto& mapel : fSpillMap) {
133 auto df_spill = df.
Filter(
137 {
"BmnEventHeader."});
139 auto df_sp_digi = df_spill
142 return std::chrono::duration_cast<std::chrono::nanoseconds>(
149 std::vector<int32_t> out;
150 for (int32_t iDig = 0; iDig < array.GetEntries(); iDig++) {
161 auto res = df_sp_digi.Histo2D({name, name, nbinsY, 0, 11e9, nbinsX + 1, 0, nbinsX},
"tss",
"strip");
165 can->SaveAs(
Form(
"spill_strip_run%u_l%d_spill%d.png", RunId, layer, ispill));