GitHub - davabase/whisper_real_time: Real time transcription with OpenAI Whisper.
1)用pip直接安装:
pip install pyaudio
可能会出现如下报错:
Failed to build pyaudio
ERROR: Could not build wheels for pyaudio, which is required to install pyproject.toml-based projects
2)安装插件
这时候需要先按照一些必要的库libasound2-dev
sudo apt-get install libasound2-dev
3)安装portaudio
先到 官网http://files.portaudio.com/download.html下载PortAudio:
pyaudio下载
把下载好的文件pa_stable_v190700_20210406.tgz放到ubuntu系统桌面上的一个文件夹中,比如我的.\soft
然后进入该目录下解压:
tar -xvf pa_stable_v190700_20210406.tgz
接着进入portaudio目录:
cd portaudio
然后编译:
./configure
make
sudo make install
make clean
4)安装pyaudio
最后再运行pip安装:
pip install pyaudio
即可安装成功。 作者:bili_65283650909 https://www.bilibili.com/read/cv22714459/ 出处:bilibili