我正在探索语音识别并遇到了这个名为SpeechRecognition的python库。我正在运行linux mint系统并按照上面链接的网页上的故障排除步骤进行操作。但是,我收到以下错误:
Traceback (most recent call last):
File "test.py", line 4, in <module>
audio = r.listen(source) # listen for the first phrase and extract it into audio data
File "/usr/local/lib/python2.7/dist-packages/speech_recognition/__init__.py", line 268, in listen
buffer = source.stream.read(source.CHUNK)
File "/usr/lib/python2.7/dist-packages/pyaudio.py", line 605, in read
return pa.read_stream(self._stream, num_frames)
KeyboardInterrupt
非常感谢任何帮助。我也明白错误的KeyboardInterrupt部分来自我的操作,按ctrl + c。