Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -24,7 +24,7 @@ generator = keras.models.load_model(model_path, compile=False)
|
|
| 24 |
def text_to_audio(text):
|
| 25 |
# Configuraciones
|
| 26 |
sample_rate = 8000 # Frecuencia de muestreo
|
| 27 |
-
target_length = 1
|
| 28 |
default_audio = np.zeros(target_length, dtype=np.float32)
|
| 29 |
|
| 30 |
if not text or not text.strip():
|
|
|
|
| 24 |
def text_to_audio(text):
|
| 25 |
# Configuraciones
|
| 26 |
sample_rate = 8000 # Frecuencia de muestreo
|
| 27 |
+
target_length = 1 * sample_rate # 2 segundos a 8000 Hz = 16000 muestras
|
| 28 |
default_audio = np.zeros(target_length, dtype=np.float32)
|
| 29 |
|
| 30 |
if not text or not text.strip():
|