DMSC Integration Testing

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

Test: nexusfiles-scipp|beer|beer_read_detector_geometry|beer_detector_n2

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f85cb6844a0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f85cb6840e0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f85cbdffcb0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00022387.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f85cbf3d4e0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:46: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f85cb6844a0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fa1fac90500>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fa1fac90140>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fa1fbd71c40>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00022247.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fa1fb4694e0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:46: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fa1fac90500>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7ff1eb599f70>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7ff1eb599b50>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7ff1eb7c7e30>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00022117.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7ff1ec355440>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7ff1eb599f70>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f5261581370>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f5261580fe0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f5261f94650>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021977.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f5261f58ea0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f5261581370>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f729d995d30>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f729d995970>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f729e1a6360>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021833.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f729e160fe0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f729d995d30>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fee00aadb80>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fee00aad790>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fee00c6b650>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021703.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fee01480fe0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fee00aadb80>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f2452ba5910>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f2452ba5520>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f2452d7b410>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021563.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f2453930ea0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f2452ba5910>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fa5975d1520>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fa5975d10d0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fa597767590>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021413.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fa5984c4ea0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fa5975d1520>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fd195d8d220>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fd195d8ce30>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fd196c093d0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021273.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fd196734fe0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fd195d8d220>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f83a50817c0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f83a50813d0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f83a5b61af0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00021123.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f83a5b84ea0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f83a50817c0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f9f52359bb0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f9f523597c0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f9f52467560>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020983.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f9f52c04fe0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f9f52359bb0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f60379d1d00>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f60379d1970>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f6037dc1d00>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020703.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f6038964f40>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f60379d1d00>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f65a927e300>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f65a927dfd0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f65a95e5040>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020563.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f65aa454f40>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f65a927e300>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f144d83a480>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f144d83a240>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f144da0fbc0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020417.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f144e684e00>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f144d83a480>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f7a2e00fda0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f7a2e00f9e0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f7a2ed285c0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020267.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f7a31838cc0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f7a2e00fda0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f89ddff7170>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f89ddff6de0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f89de227ec0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020205.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f89e14fcae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f89ddff7170>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f5b3c425130>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f5b3c424da0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f5b3c801df0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020205.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f5b3fac8ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f5b3c425130>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f4f554f2ff0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f4f554f2c30>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f4f558ffdd0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00020117.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f4f58accae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f4f554f2ff0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f01db1cb3b0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f01db1cafc0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f01db5afef0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00019974.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f01de704ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f01db1cb3b0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f9a59a49370>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f9a59a48fe0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f9a5a9f6f30>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00019807.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f9a5d05cae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f9a59a49370>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f83f4aa4a40>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f83f4aa45f0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f83f4d6b320>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00019445.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f83f80e4ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f83f4aa4a40>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fd634ffbef0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fd634ffbb30>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fd628707b30>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00019445.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fd638450ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fd634ffbef0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fd5926dfe00>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fd5926dfa40>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fd5929f7cb0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00019375.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fd595b10ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fd5926dfe00>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f7fe216be30>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f7fe216ba40>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f7fdc199430>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00019229.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f7fe5400ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f7fe216be30>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f4aa491bc80>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f4aa491b830>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f4aa5ad99d0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00019098.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f4aa7e88ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f4aa491bc80>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f75f9c9a570>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f75f9cac4a0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f75fa053b00>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00018958.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f75fd28cae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f75f9c9a570>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f013db43fb0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f013db43bc0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f013de85d00>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00018818.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f01411d4ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f013db43fb0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f846de10230>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f846de6f260>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f846becd730>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00018678.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f8471460ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f846de10230>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f1601faa810>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f1601faa3c0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f1603efbad0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00018334.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f16070d4ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f1601faa810>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f69183c6e10>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f691818ede0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f691a060d10>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00018334.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f691d310ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f69183c6e10>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f4b937a3350>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f4b937a2fc0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f4b954cf800>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00018334.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f4b98548ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f4b937a3350>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f4715562f60>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f4715562bd0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f47176ac4a0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00018254.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f471a798ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f4715562f60>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f2b851379b0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f2b85137620>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f2b867d79b0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00018124.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f2b898c8ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f2b851379b0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
In provider ess.reduce.nexus.workflow.load_nexus_component(
    location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fde4da86720>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fde4d895820>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fde504b8b00>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00017984.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fde52d9cae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:140: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fde4da86720>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.
E       In provider ess.reduce.nexus.workflow.load_nexus_component(
E           location: ess.reduce.nexus.types.NeXusComponentLocationSpec[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.reduce.nexus.types.SampleRun]

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fc8cc066d50>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fc8cbe3f1a0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fc8cdcb7710>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00017747.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fc8d0da0ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fc8cc066d50>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f53db57ecf0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f53db57e900>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f53dd28ab70>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00017659.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f53e04c8ae0>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f53db57ecf0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f77c87e3050>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f77c87e2c00>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f77ca31f110>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00017549.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f77faf01f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f77c87e3050>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f45e049c9e0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f45e049c620>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f45e1f22870>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00017399.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f4613615f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f45e049c9e0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f29c3376810>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f29c3376450>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f29c460fad0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00017259.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f29f5d45f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f29c3376810>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7ff7f1ccf4a0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7ff7f1ccf110>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7ff7f375da00>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00017119.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7ff824205f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7ff7f1ccf4a0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f2c00f24b60>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f2c00f247a0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f2c02158260>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00016979.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f2c33879f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f2c00f24b60>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f4a4c0452b0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f4a4c044f20>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f4a53993110>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00016849.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f4a84dd1f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f4a4c0452b0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f81c2878890>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f81c2878440>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f81c4452e70>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00016709.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f81f5ba5f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f81c2878890>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f0956e82cf0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f0956e82930>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f0958c0fd10>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00016559.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f098a315f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f0956e82cf0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fd4b7c5e4b0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fd4b7c5e0c0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fd4b8e15a90>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00016429.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fd4e9a01f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fd4b7c5e4b0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fe9a0ec6720>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fe9a0ec6360>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fe9a3057320>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00016279.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fe9d3b01f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fe9a0ec6720>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fe33af6aea0>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fe33b005ac0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fe33c1df0b0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00016139.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7fe36d895f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fe33af6aea0>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning

View job log here


UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f63eb7b6960>, sel = ()

    def __getitem__(self, sel):
        """
        Get a child group or child dataset, a selection of child groups, or load and
        return the current group.
    
        Three cases are supported:
    
        - String name: The child group or child dataset of that name is returned.
        - Class such as ``NXdata`` or ``NXlog``: A dict containing all direct children
          with a matching ``NX_class`` attribute are returned. Also accepts a tuple of
          classes. ``Field`` selects all child fields, i.e., all datasets but not
          groups.
        - Scipp-style index: Load the specified slice of the current group, returning
          a :class:`scipp.DataArray` or :class:`scipp.DataGroup`.
    
        Parameters
        ----------
        sel:
            Child name, class, or index.
    
        Returns
        -------
        :
            Field, group, dict of fields, or loaded data.
        """
        if isinstance(sel, str):
            # We cannot get the child directly from the HDF5 group, since we need to
            # create the parent group, to ensure that fields get the correct properties
            # such as sizes and dtype.
            if '/' in sel:
                sel_path = PurePosixPath(sel)
                if sel_path.is_absolute():
                    return self.file[sel_path.relative_to('/').as_posix()]
                # If the path is a single name, we can directly access the child
                elif len(sel_path.parts) == 1:
                    return self[sel_path.as_posix()]
                else:
                    grp = sel_path.parts[0]
                    return self[grp][sel_path.relative_to(grp).as_posix()]
            elif sel == '..':
                return self.parent
            child = self._children[sel]
            if isinstance(child, Field):
                self._populate_fields()
            return child
    
        def isclass(x):
            return inspect.isclass(x) and issubclass(x, Field | NXobject)
    
        if isclass(sel) or (
            isinstance(sel, list) and len(sel) and all(isclass(x) for x in sel)
        ):
            return self._get_children_by_nx_class(sel)
    
        dg = self._nexus.read_children(sel)
        if not dg:
            # Bail out early to avoid fallback warnings. Everything is optional in
            # NeXus so we cannot assume that the group is invalid (in contrast to
            # likely partially incomplete groups that will fail to assemble below).
            return dg
        try:
>           dg = self._nexus.assemble(dg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f63eb7b65a0>
dg = DataGroup(sizes={'dim_0': None, 'dim_1': 1000, 'dim_2': 1000}, keys=[
    detector_number: Variable({'dim_0': 12, 'dim...000}),
    z_pixel_offset: Variable({'dim_0': 12}),
    data: Variable({'dim_0': 12, 'dim_1': 1000, 'dim_2': 1000}),
])

    def _assemble_as_data(
        self, dg: sc.DataGroup
    ) -> sc.DataGroup | sc.DataArray | sc.Dataset:
        if not self._valid:
>           raise NexusStructureError("Could not determine signal field or dimensions.")
E           scippnexus.base.NexusStructureError: Could not determine signal field or dimensions.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/nxdata.py:362: NexusStructureError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f63ed692480>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_beer_999999_00015999.hdf')
detector_name = 'beer_detector_n2'
check_detector_positions_events = <function _check_detector_positions_events at 0x7f641edf9f80>

    @pytest.mark.parametrize("detector_name", DETECTOR_NAMES)
    def test_beer_read_detector_geometry(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        detector_name: str,
        check_detector_positions_events: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = detector_name
    
>       result = workflow.compute(EmptyDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/beer/beer_load_nexus_test.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
    return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
    return self._dask_get(dsk, list(map(_to_dask_key, keys)))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:242: in load_nexus_component
    nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f63eb7b6960>
e = NexusStructureError('Could not determine signal field or dimensions.')

    def _warn_fallback(self, e: Exception) -> None:
        msg = (
            f"Failed to load {self.name} as {type(self._nexus).__name__}: {e} "
            "Falling back to loading HDF5 group children as scipp.DataGroup."
        )
>       warnings.warn(msg, stacklevel=2)
E       UserWarning: Failed to load /entry/instrument/beer_detector_n2 as _StrippedDetector: Could not determine signal field or dimensions. Falling back to loading HDF5 group children as scipp.DataGroup.

.tox/nexusfiles-scipp-beer/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning