Page History
...
- Instrument independent - detector can be moved between instruments and hatches.
- Experiment independent - detector can be moved between experiments.
- Portability - calibration data for particular detector should be portable as a self consistent file or (part of) calibration directory.
- Combination of FS & DB files (hdf5 for uniformity).
- API + GUI for central management; management .Management can ONLY be done through the API/GUI in order to prevent adding/removing unknown files without history.
- Time stamp (sec) is THE ONLY value for validity range check.
- The <detname> is equivalent to <dettype>-<detid> and is THE ONLY choice for the file name . This name is mapped in the calibration store.
- Aliases to the custom names in the files with aliases.
...
- calibration file names can be used to simplify access.
Architecture
To accommodate requirements calibration store suppose to be implemented as a combination of FS & DB files (hdf5 for uniformity).
Calibration directory and files
...
Code Block |
---|
DCStore methods
===============
cs.set_tscfile(ts) # set (int) time stamp of the file creation
cs.set_dettype(dettype) # set (str) detector type
cs.set_detid(detid) # set (str) detector id
cs.set_detname(detname) # set (str) detector name of self object
cs.set_predecessor(pred) # set (str) detname of predecessor or None
cs.set_successor(succ) # set (str) detname of successor or None
cs.add_ctype(ctype) # add (str) calibration type to the DCStore object
cs.del_ctype(ctype) # delete ctype (str) from the DCStore object
cs.save(path) # save current calibration in the file specified by path, if path is Null - update current file.
DCType methods
==============
cto.add_range(tsr) # add (str) of time ranges for ctype
cto.del_range(tsr) # delete range from the DCType object
DCRange methods
===============
tsro.set_begin(tsbegin) # set (int) time stamp beginning validity range
tsro.set_end(tsend) # set (int) time stamp ending validity range
tsro.add_version(vers) # set (DCVersion ~ h5py.Group) versions of calibrations
tsro.set_versdef(vers) # set (DCVersion ~ h5py.Group) versions of calibrations
tsro.del_version(vers) # delete version
DCVersion methods
=================
verso.set_tsprod(tsprod) # set (int) time stamp of the version production
verso.add_calib(nda) # set (np.array) calibration array |
...
Overview
Content Tools