Draft: Provide helpers to dump load computed darks flat
Nabu and tomwer should looks for computed darks and flats in dedicated files "darks.hdf5" and "flats.hdf5" in order to add some flexibility. As the process is the same we can have common function like:
ScanBase.dump_darks(darks: dict) -> dict
ScanBase.dump_flats(flats: dict) -> dict
ScansBase.load_darks() -> dict
For dump:
- Input is a dict keys are frame indexes and value numpy array or DataUrl
- Output is a dict with indexes as key and data_path as value. The data path will be something like "entryXXXX/index" it should be simple enought. If entry exists already then it should be deleted.
When load keys are indexes and values are DataUrl
Then nabu / tomwer on load should look for it. For writing they can reuse it and link those dataset to the '*_pricesses.h5' files.
It should also be simple enough for some non expert to overwrite dark / flat by their own or using the 'dump_xxx' function.
Edited by payno