Error using pcread and pcshow

Hello! I have a problem using pcread and pcshow. I used a lidar to acquire the point clouds and now I have to read them in matlab. Using the pc read and pc show commands I get the following errors: I've used readmatrix to read the point clouds as an alternative, but for all the following step (segmentation and visualization of the point clouds) I don't think it works. Can someone help me?

8 个评论

Hi Samira,
Could you share your code as well?
Hi,this is the code for one of the point clouds I have to read
close all;clear all;clc;
ptCloud=pcread('Neuviton 001.pcd');
pcshow(ptCloud);
Matt J
Matt J 2023-6-6
编辑:Matt J 2023-6-6
'Neuviton 001.pcd' does not appear to be a valid .pcd file. How was it created?
I used a Lidar sensor to acquire the point clouds and this is the file I got from the acquisition
Can the Lidar be told to write the data to the file in uint16 instead of uint32?
I don't know, I was in the university lab and it was the professor I was with who set up the lidar. If this is the problem I think there is nothing to do to make ptCloud work and I have to find another way to do the segmentation
Can you actually read in the raw xyz points with readmatrix()? It doesn't seem like it should work to me. Have you plotted the points to see if the numbers you get make sense?
Yes, with readmatrix I can read the xyz points, the problem is that with readmatrix I wouldn't know how to do all the image processing and segmentation work that I could do in a simpler and more direct way with the ptcloud command.

请先登录,再进行评论。

回答(1 个)

Matt J
Matt J 2023-6-6
编辑:Matt J 2023-6-6

0 个投票

I wouldn't know how to do all the image processing and segmentation work that I could do in a simpler and more direct way with the ptcloud command.
Matlab has no command called "ptcloud", and without detail on what kind of commands you were planning to use in the follow-up processing, it's hard to see what you need. If you just want to convert your array of xyz points to a pointCloud object, just do,

类别

提问:

Sam
2023-6-5

编辑:

2023-6-6

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by