-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Build instructions for server
Eren Gölge edited this page Mar 11, 2020
·
1 revision
- Download the model
- Choose a model from our generated TTS models. You may listen to the audio samples to help you choose. If in doubt, choose the newest, that is the last in the list.
- Click on the link in the column "TTS models". This will be a download page, e.g. Google drive. Download the .tar file with the highest number and use it as "checkpoint" file in step 2. Also, download the config.json and use it as "model config".
- Build the package with the server and model
- Check out the source code from mozilla/TTS:
git clone git@github.com:mozilla/TTS.git
. If you chose an older model in step 1.1., you need to check out the corresponding server source code, from the column "commit". - Create a python environment for the build:
cd TTS; virtualenv -p python3 . ; source bin/activate
- Run
python setup.py bdist_wheel --checkpoint /path/to/checkpoint.tar --model_config /path/to/config.json
, with the model files that you downloaded in step 1.2. - This will create a new WHL in dist/ . This is a Python wheel package that contains both the server and the model.
cd ..
- Check out the source code from mozilla/TTS:
- Install and run the server
- Optional: Create a new python environment to run your server, with:
virtualenv -p python3 tacotron2
, whereas "tacetron" is a directory name that you can choose. Then, go into the new python environment:cd tacotron2; source bin/activate
. Alternatively, you may re-use the environment in your source directory. Note: You need to callsource bin/activate
every time you open a new console. - Install the server and model package that you just created in step 2.:
pip install ../TTS/dist/TTS-0.0.1+4f61539-py3-none-any.whl
(your filename will differ) - Run the server:
python -m TTS.server.server
- Open http://localhost:5002 in your browser.
- Optional: Create a new python environment to run your server, with: