Skip to main content

Describe zarr stores from the command line.

Project description

zarrdump

PyPI version Python versions Tests License

Describe zarr stores from the command line. A path to any filesystem implemented by fsspec is valid. This package is inspired by ncdump.

Installation

$ pip install zarrdump

Usage

If a zarr store can be opened by xarray, the xarray representation will be displayed:

$ zarrdump gs://bucket/dataset.zarr
<xarray.Dataset> Size: 3MB
Dimensions:  (time: 32, lat: 73, lon: 144)
Coordinates:
  * time     (time) int64 256B 0 1 2 3 4 5 6 7 8 ... 23 24 25 26 27 28 29 30 31
  * lat      (lat) float64 584B -90.0 -87.5 -85.0 -82.5 ... 82.5 85.0 87.5 90.0
  * lon      (lon) float64 1kB 0.0 2.5 5.0 7.5 10.0 ... 350.0 352.5 355.0 357.5
Data variables:
    ps       (time, lat, lon) float32 1MB dask.array<chunksize=(16, 37, 144), meta=np.ndarray>
    ts       (time, lat, lon) float32 1MB dask.array<chunksize=(16, 37, 144), meta=np.ndarray>

Use -v to show information for a particular variable/array:

$ zarrdump -v ts gs://bucket/dataset.zarr
<xarray.DataArray 'ts' (time: 32, lat: 73, lon: 144)> Size: 1MB
dask.array<open_dataset-ts, shape=(32, 73, 144), dtype=float32, chunksize=(16, 37, 144), chunktype=numpy.ndarray>
Coordinates:
  * time     (time) int64 256B 0 1 2 3 4 5 6 7 8 ... 23 24 25 26 27 28 29 30 31
  * lat      (lat) float64 584B -90.0 -87.5 -85.0 -82.5 ... 82.5 85.0 87.5 90.0
  * lon      (lon) float64 1kB 0.0 2.5 5.0 7.5 10.0 ... 350.0 352.5 355.0 357.5
Attributes:
    longname:  surface temperature
    units:     K

CLI Reference

$ zarrdump --help
Usage: zarrdump [OPTIONS] URL

Options:
  -v, --variable TEXT     Dump variable's info
  -m, --max-rows INTEGER  Maximum number of rows to display
  -i, --info              Use ncdump style
  --storage-option TEXT   Key/value pair separated by '=', to be passed to the
                          storage_options argument of fsspec. It can be used
                          multiple times to pass multiple arguments. For
                          example: --storage-option profile=contabo --storage-
                          option endpoint=https://eu2.contabostorage.com
  --obstore               Use obstore backend instead of fsspec
  --help                  Show this message and exit.

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

zarrdump-0.7.1.tar.gz (7.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

zarrdump-0.7.1-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file zarrdump-0.7.1.tar.gz.

File metadata

  • Download URL: zarrdump-0.7.1.tar.gz
  • Upload date:
  • Size: 7.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.3

File hashes

Hashes for zarrdump-0.7.1.tar.gz
Algorithm Hash digest
SHA256 4900bbced6267e598e7af8050897b6b20559481ad8d9e991857872474d99251b
MD5 6da87cd98414acc84d78794765eb88be
BLAKE2b-256 a9cdfe321f485199c4c8e3d7220387d1a76af7dbdc93cbf7911d4dd7b9d197e7

See more details on using hashes here.

File details

Details for the file zarrdump-0.7.1-py3-none-any.whl.

File metadata

  • Download URL: zarrdump-0.7.1-py3-none-any.whl
  • Upload date:
  • Size: 5.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.3

File hashes

Hashes for zarrdump-0.7.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f43d74638157a95028dc958c97aa37cb3298a6d3f2311d05c651dc31fcd24c34
MD5 09fa71bc75628d613cd26b37b9c0cb97
BLAKE2b-256 027d8159137decb1866130480adcba0375c458c433d39ef1c3e695c361175486

See more details on using hashes here.

Supported by

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