Commit
08f6cbe
1 Parent(s): bdb77ab

update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -16
app.py CHANGED
@@ -1,5 +1,3 @@
1
- # app.py
2
-
3
  import gradio as gr
4
  from gradio_leaderboard import Leaderboard, ColumnFilter, SelectColumns
5
  import pandas as pd
@@ -49,16 +47,13 @@ try:
49
  except Exception:
50
  restart_space()
51
 
52
-
53
  LEADERBOARD_DF = get_leaderboard_df(EVAL_RESULTS_PATH, EVAL_REQUESTS_PATH, COLS, BENCHMARK_COLS)
54
  print("LEADERBOARD_DF Shape:", LEADERBOARD_DF.shape) # Debug
55
  print("LEADERBOARD_DF Columns:", LEADERBOARD_DF.columns.tolist()) # Debug
56
 
57
- (
58
- finished_eval_queue_df,
59
- running_eval_queue_df,
60
- pending_eval_queue_df,
61
- ) = get_evaluation_queue_df(EVAL_REQUESTS_PATH, EVAL_COLS)
62
 
63
  demo = gr.Blocks(css=custom_css)
64
  with demo:
@@ -95,7 +90,6 @@ with demo:
95
  "still_on_hub", type="boolean", label="Deleted/incomplete", default=True
96
  ),
97
  ],
98
-
99
  bool_checkboxgroup_label="Hide models",
100
  interactive=False,
101
  )
@@ -127,12 +121,6 @@ with demo:
127
  value=None,
128
  interactive=True,
129
  )
130
- # Removed num_examples_input since we're using a fixed number
131
- # num_examples_input = gr.Number(
132
- # label="Number of Examples per Subject (e.g., 10)",
133
- # value=10,
134
- # precision=0
135
- # )
136
 
137
  with gr.Column():
138
  precision = gr.Dropdown(
@@ -162,7 +150,6 @@ with demo:
162
  precision,
163
  weight_type,
164
  model_type,
165
- # num_examples_input # Removed
166
  ],
167
  submission_result,
168
  )
 
 
 
1
  import gradio as gr
2
  from gradio_leaderboard import Leaderboard, ColumnFilter, SelectColumns
3
  import pandas as pd
 
47
  except Exception:
48
  restart_space()
49
 
50
+ # Load the leaderboard DataFrame
51
  LEADERBOARD_DF = get_leaderboard_df(EVAL_RESULTS_PATH, EVAL_REQUESTS_PATH, COLS, BENCHMARK_COLS)
52
  print("LEADERBOARD_DF Shape:", LEADERBOARD_DF.shape) # Debug
53
  print("LEADERBOARD_DF Columns:", LEADERBOARD_DF.columns.tolist()) # Debug
54
 
55
+ # Load the evaluation queue DataFrames
56
+ finished_eval_queue_df, running_eval_queue_df, pending_eval_queue_df = get_evaluation_queue_df(EVAL_REQUESTS_PATH, EVAL_COLS)
 
 
 
57
 
58
  demo = gr.Blocks(css=custom_css)
59
  with demo:
 
90
  "still_on_hub", type="boolean", label="Deleted/incomplete", default=True
91
  ),
92
  ],
 
93
  bool_checkboxgroup_label="Hide models",
94
  interactive=False,
95
  )
 
121
  value=None,
122
  interactive=True,
123
  )
 
 
 
 
 
 
124
 
125
  with gr.Column():
126
  precision = gr.Dropdown(
 
150
  precision,
151
  weight_type,
152
  model_type,
 
153
  ],
154
  submission_result,
155
  )