Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Remove backend library info
Browse files- app.py +0 -17
- src/display/utils.py +0 -12
- src/populate.py +0 -1
app.py
CHANGED
@@ -95,7 +95,6 @@ def filter_models(
|
|
95 |
num_few_shots_query: list,
|
96 |
version_query: list,
|
97 |
vllm_query: list,
|
98 |
-
# backend_query: list,
|
99 |
) -> pd.DataFrame:
|
100 |
print(f"Initial df shape: {df.shape}")
|
101 |
print(f"Initial df content:\n{df}")
|
@@ -137,10 +136,6 @@ def filter_models(
|
|
137 |
filtered_df = filtered_df[filtered_df["vllm version"].isin(vllm_query)]
|
138 |
print(f"After vllm version filter: {filtered_df.shape}")
|
139 |
|
140 |
-
# Backend フィルタリング
|
141 |
-
# filtered_df = filtered_df[filtered_df["Backend Library"].isin(backend_query)]
|
142 |
-
# print(f"After backend filter: {filtered_df.shape}")
|
143 |
-
|
144 |
print("Filtered dataframe head:")
|
145 |
print(filtered_df.head())
|
146 |
return filtered_df
|
@@ -191,7 +186,6 @@ def update_table(
|
|
191 |
num_few_shots_query: list,
|
192 |
version_query: list,
|
193 |
vllm_query: list,
|
194 |
-
# backend_query: list,
|
195 |
query: str,
|
196 |
*columns,
|
197 |
):
|
@@ -209,7 +203,6 @@ def update_table(
|
|
209 |
num_few_shots_query,
|
210 |
version_query,
|
211 |
vllm_query,
|
212 |
-
# backend_query,
|
213 |
)
|
214 |
print(f"filtered_df shape after filter_models: {filtered_df.shape}")
|
215 |
|
@@ -242,7 +235,6 @@ leaderboard_df = filter_models(
|
|
242 |
[i.value.name for i in NumFewShots],
|
243 |
[i.value.name for i in Version],
|
244 |
[i.value.name for i in VllmVersion],
|
245 |
-
# [i.value.name for i in Backend],
|
246 |
)
|
247 |
# DataFrameの初期化部分のみを修正
|
248 |
INITIAL_COLUMNS = ["T"] + [
|
@@ -469,13 +461,6 @@ with gr.Blocks() as demo_leaderboard:
|
|
469 |
elem_id="filter-columns-vllm",
|
470 |
)
|
471 |
|
472 |
-
# filter_columns_backend = gr.CheckboxGroup(
|
473 |
-
# label="Backend Library",
|
474 |
-
# choices=[i.value.name for i in Backend],
|
475 |
-
# value=[i.value.name for i in Backend],
|
476 |
-
# elem_id="filter-columns-backend",
|
477 |
-
# )
|
478 |
-
|
479 |
leaderboard_table = gr.Dataframe(
|
480 |
value=leaderboard_df,
|
481 |
headers=INITIAL_COLUMNS,
|
@@ -516,7 +501,6 @@ with gr.Blocks() as demo_leaderboard:
|
|
516 |
filter_columns_num_few_shots.change,
|
517 |
filter_columns_version.change,
|
518 |
filter_columns_vllm.change,
|
519 |
-
# filter_columns_backend.change,
|
520 |
search_bar.submit,
|
521 |
]
|
522 |
+ [shown_columns.change for shown_columns in shown_columns_dict.values()],
|
@@ -529,7 +513,6 @@ with gr.Blocks() as demo_leaderboard:
|
|
529 |
filter_columns_num_few_shots,
|
530 |
filter_columns_version,
|
531 |
filter_columns_vllm,
|
532 |
-
# filter_columns_backend,
|
533 |
search_bar,
|
534 |
]
|
535 |
+ [shown_columns for shown_columns in shown_columns_dict.values()],
|
|
|
95 |
num_few_shots_query: list,
|
96 |
version_query: list,
|
97 |
vllm_query: list,
|
|
|
98 |
) -> pd.DataFrame:
|
99 |
print(f"Initial df shape: {df.shape}")
|
100 |
print(f"Initial df content:\n{df}")
|
|
|
136 |
filtered_df = filtered_df[filtered_df["vllm version"].isin(vllm_query)]
|
137 |
print(f"After vllm version filter: {filtered_df.shape}")
|
138 |
|
|
|
|
|
|
|
|
|
139 |
print("Filtered dataframe head:")
|
140 |
print(filtered_df.head())
|
141 |
return filtered_df
|
|
|
186 |
num_few_shots_query: list,
|
187 |
version_query: list,
|
188 |
vllm_query: list,
|
|
|
189 |
query: str,
|
190 |
*columns,
|
191 |
):
|
|
|
203 |
num_few_shots_query,
|
204 |
version_query,
|
205 |
vllm_query,
|
|
|
206 |
)
|
207 |
print(f"filtered_df shape after filter_models: {filtered_df.shape}")
|
208 |
|
|
|
235 |
[i.value.name for i in NumFewShots],
|
236 |
[i.value.name for i in Version],
|
237 |
[i.value.name for i in VllmVersion],
|
|
|
238 |
)
|
239 |
# DataFrameの初期化部分のみを修正
|
240 |
INITIAL_COLUMNS = ["T"] + [
|
|
|
461 |
elem_id="filter-columns-vllm",
|
462 |
)
|
463 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
464 |
leaderboard_table = gr.Dataframe(
|
465 |
value=leaderboard_df,
|
466 |
headers=INITIAL_COLUMNS,
|
|
|
501 |
filter_columns_num_few_shots.change,
|
502 |
filter_columns_version.change,
|
503 |
filter_columns_vllm.change,
|
|
|
504 |
search_bar.submit,
|
505 |
]
|
506 |
+ [shown_columns.change for shown_columns in shown_columns_dict.values()],
|
|
|
513 |
filter_columns_num_few_shots,
|
514 |
filter_columns_version,
|
515 |
filter_columns_vllm,
|
|
|
516 |
search_bar,
|
517 |
]
|
518 |
+ [shown_columns for shown_columns in shown_columns_dict.values()],
|
src/display/utils.py
CHANGED
@@ -61,7 +61,6 @@ auto_eval_column_dict.append(
|
|
61 |
["llm_jp_eval_version", ColumnContent, ColumnContent("llm-jp-eval version", "str", False)]
|
62 |
)
|
63 |
auto_eval_column_dict.append(["vllm_version", ColumnContent, ColumnContent("vllm version", "str", False)])
|
64 |
-
auto_eval_column_dict.append(["backend", ColumnContent, ColumnContent("Backend Library", "str", False, dummy=True)])
|
65 |
auto_eval_column_dict.append(["dummy", ColumnContent, ColumnContent("model_name_for_query", "str", False, dummy=True)])
|
66 |
auto_eval_column_dict.append(["row_id", ColumnContent, ColumnContent("ID", "number", False, dummy=True)])
|
67 |
|
@@ -160,17 +159,6 @@ class Version(Enum):
|
|
160 |
return Version.Unknown
|
161 |
|
162 |
|
163 |
-
class Backend(Enum):
|
164 |
-
vllm = ModelDetails("vllm")
|
165 |
-
Unknown = ModelDetails("?")
|
166 |
-
|
167 |
-
def from_str(backend):
|
168 |
-
if backend == "vllm":
|
169 |
-
return Backend.vllm
|
170 |
-
else:
|
171 |
-
return Backend.Unknown
|
172 |
-
|
173 |
-
|
174 |
class VllmVersion(Enum):
|
175 |
current = ModelDetails("v0.6.3.post1")
|
176 |
Unknown = ModelDetails("?")
|
|
|
61 |
["llm_jp_eval_version", ColumnContent, ColumnContent("llm-jp-eval version", "str", False)]
|
62 |
)
|
63 |
auto_eval_column_dict.append(["vllm_version", ColumnContent, ColumnContent("vllm version", "str", False)])
|
|
|
64 |
auto_eval_column_dict.append(["dummy", ColumnContent, ColumnContent("model_name_for_query", "str", False, dummy=True)])
|
65 |
auto_eval_column_dict.append(["row_id", ColumnContent, ColumnContent("ID", "number", False, dummy=True)])
|
66 |
|
|
|
159 |
return Version.Unknown
|
160 |
|
161 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
162 |
class VllmVersion(Enum):
|
163 |
current = ModelDetails("v0.6.3.post1")
|
164 |
Unknown = ModelDetails("?")
|
src/populate.py
CHANGED
@@ -15,7 +15,6 @@ def get_leaderboard_df(contents_repo: str, cols: list, benchmark_cols: list) ->
|
|
15 |
df = datasets.load_dataset(contents_repo, split="train").to_pandas()
|
16 |
df["Model"] = df["model"].map(make_clickable_model)
|
17 |
df["T"] = df["model_type"].map(lambda x: x.split(":")[0].strip())
|
18 |
-
df["Backend Library"] = "vllm"
|
19 |
df = df.rename(columns={task.value.metric: task.value.col_name for task in Tasks})
|
20 |
df = df.rename(
|
21 |
columns={
|
|
|
15 |
df = datasets.load_dataset(contents_repo, split="train").to_pandas()
|
16 |
df["Model"] = df["model"].map(make_clickable_model)
|
17 |
df["T"] = df["model_type"].map(lambda x: x.split(":")[0].strip())
|
|
|
18 |
df = df.rename(columns={task.value.metric: task.value.col_name for task in Tasks})
|
19 |
df = df.rename(
|
20 |
columns={
|