main Content

pcdenoise

从3-D点云中删除噪音

描述

例子

ptcloudout= pcdenoise(ptcloudin返回卸下异常值的过滤点云。

[[ptcloudout,,,,嵌入式,,,,离群值] = pcdenoise(ptcloudinadditionally returns the linear indices to the points that are identified as inliers and outliers.

[[ptcloudout,,,,___] = pcdenoise(___名称=值除了以前的语法中的任何参数组合外,还指定了名称值参数。例如,阈值= 1.0将离群阈值设置为1.0

例子

全部收缩

创建平面云。

gv = 0:0.01:1; [X,Y] = meshgrid(gv,gv); ptCloud = pointCloud([X(:),Y(:),0.5*ones(numel(X),1)]); figure pcshow(ptCloud); title(“原始数据”);

图包含一个轴对象。带有标题原始数据的轴对象包含类型散点的对象。

Add uniformly distributed random noise.

噪声= rand(500,3);ptclouda = pointcloud([[ptcloud.location; noise]);图PCSHOW(PTCLOUDA);标题(“嘈杂数据”);

图包含一个轴对象。带有标题嘈杂数据的轴对象包含类型散点的对象。

删除异常值。

ptcloudb = pcdenoise(ptclouda);数字;PCSHOW(PTCLOUDB);标题(“变态数据”);

图包含一个轴对象。带有标题的数据的轴对象包含类型散点的对象。

Load an organized point cloud from a saved MAT-file.

ld =负载(“ drivelidarpoints.mat”);orgPtCloud = ld.ptCloud;

从点云中删除噪音。

orgptCloudout = pcDenoise(orgptCloud,PreserverStructure = true);

输入参数

全部收缩

点云,,,,specified as apointCloud目的。

名称值参数

Specify optional pairs of arguments asname1 = value1,...,namen = valuen, 在哪里姓名是参数名称和Valueis the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

在R2021a之前,请使用逗号分隔每个名称和值,并附上姓名用引号。

Example:阈值= 1.0将阈值设置为1.0

最近的邻居点的数量,指定为逗号分隔对,由'数字' and a positive integer in pixels. The value is used to estimate the mean of the average distance to neighbors of all points. Decreasing this value makes the filter more sensitive to noise. Increasing this value increases the number of computations.

数据类型:单身的|双倍的

离群阈值,指定为逗号分隔对,由'临界点' and a scalar. By default, the threshold is one standard deviation from the mean of the average distance to neighbors of all points. A point is considered to be an outlier if the average distance to itsk- 最近的邻居在指定的阈值之上。

数据类型:单身的|双倍的

将点云的有组织结构保存为m-by-n-by-3 location matrix, specified astrueor错误的。该表根据的值描述了点云结构前施工

前施工 功能返回
true

一个有条理的,deno的点云。

地点描述点云的结构的属性包含一个m-by-n-by-3 matrix.

Points that are not selected in the denoised point cloud are filled with,并将相应的颜色设置为[[0 0 0]

要返回有组织的点云,输入必须是有组织的点云。

错误的

无组织的,deno的点云。

地点描述点云的结构的属性包含一个m-by-3 matrix.

输出参数

全部收缩

过滤点云,返回pointCloud目的。

Inlier点的线性索引,以1 x-的返回n向量。

数据类型:UINT32

异常点的线性索引,以1 x-返回n向量。

数据类型:UINT32

References

[1] Rusu,R。B.,Z. C. Marton,N。Blodow,M。Dolha和M. Beetz。“针对家庭环境的基于3D点云的对象图”。机器人技术和自治系统杂志。2008.

扩展功能

C/C ++代码生成
Generate C and C++ code using MATLAB® Coder™.

版本历史记录

Introduced in R2015a