@tlambert03 - following up on discussion in napari/napari#1023 (comment) I used cookiecutter-napari-plugin to make this plugin.
It has a folder called readers
which can contain files such as imageio_reader.py
, npy_reader.py
, and eventually could contain mat_reader.py
, pims_reader.py
, meshio_reader.py
, shapely_reader.py
, geojson_reader.py
, czi_reader.py
, dv_reader.py
, nd2_reader.py
, bioformats_reader.py
etc. all of which are very minimal wrappers / converters from underlying libraries into the format napari expects.
I think the advantage of this library is the curation and testing that we could do to ensure that files are able to be read (i'm imagining we in parallel start curating a dataset of files that could be installed and tested by our CI). Another advantage is that for napari users it becomes very simple to just install one thing and have things work, rather than having to chase down and install many things.
Note here that we're able to unify across readers for different data types, shapes, images, meshes etc. A downside is that this package could have so many many dependencies that things breaking / install problems might be common. We'd have to think about what our attitude towards submissions from others would be, we could be very liberal or conservative, especially if we though about other domains of science where file types are very different (physics, astronomy, geospatial etc.)
Alternatively we try and get napari hook impls added to the various underlying libraries directly, or we have lots of napari-io-*
libraries that do the translation. Or we try and pick a smaller number of libraries to drive standardization too (i.e. get the czi reader into imageio). That still won't help with the mesh and shape reading though.
If we do do this should it live at napari/napari-io
which in some senses gives it an "official branding" or should it live somewhere else?
My current opinion is to go for it at napari/napari-io
, set up rigorous testing / CI and try and be as comprehensive as possible, across domains, file types, and napari layer types.
Curious what your vision for all this is @tlambert03? Also curious what @jni and @royerloic thinks.