distance matrix in python

Solutions on MaxInterview for distance matrix in python by the best coders in the world

showing results for - "distance matrix in python"
Marlon
09 Oct 2019
1>>> from scipy.spatial import distance_matrix
2>>> distance_matrix([[0,0],[0,1]], [[1,0],[1,1]])
3array([[ 1.        ,  1.41421356],
4       [ 1.41421356,  1.        ]])
5