mean_euc_spd#

hypercoil.functional.semidefinite.mean_euc_spd(input: Tensor, axis: int | Sequence[int] = 0) Tensor[source]#

Batch-wise Euclidean mean of tensors in the positive semidefinite cone.

This is the familiar arithmetic mean:

\(\frac{1}{N}\sum_{i=1}^N X_{i}\)

Dimension:
Input : \((N, *, D, D)\)

N denotes batch size, * denotes any number of intervening dimensions, D denotes matrix row and column dimension.

Output : \((*, D, D)\)

As above.

Parameters:
inputTensor

Batch of matrices over which the Euclidean mean is to be computed.

axisint

Axis or axes over which the mean is computed.

Returns:
outputTensor

Log-Euclidean mean of the input batch.