mirror of
https://github.com/RVC-Boss/GPT-SoVITS.git
synced 2026-11-17 18:43:37 +08:00
Merge 7e66149757785f355ef3a9194bd68e162ad051ad into 6d51ffceafbf240145619af4c92408a6e54b7924
This commit is contained in:
commit
b86e3687ea
@ -13,7 +13,7 @@ normalizer = lambda x: cn2an.transform(x, "an2cn")
|
||||
current_file_path = os.path.dirname(__file__)
|
||||
pinyin_to_symbol_map = {
|
||||
line.split("\t")[0]: line.strip().split("\t")[1]
|
||||
for line in open(os.path.join(current_file_path, "opencpop-strict.txt")).readlines()
|
||||
for line in open(os.path.join(current_file_path, "opencpop-strict.txt"), encoding="utf-8").readlines()
|
||||
}
|
||||
|
||||
import jieba_fast
|
||||
|
||||
@ -14,7 +14,7 @@ normalizer = lambda x: cn2an.transform(x, "an2cn")
|
||||
current_file_path = os.path.dirname(__file__)
|
||||
pinyin_to_symbol_map = {
|
||||
line.split("\t")[0]: line.strip().split("\t")[1]
|
||||
for line in open(os.path.join(current_file_path, "opencpop-strict.txt")).readlines()
|
||||
for line in open(os.path.join(current_file_path, "opencpop-strict.txt"), encoding="utf-8").readlines()
|
||||
}
|
||||
|
||||
import jieba_fast
|
||||
|
||||
@ -131,7 +131,7 @@ def replace_consecutive_punctuation(text):
|
||||
def read_dict():
|
||||
g2p_dict = {}
|
||||
start_line = 49
|
||||
with open(CMU_DICT_PATH) as f:
|
||||
with open(CMU_DICT_PATH, encoding="utf-8") as f:
|
||||
line = f.readline()
|
||||
line_index = 1
|
||||
while line:
|
||||
@ -154,7 +154,7 @@ def read_dict():
|
||||
|
||||
def read_dict_new():
|
||||
g2p_dict = {}
|
||||
with open(CMU_DICT_PATH) as f:
|
||||
with open(CMU_DICT_PATH, encoding="utf-8") as f:
|
||||
line = f.readline()
|
||||
line_index = 1
|
||||
while line:
|
||||
@ -167,7 +167,7 @@ def read_dict_new():
|
||||
line_index = line_index + 1
|
||||
line = f.readline()
|
||||
|
||||
with open(CMU_DICT_FAST_PATH) as f:
|
||||
with open(CMU_DICT_FAST_PATH, encoding="utf-8") as f:
|
||||
line = f.readline()
|
||||
line_index = 1
|
||||
while line:
|
||||
@ -185,7 +185,7 @@ def read_dict_new():
|
||||
|
||||
|
||||
def hot_reload_hot(g2p_dict):
|
||||
with open(CMU_DICT_HOT_PATH) as f:
|
||||
with open(CMU_DICT_HOT_PATH, encoding="utf-8") as f:
|
||||
line = f.readline()
|
||||
line_index = 1
|
||||
while line:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user