-
Notifications
You must be signed in to change notification settings - Fork 25.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for COCO style datasets for instance segmentation #25337
Comments
Hi @roboserg, thanks for opening this feature request!
The best place to put logic like this is in an example script or demo notebook.
This would provide a working example of how to transform a coco-style dataset Ideally datasets should be converted and then uploaded to their DatasetDict equivalent on the hub. Perhaps a script would be useful to add so users could quickly convert and upload their own datasets? |
Hi @roboserg :) I created a COCO dataset for bounding boxes only. Maybe it could be useful to you: You can find a COCODataset class, which takes the |
This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread. Please note that issues that do not follow the contributing guidelines are likely to be ignored. |
Feature request
Create a standard dataset loader capable of taking datasets in the JSON COCO style format and converting them into the Huggingface format. The DatasetDict will be generated with the correct features and configurations, making it suitable for various downstream tasks, such as instance segmentation fine-tuning with the Mask2Former mode from Huggingface hub.
The loader should include a flag that allows users to specify the type of segmentation they want to load, such as "panoptic," "semantic," or "instance." These different segmentation tasks store data differently within the COCO format. It is important to note that COCO segmentation masks can be represented in two ways inside the JSON file - either as a polygon or a bitmask.
Motivation
COCO style formatted datasets are prevalent in computer vision, especially in segmentation. Adopting them would ease the transition for Deep Learning practitioners as data preparation is often the main hurdle.
Your contribution
I am versed as to how the COCO format is structured but I am a total newbie to Huggingface.
The text was updated successfully, but these errors were encountered: