(X, Y, a, b, pi)
| 371 | U = U0 |
| 372 | |
| 373 | def Vpi(X, Y, a, b, pi): |
| 374 | # Return the second order matrix of the displacements: sum_ij { (pi)_ij (X_i-Y_j)(X_i-Y_j)^T }. |
| 375 | A = X.T.dot(pi).dot(Y) |
| 376 | return ( |
| 377 | X.T.dot(np.diag(a)).dot(X) |
| 378 | + Y.T.dot(np.diag(np.sum(pi, 0))).dot(Y) |
| 379 | - A |
| 380 | - A.T |
| 381 | ) |
| 382 | |
| 383 | err = 1 |
| 384 | iter = 0 |
no test coverage detected