None
Test: nexusfiles-scipp|tbl|tbl_read_choppers|
workflow =
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00001521.hdf')
check_chopper =
def test_tbl_read_choppers(
workflow: sciline.Pipeline, coda_nexus_file_path: Path, check_chopper: Callable
) -> None:
workflow[Filename[SampleRun]] = coda_nexus_file_path
choppers = workflow.compute(RawChoppers[SampleRun])
assert len(choppers) == 2
for name, chopper in choppers.items():
> check_chopper(chopper, name=name)
tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:182:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
chopper = DataGroup(sizes={'time': None, 'dim_0': 2}, keys=[
type: Chopper type single,
position: Variable({}),
tran... top_dead_center: DataArray({'time': 4962}),
transformations: DataGroup(1, {}),
nexus_component_name: bwc_1,
])
name = 'bwc_1'
def _check_chopper(chopper: sc.DataGroup, name: str = "UNKNOWN") -> None:
assert "position" in chopper, f"Chopper '{name}' missing 'position'"
assert "rotation_speed" in chopper, f"Chopper '{name}' missing 'rotation_speed'"
assert "rotation_speed_setpoint" in chopper, (
f"Chopper '{name}' missing 'rotation_speed_setpoint'"
)
assert "slit_edges" in chopper, f"Chopper '{name}' missing 'slit_edges'"
assert "delay" in chopper, f"Chopper '{name}' missing 'delay'"
> assert "beam_position" in chopper, f"Chopper '{name}' missing 'beam_position'"
E AssertionError: Chopper 'bwc_1' missing 'beam_position'
E assert 'beam_position' in DataGroup(sizes={'time': None, 'dim_0': 2}, keys=[\n type: Chopper type single,\n position: Variable({}),\n transform: Variable({}),\n delay: DataArray({}),\n depends_on: TransformationChain(parent='/entry/instrument/bwc_1', value='/entry/instrument/bwc_1/transformations/translation', transformations=DataGroup(sizes={}, keys=[\n /entry/instrument/bwc_1/transformations/translation: Transform({}),\n])),\n radius: Variable({}),\n rotation_speed: DataArray({'time': 355}),\n rotation_speed_setpoint: DataArray({'time': 355}),\n slit_edges: Variable({'dim_0': 2}),\n slit_height: Variable({}),\n slits: 1,\n top_dead_center: DataArray({'time': 4962}),\n transformations: DataGroup(1, {}),\n nexus_component_name: bwc_1,\n])
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dmsc_nightly/testing/nexusfiles/validation_fixtures.py:56: AssertionError