Skip to content

Filter invalid bounding boxes in instance segmentation#610

Merged
guarin merged 4 commits intomainfrom
filter-invalid-bboxes
Feb 19, 2026
Merged

Filter invalid bounding boxes in instance segmentation#610
guarin merged 4 commits intomainfrom
filter-invalid-bboxes

Conversation

@guarin
Copy link
Contributor

@guarin guarin commented Feb 18, 2026

What has changed and why?

  • Apply filtering as in object detection

How has it been tested?

  • Manually

Did you update CHANGELOG.md?

  • Yes
  • Not needed (internal change)

Did you update the documentation?

  • Yes
  • Not needed (internal change without effects for user)

Copilot AI review requested due to automatic review settings February 18, 2026 11:37
@guarin
Copy link
Contributor Author

guarin commented Feb 18, 2026

/review

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds filtering of invalid bounding boxes in instance segmentation transforms, applying the same filtering pattern already used in object detection models. This ensures that bounding boxes that become invalid after transformations (e.g., due to cropping or rotation) are properly filtered out.

Changes:

  • Added conditional bbox filtering parameters (filter_invalid_bboxes and clip) to instance segmentation train transforms, matching the pattern used in object detection
  • Updated CHANGELOG.md to document the fix

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/lightly_train/_task_models/dinov3_eomt_instance_segmentation/transforms.py Added version-conditional bbox filtering parameters (filter_invalid_bboxes for albumentations>=2.0.1 and clip for albumentations>=1.4.5) to DINOv3EoMTInstanceSegmentationTrainTransformArgs
CHANGELOG.md Added entry documenting the fix for invalid bounding box filtering in instance segmentation

Copy link
Contributor

@liopeer liopeer left a comment

Choose a reason for hiding this comment

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

LGTM!

@guarin guarin enabled auto-merge (squash) February 19, 2026 11:01
@guarin guarin merged commit fc56617 into main Feb 19, 2026
16 checks passed
@guarin guarin deleted the filter-invalid-bboxes branch February 19, 2026 11:12
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

Comments