summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorRémi Flamary <remi.flamary@gmail.com>2017-09-01 16:28:35 +0200
committerRémi Flamary <remi.flamary@gmail.com>2017-09-01 16:28:35 +0200
commit052ccadc5023ec500dc10477821bf0267426aa4f (patch)
tree7deac1febb3c8b8c20be578583c0b326856ee7db /examples
parent364a42954f9d2f5c43e7ff53ee0a3b6f9a682e8a (diff)
pep8
Diffstat (limited to 'examples')
-rw-r--r--examples/README.txt2
-rw-r--r--examples/plot_OT_1D.py7
-rw-r--r--examples/plot_OT_L1_vs_L2.py2
-rw-r--r--examples/plot_WDA.py2
-rw-r--r--examples/plot_barycenter_1D.py4
-rw-r--r--examples/plot_compute_emd.py2
-rw-r--r--examples/plot_optim_OTreg.py14
-rw-r--r--examples/plot_otda_mapping_colors_images.py4
8 files changed, 18 insertions, 19 deletions
diff --git a/examples/README.txt b/examples/README.txt
index c3d556d..b08d3f1 100644
--- a/examples/README.txt
+++ b/examples/README.txt
@@ -1,4 +1,4 @@
POT Examples
============
-This is a gallery of all the POT example files.
+This is a gallery of all the POT example files.
diff --git a/examples/plot_OT_1D.py b/examples/plot_OT_1D.py
index a63f29a..b6ffa5f 100644
--- a/examples/plot_OT_1D.py
+++ b/examples/plot_OT_1D.py
@@ -4,7 +4,7 @@
1D optimal transport
====================
-This example illustrates the computation of EMD and Sinkhorn transport plans
+This example illustrates the computation of EMD and Sinkhorn transport plans
and their visualization.
"""
@@ -20,7 +20,8 @@ from ot.datasets import get_1D_gauss as gauss
##############################################################################
# Generate data
-##############################################################################
+# #############
+
#%% parameters
@@ -40,7 +41,7 @@ M /= M.max()
##############################################################################
# Plot distributions and loss matrix
-##############################################################################
+###################################
#%% plot the distributions
diff --git a/examples/plot_OT_L1_vs_L2.py b/examples/plot_OT_L1_vs_L2.py
index 77bde22..49d37e1 100644
--- a/examples/plot_OT_L1_vs_L2.py
+++ b/examples/plot_OT_L1_vs_L2.py
@@ -76,7 +76,6 @@ pl.tight_layout()
##############################################################################
-
#%% EMD
G1 = ot.emd(a, b, M1)
G2 = ot.emd(a, b, M2)
@@ -172,7 +171,6 @@ pl.tight_layout()
##############################################################################
-
#%% EMD
G1 = ot.emd(a, b, M1)
G2 = ot.emd(a, b, M2)
diff --git a/examples/plot_WDA.py b/examples/plot_WDA.py
index 06a2e38..5928621 100644
--- a/examples/plot_WDA.py
+++ b/examples/plot_WDA.py
@@ -7,7 +7,7 @@ Wasserstein Discriminant Analysis
This example illustrate the use of WDA as proposed in [11].
-[11] Flamary, R., Cuturi, M., Courty, N., & Rakotomamonjy, A. (2016).
+[11] Flamary, R., Cuturi, M., Courty, N., & Rakotomamonjy, A. (2016).
Wasserstein Discriminant Analysis.
"""
diff --git a/examples/plot_barycenter_1D.py b/examples/plot_barycenter_1D.py
index 142b05e..eef8536 100644
--- a/examples/plot_barycenter_1D.py
+++ b/examples/plot_barycenter_1D.py
@@ -4,11 +4,11 @@
1D Wasserstein barycenter demo
==============================
-This example illustrates the computation of regularized Wassersyein Barycenter
+This example illustrates the computation of regularized Wassersyein Barycenter
as proposed in [3].
-[3] Benamou, J. D., Carlier, G., Cuturi, M., Nenna, L., & Peyré, G. (2015).
+[3] Benamou, J. D., Carlier, G., Cuturi, M., Nenna, L., & Peyré, G. (2015).
Iterative Bregman projections for regularized transportation problems
SIAM Journal on Scientific Computing, 37(2), A1111-A1138.
diff --git a/examples/plot_compute_emd.py b/examples/plot_compute_emd.py
index b688f93..a84b249 100644
--- a/examples/plot_compute_emd.py
+++ b/examples/plot_compute_emd.py
@@ -4,7 +4,7 @@
Plot multiple EMD
=================
-Shows how to compute multiple EMD and Sinkhorn with two differnt
+Shows how to compute multiple EMD and Sinkhorn with two differnt
ground metrics and plot their values for diffeent distributions.
diff --git a/examples/plot_optim_OTreg.py b/examples/plot_optim_OTreg.py
index b362662..d753414 100644
--- a/examples/plot_optim_OTreg.py
+++ b/examples/plot_optim_OTreg.py
@@ -5,20 +5,20 @@ Regularized OT with generic solver
==================================
Illustrates the use of the generic solver for regularized OT with
-user-designed regularization term. It uses Conditional gradient as in [6] and
+user-designed regularization term. It uses Conditional gradient as in [6] and
generalized Conditional Gradient as proposed in [5][7].
-[5] N. Courty; R. Flamary; D. Tuia; A. Rakotomamonjy, Optimal Transport for
-Domain Adaptation, in IEEE Transactions on Pattern Analysis and Machine
+[5] N. Courty; R. Flamary; D. Tuia; A. Rakotomamonjy, Optimal Transport for
+Domain Adaptation, in IEEE Transactions on Pattern Analysis and Machine
Intelligence , vol.PP, no.99, pp.1-1.
-[6] Ferradans, S., Papadakis, N., Peyré, G., & Aujol, J. F. (2014).
-Regularized discrete optimal transport. SIAM Journal on Imaging Sciences,
+[6] Ferradans, S., Papadakis, N., Peyré, G., & Aujol, J. F. (2014).
+Regularized discrete optimal transport. SIAM Journal on Imaging Sciences,
7(3), 1853-1882.
-[7] Rakotomamonjy, A., Flamary, R., & Courty, N. (2015). Generalized
-conditional gradient: analysis of convergence and applications.
+[7] Rakotomamonjy, A., Flamary, R., & Courty, N. (2015). Generalized
+conditional gradient: analysis of convergence and applications.
arXiv preprint arXiv:1510.06567.
diff --git a/examples/plot_otda_mapping_colors_images.py b/examples/plot_otda_mapping_colors_images.py
index 162c24b..5590286 100644
--- a/examples/plot_otda_mapping_colors_images.py
+++ b/examples/plot_otda_mapping_colors_images.py
@@ -1,10 +1,10 @@
# -*- coding: utf-8 -*-
"""
=====================================================
-OT for image color adaptation with mapping estimation
+OT for image color adaptation with mapping estimation
=====================================================
-OT for domain adaptation with image color adaptation [6] with mapping
+OT for domain adaptation with image color adaptation [6] with mapping
estimation [8].
[6] Ferradans, S., Papadakis, N., Peyre, G., & Aujol, J. F. (2014). Regularized