Commit 0332624e authored by Francisco Massa's avatar Francisco Massa
Browse files

Minor fix in COCO dataset

parent 9378febe
......@@ -51,6 +51,9 @@ class CocoDetection(data.Dataset):
path = coco.loadImgs(img_id)[0]['file_name']
img = Image.open(os.path.join(self.root, path)).convert('RGB')
if self.transform is not None:
img = self.transform(img)
if self.target_transform is not None:
target = self.target_transform(target)
......
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