Skip to content

Create Semantic Segmentation Model workflow block#2028

Merged
leeclemnet merged 10 commits intomainfrom
feat/workflow-semantic-seg
Mar 19, 2026
Merged

Create Semantic Segmentation Model workflow block#2028
leeclemnet merged 10 commits intomainfrom
feat/workflow-semantic-seg

Conversation

@leeclemnet
Copy link
Copy Markdown
Contributor

@leeclemnet leeclemnet commented Feb 21, 2026

What does this PR do?

  • Add Semantic Segmentation workflow block
  • Post-process semseg response into sv.Detections for integration with mask visualizer using RLE encoding to serialize non-contiguous class masks (already being done for SAM3)
  • Add support for visualizing RLE-encoded masks in MaskVisualizer (also benefits SAM3)

Type of Change

  • New feature (non-breaking change that adds functionality)

Testing

  • I have tested this change locally
  • I have added/updated tests for this change
    • unit test
    • e2e integration test

Test details:

  • unit test for semseg model workflow block
  • integration test with mask viz
  • test workflow UI in staging with local server
image

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code where necessary, particularly in hard-to-understand areas
  • My changes generate no new warnings or errors
  • I have updated the documentation accordingly (if applicable)

Additional Context

Comment thread inference/core/workflows/execution_engine/entities/types.py Outdated
@leeclemnet leeclemnet force-pushed the feat/workflow-semantic-seg branch 2 times, most recently from d7428af to 4e90543 Compare March 17, 2026 13:05
@leeclemnet leeclemnet enabled auto-merge (squash) March 17, 2026 14:05
@leeclemnet leeclemnet force-pushed the feat/workflow-semantic-seg branch 2 times, most recently from 285a843 to 9e4782e Compare March 19, 2026 12:52
Copy link
Copy Markdown
Collaborator

@PawelPeczek-Roboflow PawelPeczek-Roboflow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe output serialisation needs to be added for RLE encoded mask and following up on that - atm sv.Detections.from_inference(...) which we were alwasy recommending is not going to work with the result from server - leaving people with quite elaborated result they most likely don't know how to use
also - some e2e test would be nice

@leeclemnet leeclemnet force-pushed the feat/workflow-semantic-seg branch from 5588531 to 9d5797d Compare March 19, 2026 17:38
@leeclemnet leeclemnet force-pushed the feat/workflow-semantic-seg branch from 9d5797d to ec31839 Compare March 19, 2026 17:40
@leeclemnet
Copy link
Copy Markdown
Contributor Author

TODO for future:

  • PR to supervision to decode RLE-encoded masks (similar to how polygons are decoded) - enable sv.Detections.from_inference() to work on semseg outputs naturally
  • Bump supervision version in inference
  • For inference 2.0 consider RLE serialization for all masks, no polygon conversion

@leeclemnet leeclemnet merged commit 02c4d45 into main Mar 19, 2026
46 checks passed
@leeclemnet leeclemnet deleted the feat/workflow-semantic-seg branch March 19, 2026 18:27
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.

2 participants