hyye / lio-mapping

Implementation of Tightly Coupled 3D Lidar Inertial Odometry and Mapping (LIO-mapping)
https://sites.google.com/view/lio-mapping
GNU General Public License v3.0
898 stars 320 forks source link

can not use imu data #15

Open ZivKidd opened 5 years ago

ZivKidd commented 5 years ago

First of all, your job is really brilliant. I am new for slam, and I have test your method by our own data collected by hesai lidar and stim 300 imu, but the rqt_gragh result shows that only the lidar data was used, so what should I do to use both lidar and imu data? Thank you very much. My launch file is below.

hyye commented 5 years ago

Hi @ZivKidd, what is your IMU topic? I think it is required to remap your own IMU topic to /imu/data.

In the current version, 40 line lidar is not supported. If your data has ring information, then you may refer to sensor_type == 320, which is used for 32 line lidar with ring information, in order to modify the source code of lio_process.

ZivKidd commented 5 years ago

Thanks for your reply. My IMU topic is /imu/data.

topics: /imu/data 213017 msgs : sensor_msgs/Imu
/pandar_points 2235 msgs : sensor_msgs/PointCloud2

And I have modified the source code to satisfy my lidar.

PointProcessor processor; // Default sensor_type is 16
if (sensor_type == 32) {
    processor = PointProcessor(-30.67f, 10.67f, 32);
} else if (sensor_type == 64) {
    processor = PointProcessor(-24.9f, 2, 64);
} else if (sensor_type == 320) {
    processor = PointProcessor(-25, 15, 32, true);
} else if (sensor_type == 40) {
    processor = PointProcessor(-16, 7, 40, true);
}

So which changes should I make to use the imu data? Thank you.

ZivKidd commented 5 years ago

Is lio_estimator_node the node I need to use my imu data? So I need to calibrate my imu and lidar first, and when I get the extrinsic parameters, lio_estimator_node will add my imu data for the mapping?

ZivKidd commented 5 years ago

when the program calibrate my imu and lidar, how can I let it publish the extrinsic parameters?

hyye commented 4 years ago

Hi @ZivKidd , there is a topic extrinsic_lb.

shul-aowu commented 4 years ago

hello, @hyye , i have a question . The extrinsic_lb is the optimize parameter, when imu finished initialization , i see the extrinsic_lb published will not change .

hyye commented 4 years ago

Hi @shul-aowu, if there is no input, it will not change. I checked fast1.bag. The extrinsic parameter indeed changes all the time.

shul-aowu commented 4 years ago

Thanks for replying so quickly. I modify a para and cause the problem. and another question: my imu installation has a transform(oritation and translation) to the lidar , and I use the out_door.yaml to test my data (outdoor) , set the extrinsic_rotation . But using my data ,I found the z axis's drift , what may cause the problem ? @hyye

hyye commented 4 years ago

@shul-aowu, if it's planar motion, the extrinsic parameter of z-axis will drift because of no enough observation (constraints). The other states can still be well estimated with this drift.

It will be better to open a new issue instead of replying in a closed issue if you have further questions.