Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -9,7 +9,7 @@ def listen(audio):
|
|
| 9 |
# sample_width = audio_file.getsampwidth()
|
| 10 |
audio_file = sr.AudioData(audio_data, sample_rate=sample_rate,sample_width=2)
|
| 11 |
with audio_file as source:
|
| 12 |
-
audio = r.
|
| 13 |
try:
|
| 14 |
text = r.recognize_google(audio, language='ur')
|
| 15 |
return text
|
|
|
|
| 9 |
# sample_width = audio_file.getsampwidth()
|
| 10 |
audio_file = sr.AudioData(audio_data, sample_rate=sample_rate,sample_width=2)
|
| 11 |
with audio_file as source:
|
| 12 |
+
audio = r.listen(source)
|
| 13 |
try:
|
| 14 |
text = r.recognize_google(audio, language='ur')
|
| 15 |
return text
|