bert-vits2本地部署报错疑难问题汇总

环境:

bert-vits2.3

win 和wsl

问题描述:

bert-vits2本地部署报错疑难问题汇总

解决方案:

问题1:

Conda安装requirements里面依赖出现ERROR: No matching distribution found for opencc==1.1.6

解决方法

bash 复制代码
需要在 Python 3.11 上使用 OpenCC
打开requirements把opencc== 1.16改成1.17保存文本

问题2:

error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tool

解决方法

bash 复制代码
conda install libpython m2w64-toolchain -c msys2
bash 复制代码
 conda install -c conda-forge jieba_fast

安装VS2019

单独安装2个组件

问题3:

训练报错

TypeError: Webui_config.init() got an unexpected keyword argument 'fp16_run'

解决方法

bash 复制代码
配置文件没有更新,更新配置文件

问题4:

训练报错

rank0\]: OSError: Error no file named pytorch_model.bin, tf_model.h5, model.ckpt.index or flax_model.msgpack found in directory ./slm/wavlm-base-plus. 解决方法 没有下载pytorch_model.bin 在下面这个文件夹 ![在这里插入图片描述](https://file.jishuzhan.net/article/1756878182255955969/614a142075c1af1015f567f3602f7108.webp) **问题5:** 训练报错 RuntimeError: The expanded size of the tensor (1024) must match the existing size (2048) at non-singleton dimension 0. Target sizes: \[1024, 157\]. Tensor sizes: \[2048, 157

解决方法

bash 复制代码
删除原来生产bert文件重新生成

问题6:

raise KeyError("param 'initial_lr' is not specified "

rank0\]: KeyError: "param 'initial_lr' is not specified in param_groups\[0\] when resuming an optimizer" 解决方法 ```bash 优化爆了,手动改优化器train_ms.py代码 # 更改优化器的初始学习率参数 optim_g.param_groups[0]['initial_lr'] = 0.1 optim_d.param_groups[0]['initial_lr'] = 0.1 optim_wd.param_groups[0]['initial_lr'] = 0.1 optim_dur_disc.param_groups[0]['initial_lr'] = 0.1 # 创建调度器并应用更改后的优化器 scheduler_g = torch.optim.lr_scheduler.ExponentialLR( optim_g, gamma=hps.train.lr_decay, last_epoch=epoch_str - 2 ) scheduler_d = torch.optim.lr_scheduler.ExponentialLR( optim_d, gamma=hps.train.lr_decay, last_epoch=epoch_str - 2 ) scheduler_wd = torch.optim.lr_scheduler.ExponentialLR( optim_wd, gamma=hps.train.lr_decay, last_epoch=epoch_str - 2 ) if net_dur_disc is not None: scheduler_dur_disc = torch.optim.lr_scheduler.ExponentialLR( optim_dur_disc, gamma=hps.train.lr_decay, last_epoch=epoch_str - 2 ) ```

相关推荐
书玮嘎1 小时前
【WIP】【VLA&VLM——InternVL系列】
人工智能·深度学习
猫头虎1 小时前
猫头虎 AI工具分享:一个网页抓取、结构化数据提取、网页爬取、浏览器自动化操作工具:Hyperbrowser MCP
运维·人工智能·gpt·开源·自动化·文心一言·ai编程
要努力啊啊啊1 小时前
YOLOv2 正负样本分配机制详解
人工智能·深度学习·yolo·计算机视觉·目标跟踪
CareyWYR1 小时前
大模型真的能做推荐系统吗?ARAG论文给了我一个颠覆性的答案
人工智能
特立独行的猫a1 小时前
百度AI文心大模型4.5系列开源模型评测,从安装部署到应用体验
人工智能·百度·开源·文心一言·文心一言4.5
SKYDROID云卓小助手2 小时前
无人设备遥控器之自动调整编码技术篇
人工智能·嵌入式硬件·算法·自动化·信号处理
小陈phd2 小时前
李宏毅机器学习笔记——梯度下降法
人工智能·python·机器学习
CareyWYR2 小时前
每周AI论文速递(250630-250704)
人工智能
Ai墨芯1112 小时前
靠机器学习+组合优化就发了CCF-A
人工智能