Spaces:
Sleeping
Sleeping
add time log and reduce processing time
Browse files
app.py
CHANGED
@@ -11,8 +11,8 @@ logger = logging.getLogger(__name__)
|
|
11 |
app = FastAPI()
|
12 |
|
13 |
# Load model and tokenizer
|
14 |
-
tokenizer = AutoTokenizer.from_pretrained("VietAI/vit5-
|
15 |
-
model = AutoModelForSeq2SeqLM.from_pretrained("VietAI/vit5-
|
16 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
17 |
model.to(device)
|
18 |
|
|
|
11 |
app = FastAPI()
|
12 |
|
13 |
# Load model and tokenizer
|
14 |
+
tokenizer = AutoTokenizer.from_pretrained("VietAI/vit5-large-vietnews-summarization")
|
15 |
+
model = AutoModelForSeq2SeqLM.from_pretrained("VietAI/vit5-large-vietnews-summarization")
|
16 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
17 |
model.to(device)
|
18 |
|