在win11环境下的运行命令
克隆仓库 - 分支jongwook/large-v3-turbo
- 原有仓库
shell
git clone https://github.com/openai/whisper.git
-
在Gitee上我自己又克隆的仓库,并附带custom.py和在dataset(自己新建的文件夹)中的一些测试文件
shellgit clone https://gitee.com/kxw123/whisper-demo.git
1 创建虚拟环境(以下命令 使用git bash)
shell
python -m venv whisper-venv
2激活虚拟环境
shell
source whisper-venv/Scripts/activate
3 进入目录
shell
cd whisper
4 安装依赖
shell
pip install -r requirements.txt
项目中如果有虚拟环境,忽略以上1,2,3; 在项目下执行
shell
source .venv/Scripts/activate
5 退出虚拟环境(退出时使用)
shell
deactivate
6 音频转文字
- 直接在项目中运行该文件或者gitbash 都可
shell
python custom.py
- custom.py 自定义文件, 功能: 语音转文字,并翻译