Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -132,7 +132,7 @@ async def main(
|
|
132 |
sess_options = onnxruntime.SessionOptions()
|
133 |
model = None
|
134 |
onnx_models = detect_onnx_models(models_path)
|
135 |
-
|
136 |
if len(text_input) == 0:
|
137 |
text_input = "1, 2, 3. This is a test. Enter some text to generate."
|
138 |
# speaker_selection = widgets.Dropdown(
|
@@ -147,6 +147,11 @@ async def main(
|
|
147 |
elif isinstance(onnx_models, str):
|
148 |
onnx_model = onnx_models
|
149 |
model, config = load_onnx(onnx_model, sess_options, providers)
|
|
|
|
|
|
|
|
|
|
|
150 |
print("nuber of speakers = ", config["num_speakers"])
|
151 |
print("speaker", speaker)
|
152 |
# rate = speed_slider.value
|
|
|
132 |
sess_options = onnxruntime.SessionOptions()
|
133 |
model = None
|
134 |
onnx_models = detect_onnx_models(models_path)
|
135 |
+
|
136 |
if len(text_input) == 0:
|
137 |
text_input = "1, 2, 3. This is a test. Enter some text to generate."
|
138 |
# speaker_selection = widgets.Dropdown(
|
|
|
147 |
elif isinstance(onnx_models, str):
|
148 |
onnx_model = onnx_models
|
149 |
model, config = load_onnx(onnx_model, sess_options, providers)
|
150 |
+
config["espeak"]["voice"] == speaker
|
151 |
+
|
152 |
+
lan.load_language(speaker)
|
153 |
+
|
154 |
+
|
155 |
print("nuber of speakers = ", config["num_speakers"])
|
156 |
print("speaker", speaker)
|
157 |
# rate = speed_slider.value
|