|
1 | 1 | # Docker DeepSpeech Server |
2 | | - |
3 | 2 | This is a dockerfile to serve a [deepspeech server](https://github.com/MainRo/deepspeech-server). |
4 | 3 |
|
5 | 4 | # How to use this image |
| 5 | +Create a deepspeech server configuration file as specified in config.example.yaml. Download and copy |
| 6 | +a model tflite and a scorer file and run the following command: |
6 | 7 |
|
7 | | - docker run -dt --name deepspeech -p 0.0.0.0:8080:8080 -v [host-model-path]:/opt/deepspeech romainsah/deepspeech-server:latest |
| 8 | + docker run -dt --name deepspeech \ |
| 9 | + -p 0.0.0.0:8080:8080 \ |
| 10 | + -v [host-model-path]:/opt/deepspeech \ |
| 11 | + romainsah/deepspeech-server:latest |
8 | 12 |
|
9 | 13 | where [host-model-path] is a host directory that contains the deepspeech server |
10 | | -configuration file, the model file, and the scorer file. |
| 14 | +configuration file (e.g. config.yaml), the model file (e.g. model.tflite), and the scorer file (e.g. huge-vocabulary.scorer). |
11 | 15 |
|
12 | 16 | ## Running on GPU |
| 17 | +Change the tag of the docker image in above command to latest-gpu, like this: |
| 18 | + |
| 19 | + docker run -dt --name deepspeech \ |
| 20 | + -p 0.0.0.0:8080:8080 \ |
| 21 | + -v [host-model-path]:/opt/deepspeech \ |
| 22 | + romainsah/deepspeech-server:latest-gpu |
| 23 | + |
| 24 | +## How to get the models |
| 25 | + |
| 26 | +The latest docker image was tested with the following model and scorer files: |
| 27 | + |
| 28 | +https://github.com/coqui-ai/STT-models/releases/download/english/coqui/v1.0.0-huge-vocab/model.tflite |
| 29 | + |
| 30 | +https://github.com/coqui-ai/STT-models/releases/download/english/coqui/v1.0.0-huge-vocab/huge-vocabulary.scorer |
| 31 | + |
| 32 | +## How to build this image |
13 | 33 |
|
14 | | - docker run -dt --gpus all --name deepspeech -p 0.0.0.0:8080:8080 -v [host-model-path]:/opt/deepspeech romainsah/deepspeech-server:latest-gpu |
| 34 | + cd cpu && \ |
| 35 | + docker build -t deepspeech-server:latest . |
15 | 36 |
|
| 37 | + cd gpu && \ |
| 38 | + docker build -t deepspeech-server:latest-gpu . |
0 commit comments