diff options
author | Rémi Flamary <remi.flamary@gmail.com> | 2017-07-24 14:26:25 +0200 |
---|---|---|
committer | Rémi Flamary <remi.flamary@gmail.com> | 2017-07-24 14:26:25 +0200 |
commit | b2f91f24796a996a82db41e91f56ba6a51989159 (patch) | |
tree | 81f8ce82e2b7474378746fa591149352d89a7775 /test/test_ot.py | |
parent | 1cf304cee298e2752ce29c83e5201f593722c3af (diff) |
full coveragre utils
Diffstat (limited to 'test/test_ot.py')
-rw-r--r-- | test/test_ot.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/test_ot.py b/test/test_ot.py index 3fa1bc4..16fd510 100644 --- a/test/test_ot.py +++ b/test/test_ot.py @@ -31,9 +31,11 @@ def test_emd_emd2(): # check G is identity assert np.allclose(G, np.eye(n) / n) + # check constratints + assert np.allclose(u, G.sum(1)) # cf convergence sinkhorn + assert np.allclose(u, G.sum(0)) # cf convergence sinkhorn w = ot.emd2(u, u, M) - # check loss=0 assert np.allclose(w, 0) |