Spaces:
Running
Running
update scripts
Browse files
app.py
CHANGED
@@ -52,10 +52,12 @@ def load_data(data_path):
|
|
52 |
df_tmp[['en', 'zh', 'id', 'th', 'vi', 'avg', 'avg_sea']] *= 100
|
53 |
df_tmp[['en', 'zh', 'id', 'th', 'vi', 'avg', 'avg_sea']] = df_tmp[['en', 'zh', 'id', 'th', 'vi', 'avg', 'avg_sea']].round(2)
|
54 |
|
55 |
-
# change the order of the columns to ['Model', 'type', 'open?', 'shot', 'avg', 'avg_sea', 'en', 'zh', 'id', 'th', 'vi']
|
56 |
-
|
57 |
-
|
58 |
-
|
|
|
|
|
59 |
return df_m3exam, df_mmlu, df_avg
|
60 |
|
61 |
# Example path to your CSV file
|
|
|
52 |
df_tmp[['en', 'zh', 'id', 'th', 'vi', 'avg', 'avg_sea']] *= 100
|
53 |
df_tmp[['en', 'zh', 'id', 'th', 'vi', 'avg', 'avg_sea']] = df_tmp[['en', 'zh', 'id', 'th', 'vi', 'avg', 'avg_sea']].round(2)
|
54 |
|
55 |
+
# change the order of the columns to ['Model', 'type', 'open?', 'shot', 'avg', 'avg_sea', 'en', 'zh', 'id', 'th', 'vi']
|
56 |
+
# and sort the columns by 'avg' in descending order
|
57 |
+
df_m3exam = df_m3exam[columns_sorted].sort_values(by='avg', ascending=False)
|
58 |
+
df_mmlu = df_mmlu[columns_sorted].sort_values(by='avg', ascending=False)
|
59 |
+
df_avg = df_avg[columns_sorted].sort_values(by='avg', ascending=False)
|
60 |
+
|
61 |
return df_m3exam, df_mmlu, df_avg
|
62 |
|
63 |
# Example path to your CSV file
|