Skip to content
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

Python Basics Example/Demo #37

Open
HarrisonSteel opened this issue May 1, 2023 · 1 comment
Open

Python Basics Example/Demo #37

HarrisonSteel opened this issue May 1, 2023 · 1 comment

Comments

@HarrisonSteel
Copy link

HarrisonSteel commented May 1, 2023

Hi Team,
I ended up here from browsing HackerNews where many people were looking for open-source TTS software packages: https://news.ycombinator.com/item?id=34211457
I started having a go with OpenTTS but was significantly slowed down since I could not quickly find a nice basic python implementation showing exactly how to get it up and running (i.e. in python read aloud "hello world" in one of the many voices). Is there any possibility of such a thing being put on the repo for people to build upon, rather than the html interface focus at present?

@KMouratidis
Copy link

I used the docker container in Windows WSL and query it from the host like this:

import requests

resp = requests.get(
    "http://localhost:5500/api/tts",
    params={
        "voice": "coqui-tts:en_vctk",
        "text": "I started having a go with OpenTTS but was significantly slowed down since I could not quickly find a nice basic python implementation.",
        "speakerId": "p228",
        "lang": "en"
    }
)

# Write it on disk or something
with open("file.wav", "wb") as f:
    f.write(resp.content)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants