CbmRoot
CbmMcbm2018MonitorAlgoT0.cxx
Go to the documentation of this file.
1 // -----------------------------------------------------------------------------
2 // ----- -----
3 // ----- CbmMcbm2018MonitorAlgoT0 -----
4 // ----- Created 10.02.2019 by P.-A. Loizeau -----
5 // ----- -----
6 // -----------------------------------------------------------------------------
7 
9 
10 #include "CbmFlesHistosTools.h"
12 #include "CbmMcbm2018TofPar.h"
13 #include "CbmTofAddress.h"
14 #include "CbmTofDetectorId_v14a.h" // in cbmdata/tof
15 
16 #include "FairLogger.h"
17 #include "FairRootManager.h"
18 #include "FairRun.h"
19 #include "FairRunOnline.h"
20 #include "FairRuntimeDb.h"
21 
22 #include "TCanvas.h"
23 #include "TH1.h"
24 #include "TH2.h"
25 #include "TList.h"
26 #include "TPaveStats.h"
27 #include "TProfile.h"
28 #include "TROOT.h"
29 #include "TString.h"
30 
31 #include <fstream>
32 #include <iomanip>
33 #include <iostream>
34 #include <stdint.h>
35 
36 // -------------------------------------------------------------------------
40  fvmHitsInMs.clear();
41  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb) {
42  // fvmHitsInMs[ uDpb ].clear();
43  fvvmEpSupprBuffer[uGdpb].clear();
44  } // for( UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb )
45 }
46 
47 // -------------------------------------------------------------------------
49  LOG(info) << "Initializing mCBM T0 2019 monitor algo";
50 
51  return kTRUE;
52 }
56 
58 }
59 
60 // -------------------------------------------------------------------------
62  LOG(info) << "Init parameter containers for CbmMcbm2018MonitorAlgoT0";
63  Bool_t initOK = ReInitContainers();
64 
65  return initOK;
66 }
68  LOG(info) << "**********************************************";
69  LOG(info) << "ReInit parameter containers for CbmMcbm2018MonitorAlgoT0";
70 
71  fUnpackPar = (CbmMcbm2018TofPar*) fParCList->FindObject("CbmMcbm2018TofPar");
72  if (nullptr == fUnpackPar) return kFALSE;
73 
74  Bool_t initOK = InitParameters();
75 
76  return initOK;
77 }
79  if (nullptr == fParCList) fParCList = new TList();
80  fUnpackPar = new CbmMcbm2018TofPar("CbmMcbm2018TofPar");
81  fParCList->Add(fUnpackPar);
82 
83  return fParCList;
84 }
86 
88  LOG(info) << "Nr. of Tof GDPBs: " << fuNrOfGdpbs;
89 
91  LOG(info) << "Nr. of FEES per Tof GDPB: " << fuNrOfFeePerGdpb;
92 
94  LOG(info) << "Nr. of GET4 per Tof FEE: " << fuNrOfGet4PerFee;
95 
97  LOG(info) << "Nr. of channels per GET4: " << fuNrOfChannelsPerGet4;
98 
100  LOG(info) << "Nr. of channels per FEE: " << fuNrOfChannelsPerFee;
101 
103  LOG(info) << "Nr. of GET4s: " << fuNrOfGet4;
104 
106  LOG(info) << "Nr. of GET4s per GDPB: " << fuNrOfGet4PerGdpb;
107 
109  LOG(info) << "Nr. of channels per GDPB: " << fuNrOfChannelsPerGdpb;
110 
111  fGdpbIdIndexMap.clear();
112  for (UInt_t i = 0; i < fuNrOfGdpbs; ++i) {
114  LOG(info) << "GDPB Id of TOF " << i << " : " << std::hex
115  << fUnpackPar->GetGdpbId(i) << std::dec;
116  } // for( UInt_t i = 0; i < fuNrOfGdpbs; ++i )
117 
119  fvulCurrentEpoch.resize(fuNrOfGdpbs, 0);
122 
125 
126  return kTRUE;
127 }
128 // -------------------------------------------------------------------------
129 
131  UShort_t usDetectorId) {
133  for (UInt_t uCompIdx = 0; uCompIdx < fvMsComponentsList.size(); ++uCompIdx)
134  if (component == fvMsComponentsList[uCompIdx]) return;
135 
137  fvMsComponentsList.push_back(component);
138 
139  LOG(info) << "CbmMcbm2018MonitorAlgoT0::AddMsComponentToList => Component "
140  << component << " with detector ID 0x" << std::hex << usDetectorId
141  << std::dec << " added to list";
142 }
143 // -------------------------------------------------------------------------
144 
145 Bool_t CbmMcbm2018MonitorAlgoT0::ProcessTs(const fles::Timeslice& ts) {
146  fulCurrentTsIdx = ts.index();
147  fdTsStartTime = static_cast<Double_t>(ts.descriptor(0, 0).idx);
148 
150  if (0 == fulCurrentTsIdx) return kTRUE;
151 
153  if (-1.0 == fdTsCoreSizeInNs) {
154  fuNbCoreMsPerTs = ts.num_core_microslices();
155  fuNbOverMsPerTs = ts.num_microslices(0) - ts.num_core_microslices();
158  LOG(info) << "Timeslice parameters: each TS has " << fuNbCoreMsPerTs
159  << " Core MS and " << fuNbOverMsPerTs
160  << " Overlap MS, for a core duration of " << fdTsCoreSizeInNs
161  << " ns and a full duration of " << fdTsFullSizeInNs << " ns";
162 
165  if (kFALSE == fbIgnoreOverlapMs) fuNbMsLoop += fuNbOverMsPerTs;
166  LOG(info) << "In each TS " << fuNbMsLoop << " MS will be looped over";
167  } // if( -1.0 == fdTsCoreSizeInNs )
168 
171  // LOG(info) << Form( "TS %5d Start %12f Stop %12f", fulCurrentTsIdx, fdTsStartTime, fdTsStopTimeCore );
172 
174  for (fuMsIndex = 0; fuMsIndex < fuNbMsLoop; fuMsIndex++) {
176  for (UInt_t uMsCompIdx = 0; uMsCompIdx < fvMsComponentsList.size();
177  ++uMsCompIdx) {
178  UInt_t uMsComp = fvMsComponentsList[uMsCompIdx];
179 
180  if (kFALSE == ProcessMs(ts, uMsComp, fuMsIndex)) {
181  LOG(error) << "Failed to process ts " << fulCurrentTsIdx << " MS "
182  << fuMsIndex << " for component " << uMsComp;
183  return kFALSE;
184  } // if( kFALSE == ProcessMs( ts, uMsCompIdx, fuMsIndex ) )
185  } // for( UInt_t uMsCompIdx = 0; uMsCompIdx < fvMsComponentsList.size(); ++uMsCompIdx )
186  /*
188  std::sort( fvmHitsInMs.begin(), fvmHitsInMs.end() );
189 
191  for( auto itHitIn = fvmHitsInMs.begin(); itHitIn < fvmHitsInMs.end(); ++itHitIn )
192  {
193  UInt_t uFebIdx = itHitIn->GetAsic() / fUnpackPar->GetNbAsicsPerFeb()
194  + ( itHitIn->GetDpb() * fUnpackPar->GetNbCrobsPerDpb() + itHitIn->GetCrob() )
195  * fUnpackPar->GetNbFebsPerCrob();
196  UInt_t uChanInFeb = itHitIn->GetChan()
197  + fUnpackPar->GetNbChanPerAsic() * (itHitIn->GetAsic() % fUnpackPar->GetNbAsicsPerFeb());
198 
199  ULong64_t ulTimeInNs = static_cast< ULong64_t >( itHitIn->GetTs() * stsxyter::kdClockCycleNs - fdTimeOffsetNs );
200 
201  fDigiVect.push_back( CbmTofDigi( fviFebAddress[ uFebIdx ], uChanInFeb, ulTimeInNs, itHitIn->GetAdc() ) );
202  } // for( auto itHitIn = fvmHitsInMs.begin(); itHitIn < fvmHitsInMs.end(); ++itHitIn )
203 */
205  fvmHitsInMs.clear();
206  } // for( fuMsIndex = 0; fuMsIndex < uNbMsLoop; fuMsIndex ++ )
207 
209  fvmHitsInMs.clear();
210  /*
211  for( UInt_t uDpb = 0; uDpb < fuNrOfDpbs; ++uDpb )
212  {
213  fvmHitsInMs[ uDpb ].clear();
214  } // for( UInt_t uDpb = 0; uDpb < fuNrOfDpbs; ++uDpb )
215 */
217  if (fbMonitorMode) {
218  if (kFALSE == FillHistograms()) {
219  LOG(error) << "Failed to fill histos in ts " << fulCurrentTsIdx;
220  return kFALSE;
221  } // if( kFALSE == FillHistograms() )
222  } // if( fbMonitorMode )
223 
224  return kTRUE;
225 }
226 
227 Bool_t CbmMcbm2018MonitorAlgoT0::ProcessMs(const fles::Timeslice& ts,
228  size_t uMsCompIdx,
229  size_t uMsIdx) {
230  auto msDescriptor = ts.descriptor(uMsCompIdx, uMsIdx);
231  fuCurrentEquipmentId = msDescriptor.eq_id;
232  const uint8_t* msContent =
233  reinterpret_cast<const uint8_t*>(ts.content(uMsCompIdx, uMsIdx));
234 
235  uint32_t uSize = msDescriptor.size;
236  fulCurrentMsIdx = msDescriptor.idx;
237  fdMsTime = (1e-9) * static_cast<double>(fulCurrentMsIdx);
238  LOG(debug) << "Microslice: " << fulCurrentMsIdx << " from EqId " << std::hex
239  << fuCurrentEquipmentId << std::dec << " has size: " << uSize;
240 
241  if (0 == fvbMaskedComponents.size())
242  fvbMaskedComponents.resize(ts.num_components(), kFALSE);
243 
244  fuCurrDpbId = static_cast<uint32_t>(fuCurrentEquipmentId & 0xFFFF);
245  // fuCurrDpbIdx = fDpbIdIndexMap[ fuCurrDpbId ];
246 
247  /*
248  * Should be only for first detected TS
249  */
250  if (fulCurrentTsIdx < 10 && 0 == uMsIdx) {
251  LOG(INFO)
252  << "---------------------------------------------------------------";
253  LOG(INFO) << "Component " << uMsCompIdx << " TS Idx " << fulCurrentTsIdx;
254  LOG(INFO)
255  << "hi hv eqid flag si sv idx/start crc size offset";
256  LOG(INFO) << Form("%02x %02x %04x %04x %02x %02x %016lx %08x %08x %016lx",
257  static_cast<unsigned int>(msDescriptor.hdr_id),
258  static_cast<unsigned int>(msDescriptor.hdr_ver),
259  msDescriptor.eq_id,
260  msDescriptor.flags,
261  static_cast<unsigned int>(msDescriptor.sys_id),
262  static_cast<unsigned int>(msDescriptor.sys_ver),
263  static_cast<unsigned long>(msDescriptor.idx),
264  msDescriptor.crc,
265  msDescriptor.size,
266  static_cast<unsigned long>(msDescriptor.offset));
267  } // if( fulCurrentTsIdx < 10 && 0 == uMsIdx )
268  /*
269 */
270 
272  auto it = fGdpbIdIndexMap.find(fuCurrDpbId);
273  if (it == fGdpbIdIndexMap.end()) {
274  if (kFALSE == fvbMaskedComponents[uMsCompIdx]) {
275  LOG(info)
276  << "---------------------------------------------------------------";
277  /*
278  LOG(info) << "hi hv eqid flag si sv idx/start crc size offset";
279  LOG(info) << Form( "%02x %02x %04x %04x %02x %02x %016llx %08x %08x %016llx",
280  static_cast<unsigned int>(msDescriptor.hdr_id),
281  static_cast<unsigned int>(msDescriptor.hdr_ver), msDescriptor.eq_id, msDescriptor.flags,
282  static_cast<unsigned int>(msDescriptor.sys_id),
283  static_cast<unsigned int>(msDescriptor.sys_ver), msDescriptor.idx, msDescriptor.crc,
284  msDescriptor.size, msDescriptor.offset );
285 */
286  LOG(info) << FormatMsHeaderPrintout(msDescriptor);
287  LOG(warning) << "Could not find the gDPB index for AFCK id 0x" << std::hex
288  << fuCurrDpbId << std::dec << " in timeslice "
289  << fulCurrentTsIdx << " in microslice " << uMsIdx
290  << " component " << uMsCompIdx << "\n"
291  << "If valid this index has to be added in the TOF "
292  "parameter file in the DbpIdArray field";
293  fvbMaskedComponents[uMsCompIdx] = kTRUE;
294  } // if( kFALSE == fvbMaskedComponents[ uMsComp ] )
295  else
296  return kTRUE;
297 
300 
301  return kFALSE;
302  } // if( it == fGdpbIdIndexMap.end() )
303  else
305 
307  if (0 == fuCurrDpbIdx) {
309  if (1.0 < fdMsTime - fdLastSecondTime) {
312  fbSpillOn = kFALSE;
318  } // if( fbSpillOn && fuCountsLastSecond < fuOffSpillCountLimit )
320  fbSpillOn = kTRUE;
321 
322  fuCountsLastSecond = 0;
324  } // if( 1 < fdMsTime - fdLastSecondTime )
325  } // if( 0 == fuCurrDpbIdx )
326 
328  if (fdStartTime < 0) fdStartTime = fdMsTime;
330  else if (fuHistoryHistoSize < fdMsTime - fdStartTime) {
331  ResetHistograms();
333  } // else if( fuHistoryHistoSize < fdMsTime - fdStartTime )
334 
335  // If not integer number of message in input buffer, print warning/error
336  if (0 != (uSize % kuBytesPerMessage))
337  LOG(error) << "The input microslice buffer does NOT "
338  << "contain only complete nDPB messages!";
339 
340  // Compute the number of complete messages in the input microslice buffer
341  uint32_t uNbMessages =
342  (uSize - (uSize % kuBytesPerMessage)) / kuBytesPerMessage;
343 
344  // Prepare variables for the loop on contents
345  Int_t messageType = -111;
346  const uint64_t* pInBuff = reinterpret_cast<const uint64_t*>(msContent);
347  for (uint32_t uIdx = 0; uIdx < uNbMessages; uIdx++) {
348  // Fill message
349  uint64_t ulData = static_cast<uint64_t>(pInBuff[uIdx]);
350 
352  if (0 == uIdx) {
353  // ProcessEpochCycle( ulData );
354  continue;
355  } // if( 0 == uIdx )
356 
357  gdpbv100::Message mess(ulData);
359  messageType = mess.getMessageType();
360 
361  fuGet4Id = mess.getGdpbGenChipId();
362  ;
364  // UInt_t uChannelT0 = ( fuGet4Id < 32 ) ? ( fuGet4Id / 8 ) : (fuGet4Id / 8 - 1); /// December 2018 mapping
365  UInt_t uChannelT0 =
366  fuGet4Id / 2 + 4 * fuCurrDpbIdx;
367 
368  if (fuNrOfGet4PerGdpb <= fuGet4Id && !mess.isStarTrigger()
370  LOG(warning) << "Message with Get4 ID too high: " << fuGet4Id << " VS "
371  << fuNrOfGet4PerGdpb << " set in parameters.";
372 
373  switch (messageType) {
374  case gdpbv100::MSG_HIT: {
375  if (mess.getGdpbHitIs24b()) {
376  LOG(error)
377  << "This event builder does not support 24b hit message!!!.";
378  continue;
379  } // if( getGdpbHitIs24b() )
380  else {
383 
384  fhErrorFractEvo->Fill(fdMsTime - fdStartTime, 0.0);
385  fhLostEvtFractEvo->Fill(fdMsTime - fdStartTime, 0.0);
386  fvhErrorFractEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime, 0.0);
387  fvhEvtLostFractEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime, 0.0);
388 
391 
392  fvhHitCntEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime);
393 
394  fvuHitCntChanMs[uChannelT0]++;
395 
397  UInt_t uTot = mess.getGdpbHit32Tot();
398  if (uTot < fuMinTotPulser || fuMaxTotPulser < uTot) {
399  fhDpbMap->Fill(fuCurrDpbIdx);
400  fhChannelMap->Fill(uChannelT0);
401 
404  fuDiamChanMap[uChannelT0]);
406  } // if( uTot < fuMinTotPulser || fuMaxTotPulser < uTot )
407  else {
408  fhChannelMapPulser->Fill(uChannelT0);
409  fhHitMapEvoPulser->Fill(uChannelT0, fdMsTime - fdStartTime);
410  } // else of if( uTot < fuMinTotPulser || fuMaxTotPulser < uTot )
411  fhHitMapEvo->Fill(uChannelT0, fdMsTime - fdStartTime);
412  fhHitTotEvo->Fill(fdMsTime - fdStartTime, uTot);
413  fhChanHitMapEvo->Fill(fuDiamChanMap[uChannelT0],
415  // fvvmEpSupprBuffer[fuCurrDpbIdx].push_back( mess );
416  } // else of if( getGdpbHitIs24b() )
417  break;
418  } // case gdpbv100::MSG_HIT:
419  case gdpbv100::MSG_EPOCH: {
420  /*
421  if( gdpbv100::kuChipIdMergedEpoch == fuGet4Id )
422  {
423  ProcessEpoch(mess);
424  } // if this epoch message is a merged one valid for all chips
425  else
426  {
428  LOG(debug2) << "This event builder does not support unmerged epoch messages!!!.";
429  continue;
430  } // if single chip epoch message
431 */
432  break;
433  } // case gdpbv100::MSG_EPOCH:
434  case gdpbv100::MSG_SLOWC: {
435  // fvvmEpSupprBuffer[fuCurrDpbIdx].push_back( mess );
436  break;
437  } // case gdpbv100::MSG_SLOWC:
438  case gdpbv100::MSG_SYST: {
440  fhErrorFractEvo->Fill(fdMsTime - fdStartTime, 0.0);
441  fhLostEvtFractEvo->Fill(fdMsTime - fdStartTime, 0.0);
442  fvhErrorFractEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime, 0.0);
443  fvhEvtLostFractEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime, 0.0);
444 
447  fhErrorFractEvo->Fill(fdMsTime - fdStartTime, 1.0);
448 
449  fvhErrorCntEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime);
450  fvhErrorFractEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime, 1.0);
451 
452  fvuErrorCntChanMs[uChannelT0]++;
455  fhLostEvtFractEvo->Fill(fdMsTime - fdStartTime, 1.0);
456 
457  fvhEvtLostCntEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime);
458  fvhEvtLostFractEvoChan[uChannelT0]->Fill(fdMsTime - fdStartTime,
459  1.0);
460 
461  fvuEvtLostCntChanMs[uChannelT0]++;
462  } // if( gdpbv100::GET4_V2X_ERR_LOST_EVT == mess.getGdpbSysErrData() )
463  } // if( gdpbv100::SYS_GET4_ERROR == mess.getGdpbSysSubType() )
464  // fvvmEpSupprBuffer[fuCurrDpbIdx].push_back( mess );
465  break;
466  } // case gdpbv100::MSG_SYST:
471  break;
472  } // case gdpbv100::MSG_STAR_TRI_A-D
473  default:
474  LOG(error) << "Message type " << std::hex << std::setw(2)
475  << static_cast<uint16_t>(messageType)
476  << " not included in Get4 unpacker.";
477  } // switch( mess.getMessageType() )
478  } // for (uint32_t uIdx = 0; uIdx < uNbMessages; uIdx ++)
479 
481  FillHistograms();
482 
483  return kTRUE;
484 }
485 /*
486 // -------------------------------------------------------------------------
487 void CbmMcbm2018MonitorAlgoT0::ProcessEpochCycle( uint64_t ulCycleData )
488 {
489  ULong64_t ulEpochCycleVal = ulCycleData & gdpbv100::kulEpochCycleFieldSz;
490 
491  if( !( ulEpochCycleVal == fvulCurrentEpochCycle[fuCurrDpbIdx] ||
492  ulEpochCycleVal == fvulCurrentEpochCycle[fuCurrDpbIdx] + 1 ) &&
493  0 < fulCurrentMsIdx ) {
494  LOG(warning) << "CbmMcbm2018MonitorAlgoT0::ProcessEpochCycle => "
495  << " Missmatch in epoch cycles detected for Gdpb " << fuCurrDpbIdx <<", probably fake cycles due to epoch index corruption! "
496  << Form( " Current cycle 0x%09llX New cycle 0x%09llX", fvulCurrentEpochCycle[fuCurrDpbIdx], ulEpochCycleVal );
497  } // if epoch cycle did not stay constant or increase by exactly 1, except if first MS of the TS
498  if( ulEpochCycleVal != fvulCurrentEpochCycle[fuCurrDpbIdx] )
499  {
500  LOG(info) << "CbmStar2019EventBuilderEtofAlgo::ProcessEpochCycle => "
501  << " New epoch cycle for Gdpb " << fuCurrDpbIdx
502  << Form( ": Current cycle 0x%09llX New cycle 0x%09llX", fvulCurrentEpochCycle[fuCurrDpbIdx], ulEpochCycleVal );
503  } // if( ulEpochCycleVal != fvulCurrentEpochCycle[fuCurrDpbIdx] )
504  fvulCurrentEpochCycle[fuCurrDpbIdx] = ulEpochCycleVal;
505 
506  return;
507 }
508 void CbmMcbm2018MonitorAlgoT0::ProcessEpoch( gdpbv100::Message mess )
509 {
510  ULong64_t ulEpochNr = mess.getGdpbEpEpochNb();
511 
512  fvulCurrentEpoch[ fuCurrDpbIdx ] = ulEpochNr;
513  fvulCurrentEpochFull[ fuCurrDpbIdx ] = ulEpochNr + ( gdpbv100::kuEpochCounterSz + 1 ) * fvulCurrentEpochCycle[ fuCurrDpbIdx ];
514 
517  if( 0 < ulEpochNr )
518  mess.setGdpbEpEpochNb( ulEpochNr - 1 );
519  else mess.setGdpbEpEpochNb( gdpbv100::kuEpochCounterSz );
520 
522  ProcessEpSupprBuffer();
523 }
524 // -------------------------------------------------------------------------
525 void CbmMcbm2018MonitorAlgoT0::ProcessEpSupprBuffer()
526 {
527  Int_t iBufferSize = fvvmEpSupprBuffer[ fuCurrDpbIdx ].size();
528 
529  if( 0 == iBufferSize )
530  return;
531 
532  LOG(debug) << "Now processing stored messages for for gDPB " << fuCurrDpbIdx << " with epoch number "
533  << (fvulCurrentEpoch[fuCurrDpbIdx] - 1);
534 
537  std::stable_sort( fvvmEpSupprBuffer[ fuCurrDpbIdx ].begin(), fvvmEpSupprBuffer[ fuCurrDpbIdx ].begin() );
538 
540  ULong64_t ulCurEpochGdpbGet4 = fvulCurrentEpochFull[ fuCurrDpbIdx ];
541 
543  if( 0 == ulCurEpochGdpbGet4 )
544  return;
545 
547  ulCurEpochGdpbGet4 --;
548 
549  Int_t messageType = -111;
550  for( Int_t iMsgIdx = 0; iMsgIdx < iBufferSize; iMsgIdx++ )
551  {
552  messageType = fvvmEpSupprBuffer[ fuCurrDpbIdx ][ iMsgIdx ].getMessageType();
553 
554  fuGet4Id = fUnpackPar->ElinkIdxToGet4Idx( fvvmEpSupprBuffer[ fuCurrDpbIdx ][ iMsgIdx ].getGdpbGenChipId() );
555  if( fuDiamondDpbIdx == fuCurrDpbIdx )
556  fuGet4Id = fvvmEpSupprBuffer[ fuCurrDpbIdx ][ iMsgIdx ].getGdpbGenChipId();
557  fuGet4Nr = (fuCurrDpbIdx * fuNrOfGet4PerGdpb) + fuGet4Id;
558 
560  gdpbv100::FullMessage fullMess( fvvmEpSupprBuffer[ fuCurrDpbIdx ][ iMsgIdx ], ulCurEpochGdpbGet4 );
561 
563  switch( messageType )
564  {
565  case gdpbv100::MSG_HIT:
566  {
567  ProcessHit( fullMess );
568  break;
569  } // case gdpbv100::MSG_HIT:
570  case gdpbv100::MSG_SLOWC:
571  {
572  ProcessSlCtrl( fullMess );
573  break;
574  } // case gdpbv100::MSG_SLOWC:
575  case gdpbv100::MSG_SYST:
576  {
577  ProcessSysMess( fullMess );
578  break;
579  } // case gdpbv100::MSG_SYST:
580  case gdpbv100::MSG_EPOCH:
581  case gdpbv100::MSG_STAR_TRI_A:
582  case gdpbv100::MSG_STAR_TRI_B:
583  case gdpbv100::MSG_STAR_TRI_C:
584  case gdpbv100::MSG_STAR_TRI_D:
586  break;
587  default:
588  LOG(error) << "Message type " << std::hex
589  << std::setw(2) << static_cast<uint16_t>(messageType)
590  << " not included in Get4 unpacker.";
591  } // switch( mess.getMessageType() )
592  } // for( Int_t iMsgIdx = 0; iMsgIdx < iBufferSize; iMsgIdx++ )
593 
594  fvvmEpSupprBuffer[ fuCurrDpbIdx ].clear();
595 }
596 // -------------------------------------------------------------------------
597 void CbmMcbm2018MonitorAlgoT0::ProcessHit( gdpbv100::FullMessage mess )
598 {
599  UInt_t uChannel = mess.getGdpbHitChanId();
600  UInt_t uTot = mess.getGdpbHit32Tot();
601 
602  // In 32b mode the coarse counter is already computed back to 112 FTS bins
603  // => need to hide its contribution from the Finetime
604  // => FTS = Fullt TS modulo 112
605  UInt_t uFts = mess.getGdpbHitFullTs() % 112;
606 
607  UInt_t uChannelNr = fuGet4Id * fuNrOfChannelsPerGet4 + uChannel;
608  UInt_t uChannelNrInFee = (fuGet4Id % fuNrOfGet4PerFee) * fuNrOfChannelsPerGet4 + uChannel;
609  UInt_t uFeeNr = (fuGet4Id / fuNrOfGet4PerFee);
610  UInt_t uFeeNrInSys = fuCurrDpbIdx * fuNrOfFeePerGdpb + uFeeNr;
611  UInt_t uRemappedChannelNr = uFeeNr * fuNrOfChannelsPerFee + fUnpackPar->Get4ChanToPadiChan( uChannelNrInFee );
612  UInt_t uGbtxNr = (uFeeNr / fUnpackPar->GetNrOfFeePerGbtx());
613  UInt_t uFeeInGbtx = (uFeeNr % fUnpackPar->GetNrOfFeePerGbtx());
614  UInt_t uGbtxNrInSys = fuCurrDpbIdx * fUnpackPar->GetNrOfGbtxPerGdpb() + uGbtxNr;
615 
616  UInt_t uChanInSyst = fuCurrDpbIdx * fuNrOfChannelsPerGdpb + uChannelNr;
617  UInt_t uRemappedChannelNrInSys = fuCurrDpbIdx * fuNrOfChannelsPerGdpb
618  + uFeeNr * fuNrOfChannelsPerFee
619  + fUnpackPar->Get4ChanToPadiChan( uChannelNrInFee );
621  if( fuDiamondDpbIdx == fuCurrDpbIdx )
622  {
623  uRemappedChannelNr = uChannelNr;
624  uRemappedChannelNrInSys = fuCurrDpbIdx * fUnpackPar->GetNrOfChannelsPerGdpb() + uChannelNr;
625  } // if( fuDiamondDpbIdx == fuCurrDpbIdx )
626 
627  ULong_t ulHitTime = mess.getMsgFullTime( mess.getExtendedEpoch() );
628  Double_t dHitTime = mess.GetFullTimeNs();
629  Double_t dHitTot = uTot; // in bins
630 
631 }
632 // -------------------------------------------------------------------------
633 void CbmMcbm2018MonitorAlgoT0::ProcessSlCtrl( gdpbv100::FullMessage mess )
634 {
635 }
636 // -------------------------------------------------------------------------
637 void CbmMcbm2018MonitorAlgoT0::ProcessSysMess( gdpbv100::FullMessage mess )
638 {
639  switch( mess.getGdpbSysSubType() )
640  {
641  case gdpbv100::SYS_GET4_ERROR:
642  {
643  ProcessError( mess );
644  break;
645  } // case gdpbv100::SYSMSG_GET4_EVENT
646  case gdpbv100::SYS_GDPB_UNKWN:
647  {
648  LOG(debug) << "Unknown GET4 message, data: " << std::hex << std::setw(8)
649  << mess.getGdpbSysUnkwData() << std::dec
650  <<" Full message: " << std::hex << std::setw(16)
651  << mess.getData() << std::dec;
652  break;
653  } // case gdpbv100::SYS_GDPB_UNKWN:
654  case gdpbv100::SYS_GET4_SYNC_MISS:
655  {
656  if( mess.getGdpbSysFwErrResync() )
657  LOG(info) << Form( "GET4 Resynchronization: Get4:0x%04x ", mess.getGdpbGenChipId() ) << fuCurrDpbIdx;
658  else LOG(info) << "GET4 synchronization pulse missing in gDPB " << fuCurrDpbIdx;
659  break;
660  } // case gdpbv100::SYS_GET4_SYNC_MISS:
661  case gdpbv100::SYS_PATTERN:
662  {
663  ProcessPattern( mess );
664  break;
665  } // case gdpbv100::SYS_PATTERN:
666  default:
667  {
668  LOG(info) << "Crazy system message, subtype " << mess.getGdpbSysSubType();
669  break;
670  } // default
671  } // switch( mess.getGdpbSysSubType() )
672 }
673 void CbmMcbm2018MonitorAlgoT0::ProcessError( gdpbv100::FullMessage mess )
674 {
675  uint32_t uErrorType = mess.getGdpbSysErrData();
676 
677  switch( uErrorType )
678  {
679  case gdpbv100::GET4_V2X_ERR_READ_INIT:
680  case gdpbv100::GET4_V2X_ERR_SYNC:
681  case gdpbv100::GET4_V2X_ERR_EP_CNT_SYNC:
682  case gdpbv100::GET4_V2X_ERR_EP:
683  case gdpbv100::GET4_V2X_ERR_FIFO_WRITE:
684  case gdpbv100::GET4_V2X_ERR_CHAN_STATE:
685  case gdpbv100::GET4_V2X_ERR_TOK_RING_ST:
686  case gdpbv100::GET4_V2X_ERR_TOKEN:
687  case gdpbv100::GET4_V2X_ERR_READOUT_ERR:
688  case gdpbv100::GET4_V2X_ERR_DLL_LOCK:
689  case gdpbv100::GET4_V2X_ERR_DLL_RESET:
691  break;
692  case gdpbv100::GET4_V2X_ERR_SPI:
694  break;
695  case gdpbv100::GET4_V2X_ERR_LOST_EVT:
696  case gdpbv100::GET4_V2X_ERR_TOT_OVERWRT:
697  case gdpbv100::GET4_V2X_ERR_TOT_RANGE:
698  case gdpbv100::GET4_V2X_ERR_EVT_DISCARD:
699  case gdpbv100::GET4_V2X_ERR_ADD_RIS_EDG:
700  case gdpbv100::GET4_V2X_ERR_UNPAIR_FALL:
701  case gdpbv100::GET4_V2X_ERR_SEQUENCE_ER:
703  break;
704  case gdpbv100::GET4_V2X_ERR_EPOCH_OVERF:
705  break;
706  case gdpbv100::GET4_V2X_ERR_UNKNOWN:
708  break;
709  default:
711  break;
712  } // switch( uErrorType )
713 
714  return;
715 }
716 void CbmMcbm2018MonitorAlgoT0::ProcessPattern( gdpbv100::FullMessage mess )
717 {
718  uint16_t usType = mess.getGdpbSysPattType();
719  uint16_t usIndex = mess.getGdpbSysPattIndex();
720  uint32_t uPattern = mess.getGdpbSysPattPattern();
721 
722  switch( usType )
723  {
724  case gdpbv100::PATT_MISSMATCH:
725  {
726  LOG(debug) << Form( "Missmatch pattern message => Type %d, Index %2d, Pattern 0x%08X", usType, usIndex, uPattern );
727 
728  break;
729  } // case gdpbv100::PATT_MISSMATCH:
730  case gdpbv100::PATT_ENABLE:
731  {
732  LOG(debug2) << Form( "Enable pattern message => Type %d, Index %2d, Pattern 0x%08X", usType, usIndex, uPattern );
733 
734  break;
735  } // case gdpbv100::PATT_ENABLE:
736  case gdpbv100::PATT_RESYNC:
737  {
738  LOG(debug) << Form( "RESYNC pattern message => Type %d, Index %2d, Pattern 0x%08X", usType, usIndex, uPattern );
739 
740  break;
741  } // case gdpbv100::PATT_RESYNC:
742  default:
743  {
744  LOG(debug) << "Crazy pattern message, subtype " << usType;
745  break;
746  } // default
747  } // switch( usType )
748 
749  return;
750 }
751 // -------------------------------------------------------------------------
752 */
754  std::string sFolder = "MoniT0";
755 
756  LOG(info) << "create Histos for T0 monitoring ";
757 
759  uint32_t iNbBinsLog = 0;
761  std::vector<double> dBinsLogVector = GenerateLogBinArray(4, 9, 1, iNbBinsLog);
762  double* dBinsLog = dBinsLogVector.data();
763  // double * dBinsLog = GenerateLogBinArray( 4, 9, 1, iNbBinsLog );
764 
765  /*******************************************************************/
766  fhDpbMap = new TH1I("hDpbMap",
767  "Map of hits on T0 detector; DPB; Hits Count []",
768  fuNrOfGdpbs,
769  -0.5,
770  fuNrOfGdpbs - 0.5);
771  fhChannelMap = new TH1I("hChannelMap",
772  "Map of hits on T0 detector; Strip; Hits Count []",
774  -0.5,
775  kuNbChanDiamond - 0.5);
776  fhHitMapEvo = new TH2I("hHitMapEvo",
777  "Map of hits on T0 detector vs time in run; Chan; "
778  "Time in run [s]; Hits Count []",
780  -0.5,
781  kuNbChanDiamond - 0.5,
783  0,
785  fhHitTotEvo = new TH2I("hHitTotEvo",
786  "Evolution of TOT in T0 detector vs time in run; Time "
787  "in run [s]; TOT [ bin ]; Hits Count []",
789  0,
791  256,
792  -0.5,
793  255.5);
794  fhChanHitMapEvo = new TH2I("hChanHitMapEvo",
795  "Map of hits on T0 detector vs time in run; "
796  "Strip; Time in run [s]; Hits Count []",
798  0.,
801  0,
803  for (UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill++) {
804  fvhDpbMapSpill.push_back(new TH1I(
805  Form("hDpbMapSpill%02u", uSpill),
806  Form(
807  "Map of hits on T0 detector in current spill %02u; DPB; Hits Count []",
808  uSpill),
809  fuNrOfGdpbs,
810  -0.5,
811  fuNrOfGdpbs - 0.5));
812  fvhChannelMapSpill.push_back(
813  new TH1I(Form("hChannelMapSpill%02u", uSpill),
814  Form("Map of hits on T0 detector in current spill %02u; Strip; "
815  "Hits Count []",
816  uSpill),
818  -0.5,
819  kuNbChanDiamond - 0.5));
820  } // for( UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill ++)
821  fhHitsPerSpill = new TH1I("hHitsPerSpill",
822  "Hit count per spill; Spill; Hits Count []",
823  2000,
824  0.,
825  2000);
826 
827  fhMsgCntEvo = new TH1I("hMsgCntEvo",
828  "Evolution of Hit & error msgs counts vs time in run; "
829  "Time in run [s]; Msgs Count []",
831  0,
833  fhHitCntEvo = new TH1I(
834  "hHitCntEvo",
835  "Evolution of Hit counts vs time in run; Time in run [s]; Hits Count []",
837  0,
839  fhErrorCntEvo = new TH1I(
840  "hErrorCntEvo",
841  "Evolution of Error counts vs time in run; Time in run [s]; Error Count []",
843  0,
845  fhLostEvtCntEvo = new TH1I("hLostEvtCntEvo",
846  "Evolution of LostEvent counts vs time in run; "
847  "Time in run [s]; LostEvent Count []",
849  0,
851 
852  fhErrorFractEvo = new TProfile("hErrorFractEvo",
853  "Evolution of Error Fraction vs time in run; "
854  "Time in run [s]; Error Fract []",
856  0,
858  fhLostEvtFractEvo = new TProfile("hLostEvtFractEvo",
859  "Evolution of LostEvent Fraction vs time in "
860  "run; Time in run [s]; LostEvent Fract []",
862  0,
864 
866  new TH2I("hMsgCntPerMsEvo",
867  "Evolution of Hit & error msgs counts, per MS vs time in run; "
868  "Time in run [s]; Hits Count/MS []; MS",
870  0,
872  iNbBinsLog,
873  dBinsLog);
874  fhHitCntPerMsEvo = new TH2I("hHitCntPerMsEvo",
875  "Evolution of Hit counts, per MS vs time in run; "
876  "Time in run [s]; Hits Count/MS []; MS",
878  0,
880  iNbBinsLog,
881  dBinsLog);
882  fhErrorCntPerMsEvo = new TH2I("hErrorCntPerMsEvo",
883  "Evolution of Error counts, per MS vs time in "
884  "run; Time in run [s]; Error Count/MS []; MS",
886  0,
888  iNbBinsLog,
889  dBinsLog);
891  new TH2I("hLostEvtCntPerMsEvo",
892  "Evolution of LostEvent, per MS counts vs time in run; Time in "
893  "run [s]; LostEvent Count/MS []; MS",
895  0,
897  iNbBinsLog,
898  dBinsLog);
899 
901  new TH2I("hErrorFractPerMsEvo",
902  "Evolution of Error Fraction, per MS vs time in run; Time in run "
903  "[s]; Error Fract/MS []; MS",
905  0,
907  1000,
908  0,
909  1);
911  new TH2I("hLostEvtFractPerMsEvo",
912  "Evolution of LostEvent Fraction, per MS vs time in run; Time in "
913  "run [s]; LostEvent Fract/MS []; MS",
915  0,
917  1000,
918  0,
919  1);
920 
922  new TH1I("fhChannelMapPulser",
923  "Map of pulser hits on T0 detector; Chan; Hits Count []",
925  0.,
927  fhHitMapEvoPulser = new TH2I("fhHitMapEvoPulser",
928  "Map of hits on T0 detector vs time in run; "
929  "Chan; Time in run [s]; Hits Count []",
931  0.,
934  0,
936 
938  AddHistoToVector(fhDpbMap, sFolder);
939  AddHistoToVector(fhChannelMap, sFolder);
940  AddHistoToVector(fhHitMapEvo, sFolder);
941  AddHistoToVector(fhHitTotEvo, sFolder);
943  for (UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill++) {
944  AddHistoToVector(fvhDpbMapSpill[uSpill], sFolder);
945  AddHistoToVector(fvhChannelMapSpill[uSpill], sFolder);
946  } // for( UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill ++)
948 
949  AddHistoToVector(fhMsgCntEvo, sFolder);
950  AddHistoToVector(fhHitCntEvo, sFolder);
953 
956 
963 
966 
967  /*******************************************************************/
968  for (UInt_t uChan = 0; uChan < kuNbChanDiamond; ++uChan) {
969  fvhMsgCntEvoChan[uChan] =
970  new TH1I(Form("hMsgCntEvoChan%02u", uChan),
971  Form("Evolution of Messages counts vs time in run for channel "
972  "%02u; Time in run [s]; Messages Count []",
973  uChan),
975  0,
977  fvhMsgCntPerMsEvoChan[uChan] =
978  new TH2I(Form("hMsgCntPerMsEvoChan%02u", uChan),
979  Form("Evolution of Hit counts per MS vs time in run for channel "
980  "%02u; Time in run [s]; Hits Count/MS []; MS",
981  uChan),
983  0,
985  iNbBinsLog,
986  dBinsLog);
987 
988  fvhHitCntEvoChan[uChan] =
989  new TH1I(Form("hHitCntEvoChan%02u", uChan),
990  Form("Evolution of Hit counts vs time in run for channel %02u; "
991  "Time in run [s]; Hits Count []",
992  uChan),
994  0,
996  fvhHitCntPerMsEvoChan[uChan] =
997  new TH2I(Form("hHitCntPerMsEvoChan%02u", uChan),
998  Form("Evolution of Hit counts per MS vs time in run for channel "
999  "%02u; Time in run [s]; Hits Count/MS []; MS",
1000  uChan),
1002  0,
1004  iNbBinsLog,
1005  dBinsLog);
1006 
1007  fvhErrorCntEvoChan[uChan] =
1008  new TH1I(Form("hErrorCntEvoChan%02u", uChan),
1009  Form("Evolution of Error counts vs time in run for channel "
1010  "%02u; Time in run [s]; Error Count []",
1011  uChan),
1013  0,
1015  fvhErrorCntPerMsEvoChan[uChan] =
1016  new TH2I(Form("hErrorCntPerMsEvoChan%02u", uChan),
1017  Form("Evolution of Error counts per MS vs time in run for "
1018  "channel %02u; Time in run [s]; Error Count/MS []; MS",
1019  uChan),
1021  0,
1023  iNbBinsLog,
1024  dBinsLog);
1025 
1026  fvhEvtLostCntEvoChan[uChan] =
1027  new TH1I(Form("hEvtLostCntEvoChan%02u", uChan),
1028  Form("Evolution of LostEvent counts vs time in run for channel "
1029  "%02u; Time in run [s]; LostEvent Count []",
1030  uChan),
1032  0,
1034  fvhEvtLostCntPerMsEvoChan[uChan] =
1035  new TH2I(Form("hEvtLostCntPerMsEvoChan%02u", uChan),
1036  Form("Evolution of LostEvent counts per MS vs time in run for "
1037  "channel %02u; Time in run [s]; LostEvent Count/MS []; MS",
1038  uChan),
1040  0,
1042  iNbBinsLog,
1043  dBinsLog);
1044 
1045  fvhErrorFractEvoChan[uChan] =
1046  new TProfile(Form("hErrorFractEvoChan%02u", uChan),
1047  Form("Evolution of Error Fraction vs time in run for "
1048  "channel %02u; Time in run [s]; Error Fract []",
1049  uChan),
1051  0,
1053  fvhErrorFractPerMsEvoChan[uChan] =
1054  new TH2I(Form("hErrorFractPerMsEvoChan%02u", uChan),
1055  Form("Evolution of Error Fraction, per MS vs time in run for "
1056  "channel %02u; Time in run [s]; Error Fract/MS []; MS",
1057  uChan),
1059  0,
1061  1000,
1062  0,
1063  1);
1064 
1065  fvhEvtLostFractEvoChan[uChan] =
1066  new TProfile(Form("hEvtLostFractEvoChan%02u", uChan),
1067  Form("Evolution of LostEvent Fraction vs time in run for "
1068  "channel %02u; Time in run [s]; LostEvent Fract []",
1069  uChan),
1071  0,
1073  fvhEvtLostFractPerMsEvoChan[uChan] = new TH2I(
1074  Form("hEvtLostFractPerMsEvoChan%02u", uChan),
1075  Form("Evolution of LostEvent Fraction, per MS vs time in run for channel "
1076  "%02u; Time in run [s]; LostEvent Fract/MS []; MS",
1077  uChan),
1079  0,
1081  1000,
1082  0,
1083  1);
1084 
1086  AddHistoToVector(fvhMsgCntEvoChan[uChan], sFolder);
1087  AddHistoToVector(fvhMsgCntPerMsEvoChan[uChan], sFolder);
1088  AddHistoToVector(fvhHitCntEvoChan[uChan], sFolder);
1089  AddHistoToVector(fvhHitCntPerMsEvoChan[uChan], sFolder);
1090  AddHistoToVector(fvhErrorCntEvoChan[uChan], sFolder);
1091  AddHistoToVector(fvhErrorCntPerMsEvoChan[uChan], sFolder);
1092  AddHistoToVector(fvhEvtLostCntEvoChan[uChan], sFolder);
1094  AddHistoToVector(fvhErrorFractEvoChan[uChan], sFolder);
1096  AddHistoToVector(fvhEvtLostFractEvoChan[uChan], sFolder);
1098  } // for( UInt_t uChan = 0; uChan < kuNbChanDiamond; ++uChan )
1099 
1101  // delete dBinsLog;
1102 
1103  /*******************************************************************/
1104 
1106  Double_t w = 10;
1107  Double_t h = 10;
1108 
1109  /*******************************************************************/
1111  fcHitMaps = new TCanvas("cHitMaps", "Hit maps", w, h);
1112  fcHitMaps->Divide(2);
1113 
1114  fcHitMaps->cd(1);
1115  gPad->SetGridx();
1116  gPad->SetGridy();
1117  gPad->SetLogy();
1118  fhChannelMap->Draw();
1119 
1120  fcHitMaps->cd(2);
1121  gPad->SetGridx();
1122  gPad->SetGridy();
1123  gPad->SetLogz();
1124  fhHitMapEvo->Draw("colz");
1125 
1126  AddCanvasToVector(fcHitMaps, "canvases");
1127  /*******************************************************************/
1128 
1129  /*******************************************************************/
1131  fcSummary =
1132  new TCanvas("cSummary", "Hit maps, Hit rate, Error fraction", w, h);
1133  fcSummary->Divide(2, 2);
1134 
1135  fcSummary->cd(1);
1136  gPad->SetGridx();
1137  gPad->SetGridy();
1138  gPad->SetLogy();
1139  fhChannelMap->Draw();
1140 
1141  fcSummary->cd(2);
1142  gPad->SetGridx();
1143  gPad->SetGridy();
1144  gPad->SetLogz();
1145  fhHitMapEvo->Draw("colz");
1146 
1147  fcSummary->cd(3);
1148  gPad->SetGridx();
1149  gPad->SetGridy();
1150  gPad->SetLogy();
1151  fhHitCntEvo->Draw();
1152 
1153  fcSummary->cd(4);
1154  gPad->SetGridx();
1155  gPad->SetGridy();
1156  gPad->SetLogz();
1157  fhErrorFractEvo->Draw("hist");
1158 
1159  AddCanvasToVector(fcSummary, "canvases");
1160  /*******************************************************************/
1161 
1162  /*******************************************************************/
1164  fcGenCntsPerMs = new TCanvas(
1165  "cGenCntsPerMs",
1166  "Messages and hit cnt per MS, Error and Evt Loss Fract. per MS ",
1167  w,
1168  h);
1169  fcGenCntsPerMs->Divide(2, 2);
1170 
1171  fcGenCntsPerMs->cd(1);
1172  gPad->SetGridx();
1173  gPad->SetGridy();
1174  gPad->SetLogy();
1175  gPad->SetLogz();
1176  fhMsgCntPerMsEvo->Draw("colz");
1177 
1178  fcGenCntsPerMs->cd(2);
1179  gPad->SetGridx();
1180  gPad->SetGridy();
1181  gPad->SetLogy();
1182  gPad->SetLogz();
1183  fhHitCntPerMsEvo->Draw("colz");
1184 
1185  fcGenCntsPerMs->cd(3);
1186  gPad->SetGridx();
1187  gPad->SetGridy();
1188  gPad->SetLogy();
1189  gPad->SetLogz();
1190  fhErrorFractPerMsEvo->Draw("colz");
1191 
1192  fcGenCntsPerMs->cd(4);
1193  gPad->SetGridx();
1194  gPad->SetGridy();
1195  gPad->SetLogy();
1196  gPad->SetLogz();
1197  fhLostEvtFractPerMsEvo->Draw("colz");
1198 
1199  AddCanvasToVector(fcGenCntsPerMs, "canvases");
1200  /*******************************************************************/
1201 
1202  /*******************************************************************/
1204  fcSpillCounts =
1205  new TCanvas("cSpillCounts",
1206  "Counts per spill, last 5 spills including current one",
1207  w,
1208  h);
1209  fcSpillCounts->Divide(1, kuNbSpillPlots);
1210 
1211  for (UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill++) {
1212  fcSpillCounts->cd(1 + uSpill);
1213  gPad->SetGridx();
1214  gPad->SetGridy();
1215  // gPad->SetLogy();
1216  // fvhChannelMapSpill[ uSpill ]->SetStats( kTRUE );
1217  fvhChannelMapSpill[uSpill]->Draw();
1218  gPad->Update();
1219  TPaveStats* st =
1220  (TPaveStats*) fvhChannelMapSpill[uSpill]->FindObject("stats");
1221  st->SetOptStat(10);
1222  st->SetX1NDC(0.25);
1223  st->SetX2NDC(0.95);
1224  st->SetY1NDC(0.90);
1225  st->SetY2NDC(0.95);
1226  } // for( UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill ++)
1227 
1228  AddCanvasToVector(fcSpillCounts, "canvases");
1229  /*******************************************************************/
1230 
1231  /*******************************************************************/
1234  new TCanvas("cSpillCountsHori",
1235  "Counts per spill, last 5 spills including current one",
1236  w,
1237  h);
1239 
1240  for (UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill++) {
1241  fcSpillCountsHori->cd(1 + uSpill);
1242  gPad->SetGridx();
1243  gPad->SetGridy();
1244  gPad->SetLogy();
1245  fvhChannelMapSpill[uSpill]->Draw();
1246  gPad->Update();
1247  TPaveStats* st =
1248  (TPaveStats*) fvhChannelMapSpill[uSpill]->FindObject("stats");
1249  st->SetOptStat(10);
1250  st->SetX1NDC(0.25);
1251  st->SetX2NDC(0.95);
1252  st->SetY1NDC(0.90);
1253  st->SetY2NDC(0.95);
1254  } // for( UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill ++)
1255 
1256  AddCanvasToVector(fcSpillCountsHori, "canvases");
1257  /*******************************************************************/
1258 
1259  /*******************************************************************/
1262  new TCanvas("cSpillDpbCountsHori",
1263  "Counts in DPB per spill, last 5 spills including current one",
1264  w,
1265  h);
1267 
1268  for (UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill++) {
1269  fcSpillDpbCountsHori->cd(1 + uSpill);
1270  gPad->SetGridx();
1271  gPad->SetGridy();
1272  gPad->SetLogy();
1273  fvhDpbMapSpill[uSpill]->Draw();
1274  gPad->Update();
1275  TPaveStats* st = (TPaveStats*) fvhDpbMapSpill[uSpill]->FindObject("stats");
1276  st->SetOptStat(110);
1277  st->SetX1NDC(0.25);
1278  st->SetX2NDC(0.95);
1279  st->SetY1NDC(0.90);
1280  st->SetY2NDC(0.95);
1281  } // for( UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill ++)
1282 
1284  /*******************************************************************/
1285 
1286  return kTRUE;
1287 }
1289  Double_t dMsgCountChan;
1290  Double_t dFractErrorsInMsChan;
1291  Double_t dFractLostEvtInMsChan;
1292  UInt_t uCountHitsInMs = 0;
1293  UInt_t uCountErrorsInMs = 0;
1294  UInt_t uCountLostEvtInMs = 0;
1295  for (UInt_t uChan = 0; uChan < kuNbChanDiamond; ++uChan) {
1296  dMsgCountChan = fvuHitCntChanMs[uChan] + fvuErrorCntChanMs[uChan];
1297  dFractErrorsInMsChan = fvuErrorCntChanMs[uChan];
1298  dFractLostEvtInMsChan = fvuEvtLostCntChanMs[uChan];
1299 
1300  dFractErrorsInMsChan /= dMsgCountChan;
1301  dFractLostEvtInMsChan /= dMsgCountChan;
1302 
1303  fvhMsgCntEvoChan[uChan]->Fill(fdMsTime - fdStartTime, dMsgCountChan);
1304  fvhMsgCntPerMsEvoChan[uChan]->Fill(fdMsTime - fdStartTime, dMsgCountChan);
1306  fvuHitCntChanMs[uChan]);
1308  fvuErrorCntChanMs[uChan]);
1310  fvuEvtLostCntChanMs[uChan]);
1312  dFractErrorsInMsChan);
1314  dFractLostEvtInMsChan);
1315 
1316  uCountHitsInMs += fvuHitCntChanMs[uChan];
1317  uCountErrorsInMs += fvuErrorCntChanMs[uChan];
1318  uCountLostEvtInMs += fvuEvtLostCntChanMs[uChan];
1319 
1320  fvuHitCntChanMs[uChan] = 0;
1321  fvuErrorCntChanMs[uChan] = 0;
1322  fvuEvtLostCntChanMs[uChan] = 0;
1323  } // for( UInt_t uChan = 0; uChan < kuNbChanDiamond; ++uChan )
1324  Double_t dFractErrorsInMs = uCountErrorsInMs;
1325  Double_t dFractLostEvtInMs = uCountLostEvtInMs;
1326  dFractErrorsInMs /= (uCountHitsInMs + uCountErrorsInMs);
1327  dFractLostEvtInMs /= (uCountHitsInMs + uCountErrorsInMs);
1328 
1330  uCountHitsInMs + uCountErrorsInMs);
1331  fhHitCntPerMsEvo->Fill(fdMsTime - fdStartTime, uCountHitsInMs);
1332  fhErrorCntPerMsEvo->Fill(fdMsTime - fdStartTime, uCountErrorsInMs);
1333  fhLostEvtCntPerMsEvo->Fill(fdMsTime - fdStartTime, uCountLostEvtInMs);
1334  fhErrorFractPerMsEvo->Fill(fdMsTime - fdStartTime, dFractErrorsInMs);
1335  fhLostEvtFractPerMsEvo->Fill(fdMsTime - fdStartTime, dFractLostEvtInMs);
1336 
1337  return kTRUE;
1338 }
1340  for (UInt_t uChan = 0; uChan < kuNbChanDiamond; ++uChan) {
1341  fvhMsgCntEvoChan[uChan]->Reset();
1342  fvhMsgCntPerMsEvoChan[uChan]->Reset();
1343 
1344  fvhHitCntEvoChan[uChan]->Reset();
1345  fvhHitCntPerMsEvoChan[uChan]->Reset();
1346 
1347  fvhErrorCntEvoChan[uChan]->Reset();
1348  fvhErrorCntPerMsEvoChan[uChan]->Reset();
1349 
1350  fvhEvtLostCntEvoChan[uChan]->Reset();
1351  fvhEvtLostCntPerMsEvoChan[uChan]->Reset();
1352 
1353  fvhErrorFractEvoChan[uChan]->Reset();
1354  fvhErrorFractPerMsEvoChan[uChan]->Reset();
1355 
1356  fvhEvtLostFractEvoChan[uChan]->Reset();
1357  fvhEvtLostFractPerMsEvoChan[uChan]->Reset();
1358  } // for( UInt_t uChan = 0; uChan < kuNbChanDiamond; ++uChan )
1359 
1360  fuCurrentSpillIdx = 0;
1361  fuCurrentSpillPlot = 0;
1362  fhDpbMap->Reset();
1363  fhChannelMap->Reset();
1364  fhHitMapEvo->Reset();
1365  for (UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill++) {
1366  fvhDpbMapSpill[uSpill]->Reset();
1367  fvhChannelMapSpill[uSpill]->Reset();
1368  } // for( UInt_t uSpill = 0; uSpill < kuNbSpillPlots; uSpill ++)
1369  fhHitsPerSpill->Reset();
1370 
1371  fhMsgCntEvo->Reset();
1372  fhHitCntEvo->Reset();
1373  fhErrorCntEvo->Reset();
1374 
1375  fhErrorFractEvo->Reset();
1376  fhLostEvtFractEvo->Reset();
1377 
1378  fhMsgCntPerMsEvo->Reset();
1379  fhHitCntPerMsEvo->Reset();
1380  fhErrorCntPerMsEvo->Reset();
1381  fhLostEvtCntPerMsEvo->Reset();
1382  fhErrorFractPerMsEvo->Reset();
1383  fhLostEvtFractPerMsEvo->Reset();
1384 
1385  fhChannelMapPulser->Reset();
1386  fhHitMapEvoPulser->Reset();
1387 
1388  if (kTRUE == bResetTime) {
1390  fdStartTime = -1.0;
1391  } // if( kTRUE == bResetTime )
1392 
1393  return kTRUE;
1394 }
1395 // -------------------------------------------------------------------------
CbmMcbm2018MonitorAlgoT0::fuNrOfChannelsPerGet4
UInt_t fuNrOfChannelsPerGet4
Number of GET4s per FEE.
Definition: CbmMcbm2018MonitorAlgoT0.h:108
CbmMcbm2018MonitorAlgoT0::fcSpillDpbCountsHori
TCanvas * fcSpillDpbCountsHori
Definition: CbmMcbm2018MonitorAlgoT0.h:251
gdpbv100::MSG_STAR_TRI_A
@ MSG_STAR_TRI_A
Definition: gDpbMessv100.h:63
gdpbv100::Message
Definition: gDpbMessv100.h:133
CbmMcbm2018MonitorAlgoT0::fvvmEpSupprBuffer
std::vector< std::vector< gdpbv100::Message > > fvvmEpSupprBuffer
Buffers.
Definition: CbmMcbm2018MonitorAlgoT0.h:168
CbmMcbm2018MonitorAlgoT0::fhLostEvtCntEvo
TH1 * fhLostEvtCntEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:230
CbmMcbm2018MonitorAlgoT0::fuNrOfChannelsPerFee
UInt_t fuNrOfChannelsPerFee
Number of channels in each GET4.
Definition: CbmMcbm2018MonitorAlgoT0.h:109
CbmMcbm2018MonitorAlgoT0::fvhErrorFractEvoChan
std::vector< TProfile * > fvhErrorFractEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:199
CbmStar2019Algo< CbmTofDigi >::fdMsSizeInNs
Double_t fdMsSizeInNs
/‍** Ignore Overlap Ms: all fuOverlapMsNb MS at the end of timeslice **‍/
Definition: CbmStar2019Algo.h:117
CbmMcbm2018MonitorAlgoT0::fhMsgCntPerMsEvo
TH2 * fhMsgCntPerMsEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:234
CbmMcbm2018MonitorAlgoT0::fvulCurrentEpochFull
std::vector< ULong64_t > fvulCurrentEpochFull
Epoch cycle from the Ms Start message and Epoch counter flip.
Definition: CbmMcbm2018MonitorAlgoT0.h:156
CbmMcbm2018MonitorAlgoT0::fvhErrorFractPerMsEvoChan
std::vector< TH2 * > fvhErrorFractPerMsEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:201
CbmMcbm2018MonitorAlgoT0::Reset
virtual void Reset()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:53
CbmMcbm2018MonitorAlgoT0::fcSummary
TCanvas * fcSummary
Canvases.
Definition: CbmMcbm2018MonitorAlgoT0.h:246
CbmMcbm2018MonitorAlgoT0::fdTsStopTimeCore
Double_t fdTsStopTimeCore
Time in ns of current TS from the index of the first MS first component.
Definition: CbmMcbm2018MonitorAlgoT0.h:130
CbmMcbm2018MonitorAlgoT0::fdMsTime
Double_t fdMsTime
End Time in ns of current TS Core from the index of the first MS first component.
Definition: CbmMcbm2018MonitorAlgoT0.h:132
CbmMcbm2018MonitorAlgoT0::fuOffSpillCountLimit
UInt_t fuOffSpillCountLimit
Definition: CbmMcbm2018MonitorAlgoT0.h:117
CbmMcbm2018MonitorAlgoT0::fuMaxTotPulser
UInt_t fuMaxTotPulser
Definition: CbmMcbm2018MonitorAlgoT0.h:116
CbmStar2019Algo< CbmTofDigi >::fuNbMsLoop
size_t fuNbMsLoop
Definition: CbmStar2019Algo.h:114
CbmMcbm2018MonitorAlgoT0::fvhEvtLostFractPerMsEvoChan
std::vector< TH2 * > fvhEvtLostFractPerMsEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:205
CbmMcbm2018MonitorAlgoT0::fuNrOfFeePerGdpb
UInt_t fuNrOfFeePerGdpb
gDPB ID to index map
Definition: CbmMcbm2018MonitorAlgoT0.h:106
CbmMcbm2018MonitorAlgoT0::fuDiamChanMap
UInt_t fuDiamChanMap[kuNbChanDiamond]
Definition: CbmMcbm2018MonitorAlgoT0.h:216
CbmMcbm2018MonitorAlgoT0::fcSpillCountsHori
TCanvas * fcSpillCountsHori
Definition: CbmMcbm2018MonitorAlgoT0.h:250
CbmMcbm2018TofPar::GetGdpbId
Int_t GetGdpbId(Int_t i)
Definition: CbmMcbm2018TofPar.h:67
CbmMcbm2018MonitorAlgoT0::fvhHitCntEvoChan
std::vector< TH1 * > fvhHitCntEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:187
CbmMcbm2018MonitorAlgoT0::kuNbChanDiamond
static const UInt_t kuNbChanDiamond
Definition: CbmMcbm2018MonitorAlgoT0.h:122
CbmMcbm2018MonitorAlgoT0::kuNbSpillPlots
static const UInt_t kuNbSpillPlots
Definition: CbmMcbm2018MonitorAlgoT0.h:214
CbmMcbm2018TofPar.h
CbmMcbm2018MonitorAlgoT0::fvuErrorCntChanMs
std::vector< UInt_t > fvuErrorCntChanMs
Definition: CbmMcbm2018MonitorAlgoT0.h:179
gdpbv100::SYS_GET4_ERROR
@ SYS_GET4_ERROR
Definition: gDpbMessv100.h:70
gdpbv100::MSG_HIT
@ MSG_HIT
Definition: gDpbMessv100.h:59
CbmMcbm2018MonitorAlgoT0::fhLostEvtCntPerMsEvo
TH2 * fhLostEvtCntPerMsEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:237
CbmMcbm2018MonitorAlgoT0::fdLastSecondTime
Double_t fdLastSecondTime
Definition: CbmMcbm2018MonitorAlgoT0.h:212
CbmMcbm2018MonitorAlgoT0::fcSpillCounts
TCanvas * fcSpillCounts
Definition: CbmMcbm2018MonitorAlgoT0.h:249
i
int i
Definition: L1/vectors/P4_F32vec4.h:25
gdpbv100::MSG_SLOWC
@ MSG_SLOWC
Definition: gDpbMessv100.h:61
CbmMcbm2018MonitorAlgoT0::fuCountsLastSecond
UInt_t fuCountsLastSecond
Definition: CbmMcbm2018MonitorAlgoT0.h:213
CbmMcbm2018MonitorAlgoT0::fbMonitorMode
Bool_t fbMonitorMode
Control flags.
Definition: CbmMcbm2018MonitorAlgoT0.h:95
CbmMcbm2018MonitorAlgoT0::fuCurrentEquipmentId
UInt_t fuCurrentEquipmentId
Definition: CbmMcbm2018MonitorAlgoT0.h:137
CbmMcbm2018MonitorAlgoT0::InitParameters
Bool_t InitParameters()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:85
CbmStar2019Algo< CbmTofDigi >::fuNbOverMsPerTs
size_t fuNbOverMsPerTs
Definition: CbmStar2019Algo.h:113
CbmMcbm2018MonitorAlgoT0::fvuEvtLostCntChanMs
std::vector< UInt_t > fvuEvtLostCntChanMs
Definition: CbmMcbm2018MonitorAlgoT0.h:181
gdpbv100::MSG_STAR_TRI_D
@ MSG_STAR_TRI_D
Definition: gDpbMessv100.h:66
gdpbv100::Message::getMessageType
uint8_t getMessageType() const
Returns the message type. Valid for all message types. 4 bit.
Definition: gDpbMessv100.h:206
CbmMcbm2018MonitorAlgoT0::fhHitsPerSpill
TH1 * fhHitsPerSpill
Definition: CbmMcbm2018MonitorAlgoT0.h:225
CbmStar2019Algo< CbmTofDigi >::AddHistoToVector
void AddHistoToVector(TNamed *pointer, std::string sFolder="")
For monitor algos.
Definition: CbmStar2019Algo.h:80
CbmMcbm2018MonitorAlgoT0::fvulCurrentEpochCycle
std::vector< ULong64_t > fvulCurrentEpochCycle
Current epoch index, per DPB.
Definition: CbmMcbm2018MonitorAlgoT0.h:154
CbmMcbm2018MonitorAlgoT0::ResetHistograms
Bool_t ResetHistograms(Bool_t bResetTime=kTRUE)
Definition: CbmMcbm2018MonitorAlgoT0.cxx:1339
gdpbv100::Message::getGdpbSysSubType
uint16_t getGdpbSysSubType() const
Definition: gDpbMessv100.h:245
CbmMcbm2018MonitorAlgoT0::fhLostEvtFractEvo
TProfile * fhLostEvtFractEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:232
CbmStar2019Algo< CbmTofDigi >::fuNbCoreMsPerTs
size_t fuNbCoreMsPerTs
Definition: CbmStar2019Algo.h:112
CbmMcbm2018MonitorAlgoT0::fuCurrentSpillPlot
UInt_t fuCurrentSpillPlot
Definition: CbmMcbm2018MonitorAlgoT0.h:210
gdpbv100::Message::isStarTrigger
bool isStarTrigger() const
Returns true is message type is MSG_STAR_TRI_A, _B, _C, _D (STAR Trigger message)
Definition: gDpbMessv100.h:329
CbmMcbm2018MonitorAlgoT0::ProcessMs
Bool_t ProcessMs(const fles::Timeslice &ts, size_t uMsCompIdx, size_t uMsIdx)
Definition: CbmMcbm2018MonitorAlgoT0.cxx:227
CbmStar2019Algo< CbmTofDigi >::fdTsFullSizeInNs
Double_t fdTsFullSizeInNs
Total size of the core MS in a TS, [nanoseconds].
Definition: CbmStar2019Algo.h:121
gdpbv100::Message::getGdpbSysErrData
uint16_t getGdpbSysErrData() const
Definition: gDpbMessv100.h:253
CbmStar2019Algo< CbmTofDigi >::fParCList
TList * fParCList
Parameter management.
Definition: CbmStar2019Algo.h:108
CbmMcbm2018MonitorAlgoT0::fdTsStartTime
Double_t fdTsStartTime
Definition: CbmMcbm2018MonitorAlgoT0.h:128
CbmMcbm2018MonitorAlgoT0::fuNrOfGet4PerFee
UInt_t fuNrOfGet4PerFee
Number of FEBs per GDPB.
Definition: CbmMcbm2018MonitorAlgoT0.h:107
CbmStar2019Algo< CbmTofDigi >::fvMsComponentsList
std::vector< size_t > fvMsComponentsList
Parameters related to FLES containers.
Definition: CbmStar2019Algo.h:111
CbmMcbm2018MonitorAlgoT0::fuGet4Id
UInt_t fuGet4Id
Bin size in s for the plots with date as X axis.
Definition: CbmMcbm2018MonitorAlgoT0.h:147
CbmMcbm2018MonitorAlgoT0::fuCurrDpbIdx
UInt_t fuCurrDpbIdx
Temp holder until Current equipment ID is properly filled in MS.
Definition: CbmMcbm2018MonitorAlgoT0.h:141
CbmMcbm2018MonitorAlgoT0::fUnpackPar
CbmMcbm2018TofPar * fUnpackPar
Settings from parameter file.
Definition: CbmMcbm2018MonitorAlgoT0.h:102
CbmMcbm2018MonitorAlgoT0::fuMsIndex
UInt_t fuMsIndex
Start Time in ns of current MS from its index field in header.
Definition: CbmMcbm2018MonitorAlgoT0.h:134
CbmMcbm2018MonitorAlgoT0::InitContainers
Bool_t InitContainers()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:61
CbmTofDetectorId_v14a.h
CbmMcbm2018MonitorAlgoT0::fvhEvtLostFractEvoChan
std::vector< TProfile * > fvhEvtLostFractEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:203
CbmMcbm2018MonitorAlgoT0::fvhEvtLostCntPerMsEvoChan
std::vector< TH2 * > fvhEvtLostCntPerMsEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:197
CbmMcbm2018TofPar::GetNrOfGdpbs
Int_t GetNrOfGdpbs()
FIXME: replace with method returning the correspondign constants! see Star2019 parameter.
Definition: CbmMcbm2018TofPar.h:66
CbmMcbm2018MonitorAlgoT0::fhHitTotEvo
TH2 * fhHitTotEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:221
CbmMcbm2018MonitorAlgoT0::fvmHitsInMs
std::vector< gdpbv100::FullMessage > fvmHitsInMs
[DPB]
Definition: CbmMcbm2018MonitorAlgoT0.h:169
CbmMcbm2018MonitorAlgoT0::fvuHitCntChanMs
std::vector< UInt_t > fvuHitCntChanMs
Definition: CbmMcbm2018MonitorAlgoT0.h:178
gdpbv100::MSG_STAR_TRI_C
@ MSG_STAR_TRI_C
Definition: gDpbMessv100.h:65
CbmMcbm2018MonitorAlgoT0::fulCurrentMsIdx
ULong64_t fulCurrentMsIdx
Definition: CbmMcbm2018MonitorAlgoT0.h:127
CbmMcbm2018MonitorAlgoT0::FillHistograms
Bool_t FillHistograms()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:1288
CbmMcbm2018MonitorAlgoT0::fGdpbIdIndexMap
std::map< UInt_t, UInt_t > fGdpbIdIndexMap
Total number of GDPBs in the system.
Definition: CbmMcbm2018MonitorAlgoT0.h:105
h
Data class with information on a STS local track.
CbmMcbm2018MonitorAlgoT0::fvhErrorCntEvoChan
std::vector< TH1 * > fvhErrorCntEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:191
CbmMcbm2018MonitorAlgoT0::fbSpillOn
Bool_t fbSpillOn
Channels map.
Definition: CbmMcbm2018MonitorAlgoT0.h:208
CbmMcbm2018MonitorAlgoT0::fulCurrentTsIdx
ULong64_t fulCurrentTsIdx
Definition: CbmMcbm2018MonitorAlgoT0.h:126
CbmMcbm2018MonitorAlgoT0::fhLostEvtFractPerMsEvo
TH2 * fhLostEvtFractPerMsEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:239
CbmMcbm2018MonitorAlgoT0::fhHitMapEvoPulser
TH2 * fhHitMapEvoPulser
Definition: CbmMcbm2018MonitorAlgoT0.h:243
CbmMcbm2018MonitorAlgoT0::CbmMcbm2018MonitorAlgoT0
CbmMcbm2018MonitorAlgoT0()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:37
CbmStar2019Algo
Definition: CbmStar2019Algo.h:43
CbmMcbm2018MonitorAlgoT0::kuBytesPerMessage
static const UInt_t kuBytesPerMessage
Definition: CbmMcbm2018MonitorAlgoT0.h:121
CbmMcbm2018MonitorAlgoT0::AddMsComponentToList
void AddMsComponentToList(size_t component, UShort_t usDetectorId)
Definition: CbmMcbm2018MonitorAlgoT0.cxx:130
CbmMcbm2018MonitorAlgoT0::fuGet4Nr
UInt_t fuGet4Nr
running number (0 to fuNrOfGet4PerGdpb) of the Get4 chip of a unique GDPB for current message
Definition: CbmMcbm2018MonitorAlgoT0.h:149
CbmMcbm2018MonitorAlgoT0::fhMsgCntEvo
TH1 * fhMsgCntEvo
Global Rate.
Definition: CbmMcbm2018MonitorAlgoT0.h:227
CbmMcbm2018MonitorAlgoT0::Finish
virtual void Finish()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:54
CbmMcbm2018MonitorAlgoT0::ProcessTs
Bool_t ProcessTs(const fles::Timeslice &ts)
Definition: CbmMcbm2018MonitorAlgoT0.cxx:145
CbmMcbm2018MonitorAlgoT0::fhHitCntEvo
TH1 * fhHitCntEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:228
CbmMcbm2018MonitorAlgoT0::fhErrorCntPerMsEvo
TH2 * fhErrorCntPerMsEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:236
CbmStar2019Algo< CbmTofDigi >::fdTsCoreSizeInNs
Double_t fdTsCoreSizeInNs
Size of a single MS, [nanoseconds].
Definition: CbmStar2019Algo.h:119
CbmTofAddress.h
gdpbv100::kuChipIdMergedEpoch
const uint32_t kuChipIdMergedEpoch
Definition: gDpbMessv100.h:51
CbmMcbm2018MonitorAlgoT0::fdStartTime
Double_t fdStartTime
Epoch + Epoch Cycle.
Definition: CbmMcbm2018MonitorAlgoT0.h:159
CbmMcbm2018MonitorAlgoT0::fhErrorCntEvo
TH1 * fhErrorCntEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:229
CbmMcbm2018MonitorAlgoT0::fuNrOfGet4PerGdpb
UInt_t fuNrOfGet4PerGdpb
Total number of Get4 chips in the system.
Definition: CbmMcbm2018MonitorAlgoT0.h:111
gdpbv100::MSG_SYST
@ MSG_SYST
Definition: gDpbMessv100.h:62
CbmMcbm2018MonitorAlgoT0::fhHitCntPerMsEvo
TH2 * fhHitCntPerMsEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:235
CbmMcbm2018MonitorAlgoT0::~CbmMcbm2018MonitorAlgoT0
~CbmMcbm2018MonitorAlgoT0()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:38
CbmMcbm2018MonitorAlgoT0::fuCurrDpbId
UInt_t fuCurrDpbId
Current equipment ID, tells from which DPB the current MS is originating.
Definition: CbmMcbm2018MonitorAlgoT0.h:139
CbmMcbm2018MonitorAlgoT0::fhErrorFractEvo
TProfile * fhErrorFractEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:231
FormatMsHeaderPrintout
std::string FormatMsHeaderPrintout(const fles::MicrosliceDescriptor &msDescriptor)
Definition: CbmFormatMsHeaderPrintout.cxx:5
CbmMcbm2018MonitorAlgoT0::fvhMsgCntPerMsEvoChan
std::vector< TH2 * > fvhMsgCntPerMsEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:185
GenerateLogBinArray
std::vector< double > GenerateLogBinArray(uint32_t uNbDecadesLog, uint32_t uNbStepsDecade, uint32_t uNbSubStepsInStep, uint32_t &uNbBinsLog)
Definition: CbmFlesHistosTools.cxx:6
CbmMcbm2018TofPar
Definition: CbmMcbm2018TofPar.h:18
CbmMcbm2018MonitorAlgoT0::fcHitMaps
TCanvas * fcHitMaps
Definition: CbmMcbm2018MonitorAlgoT0.h:247
CbmMcbm2018TofPar::GetNrOfChannelsPerGet4
Int_t GetNrOfChannelsPerGet4()
Definition: CbmMcbm2018TofPar.h:70
gdpbv100::MSG_EPOCH
@ MSG_EPOCH
Definition: gDpbMessv100.h:60
gdpbv100::GET4_V2X_ERR_LOST_EVT
@ GET4_V2X_ERR_LOST_EVT
Definition: gDpbMessv100.h:113
CbmMcbm2018MonitorAlgoT0::fvhDpbMapSpill
std::vector< TH1 * > fvhDpbMapSpill
Definition: CbmMcbm2018MonitorAlgoT0.h:223
CbmMcbm2018MonitorAlgoT0::fuMinTotPulser
UInt_t fuMinTotPulser
Number of channels per GDPB.
Definition: CbmMcbm2018MonitorAlgoT0.h:115
gdpbv100::Message::getGdpbHitIs24b
uint16_t getGdpbHitIs24b() const
Definition: gDpbMessv100.h:218
CbmMcbm2018MonitorAlgoT0::fcGenCntsPerMs
TCanvas * fcGenCntsPerMs
Definition: CbmMcbm2018MonitorAlgoT0.h:248
gdpbv100::Message::getGdpbGenChipId
uint16_t getGdpbGenChipId() const
Definition: gDpbMessv100.h:214
CbmFlesHistosTools.h
CbmMcbm2018MonitorAlgoT0::fuNrOfChannelsPerGdpb
UInt_t fuNrOfChannelsPerGdpb
Number of GET4s per GDPB.
Definition: CbmMcbm2018MonitorAlgoT0.h:112
CbmMcbm2018MonitorAlgoT0::fuCurrentSpillIdx
UInt_t fuCurrentSpillIdx
Definition: CbmMcbm2018MonitorAlgoT0.h:209
gdpbv100::MSG_STAR_TRI_B
@ MSG_STAR_TRI_B
Definition: gDpbMessv100.h:64
CbmMcbm2018MonitorAlgoT0::fhChanHitMapEvo
TH2 * fhChanHitMapEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:222
CbmMcbm2018MonitorAlgoT0::fvhChannelMapSpill
std::vector< TH1 * > fvhChannelMapSpill
Definition: CbmMcbm2018MonitorAlgoT0.h:224
CbmMcbm2018MonitorAlgoT0::fuHistoryHistoSize
UInt_t fuHistoryHistoSize
All hits (time in bins, TOT in bins, asic, channel) in last MS, sorted with "<" operator.
Definition: CbmMcbm2018MonitorAlgoT0.h:173
CbmStar2019Algo< CbmTofDigi >::AddCanvasToVector
void AddCanvasToVector(TCanvas *pointer, std::string sFolder="")
Definition: CbmStar2019Algo.h:87
CbmMcbm2018MonitorAlgoT0::Init
virtual Bool_t Init()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:48
CbmMcbm2018MonitorAlgoT0::fdStartTimeSpill
Double_t fdStartTimeSpill
Definition: CbmMcbm2018MonitorAlgoT0.h:211
CbmMcbm2018MonitorAlgoT0::fhChannelMap
TH1 * fhChannelMap
Definition: CbmMcbm2018MonitorAlgoT0.h:219
CbmMcbm2018MonitorAlgoT0::fhErrorFractPerMsEvo
TH2 * fhErrorFractPerMsEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:238
CbmMcbm2018MonitorAlgoT0::fhChannelMapPulser
TH1 * fhChannelMapPulser
Pulser.
Definition: CbmMcbm2018MonitorAlgoT0.h:242
CbmMcbm2018MonitorAlgoT0::fvulCurrentEpoch
std::vector< ULong64_t > fvulCurrentEpoch
Data format control: Current time references for each GDPB: merged epoch marker, epoch cycle,...
Definition: CbmMcbm2018MonitorAlgoT0.h:152
CbmMcbm2018MonitorAlgoT0::fuNrOfGdpbs
UInt_t fuNrOfGdpbs
Readout chain dimensions and mapping.
Definition: CbmMcbm2018MonitorAlgoT0.h:104
CbmMcbm2018MonitorAlgoT0::fhHitMapEvo
TH2 * fhHitMapEvo
Definition: CbmMcbm2018MonitorAlgoT0.h:220
CbmMcbm2018MonitorAlgoT0::fhDpbMap
TH1 * fhDpbMap
Map from electronics channel to Diamond strip.
Definition: CbmMcbm2018MonitorAlgoT0.h:218
CbmMcbm2018MonitorAlgoT0::GetParList
TList * GetParList()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:78
CbmMcbm2018MonitorAlgoT0::fvhErrorCntPerMsEvoChan
std::vector< TH2 * > fvhErrorCntPerMsEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:193
CbmMcbm2018TofPar::GetNrOfGet4PerFee
Int_t GetNrOfGet4PerFee()
Definition: CbmMcbm2018TofPar.h:69
CbmMcbm2018MonitorAlgoT0::CreateHistograms
Bool_t CreateHistograms()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:753
CbmStar2019Algo< CbmTofDigi >::fbIgnoreOverlapMs
Bool_t fbIgnoreOverlapMs
Definition: CbmStar2019Algo.h:116
CbmMcbm2018MonitorAlgoT0::fvhHitCntPerMsEvoChan
std::vector< TH2 * > fvhHitCntPerMsEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:189
gdpbv100::Message::getGdpbHit32Tot
uint16_t getGdpbHit32Tot() const
Definition: gDpbMessv100.h:227
CbmMcbm2018MonitorAlgoT0::fvhMsgCntEvoChan
std::vector< TH1 * > fvhMsgCntEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:183
CbmFormatMsHeaderPrintout.h
CbmMcbm2018MonitorAlgoT0::fvhEvtLostCntEvoChan
std::vector< TH1 * > fvhEvtLostCntEvoChan
Definition: CbmMcbm2018MonitorAlgoT0.h:195
CbmMcbm2018TofPar::GetNrOfFeesPerGdpb
Int_t GetNrOfFeesPerGdpb()
Definition: CbmMcbm2018TofPar.h:68
CbmMcbm2018MonitorAlgoT0::fvbMaskedComponents
std::vector< Bool_t > fvbMaskedComponents
Switch ON the filling of a additional set of histograms.
Definition: CbmMcbm2018MonitorAlgoT0.h:99
CbmMcbm2018MonitorAlgoT0::fuNrOfGet4
UInt_t fuNrOfGet4
Number of channels in each FEE.
Definition: CbmMcbm2018MonitorAlgoT0.h:110
CbmMcbm2018MonitorAlgoT0::ReInitContainers
Bool_t ReInitContainers()
Definition: CbmMcbm2018MonitorAlgoT0.cxx:67
CbmMcbm2018MonitorAlgoT0.h