xinchen9 commited on
Commit
5433006
1 Parent(s): da0039b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +55 -2
app.py CHANGED
@@ -238,10 +238,63 @@ with demo:
238
  elem_id = "leaderboard-table",
239
  interactive = False,
240
  visible=True,
241
- # column_widths=["20%", "6%", "8%", "6%", "8%", "8%", "6%", "6%", "6%", "6%", "6%"],
242
  )
243
 
244
- # gr.Markdown("The \"Cost\" column is calculated as USD / Million tokens of output.")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
245
 
246
  hidden_leaderboard_table_for_search = gr.components.Dataframe(
247
  value=df_results_init,
 
238
  elem_id = "leaderboard-table",
239
  interactive = False,
240
  visible=True,
 
241
  )
242
 
243
+
244
+ hidden_leaderboard_table_for_search = gr.components.Dataframe(
245
+ value=df_results_init,
246
+ # elem_id="leaderboard-table",
247
+ interactive=False,
248
+ visible=False,
249
+ )
250
+
251
+ search_bar.submit(
252
+ update_table,
253
+ [
254
+ # df_avg,
255
+ hidden_leaderboard_table_for_search,
256
+ model1_column,
257
+ # shown_columns,
258
+ #type_query,
259
+ #open_query,
260
+ # filter_columns_type,
261
+ # filter_columns_precision,
262
+ # filter_columns_size,
263
+ # deleted_models_visibility,
264
+ search_bar,
265
+ ],
266
+ leaderboard_table,
267
+ )
268
+
269
+ #for selector in [type_query, open_query]:
270
+ for selector in [model1_column]:
271
+ selector.change(
272
+ update_table,
273
+ [
274
+ # df_avg,
275
+ hidden_leaderboard_table_for_search,
276
+ model1_column,
277
+ # shown_columns,
278
+ #type_query,
279
+ #open_query,
280
+ # filter_columns_type,
281
+ # filter_columns_precision,
282
+ # filter_columns_size,
283
+ # deleted_models_visibility,
284
+ search_bar,
285
+ ],
286
+ leaderboard_table,
287
+ )
288
+
289
+ gr.Markdown("### Unlearned Concepts Parachute")
290
+ leaderboard_table = gr.components.Dataframe(
291
+ value = df_results,
292
+ datatype = TYPES,
293
+ elem_id = "leaderboard-table",
294
+ interactive = False,
295
+ visible=True,
296
+ )
297
+
298
 
299
  hidden_leaderboard_table_for_search = gr.components.Dataframe(
300
  value=df_results_init,