Skip to content

Instantly share code, notes, and snippets.

@bigsnarfdude
Last active May 15, 2017 23:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bigsnarfdude/9511355f811fe1e58b2a1125c556404e to your computer and use it in GitHub Desktop.
Save bigsnarfdude/9511355f811fe1e58b2a1125c556404e to your computer and use it in GitHub Desktop.
[LIDAR] slow point cloud filtering
# real 0m5.248s
# user 0m5.084s
# sys 0m0.828s
import pcl
p = pcl.load("/media/datadrive/didi/notebooks/data/tutorials/table_scene_lms400.pcd")
fil = p.make_statistical_outlier_filter()
fil.set_mean_k(50)
fil.set_std_dev_mul_thresh(1.0)
pcl.save(fil.filter(), "table_scene_lms400_inliers.pcd")
fil.set_negative(True)
pcl.save(fil.filter(), "table_scene_lms400_outliers.pcd")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment