Spaces:
Sleeping
Sleeping
Quintino Fernandes
commited on
Commit
·
4902a85
1
Parent(s):
e773b70
model fix
Browse files- models/summarization.py +0 -2
models/summarization.py
CHANGED
@@ -8,8 +8,6 @@ class SummarizationModel:
|
|
8 |
self.model = T5ForConditionalGeneration.from_pretrained('recogna-nlp/ptt5-base-summ').to(self.device)
|
9 |
|
10 |
def summarize(self, text: str) -> str:
|
11 |
-
print(next(self.tokenizer.parameters()).device)
|
12 |
-
print(next(self.model.parameters()).device)
|
13 |
"""Summarize the input text using T5 model"""
|
14 |
# Model and tokenization parameters
|
15 |
inputs = self.tokenizer.encode(
|
|
|
8 |
self.model = T5ForConditionalGeneration.from_pretrained('recogna-nlp/ptt5-base-summ').to(self.device)
|
9 |
|
10 |
def summarize(self, text: str) -> str:
|
|
|
|
|
11 |
"""Summarize the input text using T5 model"""
|
12 |
# Model and tokenization parameters
|
13 |
inputs = self.tokenizer.encode(
|