spd_learn.functional.log_map_lem#

spd_learn.functional.log_map_lem(P, Q)[source]#

Riemannian logarithmic map under the Log-Euclidean metric.

Maps a point \(Q\) on the SPD manifold to a tangent vector at base point \(P\). This is the inverse of the exponential map.

Under the Log-Euclidean metric, the logarithmic map is:

\[\text{Log}_P(Q) = \log(Q) - \log(P)\]

The result is a symmetric matrix representing the tangent vector at \(P\) that points towards \(Q\).

Parameters:
  • P (torch.Tensor) – Base point on the SPD manifold with shape (…, n, n).

  • Q (torch.Tensor) – Target point on the SPD manifold with shape (…, n, n).

Returns:

Tangent vector at P (symmetric matrix) with shape (…, n, n).

Return type:

torch.Tensor

Notes

The norm of the tangent vector equals the Log-Euclidean distance:

\[\|\text{Log}_P(Q)\|_F = d_{\text{LEM}}(P, Q)\]

See also

exp_map_lem()

Inverse operation (exponential map).

log_euclidean_distance()

Distance under Log-Euclidean metric.

parallel_transport_lem()

Parallel transport under LEM.

References

See [Arsigny et al., 2007] for more details.