fix: json format (#84)
* Update extract_locale.py * Apply Code Formatter Change * Update locale_diff.py * Apply Code Formatter Change --------- Co-authored-by: fumiama <fumiama@users.noreply.github.com>
This commit is contained in:
parent
5ab6713bb3
commit
b0f8a4c7d1
@ -28,3 +28,4 @@ process("gui.py")
|
||||
# Save as a JSON file
|
||||
with open("./i18n/zh_CN.json", "w", encoding="utf-8") as f:
|
||||
json.dump(data, f, ensure_ascii=False, indent=4)
|
||||
f.write("\n")
|
||||
|
3
gui.py
3
gui.py
@ -1,4 +1,5 @@
|
||||
import os,sys
|
||||
import os, sys
|
||||
|
||||
now_dir = os.getcwd()
|
||||
sys.path.append(now_dir)
|
||||
import PySimpleGUI as sg
|
||||
|
@ -42,3 +42,4 @@ for lang_file in languages:
|
||||
# Save the updated language file
|
||||
with open(lang_file, "w", encoding="utf-8") as f:
|
||||
json.dump(lang_data, f, ensure_ascii=False, indent=4)
|
||||
f.write("\n")
|
||||
|
13
infer-web.py
13
infer-web.py
@ -139,8 +139,17 @@ def vc_single(
|
||||
if hubert_model == None:
|
||||
load_hubert()
|
||||
if_f0 = cpt.get("f0", 1)
|
||||
file_index = file_index.strip(" ").strip('"').strip("\n").strip('"').strip(" ").replace("trained","added")#防止小白写错,自动帮他替换掉
|
||||
file_big_npy = file_big_npy.strip(" ").strip('"').strip("\n").strip('"').strip(" ")
|
||||
file_index = (
|
||||
file_index.strip(" ")
|
||||
.strip('"')
|
||||
.strip("\n")
|
||||
.strip('"')
|
||||
.strip(" ")
|
||||
.replace("trained", "added")
|
||||
) # 防止小白写错,自动帮他替换掉
|
||||
file_big_npy = (
|
||||
file_big_npy.strip(" ").strip('"').strip("\n").strip('"').strip(" ")
|
||||
)
|
||||
audio_opt = vc.pipeline(
|
||||
hubert_model,
|
||||
net_g,
|
||||
|
@ -39,7 +39,7 @@ class PreProcess:
|
||||
max_sil_kept=150,
|
||||
)
|
||||
self.sr = sr
|
||||
self.bh, self.ah = signal.butter(N=5, Wn=48, btype='high', fs=self.sr)
|
||||
self.bh, self.ah = signal.butter(N=5, Wn=48, btype="high", fs=self.sr)
|
||||
self.per = 3.7
|
||||
self.overlap = 0.3
|
||||
self.tail = self.per + self.overlap
|
||||
|
@ -5,7 +5,9 @@ from config import x_pad, x_query, x_center, x_max
|
||||
import scipy.signal as signal
|
||||
import pyworld, os, traceback, faiss
|
||||
from scipy import signal
|
||||
bh, ah = signal.butter(N=5, Wn=48, btype='high', fs=16000)
|
||||
|
||||
bh, ah = signal.butter(N=5, Wn=48, btype="high", fs=16000)
|
||||
|
||||
|
||||
class VC(object):
|
||||
def __init__(self, tgt_sr, device, is_half):
|
||||
|
Loading…
Reference in New Issue
Block a user