Spaces:
Sleeping
Sleeping
paragon-analytics
commited on
Commit
•
998e5ed
1
Parent(s):
a6d17eb
Update app.py
Browse files
app.py
CHANGED
@@ -12,6 +12,10 @@ from transformers import AutoModelForSequenceClassification
|
|
12 |
from transformers import TFAutoModelForSequenceClassification
|
13 |
from transformers import AutoTokenizer
|
14 |
import matplotlib.pyplot as plt
|
|
|
|
|
|
|
|
|
15 |
|
16 |
device = "cuda:0" if torch.cuda.is_available() else "cpu"
|
17 |
|
@@ -92,7 +96,7 @@ with gr.Blocks(title=title) as demo:
|
|
92 |
|
93 |
with gr.Row():
|
94 |
gr.Markdown("### Click on any of the examples below to see how it works:")
|
95 |
-
gr.Examples([["
|
96 |
# , sym
|
97 |
], main, cache_examples=True)
|
98 |
|
|
|
12 |
from transformers import TFAutoModelForSequenceClassification
|
13 |
from transformers import AutoTokenizer
|
14 |
import matplotlib.pyplot as plt
|
15 |
+
import sys
|
16 |
+
import csv
|
17 |
+
|
18 |
+
csv.field_size_limit(sys.maxsize)
|
19 |
|
20 |
device = "cuda:0" if torch.cuda.is_available() else "cpu"
|
21 |
|
|
|
96 |
|
97 |
with gr.Row():
|
98 |
gr.Markdown("### Click on any of the examples below to see how it works:")
|
99 |
+
gr.Examples([["I had severe headache after taking Aspirin."],["I had minor stomachache after taking Acetaminophen."]], [prob1], [label,local_plot, med
|
100 |
# , sym
|
101 |
], main, cache_examples=True)
|
102 |
|