Spaces:
Restarting
on
CPU Upgrade
Restarting
on
CPU Upgrade
Clean up
Browse files
app.py
CHANGED
@@ -326,8 +326,8 @@ with gr.Blocks() as demo_leaderboard:
|
|
326 |
visible=False,
|
327 |
)
|
328 |
search_bar.submit(
|
329 |
-
update_table,
|
330 |
-
[
|
331 |
hidden_leaderboard_table_for_search,
|
332 |
shown_columns,
|
333 |
filter_columns_type,
|
@@ -340,14 +340,14 @@ with gr.Blocks() as demo_leaderboard:
|
|
340 |
flagged_models_visibility,
|
341 |
search_bar,
|
342 |
],
|
343 |
-
leaderboard_table,
|
344 |
)
|
345 |
|
346 |
# Define a hidden component that will trigger a reload only if a query parameter has be set
|
347 |
hidden_search_bar = gr.Textbox(value="", visible=False)
|
348 |
hidden_search_bar.change(
|
349 |
-
update_table,
|
350 |
-
[
|
351 |
hidden_leaderboard_table_for_search,
|
352 |
shown_columns,
|
353 |
filter_columns_type,
|
@@ -360,15 +360,15 @@ with gr.Blocks() as demo_leaderboard:
|
|
360 |
flagged_models_visibility,
|
361 |
search_bar,
|
362 |
],
|
363 |
-
leaderboard_table,
|
364 |
)
|
365 |
# Check query parameter once at startup and update search bar + hidden component
|
366 |
demo_leaderboard.load(load_query, inputs=[], outputs=[search_bar, hidden_search_bar])
|
367 |
|
368 |
for selector in [shown_columns, filter_columns_type, filter_columns_precision, filter_columns_size, filter_columns_add_special_tokens, filter_columns_num_few_shots, deleted_models_visibility, merged_models_visibility, flagged_models_visibility]:
|
369 |
selector.change(
|
370 |
-
update_table,
|
371 |
-
[
|
372 |
hidden_leaderboard_table_for_search,
|
373 |
shown_columns,
|
374 |
filter_columns_type,
|
@@ -381,7 +381,7 @@ with gr.Blocks() as demo_leaderboard:
|
|
381 |
flagged_models_visibility,
|
382 |
search_bar,
|
383 |
],
|
384 |
-
leaderboard_table,
|
385 |
queue=True,
|
386 |
)
|
387 |
|
|
|
326 |
visible=False,
|
327 |
)
|
328 |
search_bar.submit(
|
329 |
+
fn=update_table,
|
330 |
+
inputs=[
|
331 |
hidden_leaderboard_table_for_search,
|
332 |
shown_columns,
|
333 |
filter_columns_type,
|
|
|
340 |
flagged_models_visibility,
|
341 |
search_bar,
|
342 |
],
|
343 |
+
outputs=leaderboard_table,
|
344 |
)
|
345 |
|
346 |
# Define a hidden component that will trigger a reload only if a query parameter has be set
|
347 |
hidden_search_bar = gr.Textbox(value="", visible=False)
|
348 |
hidden_search_bar.change(
|
349 |
+
fn=update_table,
|
350 |
+
inputs=[
|
351 |
hidden_leaderboard_table_for_search,
|
352 |
shown_columns,
|
353 |
filter_columns_type,
|
|
|
360 |
flagged_models_visibility,
|
361 |
search_bar,
|
362 |
],
|
363 |
+
outputs=leaderboard_table,
|
364 |
)
|
365 |
# Check query parameter once at startup and update search bar + hidden component
|
366 |
demo_leaderboard.load(load_query, inputs=[], outputs=[search_bar, hidden_search_bar])
|
367 |
|
368 |
for selector in [shown_columns, filter_columns_type, filter_columns_precision, filter_columns_size, filter_columns_add_special_tokens, filter_columns_num_few_shots, deleted_models_visibility, merged_models_visibility, flagged_models_visibility]:
|
369 |
selector.change(
|
370 |
+
fn=update_table,
|
371 |
+
inputs=[
|
372 |
hidden_leaderboard_table_for_search,
|
373 |
shown_columns,
|
374 |
filter_columns_type,
|
|
|
381 |
flagged_models_visibility,
|
382 |
search_bar,
|
383 |
],
|
384 |
+
outputs=leaderboard_table,
|
385 |
queue=True,
|
386 |
)
|
387 |
|