我试图让Uberi识别语音(python)工作,但是recognize_azure
给了我错误。你知道吗
import speech_recognition as sr
r = sr.Recognizer()
m = sr.Microphone()
AZURE_SPEECH_KEY = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
with m as source: r.adjust_for_ambient_noise(source)
print("Say something!")
with m as source: audio = r.listen(source)
try:
print("Microsoft Azure Speech thinks you said " + r.recognize_azure(audio, key=AZURE_SPEECH_KEY))
except sr.UnknownValueError:
print("Microsoft Azure Speech could not understand audio")
except sr.RequestError as e:
print("Could not request results from Microsoft Azure Speech service; {0}".format(e))
结果是:
AttributeError: 'Recognizer' object has no attribute 'recognize_azure'
西班牙:
Estoy tratando de hacer functionar speech\u recognition de Uberi(python),pero el recognition\u azure me da errors.这是一种语音识别技术。你知道吗
埃斯特•埃斯托伊•埃斯托伊•乌桑多:ver arriba
结果如下:
AttributeError: 'Recognizer' object has no attribute 'recognize_azure'
您使用的是过期版本的
speech_recognition
包。recognize_azure
尚未由它提供。你知道吗特别是目前列在pypi.org网站太老了。您可能需要从源代码安装它,请参阅下面的github链接。你知道吗
据我所知,自从pypi版本上市以来,还没有发布过任何版本,所以您唯一的机会似乎是从git主机安装。你知道吗
见https://github.com/Uberi/speech_recognition/issues/385
相关问题 更多 >
编程相关推荐