Skip to content
This repository was archived by the owner on Apr 17, 2023. It is now read-only.

Commit add50a2

Browse files
authored
Fix ote sample (#169)
1 parent 3ab7499 commit add50a2

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

torchreid/integration/sc/utils.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -173,11 +173,9 @@ def generate_label_schema(not_empty_labels, multilabel=False):
173173
if multilabel:
174174
emptylabel = LabelEntity(name="Empty label", is_empty=True, domain=Domain.CLASSIFICATION)
175175
empty_group = LabelGroup(name="empty", labels=[emptylabel], group_type=LabelGroupType.EMPTY_LABEL)
176-
single_groups = []
177176
for label in not_empty_labels:
178-
single_groups.append(LabelGroup(name=label.name, labels=[label], group_type=LabelGroupType.EXCLUSIVE))
179-
label_schema.add_group(single_groups[-1])
180-
label_schema.add_group(empty_group, exclusive_with=single_groups)
177+
label_schema.add_group(LabelGroup(name=label.name, labels=[label], group_type=LabelGroupType.EXCLUSIVE))
178+
label_schema.add_group(empty_group)
181179
else:
182180
main_group = LabelGroup(name="labels", labels=not_empty_labels, group_type=LabelGroupType.EXCLUSIVE)
183181
label_schema.add_group(main_group)

0 commit comments

Comments
 (0)