Skip to content

doc: add third-party libraries sections to using_chainer and using_pytorch topics #725

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Mar 26, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions doc/using_chainer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,16 @@ inadvertently run your training code at the wrong point in execution.

For more on training environment variables, please visit https://github.com/aws/sagemaker-containers.

Using third-party libraries
^^^^^^^^^^^^^^^^^^^^^^^^^^^

When running your training script on SageMaker, it will have access to some pre-installed third-party libraries including ``chainer``, ``numpy``, and ``cupy``.
For more information on the runtime environment, including specific package versions, see `SageMaker Chainer Docker containers <#sagemaker-chainer-docker-containers>`__.

If there are other packages you want to use with your script, you can include a ``requirements.txt`` file in the same directory as your training script to install other dependencies at runtime.
A ``requirements.txt`` file is a text file that contains a list of items that are installed by using ``pip install``. You can also specify the version of an item to install.
For information about the format of a ``requirements.txt`` file, see `Requirements Files <https://pip.pypa.io/en/stable/user_guide/#requirements-files>`__ in the pip documentation.

Running a Chainer training script in SageMaker
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down
7 changes: 5 additions & 2 deletions doc/using_mxnet.rst
Original file line number Diff line number Diff line change
Expand Up @@ -293,9 +293,12 @@ Lastly, if you were relying on the container launching a parameter server for us
Using third-party libraries
^^^^^^^^^^^^^^^^^^^^^^^^^^^

When running your training script on SageMaker, it will have access to some pre-installed third-party libraries including ``mxnet``, ``numpy``, ``onnx``, and ``keras-mxnet``. For more information on the runtime environment, including specific package versions, see `SageMaker MXNet Containers <#sagemaker-mxnet-containers>`__.
When running your training script on SageMaker, it will have access to some pre-installed third-party libraries including ``mxnet``, ``numpy``, ``onnx``, and ``keras-mxnet``.
For more information on the runtime environment, including specific package versions, see `SageMaker MXNet Containers <#sagemaker-mxnet-containers>`__.

If there are other packages you want to use with your script, you can include a `requirements.txt <https://pip.pypa.io/en/stable/user_guide/#requirements-files>`__ file in the same directory as your training script to install other dependencies at runtime.
If there are other packages you want to use with your script, you can include a ``requirements.txt`` file in the same directory as your training script to install other dependencies at runtime.
A ``requirements.txt`` file is a text file that contains a list of items that are installed by using ``pip install``. You can also specify the version of an item to install.
For information about the format of a ``requirements.txt`` file, see `Requirements Files <https://pip.pypa.io/en/stable/user_guide/#requirements-files>`__ in the pip documentation.

Running an MXNet training script in SageMaker
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
26 changes: 12 additions & 14 deletions doc/using_pytorch.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
Using PyTorch with the SageMaker Python SDK
===========================================

.. contents::

With PyTorch Estimators and Models, you can train and host PyTorch models on Amazon SageMaker.

Supported versions of PyTorch: ``0.4.0``, ``1.0.0``.
Expand All @@ -10,20 +12,6 @@ We recommend that you use the latest supported version, because that's where we

You can visit the PyTorch repository at https://github.com/pytorch/pytorch.

Table of Contents
-----------------

1. `Training with PyTorch <#training-with-pytorch>`__
2. `PyTorch Estimators <#pytorch-estimators>`__
3. `Distributed PyTorch Training <#distributed-pytorch-training>`__
4. `Saving models <#saving-models>`__
5. `Deploying PyTorch Models <#deploying-pytorch-models>`__
6. `SageMaker PyTorch Model Server <#sagemaker-pytorch-model-server>`__
7. `Working with Existing Model Data and Training Jobs <#working-with-existing-model-data-and-training-jobs>`__
8. `PyTorch Training Examples <#pytorch-training-examples>`__
9. `SageMaker PyTorch Docker Containers <#sagemaker-pytorch-docker-containers>`__


Training with PyTorch
------------------------

Expand Down Expand Up @@ -122,6 +110,16 @@ when instantiating PyTorch Estimator.

For more on training environment variables, please visit `SageMaker Containers <https://github.com/aws/sagemaker-containers>`_.

Using third-party libraries
~~~~~~~~~~~~~~~~~~~~~~~~~~~

When running your training script on SageMaker, it will have access to some pre-installed third-party libraries including ``torch``, ``torchvisopm``, and ``numpy``.
For more information on the runtime environment, including specific package versions, see `SageMaker PyTorch Docker containers <#sagemaker-pytorch-docker-containers>`__.

If there are other packages you want to use with your script, you can include a ``requirements.txt`` file in the same directory as your training script to install other dependencies at runtime.
A ``requirements.txt`` file is a text file that contains a list of items that are installed by using ``pip install``. You can also specify the version of an item to install.
For information about the format of a ``requirements.txt`` file, see `Requirements Files <https://pip.pypa.io/en/stable/user_guide/#requirements-files>`__ in the pip documentation.

Running a PyTorch training script in SageMaker
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down