Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Update app.py
Browse files
app.py
CHANGED
@@ -279,10 +279,15 @@ with demo:
|
|
279 |
# interactive=False,
|
280 |
# visible=True,
|
281 |
# )
|
|
|
|
|
|
|
|
|
|
|
282 |
leaderboard_table = gr.components.Dataframe(
|
283 |
-
value=leaderboard_df_filtered,
|
284 |
headers=list(leaderboard_df_filtered.columns),
|
285 |
-
datatype=
|
286 |
elem_id="leaderboard-table",
|
287 |
interactive=False,
|
288 |
visible=True,
|
|
|
279 |
# interactive=False,
|
280 |
# visible=True,
|
281 |
# )
|
282 |
+
|
283 |
+
print("Columns in leaderboard_df_filtered:", leaderboard_df_filtered.columns)
|
284 |
+
|
285 |
+
datatype_dict = {col: "markdown" if col == "Model" else "str" for col in leaderboard_df_filtered.columns}
|
286 |
+
|
287 |
leaderboard_table = gr.components.Dataframe(
|
288 |
+
value=leaderboard_df_filtered.to_dict('records'), # DataFrame を辞書のリストに変換
|
289 |
headers=list(leaderboard_df_filtered.columns),
|
290 |
+
datatype=datatype_dict,
|
291 |
elem_id="leaderboard-table",
|
292 |
interactive=False,
|
293 |
visible=True,
|