DMSC Integration Testing

Last updated: September 25, 2026 08:04:50

Test: nexusfiles-scipp|tbl|tbl_read_detector_everything|orca_detector

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7feaa0386900>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7feaa0384d40>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7feaa9f99e20>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022386.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7feaabf3d9e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7feaa0386900>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f9eb01d0710>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f9eb929d040>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f9eb9357b60>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022306.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f9ebab719e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f9eb01d0710>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f6a381f87d0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f6a3871a540>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f6a3830a690>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022246.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f6a39c259e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f6a381f87d0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f2f7411e540>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f2f741c4a40>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f2f779890d0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022206.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f2f792518a0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f2f7411e540>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f8e0c2e4e90>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f8e0c241550>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f8e16cd6750>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022206.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f8e178859e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f8e0c2e4e90>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7faf0826ab40>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7faf08269190>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7faf0a61e2d0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022196.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7faf0c79d8a0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7faf0826ab40>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fc09a7cc560>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fc09a7cda90>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fc09a705be0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022116.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7fc09c201a80>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fc09a7cc560>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fcb72526390>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fcb725278f0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fcb72977c20>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022066.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7fcb749159e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fcb72526390>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fb6bbeaf920>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fb6bbb968a0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fb6bbf16930>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022066.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7fb6bd759b20>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fb6bbeaf920>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f4caddec920>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f4caddee5d0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f4cada00ad0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022066.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f4caf335b20>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f4caddec920>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f7136400680>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f7136402cc0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f7136fb7d70>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022046.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f7137c45a80>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f7136400680>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fef5bec6090>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fef5bec7620>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fef5c0fe690>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022036.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7fef5d639580>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fef5bec6090>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fb3c04f78c0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fb3c04f7bc0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fb3c02154c0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022036.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7fb3c1fd16c0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fb3c04f78c0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f059b787350>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f059b784fe0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f059b585910>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022026.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f059d151580>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f059b787350>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7ff740c03a10>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7ff740dfa570>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7ff740c8e6f0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022026.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7ff742309580>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7ff740c03a10>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f03ef4eb170>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f03ef748fe0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f03ef8f7530>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00022026.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f03f11e56c0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f03ef4eb170>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f7f7423adb0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f7f7423b110>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f7f7435d400>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021976.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f7f75d25620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f7f7423adb0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f6346b1cd40>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f6346c34ef0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f6346b27440>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021912.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f6348d1d620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:153: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f6346b1cd40>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f4e3ee562a0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f4e3eedee10>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f4e3edeb6e0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021912.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f4e40761620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f4e3ee562a0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f6d53ee7c80>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f6d53ee7650>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f6d53cfdd60>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021902.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f6d55781620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f6d53ee7c80>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f575ee31b50>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f575ee32810>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f575ee2f470>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021842.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f57604b5620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f575ee31b50>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f951e8d1580>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f951e8d3f80>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f951e6cce00>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021702.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f951fe1d620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f951e8d1580>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f01d0b4a750>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f01d0b65b20>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f01d0af5c10>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021562.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f01d2a714e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f01d0b4a750>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f3fadecf440>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f3fae1186e0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f3fae1052e0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021512.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f3faf8b1620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f3fadecf440>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f9ce5d23e60>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f9ce5d23f20>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f9ce6058ce0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021412.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f9ce7979620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f9ce5d23e60>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f254046b1d0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f25405926c0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f253c106090>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021272.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f25425d14e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f254046b1d0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f74bddd9d60>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f74bddda270>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f74bdb298b0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00021132.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f74bf42d4e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f74bddd9d60>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f21b08f2660>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f21b08f0440>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f21ac34f320>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020992.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f21b21d14e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f21b08f2660>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f4a52518a70>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f4a524ddb50>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f4a525219a0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020912.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f4a53f61620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f4a52518a70>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f94fc31fcb0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f94ff31f140>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f94ff2b5910>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020892.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f9500a014e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f94fc31fcb0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f2c246fd640>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f2c244f3800>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f2c2433ccb0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020892.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f2c2618d4e0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f2c246fd640>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7fc00f787cb0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7fc00f784d40>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7fc00f76e510>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020892.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7fc011d7f880>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7fc00f787cb0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f5495fe7e90>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f54959c0470>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f5495ff0050>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020702.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f549765b880>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f5495fe7e90>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f435da4d0a0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f435da4ed80>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f435d60d1c0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020562.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f435f757880>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f435da4d0a0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f65ac6df650>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f65ac6dd6d0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f65b776b860>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020562.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f65b998b880>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f65ac6df650>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f24937ba0f0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f24937bb2f0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f24937cb0e0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020416.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f2494def880>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f24937ba0f0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f38770f0ad0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f38770ef620>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f38779d7ef0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020276.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f3877a25760>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f38770f0ad0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f47ae81f770>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f47ae8ea840>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f47ae776180>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020203.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f47b20f1620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f47ae81f770>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f471e21c860>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f471e6b1b20>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f471f7c4d40>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020203.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f4721925620>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f471e21c860>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f28b9381cd0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f28b937cb90>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f28b91088f0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020203.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f28b992d760>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f28b9381cd0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7f8e0c2a69f0>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7f8e0c2ab9b0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7f8e15f65ee0>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020203.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7f8e1603d6c0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7f8e0c2a69f0>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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

View job log here


UserWarning: Failed to load /entry/instrument/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
    nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:409: UserWarning
Full output
self = <scippnexus.base.Group object at 0x7ff0b73c4f80>, 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-tbl/lib/python3.12/site-packages/scippnexus/base.py:390: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdetector.py:98: in assemble
    out = self._assemble_as_physical_component(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:417: in _assemble_as_physical_component
    assembled_nxdata = self._assemble_as_data(data_items)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:374: in _assemble_as_data
    da = self._add_coords(da, coords)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <ess.reduce.nexus.workflow._StrippedDetector object at 0x7ff0b792c9b0>
da = <scipp.DataArray>
Dimensions: Sizes[x_pixel_offset:2048, y_pixel_offset:2048, ]
Data:
                              int32        <no unit>  (x_pixel_offset, y_pixel_offset)  [0, 0, ..., 0, 0]


coords = DataGroup(sizes={'x_pixel_offset': 4096, 'y_pixel_offset': 4096}, keys=[
    x_pixel_offset: Variable({'x_pixel_offset': 4096}),
    y_pixel_offset: Variable({'y_pixel_offset': 4096}),
])

    def _add_coords(self, da: sc.DataArray, coords: sc.DataGroup) -> sc.DataArray:
        """Add coords to a data array.
    
        Sets alignment in the same way as slicing scipp.DataArray would.
        """
        for name, coord in coords.items():
            if not isinstance(coord, sc.Variable):
                da.coords[name] = sc.scalar(coord)
            else:
                if coord.shape == (1,) and not set(coord.dims).issubset(da.dims):
                    da.coords[name] = coord[0]
                else:
>                   da.coords[name] = coord
                    ^^^^^^^^^^^^^^^
E                   scipp._scipp.core.DimensionError: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)

.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/nxdata.py:456: DimensionError

During handling of the above exception, another exception occurred:

workflow = <sciline.pipeline.Pipeline object at 0x7ff0b7322420>
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_tbl_999999_00020203.hdf')
check_everything_histogram = <function _check_everything_histogram at 0x7ff0b7e316c0>

    def test_tbl_read_detector_everything__orca_detector(
        workflow: sciline.Pipeline,
        coda_nexus_file_path: Path,
        check_everything_histogram: Callable,
    ) -> None:
        workflow[Filename[SampleRun]] = coda_nexus_file_path
        workflow[NeXusDetectorName] = "orca_detector"
    
        # Read the event data
>       result = workflow.compute(RawDetector[SampleRun])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/tbl/tbl_load_nexus_test.py:161: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
    return self.get(tp, **kwargs).compute(reporter=reporter)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/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-tbl/lib/python3.12/site-packages/dask/threaded.py:115: in get
    results = get_async(
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:547: in get_async
    raise_exception(exc, tb)
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:351: in reraise
    raise exc
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/local.py:256: in execute_task
    result = task(data)
             ^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/_task_spec.py:768: in __call__
    return self.func(*new_argspec)
           ^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/dask/utils.py:81: in apply
    return func(*args)
           ^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/sciline/_provider.py:145: in __call__
    return self._func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/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-tbl/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
    loaded = cast(sc.DataGroup, group[selection])
                                ^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-tbl/lib/python3.12/site-packages/scippnexus/base.py:392: in __getitem__
    self._warn_fallback(e)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <scippnexus.base.Group object at 0x7ff0b73c4f80>
e = DimensionError("Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048)")

    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/orca_detector as _StrippedDetector: Cannot add coord 'x_pixel_offset' of dims (x_pixel_offset: 4096) to DataArray with dims (x_pixel_offset: 2048, y_pixel_offset: 2048) 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.imaging.types.SampleRun],
E           nx_class: ess.reduce.nexus.types.NeXusClass[scippnexus.nxdetector.NXdetector],
E       ) -> ess.reduce.nexus.types.NeXusComponent[scippnexus.nxdetector.NXdetector, ess.imaging.types.SampleRun]

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