Hello, I am using the RTK-GPS to connect with ntrip and i followed "https://hm02123.tistory.com/8" this link to ssetup the rtk_gps. I remapped the gps data to
<arg name="gps_topic" default="/ublox_gps/fix" />and i also set the : <arg name="ground_truth_frame_id" default="world"/> <arg name="ground_truth_base_frame_id" default="base_link_gt"/> .From the example "rtabmap_examples/launch/rgbdslam_datasets.launch" I included the below transform: <!-- TF FRAMES --> <node pkg="tf" type="static_transform_publisher" name="world_to_map" args="0.0 0.0 0.0 0.0 0.0 0.0 /world /map 100" /> But i am not sure where should i add the base_link_gt frmae taht is not link with my robot tf tree. Can anyone please help me to setup the rtk-gps as a ground truth to the rtabmap? Thank You |
Administrator
|
The RTK would give a relative position from where it started estimating position to the GPS receiver on the robot. If you know the offset between the GPS receiver and the base frame of the robot, you can express it as a static TF /gps_frame_gt -> /base_link_gt, with RTK pose giving /world -> /gps_frame_gt. These TF tree should be independent of the robot TF tree. You can then configure the ground truth of rtabmap like you did:
<arg name="ground_truth_frame_id" default="world"/> <arg name="ground_truth_base_frame_id" default="base_link_gt"/> The world->map is not necessary, but useful to show at the same time the two TF trees so that we can debug/visualize that base_link_gt is following base_link (assuming mapping and RTK starts both at 0,0,0). |
Thank You for the explanation, but i am still confused for the offset i set the gps_frame_gt to 1.0m high from my base_link ans i set a ststic tramnsform in my launch file like:
<launch> <!-- Static Transform for GPS --> <node pkg="tf" type="static_transform_publisher" name="base_to_gps" args="0 0 1 0 0 0 /base_link_gt /gps_frame_gt 100" /> </launch>but I didn't understand " with RTK pose giving /world -> /gps_frame_gthow i implement this. As I am using the ntrip_ros package and ublox_ros package so that is only publishing the gps data on/ublox_gps/fix. So, how i do it to make sure tahts its also giving the /world -> /gps_frame_gt. |
Administrator
|
When using /world -> /gps_frame_gt, I would do instead:
<launch> <!-- Static Transform for GPS --> <node pkg="tf" type="static_transform_publisher" name="base_to_gps" args="0 0 -1 0 0 0 /gps_frame_gt /base_link_gt 100" /> </launch>EDIT unless as shown in example below, you could get a TF tree like /world -> /base_link_gt -> gps_frame_gt, then you could keep what you did. To provide /world->/gps_frame_gt, you may use robot_localization with navsat_transform_node http://docs.ros.org/en/melodic/api/robot_localization/html/integrating_gps.html You may look at this page: https://msadowski.github.io/ardusimple-ros-integration/, it seems you may not need input odometry or imu to make it work. He has a demo repo: https://github.com/msadowski/ardusimple_rover <launch> <rosparam command="load" file="$(find ardusimple_rover)/config/ekf_ardusimple.yaml" /> <node pkg="robot_localization" type="ekf_localization_node" name="ekf_se_map" clear_params="true"> <!-- <remap from="odometry/filtered" to="odometry/filtered_map"/> --> </node> <node pkg="tf" type="static_transform_publisher" name="base_gps" args="0 0 0 0 0 0 /base_link /gps 100"/> <node pkg="robot_localization" type="navsat_transform_node" name="navsat_transform_node" respawn="true" output="screen"> <rosparam command="load" file="$(find ardusimple_rover)/config/navsat_config.yaml" /> <remap from="/imu/data" to="/gps/navheading" /> <remap from="/gps/fix" to="/gps/fix" /> <param name="wait_for_datum" value="false" /> </node> </launch> So he feeds the odometry output of the ekf node back to navsat node. The rosbag is missing from the repo to test this, but based on the blog, it looks like what you want. You may adjust the frame names of the ekf node so that right TF is published. cheers, Mathieu |
Thank you for your explanation, but I am still having trouble understanding how to use this. The EKF node is usually set up to take odometry and IMU data, but I don't want to use that data. Instead, I am using GPS as the ground truth for RTAB-Map to compare the trajectory of visual odometry with the robot's actual trajectory and calculate the RMSE. I followed your instructions and created the launch file below:
<launch> <rosparam command="load" file="$(find hada_navigation)/params/hada_ekf_config.yaml" /> <node pkg="robot_localization" type="ekf_localization_node" name="ekf_se_map" clear_params="true"> <!-- <remap from="odometry/filtered" to="odometry/filtered_map"/> --> </node> <!--node pkg="tf" type="static_transform_publisher" name="base_gps" args="0 0 0 0 0 0 /base_link_gt /gps 100"/--> <node pkg="robot_localization" type="navsat_transform_node" name="navsat_transform_node" respawn="true" output="screen"> <rosparam command="load" file="$(find hada_navigation)/params/hada_navsat_config.yaml" /> <remap from="/imu/data" to="/gps/navheading" /> <remap from="/gps/fix" to="/ublox_gps/fix" /> <param name="wait_for_datum" value="false" /> </node> </launch> However, I’m still not getting the TF between the world frame and gps_frame_gt. Also, I’m confused about where to change the topic in the EKF node. I tried changing it in the YAML file, but it didn’t work for me. Here is the transform tree:frames.pdfHere is the rqt_graph picture :rosgraph.svgI would really appreciate it if you could assist me. Actually, I am currently analyzing the RTAB-Map results generated using stereo odometry and require ground truth values to compare the accuracy and evaluate the performance of the map. If you have any alternative methods or suggestions to compare mapping accuracy, I would appreciate your guidance. Thank You |
Free forum by Nabble | Edit this page |