Ask Your Question
0

Problem with stereo odometry using rtabmap_ros

asked 2021-04-27 10:34:38 -0500

Alex_Lok gravatar image

updated 2021-04-27 15:33:23 -0500

Hi, I am new to rtabmap_ros and visual odometry. I have ros melodic. I tried to repeat the example from the guide and the solution, but in my case the robot is very shaky when moving, which makes the picture shake as well.

In my case the robot drives down a closed corridor and when the odometry is plotted the trajectory goes down very sharply, as if the robot is going down a slope. I can't add a picture directly, so I'll leave it at the link image. How can this be fixed?

Also, when I run the same script and .bag file repeatedly, the odometry trajectory is different, is it possible to achieve repeatability? For the example I connected the first point and the end point of the odometry, the first run - image, the second run - image

My compressed file.bag

My launch file:

<launch>

<param name="use_sim_time" type="bool" value="True"/>


<group ns="/tigra/front" >
    <node pkg="nodelet" type="nodelet" name="stereo_nodelet"  args="manager"/>

    <node pkg="stereo_image_proc" type="stereo_image_proc" name="stereo_image_proc">
        <remap from="left/image_raw"    to="left/image_raw"/>
        <remap from="left/camera_info"  to="left/camera_info"/>
        <remap from="right/image_raw"   to="right/image_raw"/>
        <remap from="right/camera_info" to="right/camera_info"/>
        <param name="disparity_range" value="128"/>
    </node>
</group>

<include file="$(find rtabmap_ros)/launch/rtabmap.launch">
    <arg name="frame_id" value="base_footprint"/>
    <arg name="stereo" value="true"/>
    <arg name="approx_sync" value="true"/>
    <arg name="left_image_topic"        value="/tigra/front/left/image_rect_color" />
    <arg name="right_image_topic"       value="/tigra/front/right/image_rect" /> 
    <arg name="left_camera_info_topic"  value="/tigra/front/left/camera_info" />
    <arg name="right_camera_info_topic" value="/tigra/front/right/camera_info" />
    <arg name="rtabmap_args" value="--delete_db_on_start --Vis/EstimationType 1 --Vis/MaxDepth 0 --GFTT/QualityLevel 0.00001 --Stereo/MinDisparity 0 --Stereo/MaxDisparity 64 --Vis/RoiRatios '0 0 0 .2' --Kp/RoiRatios '0 0 0 .2' --Odom/GuessMotion true --Vis/MinInliers 10 --Vis/BundleAdjustment 1 --OdomF2M/BundleAdjustment 1 --Vis/CorNNDR 0.6 --Vis/CorGuessWinSize 20 --Vis/PnPFlags 0"/>

    <arg name="rtabmapviz" value="true"/>
    <arg name="rviz" value="false"/>
</include>

</launch>
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2021-05-04 10:59:18 -0500

matlabbe gravatar image

Hi,

This is a very challenging environment for visual feature tracking. The repetitive patterns everywhere and that the robot is shaky when turning make it very difficult to track correctly the features. I had limited success with those parameters:

"--delete_db_on_start --Vis/EstimationType 1 --Vis/MaxDepth 0 --GFTT/QualityLevel 0.00001 --Stereo/MinDisparity 0 --Stereo/MaxDisparity 64 --Vis/RoiRatios '0 0 0 .2' --Kp/RoiRatios '0 0 0 .2' --Odom/GuessMotion true --Vis/MinInliers 10 --Vis/BundleAdjustment 1 --OdomF2M/BundleAdjustment 1 --Vis/CorNNDR 0.6 --Vis/CorGuessWinSize 40 --GFTT/MinDistance 10 --Vis/PnPFlags 0 --Vis/PnPReprojError 1"

The first corridor was fine, but when turning at the end, there was a large checkerboard pattern on a far wall and at the same time the robot was turning (shaking), which made odometry lose track of the features and could not recover with global matching because all features would have same descriptor. image description

I would suggest to use more random patterns on the walls, like those.

edit flag offensive delete link more

Your Answer

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

Add Answer

Question Tools

3 followers

Stats

Asked: 2021-04-27 10:34:38 -0500

Seen: 48 times

Last updated: May 04