fix v2 32k 48k extract bug

fix v2 32k 48k extract bug
This commit is contained in:
RVC-Boss 2023-06-19 15:48:25 +08:00 committed by GitHub
parent be1b0b33c9
commit 90ff4e8c29
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 84 additions and 40 deletions

View File

@ -92,47 +92,91 @@ def extract_small_model(path, name, sr, if_f0, info, version):
40000, 40000,
] ]
elif sr == "48k": elif sr == "48k":
opt["config"] = [ if(version=="v1"):
1025, opt["config"] = [
32, 1025,
192, 32,
192, 192,
768, 192,
2, 768,
6, 2,
3, 6,
0, 3,
"1", 0,
[3, 7, 11], "1",
[[1, 3, 5], [1, 3, 5], [1, 3, 5]], [3, 7, 11],
[10, 6, 2, 2, 2], [[1, 3, 5], [1, 3, 5], [1, 3, 5]],
512, [10, 6, 2, 2, 2],
[16, 16, 4, 4, 4], 512,
109, [16, 16, 4, 4, 4],
256, 109,
48000, 256,
] 48000,
]
else:
opt["config"] = [
1025,
32,
192,
192,
768,
2,
6,
3,
0,
"1",
[3, 7, 11],
[[1, 3, 5], [1, 3, 5], [1, 3, 5]],
[12,10,2,2],
512,
[24,20,4,4],
109,
256,
48000,
]
elif sr == "32k": elif sr == "32k":
opt["config"] = [ if(version=="v1"):
513, opt["config"] = [
32, 513,
192, 32,
192, 192,
768, 192,
2, 768,
6, 2,
3, 6,
0, 3,
"1", 0,
[3, 7, 11], "1",
[[1, 3, 5], [1, 3, 5], [1, 3, 5]], [3, 7, 11],
[10, 4, 2, 2, 2], [[1, 3, 5], [1, 3, 5], [1, 3, 5]],
512, [10, 4, 2, 2, 2],
[16, 16, 4, 4, 4], 512,
109, [16, 16, 4, 4, 4],
256, 109,
32000, 256,
] 32000,
]
else:
opt["config"] = [
513,
32,
192,
192,
768,
2,
6,
3,
0,
"1",
[3, 7, 11],
[[1, 3, 5], [1, 3, 5], [1, 3, 5]],
[10,8,2,2],
512,
[20,16,4,4],
109,
256,
32000,
]
if info == "": if info == "":
info = "Extracted model." info = "Extracted model."
opt["info"] = info opt["info"] = info