diff options
author | Rémi Flamary <remi.flamary@gmail.com> | 2020-04-20 15:19:09 +0200 |
---|---|---|
committer | Rémi Flamary <remi.flamary@gmail.com> | 2020-04-20 15:19:09 +0200 |
commit | e65606ae498bd611f6a994868c2a66dfbea403cd (patch) | |
tree | b9b43dcaf8499b6d57b806ce04350fb6b792537f /docs/source/auto_examples/plot_OT_L1_vs_L2.rst | |
parent | 8acaf262baa04a4d2bdd9c774c45c5bb2fb2d12a (diff) |
big update examples
Diffstat (limited to 'docs/source/auto_examples/plot_OT_L1_vs_L2.rst')
-rw-r--r-- | docs/source/auto_examples/plot_OT_L1_vs_L2.rst | 87 |
1 files changed, 56 insertions, 31 deletions
diff --git a/docs/source/auto_examples/plot_OT_L1_vs_L2.rst b/docs/source/auto_examples/plot_OT_L1_vs_L2.rst index 5db4b55..16b20f9 100644 --- a/docs/source/auto_examples/plot_OT_L1_vs_L2.rst +++ b/docs/source/auto_examples/plot_OT_L1_vs_L2.rst @@ -1,6 +1,12 @@ +.. only:: html + + .. note:: + :class: sphx-glr-download-link-note + Click :ref:`here <sphx_glr_download_auto_examples_plot_OT_L1_vs_L2.py>` to download the full example code + .. rst-class:: sphx-glr-example-title -.. _sphx_glr_auto_examples_plot_OT_L1_vs_L2.py: + .. _sphx_glr_auto_examples_plot_OT_L1_vs_L2.py: ========================================== @@ -15,8 +21,7 @@ https://arxiv.org/pdf/1706.07650.pdf - -.. code-block:: python +.. code-block:: default # Author: Remi Flamary <remi.flamary@unice.fr> @@ -34,12 +39,12 @@ https://arxiv.org/pdf/1706.07650.pdf + Dataset 1 : uniform sampling ---------------------------- - -.. code-block:: python +.. code-block:: default n = 20 # nb samples @@ -98,12 +103,13 @@ Dataset 1 : uniform sampling * .. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_001.png - :scale: 47 + :class: sphx-glr-multi-img * .. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_002.png - :scale: 47 + :class: sphx-glr-multi-img + @@ -112,12 +118,8 @@ Dataset 1 : Plot OT Matrices ---------------------------- +.. code-block:: default -.. code-block:: python - - - - #%% EMD G1 = ot.emd(a, b, M1) G2 = ot.emd(a, b, M2) Gp = ot.emd(a, b, Mp) @@ -156,8 +158,18 @@ Dataset 1 : Plot OT Matrices -.. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_005.png - :align: center +.. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_003.png + :class: sphx-glr-single-img + + +.. rst-class:: sphx-glr-script-out + + Out: + + .. code-block:: none + + /home/rflamary/PYTHON/POT/examples/plot_OT_L1_vs_L2.py:113: UserWarning: Matplotlib is currently using agg, which is a non-GUI backend, so cannot show the figure. + pl.show() @@ -166,8 +178,7 @@ Dataset 2 : Partial circle -------------------------- - -.. code-block:: python +.. code-block:: default n = 50 # nb samples @@ -228,13 +239,14 @@ Dataset 2 : Partial circle * - .. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_007.png - :scale: 47 + .. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_004.png + :class: sphx-glr-multi-img * - .. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_008.png - :scale: 47 + .. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_005.png + :class: sphx-glr-multi-img + @@ -243,12 +255,8 @@ Dataset 2 : Plot OT Matrices ----------------------------- +.. code-block:: default -.. code-block:: python - - - - #%% EMD G1 = ot.emd(a, b, M1) G2 = ot.emd(a, b, M2) Gp = ot.emd(a, b, Mp) @@ -285,28 +293,45 @@ Dataset 2 : Plot OT Matrices -.. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_011.png - :align: center +.. image:: /auto_examples/images/sphx_glr_plot_OT_L1_vs_L2_006.png + :class: sphx-glr-single-img + + +.. rst-class:: sphx-glr-script-out + Out: + .. code-block:: none + /home/rflamary/PYTHON/POT/examples/plot_OT_L1_vs_L2.py:208: UserWarning: Matplotlib is currently using agg, which is a non-GUI backend, so cannot show the figure. + pl.show() -**Total running time of the script:** ( 0 minutes 0.958 seconds) + +.. rst-class:: sphx-glr-timing + + **Total running time of the script:** ( 0 minutes 1.002 seconds) + + +.. _sphx_glr_download_auto_examples_plot_OT_L1_vs_L2.py: + + .. only :: html .. container:: sphx-glr-footer + :class: sphx-glr-footer-example + - .. container:: sphx-glr-download + .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: plot_OT_L1_vs_L2.py <plot_OT_L1_vs_L2.py>` - .. container:: sphx-glr-download + .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: plot_OT_L1_vs_L2.ipynb <plot_OT_L1_vs_L2.ipynb>` @@ -315,4 +340,4 @@ Dataset 2 : Plot OT Matrices .. rst-class:: sphx-glr-signature - `Gallery generated by Sphinx-Gallery <https://sphinx-gallery.readthedocs.io>`_ + `Gallery generated by Sphinx-Gallery <https://sphinx-gallery.github.io>`_ |