Ask Your Question
0

Map is distorted

asked 2021-09-10 05:53:34 -0600

masterkey gravatar image

Hello,

I have a rover with which I want to perform SLAM. The rover has a Kinect camera. I also have Wheel Odometry at my disposal.

It runs RTABMAP with localization:=true. For Odom I use robot_localization in which wheel odom and visual_odom is merged. If I now create a map with ocotmap in RVIZ by driving the rover once in a circle, the rover turns slower in RVIZ than in reality. The result is that a square room suddenly has 5 corners. :-D

image description

Some approach still seems to be fundamentally wrong. Shouldn't loop-clousure in rtabmap close the gap at the end of the circle and correct the map?

edit retag flag offensive close merge delete

Comments

yes, but if covariance in odometry topic is underestimated, it may reject the loop closures. Look at the terminal for possible warnings like "loop closure rejected because...".

matlabbe gravatar image matlabbe  ( 2021-09-13 10:49:12 -0600 )edit

thank you matlabbe! but what do you mean with covariance in odometry? do you mean the process_noise_covariance and initial_estimate_covariance? If yes, how can I adjust it?

masterkey gravatar image masterkey  ( 2021-10-11 14:26:44 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2021-10-11 14:24:29 -0600

masterkey gravatar image

I already found out that I have to set the localization mode to false first.

It still does not work. I get the error messages in rtabmap:

[ INFO] [1633977903.070727874]: Odom: quality=337, std dev=0.015768m|0.068844rad, update time=0.223289s
[ INFO] [1633977903.289025833]: rtabmap (113): Rate=1.00s, Limit=0.000s, Conversion=0.0021s, RTAB-Map=0.2129s, Maps update=0.0008s pub=0.0000s (local map=6, WM=6)
[ WARN] (2021-10-11 20:45:04.121) OdometryF2M.cpp:529::computeTransform() Registration failed: "Not enough inliers 7/20 (matches=141) between -1 and 124" (guess=xyz=0.000173,-0.003361,-0.004406 rpy=-0.000072,-0.001769,0.001053)
[ WARN] (2021-10-11 20:45:04.122) OdometryF2M.cpp:290::computeTransform() Failed to find a transformation with the provided guess (xyz=0.000173,-0.003361,-0.004406 rpy=-0.000072,-0.001769,0.001053), trying again without a guess.
[ WARN] (2021-10-11 20:45:04.441) OdometryF2M.cpp:539::computeTransform() Trial with no guess succeeded!
[ INFO] [1633977904.453612297]: Odom: quality=259, std dev=0.036711m|0.077304rad, update time=0.532540s
[ INFO] [1633977904.675536318]: rtabmap (114): Rate=1.00s, Limit=0.000s, Conversion=0.0020s, RTAB-Map=0.2168s, Maps update=0.0006s pub=0.0000s (local map=6, WM=6)

My r_l ekf.yaml file looks like this:

frequency: 20
silent_tf_failure: false
sensor_timeout: 1.5
two_d_mode: true
transform_time_offset: 0.0
transform_timeout: 0.0
print_diagnostics: true
debug: false
debug_out_file: /path/to/debug/file.txt
publish_tf: true
publish_acceleration: false
permit_corrected_publication: false


map_frame: map              # Defaults to "map" if unspecified
odom_frame: odom           # Defaults to "odom" if unspecified
base_link_frame: base_link  # Defaults to "base_link" if unspecified
world_frame: odom           # Defaults to the value of odom_frame if unspecified

odom0: ackermann_odom

odom0_config: [false, false, false,
           false, false, false,
           true,  true, false,
           false, false, false,
           false, false, false]

odom0_queue_size: 2
odom0_nodelay: false
odom0_differential: false     #default false
odom0_relative: false
odom0_pose_rejection_threshold: 5
odom0_twist_rejection_threshold: 1

odom1: /rtabmap/visual_odom

odom1_config: [false, false, false,
           false, false, false,
           false, false, false,
           false, false, true,
           false, false, false]

odom1_differential: false
odom1_relative: false
odom1_queue_size: 2
odom1_pose_rejection_threshold: 2
odom1_twist_rejection_threshold: 0.2
odom1_nodelay: false

use_control: true
stamped_control: false
control_timeout: 0.2
control_config: [true, false, false, false, false, true]

acceleration_limits: [1.3, 0.0, 0.0, 0.0, 0.0, 3.4]
deceleration_limits: [1.3, 0.0, 0.0, 0.0, 0.0, 4.5]
acceleration_gains: [0.8, 0.0, 0.0, 0.0, 0.0, 0.9]
deceleration_gains: [1.0, 0.0, 0.0, 0.0, 0.0, 1.0]


process_noise_covariance: [0.05, 0,    0,    0,    0,    0,    0,     0,     0,    0,    0,    0,    0,    0,    0,
                       0,    0.05, 0,    0,    0,    0,    0,     0,     0,    0,    0,    0,    0,    0,    0,
                       0,    0,    0.06, 0,    0,    0,    0,     0,     0,    0,    0,    0,    0,    0,    0,
                       0,    0,    0,    0.03, 0,    0,    0,     0,     0,    0,    0,    0,    0,    0,    0,
                       0,    0,    0,    0,    0.03, 0,    0,     0,     0,    0,    0,    0,    0,    0,    0,
                       0,    0,    0,    0,    0,    0.06, 0,     0,     0,    0 ...
(more)
edit flag offensive delete link more

Comments

That warning is only telling you that odometry did not get enough correspondences from estimation from motion, but it recovered doing global feature matching. If you have a rosbag of your trajectory (without SLAM/robot_localization started) with the corresponding launch file, it could help to see if there is a problem in sensor data.

matlabbe gravatar image matlabbe  ( 2021-10-11 15:08:37 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2021-09-10 05:53:34 -0600

Seen: 46 times

Last updated: Oct 11 '21