minwoo0611 / MA-LIO

Asynchronous Multiple LiDAR-Inertial Odometry using Point-wise Inter-LiDAR Uncertainty Propagation
GNU General Public License v2.0
287 stars 36 forks source link

stop bag, but path is updating #26

Closed rafion1 closed 3 months ago

rafion1 commented 3 months ago

Hello. Thank you for your work. During the process of reproducing, using the bag is UrbanNav-HK_TST-20210517_sensors.bag.I found out why the trajectory keeps updating when I stop playing the bag(Stop by pressing space on the terminal playing the bag)? the trajectory displayed in Rivz (as shown in the figure below) to drift far away,such as picture 1. m-lio1 At the same time, these prints are also constantly updating, such as picture 2. m-lio2

In theory, if the bag stops and does not accept sensor data, the program should stop and not continue to run, right?

minwoo0611 commented 3 months ago

Dear @rafion1

Thank you for reaching out and for your interest in our project, MA-LIO. From what you've described, it appears you've encountered an issue with the trajectory updating in Rviz after stopping the playback of the bag file, specifically "UrbanNav-HK_TST-20210517_sensors.bag".

This behavior can be attributed to how our system processes LiDAR data. The LiDAR callback function in MA-LIO is designed to save incoming ROS messages in a queue and process them sequentially. When examining the average computation time, it is evident that the processing time exceeds the LiDAR sweep rate (0.1s), resulting in a backlog of ROS messages queued for state estimation.

In theory, if the bag file stops transmitting sensor data, the program should also cease operations provided there are no more ROS messages in the subscribers' queue. However, due to the processing delay and the existing queue of messages, the state estimation might continue for a while, causing the observed drift in the trajectory.

To address this issue and enhance real-time performance, we recommend adjusting the plane_th variable in the launch file or the point_filter_num in the configuration file. Reducing the plane_th variable is particularly advised as it can significantly impact processing time by filtering out less relevant data points more efficiently.

We appreciate your support and feedback. If you have further questions or encounter additional issues, please do not hesitate to contact us.

Best regards, Minwoo