Commit 544151d3 authored by Guillaume HEUSCH's avatar Guillaume HEUSCH
Browse files

[utils] fixed the map_label function (hopefully)

parent 0f9a2e11
Pipeline #26413 failed with stages
in 6 minutes and 45 seconds
......@@ -84,8 +84,14 @@ class ToGray(object):
def map_labels(raw_labels, start_index=0):
Map the ID label to [0 - # of IDs]
raw_labels: list of int
The labels of the samples
possible_labels = list(set(raw_labels))
possible_labels = sorted(list(set(raw_labels)))
labels = numpy.array(raw_labels)
for i in range(len(possible_labels)):
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment