From e5aa6b02a7874d9f9b8083a904c7b3d88397670f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BA=90=E6=96=87=E9=9B=A8?= <41315874+fumiama@users.noreply.github.com> Date: Sun, 16 Jun 2024 20:13:09 +0900 Subject: [PATCH] optimize(i18n): too long translation --- gui.py | 2 +- i18n/i18n.py | 3 +-- i18n/locale/en_US.json | 2 +- i18n/locale/es_ES.json | 2 +- i18n/locale/fr_FR.json | 2 +- i18n/locale/it_IT.json | 2 +- i18n/locale/ja_JP.json | 2 +- i18n/locale/ko_KR.json | 2 +- i18n/locale/pt_BR.json | 2 +- i18n/locale/ru_RU.json | 2 +- i18n/locale/tr_TR.json | 2 +- i18n/locale/zh_CN.json | 2 +- i18n/locale/zh_HK.json | 2 +- i18n/locale/zh_SG.json | 2 +- i18n/locale/zh_TW.json | 2 +- tools/web/infer-only.py | 2 +- web.py | 4 ++-- 17 files changed, 18 insertions(+), 19 deletions(-) diff --git a/gui.py b/gui.py index c460e7b..34e6b6c 100644 --- a/gui.py +++ b/gui.py @@ -373,7 +373,7 @@ if __name__ == "__main__": [ sg.Text( i18n( - "Search feature ratio (controls accent strength, too high has artifacting)" + "Feature searching ratio" ) ), sg.Slider( diff --git a/i18n/i18n.py b/i18n/i18n.py index ea555da..37f401b 100644 --- a/i18n/i18n.py +++ b/i18n/i18n.py @@ -17,8 +17,7 @@ class I18nAuto: language = locale.getdefaultlocale( envvars=("LANG", "LC_ALL", "LC_CTYPE", "LANGUAGE") )[0] - if not os.path.exists(f"./i18n/locale/{language}.json"): - language = "en_US" + language = "en_US" self.language = language self.language_map = load_language_list(language) diff --git a/i18n/locale/en_US.json b/i18n/locale/en_US.json index 1f5f747..f33c5fa 100644 --- a/i18n/locale/en_US.json +++ b/i18n/locale/en_US.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "Save only the latest '.ckpt' file to save disk space", "Saved model name (without extension)": "Saved model name (without extension)", "Sealing date": "Sealing date", - "Search feature ratio (controls accent strength, too high has artifacting)": "Search feature ratio (controls accent strength, too high has artifacting)", + "Feature searching ratio": "Feature searching ratio", "Select Speaker/Singer ID": "Select Speaker/Singer ID", "Select the .index file": "Select the .index file", "Select the .pth file": "Select the .pth file", diff --git a/i18n/locale/es_ES.json b/i18n/locale/es_ES.json index 875e82a..1c253d2 100644 --- a/i18n/locale/es_ES.json +++ b/i18n/locale/es_ES.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "Guardar solo el archivo ckpt más reciente para ahorrar espacio en disco", "Saved model name (without extension)": "Nombre del modelo guardado sin extensión.", "Sealing date": "fecha de sellado", - "Search feature ratio (controls accent strength, too high has artifacting)": "Proporción de función de búsqueda", + "Feature searching ratio": "Proporción de función de búsqueda", "Select Speaker/Singer ID": "Seleccione una identificación de altavoz", "Select the .index file": "Seleccione el archivo .index", "Select the .pth file": "Seleccione el archivo .pth", diff --git a/i18n/locale/fr_FR.json b/i18n/locale/fr_FR.json index da373ef..8ac9d15 100644 --- a/i18n/locale/fr_FR.json +++ b/i18n/locale/fr_FR.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "Enregistrer uniquement le dernier fichier '.ckpt' pour économiser de l'espace disque :", "Saved model name (without extension)": "Nom du modèle enregistré (sans extension) :", "Sealing date": "Date de scellement", - "Search feature ratio (controls accent strength, too high has artifacting)": "Rapport de recherche de caractéristiques (contrôle l'intensité de l'accent, un rapport trop élevé provoque des artefacts) :", + "Feature searching ratio": "Rapport de recherche de caractéristiques (contrôle l'intensité de l'accent, un rapport trop élevé provoque des artefacts) :", "Select Speaker/Singer ID": "Sélectionner l'ID de l'orateur ou du chanteur :", "Select the .index file": "Sélectionner le fichier .index", "Select the .pth file": "Sélectionner le fichier .pth", diff --git a/i18n/locale/it_IT.json b/i18n/locale/it_IT.json index 462f643..7b21a0a 100644 --- a/i18n/locale/it_IT.json +++ b/i18n/locale/it_IT.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "Salva solo l'ultimo file '.ckpt' per risparmiare spazio su disco:", "Saved model name (without extension)": "Nome del modello salvato (senza estensione):", "Sealing date": "封装时间", - "Search feature ratio (controls accent strength, too high has artifacting)": "Rapporto funzionalità di ricerca (controlla la forza dell'accento, troppo alto ha artefatti):", + "Feature searching ratio": "Rapporto funzionalità di ricerca (controlla la forza dell'accento, troppo alto ha artefatti):", "Select Speaker/Singer ID": "Seleziona ID locutore/cantante:", "Select the .index file": "Seleziona il file .index", "Select the .pth file": "Seleziona il file .pth", diff --git a/i18n/locale/ja_JP.json b/i18n/locale/ja_JP.json index 8b21cf0..a330744 100644 --- a/i18n/locale/ja_JP.json +++ b/i18n/locale/ja_JP.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "ハードディスク容量を節約するため、最新のckptファイルのみを保存しますか?", "Saved model name (without extension)": "拡張子のない保存するモデル名", "Sealing date": "締め日付", - "Search feature ratio (controls accent strength, too high has artifacting)": "検索特徴率", + "Feature searching ratio": "検索特徴率", "Select Speaker/Singer ID": "話者IDを選択してください", "Select the .index file": ".indexファイルを選択", "Select the .pth file": ".pthファイルを選択", diff --git a/i18n/locale/ko_KR.json b/i18n/locale/ko_KR.json index ff307ad..7ee3b6d 100644 --- a/i18n/locale/ko_KR.json +++ b/i18n/locale/ko_KR.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "디스크 공간을 절약하기 위해 최신 ckpt 파일만 저장할지 여부", "Saved model name (without extension)": "저장된 모델명은 접미사 없음", "Sealing date": "Sealing date", - "Search feature ratio (controls accent strength, too high has artifacting)": "검색 특징 비율", + "Feature searching ratio": "검색 특징 비율", "Select Speaker/Singer ID": "화자 ID 선택", "Select the .index file": ".index 파일 선택", "Select the .pth file": ".pth 파일 선택", diff --git a/i18n/locale/pt_BR.json b/i18n/locale/pt_BR.json index 0559f6a..3e426f4 100644 --- a/i18n/locale/pt_BR.json +++ b/i18n/locale/pt_BR.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "Só deve salvar apenas o arquivo ckpt mais recente para economizar espaço em disco:", "Saved model name (without extension)": "Nome do modelo salvo (sem extensão):", "Sealing date": "封装时间", - "Search feature ratio (controls accent strength, too high has artifacting)": "Taxa de recurso de recuperação:", + "Feature searching ratio": "Taxa de recurso de recuperação:", "Select Speaker/Singer ID": "Selecione Palestrantes/Cantores ID:", "Select the .index file": "Selecione o Index", "Select the .pth file": "Selecione o Arquivo", diff --git a/i18n/locale/ru_RU.json b/i18n/locale/ru_RU.json index 3aa0f33..77cfe44 100644 --- a/i18n/locale/ru_RU.json +++ b/i18n/locale/ru_RU.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "Сохранять только последний файл '.ckpt', чтобы сохранить место на диске:", "Saved model name (without extension)": "Имя файла модели для сохранения (без расширения):", "Sealing date": "Sealing date", - "Search feature ratio (controls accent strength, too high has artifacting)": "Соотношение поиска черт:", + "Feature searching ratio": "Соотношение поиска черт:", "Select Speaker/Singer ID": "Номер говорящего:", "Select the .index file": "Выбрать файл .index", "Select the .pth file": "Выбрать файл .pth", diff --git a/i18n/locale/tr_TR.json b/i18n/locale/tr_TR.json index 74914be..951334f 100644 --- a/i18n/locale/tr_TR.json +++ b/i18n/locale/tr_TR.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "Sadece en son '.ckpt' dosyasını kaydet:", "Saved model name (without extension)": "Kaydedilecek model adı (uzantı olmadan):", "Sealing date": "Sealing date", - "Search feature ratio (controls accent strength, too high has artifacting)": "Arama özelliği oranı (vurgu gücünü kontrol eder, çok yüksek olması sanal etkilere neden olur)", + "Feature searching ratio": "Arama özelliği oranı (vurgu gücünü kontrol eder, çok yüksek olması sanal etkilere neden olur)", "Select Speaker/Singer ID": "Konuşmacı/Şarkıcı No seçin:", "Select the .index file": ".index dosyası seç", "Select the .pth file": ".pth dosyası seç", diff --git a/i18n/locale/zh_CN.json b/i18n/locale/zh_CN.json index 0bfc69f..01e8c94 100644 --- a/i18n/locale/zh_CN.json +++ b/i18n/locale/zh_CN.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "是否仅保存最新的ckpt文件以节省硬盘空间", "Saved model name (without extension)": "保存的模型名不带后缀", "Sealing date": "封装时间", - "Search feature ratio (controls accent strength, too high has artifacting)": "检索特征占比", + "Feature searching ratio": "检索特征占比", "Select Speaker/Singer ID": "请选择说话人id", "Select the .index file": "选择.index文件", "Select the .pth file": "选择.pth文件", diff --git a/i18n/locale/zh_HK.json b/i18n/locale/zh_HK.json index 92ee1af..760b34e 100644 --- a/i18n/locale/zh_HK.json +++ b/i18n/locale/zh_HK.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "是否僅保存最新的ckpt檔案以節省硬碟空間", "Saved model name (without extension)": "儲存的模型名不帶副檔名", "Sealing date": "封装时间", - "Search feature ratio (controls accent strength, too high has artifacting)": "檢索特徵佔比", + "Feature searching ratio": "檢索特徵佔比", "Select Speaker/Singer ID": "請選擇說話人ID", "Select the .index file": "選擇 .index 檔案", "Select the .pth file": "選擇 .pth 檔案", diff --git a/i18n/locale/zh_SG.json b/i18n/locale/zh_SG.json index 92ee1af..760b34e 100644 --- a/i18n/locale/zh_SG.json +++ b/i18n/locale/zh_SG.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "是否僅保存最新的ckpt檔案以節省硬碟空間", "Saved model name (without extension)": "儲存的模型名不帶副檔名", "Sealing date": "封装时间", - "Search feature ratio (controls accent strength, too high has artifacting)": "檢索特徵佔比", + "Feature searching ratio": "檢索特徵佔比", "Select Speaker/Singer ID": "請選擇說話人ID", "Select the .index file": "選擇 .index 檔案", "Select the .pth file": "選擇 .pth 檔案", diff --git a/i18n/locale/zh_TW.json b/i18n/locale/zh_TW.json index 92ee1af..760b34e 100644 --- a/i18n/locale/zh_TW.json +++ b/i18n/locale/zh_TW.json @@ -114,7 +114,7 @@ "Save only the latest '.ckpt' file to save disk space": "是否僅保存最新的ckpt檔案以節省硬碟空間", "Saved model name (without extension)": "儲存的模型名不帶副檔名", "Sealing date": "封装时间", - "Search feature ratio (controls accent strength, too high has artifacting)": "檢索特徵佔比", + "Feature searching ratio": "檢索特徵佔比", "Select Speaker/Singer ID": "請選擇說話人ID", "Select the .index file": "選擇 .index 檔案", "Select the .pth file": "選擇 .pth 檔案", diff --git a/tools/web/infer-only.py b/tools/web/infer-only.py index 29f096a..7f869ca 100644 --- a/tools/web/infer-only.py +++ b/tools/web/infer-only.py @@ -106,7 +106,7 @@ with app: minimum=0, maximum=1, label=i18n( - "Search feature ratio (controls accent strength, too high has artifacting)" + "Feature searching ratio" ), value=0.88, interactive=True, diff --git a/web.py b/web.py index e43ac2c..8f4d278 100644 --- a/web.py +++ b/web.py @@ -911,7 +911,7 @@ with gr.Blocks(title="RVC WebUI") as app: minimum=0, maximum=1, label=i18n( - "Search feature ratio (controls accent strength, too high has artifacting)" + "Feature searching ratio" ), value=0.75, interactive=True, @@ -1068,7 +1068,7 @@ with gr.Blocks(title="RVC WebUI") as app: minimum=0, maximum=1, label=i18n( - "Search feature ratio (controls accent strength, too high has artifacting)" + "Feature searching ratio" ), value=1, interactive=True,