Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -3,9 +3,12 @@ import gradio as gr
|
|
3 |
import torch
|
4 |
from transformers import pipeline
|
5 |
|
|
|
|
|
|
|
6 |
examples = [['COVID-19 is'],['A 65-year-old female patient with a past medical history of']]
|
7 |
|
8 |
-
pipe_biogpt = pipeline("text-generation", model="microsoft/biogpt-large")
|
9 |
|
10 |
title = "BioGPT-Large Demo"
|
11 |
description = """
|
|
|
3 |
import torch
|
4 |
from transformers import pipeline
|
5 |
|
6 |
+
print(f"Is CUDA available: {torch.cuda.is_available()}")
|
7 |
+
print(f"CUDA device: {torch.cuda.get_device_name(torch.cuda.current_device())}")
|
8 |
+
|
9 |
examples = [['COVID-19 is'],['A 65-year-old female patient with a past medical history of']]
|
10 |
|
11 |
+
pipe_biogpt = pipeline("text-generation", model="microsoft/biogpt-large", device="cuda:0")
|
12 |
|
13 |
title = "BioGPT-Large Demo"
|
14 |
description = """
|