Speech Recognition Using Python (Basic Example)

What is Speech Recognition ?

Speech Recognition is the inter-disciplinary sub-filed of computational linguistics that develops methodologies and technologies that enables the recognition and translation of spoken language into text by computers

Setup The Virtual Environment :-

1. Create a Directory => mkdir speech (here "speech" is the directory name)
2. Change Directory => cd speech
3. Install virtualenv => sudo pip3 install virtualenv
4. Create Virtual Environment => virtualenv speech (here "speech" is the virtual environment name)
5. Get inside Virtual Environment => cd speech
6. Activate bin => source bin/activate

Your Virtual Environment is Setup Successfully :)

Install Required Module :-

1. pyaudio = >
a.) sudo apt-get install libasound-dev portaudio19-dev libportaudio2 libportaudiocpp0
b.) sudo apt-get install ffmpeg libav-tools
c.) sudo apt-get install python-pyaudio
d.) sudo pip install pyaudio

2. SpeechRecoginition => 
a.) sudo pip install SpeechRecognition (make sure 'S' and  'R' is Bold letter)

Python Script speech.py :-

Run the speech.py :-
Make sure you have an internet connection .

Posted By : Tushar Verma 
SpeechRecognition Link : https://realpython.com/python-speech-recognition/
LinkedIn Profile  : https://www.linkedin.com/in/tushar-verma-047329154/
Github Profile  : https://github.com/tushar821999/


Post a comment

Previous Post Next Post