Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -20,7 +20,7 @@ vae = get_vae().to(device)
|
|
| 20 |
|
| 21 |
def translation_wrapper(text: str):
|
| 22 |
input_ids = translation_tokenizer.encode(text, return_tensors="pt")
|
| 23 |
-
outputs = translation_model.generate(input_ids)
|
| 24 |
decoded = translation_tokenizer.decode(outputs[0].float(), skip_special_tokens=True)
|
| 25 |
return decoded
|
| 26 |
|
|
|
|
| 20 |
|
| 21 |
def translation_wrapper(text: str):
|
| 22 |
input_ids = translation_tokenizer.encode(text, return_tensors="pt")
|
| 23 |
+
outputs = translation_model.generate(input_ids.to(device))
|
| 24 |
decoded = translation_tokenizer.decode(outputs[0].float(), skip_special_tokens=True)
|
| 25 |
return decoded
|
| 26 |
|