Noisy and overlapping RTabMap in PX4 SITL

asked 2022-06-10 17:16:56 -0500

penns_landing gravatar image

Model used: iris_depth_camera. Following is the launch file.

<launch> <arg name="use_rviz" default="false"/> <arg name="use_rtabmapviz" default="false"/> <node pkg="tf" type="static_transform_publisher" name="cam_to_odom" args="0.1 0 0 -1.5708 0 -1.5708 base_link camera_link 100"/>

<include file="$(find rtabmap_ros)/launch/rtabmap.launch">
        <arg name="rtabmap_args"       value="--delete_db_on_start"/>
        <arg name="depth_topic"        value="/camera/depth/image_raw"/>
        <arg name="frame_id"           value="camera_link"/>
        <arg name="visual_odometry"    value="false"/>
        <arg name="odom_topic"         value="/mavros/local_position/odom"/>
        <arg name="rgb_topic"          value="/camera/rgb/image_raw"/>
        <arg name="camera_info_topic"  value="/camera/depth/camera_info"/>
        <arg name="queue_size"         value="40"/>
        <arg name="rviz"               value="$(arg use_rviz)"/>
        <arg name="rtabmapviz"         value="$(arg use_rtabmapviz)"/>
        <arg name="publish_tf_map"     value="false" />
</include>

</launch>

The warning I'm getting:

[ WARN] [1654898169.047724132, 3625.437000000]: Could not get transform from map to camera_link after 0.200000 seconds (for stamp=3615.114000)! Error="Lookup would require extrapolation into the past. Requested time 3615.114000000 but the earliest data is at time 3615.476000000, when looking up transform from frame [camera_link] to frame [map]. canTransform returned after 0.2 timeout was 0.2."

I'm rvizing it in map frame. The map cloud is very noisy and overlapping. I believe it is related to TF. Can someone provide a brief explanation on "frame_id", and the required static transforms to use?

My thoughts:

  • Set "frame_id" to base_link
  • Run a static transform from "base_link camera_link" and "map base_link"

Did not work though!

edit retag flag offensive close merge delete

Comments

With TF issues, add tf tree to the question:

rosrun tf2_tools view_frames.py
matlabbe gravatar image matlabbe  ( 2022-10-09 17:12:45 -0500 )edit