Skip to content

Commit 01cee15

Browse files
committed
quick fix to reduce number of histos
1 parent 9852e93 commit 01cee15

2 files changed

Lines changed: 6 additions & 5 deletions

File tree

Modules/CTP/include/CTP/RawDataQcTask.h

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,11 @@ class CTPRawDataReaderTask final : public TaskInterface
6161
std::unique_ptr<TH1D> mHistoBCMinBias1 = nullptr; // histogram of BC positions to check LHC filling scheme
6262
std::unique_ptr<TH1D> mHistoBCMinBias2 = nullptr; // histogram of BC positions to check LHC filling scheme
6363
std::unique_ptr<TH1D> mHistoDecodeError = nullptr; // histogram of erros from decoder
64-
std::array<TH1D*, o2::ctp::CTP_NINPUTS> mHisInputs = {}; ///< Array of input histograms, all BCs
65-
std::array<TH1D*, o2::ctp::CTP_NINPUTS> mHisInputsYesLHC = {}; ///< Array of input histograms, LHC BCs
66-
std::array<TH1D*, o2::ctp::CTP_NINPUTS> mHisInputsNotLHC = {}; ///< Array of input histograms, not LHC BCs
67-
std::array<std::size_t, o2::ctp::CTP_NINPUTS> shiftBC = {}; ///< Array of shifts for the BCs for each input
64+
static constexpr int mUsedInputsMax = 18;
65+
std::array<TH1D*, mUsedInputsMax> mHisInputs = {}; ///< Array of input histograms, all BCs
66+
std::array<TH1D*, mUsedInputsMax> mHisInputsYesLHC = {}; ///< Array of input histograms, LHC BCs
67+
std::array<TH1D*, mUsedInputsMax> mHisInputsNotLHC = {}; ///< Array of input histograms, not LHC BCs
68+
std::array<std::size_t, mUsedInputsMax> shiftBC = {}; ///< Array of shifts for the BCs for each input
6869
int mRunNumber;
6970
int indexMB1 = -1;
7071
int indexMB2 = -1;

Modules/CTP/src/RawDataQcTask.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ void CTPRawDataReaderTask::monitorData(o2::framework::ProcessingContext& ctx)
342342
for (auto const digit : outputDigits) {
343343
uint16_t bcid = digit.intRecord.bc;
344344
if (digit.CTPInputMask.count()) {
345-
for (int i = 0; i < o2::ctp::CTP_NINPUTS; i++) {
345+
for (int i = 0; i < mUsedInputsMax; i++) {
346346
if (digit.CTPInputMask[i]) {
347347
mHistoInputs->getNum()->Fill(i);
348348
mHistoInputRatios->getNum()->Fill(i);

0 commit comments

Comments
 (0)