How to find center of many objects included in single image
4 次查看(过去 30 天)
显示 更早的评论
Hello, I need some solution to find the center of the discs in the next image automatically. then i have to draw the profile of the line that crossing these points. I have the attached reference, i really don't understand what they did when telling about the step of "Locating the Central Sagittal Cross-section". So can anyone help me PLEASE :(
0 个评论
回答(1 个)
Florian Morsch
2018-5-11
They used a canny edge detection and then compared the found objects with a reference.
What you want to do is to check for the "disks", use a edge detection ( e.g. canny https://de.mathworks.com/help/images/edge-detection.html?searchHighlight=edge%2520detection&s_tid=doc_srchtitle ) and then use regionprops() ( https://de.mathworks.com/help/images/ref/regionprops.html?s_tid=srchtitle ) to find the center of the found objects. After that you can draw a line from point to point.
2 个评论
Florian Morsch
2018-5-17
编辑:Florian Morsch
2018-5-17
If you check the documentation on regionprops() you will see different properties you can use. Try to figure out which combination suits your case.
For exsample you could take a look on all found objects. The vertebras should be bigger (pixelwise) then other objects, maybe even the bigges. So you could filter regionprops() for only the biggest objects.
Maybe you have to do some image processing first, e.g. if you know that the spine will be on the same position in multiple images you could try to create a mask so you see only a part of the image, then check that part, which will erase some false objects.
EDIT: After i have taken another look on the paper you gave, they find the vertebrae with a canny edge detector and then run a comparison to a predefined model. So they know what the vertebrae looks like and find all objects looking the same found with the canny per correlation.
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!