Exception on CommonHeaderPreset during commisioning at BM05
Replace _setup_detectors_in_chain
by a preset.
It could look like
class PatchDefaultChain:
"""Patch the BLISS default for a specific `blissobj` using configuration of other chains.
The initial state of the default chain will be restored in the end.
Arguments:
blissobj: The bliss object which will be changed in the default chain
chains: A priority list of chains to use to feed the default chain.
The first list which contain the `blissobj` will be used, others
will be ingored.
"""
class TomoChain(PatchDefaultChain):
def __init__(self, blissobj, tomoconfig):
acc = blissobj.accumulation
super(
blissobj=blissobj,
chains=[
tomoconfig.chain_slow if not acc else None,
tomoconfig.chain_slow_acc if acc else None,
tomoconfig.chain_default if not acc else None,
tomoconfig.chain_default_acc if acc else None,
]
)