Skip to content

SOLO2COCOConverter throws keyerror "instances" when no labeled objects in image #136

@TimSchoonbeek

Description

@TimSchoonbeek

Hi,

Due to the settings used in my dataset generation, apparently not all images have a visible object (around 1/1000 images don't have 2D bounding boxes).
This causes the SOLO2COCOConverter to crash with a keyerror "instances" error.

Perhaps the converter can be updated to just skip images if there is no label, rather than crash? As I don't know which images don't have any bounding boxes, I now have to write a separate script which deletes these instances this before feeding the data to the converter.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions