Spaces:
Running
Running
Commit
•
6de1a1d
1
Parent(s):
1dcb2d8
show all options when no model id matched
Browse files
text_classification_ui_helpers.py
CHANGED
@@ -47,8 +47,9 @@ def get_related_datasets_from_leaderboard(model_id):
|
|
47 |
records = leaderboard.records
|
48 |
model_records = records[records["model_id"] == model_id]
|
49 |
datasets_unique = model_records["dataset_id"].unique()
|
|
|
50 |
if len(datasets_unique) == 0:
|
51 |
-
return gr.update()
|
52 |
return gr.update(choices=datasets_unique, value=datasets_unique[0])
|
53 |
|
54 |
|
|
|
47 |
records = leaderboard.records
|
48 |
model_records = records[records["model_id"] == model_id]
|
49 |
datasets_unique = model_records["dataset_id"].unique()
|
50 |
+
all_unique_datasets = records["dataset_id"].unique()
|
51 |
if len(datasets_unique) == 0:
|
52 |
+
return gr.update(choices=all_unique_datasets)
|
53 |
return gr.update(choices=datasets_unique, value=datasets_unique[0])
|
54 |
|
55 |
|