:orphan:

.. _examples:

Examples
========

This gallery shows examples that integrate several aspects of shoot.
This examples works in a sequential way. Mind that however things
are implicitly parallelized through xarray methods.


Parallelisation
---------------

The eddy detection can be parallelized easily.
In laptops change the ``paral`` boolean argument to True in :meth:`shoot.eddies.Eddies.detect_eddies`
and in :meth:`shoot.eddies.EvolEddies.detect_eddies`.
To run with large grid on HPC, wrap your example in ``if __name__ == "__main__"``
and add the following lines::

    import multiprocessing as mp
    mp.set_start_method("spawn")





.. raw:: html

    <div class="sphx-glr-thumbnails">

.. thumbnail-parent-div-open

.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="Detect eddies from satellite sea level">

.. only:: html

  .. image:: /examples/images/thumb/sphx_glr_plot_eddy_detect_sat_thumb.png
    :alt:

  :doc:`/examples/plot_eddy_detect_sat`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Detect eddies from satellite sea level</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="Detect CROCO-GIGATL1 eddies at 1000m">

.. only:: html

  .. image:: /examples/images/thumb/sphx_glr_plot_eddy_detect_croco_thumb.png
    :alt:

  :doc:`/examples/plot_eddy_detect_croco`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Detect CROCO-GIGATL1 eddies at 1000m</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="Detect eddies from different files and merge tracking">

.. only:: html

  .. image:: /examples/images/thumb/sphx_glr_tracking_merged_eddies_thumb.png
    :alt:

  :doc:`/examples/tracking_merged_eddies`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Detect eddies from different files and merge tracking</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="Diagnostics prior to eddy detection">

.. only:: html

  .. image:: /examples/images/thumb/sphx_glr_plot_diags_prior_eddies_thumb.png
    :alt:

  :doc:`/examples/plot_diags_prior_eddies`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Diagnostics prior to eddy detection</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="In this example, 3D eddies are detected from CROCO model currents interpolated at several depths and collocated at RHO points.">

.. only:: html

  .. image:: /examples/images/thumb/sphx_glr_plot_eddy_detect_3d_thumb.png
    :alt:

  :doc:`/examples/plot_eddy_detect_3d`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Detect CROCO-MED1.8 eddies at different depths and link the detections</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="Detect and Track eddies from satellite sea level">

.. only:: html

  .. image:: /examples/images/thumb/sphx_glr_plot_eddy_tracking_duacs_thumb.png
    :alt:

  :doc:`/examples/plot_eddy_tracking_duacs`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Detect and Track eddies from satellite sea level</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="This example requires 3D dataset including depth dimension Hydrology anomalies can be performes in every 3D fields.">

.. only:: html

  .. image:: /examples/images/thumb/sphx_glr_plot_hydrology_diags_thumb.png
    :alt:

  :doc:`/examples/plot_hydrology_diags`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Profile anomalies diags</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="Open and analyse shoot output netcdf">

.. only:: html

  .. image:: /examples/images/thumb/sphx_glr_plot_shoot_netcdf_thumb.png
    :alt:

  :doc:`/examples/plot_shoot_netcdf`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Open and analyse shoot output netcdf</div>
    </div>


.. thumbnail-parent-div-close

.. raw:: html

    </div>


.. toctree::
   :hidden:

   /examples/plot_eddy_detect_sat
   /examples/plot_eddy_detect_croco
   /examples/tracking_merged_eddies
   /examples/plot_diags_prior_eddies
   /examples/plot_eddy_detect_3d
   /examples/plot_eddy_tracking_duacs
   /examples/plot_hydrology_diags
   /examples/plot_shoot_netcdf


.. only:: html

  .. container:: sphx-glr-footer sphx-glr-footer-gallery

    .. container:: sphx-glr-download sphx-glr-download-python

      :download:`Download all examples in Python source code: examples_python.zip </examples/examples_python.zip>`

    .. container:: sphx-glr-download sphx-glr-download-jupyter

      :download:`Download all examples in Jupyter notebooks: examples_jupyter.zip </examples/examples_jupyter.zip>`


.. only:: html

 .. rst-class:: sphx-glr-signature

    `Gallery generated by Sphinx-Gallery <https://sphinx-gallery.github.io>`_
