summaryrefslogtreecommitdiff
path: root/ot/bregman.py
diff options
context:
space:
mode:
authorMokhtar Z. Alaya <mzalaya@Mokhtars-MacBook-Pro.local>2020-01-24 01:39:26 +0100
committerMokhtar Z. Alaya <mzalaya@Mokhtars-MacBook-Pro.local>2020-01-24 01:39:26 +0100
commite92b7075decc2b6b55a5b395768f733a577591ea (patch)
tree05fa151f9903fafb7e60260904c161f4050b1f11 /ot/bregman.py
parentbfde1aca37e0a1ee44b885eb8be624a0f7257bea (diff)
add a warning for non installed Botteleneck module
Diffstat (limited to 'ot/bregman.py')
-rw-r--r--ot/bregman.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/ot/bregman.py b/ot/bregman.py
index c304b5d..2707b7c 100644
--- a/ot/bregman.py
+++ b/ot/bregman.py
@@ -1877,7 +1877,8 @@ def screenkhorn(a, b, M, reg, ns_budget=None, nt_budget=None, uniform=False, res
try:
import bottleneck
except ImportError:
- print("Bottleneck module doesn't exist. Install it from https://pypi.org/project/Bottleneck/")
+ warnings.warn("Bottleneck module is not installed. Install it from https://pypi.org/project/Bottleneck/ for better performance.")
+ bottleneck = np
a = np.asarray(a, dtype=np.float64)
b = np.asarray(b, dtype=np.float64)