Skip to content

Add polygon dataset class#1359

Open
Om-Doiphode wants to merge 7 commits intoweecology:mainfrom
Om-Doiphode:polygon_dataset
Open

Add polygon dataset class#1359
Om-Doiphode wants to merge 7 commits intoweecology:mainfrom
Om-Doiphode:polygon_dataset

Conversation

@Om-Doiphode
Copy link
Copy Markdown
Contributor

@Om-Doiphode Om-Doiphode commented Mar 24, 2026

Description

This PR adds a polygon dataset loader class that can be used for training segmentation models like Mask RCNN.

  1. Create a polygon dataset class.
  2. Create an evaluation function for polygon predictions
  3. Write tests for polygon dataset loader

Related Issue(s)

Fixes issue #758

AI-Assisted Development

  • I used AI tools (e.g., GitHub Copilot, ChatGPT, etc.) in developing this PR
  • I understand all the code I'm submitting
  • I have reviewed and validated all AI-generated code

AI tools used (if applicable):

ChatGPT

@Om-Doiphode Om-Doiphode mentioned this pull request Mar 24, 2026
4 tasks
@jveitchmichaelis
Copy link
Copy Markdown
Collaborator

jveitchmichaelis commented Mar 25, 2026

Could you scope this pr to only the dataset/loader please? You could have a look at the keypoint commit (recently) for reference.

We can test that we can evaluate predictions (would need to add some to the repo) without integrating the training and inference loop.

We should also think about:

  • What format labels do we support loading? I think we probably should support MS-COCO at this point, or at least add a conversion script to generate a suitable CSV with the correct geometry.
  • Output format (get_item)? Typically this is boolean mask-per-object or it may need to be type long for torchvision.
  • Similarly, format convention for models in HuggingFace? See MaskFormer, etc.

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