Skip to main content

No project description provided

Project description

ngff-zarr

PyPI - Version PyPI - Python Version Test


A lean and kind Open Microscopy Environment (OME) Next Generation File Format (NGFF) Zarr implementation.

Table of Contents

Installation

To install the command line interface (CLI):

pip install 'ngff-zarr[cli]'

Features

  • Minimal dependencies
  • Work with arbitrary Zarr store types
  • Lazy, parallel, and web ready -- no local filesystem required
  • Process extremely large datasets
  • Multiple downscaling methods
  • Supports Python>=3.7
  • Implements version 0.4 of the OME-Zarr NGFF specification

Usage

Convert an image file

Convert any scientific image file format supported by either itk, tifffile, or imageio.

Example:

ngff-zarr -i ./MR-head.nrrd -o ./MR-head.zarr

ngff-zarr convert

Convert an image volume slice series

Note the quotes:

ngff-zarr -i "series/*.tif" -o ome-ngff.zarr

Print information about generated multiscales

To print information about the input, omit the output argument.

ngff-zarr -i ./MR-head.nrrd

ngff-zarr information

Specify output chunks

ngff-zarr -c 64 -i ./MR-head.nrrd

ngff-zarr output chunks

Specify metadata

ngff-zarr --dims "z" "y" "x" --scale x 1.4 y 1.4 z 2.5 --translation x 6.24 y 360.0 z 332.5 --name LIDC2 -i "series/*.tif"

ngff-zarr metadata

Limit memory consumption

Limit memory consumption by passing a rough memory limit in human-readable units, e.g. 8GB with the --memory-target option.

ngff-zarr --memory-target 50M -i ./LIDCFull.vtk -o ./LIDCFull.zarr

ngff-zarr memory-target

More options

ngff-zarr --help

See also

License

ngff-zarr is distributed under the terms of the MIT license.

Development

Contributions are welcome and appreciated.

To run the unit tests:

pip install -e ".[test,dask-image,itk,cli]"
pytest

Updating test data

  1. Generate new test data tarball
cd test/data
tar cvf ../data.tar baseline input
gzip -9 ../data.tar
  1. Upload the data to web3.storage

  2. Upload the test_data_ipfs_cid (from web3.storage web UI) and test_data_sha256 (sh256sum ../data.tar.gz) variables in test/_data.py.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ngff_zarr-0.4.2.tar.gz (30.2 kB view details)

Uploaded Source

Built Distribution

ngff_zarr-0.4.2-py3-none-any.whl (35.3 kB view details)

Uploaded Python 3

File details

Details for the file ngff_zarr-0.4.2.tar.gz.

File metadata

  • Download URL: ngff_zarr-0.4.2.tar.gz
  • Upload date:
  • Size: 30.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0

File hashes

Hashes for ngff_zarr-0.4.2.tar.gz
Algorithm Hash digest
SHA256 ff728d677eab8e8ade6599b284f11db3beb94c755a47bda4f7bf4bb06edc28fd
MD5 0927001a484f74345499c2ea2b13f5a9
BLAKE2b-256 582b9baf8cc503319e05a373353959883ece3b6ccfc9edb3f61b500e1179897b

See more details on using hashes here.

Provenance

File details

Details for the file ngff_zarr-0.4.2-py3-none-any.whl.

File metadata

  • Download URL: ngff_zarr-0.4.2-py3-none-any.whl
  • Upload date:
  • Size: 35.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0

File hashes

Hashes for ngff_zarr-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 fae01a4f2fd3b49bf1366676316b19bdb3143f04bc3d66b185ae3d96c7a9e195
MD5 0f1f327a761ac0da2dcaca58b1ec1aba
BLAKE2b-256 2095819e213f963f00109d88df176885b7f7b45789436bce786611f6f1d7fbf6

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page