MaverickPeter / MR_SLAM

[IEEE T-RO 2023] A modularized multi-robot SLAM system with elevation mapping and a costmap converter for easy navigation. Different odometry and loop closure algorithms can be easily integrated into the system.
MIT License
280 stars 19 forks source link

For single robot application. #23

Closed cxmzdd closed 6 months ago

cxmzdd commented 6 months ago

Hello author, thank you very much for open sourcing this project. FAST-LIO will experience drift during loopback.So i Attempt to change the loop back detection module,like this 2024-04-10 15-06-01 的屏幕截图 But there was an error in the global_manager module 2024-04-10 15-06-58 的屏幕截图 and i noticed that MR SLAM supports single robot applications, Can you give me some help for this. Thanks

MaverickPeter commented 6 months ago

@cxmzdd Thanks for following our work. I cannot understand the first question. The drift is common in FAST-LIO, and the loopback problem is caused by the loop play of the rosbag, which is not the problem of the loop detection module. As for single robot application, the error indicates that the robotid is mismatched. You may modify the start_robot_id in launch file.

cxmzdd commented 6 months ago

Thanks for your reply. I'm sorry I didn't express myself clearly. I mean FAST-LIO will experience drift during loopback. Is there a way to eliminate this drift. I noticed there is a "odometry_loop_enable" parameter,Perhaps I can change it to true to achieve my goal?

MaverickPeter commented 6 months ago

@cxmzdd odometry_loop_enable is only enabled using built-in loop detection which is not recommended. The way to achieve single robot SLAM, you need to activate the corresponding lines to detect inter-robot loops. https://github.com/MaverickPeter/MR_SLAM/blob/a46cbadac6400f4a815dcabe806e02ed67d17a0f/LoopDetection/src/RING_ros/main_RING.py#L276C4-L277C116. Also you need to comment out the inter-robot check in this line: https://github.com/MaverickPeter/MR_SLAM/blob/a46cbadac6400f4a815dcabe806e02ed67d17a0f/LoopDetection/src/RING_ros/main_RING.py#L213

cxmzdd commented 6 months ago

@MaverickPeter Thank you for your advise.i've tried it.But the mapping wil crash when receiving loop.

[ INFO] [1713874305.252086589, 1705910721.077912261]:  received loop update 
[global_manager-1] process has died [pid 636399, exit code -11, cmd /home/Mapping/devel/lib/global_manager/global_manager_node __name:=global_manager __log:=/root/.ros/log/54aaab66-015c-11ef-9537-0242ac110002/global_manager-1.log].
log file: /root/.ros/log/54aaab66-015c-11ef-9537-0242ac110002/global_manager-1*.log
MaverickPeter commented 6 months ago

@cxmzdd Could you please share your launch file and loop detection python file? I'll check it out.

cxmzdd commented 6 months ago

Sure,here is the launch file:global_manager.launch i only change the "start_robot_id" to 2. And this is the loop detection python file:main_RING.py. i use detect_loop_single_icp to add a time limit for single robot loop back detection,and change some parameters for icp to run faster

MaverickPeter commented 6 months ago

@cxmzdd Sorry for the late reply. I'll try to reproduce your issue this weekend and try to fix it.

MaverickPeter commented 6 months ago

@cxmzdd You may need to use the callback1 to subscribe /robot_2/xxx in main_RING.py to achieve single_robot application.

cxmzdd commented 6 months ago

I got it. Thanks