John Graham Reynolds
commited on
Commit
·
31ed20e
1
Parent(s):
bb107ac
change to add from add_batch
Browse files
app.py
CHANGED
@@ -39,10 +39,10 @@ def evaluation(predictions, metrics) -> str:
|
|
39 |
|
40 |
combined = evaluate.combine(combined_list)
|
41 |
|
42 |
-
predicted = predictions["Predicted Label"].to_list()
|
43 |
-
references = predictions["Actual Label"].to_list()
|
44 |
|
45 |
-
combined.
|
46 |
outputs = combined.compute()
|
47 |
|
48 |
return "Your metrics are as follows: \n" + outputs
|
@@ -76,7 +76,7 @@ space = gr.Interface(
|
|
76 |
fn=evaluation,
|
77 |
inputs=[
|
78 |
gr.Dataframe(
|
79 |
-
headers=["Predicted Label", "Actual Label"],
|
80 |
datatype=["number", "number"],
|
81 |
row_count=5,
|
82 |
col_count=(2, "fixed"),
|
|
|
39 |
|
40 |
combined = evaluate.combine(combined_list)
|
41 |
|
42 |
+
predicted = predictions["Predicted Class Label"].to_list()
|
43 |
+
references = predictions["Actual Class Label"].to_list()
|
44 |
|
45 |
+
combined.add(prediction=predicted, reference=references)
|
46 |
outputs = combined.compute()
|
47 |
|
48 |
return "Your metrics are as follows: \n" + outputs
|
|
|
76 |
fn=evaluation,
|
77 |
inputs=[
|
78 |
gr.Dataframe(
|
79 |
+
headers=["Predicted Class Label", "Actual Class Label"],
|
80 |
datatype=["number", "number"],
|
81 |
row_count=5,
|
82 |
col_count=(2, "fixed"),
|