Reputation: 690
I am trying to convert audio to text. The audio is not in English but in Dutch. I am unable to convert the Dutch audio to text. The code works only for English audios. I am not sure if I need to include some functions or options for the code to recognise other languages as well. Below is the code:
import speech_recognition as sr
r = sr.Recognizer()
with sr.AudioFile('audio.wav') as source:
audio = r.listen(source)
try:
text = (r.recognize_google)
print(text)
Upvotes: 5
Views: 5246
Reputation: 1
you can do any language you just need to know what is your countries domains like for instance German would be: de-DE
Upvotes: 0