Napari plugin to store set of layers in a .h5 file. Label layer are stored in a sparse representation
Project description
napari-hdf5-labels-io
napari plugin to store napari projects in a .h5 file. Label layer are stored in a sparse representation (COO list).
This napari plugin was generated with Cookiecutter using with @napari's cookiecutter-napari-plugin template.
Description
This napari plugin provides a writer and reader to store existing layers in the current napari window, all the metadata is stored as well in a HDF5 file. All the stored preferences are included when a project file is opened.
Label layers are stored in a coordinate list sparse representation with the Sparse module to keep the project file size minimum when possible (aiming to implement this in other layers in the future).
HDF5 file architecture
The project file is a HDF5 generated with the h5py module. The file groups correspond to the different napari layer types and the layer metadata is stored as attributes of each layer.
In the case of the meta dictionary which is nested in the LayerData meta dictionary (napari IO), new keys are generated in the outer dictionary to use them as h5 dataset attributes. This nested dictionary architecture is reconstructed by the reader to ensure format compatibility.
Installation
You can install napari-hdf5-labels-io
via pip:
pip install napari-hdf5-labels-io
Contributing
Contributions are very welcome. Tests can be run with tox, please ensure the coverage at least stays the same before you submit a pull request.
License
Distributed under the terms of the GNU GPL v3.0 license, "napari-hdf5-labels-io" is free and open source software.
Issues
If you encounter any problems, please file an issue along with a detailed description.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for napari-hdf5-labels-io-0.2.dev23.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 97116386ea512ac3beeec8939a7806608b0a4ec85c54ead8c9b2ea54299075a0 |
|
MD5 | bc9ff5a65bd4d8782ca6d5907510cc1d |
|
BLAKE2b-256 | 1b419234a6749d2fcee44040bb69ef10d856d1d50af92caec4e72b2ab39cf168 |
Hashes for napari_hdf5_labels_io-0.2.dev23-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | edbd64c419a529c448f4b0a072166603b4d0266f6bf1911a2bc74cf71766b8fa |
|
MD5 | 52a805e1ea3ec1bde67f8b79ac3b8142 |
|
BLAKE2b-256 | ff4324dfeaee21babe339ca75a14c90e6d8a1d1d8b0f1439c3d07be335f8ba73 |