mrfakename commited on
Commit
d2781d4
1 Parent(s): 24aea25

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -483,13 +483,13 @@ def reload(chosenmodel1=None, chosenmodel2=None, userid=None, chose_a=False, cho
483
  with gr.Blocks() as leaderboard:
484
  gr.Markdown(LDESC)
485
  # df = gr.Dataframe(interactive=False, value=get_leaderboard())
486
- df = gr.Dataframe(interactive=False, min_width=0, wrap=True, column_widths=[30, 200, 50, 50])
487
  with gr.Row():
488
  reveal_prelim = gr.Checkbox(label="Reveal preliminary results", info="Show all models, including models with very few human ratings.", scale=1)
489
  reloadbtn = gr.Button("Refresh", scale=3)
490
- reveal_prelim.input(get_leaderboard, inputs=[reveal_prelim], outputs=[df])
491
- leaderboard.load(get_leaderboard, inputs=[reveal_prelim], outputs=[df])
492
- reloadbtn.click(get_leaderboard, inputs=[reveal_prelim], outputs=[df])
493
  # gr.Markdown("DISCLAIMER: The licenses listed may not be accurate or up to date, you are responsible for checking the licenses before using the models. Also note that some models may have additional usage restrictions.")
494
 
495
  # with gr.Blocks() as vote:
 
483
  with gr.Blocks() as leaderboard:
484
  gr.Markdown(LDESC)
485
  # df = gr.Dataframe(interactive=False, value=get_leaderboard())
486
+ df1 = gr.Dataframe(interactive=False, min_width=0, wrap=True, column_widths=[30, 200, 50, 50])
487
  with gr.Row():
488
  reveal_prelim = gr.Checkbox(label="Reveal preliminary results", info="Show all models, including models with very few human ratings.", scale=1)
489
  reloadbtn = gr.Button("Refresh", scale=3)
490
+ reveal_prelim.input(get_leaderboard, inputs=[reveal_prelim], outputs=[df1])
491
+ leaderboard.load(get_leaderboard, inputs=[reveal_prelim], outputs=[df1])
492
+ reloadbtn.click(get_leaderboard, inputs=[reveal_prelim], outputs=[df1])
493
  # gr.Markdown("DISCLAIMER: The licenses listed may not be accurate or up to date, you are responsible for checking the licenses before using the models. Also note that some models may have additional usage restrictions.")
494
 
495
  # with gr.Blocks() as vote: