pyriemann.utils.ajd.ajd_pham¶
- pyriemann.utils.ajd.ajd_pham(X, *, init=None, eps=1e-06, n_iter_max=20, sample_weight=None)¶
Approximate joint diagonalization based on Pham’s algorithm.
This is a direct implementation of the AJD algorithm [1], optimizing a log-likelihood criterion based on the Kullback-Leibler divergence.
- Parameters:
- Xndarray, shape (n_matrices, n, n)
Set of SPD matrices to diagonalize.
- initNone | ndarray, shape (n, n), default=None
Initialization for the diagonalizer.
- epsfloat, default=1e-6
Tolerance for stoping criterion.
- n_iter_maxint, default=20
The maximum number of iterations to reach convergence.
- sample_weightNone | ndarray, shape (n_matrices,), default=None
Weights for each matrix, strictly positive. If None, it uses equal weights.
- Returns:
- Vndarray, shape (n, n)
The diagonalizer, an invertible matrix.
- Dndarray, shape (n_matrices, n, n)
Set of quasi diagonal matrices, D = V X V^T.
See also
Notes
New in version 0.2.4.
References
[1]Joint approximate diagonalization of positive definite Hermitian matrices D.-T. Pham. SIAM Journal on Matrix Analysis and Applications, 22(4), pp. 1136-1152, 2000.