alsdb.storage.ALSZarrStore#
- class alsdb.storage.ALSZarrStore(path: str | Path, mode: str = 'a', storage_options: dict | None = None)[source]#
Zarr-backed store for ALS gridded products.
- Parameters:
path – Directory path for the Zarr store. Local path or an
s3://URI.mode –
"a"(default) opens existing store or creates a new empty one."r"opens read-only.storage_options – Keyword arguments forwarded to the fsspec/s3fs backend when path is an S3 URI. Typical keys:
key,secret,endpoint_url,client_kwargs. Ignored for local paths.
Methods
__init__(path[, mode, storage_options])create(path, bbox, crs_wkt, variables[, ...])Create a new Zarr store pre-allocated for bbox and variables.
ensure_group(variable, resolution, bbox, crs_wkt)Ensure the resolution group and variable array exist.
has_data(variable, resolution, year)Return
Trueif variable already has a time slice for year.to_dataset(resolution)Return an
xarray.Datasetfor resolution.variables(resolution)Variable names available at resolution.
write_tile(variable, resolution, year, data, ...)Write a processed tile into the store.
Attributes
resolutionsResolution values present in the store.