Project
Loading...
Searching...
No Matches
ReconstructionErrors.h
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11#ifndef ALICEO2_EMCAL_RECONSTRUCTIONERRORS_H
12#define ALICEO2_EMCAL_RECONSTRUCTIONERRORS_H
13
14namespace o2
15{
16
17namespace emcal
18{
19
20namespace reconstructionerrors
21{
22
35
38constexpr int getNumberOfGeometryErrorCodes() { return 2; }
39
44{
45 switch (errortype) {
47 return 0;
49 return 1;
50 default:
51 return -1;
52 }
53}
54
63
71const char* getGeometryErrorName(GeometryError_t errortype);
72
81const char* getGeometryErrorName(unsigned int errorcode);
82
90const char* getGeometryErrorTitle(GeometryError_t errortype);
91
100const char* getGeometryErrorTitle(unsigned int errorcode);
101
108const char* getGeometryErrorDescription(GeometryError_t errortype);
109
117const char* getGeometryErrorDescription(unsigned int errorcode);
118
127enum class GainError_t {
128 LGNOHG,
129 HGNOLG,
131};
132
135constexpr int getNumberOfGainErrorCodes() { return 2; }
136
141{
142 switch (errortype) {
144 return 0;
146 return 1;
147 default:
148 return -1;
149 };
150}
151
159GainError_t getGainErrorFromErrorCode(unsigned int errorcode);
160
168const char* getGainErrorName(GainError_t errortype);
169
178const char* getGainErrorName(unsigned int errorcode);
179
187const char* getGainErrorTitle(GainError_t errortype);
188
197const char* getGainErrorTitle(unsigned int errorcode);
198
205const char* getGainErrorDescription(GainError_t errortype);
206
214const char* getGainErrorDescription(unsigned int errorcode);
215
231
234constexpr int getNumberOfTRUErrorCodes() { return 3; }
235
244
249{
250 switch (error) {
252 return 0;
254 return 1;
256 return 2;
258 return 3;
260 return -1;
261 }
262}
263
271const char* getTRUDecodingErrorName(TRUDecodingError_t errortype);
272
281const char* getTRUDecodingErrorName(unsigned int errorcode);
282
290const char* getTRUDecodingErrorTitle(TRUDecodingError_t errortype);
291
300const char* getTRUDecodingErrorTitle(unsigned int errorcode);
301
309
317const char* getTRUDecodingErrorErrorDescription(unsigned int errorcode);
318
319} // namespace reconstructionerrors
320
321} // namespace emcal
322
323} // namespace o2
324
325#endif // !ALICEO2_EMCAL_RECONSTRUCTIONERRORS_H
Errors appearing in geometry access obtaining the tower ID.
constexpr int getErrorCodeFromGainError(GainError_t errortype)
Convert gain error type into numberic representation.
const char * getGainErrorDescription(GainError_t errortype)
Get detailed description of a given gain error type.
@ LGNOHG
LG found below HG/LG transition, HG missing.
@ CELL_RANGE_EXCEED
Requested cell value exceeding allowed cell range.
@ CELL_INDEX_NEGATIVE
Requested cell value negative.
constexpr int getErrorCodeFromGeometryError(GeometryError_t errortype)
Convert geometry error type into numberic representation.
const char * getGeometryErrorName(GeometryError_t errortype)
Get name of a given geometry error type.
const char * getGeometryErrorDescription(GeometryError_t errortype)
Get detailed description of a given geometry error type.
constexpr int getErrorCodeFromTRUDecodingError(TRUDecodingError_t error)
Convert TRU decoding error type into numberic representation.
GainError_t getGainErrorFromErrorCode(unsigned int errorcode)
Convert error code to gain error type.
const char * getTRUDecodingErrorTitle(TRUDecodingError_t errortype)
Get title of a given TRU decoding error type.
const char * getTRUDecodingErrorErrorDescription(TRUDecodingError_t errortype)
Get detailed description of a given TRU decoding error type.
constexpr int getNumberOfGainErrorCodes()
Get the number of gain error codes.
const char * getGainErrorName(GainError_t errortype)
Get name of a given gain error type.
TRUDecodingError_t getTRUDecodingErrorFromErrorCode(unsigned int errorcode)
Convert error code to TRU decoding error type.
const char * getGainErrorTitle(GainError_t errortype)
Get title of a given gain error type.
constexpr int getNumberOfTRUErrorCodes()
Get the number of TRU error codes.
GeometryError_t getGeometryErrorFromErrorCode(unsigned int errorcode)
Convert error code to geometry error type.
constexpr int getNumberOfGeometryErrorCodes()
Get the number of geometry error codes.
const char * getTRUDecodingErrorName(TRUDecodingError_t errortype)
Get name of a given TRU decoding error type.
@ FASTOR_STARTTIME_INVALID
FastOr stattime is larger than 14.
const char * getGeometryErrorTitle(GeometryError_t errortype)
Get title of a given geometry error type.
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...