Spaces:
Running
Running
Kung-Hsiang Huang
commited on
Commit
·
2317ce5
1
Parent(s):
eb11dfa
fix rounding issue
Browse files
app.py
CHANGED
|
@@ -58,7 +58,7 @@ def update_table(
|
|
| 58 |
|
| 59 |
df = df.round(decimals=1)
|
| 60 |
|
| 61 |
-
return df
|
| 62 |
|
| 63 |
|
| 64 |
# def highlight_cols(x):
|
|
@@ -85,7 +85,7 @@ def init_leaderboard_df(
|
|
| 85 |
# use_case_type_query: list,
|
| 86 |
# metric_area_query: list,
|
| 87 |
):
|
| 88 |
-
|
| 89 |
# Applying the style function
|
| 90 |
# return df.style.apply(highlight_cols, axis=None)
|
| 91 |
return update_table(
|
|
@@ -264,22 +264,16 @@ with demo:
|
|
| 264 |
# info="Range: 0.0 to 4.0",
|
| 265 |
# interactive=True,
|
| 266 |
# )
|
| 267 |
-
|
| 268 |
-
leaderboard_table = gr.components.Dataframe(
|
| 269 |
-
# value=leaderboard_df[[c.name for c in fields(AutoEvalColumn) if c.never_hidden] + shown_columns.value],
|
| 270 |
-
value=init_leaderboard_df(
|
| 271 |
leaderboard_df,
|
| 272 |
shown_columns.value,
|
| 273 |
filter_agentic_framework.value
|
| 274 |
-
|
| 275 |
-
|
| 276 |
-
|
| 277 |
-
|
| 278 |
-
|
| 279 |
-
|
| 280 |
-
# filter_use_case_type.value,
|
| 281 |
-
# filter_metric_area.value,
|
| 282 |
-
),
|
| 283 |
headers=[c.name for c in fields(AutoEvalColumn) if c.never_hidden] + shown_columns.value,
|
| 284 |
datatype=TYPES,
|
| 285 |
elem_id="leaderboard-table",
|
|
|
|
| 58 |
|
| 59 |
df = df.round(decimals=1)
|
| 60 |
|
| 61 |
+
return df
|
| 62 |
|
| 63 |
|
| 64 |
# def highlight_cols(x):
|
|
|
|
| 85 |
# use_case_type_query: list,
|
| 86 |
# metric_area_query: list,
|
| 87 |
):
|
| 88 |
+
|
| 89 |
# Applying the style function
|
| 90 |
# return df.style.apply(highlight_cols, axis=None)
|
| 91 |
return update_table(
|
|
|
|
| 264 |
# info="Range: 0.0 to 4.0",
|
| 265 |
# interactive=True,
|
| 266 |
# )
|
| 267 |
+
lb = init_leaderboard_df(
|
|
|
|
|
|
|
|
|
|
| 268 |
leaderboard_df,
|
| 269 |
shown_columns.value,
|
| 270 |
filter_agentic_framework.value
|
| 271 |
+
|
| 272 |
+
)
|
| 273 |
+
|
| 274 |
+
leaderboard_table = gr.components.Dataframe(
|
| 275 |
+
# value=leaderboard_df[[c.name for c in fields(AutoEvalColumn) if c.never_hidden] + shown_columns.value],
|
| 276 |
+
value=lb,
|
|
|
|
|
|
|
|
|
|
| 277 |
headers=[c.name for c in fields(AutoEvalColumn) if c.never_hidden] + shown_columns.value,
|
| 278 |
datatype=TYPES,
|
| 279 |
elem_id="leaderboard-table",
|