无法在我的 python 3.7 中安装 Pyaudio ..甚至尝试安装 Visual C++。pip install pyaudioCollecting pyaudio Using cached https://files.pythonhosted.org/packages/ab/42/b4f04721c5c5bfc196ce156b3c768998ef8c0ae3654ed29ea5020c749a6b/PyAudio-0.2.11.tar.gzBuilding wheels for collected packages: pyaudio Running setup.py bdist_wheel for pyaudio Complete output from command "c:\users\vicky kumar\appdata\local\programs\python\python37\python.exe" -c "import setuptools;__file__='C:\\Users\\VICKYK~1\\AppData\\Local\\Temp\\pip-build-5v23nswh\\pyaudio\\setup.py';exec(compile(open(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" bdist_wheel -d C:\Users\VICKYK~1\AppData\Local\Temp\tmprsn0men8pip-wheel-: running bdist_wheel running build running build_py creating build creating build\lib.win-amd64-3.7 copying src\pyaudio.py -> build\lib.win-amd64-3.7 running build_ext building '_portaudio' extension error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools ---------------------------------------- Failed building wheel for pyaudioFailed to build pyaudioInstalling collected packages: pyaudio Running setup.py install for pyaudio Complete output from command "c:\users\vicky kumar\appdata\local\programs\python\python37\python.exe" -c "import setuptools, tokenize;__file__='C:\\Users\\VICKYK~1\\AppData\\Local\\Temp\\pip-build-5v23nswh\\pyaudio\\setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record C:\Users\VICKYK~1\AppData\Local\Temp\pip-m53gsf79-record\install-record.txt --single-version-externally-managed --compile:
2 回答

小怪兽爱吃肉
TA贡献1852条经验 获得超1个赞
不能安装 Pyaudio 的原因是你的 python 版本,支持 Pyaudio 的最后一个 python 版本是 python 3.6 所以你必须安装 python 3.6 或 3.5 或 3.4 或 python 2.7。安装 python 3.6 后,使用此链接并根据您的操作系统下载 pyaudio.whl。然后使用此命令安装它:
pip install <package_name>.whl

慕工程0101907
TA贡献1887条经验 获得超5个赞
要使用 conda 安装最新版本的 pyaudio:
source activate -your environment name-
pip install pyaudio
如果遇到 PortAudio 开发包错误,请安装
sudo apt-get install portaudio19-dev
添加回答
举报
0/150
提交
取消