🍾 Xarray is now 10 years old! 🎉

xarray.backends.ZarrStore

xarray.backends.ZarrStore#

class xarray.backends.ZarrStore(zarr_group, mode=None, consolidate_on_close=False, append_dim=None, write_region=None, safe_chunks=True, write_empty=None, close_store_on_close=False)[source]#

Store for reading and writing data via zarr

__init__(zarr_group, mode=None, consolidate_on_close=False, append_dim=None, write_region=None, safe_chunks=True, write_empty=None, close_store_on_close=False)[source]#

Methods

__init__(zarr_group[, mode, ...])

close()

encode(variables, attributes)

Encode the variables and attributes in this store

encode_attribute(a)

encode one attribute

encode_variable(variable)

encode one variable

get_attrs()

get_dimensions()

get_encoding()

get_variables()

load()

This loads the variables and attributes simultaneously.

open_group(store[, mode, synchronizer, ...])

open_store_variable(name, zarr_array)

set_attribute(k, v)

set_attributes(attributes)

This provides a centralized method to set the dataset attributes on the data store.

set_dimension(dim, length)

set_dimensions(variables[, unlimited_dims])

This provides a centralized method to set the dimensions on the data store.

set_variable(k, v)

set_variables(variables, check_encoding_set, ...)

This provides a centralized method to set the variables on the data store.

store(variables, attributes[, ...])

Top level method for putting data on this store, this method:

store_dataset(dataset)

in stores, variables are all variables AND coordinates in xarray.Dataset variables are variables NOT coordinates, so here we pass the whole dataset in instead of doing dataset.variables

sync()

Attributes

zarr_group

ds