Skip to content

Commit 66816cb

Browse files
committed
pep8 all the way
1 parent 209835b commit 66816cb

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ot/bregman.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -378,9 +378,9 @@ def sinkhorn_knopp(a, b, M, reg, numItermax=1000,
378378
err = np.sum((u - uprev)**2) / np.sum((u)**2) + \
379379
np.sum((v - vprev)**2) / np.sum((v)**2)
380380
else:
381-
# compute right marginal tmp2= (diag(u)Kdiag(v))^T1
382-
np.einsum('i,ij,j->j',u,K,v,out=tmp2)
383-
err = np.linalg.norm(tmp2-b)**2 # violation of marginal
381+
# compute right marginal tmp2= (diag(u)Kdiag(v))^T1
382+
np.einsum('i,ij,j->j', u, K, v, out=tmp2)
383+
err = np.linalg.norm(tmp2 - b)**2 # violation of marginal
384384
if log:
385385
log['err'].append(err)
386386

0 commit comments

Comments
 (0)