Gagan Bhatia commited on
Commit
8291502
·
1 Parent(s): bf102c2

Update model.py

Browse files
Files changed (1) hide show
  1. src/models/model.py +1 -0
src/models/model.py CHANGED
@@ -357,6 +357,7 @@ class Summarization:
357
  if model_type == "t5":
358
  self.tokenizer = T5Tokenizer.from_pretrained(f"{model_dir}")
359
  self.model = T5ForConditionalGeneration.from_pretrained(
 
360
 
361
  if use_gpu:
362
  if torch.cuda.is_available():
 
357
  if model_type == "t5":
358
  self.tokenizer = T5Tokenizer.from_pretrained(f"{model_dir}")
359
  self.model = T5ForConditionalGeneration.from_pretrained(
360
+ f"{model_dir}", return_dict=True
361
 
362
  if use_gpu:
363
  if torch.cuda.is_available():