Hecheng0625
commited on
Commit
•
8695770
1
Parent(s):
84137be
Update app.py
Browse files
app.py
CHANGED
@@ -327,6 +327,18 @@ def inference(
|
|
327 |
sf.write(save_path, recovered_audio, 24000)
|
328 |
return save_path
|
329 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
330 |
|
331 |
# Language list
|
332 |
language_list = ["en", "zh", "ja", "ko", "fr", "de"]
|
|
|
327 |
sf.write(save_path, recovered_audio, 24000)
|
328 |
return save_path
|
329 |
|
330 |
+
# Load models once
|
331 |
+
(
|
332 |
+
semantic_model,
|
333 |
+
semantic_mean,
|
334 |
+
semantic_std,
|
335 |
+
semantic_codec,
|
336 |
+
codec_encoder,
|
337 |
+
codec_decoder,
|
338 |
+
t2s_model,
|
339 |
+
s2a_model_1layer,
|
340 |
+
s2a_model_full,
|
341 |
+
) = load_models()
|
342 |
|
343 |
# Language list
|
344 |
language_list = ["en", "zh", "ja", "ko", "fr", "de"]
|