Ray Tutorials and Examples
==========================

Get started with Ray, Tune, and RLlib with these notebooks that you can run online in Colab or Binder: `Ray Tutorial Notebooks <https://github.com/ray-project/tutorial>`__


Ray Examples
------------

.. raw:: html

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

.. toctree::
   :hidden:

   tips-for-first-time.rst
   testing-tips.rst
   progress_bar.rst
   plot_streaming.rst
   placement-group.rst

.. customgalleryitem::
   :tooltip: Tips for first time users.
   :figure: /images/pipeline.png
   :description: :doc:`/auto_examples/tips-for-first-time`

.. customgalleryitem::
   :tooltip: Tips for testing Ray applications
   :description: :doc:`/auto_examples/testing-tips`

.. customgalleryitem::
   :tooltip: Progress Bar for Ray Tasks
   :description: :doc:`/auto_examples/progress_bar`

.. customgalleryitem::
   :tooltip: Implement a simple streaming application using Ray’s actors.
   :description: :doc:`/auto_examples/plot_streaming`

.. customgalleryitem::
   :tooltip: Learn placement group use cases with examples.
   :description: :doc:`/auto_examples/placement-group`

.. raw:: html

    </div>


Machine Learning Examples
-------------------------

.. raw:: html

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

.. toctree::
   :hidden:

   plot_parameter_server.rst
   plot_hyperparameter.rst
   plot_lbfgs.rst
   plot_example-lm.rst
   plot_newsreader.rst


.. customgalleryitem::
   :tooltip: Build a simple parameter server using Ray.
   :figure: /images/param_actor.png
   :description: :doc:`/auto_examples/plot_parameter_server`

.. customgalleryitem::
   :tooltip: Simple parallel asynchronous hyperparameter evaluation.
   :figure: /images/hyperparameter.png
   :description: :doc:`/auto_examples/plot_hyperparameter`

.. customgalleryitem::
   :tooltip: Walkthrough of parallelizing the L-BFGS algorithm.
   :description: :doc:`/auto_examples/plot_lbfgs`


.. customgalleryitem::
   :tooltip: Distributed Fault-Tolerant BERT training for FAIRSeq using Ray.
   :description: :doc:`/auto_examples/plot_example-lm`

.. customgalleryitem::
   :tooltip: Implementing a simple news reader using Ray.
   :description: :doc:`/auto_examples/plot_newsreader`


.. raw:: html

    </div>


Reinforcement Learning Examples
-------------------------------

These are simple examples that show you how to leverage Ray Core. For Ray's production-grade reinforcement learning library, see `RLlib <http://docs.ray.io/en/master/rllib.html>`__.

.. raw:: html

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

.. toctree::
   :hidden:

   plot_pong_example.rst
   plot_example-a3c.rst

.. customgalleryitem::
   :tooltip: Asynchronous Advantage Actor Critic agent using Ray.
   :figure: /images/a3c.png
   :description: :doc:`/auto_examples/plot_example-a3c`

.. customgalleryitem::
   :tooltip: Parallelizing a policy gradient calculation on OpenAI Gym Pong.
   :figure: /images/pong.png
   :description: :doc:`/auto_examples/plot_pong_example`

.. raw:: html

    </div>
