Closed psobolewskiPhD closed 1 year ago
Lint CI fail is unrelated, hopefully fixed by https://github.com/AllenCellModeling/napari-aicsimageio/pull/70
Seems fine to me! Thanks! Also @psobolewskiPhD do you mind if I give you write access to this repo?
I unfortunately haven't had time to work on imaging / cell science stuff in a long time. Happy to still review but I don't see myself as a large code author for the foreseeable future...
Reason being: if you have write access you can publish releases after something merges.
Um, I don't mind I guess, if you think it's helpful! I'll definitely need to bone up on releases and all that—I've never done that.
Description
If a single scene image is opened, the return is
data.data
which is just the array from the xarray.DataArray If a multi scene file is opened (using the scene selector widget) the return from theopen_scene
is an image layer withdata
, the actual xarray.DataArray.Napari actually handles this just fine, but some downstream plugins do not, expecting numpy arrays (e.g. napari-matplotlib). This is sort of something they should be better at handling, perhaps using
np.asarray
, but at the same time I feel like these two should work the same? I think this plugin should/could be the default beyond builtins, so probably standardizing on the array and not xarray.DataArray is best, so probablydata.data
is preferred as a default behavior. As the person partially responsible for the scene selector, I think this was an oversight on my part...So in this PR I just make that small change and update the test accordingly. At the same time, I can understand just returning the xarray.DataArray. But then for consistency, the single scene should just return
data
.Pull request recommendations:
Thanks for contributing!