How to segment/partition point cloud into upper and lower layers?
22 次查看(过去 30 天)
显示 更早的评论
This problem has been troubling me for long. I have attached a dataset of unorganized point cloud. It is the partial surface of a cartilage, and it's clear that it has upper and lower surfaces. Now I'd like to use Matlab to divide the point cloud into upper and lower parts, any idea how I could do this? I thought about local search method grid by grid then separating them from the mid-plane. But this method seems very limited and doesn't work well for dataset with a severe slope.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/162639/image.jpeg)
Alternatively, I could look to segment a contour slice of it into upper and lower part. I just need a rough segmentation, the left and right end points don't matter much. After segmentation, I'd do a B-Spline surface approximation.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/162641/image.jpeg)
Any ideas? Thanks in advance!
0 个评论
回答(1 个)
Image Analyst
2017-4-5
Assuming you have (x,y,z) coordinates and want to find points above and below some specified z value:
zDivider = -41; % Dividing line between upper and lower points.
lowerPointsIndexes = z < zDivider; % Logical index.
% Now extract out x, y, and z for the lower part
xLower = x(lowerPointsIndexes);
yLower = y(lowerPointsIndexes);
zLower = z(lowerPointsIndexes);
% Now do for the upper points:
upperPointsIndexes = z >= zDivider; % Logical index.
% Now extract out x, y, and z for the lower part
xUpper = x(upperPointsIndexes);
yUpper = y(upperPointsIndexes);
zUpper = z(upperPointsIndexes);
4 个评论
stefano chiappini
2022-3-7
Hi, i have a similar question. I have got a point cloud crown tree and i need slicing along z direction with with 10 cm thickness. Is there a way to create a list ? my aim is to compute the volume with alpha shape concern each singular slice.
Thank you so much
Image Analyst
2022-3-7
Not sure what you have. Do you have a 3-D volumetric image where the voxel value is 1 if a tree occupies that voxel? Do you just want to get the top most z value for every (x,y) coordinate? And then maybe fill in some "holes" where the top most z value is way down near the middle or bottom of the tree? If so, attach your variable in a .mat file.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Point Cloud Processing 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!