Posts

Showing posts with the label python program

Text to Speech using python

Image
Text2speech Today's video we are going to create Text to speech using python First of all you have to install pyttsx3 library Pyttsx3- Pypl You can just write pip install pyttsx3 in your cmd or Powershell. It will start installing in your system environment. After installation, open your text editor or IDE. Import libraries Just Import pyttsx3 import pyttsx3 as pt Start engine Now it's time to start engine of pyttsx3 module. engine= pt.init() pt is the alias that we used instead of pyttsx3. we used init() method to initialize pyttsx3 library. Here engine is the variable used to start the engine. say() say() is the pyttsx3 method to say or speek the written text. engine.say("Hello World") by calling the engine.say() method we are going to make our computer able to speek