Commit a7935ea6 authored by Kyryl Truskovskyi's avatar Kyryl Truskovskyi Committed by Francisco Massa
Browse files

cast mnist targer to int (#605)

parent e15e81f1
......@@ -67,7 +67,7 @@ class MNIST(data.Dataset):
Returns:
tuple: (image, target) where target is index of the target class.
"""
img, target = self.data[index], self.targets[index]
img, target = self.data[index], int(self.targets[index])
# doing this so that it is consistent with all other datasets
# to return a PIL Image
......
Markdown is supported
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