Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -11,6 +11,7 @@ def modelo1(audio):
|
|
| 11 |
whisper = pipeline('automatic-speech-recognition', model='openai/whisper-medium', device=-1) # Cambia 'device' a -1 para usar la CPU
|
| 12 |
print(np.array(audio[1]))
|
| 13 |
text = whisper(np.array(audio[1]))
|
|
|
|
| 14 |
return text["text"]
|
| 15 |
def modelo2(text):
|
| 16 |
model_id = "stabilityai/stable-diffusion-2-1"
|
|
|
|
| 11 |
whisper = pipeline('automatic-speech-recognition', model='openai/whisper-medium', device=-1) # Cambia 'device' a -1 para usar la CPU
|
| 12 |
print(np.array(audio[1]))
|
| 13 |
text = whisper(np.array(audio[1]))
|
| 14 |
+
print(text["text"])
|
| 15 |
return text["text"]
|
| 16 |
def modelo2(text):
|
| 17 |
model_id = "stabilityai/stable-diffusion-2-1"
|