Using Apriltags to optimize the graph

Posted by nikitha on
URL: http://official-rtab-map-forum.206.s1.nabble.com/Using-Apriltags-to-optimize-the-graph-tp6369.html

I am trying to optimise the graph and the point cloud so produced by placing standalone apriltags at fixed locations. However the results produced without using the tags appear to be better on comparison. I am using apriltags_ros package and the /tag_detections message produced by it.
Cameras used : D435 and T265 (Odometry fused with the help of robot localisation package with ukf template)
Rqt_graph : tag.png
Transform tree :  frames.pdf
Launch File : Final_Merged_file.launch, problem_test.launch , continuous_detection.launch

Results produced without using apriltags_ros package :

Results produced using apriltag_ros package :

RGBD/MarkerDetection is set to true in both cases.

It would be helpful if you could let me know what changes are required to obtain better results when tags are used.
Thank you


EDIT
When one of the tags is revisited, the map realigns and appears like this.

In order to improvise it further i have tried to fuse the pose and orientation information coming from apriltags_ros using robot_localisation package. I have changed the type of the message to nav_msg/Odometry by using a separate node that captures the data and republishes it. The problem still persists. How is the information received via /tag_detections topic being used in RTAB-Map? Should a transform be applied to the data before using it?
As a part of another experiment i have placed the tags on floor and walked in the same path. The  path is perfect and here is it's graph view.