virtualizarr.manifests.ManifestArray#

class virtualizarr.manifests.ManifestArray(metadata: ArrayV3Metadata | dict, chunkmanifest: dict | ChunkManifest)#

Virtualized array representation of the chunk data in a single Zarr Array.

Supports concatenation / stacking, but only if the two arrays to be concatenated have the same codecs.

Cannot be directly altered.

Implements subset of the array API standard such that it can be wrapped by xarray. Doesn’t store the zarr array name, zattrs or ARRAY_DIMENSIONS, as instead those can be stored on a wrapping xarray object.

__init__(metadata: ArrayV3Metadata | dict, chunkmanifest: dict | ChunkManifest) None#

Create a ManifestArray directly from the metadata of a zarr array and the manifest of chunks.

Parameters:

Methods

__init__(metadata, chunkmanifest)

Create a ManifestArray directly from the metadata of a zarr array and the manifest of chunks.

astype(dtype, /, *[, copy])

Cannot change the dtype, but needed because xarray will call this even when it's a no-op.

rename_paths(new)

Rename paths to chunks in this array's manifest.

to_virtual_variable()

Create a "virtual" xarray.Variable containing the contents of one zarr array.

Attributes

chunks

Individual chunk size by number of elements.

dtype

manifest

metadata

nbytes_virtual

Size required to hold these references in memory in bytes.

ndim

shape

Array shape by number of elements along each dimension.

size