Spaces:
Running
Running
Commit
·
b760f7b
1
Parent(s):
98c4cda
Update app.py
Browse files
app.py
CHANGED
@@ -16,7 +16,7 @@ description2 = "<h3>Demo EmotioNL</h3>\nThis demo allows you to analyse the emot
|
|
16 |
|
17 |
inference_modelpath = "model/checkpoint-128"
|
18 |
|
19 |
-
|
20 |
output_dir = "model"
|
21 |
model_config = {
|
22 |
"model_weights": "pdelobelle/robbert-v2-dutch-base",
|
@@ -118,7 +118,7 @@ def inference_dataset(file_object, option_list):
|
|
118 |
if "topics" in option_list:
|
119 |
output5 = "This option was selected."
|
120 |
return [output1, output2, output3, output4, output5]
|
121 |
-
|
122 |
def what_happened(text, file_object, option_list):
|
123 |
if file_object:
|
124 |
output = "You uploaded a file."
|
@@ -190,7 +190,8 @@ iface_sentence = gr.Interface(
|
|
190 |
outputs="text")
|
191 |
|
192 |
iface2 = gr.Interface(
|
193 |
-
fn=what_happened2,
|
|
|
194 |
description = description2,
|
195 |
inputs=[
|
196 |
gr.File(
|
|
|
16 |
|
17 |
inference_modelpath = "model/checkpoint-128"
|
18 |
|
19 |
+
"""
|
20 |
output_dir = "model"
|
21 |
model_config = {
|
22 |
"model_weights": "pdelobelle/robbert-v2-dutch-base",
|
|
|
118 |
if "topics" in option_list:
|
119 |
output5 = "This option was selected."
|
120 |
return [output1, output2, output3, output4, output5]
|
121 |
+
|
122 |
def what_happened(text, file_object, option_list):
|
123 |
if file_object:
|
124 |
output = "You uploaded a file."
|
|
|
190 |
outputs="text")
|
191 |
|
192 |
iface2 = gr.Interface(
|
193 |
+
#fn=what_happened2,
|
194 |
+
fn = inference_dataset,
|
195 |
description = description2,
|
196 |
inputs=[
|
197 |
gr.File(
|