Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segmentation parameter min_size (for discarding small fragments) has no effect #128

Open
SilverViking opened this issue Aug 17, 2023 · 1 comment
Assignees

Comments

@SilverViking
Copy link
Collaborator

SilverViking commented Aug 17, 2023

Changing the min_size parameter in the segmentation widget in napari-sparrow has no effect whatsoever, no segmentation masks get discarded even when setting min_size to a very large value.

This seems to be due to a bug in Cellpose: internally in Cellpose the min_size parameter is not correctly passed around in all cases. Others have noticed this too, but the corresponding Cellpose issue was closed, even though the bug persists.

TODO: make small test file and re-open issue in Cellpose.

@SilverViking SilverViking self-assigned this Aug 17, 2023
@ArneDefauw
Copy link
Collaborator

ArneDefauw commented Aug 23, 2023

In sparrow we have the nas.tb.filter_on_size(sdata, min_size=..., ) function, which can filter cells that are too small/big.

So the temporary fix in sparrow could be to remove this min_size parameter from nas.im.segmentation_cellpose, and also from the segmentation widget in the plugin.

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

No branches or pull requests

2 participants