summaryrefslogtreecommitdiff
path: root/ot/utils.py
diff options
context:
space:
mode:
authorievred <ievgen.redko@univ-st-etienne.fr>2020-04-03 17:29:13 +0200
committerievred <ievgen.redko@univ-st-etienne.fr>2020-04-03 17:29:13 +0200
commit98b68f1edc916d3802eeb24a19d0e10d855e01c6 (patch)
tree8830ef44936292de0d048d3c25170f180e843e7f /ot/utils.py
parentfa99199c02e497354e34c6ce76e7b4ba15b44d05 (diff)
autopep+remove sinkhorn+add simtype
Diffstat (limited to 'ot/utils.py')
-rw-r--r--ot/utils.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/ot/utils.py b/ot/utils.py
index b8a6f44..a633be2 100644
--- a/ot/utils.py
+++ b/ot/utils.py
@@ -48,6 +48,7 @@ def kernel(x1, x2, method='gaussian', sigma=1, **kwargs):
K = np.exp(-dist(x1, x2) / (2 * sigma**2))
return K
+
def laplacian(x):
"""Compute Laplacian matrix"""
L = np.diag(np.sum(x, axis=0)) - x