The scipy.stats.wasserstein_distance
function only returns the minimum distance (the solution) between two input distributions, p
and q
. But that distance is the result of the product of a distance matrix and an optimal transport matrix that must have been computed inside the same function.
How can I extract the distance matrix and optimal transport matrix that correspond to the solution as 2nd and 3rd output arguments?