DMSC Integration Testing

Last updated: September 25, 2026 08:02:48

Test: nexusfiles-scipp|beer|beer_read_choppers_to_disk_choppers|fc1a_chopper

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f85cb787c20>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00022387.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f86239abec0>
check_disk_chopper = <function _check_disk_chopper at 0x7f85cbf31760>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:138: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:30: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7fa1fad1b260>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00022247.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7fa253053ec0>
check_disk_chopper = <function _check_disk_chopper at 0x7fa1fb475760>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:138: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:30: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7ff1eb660cb0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00022117.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7ff1edbf1580>
check_disk_chopper = <function _check_disk_chopper at 0x7ff1ec349800>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f5261717410>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021977.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f52b45f6a20>
check_disk_chopper = <function _check_disk_chopper at 0x7f5261f0d260>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f729d9951c0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021833.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f72f0702a20>
check_disk_chopper = <function _check_disk_chopper at 0x7f729e1513a0>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7fee00edd160>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021703.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7fee53506a20>
check_disk_chopper = <function _check_disk_chopper at 0x7fee014913a0>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f2452fb4230>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021563.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f24a73eaa20>
check_disk_chopper = <function _check_disk_chopper at 0x7f245393d260>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7fa5979c48c0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021413.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7fa5ea5f2a20>
check_disk_chopper = <function _check_disk_chopper at 0x7fa598481260>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7fd196142a80>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021273.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7fd1e8de6a20>
check_disk_chopper = <function _check_disk_chopper at 0x7fd1967253a0>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f83a5083920>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021123.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f83f95eaa20>
check_disk_chopper = <function _check_disk_chopper at 0x7f83a5b91260>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f9f5247d9a0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020983.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f9f7d3f2a20>
check_disk_chopper = <function _check_disk_chopper at 0x7f9f52c113a0>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f6037ebd8b0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020703.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f60629e6200>
check_disk_chopper = <function _check_disk_chopper at 0x7f6038967600>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f65a966ecc0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020563.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f65d3b06200>
check_disk_chopper = <function _check_disk_chopper at 0x7f65aa457600>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f144e97b530>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020417.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f147d8fe200>
check_disk_chopper = <function _check_disk_chopper at 0x7f144e6874c0>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:352: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:686: DimensionError

View job log here


scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:676: DimensionError
Full output
chopper_name = 'fc1a_chopper'
workflow = <sciline.pipeline.Pipeline object at 0x7f7a2de8ba10>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020267.hdf')
to_disk_choppers = <function _to_disk_choppers at 0x7f7a59b06200>
check_disk_chopper = <function _check_disk_chopper at 0x7f7a2e8254e0>

    @pytest.mark.parametrize(
        "chopper_name",
        ["fc1a_chopper", "fc2a_chopper", "mca_chopper", "psc1_chopper", "psc2_chopper"],
    )
    def test_beer_read_choppers_to_disk_choppers(
        chopper_name: str,
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        to_disk_choppers: Callable,
        check_disk_chopper: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        choppers = workflow.compute(RawChoppers[SampleRun])
    
>       disk_choppers = to_disk_choppers({chopper_name: choppers[chopper_name]})
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:149: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
tests/nexusfiles-scipp/conftest.py:89: in _to_disk_choppers
    key: DiskChopper.from_nexus(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:343: in from_nexus
    frequency = _get_0d_variable(chopper, 'rotation_speed_setpoint')
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dg = {'beam_position': <scipp.Variable> ()    float64            [deg]  0, 'type': <DiskChopperType.single: 'Chopper type s...3              [m]  (0, 0, 8.283), 'transform': <scipp.Variable> ()  translation3              [m]  (0, 0, 8.283), ...}
name = 'rotation_speed_setpoint'

    def _get_0d_variable(
        dg: Mapping[str, sc.Variable | sc.DataArray], name: str
    ) -> sc.Variable:
        if (val := dg.get(name)) is None:
            raise ValueError(f"Chopper field '{name}' is missing")
    
        msg = (
            "Chopper field '{name}' must be a scalar variable, {got}. "
            "See the chopper user-guide for more information: "
            "https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html"
        )
    
        if isinstance(val, sc.DataArray):
            val = val.data
        if not isinstance(val, sc.Variable):
            raise TypeError(msg.format(name=name, got=f'got a {type(val)}'))
        val = val.squeeze()
        if val.ndim != 0:
>           raise sc.DimensionError(
                msg.format(name=name, got=f'got a {val.ndim}d variable')
            )
E           scipp._scipp.core.DimensionError: Chopper field 'rotation_speed_setpoint' must be a scalar variable, got a 1d variable. See the chopper user-guide for more information: https://scipp.github.io/scippneutron/user-guide/chopper/processing-nexus-choppers.html

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippneutron/chopper/disk_chopper.py:676: DimensionError