Update app.py
Browse files
app.py
CHANGED
@@ -38,7 +38,7 @@ def filter_data(model, scenario):
|
|
38 |
return pd.DataFrame([pass_at_k])
|
39 |
|
40 |
# Initialize the leaderboard
|
41 |
-
def init_leaderboard(dataframe, height=
|
42 |
if dataframe is None or dataframe.empty:
|
43 |
raise ValueError("Leaderboard DataFrame is empty or None.")
|
44 |
return Leaderboard(
|
@@ -76,11 +76,11 @@ with gr.Blocks() as demo:
|
|
76 |
with gr.Row():
|
77 |
with gr.Column(scale=1):
|
78 |
gr.Markdown("## WebApp1K-Duo ([Benchmark](https://huggingface.co/datasets/onekq-ai/WebApp1K-Duo-React))")
|
79 |
-
duo_leaderboard = init_leaderboard(duo_complete_pass_at_k, height=
|
80 |
|
81 |
with gr.Column(scale=1):
|
82 |
gr.Markdown("## WebApp1K ([Benchmark](https://huggingface.co/datasets/onekq-ai/WebApp1K-React))")
|
83 |
-
leaderboard = init_leaderboard(complete_pass_at_k, height=
|
84 |
|
85 |
# Launch the Gradio interface
|
86 |
demo.launch()
|
|
|
38 |
return pd.DataFrame([pass_at_k])
|
39 |
|
40 |
# Initialize the leaderboard
|
41 |
+
def init_leaderboard(dataframe, height=800):
|
42 |
if dataframe is None or dataframe.empty:
|
43 |
raise ValueError("Leaderboard DataFrame is empty or None.")
|
44 |
return Leaderboard(
|
|
|
76 |
with gr.Row():
|
77 |
with gr.Column(scale=1):
|
78 |
gr.Markdown("## WebApp1K-Duo ([Benchmark](https://huggingface.co/datasets/onekq-ai/WebApp1K-Duo-React))")
|
79 |
+
duo_leaderboard = init_leaderboard(duo_complete_pass_at_k, height=800)
|
80 |
|
81 |
with gr.Column(scale=1):
|
82 |
gr.Markdown("## WebApp1K ([Benchmark](https://huggingface.co/datasets/onekq-ai/WebApp1K-React))")
|
83 |
+
leaderboard = init_leaderboard(complete_pass_at_k, height=800)
|
84 |
|
85 |
# Launch the Gradio interface
|
86 |
demo.launch()
|