-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Open
Description
Is your feature request related to a problem? Please describe.
Currently, in the context of pathology, PatchWSIDataset accepts
[
{"image": "path/to/image1.tiff", "location": [200, 500], "label": 0},
{"image": "path/to/image2.tiff", "location": [100, 700], "patch_size": [20, 20], "patch_level": 2, "label": 1},
]Consider the following sampling strategy:
- sample from a distribution of labels
- using that label, sample from all available annotations of that label
- using that annotation, sample a location
- using that location, sample a patch from the WSI using
PatchWSIDataset
A lot of the strategy must be done outside WSIPatchDatset.
Describe the solution you'd like
It would be nice to have these sampling strategies available out of the box, e.g. make SlidingPatchWSIDataset accept masks too or make PatchWSIDataset accept masks and sampling probabilities of classes.
Describe alternatives you've considered
The strategy is implemented by WholeSlideData. It associates annotations with images.
PathML also supports loading masks and slides simultaneously, so does TIA Toolbox.
Reactions are currently unavailable