anton-l HF staff commited on
Commit
0fef3d0
β€’
1 Parent(s): 976f94a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
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