Spaces:
Sleeping
Sleeping
mrolando
commited on
Commit
·
03fc7c5
1
Parent(s):
4f62fd7
second
Browse files- app.py +11 -11
- requirements.txt +3 -1
app.py
CHANGED
@@ -43,13 +43,13 @@ def query_chatgpt(text):
|
|
43 |
|
44 |
|
45 |
|
46 |
-
models, cfg, task = load_model_ensemble_and_task_from_hf_hub(
|
47 |
-
|
48 |
-
|
49 |
-
)
|
50 |
-
model = models[0]
|
51 |
-
TTSHubInterface.update_cfg_with_data_cfg(cfg, task.data_cfg)
|
52 |
-
generator = task.build_generator([model], cfg)
|
53 |
|
54 |
# text = "Había una vez."
|
55 |
|
@@ -60,10 +60,10 @@ generator = task.build_generator([model], cfg)
|
|
60 |
from tts import synthesize
|
61 |
|
62 |
|
63 |
-
def syn_facebookmms(text):
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
|
68 |
def answer_question(filepath):
|
69 |
transcription = transcribe_speech(filepath)
|
|
|
43 |
|
44 |
|
45 |
|
46 |
+
# models, cfg, task = load_model_ensemble_and_task_from_hf_hub(
|
47 |
+
# "facebook/tts_transformer-es-css10",
|
48 |
+
# arg_overrides={"vocoder": "hifigan", "fp16": False}
|
49 |
+
# )
|
50 |
+
# model = models[0]
|
51 |
+
# TTSHubInterface.update_cfg_with_data_cfg(cfg, task.data_cfg)
|
52 |
+
# generator = task.build_generator([model], cfg)
|
53 |
|
54 |
# text = "Había una vez."
|
55 |
|
|
|
60 |
from tts import synthesize
|
61 |
|
62 |
|
63 |
+
# def syn_facebookmms(text):
|
64 |
+
# sample = TTSHubInterface.get_model_input(task, text)
|
65 |
+
# wav,rate = TTSHubInterface.get_prediction(task, model, generator, sample)
|
66 |
+
# return wav,rate
|
67 |
|
68 |
def answer_question(filepath):
|
69 |
transcription = transcribe_speech(filepath)
|
requirements.txt
CHANGED
@@ -9,4 +9,6 @@ torch
|
|
9 |
torchvision
|
10 |
matplotlib
|
11 |
Unidecode
|
12 |
-
openai
|
|
|
|
|
|
9 |
torchvision
|
10 |
matplotlib
|
11 |
Unidecode
|
12 |
+
openai
|
13 |
+
dotenv
|
14 |
+
fairseq
|