Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Use gr.on
Browse files
app.py
CHANGED
@@ -330,7 +330,19 @@ with gr.Blocks() as demo_leaderboard:
|
|
330 |
hidden_search_bar = gr.Textbox(value="", visible=False)
|
331 |
|
332 |
gr.on(
|
333 |
-
triggers=[
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
334 |
fn=update_table,
|
335 |
inputs=[
|
336 |
hidden_leaderboard_table_for_search,
|
@@ -351,25 +363,6 @@ with gr.Blocks() as demo_leaderboard:
|
|
351 |
# Check query parameter once at startup and update search bar + hidden component
|
352 |
demo_leaderboard.load(fn=load_query, outputs=[search_bar, hidden_search_bar])
|
353 |
|
354 |
-
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]:
|
355 |
-
selector.change(
|
356 |
-
fn=update_table,
|
357 |
-
inputs=[
|
358 |
-
hidden_leaderboard_table_for_search,
|
359 |
-
shown_columns,
|
360 |
-
filter_columns_type,
|
361 |
-
filter_columns_precision,
|
362 |
-
filter_columns_size,
|
363 |
-
filter_columns_add_special_tokens,
|
364 |
-
filter_columns_num_few_shots,
|
365 |
-
deleted_models_visibility,
|
366 |
-
merged_models_visibility,
|
367 |
-
flagged_models_visibility,
|
368 |
-
search_bar,
|
369 |
-
],
|
370 |
-
outputs=leaderboard_table,
|
371 |
-
queue=True,
|
372 |
-
)
|
373 |
|
374 |
# Submission demo
|
375 |
|
|
|
330 |
hidden_search_bar = gr.Textbox(value="", visible=False)
|
331 |
|
332 |
gr.on(
|
333 |
+
triggers=[
|
334 |
+
search_bar.submit,
|
335 |
+
hidden_search_bar.change,
|
336 |
+
shown_columns.change,
|
337 |
+
filter_columns_type.change,
|
338 |
+
filter_columns_precision.change,
|
339 |
+
filter_columns_size.change,
|
340 |
+
filter_columns_add_special_tokens.change,
|
341 |
+
filter_columns_num_few_shots.change,
|
342 |
+
deleted_models_visibility.change,
|
343 |
+
merged_models_visibility.change,
|
344 |
+
flagged_models_visibility.change,
|
345 |
+
],
|
346 |
fn=update_table,
|
347 |
inputs=[
|
348 |
hidden_leaderboard_table_for_search,
|
|
|
363 |
# Check query parameter once at startup and update search bar + hidden component
|
364 |
demo_leaderboard.load(fn=load_query, outputs=[search_bar, hidden_search_bar])
|
365 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
366 |
|
367 |
# Submission demo
|
368 |
|