-
Notifications
You must be signed in to change notification settings - Fork 9
/
PlaneFitting.cfg
executable file
·51 lines (41 loc) · 2.79 KB
/
PlaneFitting.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#!/usr/bin/env python
from dynamic_reconfigure.parameter_generator_catkin import ParameterGenerator, double_t, int_t, bool_t, str_t
PACKAGE='mas_perception_libs'
NODE_NAME = PACKAGE
gen = ParameterGenerator()
# cloud filter group
cloud_filter_params = gen.add_group("Cloud Filter")
# pass-through filter parameters
cloud_filter_params.add("passthrough_limit_min_x", double_t, 0,
"Minimum field value of a point along x-axis for it to be considered", 0.0, -10.0, 10.0)
cloud_filter_params.add("passthrough_limit_max_x", double_t, 0,
"Maximum field value of a point along x-axis for it to be considered", 1.0, -10.0, 10.0)
cloud_filter_params.add("passthrough_limit_min_y", double_t, 0,
"Minimum field value of a point along y-axis for it to be considered", -1.0, -10.0, 10.0)
cloud_filter_params.add("passthrough_limit_max_y", double_t, 0,
"Maximum field value of a point along y-axis for it to be considered", 1.0, -10.0, 10.0)
# voxel-grid filter parameters; note that we limit the cloud along the z-axis using the voxel filter to avoid adding
# a third pass-through filter
cloud_filter_params.add("voxel_limit_min_z", double_t, 0,
"Minimum field value of a point along z-axis for it to be considered", 0.0, -10.0, 10.0)
cloud_filter_params.add("voxel_limit_max_z", double_t, 0,
"Maximum field value of a point along z-axis for it to be considered", 1.0, -10.0, 10.0)
cloud_filter_params.add("voxel_leaf_size", double_t, 0, "Size of a leaf (on x,y,z) used for downsampling.",
0.01, 0, 1.0)
# plane fitting group
plane_fitting_params = gen.add_group("SAC Plane Fitting")
# normal fitting
plane_fitting_params.add("normal_radius_search", double_t, 0,
"Sphere radius for nearest neighbor search", 0.0, 0.0, 0.5)
# RANSAC parameters
plane_fitting_params.add("sac_max_iterations", int_t, 0, "The maximum number of iterations the algorithm will run for",
50, 0, 100000)
plane_fitting_params.add("sac_distance_threshold", double_t, 0, "The threshold distance for SAC inliers", 0.02, 0, 1.0)
plane_fitting_params.add("sac_optimize_coefficients", bool_t, 0, "Model coefficient refinement", True)
plane_fitting_params.add("sac_eps_angle", double_t, 0,
"The maximum allowed difference between the point normal and the given axis in radians.",
0.17, 0.0, 1.5707)
plane_fitting_params.add("sac_normal_distance_weight", double_t, 0,
"The relative weight (between 0 and 1) to give to the angular distance (0 to pi/2)"
" between point normals and the plane normal.", 0.1, 0, 1.0)
exit (gen.generate (PACKAGE, NODE_NAME, "PlaneFitting"))