// $Id$ /*! \page README_calib Calibration The Offline Condition DataBase is described extensively on ALICE Offline pages. Here you'll find mainly information relevant to the MUON objects in the OCDB, and to the AliMUONCDB class (formerly MUONCDB.C macro), which defines a set of functions to read/write MUON information to this CDB. Those functions are not meant to be used as black boxes. Please have a closer look before using (especially the ones writing to the CDB...) \section calib_s0 MUON objects in OCDB
OCDB pathSubsystemRun TypeFileIDDAQsourceUpdate frequencyAppox. Size
MUON/Calib/RecoParambothN/AN/AN/AFew per year ?5 KB
MUON/Calib/MappingDatabothN/AN/AN/AOnce for all once debugged1 MB
MUON/Calib/MappingRunDatabothN/AN/AN/ABetween zero and few per year100 KB
MUON/Calib/CapacitancesMCHN/AN/AN/AOnce for all once debugged7 MB
MUON/Calib/GainsMCHCALIBRATIONGAINSLDCOnce per calibration run10 MB
MUON/Calib/HVMCHPHYSICSN/AN/AOnce per physics runDepends on the number of trips, 10-20 KB normally
MUON/Calib/NeighboursMCHN/AN/AN/AAs MappingData10 MB
MUON/Calib/OccupancyMapMCHPHYSICSOCCUPANCYMONOnce per physics runDepends on the number of bad manus, normally 100-200 KB
MUON/Calib/PedestalsMCHPEDESTALPEDESTALSLDCOnce per pedestal run7 MB
MUON/Calib/RejectListMCHN/AN/AN/AFew per yearDepends on the number of bad elements
MUON/Calib/GlobalTriggerCrateConfigMTR?????
MUON/Calib/LocalTriggerBoardMasksMTR?????
MUON/Calib/RegionalTriggerConfigMTR?????
MUON/Calib/TriggerDCSMTR?????
MUON/Calib/TriggerEfficiencyMTR?????
MUON/Calib/TriggerLutMTR?????
In addition, the following ones were used in the past, but have been discontinued (but are still present in the OCDB, as object removal is not allowed).
OCDB path
MUON/Calib/DDLStore
MUON/CalibGlobalTriggerBoardMasks/
MUON/Calib/Mapping
MUON/Calib/RegionalTriggerBoardMasks
MUON/Calib/RegionalTriggerConfig?
\section calib_s1 Calibration data object classes We've designed generic data containers to store calibration information, tailored to the way we usually access MUON tracker data, that is, indexed by the pair (detElemId,manuId). This container is called AliMUONVStore. You can attach a TObject to every and each pair (detElemId,manuId). For the moment, that TObject is generally of AliMUONVCalibParam type, which handles a given number of channels (64 typically) as a group. There's also 1D versions of AliMUONVStore for data types which only requires indexing by 1 value (like trigger masks for instance). As the class names suggest (V...), those classes are only interfaces. Concrete ones are AliMUON2DMap (used instead of a vector as detElemId are not contiguous), AliMUON1DArray (for things where indices are contiguous) and AliMUON1DMap, and CalibParamNI (VCalibParam storing n integer per channel), CalibParamNF (VCalibParam storing n floats per channel), and CalibParamND (VCalibParam storing n doubles per channel). One exception are the HV values from DCS, which are stored "as they come" from the shuttle-dcs interface, as a TMap, where the key is the aliasname (TString), and the value a TObjArray of AliDCSValue. \section calib_s2 CDB location One very important notion is that of the DefaultStorage (which you might set with AliCDBManager::Instance()->SetDefaultStorage(path)), which tells the CDB library where the CDB is sitting (either locally on disk, or on the grid). For local tests, path will be most likely = "local://$ALICE_ROOT/OCDB" (i.e. there is, in svn a slim version of the calibration objects needed for running the MUON code), or "local://$ALICE_ROOT/OCDB/SHUTTLE/TestShuttle/TestCDB for Shuttle testing. When using alien, the path definition can be eg. "alien://folder=/alice/data/2009/OCDB" . \section calib_s3 Writing to CDB AliMUONCDB class is used to populate the CDB with fake calibration objects for testing purposes. Real calibration data will normally be handled by the Shuttle (see READMEshuttle). The various WriteXXX() static methods may be used to populate MUON tracker and trigger information. A full set of calibration data types can be created from scratch using, from the Root prompt (from within the $ALICE_ROOT/MUON directory to get the correct list of libraries loaded by the loadlibs.C macro)
root[0] AliMpCDB::LoadAll2(); 
root[1] Int_t startRun = 0;
root[2] Bool_t defaultValues = kTRUE;
root[3] AliMUONCDB::WriteTrigger(startRun);
root[4] AliMUONCDB::WriteTracker(defaultValues,startRun);
\section calib_s4 Reading the CDB The actual reading is encapsulated into AliMUONCalibrationData class. e.g. to read pedestals for run 67138, one would do :
AliCDBManager::Instance()->SetDefaultStorage(cdbPath);
AliMUONVStore* ped = AliMUONCalibrationData::CreatePedestals(67138);
If you want to plot calibration data (not terribly usefull as it's a really global view), use the Plot() function of AliMUONCDB (this require to load the segmentation), e.g.
AliCDBManager::Instance()->SetRun(0);
AliMUONCDB::LoadMapping(kTRUE);
AliMUONCDB::Plot(*ped,"pedestal");
which will create 2 histograms : pedestal_0 (mean) and pedestal_1 (sigma). A more usefull way to look at calibration data might be the \link README_mchview mchview \endlink program. \section calib_s5 A note on status and status map A special kind of object is the status map. It would deserve a full documentation (and that will need to be done some day), but for the moment, please have a look at the MUONStatusMap.C macro which can let you play with it. For more information, have a look at the AliMUONPadStatusMaker and AliMUONPadStatusMapMaker. $Id$ */