Created
May 26, 2017 15:30
-
-
Save chiahaoliu/d80738da97c0a1056d113fe41020a4dd to your computer and use it in GitHub Desktop.
rethink about xpdacq
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# whaht xpdacq has: | |
# dark frame: | |
# 1. dark frame before scan | |
# 2. update global dark frame information | |
# 3. inject associated dark frame information to each run | |
# tiff save (exporter): | |
# 1. read md from header to pull associated dark frame | |
# 2. dark subtraction | |
# 3. filename template | |
# device configuration : | |
# 1. centralized device configuration, e.g. pe1c -> area_det | |
# 2. passing device around | |
##pseudo code | |
from xpdacq.xpdacq import take_dark, _update_dark_dict_list, _validate_dark | |
from xpdan.tiff_exporter import TiffExportor | |
## take dark | |
def configure_RE(RE): | |
RE.preprocessors.append(take_dark) | |
RE.preprocessors.append(_update_dark_dict_list) | |
RE.preprocessors.append(_validate_dark) | |
## exporter | |
def hook_exporter(RE): | |
RE.subscribe('all', post_run(TiffExportor(tmp))) | |
## |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment