Checksum support for zarrs stored in various backends
Project description
zarr_checksum
Algorithms for calculating a zarr checksum against local or cloud storage
Install
pip install zarr-checksum
Usage
CLI
To calculate the checksum for a local zarr archive
zarrsum local <directory>
To calculate the checksum for a remote (S3) zarr archive
zarrsum remote s3://your_bucket/prefix_to_zarr
Python
To calculate the checksum for a local zarr archive
from zarr_checksum import compute_zarr_checksum
from zarr_checksum.generators import yield_files_local, yield_files_s3
# Local
checksum = compute_zarr_checksum(yield_files_local("local_path"))
# Remote
checksum = compute_zarr_checksum(
yield_files_s3(
bucket="your_bucket",
prefix="prefix_to_zarr",
# Credentials can also be passed via environment variables
credentials={
aws_access_key_id: "youraccesskey",
aws_secret_access_key: "yoursecretkey",
region_name: "us-east-1",
}
)
)
Access checksum information
>>> checksum.digest
'c228464f432c4376f0de6ddaea32650c-37481--38757151179'
>>> checksum.md5
'c228464f432c4376f0de6ddaea32650c'
>>> checksum.count
37481
>>> checksum.size
38757151179
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file zarr_checksum-0.4.7.tar.gz.
File metadata
- Download URL: zarr_checksum-0.4.7.tar.gz
- Upload date:
- Size: 12.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.2 CPython/3.13.2 Linux/6.8.0-1021-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
081f163d52533a286bc8249a241da5614b5dab0c06377b208980dc205e272da9
|
|
| MD5 |
7a8cc1bf8df0f014397e91fb0fb4a5cd
|
|
| BLAKE2b-256 |
b4afeb603e6d7f02d16a60b05335ed97a08de4c71f5b109c2a65f3a571d2c4be
|
File details
Details for the file zarr_checksum-0.4.7-py3-none-any.whl.
File metadata
- Download URL: zarr_checksum-0.4.7-py3-none-any.whl
- Upload date:
- Size: 15.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.2 CPython/3.13.2 Linux/6.8.0-1021-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
97cbffe2288338f9083f92a2312052f045fb2154a6f4ddbbcb1bde109b6fd22e
|
|
| MD5 |
06462f9f76f3edb862f8c9f0e4d346f9
|
|
| BLAKE2b-256 |
e36ba57376f2713b79e5f2eb8003ebc569aa3201a36779ee1472404f183e3c87
|