From 2c7d39a60a65fc0913ccdbd23361f20b0143cb98 Mon Sep 17 00:00:00 2001 From: Siarhei Harkusha <Siarhei.Harkusha@cern.ch> Date: Fri, 20 Nov 2020 15:31:13 +0100 Subject: [PATCH] TileMonitoring: Add Tile monitoring histogram with bad CRC for Run 3 Tile monitoring histogram with global CRC errros has been added. Titles of several monitoring histograms have been fixed. --- .../python/TileDQFragMonitorAlgorithm.py | 21 ++++++++++++------- .../src/TileDQFragMonitorAlgorithm.cxx | 12 ++++++++++- 2 files changed, 24 insertions(+), 9 deletions(-) diff --git a/TileCalorimeter/TileMonitoring/python/TileDQFragMonitorAlgorithm.py b/TileCalorimeter/TileMonitoring/python/TileDQFragMonitorAlgorithm.py index 80fd2ae1af5..cf2674cbe06 100644 --- a/TileCalorimeter/TileMonitoring/python/TileDQFragMonitorAlgorithm.py +++ b/TileCalorimeter/TileMonitoring/python/TileDQFragMonitorAlgorithm.py @@ -107,19 +107,19 @@ def _TileDQFragMonitoringCore(helper, algConfObj, runNumber, **kwargs): # 2) Configure histogram with Tile error state in EventInfo vs lumi block errorStateGroup = helper.addGroup(tileDQFragMonAlg, 'TileEventsWithErrEventInfoLB', 'Tile/DMUErrors') errorStateGroup.defineHistogram('lumiBlock;TileEventsWithErrEventInfo', path = 'BadDrawers', type='TH1F', - title = '# events with Tile error state in EventInfo;LumiBlock;# events with error', + title = 'Run ' + run + ': # events with Tile error state in EventInfo;LumiBlock;# events with error', xbins = 1000, xmin = -0.5, xmax = 999.5, opt = 'kAddBinsDynamically') # 3) Configure histogram with number of consecutive bad Tile modules consecutiveBadGroup = helper.addGroup(tileDQFragMonAlg, 'TileConsecutiveBadModules', 'Tile/DMUErrors') consecutiveBadGroup.defineHistogram('TileConsecutiveBad', path = 'BadDrawers', type='TH1F', - title = 'Max # Tile consecutive bad modules;# consecutive bad modules;N', + title = 'Run ' + run + ': Max # Tile consecutive bad modules;# consecutive bad modules;N', xbins = 17, xmin = -0.5, xmax = 16.5) # 4) Configure histogram with number of consecutive bad Tile modules per lumi block consecutiveBadLBGroup = helper.addGroup(tileDQFragMonAlg, 'TileConsecutiveBadModulesLB', 'Tile/DMUErrors') consecutiveBadLBGroup.defineHistogram('lumiBlock,TileConsecutiveBad;TileConsecutiveBadLB', path = 'BadDrawers', type='TH2F', - title = 'Max # Tile consecutive bad modules;LumiBlock;# consecutive bad modules', + title = 'Run ' + run + ': Max # Tile consecutive bad modules;LumiBlock;# consecutive bad modules', xbins = 1000, xmin = -0.5, xmax = 999.5, ybins = 17, ymin = -0.5, ymax = 16.5, opt = 'kAddBinsDynamically') @@ -133,21 +133,26 @@ def _TileDQFragMonitoringCore(helper, algConfObj, runNumber, **kwargs): mismatchedLVL1Group = helper.addGroup(tileDQFragMonAlg, 'TileMismatchedL1TriggerType', 'Tile/') mismatchedLVL1Group.defineHistogram('module,ROS;TileMismatchedL1TriggerType', path = 'DMUErrors', - title = run + ': Tile mismatched L1 Trigger Type;Module;Partition', + title = 'Run ' + run + ': Tile mismatched L1 Trigger Type;Module;Partition', type = 'TH2F', xlabels = moduleLabels, ylabels = partitionLabels, xbins = Tile.MAX_DRAWER, xmin = -0.5, xmax = Tile.MAX_DRAWER - 0.5, ybins = Tile.MAX_ROS - 1, ymin = 1.0, ymax = Tile.MAX_ROS) - # 6) Configure histogram with no all Tile digits in the case of Trigger Type = 0x82 noAllDigitsGroup = helper.addGroup(tileDQFragMonAlg, 'TileNoAllDigits', 'Tile/') noAllDigitsGroup.defineHistogram('module,ROS;TileNoalldigits', path = 'DMUErrors', type = 'TH2F', - title = run + ': No All Tile digits in event with Trigger Type = 0x82;Module;Partition', + title = 'Run ' + run + ': No All Tile digits in event with Trigger Type = 0x82;Module;Partition', xlabels = moduleLabels, ylabels = partitionLabels, - xbins = Tile.MAX_DRAWER, xmin = 0.0, xmax = Tile.MAX_DRAWER, + xbins = Tile.MAX_DRAWER, xmin = -0.5, xmax = Tile.MAX_DRAWER - 0.5, ybins = Tile.MAX_ROS - 1, ymin = 1.0, ymax = Tile.MAX_ROS) - + # ) Configure histogram with global CRC errors vs module and partition + globalCRCGroup = helper.addGroup(tileDQFragMonAlg, 'TileBadGlobalCRC', 'Tile/') + globalCRCGroup.defineHistogram('module,ROS;TileBadGlobalCRC', path = 'DMUErrors', type = 'TH2F', + title = 'Run ' + run + ': Global CRC errors;Module;Partition', + xlabels = moduleLabels, ylabels = partitionLabels, + xbins = Tile.MAX_DRAWER, xmin = -0.5, xmax = Tile.MAX_DRAWER - 0.5, + ybins = Tile.MAX_ROS - 1, ymin = 1.0, ymax = Tile.MAX_ROS) # 7) Configure histograms with Tile DMU errors maxDMUs = 16 diff --git a/TileCalorimeter/TileMonitoring/src/TileDQFragMonitorAlgorithm.cxx b/TileCalorimeter/TileMonitoring/src/TileDQFragMonitorAlgorithm.cxx index 05b964b9fdf..2b6506b4e94 100644 --- a/TileCalorimeter/TileMonitoring/src/TileDQFragMonitorAlgorithm.cxx +++ b/TileCalorimeter/TileMonitoring/src/TileDQFragMonitorAlgorithm.cxx @@ -300,7 +300,8 @@ StatusCode TileDQFragMonitorAlgorithm::fillHistograms( const EventContext& ctx ) } } - + std::vector<int> rosWithGloblaCRC; + std::vector<int> drawerWithGlobalCRC; auto fractionOfBadDMUs = Monitored::Scalar<float>("fractionOfBadDMUs", 0.0); for (unsigned int ros = 1; ros < Tile::MAX_ROS; ++ros) { @@ -436,9 +437,18 @@ StatusCode TileDQFragMonitorAlgorithm::fillHistograms( const EventContext& ctx ) fill(m_tools[m_errorsGroups[ros - 1][drawer]], drawerDMUs, errorsInDMUs); fill(m_tools[m_errorsVsLBGroups[ros - 1][drawer]], lumiBlock, fractionOfBadDMUs); + if (dqStatus->checkGlobalCRCErr(ros, drawer, 0) != 0) { + rosWithGloblaCRC.push_back(ros); + drawerWithGlobalCRC.push_back(drawer); + } } } + if (!rosWithGloblaCRC.empty()) { + auto monModule = Monitored::Collection("module", drawerWithGlobalCRC); + auto monROS = Monitored::Collection("ROS", rosWithGloblaCRC); + fill("TileBadGlobalCRC", monModule, monROS); + } fill("TileDQFragMonExecuteTime", timer); -- GitLab