Spaces:
Runtime error
Runtime error
Commit
•
517bcc3
1
Parent(s):
36749b6
set to device() in synthesise(); added print() dir to synthesise()
Browse files
app.py
CHANGED
@@ -27,8 +27,9 @@ def translate(audio):
|
|
27 |
def synthesise(text):
|
28 |
inputs = tokenizer(text, return_tensors="pt")
|
29 |
with torch.no_grad():
|
30 |
-
|
31 |
-
|
|
|
32 |
|
33 |
|
34 |
def speech_to_speech_translation(audio):
|
|
|
27 |
def synthesise(text):
|
28 |
inputs = tokenizer(text, return_tensors="pt")
|
29 |
with torch.no_grad():
|
30 |
+
speech = model(inputs["input_ids"].to(device))
|
31 |
+
print(dir(speech))
|
32 |
+
return speech.waveform
|
33 |
|
34 |
|
35 |
def speech_to_speech_translation(audio):
|