From c7a28da18dcd53f390ef56d892312efef9e1cfab Mon Sep 17 00:00:00 2001 From: Erik Andresen Date: Sun, 12 Mar 2017 11:27:32 +0100 Subject: [PATCH] added hector, cartographer launch --- config/cartographer.lua | 52 +++++++++++++++++++++++++++++++ config/costmap_common_params.yaml | 2 +- launch/cartographer.launch | 14 +++++++++ launch/hector.launch | 15 +++++++++ 4 files changed, 82 insertions(+), 1 deletion(-) create mode 100644 config/cartographer.lua create mode 100644 launch/cartographer.launch create mode 100644 launch/hector.launch diff --git a/config/cartographer.lua b/config/cartographer.lua new file mode 100644 index 0000000..fdc1de6 --- /dev/null +++ b/config/cartographer.lua @@ -0,0 +1,52 @@ +-- Copyright 2016 The Cartographer Authors +-- +-- Licensed under the Apache License, Version 2.0 (the "License"); +-- you may not use this file except in compliance with the License. +-- You may obtain a copy of the License at +-- +-- http://www.apache.org/licenses/LICENSE-2.0 +-- +-- Unless required by applicable law or agreed to in writing, software +-- distributed under the License is distributed on an "AS IS" BASIS, +-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +-- See the License for the specific language governing permissions and +-- limitations under the License. + +include "map_builder.lua" + +options = { + map_builder = MAP_BUILDER, + map_frame = "map", + tracking_frame = "base_imu_link", + published_frame = "base_link", + odom_frame = "odom", + provide_odom_frame = false, + use_odometry = true, + use_laser_scan = true, + use_multi_echo_laser_scan = false, + num_point_clouds = 0, + lookup_transform_timeout_sec = 0.2, + submap_publish_period_sec = 0.3, + pose_publish_period_sec = 5e-3, +} + +MAP_BUILDER.use_trajectory_builder_2d = true + +TRAJECTORY_BUILDER_2D.laser_min_range = 0.4 +TRAJECTORY_BUILDER_2D.laser_max_range = 3.5 +TRAJECTORY_BUILDER_2D.laser_missing_echo_ray_length = 2.0 +TRAJECTORY_BUILDER_2D.use_imu_data = true +TRAJECTORY_BUILDER_2D.motion_filter.max_time_seconds = 0.3 +TRAJECTORY_BUILDER_2D.motion_filter.max_distance_meters = 0.2 +TRAJECTORY_BUILDER_2D.motion_filter.max_angle_radians = math.rad(3.) +TRAJECTORY_BUILDER_2D.ceres_scan_matcher.translation_weight = 70 +TRAJECTORY_BUILDER_2D.ceres_scan_matcher.rotation_weight = 300 + +TRAJECTORY_BUILDER_2D.submaps.resolution = 0.035 +TRAJECTORY_BUILDER_2D.submaps.num_laser_fans = 120 +SPARSE_POSE_GRAPH.optimize_every_n_scans = 120 +SPARSE_POSE_GRAPH.constraint_builder.min_score = 0.82 +SPARSE_POSE_GRAPH.constraint_builder.sampling_ratio = 1. +SPARSE_POSE_GRAPH.constraint_builder.ceres_scan_matcher.covariance_scale = 3e-5 + +return options diff --git a/config/costmap_common_params.yaml b/config/costmap_common_params.yaml index 5662912..998b0be 100644 --- a/config/costmap_common_params.yaml +++ b/config/costmap_common_params.yaml @@ -4,7 +4,7 @@ obstacle_layer: observation_sources: laser_scan_sensor obstacle_range: 2.5 raytrace_range: 3.0 - laser_scan_sensor: {sensor_frame: camera_depth_frame, data_type: LaserScan, topic: scan, marking: true, clearing: true} + laser_scan_sensor: {data_type: LaserScan, topic: scan, marking: true, clearing: true} inflation_layer: inflation_radius: 0.20 diff --git a/launch/cartographer.launch b/launch/cartographer.launch new file mode 100644 index 0000000..5c2eb9e --- /dev/null +++ b/launch/cartographer.launch @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/launch/hector.launch b/launch/hector.launch new file mode 100644 index 0000000..82cd102 --- /dev/null +++ b/launch/hector.launch @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + -- 2.39.2