edit app.py
Browse files
app.py
CHANGED
@@ -28,7 +28,7 @@ def create_tts_fn(model, hps, speaker_ids):
|
|
28 |
def tts_fn(text, speaker, speed, is_phoneme):
|
29 |
if limitation:
|
30 |
text_len = len(text)
|
31 |
-
max_len =
|
32 |
if is_phoneme:
|
33 |
max_len *= 3
|
34 |
else:
|
@@ -83,7 +83,7 @@ if __name__ == '__main__':
|
|
83 |
models_tts = []
|
84 |
name = 'γγ«γ’γ« TTS'
|
85 |
lang = 'ζ₯ζ¬θͺ (Japanese)'
|
86 |
-
example = '
|
87 |
config_path = f"saved_model/config.json"
|
88 |
model_path = f"saved_model/model.pth"
|
89 |
cover_path = f"saved_model/cover.png"
|
@@ -107,8 +107,8 @@ if __name__ == '__main__':
|
|
107 |
app = gr.Blocks(css=css)
|
108 |
|
109 |
with app:
|
110 |
-
gr.Markdown("#
|
111 |
-
"![visitor badge](https://visitor-badge.glitch.me/badge?page_id=kdrkdrkdr.
|
112 |
|
113 |
for i, (name, cover_path, speakers, lang, example, symbols, tts_fn,
|
114 |
to_phoneme_fn) in enumerate(models_tts):
|
@@ -117,7 +117,7 @@ if __name__ == '__main__':
|
|
117 |
gr.Markdown(f"## {name}\n\n"
|
118 |
f"![cover](file/{cover_path})\n\n"
|
119 |
f"lang: {lang}")
|
120 |
-
tts_input1 = gr.TextArea(label="Text (
|
121 |
elem_id=f"tts-input{i}")
|
122 |
tts_input2 = gr.Dropdown(label="Speaker", choices=speakers,
|
123 |
type="index", value=speakers[0])
|
|
|
28 |
def tts_fn(text, speaker, speed, is_phoneme):
|
29 |
if limitation:
|
30 |
text_len = len(text)
|
31 |
+
max_len = 100
|
32 |
if is_phoneme:
|
33 |
max_len *= 3
|
34 |
else:
|
|
|
83 |
models_tts = []
|
84 |
name = 'γγ«γ’γ« TTS'
|
85 |
lang = 'ζ₯ζ¬θͺ (Japanese)'
|
86 |
+
example = 'ε
ηγγ‘γγ£γ¨γζιγγγ γγΎγγοΌ'
|
87 |
config_path = f"saved_model/config.json"
|
88 |
model_path = f"saved_model/model.pth"
|
89 |
cover_path = f"saved_model/cover.png"
|
|
|
107 |
app = gr.Blocks(css=css)
|
108 |
|
109 |
with app:
|
110 |
+
gr.Markdown("# BlueArchive Yuuka TTS Using Vits Model\n"
|
111 |
+
"![visitor badge](https://visitor-badge.glitch.me/badge?page_id=kdrkdrkdr.YuukaTTS)\n\n")
|
112 |
|
113 |
for i, (name, cover_path, speakers, lang, example, symbols, tts_fn,
|
114 |
to_phoneme_fn) in enumerate(models_tts):
|
|
|
117 |
gr.Markdown(f"## {name}\n\n"
|
118 |
f"![cover](file/{cover_path})\n\n"
|
119 |
f"lang: {lang}")
|
120 |
+
tts_input1 = gr.TextArea(label="Text (100 words limitation)", value=example,
|
121 |
elem_id=f"tts-input{i}")
|
122 |
tts_input2 = gr.Dropdown(label="Speaker", choices=speakers,
|
123 |
type="index", value=speakers[0])
|