Read only Zarr storage class using a Tar file
Project description
sferriol-zarr
sferriol-zarr is a module with new zarr storage class TarStore (only read-only).
Installation
pip install git+https://gitlab.in2p3.fr/sferriol-ip2i/sferriol-zarr.git
Usage
import zarr
import sferriol.zarr
# original zarr storage
dir_store = zarr.DirectoryStore('data/example.zarr')
z = zarr.create(store=dir_store, overwrite=True, shape=1000000, dtype='i4')
# convert it to tar file ('data/example.zarr.tar')
tar_fpath = sferriol.zarr.create_tar('data/example.zarr')
# now use TarStore
tar_store = sferriol.zarr.TarStore('data/example.zarr.tar')
tz = zarr.open(store=tar_store, mode='r')
tar_store.close() # don't forget to call this when you're done
# or in a with statement
with sferriol.zarr.TarStore('data/example.zarr.tar') as tar_store:
tz = zarr.open(store=tar_store, mode='r')
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 Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
File details
Details for the file sferriol_zarr-0.2.2-py3-none-any.whl
.
File metadata
- Download URL: sferriol_zarr-0.2.2-py3-none-any.whl
- Upload date:
- Size: 3.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a7a2bcd0cc42af05b85d799a20e36d467f52a827729f3fa29d2863d6f9ae5056 |
|
MD5 | e4c51b883631c3e4aca67444fb138b4d |
|
BLAKE2b-256 | 3542842eeff3b2bca11f4c5b6993c83ed91e1c6c369f666af48dd030bd802ef1 |