Excellent video, thank you Thorsten! A member of the Piper community has created a new streaming mode for Piper that I hope to get released soon. The current streaming mode only works on sentences, but his will start outputting audio in around 100 ms :)
Thanks for that information, that is actually THE feature I was waiting for. I love piper, but for a 'realtime' llm chat it takes a bit too long to process a longer text.
If somebody is trying this right now, with the current pre-release (2023.11.14-2), you'll need to add also the model config file's path to the command, or it won't work (and the worst thing is that you won't get an error message, so you won't know what's happening ^^U). Here's an example of what you'll need to input for it to work: echo "Hello, this is a test using Piper TTS." | piper.exe -m en_US-kathleen-low.onnx -c en_en_US_kathleen_low_en_US-kathleen-low.onnx.json -f test1.wav As always, thank you very much for your great videos! :D
@@ThorstenMueller sadly no, as the above user says no error message is displayed when something goes wrong, I run with --debug too and nothing i tried running ps as admin too
It's great that these models are making progress. I'm still surprised that open source models have less consistency in the output than 15+ yr old model like Microsoft Zira.
I love the results-driven adjustment to your script. (Seeing/hearing the end result at the beginning was great.) I've really wanted to export some of my epub books into audiobooks and this looks like one of the first steps. Thanks for all you do Thorsten.
Freut mich, dass Dir das Video gefällt 😊. Gute Frage wegen Untertitel Dateien. Vielleicht sollte ich mir das mal anschauen - klingt auf jeden Fall spannend 🤔. Müsste mir mal eine SRT/SBV Datei anschauen.
Hallo Thorsten, ich muss Dir dreifach DANKEN. 1. Habe mit Piper genau die AI Anwendung gefunden die ich schon lange gesucht habe. 2. Danke für Deine super Piper Stimme und vielen danke für Deine Arbeit und Bemühungen. 3. Habe nun selber ein RUclips Kanal und verwende dafür Deine Stimme :-) Natürlich erwähne ich Dich in jedem Video. Siehe @MundusInfo | www.youtube.com/@MundusInfo
Hallo, dann sage ich Dir dreifach GERN GESCHEHEN 😊. Es war tatsächlich eine lange Reise, bis ich mit meiner Thorsten-Voice TTS Stimme zufrieden war. Umso mehr freut es mich, wenn meine Stimme als nützlich empfunden wird.
Thanks for the video! Any suggestions on introducing better natural pauses within the text to slow down voice? It doesn't seem to respond much to commas and periods.
Great video Thorsten! I was hoping at some point that you would explain how to implement this into a python project since the documentation is pretty limited? That would be amazing.
🎯 Key Takeaways for quick navigation: - Introduction to Piper TTS - Description of Piper TTS - Link to related Piper TTS videos - Downloading the Piper TTS Windows installer - Extracting the Piper TTS files - Copying the Piper TTS files to a desired location - Checking the Piper TTS directory contents - Opening a PowerShell window - Navigating to the Piper TTS directory - Running the Piper TTS help command - Understanding the required arguments for Piper TTS - Downloading the Piper TTS English US Castline TTS model files (.onnx and .json) - Saving the downloaded TTS model files to the Downloads folder - Copying the downloaded TTS model files to the Piper TTS directory - Echoing test text to the standard input - Piping the echoed text to the Piper TTS command - Providing the downloaded TTS model file name as an argument to Piper TTS - Running the Piper TTS command - Generating test audio using Piper TTS - Specifying output filename using the -F parameter - Observing real-time audio generation speed - Downloading a different Piper TTS voice model (English US Castline High) - Generating test audio using the new voice model and saving it as test2.wav - Observing the difference in voice quality between the two models - Creating a text file (demo.txt) with longer content - Using the cat command to pass the contents of demo.txt to Piper TTS - Generating test audio (test3.wav) from the contents of demo.txt - Recap of the process for using Piper TTS on Windows - Encouragement to subscribe to the Thorsten Voice RUclips channel - Invitation to share feedback on the video Made with HARPA AI
hey there thorsten i just came across your channel and it so amziang i get the stuffs i as looking for ,these tts model but i have a question iis there a one where he nvidia graphics card is not necessary and it sounds very much human like with easy setup and probably a ui. thank you
If this do not work for you and the one in the description does not work, try this (no * start and .\ before piper.exe) : echo "Hello, this is a test using Piper TTS." | .\piper.exe -m en_US-kathleen-low.onnx -c en_en_US_kathleen_low_en_US-kathleen-low.onnx.json -f test1.wav Also, you can right click in your folder and chose the option "open in the terminal" so you will not need to do the "cd" part to move inside your folder!
Ich habe Piper TTS mit mycroft-ai Mimic3 verglichen und kann bei der gleichen Stimme keinen Unterschied feststellen. Gibt es irgendwelche Vorteile von Piper TTS die einen Umstieg interessant machen könnten?
It gets 5 stars from me due to simple install and running. Voices are pretty ok, certainly good enough for what what I wanted to use it for. Now for the next challenge. How to create new voices for it. :) - Would have been cool if there was some online tool for it.
I guess you already know my tutorial on how to create your own cloned voice for Piper TTS, or 😊? ruclips.net/video/b_we_jma220/видео.htmlsi=FV-6UatCjN4f8a4Z
@@ThorstenMueller , yes I have just integrated Piper-TTS in a Unity VR "sandbox" app I am working on now and it works brilliantly. Definitely need to see if I can get some more voices or train new ones although the task of creating those datasets seems rather daunting. I hope someone creates a repository of voices (even paid ones) to use with Piper-TTS as I feel it is more than good enough for a lot of applications.
Awesome tutorial! I followed all of the steps, but I'm running into a problem. The program runs, but it doesn't give any output. It doesn't matter if I try to stream to stdout, or if I try to write to a file. The program runs and nothing happens. Any idea what might be going wrong? I'm running the latest version on windows, btw.
Hey thorsten ! I would like to ask you, i am trying to find a free realistic male voice for tts in python (i dont mind being locally) Do you have any suggestions ??
I have compared Piper TTS with mycroft-ai Mimic3 and can't tell any difference with the same voice. Are there any advantages of Piper TTS that might make a switch interesting?
Might be the reason that the developer of Mimic3 is the same as the main developer of Piper TTS 😁. Personally i'd prefer Piper TTS because there's more active development. For example there will be a streaming feature in nearer future 😊.
@@ThorstenMueller I have now experimented with it and realised that Piper is really much more advanced than Mimic3. It is faster thanks to better multi-core support (RTF 0.06 with a very old Intel i5 4670), uses only a fifth of the RAM memory, makes fewer errors, can handle larger text files and audio books with significantly more than 1,000,000 characters and, with the --model en_US-libritts_r-medium.onnx, has an incredible number of very good voices that can compete in the pronunciation quality with coqui-ai TTS. I am impressed! Thanks for the video and for pointing out Piper.
Here is an example of text file input, for example for audio books of any size: ./piper --model en_US-libritts_r-medium.onnx --speaker 341 --sentence-silence 0.6 --length-scale 1.3 --output_file ./audiobook.wav < ./text.txt (Note: -sentence-silence and --length-scale can be dropped, but for my taste the voice then speaks too fast.)
you mention "piper is It is faster thanks to better multi-core support" if i train on specific voice dataset and use case only need one type of voice will i be able to run it on a mobile device?
I wish there was just a simple download executable that would install everything on Windows 11. This seems like you'd need a degree in computer science to get it running.
I guess a solid computer knowledge is not too bad to get it set up. Maybe there will be more easy ways to set it up in future - but i guess it's not too soon on their roadmap. Maybe ask on an easier way on Piper github community to get it more into the spotlight.
Didn't try it myself, but there's some discussion on CUDA (nvidia gpu) on their repository. Maybe you can find additional info there 😊. github.com/rhasspy/piper/issues?q=is%3Aissue+cuda
hi .tnx4da hlp. question: how long can input file "demo.txt" be? and for 1 minute of high quality wav file, how much space occupied on the storage device in MegaBytes? tnx
I'm not sure if there's a hard limit on text input, but obviously it'll take more time to compute when inputting longer text. I guess disk space is really low for one minute of audio in 22kHz samplerate. Guessing 3-5 megabyte
IMHO Piper TTS does not yet support SSML. Maybe there's a way to add phonetical stress by adjusting eSpeak dictionary. Do you know this video? ruclips.net/video/493xbPIQBSU/видео.htmlsi=XbNJcOy7JODR7ome
Technically i guess yes. Depends on the training voice data. Maybe cartoon voices are not "neutral" enough and have too much voice variation in it to create a consistent tts voice. And of course you have to think about licences when using foreign voices.
You're welcome 😊. I encountered problems running Piper TTS on m1, too but had not time to give it a closer look. Have you already asked on Piper community? Maybe there's someone who got it working already.
Yes! I've found this video at last!! :) Thank you very much indeed, friend, for your wonderful video tutorial! Everything is clear explained. Finally, my dream is soooo close to be realized! :) (a few moments later...) Unfortunately, it cannot convert a russian (cyrillic) text to *.wav file :( Just wrote: "Real-time factor: 5.776e-321 (infer=0 sec, audio=0 sec)" and created an empty *.wav file.
@@Lc9real I've chatted with Mike about native Python integration and there's seems to be room for improvement. So maybe keep an eye on that for future upcoming updates.
@@faizanibrahim8320 ./piper --model en_US-libritts_r-medium.onnx --speaker 341 --sentence-silence 0.6 --length-scale 1.3 --output_file ./audiobook.wav < ./text.txt Where "--sentence-silence" is the pause in seconds after each sentence and "--length-scale" is the inversely proportional speed factor. 0.5= double reading speed, 2.0= half reading speed.
Helo sir, thank you I already practice with this tutorial, succes i can make voice. wtih this TTS. I have question. write what letters or what code in the txt file, to produce a pause in the voice results. For example, I have 2 paragraphs in the text file, but between the paragraphs I want there to be a 3 second pause in the voice results. So in the audio voice file, he reads paragraph 1, then pauses 3 seconds, then reads the second paragraph again. in this example, I place code DDDD. ( but audio result , say DDDD , I want result a pause 3 second on code DDDD ) The story begins with a spaceship returning to Earth. However, the spacecraft encounters an error, causing it to crash into a forest in Malaysia. DDDD The spaceship belongs to a company called Life Foundation, led by an ambitious man named Drake. The spaceship was carrying samples of extraterrestrial life, prompting Drake to urge his team to quickly gather all the salvageable samples. DDDD Out of all the crew members found, only the pilot survived. Medical personnel quickly transported him to an ambulance. However, suddenly... DDDD Yes, an entity possessed the pilot's body and then transferred to a medical staff member. The entity saw the Life Foundation logo and intended to go to the company's location. DDDD Upon arriving at the outskirts of the city, the entity possessing the medical staff member grabbed a catfish and ate it alive, terrifying everyone around. Eventually, the local thugs approached to confront the entity. But... DDDD Feeling that its current host was no longer suitable, the entity transferred to the body of an elderly woman, instantly revitalizing her. The entity then headed to the airport to find another host bound for America, which happened to be a little girl. And thus, Venom begins.
In general i would go with Piper, because it's both developed by the same person, but Mimic isn't active in development any more, but Piper is. But IMHO both is not supported on Mobile, yet.
i would like to use piper but with my own voice, like training it with lots of audios. Im from argentina i need it to speak spanish, what i´ve seen is the hardest is the accent
Yes as a phonemizer. A LLM that can turn text into phonics would be interesting. I can't find a good collection of phonics sound samples. Which could be used for experimenting.
@@WorldOLuxury Okay, i have not used it for adjusting speed myself so i have no practical experiences. It's on my (growing) TODO list. Maybe you want to ask this question on Piper or Coqui TTS community. Maybe there's some practical experiences.
piper -h shows these parameters available to adjust the output: --length_scale NUM phoneme length (default: 1.0) --noise_w NUM phoneme width noise (default: 0.8) --sentence_silence NUM seconds of silence after each sentence (default: 0.2)
IMHO opinion i guess this is not possible by now. I tried integrating Piper to Windows SAPI, which could help on that use case, but this didn't work yet.
@@ThorstenMueller, I would like to use Piper to reproduce the text I select as I read the document. My intention is to play the Piper parallel to my reading of an article, for example, in order to facilitate my concentration on the reading. It doesn't need to be in Microsoft Word. The "Read Aloud: A Text to Speech Voice Reader" extension provides something similar, but is buggy regarding Pitch. I found the "Balabolka" interface, but I couldn't install the Piper voice in it. I have some knowledge in IT, but using Piper is something very advanced for me.
Bro how to create text to speech and voice cloning multilingual model like eleven labs and deploy it has a website or app. Can you make a video for that please ❤...
@ThorstenMueller CMDbut I already wrote a python script that uses a subprocessimport os import subprocess import argparse def run_speech_generation(text, model_name, json_name, output_file): os.chdir('C:/piper') command = f'echo "{text}" | .\\piper.exe -m {model_name} -c {json_name} -f {output_file}' subprocess.run(command, shell=True)and now I generate speech through python programsthanks for tutorial BTW 🤝👍🙏
@@Владик-щ8ъ Okay, maybe it's worth to post this on Piper TTS Github repo (github.com/rhasspy/piper/issues). I guess there are more (experienced) people that might be able to support you on this.
@@ThorstenMueller We want to run this on an A100. can it convert in less than 50 MS? also, are you the lead dev? i have some questions. maybe we can email each other if that is ok
Should work in general. I'm not sure if there's any arabic model available yet. You can see all models here: github.com/coqui-ai/TTS/blob/dev/TTS/.models.json Maybe it's worth to ask on their community for arabic support.
After literally wasting "hours" of trying to make it work, on different Windows system, trying all the switches, options, way to use them, its a total failure to a point. Fuck this garbage and fuck whoever did this awful Windows port.
It always amazes me how entitled some people feel about things they get for free. It worked flawlessly for me, but depending on the model you downloaded, if the config filename doesn't match the model filename, you might have to manually specify it.
Hi thorsten is this still working because when i run this command "echo "Hello, this is a test using Piper TTS." | .\piper.exe -m en_US-kathleen-low.onnx -f test1.wav" there is no output
Make sure that your config file has the same name as the model file. I noticed that all the ones I've downloaded so far have duplicated filenames, like "en_en_US_kathleen_low_en_US-kathleen-low.onnx.json". Either rename the config file to match the model file, or manually specify it with the --config trigger.
So, I have just given this a go, followed all the steps, running Powershell as Administrator and it wouldn't produce just goes back to C:\Ai\piper folder... C:\Ai\piper> echo "Hello this is a test of piper TTS." Hello this is a test of piper TTS. C:\Ai\piper> echo "Hello this is a test of piper TTS." | .\piper.exe -m .\en_US-lessac-high.onnx -f test1.wav C:\Ai\piper> And that's it, tried with multiple voices, read through the comments saying you also need to use the model, so have the model in the folder as well tried with Kathleen low voice as well using the command in the description for her voice C:\Ai\piper> echo "Hello, this is a test using Piper TTS." | .\piper.exe -m en_US-kathleen-low.onnx -c en_en_US_kathleen_low_en_US-kathleen-low.onnx.json -f test1.wav C:\Ai\piper> Nada. Other issue is, even if it did somehow work, it's a lot of faffing around just for a line of audio. Just want to be able to clone my voice and my friends voice from prerecorded clean audio, and be able to produce a podcast without us actually having to do any talking. I don't think Piper is going to be the answer on this one, Tried Tortoise TTs, it was ok, but outputs were generally either quite a way off, or different pitches altogether, want something like Tortoise TTs that is user friendly, but one that actually works. What do you suggest, has to be locally, not paying anyone like Elevenlabs. Can do it all on my gaming computer.
Not sure where I went wrong. echo 'Welcome to the world of speech synthesis!' | ./piper.exe --model en_US-lessac-medium.onnx --output_file welcome.wav has no output on windows it does something for a second but no output in the shell or in the folder. I have powershell open inside of the directory that I extracted the zip file to. ./piper.exe --help does work
Thanks for your comment and reply 😊. Normally piper should detect config file automatically if their name is identical to model file (+ json) if it's in the same directory. Does it generate audio then or still produce no output?
@@ThorstenMuellerI finally found the issue after getting it to work on another computer. The model files I downloaded corrupted at some point. After redownloading them it works.
Excellent video, thank you Thorsten! A member of the Piper community has created a new streaming mode for Piper that I hope to get released soon. The current streaming mode only works on sentences, but his will start outputting audio in around 100 ms :)
Thanks for that information, that is actually THE feature I was waiting for. I love piper, but for a 'realtime' llm chat it takes a bit too long to process a longer text.
Thanks for your kind feedback, Mike 😊. Excited to give the coming streaming-feature a try in future.
please can you give me link how can use piper-tts with python
It looks like the streaming mode is now available! I don't suppose we can get a tutorial on how to use it?
Especially on how to play the stream on Windows as the example code utilizes a Linux tool to play the audio stream.
If somebody is trying this right now, with the current pre-release (2023.11.14-2), you'll need to add also the model config file's path to the command, or it won't work (and the worst thing is that you won't get an error message, so you won't know what's happening ^^U).
Here's an example of what you'll need to input for it to work:
echo "Hello, this is a test using Piper TTS." | piper.exe -m en_US-kathleen-low.onnx -c en_en_US_kathleen_low_en_US-kathleen-low.onnx.json -f test1.wav
As always, thank you very much for your great videos! :D
Thanks for your really helpful command 😊. I added your hint to the video description and tagged you - hope this is okay.
even with that command i can not get any wav file to be created will try on the pi
@@justinanthony8858 Is any error message shown?
@@ThorstenMueller sadly no, as the above user says no error message is displayed when something goes wrong, I run with --debug too and nothing i tried running ps as admin too
Yes - this worked for me. Thanks!
It's great that these models are making progress. I'm still surprised that open source models have less consistency in the output than 15+ yr old model like Microsoft Zira.
I'm happy too to see open source TTS models making progress on quality and performance. I'm not sure what you mean with "consistency" in this context.
I love the results-driven adjustment to your script. (Seeing/hearing the end result at the beginning was great.) I've really wanted to export some of my epub books into audiobooks and this looks like one of the first steps.
Thanks for all you do Thorsten.
Thanks for your great feedback 😊.
This has been the first genuinely helpful video I've found on running an A.I text to speech model locally, thank you sir!
Thanks for your kind feedback 😊.
Hey Thorsten, danke für dieses und die anderen Tutorials!
Hi 👋, vielen Dank für deinen netten Kommentar und sehr gerne 😊.
Hallo Thorsten, schönes Video! Klappt das auch mit srt oder sbv Dateien? VG Anton
Freut mich, dass Dir das Video gefällt 😊. Gute Frage wegen Untertitel Dateien. Vielleicht sollte ich mir das mal anschauen - klingt auf jeden Fall spannend 🤔. Müsste mir mal eine SRT/SBV Datei anschauen.
Hallo Thorsten, ich muss Dir dreifach DANKEN.
1. Habe mit Piper genau die AI Anwendung gefunden die ich schon lange gesucht habe.
2. Danke für Deine super Piper Stimme und vielen danke für Deine Arbeit und Bemühungen.
3. Habe nun selber ein RUclips Kanal und verwende dafür Deine Stimme :-) Natürlich erwähne ich Dich in jedem Video.
Siehe @MundusInfo | www.youtube.com/@MundusInfo
Hallo, dann sage ich Dir dreifach GERN GESCHEHEN 😊.
Es war tatsächlich eine lange Reise, bis ich mit meiner Thorsten-Voice TTS Stimme zufrieden war. Umso mehr freut es mich, wenn meine Stimme als nützlich empfunden wird.
Thank you very much for this excellent and very easy to follow tutorial!
Thanks for your amazing feedback 😊 and you are welcome.
I love how you say it's "super simple" at the end. Well, now it is because you just showed us all how to do it! Thank you!
Thanks a lot for your very nice feedback 😊. Happy you found my video helpful so now it's "super simple" for you too ;-).
Thanks for the video! Any suggestions on introducing better natural pauses within the text to slow down voice? It doesn't seem to respond much to commas and periods.
Imho the Piper TTS project is working on ssml support which should be helpful for that. But i am unsure on their roadmap.
@@ThorstenMueller thank you!
This is great, I installed for my home assistant! Do you know how I could use it for twitch chat tts?
Thanks for your feedback 😊. Not yet, but using Piper for Twitch is on my (long) TODO list.
Great video Thorsten! I was hoping at some point that you would explain how to implement this into a python project since the documentation is pretty limited? That would be amazing.
Using Piper TTS in Python in one of my questions for my interview with the creator, Michael.
@@ThorstenMueller this would be really helpful. I have GTTS working, but want to pull it out and put in piper. thx for your hard work.
🎯 Key Takeaways for quick navigation:
- Introduction to Piper TTS
- Description of Piper TTS
- Link to related Piper TTS videos
- Downloading the Piper TTS Windows installer
- Extracting the Piper TTS files
- Copying the Piper TTS files to a desired location
- Checking the Piper TTS directory contents
- Opening a PowerShell window
- Navigating to the Piper TTS directory
- Running the Piper TTS help command
- Understanding the required arguments for Piper TTS
- Downloading the Piper TTS English US Castline TTS model files (.onnx and .json)
- Saving the downloaded TTS model files to the Downloads folder
- Copying the downloaded TTS model files to the Piper TTS directory
- Echoing test text to the standard input
- Piping the echoed text to the Piper TTS command
- Providing the downloaded TTS model file name as an argument to Piper TTS
- Running the Piper TTS command
- Generating test audio using Piper TTS
- Specifying output filename using the -F parameter
- Observing real-time audio generation speed
- Downloading a different Piper TTS voice model (English US Castline High)
- Generating test audio using the new voice model and saving it as test2.wav
- Observing the difference in voice quality between the two models
- Creating a text file (demo.txt) with longer content
- Using the cat command to pass the contents of demo.txt to Piper TTS
- Generating test audio (test3.wav) from the contents of demo.txt
- Recap of the process for using Piper TTS on Windows
- Encouragement to subscribe to the Thorsten Voice RUclips channel
- Invitation to share feedback on the video
Made with HARPA AI
Thanks for sharing 👏😊.
hey there thorsten i just came across your channel and it so amziang i get the stuffs i as looking for ,these tts model but i have a question iis there a one where he nvidia graphics card is not necessary and it sounds very much human like with easy setup and probably a ui. thank you
Not sure on the ui aspect but Piper tts works well on cpu. So not (nvidia) gpu required.
If this do not work for you and the one in the description does not work, try this (no * start and .\ before piper.exe) :
echo "Hello, this is a test using Piper TTS." | .\piper.exe -m en_US-kathleen-low.onnx -c en_en_US_kathleen_low_en_US-kathleen-low.onnx.json -f test1.wav
Also, you can right click in your folder and chose the option "open in the terminal" so you will not need to do the "cd" part to move inside your folder!
Thanks for your good additional info. I've added it to the video description and linked your profile - Thanks 😊.
THANKSS
Ich habe Piper TTS mit mycroft-ai Mimic3 verglichen und kann bei der gleichen Stimme keinen Unterschied feststellen. Gibt es irgendwelche Vorteile von Piper TTS die einen Umstieg interessant machen könnten?
Ich habe mal auf deinen englischen Kommentar geantwortet 😊.
How do I train models on my computer wth this or how do I convert a pth model to onnx
Do you know my tutorial on how to create your own AI voice with Piper TTS?
ruclips.net/video/b_we_jma220/видео.htmlsi=00Y1-7IS7WV514VY
It gets 5 stars from me due to simple install and running. Voices are pretty ok, certainly good enough for what what I wanted to use it for. Now for the next challenge. How to create new voices for it. :) - Would have been cool if there was some online tool for it.
I guess you already know my tutorial on how to create your own cloned voice for Piper TTS, or 😊? ruclips.net/video/b_we_jma220/видео.htmlsi=FV-6UatCjN4f8a4Z
@@ThorstenMueller , yes I have just integrated Piper-TTS in a Unity VR "sandbox" app I am working on now and it works brilliantly. Definitely need to see if I can get some more voices or train new ones although the task of creating those datasets seems rather daunting. I hope someone creates a repository of voices (even paid ones) to use with Piper-TTS as I feel it is more than good enough for a lot of applications.
Is it possible to compile it to webassembly to be able to use in a chrome extension for read aloud (text to speech) as offline voices?
That is a great idea 👍. Did you suggest that on their project community?
@@ThorstenMueller No I didn't
@@tahasoft1 Maybe that's worth a try to reach more Piper TTS developers that might make this possible.
Awesome tutorial! I followed all of the steps, but I'm running into a problem. The program runs, but it doesn't give any output. It doesn't matter if I try to stream to stdout, or if I try to write to a file. The program runs and nothing happens. Any idea what might be going wrong? I'm running the latest version on windows, btw.
Never mind, I found the command in your description, that fixed it.
Happy you got it working 😊.
Hello, what was your problem and how did you fix it?
I'm having the same problem, CMD says piper tries to access a pipe that doesn't exist
I found the problem XD
I used the command in the comment of @juanjesusligero391 and it worked now
The fix isn't in the german description I think
@@TheRealThomcat Thanks for your hint - you're right 😊. I've added it to the german description, too.
Hey thorsten ! I would like to ask you, i am trying to find a free realistic male voice for tts in python (i dont mind being locally) Do you have any suggestions ??
Have you checked existing Coqui / Piper TTS models? I know about a female voice, but am not sure if they have a male voice?
I have compared Piper TTS with mycroft-ai Mimic3 and can't tell any difference with the same voice. Are there any advantages of Piper TTS that might make a switch interesting?
Might be the reason that the developer of Mimic3 is the same as the main developer of Piper TTS 😁. Personally i'd prefer Piper TTS because there's more active development. For example there will be a streaming feature in nearer future 😊.
@@ThorstenMueller I have now experimented with it and realised that Piper is really much more advanced than Mimic3. It is faster thanks to better multi-core support (RTF 0.06 with a very old Intel i5 4670), uses only a fifth of the RAM memory, makes fewer errors, can handle larger text files and audio books with significantly more than 1,000,000 characters and, with the --model en_US-libritts_r-medium.onnx, has an incredible number of very good voices that can compete in the pronunciation quality with coqui-ai TTS. I am impressed! Thanks for the video and for pointing out Piper.
Here is an example of text file input, for example for audio books of any size:
./piper --model en_US-libritts_r-medium.onnx --speaker 341 --sentence-silence 0.6 --length-scale 1.3 --output_file ./audiobook.wav < ./text.txt
(Note: -sentence-silence and --length-scale can be dropped, but for my taste the voice then speaks too fast.)
@@patrick3273 Happy to hear that you made really good experience with Piper TTS :).
you mention "piper is It is faster thanks to better multi-core support" if i train on specific voice dataset and use case only need one type of voice will i be able to run it on a mobile device?
I wish there was just a simple download executable that would install everything on Windows 11. This seems like you'd need a degree in computer science to get it running.
I guess a solid computer knowledge is not too bad to get it set up. Maybe there will be more easy ways to set it up in future - but i guess it's not too soon on their roadmap. Maybe ask on an easier way on Piper github community to get it more into the spotlight.
is there a way to use this with nvidia gpu on windows to speed up performance?
Didn't try it myself, but there's some discussion on CUDA (nvidia gpu) on their repository. Maybe you can find additional info there 😊.
github.com/rhasspy/piper/issues?q=is%3Aissue+cuda
I have been trying to implement the video but the executed command shows nothing no error no results. Does piper still work? I am on windows 11 also
Strange, does it show help output when running with "--help"? Or no output in general?
@@ThorstenMueller when using --help it shows the commands
but when running the echo command with piper the log is empty
i don't know if thats a version issue ? i have the latest version installed
OH okay it worked i just a comment that i needed to add the config file also with the model
@@mohdgh7394 Thanks for your helpful feedback, i've added that hint to the english and german description 😊.
Hi, Sorry I am arriving very late, but I am trying to get my clone to attend for me !
;)
hi .tnx4da hlp.
question:
how long can input file "demo.txt" be?
and for 1 minute of high quality wav file, how much space occupied on the storage device in MegaBytes?
tnx
I'm not sure if there's a hard limit on text input, but obviously it'll take more time to compute when inputting longer text. I guess disk space is really low for one minute of audio in 22kHz samplerate. Guessing 3-5 megabyte
I have been trying all kinds off tts, I am not able to get any to work, I ran the terminal command like u showed and its returning nothing
Even the parameter "--help" does not show anything?
hi that didnt work for me i dont know whay
Sorry to hear that, is there any error message shown?
Can Piper TTS be used for audiobooks?
You mean technically or by license?
@@ThorstenMueller Both. But, it would be for personal use.
@@Nightman-eb8mj I guess, this should be work and be ok (IMHO). You might have to split longer texts into multiple chunks to make it synthesized.
While testing Piper-tts, I couldn't find a way to put the stress in word. Maybe there is some way to do this?
IMHO Piper TTS does not yet support SSML. Maybe there's a way to add phonetical stress by adjusting eSpeak dictionary. Do you know this video? ruclips.net/video/493xbPIQBSU/видео.htmlsi=XbNJcOy7JODR7ome
Can i also use any cartoon character's voice ?
Technically i guess yes. Depends on the training voice data. Maybe cartoon voices are not "neutral" enough and have too much voice variation in it to create a consistent tts voice. And of course you have to think about licences when using foreign voices.
Thank you so much. I am using macbook m1. Can you help me make piper TTS on Macbook m1?. Thank you.
You're welcome 😊. I encountered problems running Piper TTS on m1, too but had not time to give it a closer look. Have you already asked on Piper community? Maybe there's someone who got it working already.
Hi, 😊, for an assistant I would need to stream the piper output so it starts immediately to speak. How can I do that in windows?
Playing around with streaming feature in piper tts is still on my todo list, so i have no practical experience on that (yet) 🙂.
Yes! I've found this video at last!! :) Thank you very much indeed, friend, for your wonderful video tutorial! Everything is clear explained. Finally, my dream is soooo close to be realized! :)
(a few moments later...) Unfortunately, it cannot convert a russian (cyrillic) text to *.wav file :( Just wrote: "Real-time factor: 5.776e-321 (infer=0 sec, audio=0 sec)" and created an empty *.wav file.
Ah, oops, i just replied to your other comment. So ignore my other comment 😆 as you already found "the right" video for you.
No matter which voice I use, I get the error message, that version 14 is not supported, "only version1 to 10 is supported in this version".
Good question 🤔. Have you asked on Piper community? github.com/rhasspy/piper/issues
Is it possible to use it in a Python script?
Making a tutorial on using Piper TTS in Python is on my TODO list on a very high (soon) position 😊.
@@ThorstenMueller Ok good to know because i tried using the pip command on the github but I kept getting an error
@@Lc9real I've chatted with Mike about native Python integration and there's seems to be room for improvement. So maybe keep an eye on that for future upcoming updates.
Not the most natural, but a more distinctive and faster tts voice compared to Microsoft Azure and Google Cloud.
And there's a bunch of available voices to choose from. Maybe there's a voice that feels more natural to you 😊.
@OpinionatedReviewer Try --model en_US-libritts_r-medium.onnx --speaker 7 or -speaker 341. Very natural ! There are also many more natural voices.
@@patrick3273 how to adjust tye speed , like i want to narrate it on slower speed
@@faizanibrahim8320 ./piper --model en_US-libritts_r-medium.onnx --speaker 341 --sentence-silence 0.6 --length-scale 1.3 --output_file ./audiobook.wav < ./text.txt
Where "--sentence-silence" is the pause in seconds after each sentence and "--length-scale" is the inversely proportional speed factor. 0.5= double reading speed, 2.0= half reading speed.
@@faizanibrahim8320 I saw this in the github repo
--length_scale 1.0 (this is the default speed, lower value = faster) after model name.
Helo sir, thank you I already practice with this tutorial, succes i can make voice. wtih this TTS.
I have question.
write what letters or what code in the txt file, to produce a pause in the voice results.
For example, I have 2 paragraphs in the text file, but between the paragraphs I want there to be a 3 second pause in the voice results.
So in the audio voice file, he reads paragraph 1, then pauses 3 seconds, then reads the second paragraph again.
in this example, I place code DDDD. ( but audio result , say DDDD , I want result a pause 3 second on code DDDD )
The story begins with a spaceship returning to Earth. However, the spacecraft encounters an error, causing it to crash into a forest in Malaysia.
DDDD
The spaceship belongs to a company called Life Foundation, led by an ambitious man named Drake. The spaceship was carrying samples of extraterrestrial life, prompting Drake to urge his team to quickly gather all the salvageable samples.
DDDD
Out of all the crew members found, only the pilot survived. Medical personnel quickly transported him to an ambulance. However, suddenly...
DDDD
Yes, an entity possessed the pilot's body and then transferred to a medical staff member. The entity saw the Life Foundation logo and intended to go to the company's location.
DDDD
Upon arriving at the outskirts of the city, the entity possessing the medical staff member grabbed a catfish and ate it alive, terrifying everyone around. Eventually, the local thugs approached to confront the entity. But...
DDDD
Feeling that its current host was no longer suitable, the entity transferred to the body of an elderly woman, instantly revitalizing her. The entity then headed to the airport to find another host bound for America, which happened to be a little girl. And thus, Venom begins.
IMHO piper tts is about to add ssml support. With that you can add breaks and more as xml notation to your text input.
Unfortunately, on that website, there are no Indonesian speakers, could you add it to the website so there are Indonesian speakers?
Do you ask on providing an Indonesian tts model or is there already a model and it's just not listed on their website?
PLease TELLL me which one is faster piper or mimic tts and will any of them work on Mobile?? app
In general i would go with Piper, because it's both developed by the same person, but Mimic isn't active in development any more, but Piper is. But IMHO both is not supported on Mobile, yet.
i would like to use piper but with my own voice, like training it with lots of audios. Im from argentina i need it to speak spanish, what i´ve seen is the hardest is the accent
Good luck with creating your own TTS voice with Piper 😊.
i need more georgian voices. there is only Natia(woman) voice (
how can i make them? any tut?
If you have a useable voice dataset for georgian, you can use this tutorial: ruclips.net/video/b_we_jma220/видео.htmlsi=iRIGUkAKf_7gWkRF
@@ThorstenMueller thanks
What's the speed of espeak?
You mean as a phonemizer or their robotic (mbrola) voices? Either way it is really super fast (on small compute devices).
Yes as a phonemizer. A LLM that can turn text into phonics would be interesting. I can't find a good collection of phonics sound samples. Which could be used for experimenting.
Arduino talkie is fun. And software 'praat' might be worth looking at.
How we can adjust the speed of voice..?? Eg slow and fast??? Whats tge command or something like that
Maybe you can use pydub or ffmpeg to adjust generated audio.
i have used both it doesnt work @@ThorstenMueller
@@WorldOLuxury Okay, i have not used it for adjusting speed myself so i have no practical experiences. It's on my (growing) TODO list. Maybe you want to ask this question on Piper or Coqui TTS community. Maybe there's some practical experiences.
piper -h shows these parameters available to adjust the output:
--length_scale NUM phoneme length (default: 1.0)
--noise_w NUM phoneme width noise (default: 0.8)
--sentence_silence NUM seconds of silence after each sentence (default: 0.2)
@@64jcl cn you writ me a command full ?
Is there a way to link a Piper voice to the Microsoft Word reader?
IMHO opinion i guess this is not possible by now. I tried integrating Piper to Windows SAPI, which could help on that use case, but this didn't work yet.
@@ThorstenMueller, I would like to use Piper to reproduce the text I select as I read the document. My intention is to play the Piper parallel to my reading of an article, for example, in order to facilitate my concentration on the reading. It doesn't need to be in Microsoft Word. The "Read Aloud: A Text to Speech Voice Reader" extension provides something similar, but is buggy regarding Pitch. I found the "Balabolka" interface, but I couldn't install the Piper voice in it. I have some knowledge in IT, but using Piper is something very advanced for me.
@@ThorstenMueller The key question to solve my problem is: "How to install Piper TTS as SAPI 5 language on Windows?"
tbh no matter the quality, to me it sounds just like regular microsoft tts, not at all ai generated
So you mean, there's room for improvement on the naturalness (and quality) in piper?
im trying to make it work with json, but the usage about this on the repo is too much unclear, not even an example with this...
I didn't try json based input myself. But maybe you can ask on Piper github repository for support. There might be people who worked with json input.
I get error "api-ms-win-core-heap-l1-2-0.dll" is missing while cmd tryna run piper.exe, os is Windows 8.1 😔
Strange, i didn't encounter this problem on Windows 10. Did you already ask on Piper TTS community?
Bro how to create text to speech and voice cloning multilingual model like eleven labs and deploy it has a website or app. Can you make a video for that please ❤...
Good topic suggestion. But this seems to be a combination of multiple tools to build this. Do you have a suggestion of the required tools in total?
how i can generate these and save this voices usingpython ??
Thanks for your question 😊. This topic will be the next or at least one of my next video tutorials.
my terminal cant recognize "cat" and "Get-Content" commands
Are you using classic "cmd" command line or windows powershell?
@ThorstenMueller CMDbut I already wrote a python script
that uses a subprocessimport os
import subprocess
import argparse
def run_speech_generation(text, model_name, json_name, output_file):
os.chdir('C:/piper')
command = f'echo "{text}" | .\\piper.exe -m {model_name} -c {json_name} -f {output_file}'
subprocess.run(command, shell=True)and now I generate speech through python programsthanks for tutorial BTW 🤝👍🙏
@@ThorstenMueller CMD
but I have already implemented what I needed with the help of a python script. Thanks for the tutorial
it won't run on windows 11
can piper use gpu(cuda) in windows 10?
I didn't try it, but according to some Github issues there seems to be a "--cuda" argument. Did you try that?
@@ThorstenMueller Yes I did. and --use-cuda too. no effect
@@Владик-щ8ъ Okay, maybe it's worth to post this on Piper TTS Github repo (github.com/rhasspy/piper/issues). I guess there are more (experienced) people that might be able to support you on this.
Hi Sir, how fast is this? can it be run in real time?
Depending on your hardware it can be run faster than realtime (RTF < 1.0).
@@ThorstenMueller We want to run this on an A100. can it convert in less than 50 MS?
also, are you the lead dev? i have some questions. maybe we can email each other if that is ok
@@shake6321 Not sure on the A100 performance as i do not have any experience with that card.
The lead dev is Michael Hansen.
Hello sir, is there any way to "make the tts slower or faster"
Not by Piper TTS itself, but maybe you can use tools like "ffmpeg" or "pydub" to adjust synthesized audio after generation.
I can change the speed using Audacity a open source audio player.
@@ThorstenMueller ffmpeg is better
I saw this in the github repo
--length_scale 1.0 (this is the default speed, lower value = faster) after model name.
@@AndrewDrafahl divide by 1
how can use Coqui-ai with langauge arabic
Should work in general. I'm not sure if there's any arabic model available yet. You can see all models here: github.com/coqui-ai/TTS/blob/dev/TTS/.models.json
Maybe it's worth to ask on their community for arabic support.
Vietnamese language is not work. Can you fix it? please.
As i'm no active Piper developer i probably can't fix it. Did you already share this topic on Piper TTS Github community?
need python on windows for this with api maybe hahah
I hope to play around with Piper TTS and Python (API) integration in nearer future.
Thx
You're welcome.
Thanks for this, however I cant get it working in w1p even with the useful tip by the fellow youtber in the comments,
I'm not sure what "w1p" means in this context?
windows 10 sorry @@ThorstenMueller
After literally wasting "hours" of trying to make it work, on different Windows system, trying all the switches, options, way to use them, its a total failure to a point. Fuck this garbage and fuck whoever did this awful Windows port.
It always amazes me how entitled some people feel about things they get for free. It worked flawlessly for me, but depending on the model you downloaded, if the config filename doesn't match the model filename, you might have to manually specify it.
Hi thorsten is this still working because when i run this command "echo "Hello, this is a test using Piper TTS." | .\piper.exe -m en_US-kathleen-low.onnx -f test1.wav" there is no output
Should still work as explained. Is there any error message or just no audio output?
Make sure that your config file has the same name as the model file. I noticed that all the ones I've downloaded so far have duplicated filenames, like "en_en_US_kathleen_low_en_US-kathleen-low.onnx.json". Either rename the config file to match the model file, or manually specify it with the --config trigger.
this is not working on my windows 11 at all. No output when i run.. echo "hi there" | .\piper.exe --model .\en_US-kathleen-low.onnx -f test1.wav
No output at all? No error message? Are you using command line or powershell? What happens when you just run: echo "hi"?
@@ThorstenMueller nada. No output at all 😩. I tested it on Ubuntu on virtual box which was working.
@@ThorstenMueller yes no input at all. I have pasted my output screen on this link (remove spaces).
paste board .co [slash] XfeQwZDQHh7Y.png
i can run the command but it doesnt make the wav file
Check the command in the description. If you're running the newer version of piper, you need the config file included in the command you're running.
So, I have just given this a go, followed all the steps, running Powershell as Administrator and it wouldn't produce just goes back to C:\Ai\piper folder...
C:\Ai\piper> echo "Hello this is a test of piper TTS."
Hello this is a test of piper TTS.
C:\Ai\piper> echo "Hello this is a test of piper TTS." | .\piper.exe -m .\en_US-lessac-high.onnx -f test1.wav
C:\Ai\piper>
And that's it, tried with multiple voices, read through the comments saying you also need to use the model, so have the model in the folder as well tried with Kathleen low voice as well using the command in the description for her voice
C:\Ai\piper> echo "Hello, this is a test using Piper TTS." | .\piper.exe -m en_US-kathleen-low.onnx -c en_en_US_kathleen_low_en_US-kathleen-low.onnx.json -f test1.wav
C:\Ai\piper> Nada. Other issue is, even if it did somehow work, it's a lot of faffing around just for a line of audio. Just want to be able to clone my voice and my friends voice from prerecorded clean audio, and be able to produce a podcast without us actually having to do any talking. I don't think Piper is going to be the answer on this one, Tried Tortoise TTs, it was ok, but outputs were generally either quite a way off, or different pitches altogether, want something like Tortoise TTs that is user friendly, but one that actually works. What do you suggest, has to be locally, not paying anyone like Elevenlabs. Can do it all on my gaming computer.
So no output at all? Does "piper.exe --help" show some output? Did you download onnx and mapping json file?
@@ThorstenMueller yes all the mapping works but no output voices. Doesn't matter anymore I'm using TryParot ai voices now.
Not sure where I went wrong. echo 'Welcome to the world of speech synthesis!' | ./piper.exe --model en_US-lessac-medium.onnx --output_file welcome.wav has no output on windows it does something for a second but no output in the shell or in the folder. I have powershell open inside of the directory that I extracted the zip file to. ./piper.exe --help does work
Look in the comments, someone mentions for the latest updates you also need to add -config (and config file)
Thanks for your comment and reply 😊. Normally piper should detect config file automatically if their name is identical to model file (+ json) if it's in the same directory. Does it generate audio then or still produce no output?
@@ThorstenMuellerI finally found the issue after getting it to work on another computer. The model files I downloaded corrupted at some point. After redownloading them it works.