Skip to content

Commit

Permalink
fix(data): fix a potential bug after closing the mosaic augmentation (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Joker316701882 committed Aug 27, 2021
1 parent a1a2958 commit 40bde39
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions yolox/data/datasets/mosaicdetection.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,9 +154,9 @@ def __getitem__(self, idx):

else:
self._dataset._input_dim = self.input_dim
img, label, img_info, id_ = self._dataset.pull_item(idx)
img, label, img_info, idx = self._dataset.pull_item(idx)
img, label = self.preproc(img, label, self.input_dim)
return img, label, img_info, id_
return img, label, img_info, np.array([idx])

def mixup(self, origin_img, origin_labels, input_dim):
jit_factor = random.uniform(*self.mixup_scale)
Expand Down

0 comments on commit 40bde39

Please sign in to comment.