Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -23,22 +23,27 @@ api = HfApi(token=HF_TOKEN)
|
|
23 |
|
24 |
hivex_envs = [
|
25 |
{
|
|
|
26 |
"hivex_env": "hivex-wind-farm-control",
|
27 |
"task_count": 2,
|
28 |
},
|
29 |
{
|
|
|
30 |
"hivex_env": "hivex-wildfire-resource-management",
|
31 |
"task_count": 3,
|
32 |
},
|
33 |
{
|
|
|
34 |
"hivex_env": "hivex-drone-based-reforestation",
|
35 |
"task_count": 7,
|
36 |
},
|
37 |
{
|
|
|
38 |
"hivex_env": "hivex-ocean-plastic-collection",
|
39 |
"task_count": 4,
|
40 |
},
|
41 |
{
|
|
|
42 |
"hivex_env": "hivex-aerial-wildfire-suppression",
|
43 |
"task_count": 9,
|
44 |
},
|
@@ -209,25 +214,15 @@ with block:
|
|
209 |
with gr.Tabs(elem_classes="tab-buttons") as tabs:
|
210 |
for i in range(0, len(hivex_envs)):
|
211 |
hivex_env = hivex_envs[i]
|
212 |
-
with gr.Tab(hivex_env["
|
213 |
# TASK TABS
|
214 |
for j in range(0, hivex_env["task_count"]):
|
215 |
task = "Task " + str(j + 1)
|
216 |
with gr.TabItem(f"Task {j}"):
|
217 |
with gr.Row():
|
218 |
-
gr_dataframe = gr.components.Dataframe(value=get_data(hivex_env["hivex_env"], path_), headers=["User", "Model", "Cumulative Reward"], datatype=["markdown", "markdown", "number"], row_count=(100, 'fixed'))
|
|
|
219 |
|
220 |
-
# with gr.Tab("π Hard Set") as hard_tabs:
|
221 |
-
# with gr.TabItem(
|
222 |
-
# "π
Benchmark", elem_id="llm-benchmark-tab-table", id="hard_bench"
|
223 |
-
# ):
|
224 |
-
# gr.DataTable(
|
225 |
-
# get_data(
|
226 |
-
# "hivex-wind-farm-control", "datasets/hivex-leaderboard-data"
|
227 |
-
# ),
|
228 |
-
# elem_id="hard_benchmark_table",
|
229 |
-
# elem_classes="table",
|
230 |
-
# )
|
231 |
|
232 |
scheduler = BackgroundScheduler()
|
233 |
scheduler.add_job(restart, "interval", seconds=86400)
|
|
|
23 |
|
24 |
hivex_envs = [
|
25 |
{
|
26 |
+
"title": "Wind Farm Control",
|
27 |
"hivex_env": "hivex-wind-farm-control",
|
28 |
"task_count": 2,
|
29 |
},
|
30 |
{
|
31 |
+
"title": "Wildfire Resource Management",
|
32 |
"hivex_env": "hivex-wildfire-resource-management",
|
33 |
"task_count": 3,
|
34 |
},
|
35 |
{
|
36 |
+
"title": "Drone-Based Reforestation",
|
37 |
"hivex_env": "hivex-drone-based-reforestation",
|
38 |
"task_count": 7,
|
39 |
},
|
40 |
{
|
41 |
+
"title": "Ocean Plastic Collection",
|
42 |
"hivex_env": "hivex-ocean-plastic-collection",
|
43 |
"task_count": 4,
|
44 |
},
|
45 |
{
|
46 |
+
"title": "Aerial Wildfire Suppression",
|
47 |
"hivex_env": "hivex-aerial-wildfire-suppression",
|
48 |
"task_count": 9,
|
49 |
},
|
|
|
214 |
with gr.Tabs(elem_classes="tab-buttons") as tabs:
|
215 |
for i in range(0, len(hivex_envs)):
|
216 |
hivex_env = hivex_envs[i]
|
217 |
+
with gr.Tab(hivex_env["title"]) as env_tabs:
|
218 |
# TASK TABS
|
219 |
for j in range(0, hivex_env["task_count"]):
|
220 |
task = "Task " + str(j + 1)
|
221 |
with gr.TabItem(f"Task {j}"):
|
222 |
with gr.Row():
|
223 |
+
# gr_dataframe = gr.components.Dataframe(value=get_data(hivex_env["hivex_env"], path_), headers=["User", "Model", "Cumulative Reward"], datatype=["markdown", "markdown", "number"], row_count=(100, 'fixed'))
|
224 |
+
gr_dataframe = gr.components.Dataframe(value=get_data(hivex_env["hivex_env"], path_), row_count=(100, 'fixed'))
|
225 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
226 |
|
227 |
scheduler = BackgroundScheduler()
|
228 |
scheduler.add_job(restart, "interval", seconds=86400)
|