Skip to content
Snippets Groups Projects
Commit 79cecbd2 authored by Guillaume HEUSCH's avatar Guillaume HEUSCH
Browse files

[utils] remove comments in the map_label function

parent 46fc1f92
No related branches found
No related tags found
1 merge request!9Light cnn
......@@ -90,18 +90,8 @@ def map_labels(raw_labels, start_index=0):
for i in range(len(possible_labels)):
l = possible_labels[i]
#labels[numpy.where(labels==l)[0][0]] = i + start_index
labels[numpy.where(labels==l)[0]] = i + start_index
# -----
# map back to native int, resolve the problem with dataset concatenation
# it does: line 78 is now ok
# for some reason, it was not working when the type of id labels were numpy.int64 ...
#labels_int = []
#for i in range(len(labels)):
# labels_int.append(labels[i].item())
#return labels_int
return labels
from torch.utils.data import Dataset
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment