-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
779ad01
commit e280290
Showing
2 changed files
with
60 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,63 @@ | ||
# Python Real Time Language Translation Bot | ||
# Real Time Voice Recognition based Language Translation Bot | ||
|
||
This repository contains some python scripts which can translate languages with audio processing. These scripts are written in python with some modules. | ||
## Introduction | ||
|
||
###### How does it work | ||
A voice recognition based tool for translating languages in real time. This tool could be used to translate languages with voice data. For an example, it can listen and, translate that voice data into the target language then, it speaks out as a voice output, similar to a human translator, who listens and then translate in a targeted language. | ||
|
||
1. Convert audio speeches into texts with [speech-recognition library](https://pypi.org/project/SpeechRecognition/). | ||
2. Translate the text into another language with [googletrans library](https://pypi.org/project/googletrans/) | ||
3. Convert the translated text into voice [gtts library](https://pypi.org/project/gTTS/) | ||
4. Play the voice as sound [playsound library](https://pypi.org/project/playsound/) | ||
This is not efficient like human translator, it is using the google translate platform as backbone to perform the translation process. | ||
|
||
|
||
![diagram](github-readme-contents/system-architeture.png) | ||
|
||
## Technologies & Frameworks | ||
|
||
- Python 3.8 | ||
- GTTS Module | ||
- SpeechRecognition Module | ||
- Playsound Module | ||
- Googletrans Module | ||
|
||
|
||
### Why GTTS Module? | ||
|
||
gTTS (Google Text-to-Speech)is a Python library and CLI tool to interface with Google Translate text-to-speech API. We will import the gTTS library from the gtts module which can be used for speech translation. | ||
|
||
**Note:** This module helps to convert text as voice output. | ||
|
||
|
||
### Why SpeechRecognition Module? | ||
|
||
This module gives the ability to perform speech recognition, basically, it could be used to convert speech to text operations. | ||
|
||
### Why Playsound Module? | ||
|
||
playsound is a “pure Python, cross platform, single function module with no dependencies for playing sounds.” With this module, you can play a sound file with a single line of code: | ||
|
||
``` python | ||
from playsound import playsound | ||
playsound('myfile.wav') | ||
``` | ||
|
||
### Why Googletrans Module? | ||
|
||
Googletrans is a free and unlimited python library that implemented Google Translate API. This uses the Google Translate Ajax API to make calls to such methods as detect and translate. | ||
|
||
This is core library of this project, which does the translations among languages. | ||
|
||
## Execution & Running | ||
|
||
**Note:** To perform translation, navigate to the preferred folder, and execute the run.py script to start the program. | ||
|
||
``` | ||
python run.py | ||
``` | ||
|
||
Any Questions? | Conduct Me | ||
--- | ||
|
||
* [Linkedin Profile](https://www.linkedin.com/in/gunarakulangunaretnam/) | ||
* [Facebook Profile](https://www.facebook.com/gunarakulan) | ||
* [Twitter Profile](https://twitter.com/gunarakulang) | ||
* [Instagram Profile](https://www.instagram.com/gunarakulan_gunaretnam/) | ||
* [Youtube Channel](https://www.youtube.com/channel/UCMWkED5sabgVZSCKjZuRJXA/videos) |
File renamed without changes