Skip to main content
rustytree — Rust-backed xarray DataTree backend

CI PyPI version Python versions License

rustytree registers as xr.open_datatree(engine="rustytree") and walks Zarr v3 hierarchies — both icechunk-backed and vanilla — concurrently in async across one FFI crossing. The goal is a drop-in faster replacement for xr.open_datatree(engine="zarr"), especially on icechunk repos served from object storage where xarray's current per-group sequential decoding is the dominant cost.

Status

Alpha. xr.open_datatree(..., engine="rustytree") works end-to-end against both icechunk repositories (pass session.store) and vanilla Zarr v3 stores (path or s3:// URL). Lazy chunk reads via RustyBackendArray, CF decoding (incl. metadata-only datetime dtype inference), the recursive multi-node walk, glob group= filtering, and non-recursive single-Dataset opens are all in. See CHANGELOG.md for the per-PR breakdown.

Compatibility

Surface Supported Not supported
Zarr format v3 only v2 — passing zarr_format=2 or consolidated=True raises NotImplementedError; use stock engine="zarr" for v2 stores
icechunk icechunk>=2.0 (the current major) older icechunk releases
Python 3.12, 3.13 older versions
Platforms manylinux x86_64, manylinux aarch64, macOS arm64 (wheels); other platforms via sdist Windows / macOS Intel / linux musl wheels (build from source via sdist)

Install

Install from PyPI (the import name stays rustytree; the distribution name on PyPI is rustytree-xarray because rustytree collides with an unrelated dormant package):

pip install rustytree-xarray

Or install from source per Quick start below.

Example

Open the public anonymous NEXRAD KLOT icechunk repo on S3:

import icechunk
import xarray as xr

storage = icechunk.s3_storage(
    bucket="nexrad-arco", prefix="KLOT",
    region="us-east-1", anonymous=True,
)
session = icechunk.Repository.open(storage).readonly_session("main")

# Open the full DataTree (107 nodes — every VCP × sweep combination).
dt = xr.open_datatree(session.store, engine="rustytree")

# Or grab one specific sweep as a flat Dataset (skips walking siblings):
ds = xr.open_dataset(session.store, engine="rustytree",
                     group="/VCP-12/sweep_0")

# Or apply a glob pattern. "Give me sweep_0 from every VCP" is the
# canonical radar workflow — returns a tree filtered to those matches,
# with the VCP container groups auto-included as ancestors.
sweeps_0 = xr.open_datatree(session.store, engine="rustytree",
                            group_filter="/*/sweep_0")

engine="rustytree" is a drop-in replacement for engine="zarr" — same xr.open_datatree / xr.open_dataset entry points, same storage_options / decode_* kwargs. The full demo (with side-by-side timings against engine="zarr") is in notebooks/klot_demo.ipynb.

Quick start

rustytree is a Rust extension built via maturin; uv sync handles the venv, Python deps, and the Rust build (via maturin's PEP 517 hook) in one command.

# Clone + enter the repo
git clone https://github.com/aladinor/rustytree.git
cd rustytree

# Install everything: venv, deps, and the compiled Rust extension.
uv sync --extra dev

# Confirm the install
.venv/bin/pytest tests/

# Launch Jupyter and open the demo notebook
.venv/bin/jupyter lab notebooks/klot_demo.ipynb

The notebooks and tests don't require AWS credentials — KLOT is read anonymously via icechunk's anonymous S3 path. Network speed determines cold-cache timings (expect ~1–3 s for engine="rustytree" on KLOT from a home connection; ~50 s for engine="zarr" on the same).

Documentation

License

Apache License 2.0 (Apache-2.0).

Acknowledgements

Built on zarrs + zarrs_icechunk + icechunk. Sibling project radish proved the PyO3 + xarray-backend pattern. The bottlenecks this project sets out to collapse are tracked in xarray PRs #10742, #11304, and #11302.

Metadata

Release files for rustytree-xarray 0.5.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for rustytree-xarray 0.5.2
File Size Uploaded Provenance Actions
rustytree_xarray-0.5.2.tar.gz 1.2 MB With provenance Details for rustytree_xarray-0.5.2.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for rustytree-xarray 0.5.2
File Actions
rustytree_xarray-0.5.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ x86-64 Details for rustytree_xarray-0.5.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
rustytree_xarray-0.5.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ ARM64 Details for rustytree_xarray-0.5.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
rustytree_xarray-0.5.2-cp313-cp313-macosx_11_0_arm64.whl CPython 3.13 CPython 3.13 macOS 11.0+ ARM64 Details for rustytree_xarray-0.5.2-cp313-cp313-macosx_11_0_arm64.whl
rustytree_xarray-0.5.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64 Details for rustytree_xarray-0.5.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
rustytree_xarray-0.5.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ ARM64 Details for rustytree_xarray-0.5.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
rustytree_xarray-0.5.2-cp312-cp312-macosx_11_0_arm64.whl CPython 3.12 CPython 3.12 macOS 11.0+ ARM64 Details for rustytree_xarray-0.5.2-cp312-cp312-macosx_11_0_arm64.whl

Total release size: 67.2 MB

Release files / rustytree_xarray-0.5.2.tar.gz

Download URL rustytree_xarray-0.5.2.tar.gz
Size 1.2 MB
Tags Source
SHA-256 checksum
How to use checksums
adb245d4dae3eabbae2cf8acaaae7ae426e4c847878c9f6dd047edd7617be622
BLAKE2b-256 checksum
How to use checksums
62f05083a25e70f421cfe2227b855449b84ad66ba14275c64b93893ebf3d4679
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / rustytree_xarray-0.5.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL rustytree_xarray-0.5.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 11.8 MB
Tags CPython 3.13 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
1bb881fb3f048c0f2f86e431e68cde6c4e187d061d4cc71ff6228079fb25af98
BLAKE2b-256 checksum
How to use checksums
a5100b006301daf4069bfd45cd46799db6f50b70de152bd6662f773404314597
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / rustytree_xarray-0.5.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL rustytree_xarray-0.5.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 11.1 MB
Tags CPython 3.13 Linux glibc 2.17+ ARM64
SHA-256 checksum
How to use checksums
ecdc365561772efc90a60eef35d3d10ee05e1ba1c77b28b30201a30d9e6db954
BLAKE2b-256 checksum
How to use checksums
157c29d3dded81c039d8ba495ba673552f9d30c420cd5a8583c8cf430842c795
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / rustytree_xarray-0.5.2-cp313-cp313-macosx_11_0_arm64.whl

Download URL rustytree_xarray-0.5.2-cp313-cp313-macosx_11_0_arm64.whl
Size 10.1 MB
Tags CPython 3.13 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
dd80c97676352f69ac406355640f8e1129d54eadf401854d68cdbb55eb9fae5e
BLAKE2b-256 checksum
How to use checksums
7cc72dbc1c6bde1dc91ce707dae1c3b62796e1d9b802e4d4f190fc22caa3fafc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / rustytree_xarray-0.5.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL rustytree_xarray-0.5.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 11.8 MB
Tags CPython 3.12 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
f2501c39f4a6650e4bd04942a4e94cfd34cdfd2150098a3b4be501f8ffd010a7
BLAKE2b-256 checksum
How to use checksums
40cab8ef350c9ca01439affdbea08c88edb9e493686ca1e0841bea9ddff81b4d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / rustytree_xarray-0.5.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL rustytree_xarray-0.5.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 11.1 MB
Tags CPython 3.12 Linux glibc 2.17+ ARM64
SHA-256 checksum
How to use checksums
d5a601dd29b13e73d83f0adb0cae382c897032241d80c24fbf3facb13aba2bfc
BLAKE2b-256 checksum
How to use checksums
ac342346c832f9beb45fa7fea78c6bd5e537e1f18f66398209978f45d6abb80d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / rustytree_xarray-0.5.2-cp312-cp312-macosx_11_0_arm64.whl

Download URL rustytree_xarray-0.5.2-cp312-cp312-macosx_11_0_arm64.whl
Size 10.1 MB
Tags CPython 3.12 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
70dc1105d7aab8be841cc1fb2181b2743613648c5f4201ec52fbc4ad5288e2cb
BLAKE2b-256 checksum
How to use checksums
0f39f6215ede1677445240f6176e08eaa544c94b975c2d90c24f986d020e718e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Security for rustytree-xarray 0.5.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 7 files in this release have been uploaded with provenance metadata.

Select from 7 files

Attestation for rustytree_xarray-0.5.2.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page