@@ -79,8 +79,20 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
7979 };
8080 mExcludeGainErrorsFromOverview = get_bool (getConfigValueLower (" excludeGainErrorFromSummary" ));
8181
82+ // Set DDL indices
83+ // SRU: 0-39
84+ // STU: 44-45
85+ static constexpr int NDDL_ALL = 46 , NDDL_FEE = 40 ;
86+ // FEC IDs: 0-39
87+ static constexpr int NFEC = 40 ;
88+
89+ /* ********
90+ * Most reconstruction errors are specific to ALTRO decoding (i.e. ALTRO decoding errors, geometry, raw fit, ...). Consequently their range can be restricted to the
91+ * DDL range of FEE DDLs. Some reconstruction errors like page decoding errors and link errors are so general that they can also affect the STU data (in case i.e. the
92+ * entire page is corrupted). Consequently the range has to be enlarged to cover also the STU DDLs.
93+ */
8294 constexpr float binshift = -0.5 ; // shift bin centers of error codes in order to avoid edge effects
83- mErrorTypeAll = new TH2F (" RawDataErrors" , " Raw data errors" , 40 , 0 , 40 , o2::emcal::ErrorTypeFEE::getNumberOfErrorTypes (), binshift, o2::emcal::ErrorTypeFEE::getNumberOfErrorTypes () + binshift);
95+ mErrorTypeAll = new TH2F (" RawDataErrors" , " Raw data errors" , NDDL_ALL , 0 , NDDL_ALL , o2::emcal::ErrorTypeFEE::getNumberOfErrorTypes (), binshift, o2::emcal::ErrorTypeFEE::getNumberOfErrorTypes () + binshift);
8496 mErrorTypeAll ->GetXaxis ()->SetTitle (" Link" );
8597 mErrorTypeAll ->GetYaxis ()->SetTitle (" Error type" );
8698 for (int ierror = 0 ; ierror < o2::emcal::ErrorTypeFEE::getNumberOfErrorTypes (); ierror++) {
@@ -89,7 +101,7 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
89101 mErrorTypeAll ->SetStats (0 );
90102 getObjectsManager ()->startPublishing (mErrorTypeAll );
91103
92- mErrorTypeAltro = new TH2F (" MajorAltroErrors" , " Major ALTRO decoding errors" , 40 , 0 , 40 , o2::emcal::AltroDecoderError::getNumberOfErrorTypes (), binshift, o2::emcal::AltroDecoderError::getNumberOfErrorTypes () + binshift);
104+ mErrorTypeAltro = new TH2F (" MajorAltroErrors" , " Major ALTRO decoding errors" , NDDL_FEE , 0 , NDDL_FEE , o2::emcal::AltroDecoderError::getNumberOfErrorTypes (), binshift, o2::emcal::AltroDecoderError::getNumberOfErrorTypes () + binshift);
93105 mErrorTypeAltro ->GetXaxis ()->SetTitle (" Link" );
94106 mErrorTypeAltro ->GetYaxis ()->SetTitle (" Error Type" );
95107 for (auto ierror = 0 ; ierror < o2::emcal::AltroDecoderError::getNumberOfErrorTypes (); ierror++) {
@@ -98,7 +110,7 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
98110 mErrorTypeAltro ->SetStats (0 );
99111 getObjectsManager ()->startPublishing (mErrorTypeAltro );
100112
101- mErrorTypePage = new TH2F (" PageErrors" , " DMA page decoding errors" , 40 , 0 , 40 , o2::emcal::RawDecodingError::getNumberOfErrorTypes (), binshift, o2::emcal::RawDecodingError::getNumberOfErrorTypes () + binshift);
113+ mErrorTypePage = new TH2F (" PageErrors" , " DMA page decoding errors" , NDDL_ALL , 0 , NDDL_ALL , o2::emcal::RawDecodingError::getNumberOfErrorTypes (), binshift, o2::emcal::RawDecodingError::getNumberOfErrorTypes () + binshift);
102114 mErrorTypePage ->GetXaxis ()->SetTitle (" Link" );
103115 mErrorTypePage ->GetYaxis ()->SetTitle (" Page Error Type" );
104116 for (int ierror = 0 ; ierror < o2::emcal::RawDecodingError::getNumberOfErrorTypes (); ierror++) {
@@ -107,7 +119,7 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
107119 mErrorTypePage ->SetStats (0 );
108120 getObjectsManager ()->startPublishing (mErrorTypePage );
109121
110- mErrorTypeMinAltro = new TH2F (" MinorAltroError" , " Minor ALTRO decoding error" , 40 , 0 , 40 , o2::emcal::MinorAltroDecodingError::getNumberOfErrorTypes (), binshift, o2::emcal::MinorAltroDecodingError::getNumberOfErrorTypes () + binshift);
122+ mErrorTypeMinAltro = new TH2F (" MinorAltroError" , " Minor ALTRO decoding error" , NDDL_FEE , 0 , NDDL_FEE , o2::emcal::MinorAltroDecodingError::getNumberOfErrorTypes (), binshift, o2::emcal::MinorAltroDecodingError::getNumberOfErrorTypes () + binshift);
111123 mErrorTypeMinAltro ->GetXaxis ()->SetTitle (" Link" );
112124 mErrorTypeMinAltro ->GetYaxis ()->SetTitle (" MinorAltro Error Type" );
113125 for (int ierror = 0 ; ierror < o2::emcal::MinorAltroDecodingError::getNumberOfErrorTypes (); ierror++) {
@@ -116,7 +128,7 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
116128 mErrorTypeMinAltro ->SetStats (0 );
117129 getObjectsManager ()->startPublishing (mErrorTypeMinAltro );
118130
119- mErrorTypeFit = new TH2F (" RawFitError" , " Error in raw fitting " , 40 , 0 , 40 , o2::emcal::CaloRawFitter::getNumberOfErrorTypes (), binshift, o2::emcal::CaloRawFitter::getNumberOfErrorTypes () + binshift);
131+ mErrorTypeFit = new TH2F (" RawFitError" , " Error in raw fitting " , NDDL_FEE , 0 , NDDL_FEE , o2::emcal::CaloRawFitter::getNumberOfErrorTypes (), binshift, o2::emcal::CaloRawFitter::getNumberOfErrorTypes () + binshift);
120132 mErrorTypeFit ->GetXaxis ()->SetTitle (" Link" );
121133 mErrorTypeFit ->GetYaxis ()->SetTitle (" Fit Error Type" );
122134 for (int ierror = 0 ; ierror < o2::emcal::CaloRawFitter::getNumberOfErrorTypes (); ierror++) {
@@ -125,7 +137,7 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
125137 mErrorTypeFit ->SetStats (0 );
126138 getObjectsManager ()->startPublishing (mErrorTypeFit );
127139
128- mErrorTypeGeometry = new TH2F (" GeometryError" , " Geometry error" , 40 , 0 , 40 , o2::emcal::reconstructionerrors::getNumberOfGeometryErrorCodes (), binshift, o2::emcal::reconstructionerrors::getNumberOfGeometryErrorCodes () + binshift);
140+ mErrorTypeGeometry = new TH2F (" GeometryError" , " Geometry error" , NDDL_FEE , 0 , NDDL_FEE , o2::emcal::reconstructionerrors::getNumberOfGeometryErrorCodes (), binshift, o2::emcal::reconstructionerrors::getNumberOfGeometryErrorCodes () + binshift);
129141 mErrorTypeGeometry ->GetXaxis ()->SetTitle (" Link" );
130142 mErrorTypeGeometry ->GetYaxis ()->SetTitle (" Geometry Error Type" );
131143 for (int ierror = 0 ; ierror < o2::emcal::reconstructionerrors::getNumberOfGeometryErrorCodes (); ierror++) {
@@ -134,7 +146,7 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
134146 mErrorTypeGeometry ->SetStats (0 );
135147 getObjectsManager ()->startPublishing (mErrorTypeGeometry );
136148
137- mErrorTypeGain = new TH2F (" GainTypeError" , " Gain type error" , 40 , 0 , 40 , o2::emcal::reconstructionerrors::getNumberOfGainErrorCodes (), binshift, o2::emcal::reconstructionerrors::getNumberOfGainErrorCodes () + binshift);
149+ mErrorTypeGain = new TH2F (" GainTypeError" , " Gain type error" , NDDL_FEE , 0 , NDDL_FEE , o2::emcal::reconstructionerrors::getNumberOfGainErrorCodes (), binshift, o2::emcal::reconstructionerrors::getNumberOfGainErrorCodes () + binshift);
138150 mErrorTypeGain ->GetXaxis ()->SetTitle (" Link" );
139151 mErrorTypeGain ->GetYaxis ()->SetTitle (" Gain Error Type" );
140152 for (int ierror = 0 ; ierror < o2::emcal::reconstructionerrors::getNumberOfGainErrorCodes (); ierror++) {
@@ -143,19 +155,19 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
143155 mErrorTypeGain ->SetStats (0 );
144156 getObjectsManager ()->startPublishing (mErrorTypeGain );
145157
146- mErrorGainLow = new TH2F (" NoHGPerDDL" , " High Gain bunch missing" , 40 , 0 , 40 , 40 , 0 , 40 );
158+ mErrorGainLow = new TH2F (" NoHGPerDDL" , " High Gain bunch missing" , NFEC , 0 , NFEC , NDDL_FEE , 0 , NDDL_FEE );
147159 mErrorGainLow ->GetYaxis ()->SetTitle (" fecID" );
148160 mErrorGainLow ->GetXaxis ()->SetTitle (" Link" );
149161 mErrorGainLow ->SetStats (0 );
150162 getObjectsManager ()->startPublishing (mErrorGainLow );
151163
152- mErrorGainHigh = new TH2F (" NoLGPerDDL" , " Low Gain bunch missing for saturated High Gain" , 40 , 0 , 40 , 40 , 0 , 40 );
164+ mErrorGainHigh = new TH2F (" NoLGPerDDL" , " Low Gain bunch missing for saturated High Gain" , NFEC , 0 , NFEC , NDDL_FEE , 0 , NDDL_FEE );
153165 mErrorGainHigh ->GetYaxis ()->SetTitle (" fecID" );
154166 mErrorGainHigh ->GetXaxis ()->SetTitle (" Link" );
155167 mErrorGainHigh ->SetStats (0 );
156168 getObjectsManager ()->startPublishing (mErrorGainHigh );
157169
158- mFecIdMinorAltroError = new TH2F (" FecIDMinorAltroError" , " FecID Minor Altro Error" , 40 , 0 , 40 , 40 , 0 , 40 );
170+ mFecIdMinorAltroError = new TH2F (" FecIDMinorAltroError" , " FecID Minor Altro Error" , NFEC , 0 , NFEC , NDDL_FEE , 0 , NDDL_FEE );
159171 mFecIdMinorAltroError ->GetYaxis ()->SetTitle (" fecID" );
160172 mFecIdMinorAltroError ->GetXaxis ()->SetTitle (" Link" );
161173 mFecIdMinorAltroError ->SetStats (0 );
@@ -173,7 +185,7 @@ void RawErrorTask::initialize(o2::framework::InitContext& /*ctx*/)
173185 mChannelGainHigh ->SetStats (0 );
174186 getObjectsManager ()->startPublishing (mChannelGainHigh );
175187
176- mErrorTypeUnknown = new TH1F (" UnknownErrorType" , " Unknown error types" , 40 , 0 ., 40 );
188+ mErrorTypeUnknown = new TH1F (" UnknownErrorType" , " Unknown error types" , NDDL_ALL , 0 ., NDDL_ALL );
177189 mErrorTypeUnknown ->GetXaxis ()->SetTitle (" Link" );
178190 mErrorTypeUnknown ->GetYaxis ()->SetTitle (" Number of errors" );
179191 getObjectsManager ()->startPublishing (mErrorTypeUnknown );
0 commit comments