[FEATURE]: Enable masking of unlabeled portions of imagery during model training
See original GitHub issueThis was a topic raised by an attendee at a workshop at FOSS4G International 2019 and is something we should consider implementing.
At the moment, we assume that all pixels in the input imagery are labeled when creating pixel masks and training models. Any unlabeled portion is assumed to have no objects of interest in it. There are some use cases where only a portion of an input image is labeled, and the user only wants the model to learn based on the labeled portion. There are a few ways we could support this:
- Enable selective tiling where unlabeled portions are filled with nodata values;
- Enable selective masking where unlabeled portions of masks are filled with
NaN
or something like that; - Find a way to have loss functions have NA values in specific regions of the images so those get ignored during model training.
.
- is good though if there’s some bias in the labels near the edges of the labeled area, it could introduce bias in the model (it may learn that near nodata values some targets are more/less likely to occur).
- Is good but would be hard;
- Is good but would be really hard, particularly as we’d have to re-write every loss function anytime we added a new one. To some degree we’d have to do the same for 2., though it would just be with how to handle
NaN
inputs.
I’m inclined to go with 1. or 2. if we implement this. We’d definitely need tests implemented to make sure it works.
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
Image segmentation: leaving some pixels unlabeled?
Short version: Is it possible to leave some pixels unlabeled when training a segmentation model? If so, how would I specify “unlabeled” when...
Read more >Fine-Tune a Pretrained Deep Learning Model - Esri
In this blog post, we will cover how to fine-tune Esri's existing pretrained deep learning models to fit to your local geography, imagery,...
Read more >Semi-Supervised Learning for Forest Fire Segmentation Using ...
By taking into account the unique characteristics of UAV-acquired imagery of forest fire, the proposed method first uses occlusion-aware data ...
Read more >Export Training Data For Deep Learning (Image Analyst)
The model generates bounding boxes and segmentation masks for each instance of an object in the image. This format is based on Feature...
Read more >Self-supervised machine learning for live cell imagery ... - Nature
Pixels that exhibit FD in between these regimes remain unlabeled (gray pixels). e, f Supervised learning via self-labeled training data. The ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Got it, should have made it clear that what I’m discussing is a separate problem from filling nodata areas outside of an unlabeled boundary. To be more clear, I was discussing how to handle the case where labels are present but no valid image values exist (either due to edge effects or cloud masking). I’ve made a separate issue here: https://github.com/CosmiQ/solaris/issues/328
I don’t think this actually fully solves the intention of this request - specifically, to find a way to mask out areas from contributing to the loss function. So I’ll leave it open for now.