Spaces:
Sleeping
Sleeping
SpicyqSama007
commited on
Commit
•
c01252a
1
Parent(s):
c8d873a
Upload 3 files
Browse files- Data/mix/config.json +109 -0
- Data/mix/models/G_3000_release.pth +3 -0
- config.yml +187 -0
Data/mix/config.json
ADDED
@@ -0,0 +1,109 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"train": {
|
3 |
+
"log_interval": 200,
|
4 |
+
"eval_interval": 1000,
|
5 |
+
"seed": 42,
|
6 |
+
"epochs": 1000,
|
7 |
+
"learning_rate": 0.0002,
|
8 |
+
"betas": [
|
9 |
+
0.8,
|
10 |
+
0.99
|
11 |
+
],
|
12 |
+
"eps": 1e-09,
|
13 |
+
"batch_size": 12,
|
14 |
+
"fp16_run": false,
|
15 |
+
"lr_decay": 0.99995,
|
16 |
+
"segment_size": 16384,
|
17 |
+
"init_lr_ratio": 1,
|
18 |
+
"warmup_epochs": 0,
|
19 |
+
"c_mel": 45,
|
20 |
+
"c_kl": 1.0,
|
21 |
+
"skip_optimizer": true,
|
22 |
+
"freeze_ZH_bert": false,
|
23 |
+
"freeze_JP_bert": false,
|
24 |
+
"freeze_EN_bert": false
|
25 |
+
},
|
26 |
+
"data": {
|
27 |
+
"training_files": "Data/mix/filelists/train.list",
|
28 |
+
"validation_files": "Data/mix/filelists/val.list",
|
29 |
+
"max_wav_value": 32768.0,
|
30 |
+
"sampling_rate": 44100,
|
31 |
+
"filter_length": 2048,
|
32 |
+
"hop_length": 512,
|
33 |
+
"win_length": 2048,
|
34 |
+
"n_mel_channels": 128,
|
35 |
+
"mel_fmin": 0.0,
|
36 |
+
"mel_fmax": null,
|
37 |
+
"add_blank": true,
|
38 |
+
"n_speakers": 896,
|
39 |
+
"cleaned_text": true,
|
40 |
+
"spk2id": {
|
41 |
+
"Clara": 0,
|
42 |
+
"Fu Xuan": 1,
|
43 |
+
"「公子」中文": 2,
|
44 |
+
"「公子」日语": 3,
|
45 |
+
"克拉拉": 4,
|
46 |
+
"可莉": 5,
|
47 |
+
"宵宫": 6,
|
48 |
+
"宵宮": 7,
|
49 |
+
"桂乃芬": 8,
|
50 |
+
"符玄": 9,
|
51 |
+
"胡桃": 10
|
52 |
+
}
|
53 |
+
},
|
54 |
+
"model": {
|
55 |
+
"use_spk_conditioned_encoder": true,
|
56 |
+
"use_noise_scaled_mas": true,
|
57 |
+
"use_mel_posterior_encoder": false,
|
58 |
+
"use_duration_discriminator": true,
|
59 |
+
"inter_channels": 192,
|
60 |
+
"hidden_channels": 192,
|
61 |
+
"filter_channels": 768,
|
62 |
+
"n_heads": 2,
|
63 |
+
"n_layers": 6,
|
64 |
+
"kernel_size": 3,
|
65 |
+
"p_dropout": 0.1,
|
66 |
+
"resblock": "1",
|
67 |
+
"resblock_kernel_sizes": [
|
68 |
+
3,
|
69 |
+
7,
|
70 |
+
11
|
71 |
+
],
|
72 |
+
"resblock_dilation_sizes": [
|
73 |
+
[
|
74 |
+
1,
|
75 |
+
3,
|
76 |
+
5
|
77 |
+
],
|
78 |
+
[
|
79 |
+
1,
|
80 |
+
3,
|
81 |
+
5
|
82 |
+
],
|
83 |
+
[
|
84 |
+
1,
|
85 |
+
3,
|
86 |
+
5
|
87 |
+
]
|
88 |
+
],
|
89 |
+
"upsample_rates": [
|
90 |
+
8,
|
91 |
+
8,
|
92 |
+
2,
|
93 |
+
2,
|
94 |
+
2
|
95 |
+
],
|
96 |
+
"upsample_initial_channel": 512,
|
97 |
+
"upsample_kernel_sizes": [
|
98 |
+
16,
|
99 |
+
16,
|
100 |
+
8,
|
101 |
+
2,
|
102 |
+
2
|
103 |
+
],
|
104 |
+
"n_layers_q": 3,
|
105 |
+
"use_spectral_norm": false,
|
106 |
+
"gin_channels": 256
|
107 |
+
},
|
108 |
+
"version": "2.2"
|
109 |
+
}
|
Data/mix/models/G_3000_release.pth
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:112020f23bfb1d3961624cd91bb64a1aa9631b8c98398f675be2b3de907d6d87
|
3 |
+
size 200101926
|
config.yml
ADDED
@@ -0,0 +1,187 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# 全局配置
|
2 |
+
# 对于希望在同一时间使用多个配置文件的情况,例如两个GPU同时跑两个训练集:通过环境变量指定配置文件,不指定则默认为./config.yml
|
3 |
+
|
4 |
+
# 拟提供通用路径配置,统一存放数据,避免数据放得很乱
|
5 |
+
# 每个数据集与其对应的模型存放至统一路径下,后续所有的路径配置均为相对于datasetPath的路径
|
6 |
+
# 不填或者填空则路径为相对于项目根目录的路径
|
7 |
+
dataset_path: "Data/mix"
|
8 |
+
|
9 |
+
# 模型镜像源,默认huggingface,使用openi镜像源需指定openi_token
|
10 |
+
mirror: ""
|
11 |
+
openi_token: "" # openi token
|
12 |
+
|
13 |
+
# resample 音频重采样配置
|
14 |
+
# 注意, “:” 后需要加空格
|
15 |
+
resample:
|
16 |
+
# 目标重采样率
|
17 |
+
sampling_rate: 44100
|
18 |
+
# 音频文件输入路径,重采样会将该路径下所有.wav音频文件重采样
|
19 |
+
# 请填入相对于datasetPath的相对路径
|
20 |
+
in_dir: "audios/raw" # 相对于根目录的路径为 /datasetPath/in_dir
|
21 |
+
# 音频文件重采样后输出路径
|
22 |
+
out_dir: "audios/wavs"
|
23 |
+
|
24 |
+
|
25 |
+
# preprocess_text 数据集预处理相关配置
|
26 |
+
# 注意, “:” 后需要加空格
|
27 |
+
preprocess_text:
|
28 |
+
# 原始文本文件路径,文本格式应为{wav_path}|{speaker_name}|{language}|{text}。
|
29 |
+
transcription_path: "filelists/你的数据集文本.list"
|
30 |
+
# 数据清洗后文本路径,可以不填。不填则将在原始文本目录生成
|
31 |
+
cleaned_path: ""
|
32 |
+
# 训练集路径
|
33 |
+
train_path: "filelists/train.list"
|
34 |
+
# 验证集路径
|
35 |
+
val_path: "filelists/val.list"
|
36 |
+
# 配置文件路径
|
37 |
+
config_path: "config.json"
|
38 |
+
# 每个speaker的验证集条数
|
39 |
+
val_per_spk: 4
|
40 |
+
# 验证集最大条数,多于的会被截断并放到训练集中
|
41 |
+
max_val_total: 8
|
42 |
+
# 是否进行数据清洗
|
43 |
+
clean: true
|
44 |
+
|
45 |
+
|
46 |
+
# bert_gen 相关配置
|
47 |
+
# 注意, “:” 后需要加空格
|
48 |
+
bert_gen:
|
49 |
+
# 训练数据集配置文件路径
|
50 |
+
config_path: "config.json"
|
51 |
+
# 并行数
|
52 |
+
num_processes: 4
|
53 |
+
# 使用设备:可选项 "cuda" 显卡推理,"cpu" cpu推理
|
54 |
+
# 该选项同时决定了get_bert_feature的默认设备
|
55 |
+
device: "cuda"
|
56 |
+
# 使用多卡推理
|
57 |
+
use_multi_device: false
|
58 |
+
|
59 |
+
# emo_gen 相关配置
|
60 |
+
# 注意, “:” 后需要加空格
|
61 |
+
emo_gen:
|
62 |
+
# 训练数据集配置文件路径
|
63 |
+
config_path: "config.json"
|
64 |
+
# 并行数
|
65 |
+
num_processes: 2
|
66 |
+
# 使用设备:可选项 "cuda" 显卡推理,"cpu" cpu推理
|
67 |
+
device: "cuda"
|
68 |
+
|
69 |
+
emo_cluster:
|
70 |
+
# 聚类方法,可选k,b,s,a
|
71 |
+
method: "k"
|
72 |
+
# 聚类数量
|
73 |
+
n_clusters: 5
|
74 |
+
# 每类的数量
|
75 |
+
n_samples: 10
|
76 |
+
# 是否保存center
|
77 |
+
save_center: True
|
78 |
+
# 训练数据集配置文件路径
|
79 |
+
config_path: "config.json"
|
80 |
+
|
81 |
+
# train 训练配置
|
82 |
+
# 注意, “:” 后需要加空格
|
83 |
+
train_ms:
|
84 |
+
env:
|
85 |
+
MASTER_ADDR: "localhost"
|
86 |
+
MASTER_PORT: 10086
|
87 |
+
WORLD_SIZE: 1
|
88 |
+
LOCAL_RANK: 0
|
89 |
+
RANK: 0
|
90 |
+
# 可以填写任意名的环境变量
|
91 |
+
# THE_ENV_VAR_YOU_NEED_TO_USE: "1234567"
|
92 |
+
# 底模设置
|
93 |
+
base:
|
94 |
+
use_base_model: false
|
95 |
+
repo_id: "Stardust_minus/Bert-VITS2"
|
96 |
+
model_image: "Bert-VITS2_2.2-Emo底模" # openi网页的模型名
|
97 |
+
# 训练模型存储目录:与旧版本的区别,原先数据集是存放在logs/model_name下的,现在改为统一存放在Data/你的数据集/models下
|
98 |
+
model: "models"
|
99 |
+
# 配置文件路径
|
100 |
+
config_path: "config.json"
|
101 |
+
# 训练使用的worker,不建议超过CPU核心数
|
102 |
+
num_workers: 16
|
103 |
+
# 关闭此项可以节约接近50%的磁盘空间,但是可能导致实际训练速度变慢和更高的CPU使用率。
|
104 |
+
spec_cache: True
|
105 |
+
# 保存的检查点数量,多于此数目的权重会被删除来节省空间。
|
106 |
+
keep_ckpts: 6
|
107 |
+
|
108 |
+
|
109 |
+
# webui webui配置
|
110 |
+
# 注意, “:” 后需要加空格
|
111 |
+
webui:
|
112 |
+
# 推理设备
|
113 |
+
device: "cuda"
|
114 |
+
# 模型路径
|
115 |
+
model: "models/G_5000_release.pth"
|
116 |
+
# 配置文件路径
|
117 |
+
config_path: "config.json"
|
118 |
+
# 端口号
|
119 |
+
port: 7860
|
120 |
+
# 是否公开部署,对外网开放
|
121 |
+
share: true
|
122 |
+
# 是否开启debug模式
|
123 |
+
debug: false
|
124 |
+
# 语种识别库,可选langid, fastlid
|
125 |
+
language_identification_library: "langid"
|
126 |
+
|
127 |
+
|
128 |
+
# server-fastapi配置
|
129 |
+
# 注意, “:” 后需要加空格
|
130 |
+
# 注意,本配置下的所有配置均为相对于根目录的路径
|
131 |
+
server:
|
132 |
+
# 端口号
|
133 |
+
port: 5000
|
134 |
+
# 模型默认使用设备:但是当前并没有实现这个配置。
|
135 |
+
device: "cuda"
|
136 |
+
# 需要加载的所有模型的配置,可以填多个模型,也可以不填模型,等网页成功后手动加载模型
|
137 |
+
# 不加载模型的配置格式:删除默认给的两个模型配置,给models赋值 [ ],也就是空列表。参考模型2的speakers 即 models: [ ]
|
138 |
+
# 注意,所有模型都必须正确配置model与config的路径,空路径会导致加载错误。
|
139 |
+
# 也可以不填模型,等网页加载成功后手动填写models。
|
140 |
+
models:
|
141 |
+
- # 模型的路径
|
142 |
+
model: ""
|
143 |
+
# 模型config.json的路径
|
144 |
+
config: ""
|
145 |
+
# 模型使用设备,若填写则会覆盖默认配置
|
146 |
+
device: "cuda"
|
147 |
+
# 模型默认使��的语言
|
148 |
+
language: "ZH"
|
149 |
+
# 模型人物默认参数
|
150 |
+
# 不必填写所有人物,不填的使用默认值
|
151 |
+
# 暂时不用填写,当前尚未实现按人区分配置
|
152 |
+
speakers:
|
153 |
+
- speaker: "科比"
|
154 |
+
sdp_ratio: 0.2
|
155 |
+
noise_scale: 0.6
|
156 |
+
noise_scale_w: 0.8
|
157 |
+
length_scale: 1
|
158 |
+
- speaker: "五条悟"
|
159 |
+
sdp_ratio: 0.3
|
160 |
+
noise_scale: 0.7
|
161 |
+
noise_scale_w: 0.8
|
162 |
+
length_scale: 0.5
|
163 |
+
- speaker: "安倍晋三"
|
164 |
+
sdp_ratio: 0.2
|
165 |
+
noise_scale: 0.6
|
166 |
+
noise_scale_w: 0.8
|
167 |
+
length_scale: 1.2
|
168 |
+
- # 模型的路径
|
169 |
+
model: ""
|
170 |
+
# 模型config.json的路径
|
171 |
+
config: ""
|
172 |
+
# 模型使用设备,若填写则会覆盖默认配置
|
173 |
+
device: "cpu"
|
174 |
+
# 模型默认使用的语言
|
175 |
+
language: "JP"
|
176 |
+
# 模型人物默认参数
|
177 |
+
# 不必填写所有人物,不填的使用默认值
|
178 |
+
speakers: [ ] # 也可以不填
|
179 |
+
|
180 |
+
# 百度翻译开放平台 api配置
|
181 |
+
# api接入文档 https://api.fanyi.baidu.com/doc/21
|
182 |
+
# 请不要在github等网站公开分享你的app id 与 key
|
183 |
+
translate:
|
184 |
+
# 你的APPID
|
185 |
+
"app_key": ""
|
186 |
+
# 你的密钥
|
187 |
+
"secret_key": ""
|