Use this to create a docker image that runs the piper http_server on a NVIDIA GPU (a lot faster than CPU)
This is based on my fork of piper which uses fastapi for the server
https://hub.docker.com/r/notv3nom/piper-http-gpu
This image uses lessac-high voice
docker run -d --gpus all --ipc=host --ulimit memlock=-1 --ulimit stack=67108864 --name piper-http-gpu -p 5000:5000 notv3nom/piper-http-gpu
-
Clone this repository
-
Create a models folder and add your .onnx and .onnx.json
-
Update the model name in Dockerfile
-
Build the image
docker build --no-cache -t piper-gpu .
-
Run the image
docker run -d --gpus all --ipc=host --ulimit memlock=-1 --ulimit stack=67108864 --name piper-gpu -p 5000:5000 piper-gpu