mirror of
https://github.com/RVC-Boss/GPT-SoVITS.git
synced 2025-10-07 15:19:59 +08:00
Merge 27f503632aadd16f87fee07becd05483ff4d9af1 into 0c25e57959e1f6287cbd0fe8fa07369864af2fd3
This commit is contained in:
commit
05da8f8708
4
api.py
4
api.py
@ -163,7 +163,7 @@ from io import BytesIO
|
|||||||
from module.models import SynthesizerTrn
|
from module.models import SynthesizerTrn
|
||||||
from AR.models.t2s_lightning_module import Text2SemanticLightningModule
|
from AR.models.t2s_lightning_module import Text2SemanticLightningModule
|
||||||
from text import cleaned_text_to_sequence
|
from text import cleaned_text_to_sequence
|
||||||
from text.cleaner import clean_text
|
from text.cleaner import clean_text, language_module_map
|
||||||
from module.mel_processing import spectrogram_torch
|
from module.mel_processing import spectrogram_torch
|
||||||
from tools.my_utils import load_audio
|
from tools.my_utils import load_audio
|
||||||
import config as global_config
|
import config as global_config
|
||||||
@ -290,6 +290,8 @@ def get_phones_and_bert(text,language):
|
|||||||
dtype=torch.float16 if is_half == True else torch.float32,
|
dtype=torch.float16 if is_half == True else torch.float32,
|
||||||
).to(device)
|
).to(device)
|
||||||
elif language in {"zh", "ja","auto"}:
|
elif language in {"zh", "ja","auto"}:
|
||||||
|
if language in ["zh"]:
|
||||||
|
text = language_module_map[language].text_normalize(text)
|
||||||
textlist=[]
|
textlist=[]
|
||||||
langlist=[]
|
langlist=[]
|
||||||
LangSegment.setfilters(["zh","ja","en","ko"])
|
LangSegment.setfilters(["zh","ja","en","ko"])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user