PCL-Python (50%)

1. Statistical Outlier Removal

Jupyter ๋ฒ„์ ผ์€ [์ด๊ณณ]์—์„œ ํ™•์ธ ๊ฐ€๋Šฅ ํ•ฉ๋‹ˆ๋‹ค.

def do_statistical_outlier_filtering(pcl_data,mean_k,tresh):
    '''
    :param pcl_data: point could data subscriber
    :param mean_k:  number of neighboring points to analyze for any given point
    :param tresh:   Any point with a mean distance larger than global will be considered outlier
    :return: Statistical outlier filtered point cloud data
    eg) cloud = do_statistical_outlier_filtering(cloud,10,0.001)
    : https://github.com/fouliex/RoboticPerception
    '''
    outlier_filter = pcl_data.make_statistical_outlier_filter()
    outlier_filter.set_mean_k(mean_k)
    outlier_filter.set_std_dev_mul_thresh(tresh)
    return outlier_filter.filter()


cloud = do_statistical_outlier_filtering(cloud,10,0.001)
        # number of neighboring points of 10
        # standard deviation threshold of 0.001

    """
    ์ž…๋ ฅ cloudํฌ๋งท : pcl_xyz 
    pcl_xyz = pcl_helper.XYZRGB_to_XYZ(pcl_xyzrgb)    
    pcl_xyz = do_statistical_outlier_filtering(pcl_xyz,10, 0.001)    
    pcl_xyzrgb = pcl_helper.XYZ_to_XYZRGB(pcl_xyz,[255,255,255]) 

    pcl_xyzrgb์‹œ : TypeError: __cinit__() takes exactly 1 positional argument (0 given) ์—๋Ÿฌ 
    """

First filter is the PCLโ€™s Statistical Outlier Removal filter. in this filter for each point in the point cloud, it computes the distance to all of its neighbors, and then calculates a mean distance. By assuming a Gaussian distribution, all points whose mean distances are outside of an interval defined by the global distances mean+standard deviation are considered to be outliers and removed from the point cloud.

RGB-D์„ผ์„œ : Mean K = 3, x = 0.00001

ํ˜„์žฌ Radius based ๋ฐฉ์‹์€ ์ •์ƒ ๋™์ž‘ ํ•˜์ง€ ์•Š๋Š”๋‹ค๊ณ  ํ•ฉ๋‹ˆ๋‹ค. ํŒŒ๋ผ๋ฏธํ„ฐ๋ฅผ ๋ฐ”๊พธ์–ด๋„ ๊ฒฐ๊ณผ๊ฐ€ '0'์ด๋ผ๊ณ  ํ•˜๋„ค์š”. [์ฐธ๊ณ ] - 2018.06.11

Last updated