API Reference#

Classes#

CreationFunctions(array, units)

DimensionedArray(*, dims, values, unit)

Array with named dimensions and optional unit.

DimensionError

UnitsError

Top-level functions#

General#

exp(x, /)

rtype:

TypeVar(DimArr, bound= DimensionedArray)

Reduction functions#

all(x, /, *[, dim])

Test whether all elements are true along one or multiple dimensions.

any(x, /, *[, dim])

Test whether any elements are true along one or multiple dimensions.

max(x, /, *[, dim])

Maximum value along one or multiple dimensions.

mean(x, /, *[, dim])

Mean along one or multiple dimensions.

min(x, /, *[, dim])

Minimum value along one or multiple dimensions.

prod(x, /, *[, dim, dtype])

Product along one or multiple dimensions.

sum(x, /, *[, dim, dtype])

Sum along one or multiple dimensions.

std(x, /, *[, dim, correction])

Standard deviation along one or multiple dimensions.

var(x, /, *[, dim, correction])

Variance along one or multiple dimensions.

Manipulation functions#

broadcast_to(*args, **kwargs)

Not supported since it relies on a particular axis order.

concat(arrays, /, *[, dim])

Concatenate arrays along a given dimension.

expand_dims(array, /, sizes)

Expand an array by adding new dimensions of the given sizes at the beginning.

flatten(array, /, *[, dims, dim])

Flatten a set of dimensions into a single dimension.

fold(array, /, dim, *, sizes)

Fold a dimension of an array into a new set of dimensions.

moveaxis(*args, **kwargs)

Not supported since it relies on a particular axis order.

permute_dims(array, /, dims)

Permute the dimensions of an array.

reshape(*args, **kwargs)

Not supported since it relies on a particular axis order.

squeeze(array, /[, dim])

Remove dimensions of size 1.

stack(arrays, /, *, dim[, axis])

Stack arrays along a new dimension.

Indexing functions#

take(x, /, indices)

Returns elements of an array along an axis.

Submodules#