Skip to content

Add support for instance segmentation#1877

Merged
gdlg merged 2 commits intodevelopfrom
gppayend/instance-segmentation
Sep 15, 2025
Merged

Add support for instance segmentation#1877
gdlg merged 2 commits intodevelopfrom
gppayend/instance-segmentation

Conversation

@gdlg
Copy link
Copy Markdown
Contributor

@gdlg gdlg commented Sep 12, 2025

This PR adds a new mask type for instance segmentation. The difference with semantic segmentation is that the semantic segmentation mask is a 2D mask containing the class ID associated with each pixel while the instance segmentation mask is a stack of boolean masks, one for each object.

The PR adds the following:

  • Converter from polygons to masks
  • Converter from polygons to bounding boxes because many instance segmentation algorithm needs both the masks and the bounding box of each object

Checklist

  • I have added tests to cover my changes or documented any manual tests.
  • I have added the description of my changes into CHANGELOG.
  • I have updated the documentation accordingly

Signed-off-by: Grégoire Payen de La Garanderie <gregoire.payen.de.la.garanderie@intel.com>
@codecov-commenter
Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

❌ Patch coverage is 52.56410% with 37 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/datumaro/experimental/converters.py 53.22% 29 Missing ⚠️
src/datumaro/experimental/fields.py 50.00% 8 Missing ⚠️

📢 Thoughts on this report? Let us know!

@gdlg gdlg marked this pull request as ready for review September 15, 2025 08:07
Signed-off-by: Grégoire Payen de La Garanderie <gregoire.payen.de.la.garanderie@intel.com>
@gdlg gdlg merged commit 1eeb7b4 into develop Sep 15, 2025
16 checks passed
@gdlg gdlg deleted the gppayend/instance-segmentation branch September 25, 2025 11:42
@leoll2 leoll2 mentioned this pull request Nov 20, 2025
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants