解决安装pynini和WeTextProcessing报错问题

点击这里,访问博客

0. 背景

最近在给别人有偿部署ASR-LLM-TTS项目时遇到安装pyniniWeTextProcessing依赖报错的问题,报错信息如下:

markdown 复制代码
IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" /EHsc /Tpextensions/_pywrapfst.cpp /Fobuild\temp.win-amd64-cpython-311\Release\extensions/_pywrapfst.obj -std=c++17 -Wno-register -Wno-deprecated-declarations -Wno-unused-function -Wno-unused-local-typedefs -funsigned-char
cl: 命令行 error D8021 :无效的数值参数"/Wno-register"
error: command 'D:\Visual_Studio2022\VC\Tools\MSVC\14.42.34433\bin\HostX86\x64\cl.exe' failed with exit code 2
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pynini
Running setup.py clean for pynini
Failed to build pynini
ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (pynini)

1. 解决pynini依赖报错问题

我使用了pip install 方式来安装,结果也是会报错。

于是在网上找到了解决方案,点击这里,跳转到原文。

使用pip install方式,安装报错,那么就可以考虑使用conda install方式安装,如下所示:

shell 复制代码
conda install -c conda-forge pynini=2.1.6

2. 解决WeTextProcessing依赖报错问题

可以使用下面命令解决。

shell 复制代码
pip install WeTextProcessing --no-deps

3. 其它

ASR-LLM-TTS项目源码,点击这里

前后端分离ASR_LLM_TTS项目后端源码,点击这里

前后端分离ASR_LLM_TTS项目前端源码,点击这里

原文出自我的博客,点击这里

相关推荐
Lyn_Li10 分钟前
扫描 PDF 歪了怎么办?用 6 种检测方法做本地批量扶正(附开源工具)
python·pdf·ocr·tesseract·开源工具·文档处理·本地处理·扫描件纠偏
金銀銅鐵31 分钟前
费马小定理
python·数学·算法
copyer_xyf1 小时前
LangGraph 多 Agent 入门:从流程图到旅行规划助手
llm·agent
wumingxiaoyao4 小时前
从 0 开始学 AI:第 2 课,AI、机器学习、深度学习和大模型是什么关系?
人工智能·深度学习·机器学习·ai·大模型·llm
疋瓞4 小时前
python和C++对比(1)_数据类型和数据结构
数据结构·c++·python
如此这般英俊6 小时前
手搓Claude Code-第六章 subagent
数据结构·人工智能·python·语言模型·自然语言处理
元Y亨H7 小时前
Python - FastAPI 全方位介绍
python·fastapi
掉鱼的猫7 小时前
Agent Harness 实战指南:构建生产级 AI Agent 的"马具"框架
java·llm·aigc
带刺的坐椅7 小时前
Agent Harness 实战指南:构建生产级 AI Agent 的"马具"框架
java·ai·llm·agent·solon-ai
error:(8 小时前
【系统与实战双精通】VS Code 调试 ROS2 Python 节点与 Launch 系统指南
android·java·python