今天爱分享给大家带来Could not import the PyAudio C module ‘_portaudio’. Reason: image not found【解决办法】,希望能够帮助到大家。
跑python的vad程序的时候,出现了下面的问题:
(base) ➜ python-vad git:(master) python vad.py Could not import the PyAudio C module '_portaudio'. Traceback (most recent call last): File "vad.py", line 10, inimport pyaudio File "/Users/admin/anaconda3/lib/python3.7/site-packages/pyaudio.py", line 116, in import _portaudio as pa ImportError: dlopen(/Users/admin/anaconda3/lib/python3.7/site-packages/_portaudio.cpython-37m-darwin.so, 2): Library not loaded: /usr/local/opt/portaudio/lib/libportaudio.2.dylib Referenced from: /Users/admin/anaconda3/lib/python3.7/site-packages/_portaudio.cpython-37m-darwin.so Reason: image not found
解决方法
conda install pyaudio