remove objects with iscrowd=True in Objects365 (#11788)
Signed-off-by: tino926 <tino926@users.noreply.github.com>
This commit is contained in:
1 parent
d19439afeb
commit
a453a45559
1 file changed
+1
-1
@@ -428,7 +428,7 @@ download: |
|
||||
path = Path(im["file_name"]) # image filename
|
||||
try:
|
||||
with open(labels / path.with_suffix('.txt').name, 'a') as file:
|
||||
annIds = coco.getAnnIds(imgIds=im["id"], catIds=catIds, iscrowd=None)
|
||||
annIds = coco.getAnnIds(imgIds=im["id"], catIds=catIds, iscrowd=False)
|
||||
for a in coco.loadAnns(annIds):
|
||||
x, y, w, h = a['bbox'] # bounding box in xywh (xy top-left corner)
|
||||
xyxy = np.array([x, y, x + w, y + h])[None] # pixels(1,4)
|
||||
|
||||
Reference in new issue
Block a user