tttoaster commited on
Commit
04a0fb2
1 Parent(s): 255a4d2

Upload 15 files

Browse files
Files changed (1) hide show
  1. app.py +15 -9
app.py CHANGED
@@ -464,12 +464,16 @@ with block:
464
 
465
  average_type_v2 = gr.Radio(AVERAGE_TYPE, label="Performance Average Type", value="All Average")
466
 
 
 
 
 
467
  # 创建数据帧组件
468
  data_component_v2 = gr.components.Dataframe(
469
- value=get_baseline_v2_df(average_type_v2.value),
470
- headers=COLUMN_V2_NAMES,
471
  type="pandas",
472
- datatype=DATA_TITILE_V2_TYPE,
473
  interactive=False,
474
  visible=True,
475
  )
@@ -568,17 +572,19 @@ with block:
568
 
569
  average_type = gr.Radio(AVERAGE_TYPE, label="Performance Average Type", value="All Average")
570
 
571
-
 
 
 
572
  # 创建数据帧组件
573
  data_component = gr.components.Dataframe(
574
- value=get_baseline_df(average_type.value),
575
- headers=COLUMN_NAMES,
576
  type="pandas",
577
- datatype=DATA_TITILE_TYPE,
578
  interactive=False,
579
  visible=True,
580
- )
581
-
582
 
583
  def on_filter_model_size_method_change(selected_model_size, selected_evaluation_method, selected_columns):
584
 
 
464
 
465
  average_type_v2 = gr.Radio(AVERAGE_TYPE, label="Performance Average Type", value="All Average")
466
 
467
+ baseline_v2_value = get_baseline_v2_df(average_type_v2.value)
468
+ baseline_v2_header = MODEL_INFO_V2 + checkbox_group_v2.value
469
+ baseline_v2_datatype = ['markdown'] * 3 + ['number'] * len(checkbox_group_v2.value)
470
+ # pdb.set_trace()
471
  # 创建数据帧组件
472
  data_component_v2 = gr.components.Dataframe(
473
+ value=baseline_v2_value,
474
+ headers=baseline_v2_header,
475
  type="pandas",
476
+ datatype=baseline_v2_datatype,
477
  interactive=False,
478
  visible=True,
479
  )
 
572
 
573
  average_type = gr.Radio(AVERAGE_TYPE, label="Performance Average Type", value="All Average")
574
 
575
+ baseline_value = get_baseline_df(average_type.value)
576
+ baseline_header = MODEL_INFO + checkbox_group.value
577
+ baseline_datatype = ['markdown'] * 4 + ['number'] * len(checkbox_group.value)
578
+ # pdb.set_trace()
579
  # 创建数据帧组件
580
  data_component = gr.components.Dataframe(
581
+ value=baseline_value,
582
+ headers=baseline_header,
583
  type="pandas",
584
+ datatype=baseline_datatype,
585
  interactive=False,
586
  visible=True,
587
+ )
 
588
 
589
  def on_filter_model_size_method_change(selected_model_size, selected_evaluation_method, selected_columns):
590