General description
[Databases]

General descriptions of the EMCAL databases and their usage.

Here's a table of EMCAL calibration databases we currently have, corresponding to calibration data "flavours". The table columns are :

By clicking on the class name, you'll be able to see which other class/module uses that calibration flavour.

Flavour nameDescriptionClass nameObject granularityPg table nameASCII location
Gains(relative) Gain valuesemcGainFEM1 per FEMcalibemcgainsDIR/Gains
HLRatiosHigh to Low gains valuesemcHLRatioFEM1 per FEMcalibemchlratiosDIR/HLRatio
PedestalsPedestal values, Run1 version (3 ped. per amu cell)emcPedestalFEM1 per FEMcalibemcpedestalsDIR/PEDESTAL
Pedestals5Pedestal values, Run2 and up version (5 ped per amu cell)emcPedestalFEM1 per FEMcalibemcpedestals5DIR/PEDESTAL
QAsQuality & Assurance valuesemcQAFEM1 per FEMcalibemcqasDIR/QA
LCTofsLeast-Count ToF valuesemcLCTofFEM1 per FEMcalibemclctofsDIR/ToF
WalkTofsWalk ToF valuesemcWalkTofFEM1 per FEMcalibemcwalktofsDIR/ToF
TofT0BsToF-T0 drift valuesemcTofT0FEM1 per FEMcalibemctoft0bsDIR/ToF
IniCalAbsolute energy calibrationemcCalibrationData1 per sectorcalibemcgenericinicalDIR/IniCal
RejectListList of towers known to be bad (offline determined)emcRejectList1 for whole EMCALcalibemcrejectlistDIR/RejectList
Tof SectorOffsetsMean ToF offset per sectoremcCalibrationData1 per sectorcalibemctofsectoroffsetsDIR/ToF/[runnumber]

Please note that all the *FEM classes derive from the same base class, emcCalFEM.

The table below lists the calibrations that are either not part of the DataManager realm or that are no longer used (or both).

Pg table name(probable)(past) usage
calibemctoft0sOld calibration software (now uses calibemctoft0bs)/ToF
calibemcbbct0???
calibemcdeltat0_sector
calibemcdeltat0_tower
calibemcescale_tower
calibemcescalerecal
calibemcgainsrecalEmpty database
calibemclaser
calibemcrejectlistrecal
calibemct0_sectorWas used to correct for tof-drift per sector during some runs (e.g. Run3)
calibemct0_towerWas used to correct for tof-drift per tower during some runs (e.g. Run3)
calibemctacpedsOld calibration software
calibemctofdt
calibemctofgain
calibemctoflcdt
calibemctoflcrun
calibemctofmom
calibemctofrun
calibemcvd_t0sector

Note:
In the Objectivity era, the db names had dots in there, e.g. calib.emc.gains, so in the code you'll still find them referenced that way sometimes. It's transparent for you, as the underlying software understands both conventions.
In the following, databases are referred to by the flavour name (e.g. Gains).

Different ways of accessing the EMCAL databases.

The various methods for accessing EMCAL databases are depicted in the figure below. Depending on what you would like to do, the preferred method might differ.

If you just need a quick browse (of either the raw content of the databases or just the validity ranges of the calibrations) or to upload things into the DB from ASCII files, please use the emcDB program.

If you need to get access to plain objects like emcGainFEM for instance, then the API defined by the emcCalibrationDataHelper is your best take.

Then, if you really want or need to, you can use the emcDataManager interface. This might be the case if you'd like to write some piece of code that computes calibration parameters and must then be able to write them into a database (typical of an OnlCal piece of code, for instance).

Last, if you are really forced to do it (but this should be the exception), you might want to bypass all those APIs and use pdbcal directly (or worse, find your way directly using ODBC...). But then you're on your own...

EMCAL Calibrations.png

EMCAL databases access routes