summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortlacombe <lacombe1993@gmail.com>2020-03-10 15:45:45 +0100
committertlacombe <lacombe1993@gmail.com>2020-03-10 15:45:45 +0100
commit2eca5c75b1fbd7157e2656b875e730dc5f00f373 (patch)
treee3c2a0053590c153ae6b04ba92f9bb8ef73310c8 /src
parent570a9b83eb3f714bc52735dae289a5195874bf41 (diff)
removed P[P < 0.5] thresholding ; as it shouldn't happen anymore.
Diffstat (limited to 'src')
-rw-r--r--src/python/gudhi/wasserstein.py1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/python/gudhi/wasserstein.py b/src/python/gudhi/wasserstein.py
index aab0cb3c..e28c63e6 100644
--- a/src/python/gudhi/wasserstein.py
+++ b/src/python/gudhi/wasserstein.py
@@ -130,7 +130,6 @@ def wasserstein_distance(X, Y, matching=False, order=2., internal_p=2.):
if matching:
P = ot.emd(a=a,b=b,M=M, numItermax=2000000)
ot_cost = np.sum(np.multiply(P,M))
- P[P < 0.5] = 0 # trick to avoid numerical issue, could it be improved?
match = np.argwhere(P)
# Now we turn to -1 points encoding the diagonal
match = _clean_match(match, n, m)