Skip to content

Commit 042b52d

Browse files
committed
pep8
1 parent c112190 commit 042b52d

File tree

2 files changed

+19
-6
lines changed

2 files changed

+19
-6
lines changed

README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,12 @@ The library has been tested on Linux, MacOSX and Windows. It requires a C++ comp
5353

5454
#### Pip installation
5555

56+
Note that due to a limitation of pip, `cython` and `numpy` need to be installed
57+
prior to installing POT. This can be done easily with
58+
```
59+
pip install numpy cython
60+
```
61+
5662
You can install the toolbox through PyPI with:
5763
```
5864
pip install POT
@@ -62,6 +68,8 @@ or get the very latest version by downloading it and then running:
6268
python setup.py install --user # for user install (no root)
6369
```
6470

71+
72+
6573
#### Anaconda installation with conda-forge
6674

6775
If you use the Anaconda python distribution, POT is available in [conda-forge](https://conda-forge.org). To install it and the required dependencies:
@@ -150,7 +158,12 @@ You can also see the notebooks with [Jupyter nbviewer](https://nbviewer.jupyter.
150158

151159
## Acknowledgements
152160

153-
The contributors to this library are:
161+
This toolbox has been created and is maintained by
162+
163+
* [Rémi Flamary](http://remi.flamary.com/)
164+
* [Nicolas Courty](http://people.irisa.fr/Nicolas.Courty/)
165+
166+
The contributors to this library are
154167

155168
* [Rémi Flamary](http://remi.flamary.com/)
156169
* [Nicolas Courty](http://people.irisa.fr/Nicolas.Courty/)

ot/gromov.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ def fused_gromov_wasserstein(M, C1, C2, p, q, loss_fun='square_loss', alpha=0.5,
359359
.. math::
360360
\gamma = arg\min_\gamma (1-\alpha)*<\gamma,M>_F + \alpha* \sum_{i,j,k,l}
361361
L(C1_{i,k},C2_{j,l})*T_{i,j}*T_{k,l}
362-
362+
363363
s.t. \gamma 1 = p
364364
\gamma^T 1= q
365365
\gamma\geq 0
@@ -414,7 +414,7 @@ def fused_gromov_wasserstein(M, C1, C2, p, q, loss_fun='square_loss', alpha=0.5,
414414
and Courty Nicolas "Optimal Transport for structured data with
415415
application on graphs", International Conference on Machine Learning
416416
(ICML). 2019.
417-
417+
418418
"""
419419

420420
constC, hC1, hC2 = init_matrix(C1, C2, p, q, loss_fun)
@@ -442,7 +442,7 @@ def fused_gromov_wasserstein2(M, C1, C2, p, q, loss_fun='square_loss', alpha=0.5
442442
.. math::
443443
\min_\gamma (1-\alpha)*<\gamma,M>_F + \alpha* \sum_{i,j,k,l}
444444
L(C1_{i,k},C2_{j,l})*T_{i,j}*T_{k,l}
445-
445+
446446
447447
s.t. \gamma 1 = p
448448
\gamma^T 1= q
@@ -647,7 +647,7 @@ def entropic_gromov_wasserstein(C1, C2, p, q, loss_fun, epsilon,
647647
Returns
648648
-------
649649
T : ndarray, shape (ns, nt)
650-
Optimal coupling between the two spaces
650+
Optimal coupling between the two spaces
651651
652652
References
653653
----------
@@ -1024,7 +1024,7 @@ def fgw_barycenters(N, Ys, Cs, ps, lambdas, alpha, fixed_structure=False, fixed_
10241024
T : list of (N,ns) transport matrices
10251025
Ms : all distance matrices between the feature of the barycenter and the
10261026
other features dist(X,Ys) shape (N,ns)
1027-
1027+
10281028
References
10291029
----------
10301030
.. [24] Vayer Titouan, Chapel Laetitia, Flamary R{\'e}mi, Tavenard Romain

0 commit comments

Comments
 (0)