legacy107 commited on
Commit
ff2962c
1 Parent(s): a1fb3d5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -3,10 +3,8 @@ from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
3
 
4
  # Load your fine-tuned model and tokenizer
5
  model_name = "legacy107/flan-t5-large-bottleneck-adapter-cpgQA-unique"
6
- tokenizer = AutoTokenizer.from_pretrained(model_name, device_map="auto")
7
- model = AutoModelForSeq2SeqLM.from_pretrained(
8
- model_name, device_map="auto"
9
- )
10
  model.set_active_adapters("question_answering")
11
 
12
  max_length = 512
 
3
 
4
  # Load your fine-tuned model and tokenizer
5
  model_name = "legacy107/flan-t5-large-bottleneck-adapter-cpgQA-unique"
6
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
7
+ model = AutoModelForSeq2SeqLM.from_pretrained(model_name)
 
 
8
  model.set_active_adapters("question_answering")
9
 
10
  max_length = 512