sm_options.c
Go to the documentation of this file.
1 #include <options/options.h>
2 
3 #include "csm_all.h"
4 
5 
6 void sm_options(struct sm_params*p, struct option*ops) {
7 
8  options_double(ops, "max_angular_correction_deg", &(p->max_angular_correction_deg),
9  90.0, "Maximum angular displacement between scans");
10 
11  options_double(ops, "max_linear_correction",
12  &(p->max_linear_correction), 2.0,
13  "Maximum translation between scans (m)");
14 
15  options_int(ops, "max_iterations",
16  &(p->max_iterations), 1000,
17  "When we had enough");
18 
19  options_double(ops, "epsilon_xy",
20  &(p->epsilon_xy), 0.0001,
21  "A threshold for stopping (m)");
22 
23  options_double(ops, "epsilon_theta",
24  &(p->epsilon_theta), 0.0001, /* = 0.005 deg */
25  "A threshold for stopping (rad)");
26 
27  options_double(ops, "max_correspondence_dist",
28  &(p->max_correspondence_dist), 2.0,
29  "dubious parameter (m)");
30 
31  options_double(ops, "sigma",
32  &(p->sigma), 0.01,
33  "Noise in the scan (m)");
34 
35  options_int(ops, "use_corr_tricks",
36  &(p->use_corr_tricks), 1,
37  "Use smart tricks for finding correspondences.");
38 
39  options_int(ops, "restart",
40  &(p->restart), 1,
41  "Restart: Restart if error is over threshold");
42 
43  options_double(ops, "restart_threshold_mean_error",
44  &(p->restart_threshold_mean_error), 0.01,
45  "Restart: Threshold for restarting. )");
46 
47  options_double(ops, "restart_dt",
48  &(p->restart_dt), 0.01,
49  "Restart: displacement for restarting. (m)");
50 
51  options_double(ops, "restart_dtheta",
52  &(p->restart_dtheta), deg2rad(1.5),
53  "Restart: displacement for restarting. (rad)");
54 
55  options_double(ops, "clustering_threshold",
56  &(p->clustering_threshold), 0.05,
57  "Max distance for staying in the same clustering");
58 
59  options_int(ops, "orientation_neighbourhood",
61  "Number of neighbour rays used to estimate the orientation.");
62 
63 
64  options_int(ops, "use_point_to_line_distance",
66  "If 0, it's vanilla ICP.");
67 
68  options_int(ops, "do_alpha_test",
69  &(p->do_alpha_test), 0,
70  "Discard correspondences based on the angles");
71 
72  options_double(ops, "do_alpha_test_thresholdDeg",
73  &(p->do_alpha_test_thresholdDeg), 20.0, "");
74 
75  options_double(ops, "outliers_maxPerc",
76  &(p->outliers_maxPerc), 0.95, "");
77 
78  options_double(ops, "outliers_adaptive_order",
79  &(p->outliers_adaptive_order), 0.7, "");
80  options_double(ops, "outliers_adaptive_mult",
81  &(p->outliers_adaptive_mult), 2.0, "");
82 
83  options_int(ops, "do_visibility_test",
84  &(p->do_visibility_test), 0,
85  " ... ");
86 
87  options_int(ops, "outliers_remove_doubles",
88  &(p->outliers_remove_doubles), 1, "no two points in laser_sens can have the same corr.");
89 
90  options_int(ops, "do_compute_covariance",
91  &(p->do_compute_covariance), 0,
92  "If 1, computes the covariance of ICP using the method http://purl.org/censi/2006/icpcov .");
93 
94  options_int(ops, "debug_verify_tricks",
95  &(p->debug_verify_tricks), 0,
96  "Checks that find_correspondences_tricks gives the right answer.");
97 
98  options_double(ops, "gpm_theta_bin_size_deg", &(p->gpm_theta_bin_size_deg), 5.0,
99  "GPM: Dimension of bins for finding first theta.");
100  options_double(ops, "gpm_extend_range_deg", &(p->gpm_extend_range_deg), 15.0,
101  "GPM: Area around maximum.");
102  options_int(ops, "gpm_interval", &(p->gpm_interval), 1, "Interval of points to consider (1: all points, 2: every other point, etc.)");
103 
104  options_double(ops, "laser_x", &(p->laser[0]), 0.0, "laser.x (m)");
105  options_double(ops, "laser_y", &(p->laser[1]), 0.0, "laser.y (m)");
106  options_double(ops, "laser_theta", &(p->laser[2]), 0.0, "laser.theta (rad)");
107 
108  options_double(ops, "min_reading", &(p->min_reading), 0.0, "Don't use readings less than min_reading (m)");
109  options_double(ops, "max_reading", &(p->max_reading), 1000.0, "Don't use readings longer than max_reading (m)");
110 
111  options_int(ops, "use_ml_weights", &(p->use_ml_weights), 0,
112  "If 1, the field 'true_alpha' (or 'alpha') in the first scan is used to compute the incidence beta, and the factor (1/cos^2(beta)) used to weight the correspondence.");
113 
114  options_int(ops, "use_sigma_weights", &(p->use_sigma_weights), 0,
115  "If 1, the field 'readings_sigma' in the second scan is used to weight the correspondence by 1/sigma^2");
116 
117 
118  hsm_add_options(ops, &p->hsm);
119 }
int do_alpha_test
Definition: algos.h:79
#define deg2rad(x)
Definition: gpc_test.c:22
int outliers_remove_doubles
Definition: algos.h:69
int use_ml_weights
Definition: algos.h:107
double epsilon_xy
Definition: algos.h:29
int max_iterations
Definition: algos.h:27
double max_angular_correction_deg
Definition: algos.h:22
int orientation_neighbourhood
Definition: algos.h:77
void options_double(struct option *, const char *name, double *p, double def_value, const char *desc)
double clustering_threshold
Definition: algos.h:75
double max_linear_correction
Definition: algos.h:24
struct option * ops
Definition: rb_sm.c:31
double max_reading
Definition: algos.h:127
double outliers_adaptive_mult
Definition: algos.h:66
int use_corr_tricks
Definition: algos.h:36
double restart_dt
Definition: algos.h:43
double sigma
Definition: algos.h:124
Definition: options.h:49
int use_sigma_weights
Definition: algos.h:110
double restart_threshold_mean_error
Definition: algos.h:41
double max_correspondence_dist
Definition: algos.h:34
double outliers_maxPerc
Definition: algos.h:53
struct @0 p
void options_int(struct option *, const char *name, int *p, int def_value, const char *desc)
void hsm_add_options(struct option *ops, struct hsm_params *p)
Definition: hsm_interface.c:6
int do_visibility_test
Definition: algos.h:96
double do_alpha_test_thresholdDeg
Definition: algos.h:80
struct hsm_params hsm
Definition: algos.h:134
double min_reading
Definition: algos.h:127
int restart
Definition: algos.h:39
double restart_dtheta
Definition: algos.h:45
double laser[3]
Definition: algos.h:121
int gpm_interval
Definition: algos.h:132
double gpm_theta_bin_size_deg
Definition: algos.h:130
int do_compute_covariance
Definition: algos.h:114
double gpm_extend_range_deg
Definition: algos.h:131
double outliers_adaptive_order
Definition: algos.h:65
double epsilon_theta
Definition: algos.h:31
int use_point_to_line_distance
Definition: algos.h:99
void sm_options(struct sm_params *p, struct option *ops)
Definition: sm_options.c:6
int debug_verify_tricks
Definition: algos.h:117


csm
Author(s): Andrea Censi
autogenerated on Tue May 11 2021 02:18:23