Spaces:
Sleeping
Sleeping
daljeetsingh
commited on
Commit
•
f2a9e61
1
Parent(s):
5818333
changes
Browse files
app.py
CHANGED
@@ -13,10 +13,11 @@ logger = logging.get_logger("transformers")
|
|
13 |
model_name='t5-small'
|
14 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
15 |
original_model = AutoModelForSeq2SeqLM.from_pretrained(model_name, torch_dtype=torch.bfloat16)
|
16 |
-
original_model.to('cuda')
|
17 |
|
18 |
ft_model_name="daljeetsingh/sql_ft_t5small_kag" #"cssupport/t5-small-awesome-text-to-sql"
|
19 |
ft_model = AutoModelForSeq2SeqLM.from_pretrained(ft_model_name, torch_dtype=torch.bfloat16)
|
|
|
|
|
20 |
ft_model.to('cuda')
|
21 |
|
22 |
@spaces.GPU
|
|
|
13 |
model_name='t5-small'
|
14 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
15 |
original_model = AutoModelForSeq2SeqLM.from_pretrained(model_name, torch_dtype=torch.bfloat16)
|
|
|
16 |
|
17 |
ft_model_name="daljeetsingh/sql_ft_t5small_kag" #"cssupport/t5-small-awesome-text-to-sql"
|
18 |
ft_model = AutoModelForSeq2SeqLM.from_pretrained(ft_model_name, torch_dtype=torch.bfloat16)
|
19 |
+
|
20 |
+
original_model.to('cuda')
|
21 |
ft_model.to('cuda')
|
22 |
|
23 |
@spaces.GPU
|