简体   繁体   中英

MATLAB Count spheres with overlap

I am trying to count the number of spheres based on intensity value. The spheres are biomarkers from a CT scan. Therefore the center has the largest intensity. However, it is hard for me to count the spheres if there are overlaps. How can we figure out how to do the count of the spheres with overlap.

在此处输入图像描述 e这是我正在使用的真实图像的一部分

for a 3D binary image, you can call bwlabeln ( https://www.mathworks.com/help/images/ref/bwlabeln.html ) in the image processing toolbox to count/label isolated islands, but this can be slow.

if you download my iso2mesh toolbox ( http://github.com/fangq/iso2mesh ), you can also try the bwislands function

https://github.com/fangq/iso2mesh/blob/master/bwislands.m

or, create isosurfaces first and then count the closed surface components using finddisconnsurf in iso2mesh.

fv=isosurface(im, 0.5);
fc=finddisconnsurf(fv.faces);
length(fc)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM