Spaces:
Running
Running
Update OpenVoice/text/__init__.py
Browse files
OpenVoice/text/__init__.py
CHANGED
@@ -1,7 +1,6 @@
|
|
1 |
""" from https://github.com/keithito/tacotron """
|
2 |
from . import cleaners
|
3 |
-
from .symbols import symbols
|
4 |
-
|
5 |
|
6 |
# Mappings from symbol to numeric ID and vice versa:
|
7 |
_symbol_to_id = {s: i for i, s in enumerate(symbols)}
|
@@ -41,9 +40,6 @@ def cleaned_text_to_sequence(cleaned_text, symbols):
|
|
41 |
sequence = [symbol_to_id[symbol] for symbol in cleaned_text if symbol in symbol_to_id.keys()]
|
42 |
return sequence
|
43 |
|
44 |
-
|
45 |
-
|
46 |
-
from text.symbols import language_tone_start_map
|
47 |
def cleaned_text_to_sequence_vits2(cleaned_text, tones, language, symbols, languages):
|
48 |
"""Converts a string of text to a sequence of IDs corresponding to the symbols in the text.
|
49 |
Args:
|
|
|
1 |
""" from https://github.com/keithito/tacotron """
|
2 |
from . import cleaners
|
3 |
+
from .symbols import symbols, language_tone_start_map
|
|
|
4 |
|
5 |
# Mappings from symbol to numeric ID and vice versa:
|
6 |
_symbol_to_id = {s: i for i, s in enumerate(symbols)}
|
|
|
40 |
sequence = [symbol_to_id[symbol] for symbol in cleaned_text if symbol in symbol_to_id.keys()]
|
41 |
return sequence
|
42 |
|
|
|
|
|
|
|
43 |
def cleaned_text_to_sequence_vits2(cleaned_text, tones, language, symbols, languages):
|
44 |
"""Converts a string of text to a sequence of IDs corresponding to the symbols in the text.
|
45 |
Args:
|