pub fn kernel_alignment(k1: &Array2<f64>, k2: &Array2<f64>) -> Result<f64>Expand description
Kernel alignment between two kernel matrices
The alignment A(K1, K2) = <K1, K2>_F / (||K1||_F * ||K2||_F) where <.,.>_F is the Frobenius inner product.
This measures how similar two kernel matrices are.
§Arguments
k1- First kernel matrixk2- Second kernel matrix
§Returns
Result<f64>- The alignment score in [0, 1]