Unverified Commit 80ae224f authored by Cao Yuhang's avatar Cao Yuhang Committed by GitHub
Browse files

Fix fovea no ann (#2032)

parent aade6801
......@@ -838,6 +838,7 @@ class Albu(object):
if isinstance(results['bboxes'], list):
results['bboxes'] = np.array(
results['bboxes'], dtype=np.float32)
results['bboxes'] = results['bboxes'].reshape(-1, 4)
# filter label_fields
if self.filter_lost_elements:
......@@ -858,6 +859,7 @@ class Albu(object):
if 'gt_labels' in results:
if isinstance(results['gt_labels'], list):
results['gt_labels'] = np.array(results['gt_labels'])
results['gt_labels'] = results['gt_labels'].astype(np.int64)
# back to the original format
results = self.mapper(results, self.keymap_back)
......
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