rtabmap_ros
rtabmap_ros copied to clipboard
how to use the vins as an Odom in rtabmap?
hello introlab , I'm just a newbee and a small student, want to learn how to use your great work rtabmap to build my own map .
I just learned using vins-fusion with d435i, it can provide a VIO Odom. And I want to use this odom to guide my rtabmap building a great map. I learned that the rtabmap can build with vins , but I tried a lot, it failed many times, I just gave up.......... I build the rtabmap and rtabmap_ros with apt-get install, and it works well in the euroc dataset. But the rtabmap build with apt is not able to use the vins together....
in another hand, I find the rtabmap can recive "Odom" as the input odom to guide the mapping.
So I change the rtabmap-ros launch file as this:
`
<arg name="clip_distance" default="-2"/>
<arg name="use_rviz" default="true"/>
<arg name="use_rtabmapviz" default="false"/>
<include file="$(find rtabmap_ros)/launch/rtabmap.launch">
<arg name="rtabmap_args" value="--delete_db_on_start"/>
<arg name="depth_topic" value="/camera/aligned_depth_to_color/image_raw"/>
<arg name="frame_id" value="camera_link"/>
<arg name="visual_odometry" value="false"/>
<arg name="odom_topic" value="/vins_estimator/odometry"/>
<arg name="rgb_topic" value="/camera/color/image_raw"/>
<arg name="camera_info_topic" value="/camera/color/camera_info"/>
<arg name="queue_size" value="200"/>
<arg name="rviz" value="$(arg use_rviz)"/>
<arg name="rtabmapviz" value="$(arg use_rtabmapviz)"/>
</include>
`
which the vins odom topic is "/vins_estimator/odometry", and just use d435i as my camera.
And I tried run vins and rtabmap-ros together
I can get VIO Odom well, but the rtabmap-ros output like this
and the map is like this:
it seems that the tf tree is not set well and the map can not fusion together. And in rtabmapviz, it seems that the camera does not move, it holds on in the start point(although rviz the camera is move in the world frame).
how can I get the correct tf between world and map? or how to use the vins in the rtabmap? what the odom frame means about?
Hi,
The frame_id
of rtabmap
should be set to child_frame_id
set in vins odometry topic (/vins_estimator/odometry
).
Which frames VINS is published? Can you show the tf tree? rosrun tf2_tools view_frames.py
Hi,
The
frame_id
ofrtabmap
should be set tochild_frame_id
set in vins odometry topic (/vins_estimator/odometry
).Which frames VINS is published? Can you show the tf tree?
rosrun tf2_tools view_frames.py
Hello! I just learned that it may be the tf_tree not connect correctly.
After running rosrun tf2_ tools view_ Frames.py, the following results appear:
And this time, I run with the d455 (the effect should be the same as the d435i), and then after changing the value of frame_id to body, with the pkg static_transformer node like this(The content of the launch file here is as follows:):
,the result of running rtabmap_vins is shown in the left figure:
There is no yellow warning.
However, it seems that the desired effect has not been achieved, which means that the established diagrams are still not well integrated. is there something wrong?
One issue sometimes with other packages is that they provide odometry in camera optical frame (x->left, y->down, z->forward) instead of ros standard (x->forward, y->left, z->up). Even before trying rtabmap, you could launch VINS alone, open RVIZ, add a DepthCloud display, set an history of some seconds and move the camera to make sure the point clouds overlap correctly.
Hello, can you share how to use vins as odom in rtabmap? I also use a d435i camera, thank you (ಥ_ಥ)