pyriemann.utils.distance.distance_euclid¶
- pyriemann.utils.distance.distance_euclid(A, B)¶
Euclidean distance between SPD matrices.
The Euclidean distance between two SPD matrices A and B is defined as the Frobenius norm of the difference of the two matrices:
\[d(\mathbf{A},\mathbf{B}) = \Vert \mathbf{A} - \mathbf{B} \Vert_F\]- Parameters
- Andarray, shape (…, n, n)
First SPD matrices, at least 2D ndarray.
- Bndarray, shape (…, n, n)
Second SPD matrices, same dimensions as A.
- Returns
- dndarray, shape (…,) or float
Euclidean distance between A and B.