Skip to content

Make FE masking possible without further information needed in the DB

Kira Abeling requested to merge kiabelin/athena:FixFEMasking into 21.9

Masking is used to tell athena in detector simulation that certain (pixel) modules or parts of it are not working. Those masks are stored in the COOL database.

The mask itself consists of three entries: the module hash-ID, the module status and the front-end status. While the module status is either 0 (working) or 1 (dead), the front-end status is encoded to include all front-ends of a module in a single number. For this the binary representation (e.g. 1111 for four front-ends masked or 0101 for two of four front-ends masked) is translated into an integer (e.g. 15 or 5). Furthermore, the old code required the same information again but in detached and inverted binary representation. Such that the database entry for the examples from above would look like this:

hashID   MStatus   FEStatus
XXXXXX      0      15 1 1 1 1
XXXXXX      0       5 1 0 1 0 

Unless there is the usage for a front-end status that is neither 0 (working) nor 1 (dead) this is redundant information that needed to be stored in the DB which also increases the DB size not negligibly.

The proposed "fix" is to simply set the the front-end status to 1 if the binary representation of the integer front-end status suggests that the front-end should be masked.

Locally, all Tier0 tests have been passed. It is under discussion, if this change should be propagated to master.

FYI @nstyles , @nreadiof , @ncalace , @tstreble , @tidreyer

Edited by Kira Abeling

Merge request reports