kennymckormick commited on
Commit
0c31bc1
1 Parent(s): 6eac4ec

add rank in df

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -24,6 +24,7 @@ with gr.Blocks() as demo:
24
  gr.Markdown(LEADERBOARD_MD['MAIN'])
25
  _, check_box = BUILD_L1_DF(results, MAIN_FIELDS)
26
  table = generate_table(results, DEFAULT_BENCH)
 
27
  type_map = check_box['type_map']
28
  checkbox_group = gr.CheckboxGroup(
29
  choices=check_box['all'],
@@ -65,6 +66,7 @@ with gr.Blocks() as demo:
65
  df['flag'] = [model_type_flag(df.iloc[i], model_type) for i in range(len(df))]
66
  df = df[df['flag']]
67
  df.pop('flag')
 
68
 
69
  comp = gr.components.DataFrame(
70
  value=df[headers],
 
24
  gr.Markdown(LEADERBOARD_MD['MAIN'])
25
  _, check_box = BUILD_L1_DF(results, MAIN_FIELDS)
26
  table = generate_table(results, DEFAULT_BENCH)
27
+ table['Rank'] = list(range(1, len(table) + 1))
28
  type_map = check_box['type_map']
29
  checkbox_group = gr.CheckboxGroup(
30
  choices=check_box['all'],
 
66
  df['flag'] = [model_type_flag(df.iloc[i], model_type) for i in range(len(df))]
67
  df = df[df['flag']]
68
  df.pop('flag')
69
+ df['Rank'] = list(range(1, len(df) + 1))
70
 
71
  comp = gr.components.DataFrame(
72
  value=df[headers],