gpt4 book ai didi

python - 安装基于 pyproject.toml 的项目所需的错误 : Could not build wheels for pyaudio,

转载 作者:行者123 更新时间:2023-12-05 08:14:45 75 4
gpt4 key购买 nike

我在尝试安装 PyAudio 时遇到此错误:

ERROR: Could not build wheels for pyaudio, which is required to install pyproject.toml-based projects

有谁知道为什么会这样以及如何解决?

最佳

最佳答案

试试这个 solution :

这些步骤适用于 M1 Pro 芯片

  1. 安装portaudio
brew install portaudio
  1. 链接 portaudio
brew link portaudio
  1. 复制安装portaudio的路径(下一步使用)
brew --prefix portaudio
  1. 在您的主目录中创建 .pydistutils.cfg
sudo nano $HOME/.pydistutils.cfg

然后粘贴以下内容

[build_ext]
include_dirs=<PATH FROM STEP 3>/include/
library_dirs=<PATH FROM STEP 3>/lib/

  1. 安装pyaudio
pip install pyaudio

or

pip3 install pyaudio

来自:Unable to install PyAudio on M1 Mac [PortAudio already installed]

关于python - 安装基于 pyproject.toml 的项目所需的错误 : Could not build wheels for pyaudio,,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/73268630/

75 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com