breadlicker45 commited on
Commit
b72a9d6
·
verified ·
1 Parent(s): a655994

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -1,10 +1,10 @@
1
  import gradio as gr
2
- from transformers import MBartForConditionalGeneration, MBart50TokenizerFast
3
  import torch
4
 
5
  # Load the model and tokenizer
6
  model = MBartForConditionalGeneration.from_pretrained("facebook/mbart-large-50-many-to-many-mmt")
7
- tokenizer = MBart50TokenizerFast.from_pretrained("facebook/mbart-large-50-many-to-many-mmt")
8
 
9
  # Define the language codes supported by the model
10
  language_codes = {
 
1
  import gradio as gr
2
+ from transformers import MBartForConditionalGeneration, MBartTokenizer
3
  import torch
4
 
5
  # Load the model and tokenizer
6
  model = MBartForConditionalGeneration.from_pretrained("facebook/mbart-large-50-many-to-many-mmt")
7
+ tokenizer = MBartTokenizer.from_pretrained("facebook/mbart-large-50-many-to-many-mmt")
8
 
9
  # Define the language codes supported by the model
10
  language_codes = {