spd_learn.functional.spd_rebiasing#
- spd_learn.functional.spd_rebiasing(X: Tensor, bias_sqrt: Tensor) Tensor[source]#
Apply learnable rebiasing to centered SPD matrices.
Applies a congruence transformation to rebias centered SPD matrices:
\[\hat{X}_i = B^{1/2} X_i B^{1/2}\]This corresponds to parallel transport from the identity to the bias matrix \(B\) under the affine-invariant Riemannian metric.
- Parameters:
X (torch.Tensor) – Batch of centered SPD matrices with shape (…, n, n).
bias_sqrt (torch.Tensor) – Square root of the bias SPD matrix with shape (…, n, n).
- Returns:
Rebiased SPD matrices with shape (…, n, n).
- Return type:
See also
spd_centering()Center matrices around a mean.