-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Add "roundness" property to regionprops #5261
base: main
Are you sure you want to change the base?
Conversation
Hello @AlexanderSvan! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found: There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2021-03-08 16:59:03 UTC |
Hi @AlexanderSvan! 👋 And welcome. Looking up the paper, it doesn't seem to have much traction in the community, with just one citation. We try to provide reference algorithms with proven widespread use in the community. It also appears to be a simple variant/combination of "equivalent diameter"/"major axis length". So I'm not sure whether we would want to expand the API for this. We'll have to have a discussion with @scikit-image/core. I'll point you to the fact that regionprops allows you to define custom properties, so you can always define a function Regardless of whether we end up merging this, thank you for the contribution! |
I didn't look too carefully, but this may be closely related to "circularity", for which there are a whole bunch of published definitions out there. |
It's such a commonly used measure that it would be worth our while to do some research and implement the most commonly used one (or the best one, if there's a difference). |
I have seen it used a few places and was one thing i found lacking for some of the cell segmentation pipelines i have been using skimage for, so i thought it might be a nice addition. I am not experienced with github contribution to established packages, but i though to try to make the addition as a learning task for myself, and then see if you thought it would be useful or not. The implementation i opted for was one that relied on the parameters already present in regionprops. |
Great @AlexanderSvan! We love that attitude here at scikit-image! 😊 Like @stefanv said, it makes sense to find e.g. the n-dimensional equivalent function to the most commonly-seen implementations in the literature. n-dimensional so that "circularity" becomes "sphericity" in 3D and so on. =) |
I would love to try to read up on it and see if i can come up with an implementation that might solve that, though that would take some time as it happens on the side of my regular studies. What is the routine with this then. We close this one, right and then i can make a new request once i manage the better approach? |
Excellent, thanks for taking this on! You can just keep improving this PR. Every time you make an adjustment and push up a commit into the same branch, the PR will update automatically. |
I have a quick question i hope i can ask you. I have been looking up the best ways of implementing sphericity/circularity calculations. Implementations are simple relations between surface area and volume, with perfect circles/spheres returning 1. |
@AlexanderSvan man, I'm sorry that we dropped the ball on this one and you never got a response to your question. If you are still interested in this, I would be happy to have a video chat with you next month and get this across the line. Hopefully you can find a time that works for you at https://meet.jni.codes. Thank you! 🙏 |
Description
This is adds a property to regionprops which calculates the roundness of a particle, similart to what is done in the following paper: 1. Abu-Qasmieh I (2018) Novel and Efficient Approach for Automated Separation, Segmentation, and Detection of Overlapped Elliptical Red Blood Cells. Pattern Recognit Image Anal 28:792–804. doi: 10.1134/S1054661818040156
For cell based imaging of nuclei and red blood cells this is a usefull parameter for stratification of objects into single objects/multiple objects.
For reviewers
later.
__init__.py
.doc/release/release_dev.rst
.