[tune][docs/util] gputil check, docs (#11260)

Co-authored-by: Amog Kamsetty <amogkam@users.noreply.github.com>
This commit is contained in:
Richard Liaw
2020-10-10 00:54:31 -07:00
committed by GitHub
co-authored by Amog Kamsetty
parent defd41aad7
commit 56f858ed1a
11 changed files with 229 additions and 98 deletions
+1 -1
View File
@@ -3,7 +3,7 @@
Tune API Reference
==================
.. tip:: We'd love to hear your feedback on using Tune - fill out a `short survey <https://forms.gle/PTRvGLbKRdUfuzQo9>`_!
.. tip:: We'd love to hear your feedback on using Tune - `get in touch <https://forms.gle/PTRvGLbKRdUfuzQo9>`_!
This section contains a reference for the Tune API. If there is anything missing, please open an issue
on `Github`_.
+15 -1
View File
@@ -17,7 +17,7 @@ For the sake of example, let's maximize this objective function:
Function API
------------
Here is a simple example of using the function API. You can report intermediate metrics by simply calling ``tune.report`` within the provided function.
With the Function API, you can report intermediate metrics by simply calling ``tune.report`` within the provided function.
.. code-block:: python
@@ -40,6 +40,8 @@ Here is a simple example of using the function API. You can report intermediate
Tune will run this function on a separate thread in a Ray actor process.
You'll notice that Ray Tune will output extra values in addition to the user reported metrics, such as ``iterations_since_restore``. See :ref:`tune-autofilled-metrics` for an explanation/glossary of these values.
.. tip:: If you want to leverage multi-node data parallel training with PyTorch while using parallel hyperparameter tuning, check out our :ref:`PyTorch <tune-pytorch-cifar>` user guide and Tune's :ref:`distributed pytorch integrations <tune-integration-torch>`.
Function API return and yield values
@@ -182,6 +184,7 @@ As a subclass of ``tune.Trainable``, Tune will create a ``Trainable`` object on
.. tip:: As a rule of thumb, the execution time of ``step`` should be large enough to avoid overheads (i.e. more than a few seconds), but short enough to report progress periodically (i.e. at most a few minutes).
You'll notice that Ray Tune will output extra values in addition to the user reported metrics, such as ``iterations_since_restore``. See :ref:`tune-autofilled-metrics` for an explanation/glossary of these values.
.. _tune-trainable-save-restore:
@@ -332,6 +335,17 @@ tune.Trainable (Class API)
:private-members:
:members:
.. _tune-util-ref:
Utilities
---------
.. autofunction:: ray.tune.utils.wait_for_gpu
.. autofunction:: ray.tune.utils.diagnose_serialization
.. autofunction:: ray.tune.utils.validate_save_restore
.. _tune-ddp-doc: