Spaces:
Sleeping
Sleeping
truongghieu
commited on
Commit
•
868bc89
1
Parent(s):
a266d09
Update app.py
Browse files
app.py
CHANGED
@@ -5,7 +5,7 @@ import numpy as np
|
|
5 |
|
6 |
def recognize_speech(audio_data):
|
7 |
# nontype to wav
|
8 |
-
audio_data = sr.AudioData(np.array(audio_data)
|
9 |
|
10 |
recognizer = sr.Recognizer()
|
11 |
try:
|
|
|
5 |
|
6 |
def recognize_speech(audio_data):
|
7 |
# nontype to wav
|
8 |
+
audio_data = sr.AudioData(np.array(audio_data), 16000, 2)
|
9 |
|
10 |
recognizer = sr.Recognizer()
|
11 |
try:
|