-
Notifications
You must be signed in to change notification settings - Fork 1
/
LocalizationConfig.hpp
123 lines (95 loc) · 3.1 KB
/
LocalizationConfig.hpp
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
#ifndef UW_PARTICLE_LOCALIZATION_CONFIG_HPP
#define UW_PARTICLE_LOCALIZATION_CONFIG_HPP
#include <vector>
#include <string>
#include <boost/assert.hpp>
#include <uw_localization/types/environment.hpp>
namespace uw_localization {
template <typename M>
M convertProperty(const std::vector<double>& v) {
M result;
BOOST_ASSERT(result.rows() * result.cols() == (int) v.size());
unsigned s = 0;
for(unsigned i = 0; i < result.rows(); i++) {
for(unsigned j = 0; j < result.cols(); j++) {
result(i, j) = v[s++];
}
}
return result;
}
struct FilterConfig {
// General properties
unsigned int particle_number;
unsigned int perception_history_number;
double hough_interspersal_ratio;
double effective_sample_size_threshold;
int minimum_perceptions;
bool pure_random_motion;
base::Vector3d init_position;
base::Vector3d init_variance;
double utm_relative_angle;
double gps_covarianz;
double gps_interspersal_ratio;
bool use_markov;
bool avg_particle_position;
bool use_best_feature_only;
// Sensor uncertainty
double sonar_maximum_distance;
double sonar_minimum_distance;
double sonar_covariance;
double pipeline_covariance;
double buoy_covariance;
double sonar_vertical_angle;
double sonar_covariance_reflection_factor;
double sonar_covariance_corner_factor;
Eigen::Matrix3d static_motion_covariance;
Eigen::Matrix3d static_speed_covariance;
//Sensor transformations
Eigen::Translation3d sonarToAvalon;
Eigen::Vector3d pipelineToAvalon;
Eigen::Vector3d gpsToAvalon;
Eigen::Vector3d buoyCamPosition;
Eigen::Quaternion<double> buoyCamRotation;
Eigen::Quaterniond dvlRotation;
double yaw_offset;
bool useMap;
bool filterZeros;
//Motion model Properties
double param_length;
double param_radius;
double param_mass;
std::vector<double> param_thrusterCoefficient;
std::vector<double> param_linearThrusterCoefficient;
std::vector<double> param_squareThrusterCoefficient;
double param_thrusterVoltage;
std::vector<double> param_TCM;
base::Matrix6d param_linDamp;
base::Matrix6d param_sqDamp;
base::Matrix6d param_linDampNeg;
base::Matrix6d param_sqDampNeg;
base::Vector3d param_centerOfGravity;
base::Vector3d param_centerOfBuoyancy;
bool param_floating;
bool advanced_motion_model;
double max_velocity_drift;
Environment* env;
std::vector<std::string> joint_names;
//slam stuff
double feature_weight_reduction;
double feature_observation_range;
double feature_observation_minimum_range;
double feature_grid_resolution;
double feature_filter_threshold;
double feature_confidence;
double feature_empty_cell_confidence;
double feature_confidence_threshold;
double feature_output_confidence_threshold;
int feature_observation_count_threshold;
double echosounder_variance;
bool use_slam;
bool use_mapping_only;
bool single_depth_map;
bool use_initial_depthmap;
};
}
#endif