Posts

Showing posts with the label Python Projects

Just Listen Program || with Python || Computer Science World ||

Image
ComputerScienceWorld Hello Code Lovers, Here I will give you a program, “Text-to-Speech” with a little line of python codes. In this program, you will get a function that can speak an open-source file format. Like: - (.txt, .pdf, .py) and many more Just Enter the file location and then take the rest to your eyes. You can use this in travel or if not want to read files. (Works Like mp3 🎧).   Requirements for using this program:    1. The  latest version of Python (>=3.2)         2. Install pyttsx3 module “pip install pyttsx3”    3.  File format: (.txt, .pdf and more readable file) Codes are: import pyttsx3 # Just Import pyttsx3, for installation pyttsx3 "pip install pyttsx3".   process = pyttsx3 . init ( 'sapi5' ) # Microsoft Speech API ('SAPI'). volume = pyttsx3 . init ( 'sapi5' ). getProperty ( 'voices' ) #'voices' = List of L{voice.Voice} objects supported by the driver.   ...