Blosc2 Classes

Fundamental Data Containers

Core user-facing containers for compressed, chunked, lazy, remote, batched, variable-length, and object data.

NDArray(**kwargs)

Compressed, chunked N-dimensional array with NumPy-like indexing.

C2Array(path, /[, urlbase, auth_token])

Remote compressed NDArray accessed from a Caterva2 server.

LazyArray()

Base class for lazy array expressions that compute data on demand.

BatchArray([items_per_block, serializer, ...])

A batched container for variable-length Python items.

ListArray([spec, item_spec, nullable, ...])

A row-oriented container for list-valued data.

ObjectArray([chunksize, _from_schunk])

A variable-length array backed by an blosc2.SChunk.

Proxies and External Data Sources

Classes and interfaces for exposing external array-like data to Blosc2, with or without chunk caching.

Proxy(src[, urlpath, mode])

Proxy (with cache support) for an object following the ProxySource interface.

ProxySource()

Base interface for sources of Proxy that are not NDim objects.

ProxyNDSource()

Base interface for NDim sources in Proxy.

SimpleProxy(src[, chunks, blocks])

Simple proxy for any data container to be used with the compute engine.

General Data Stores

Dictionary-like stores for embedding and organizing multiple Blosc2 objects.

EmbedStore([urlpath, mode, cparams, ...])

A dictionary-like container for storing NumPy/Blosc2 arrays (NDArray or SChunk) as nodes.

DictStore(localpath[, mode, tmpdir, ...])

Dictionary-like storage for compressed Blosc2 objects.

TreeStore(*args[, _from_parent_store])

A hierarchical tree-based storage container for Blosc2 data.

Tabular Data

Columnar table containers, column views, indexes, and CTable schema helpers.

CTable(row_type[, new_data, urlpath, mode, ...])

Columnar compressed table with typed columns and row-oriented access.

Column(table, col_name[, mask])

Column view for a CTable, with vectorized operations and reductions.

Index(array, token, *[, table, descriptor])

Handle for an index attached to an blosc2.NDArray.

NullPolicy(string_value, bytes_value, ...)

Default sentinels for inferred CTable scalar nulls.

Schema Specs and Helpers

int8(*[, ge, gt, le, lt, nullable, null_value])

8-bit signed integer column (−128 … 127).

int16(*[, ge, gt, le, lt, nullable, null_value])

16-bit signed integer column (−32 768 … 32 767).

int32(*[, ge, gt, le, lt, nullable, null_value])

32-bit signed integer column (−2 147 483 648 … 2 147 483 647).

int64(*[, ge, gt, le, lt, nullable, null_value])

64-bit signed integer column.

uint8(*[, ge, gt, le, lt, nullable, null_value])

8-bit unsigned integer column (0 … 255).

uint16(*[, ge, gt, le, lt, nullable, null_value])

16-bit unsigned integer column (0 … 65 535).

uint32(*[, ge, gt, le, lt, nullable, null_value])

32-bit unsigned integer column (0 … 4 294 967 295).

uint64(*[, ge, gt, le, lt, nullable, null_value])

64-bit unsigned integer column.

float32(*[, ge, gt, le, lt, nullable, ...])

32-bit floating-point column (single precision).

float64(*[, ge, gt, le, lt, nullable, ...])

64-bit floating-point column (double precision).

complex64()

64-bit complex number column (two 32-bit floats).

complex128()

128-bit complex number column (two 64-bit floats).

bool(*[, nullable, null_value])

Boolean column.

string(*[, min_length, max_length, pattern, ...])

Fixed-width Unicode string column.

bytes(*[, min_length, max_length, nullable, ...])

Fixed-width bytes column.

list(item_spec, *[, nullable, storage, ...])

Build a list-valued schema descriptor for CTable and ListArray.

struct(fields, *[, nullable])

Build a structured schema descriptor for dict-like CTable values.

object(*[, nullable, serializer, ...])

Build a schema-less Python object column descriptor for CTable.

vlstring(*[, nullable, serializer, ...])

Build a variable-length scalar string schema descriptor.

vlbytes(*[, nullable, serializer, ...])

Build a variable-length scalar bytes schema descriptor.

field(spec, *[, default, cparams, dparams, ...])

Attach a Blosc2 schema spec and per-column storage options to a dataclass field.

Compression, Storage, and Low-level Containers

Lower-level containers and configuration classes for compression, storage, codecs, filters, and remote paths.

SChunk([chunksize, data])

Compressed super-chunk storing a sequence of compressed chunks.

CParams(codec, codec_meta, clevel, use_dict, ...)

Dataclass for hosting the different compression parameters.

DParams(nthreads)

Dataclass for hosting the different decompression parameters.

Storage([contiguous, urlpath, mode, ...])

Dataclass for hosting the different storage parameters.

Codec(*values)

Available codecs.

Filter(*values)

Available filters.

SplitMode(*values)

Available split modes.

SpecialValue(*values)

Possible special values in a chunk.

Tuner(*values)

Available tuners.

FPAccuracy(*values)

Floating point accuracy modes for Blosc2 computing with lazy expressions.

URLPath(path, /[, urlbase, auth_token])

Ancillary / Advanced Classes

Base protocols, expression internals, structured-field views, proxy field views, and durable references. Most users encounter these indirectly through the container APIs above.

Array(*args, **kwargs)

A typing protocol for array-like objects with basic array interface.

NDField(ndarr, field)

View of one field from an NDArray with a structured dtype.

LazyExpr(new_op)

Class for hosting lazy expressions.

Operand()

Base class for all operands in expressions.

ProxyNDField(proxy, field)

Ref(kind[, urlpath, key, path, urlbase])

A durable reference to a Blosc2 object.