Fix #3443: Link to upstream Dockerfile for lack of correct TensorFlow GPU deps doc.
This commit is contained in:
parent
da31812173
commit
c979e360da
@ -3,11 +3,14 @@
|
|||||||
Training Your Own Model
|
Training Your Own Model
|
||||||
=======================
|
=======================
|
||||||
|
|
||||||
|
.. _cuda-training-deps:
|
||||||
|
|
||||||
Prerequisites for training a model
|
Prerequisites for training a model
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
* `Python 3.6 <https://www.python.org/>`_
|
* `Python 3.6 <https://www.python.org/>`_
|
||||||
* Mac or Linux environment
|
* Mac or Linux environment
|
||||||
|
* CUDA 10.0 / CuDNN v7.6 per `Dockerfile <https://hub.docker.com/layers/tensorflow/tensorflow/1.15.4-gpu-py3/images/sha256-a5255ae38bcce7c7610816c778244309f8b8d1576e2c0023c685c011392958d7?context=explore>`_.
|
||||||
|
|
||||||
Getting the training code
|
Getting the training code
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
@ -69,7 +72,7 @@ If you have a capable (NVIDIA, at least 8GB of VRAM) GPU, it is highly recommend
|
|||||||
pip3 uninstall tensorflow
|
pip3 uninstall tensorflow
|
||||||
pip3 install 'tensorflow-gpu==1.15.4'
|
pip3 install 'tensorflow-gpu==1.15.4'
|
||||||
|
|
||||||
Please ensure you have the required :ref:`CUDA dependency <cuda-deps>`.
|
Please ensure you have the required `CUDA dependency <https://www.tensorflow.org/install/source#gpu>`_ and/or :ref:`Prerequisites <cuda-training-deps>`.
|
||||||
|
|
||||||
It has been reported for some people failure at training:
|
It has been reported for some people failure at training:
|
||||||
|
|
||||||
@ -78,7 +81,7 @@ It has been reported for some people failure at training:
|
|||||||
tensorflow.python.framework.errors_impl.UnknownError: Failed to get convolution algorithm. This is probably because cuDNN failed to initialize, so try looking to see if a warning log message was printed above.
|
tensorflow.python.framework.errors_impl.UnknownError: Failed to get convolution algorithm. This is probably because cuDNN failed to initialize, so try looking to see if a warning log message was printed above.
|
||||||
[[{{node tower_0/conv1d/Conv2D}}]]
|
[[{{node tower_0/conv1d/Conv2D}}]]
|
||||||
|
|
||||||
Setting the ``TF_FORCE_GPU_ALLOW_GROWTH`` environment variable to ``true`` seems to help in such cases. This could also be due to an incorrect version of libcudnn. Double check your versions with the :ref:`TensorFlow 1.15 documentation <cuda-deps>`.
|
Setting the ``TF_FORCE_GPU_ALLOW_GROWTH`` environment variable to ``true`` seems to help in such cases. This could also be due to an incorrect version of libcudnn. Double check your versions with the :ref:`TensorFlow 1.15 documentation <cuda-training-deps>`.
|
||||||
|
|
||||||
Basic Dockerfile for training
|
Basic Dockerfile for training
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
@ -23,10 +23,10 @@ Running ``deepspeech`` might, see below, require some runtime dependencies to be
|
|||||||
|
|
||||||
Please refer to your system's documentation on how to install these dependencies.
|
Please refer to your system's documentation on how to install these dependencies.
|
||||||
|
|
||||||
.. _cuda-deps:
|
.. _cuda-inference-deps:
|
||||||
|
|
||||||
CUDA dependency
|
CUDA dependency (inference)
|
||||||
^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
The GPU capable builds (Python, NodeJS, C++, etc) depend on CUDA 10.1 and CuDNN v7.6.
|
The GPU capable builds (Python, NodeJS, C++, etc) depend on CUDA 10.1 and CuDNN v7.6.
|
||||||
|
|
||||||
@ -37,8 +37,8 @@ If you want to use the pre-trained English model for performing speech-to-text,
|
|||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
wget https://github.com/mozilla/DeepSpeech/releases/download/v0.7.4/deepspeech-0.7.4-models.pbmm
|
wget https://github.com/mozilla/DeepSpeech/releases/download/v0.9.1/deepspeech-0.9.1-models.pbmm
|
||||||
wget https://github.com/mozilla/DeepSpeech/releases/download/v0.7.4/deepspeech-0.7.4-models.scorer
|
wget https://github.com/mozilla/DeepSpeech/releases/download/v0.9.1/deepspeech-0.9.1-models.scorer
|
||||||
|
|
||||||
There are several pre-trained model files available in official releases. Files ending in ``.pbmm`` are compatible with clients and language bindings built against the standard TensorFlow runtime. Usually these packages are simply called ``deepspeech``. These files are also compatible with CUDA enabled clients and language bindings. These packages are usually called ``deepspeech-gpu``. Files ending in ``.tflite`` are compatible with clients and language bindings built against the `TensorFlow Lite runtime <https://www.tensorflow.org/lite/>`_. These models are optimized for size and performance in low power devices. On desktop platforms, the compatible packages are called ``deepspeech-tflite``. On Android and Raspberry Pi, we only publish TensorFlow Lite enabled packages, and they are simply called ``deepspeech``. You can see a full list of supported platforms and which TensorFlow runtime is supported at :ref:`supported-platforms-inference`.
|
There are several pre-trained model files available in official releases. Files ending in ``.pbmm`` are compatible with clients and language bindings built against the standard TensorFlow runtime. Usually these packages are simply called ``deepspeech``. These files are also compatible with CUDA enabled clients and language bindings. These packages are usually called ``deepspeech-gpu``. Files ending in ``.tflite`` are compatible with clients and language bindings built against the `TensorFlow Lite runtime <https://www.tensorflow.org/lite/>`_. These models are optimized for size and performance in low power devices. On desktop platforms, the compatible packages are called ``deepspeech-tflite``. On Android and Raspberry Pi, we only publish TensorFlow Lite enabled packages, and they are simply called ``deepspeech``. You can see a full list of supported platforms and which TensorFlow runtime is supported at :ref:`supported-platforms-inference`.
|
||||||
|
|
||||||
@ -136,7 +136,7 @@ Note: the following command assumes you `downloaded the pre-trained model <#gett
|
|||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
deepspeech --model deepspeech-0.7.4-models.pbmm --scorer deepspeech-0.7.4-models.scorer --audio my_audio_file.wav
|
deepspeech --model deepspeech-0.9.1-models.pbmm --scorer deepspeech-0.9.1-models.scorer --audio my_audio_file.wav
|
||||||
|
|
||||||
The ``--scorer`` argument is optional, and represents an external language model to be used when transcribing the audio.
|
The ``--scorer`` argument is optional, and represents an external language model to be used when transcribing the audio.
|
||||||
|
|
||||||
@ -200,7 +200,7 @@ Note: the following command assumes you `downloaded the pre-trained model <#gett
|
|||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
./deepspeech --model deepspeech-0.7.4-models.pbmm --scorer deepspeech-0.7.4-models.scorer --audio audio_input.wav
|
./deepspeech --model deepspeech-0.9.1-models.pbmm --scorer deepspeech-0.9.1-models.scorer --audio audio_input.wav
|
||||||
|
|
||||||
See the help output with ``./deepspeech -h`` for more details.
|
See the help output with ``./deepspeech -h`` for more details.
|
||||||
|
|
||||||
|
@ -20,15 +20,15 @@ To install and use DeepSpeech all you have to do is:
|
|||||||
pip3 install deepspeech
|
pip3 install deepspeech
|
||||||
|
|
||||||
# Download pre-trained English model files
|
# Download pre-trained English model files
|
||||||
curl -LO https://github.com/mozilla/DeepSpeech/releases/download/v0.7.4/deepspeech-0.7.4-models.pbmm
|
curl -LO https://github.com/mozilla/DeepSpeech/releases/download/v0.9.1/deepspeech-0.9.1-models.pbmm
|
||||||
curl -LO https://github.com/mozilla/DeepSpeech/releases/download/v0.7.4/deepspeech-0.7.4-models.scorer
|
curl -LO https://github.com/mozilla/DeepSpeech/releases/download/v0.9.1/deepspeech-0.9.1-models.scorer
|
||||||
|
|
||||||
# Download example audio files
|
# Download example audio files
|
||||||
curl -LO https://github.com/mozilla/DeepSpeech/releases/download/v0.7.4/audio-0.7.4.tar.gz
|
curl -LO https://github.com/mozilla/DeepSpeech/releases/download/v0.9.1/audio-0.9.1.tar.gz
|
||||||
tar xvf audio-0.7.4.tar.gz
|
tar xvf audio-0.9.1.tar.gz
|
||||||
|
|
||||||
# Transcribe an audio file
|
# Transcribe an audio file
|
||||||
deepspeech --model deepspeech-0.7.4-models.pbmm --scorer deepspeech-0.7.4-models.scorer --audio audio/2830-3980-0043.wav
|
deepspeech --model deepspeech-0.9.1-models.pbmm --scorer deepspeech-0.9.1-models.scorer --audio audio/2830-3980-0043.wav
|
||||||
|
|
||||||
A pre-trained English model is available for use and can be downloaded following the instructions in :ref:`the usage docs <usage-docs>`. For the latest release, including pre-trained models and checkpoints, `see the GitHub releases page <https://github.com/mozilla/DeepSpeech/releases/latest>`_.
|
A pre-trained English model is available for use and can be downloaded following the instructions in :ref:`the usage docs <usage-docs>`. For the latest release, including pre-trained models and checkpoints, `see the GitHub releases page <https://github.com/mozilla/DeepSpeech/releases/latest>`_.
|
||||||
|
|
||||||
@ -44,9 +44,9 @@ Quicker inference can be performed using a supported NVIDIA GPU on Linux. See th
|
|||||||
pip3 install deepspeech-gpu
|
pip3 install deepspeech-gpu
|
||||||
|
|
||||||
# Transcribe an audio file.
|
# Transcribe an audio file.
|
||||||
deepspeech --model deepspeech-0.7.4-models.pbmm --scorer deepspeech-0.7.4-models.scorer --audio audio/2830-3980-0043.wav
|
deepspeech --model deepspeech-0.9.1-models.pbmm --scorer deepspeech-0.9.1-models.scorer --audio audio/2830-3980-0043.wav
|
||||||
|
|
||||||
Please ensure you have the required :ref:`CUDA dependencies <cuda-deps>`.
|
Please ensure you have the required :ref:`CUDA dependencies <cuda-inference-deps>`.
|
||||||
|
|
||||||
See the output of ``deepspeech -h`` for more information on the use of ``deepspeech``. (If you experience problems running ``deepspeech``, please check :ref:`required runtime dependencies <runtime-deps>`).
|
See the output of ``deepspeech -h`` for more information on the use of ``deepspeech``. (If you experience problems running ``deepspeech``, please check :ref:`required runtime dependencies <runtime-deps>`).
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user