diff options
author | Romain Tavenard <romain.tavenard@univ-rennes2.fr> | 2019-07-02 09:44:02 +0200 |
---|---|---|
committer | Romain Tavenard <romain.tavenard@univ-rennes2.fr> | 2019-07-02 09:44:02 +0200 |
commit | 8d47d32713a6e2d448fae6db7420e93b4395d5e6 (patch) | |
tree | 454597ade5a46ecb089ace3307f658a740841b99 | |
parent | f7fbb57a96bc6c7fe7d6237292aa39516c2f614e (diff) |
Bugfix (python2 in unbalanced)
-rw-r--r-- | ot/unbalanced.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ot/unbalanced.py b/ot/unbalanced.py index 4a2af8a..44ab411 100644 --- a/ot/unbalanced.py +++ b/ot/unbalanced.py @@ -6,6 +6,7 @@ Regularized Unbalanced OT # Author: Hicham Janati <hicham.janati@inria.fr> # License: MIT License +from __future__ import division import warnings import numpy as np # from .utils import unif, dist @@ -287,12 +288,12 @@ def sinkhorn_knopp_unbalanced(a, b, M, reg, alpha, numItermax=1000, -------- >>> import ot - >>> a=[.5, .15] + >>> a=[.5, .5] >>> b=[.5, .5] >>> M=[[0., 1.],[1., 0.]] >>> ot.unbalanced.sinkhorn_knopp_unbalanced(a, b, M, 1., 1.) - array([[0.52761554, 0.22392482], - [0.10286295, 0.32257641]]) + array([[0.51122823, 0.18807035], + [0.18807035, 0.51122823]]) References ---------- |