Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fail #3

Closed
HIT-Ygq opened this issue Jun 28, 2023 · 10 comments
Closed

fail #3

HIT-Ygq opened this issue Jun 28, 2023 · 10 comments

Comments

@HIT-Ygq
Copy link

HIT-Ygq commented Jun 28, 2023

Very good work! I can run roslaunch ma_lio mapping_city.launch successfully, but roslaunch ma_lio mapping_urban.launch will fail, have you encountered this?
err01

@HIT-Ygq HIT-Ygq closed this as completed Jun 28, 2023
@minwoo0611
Copy link
Owner

It appears that your issue may have been resolved, but I've added some additional comments to further clarify things.

The launch file I utilize for urbanNav is designed for a 2 LiDAR system, whereas for the city dataset, it is tailored for a 3 LiDAR system. As detailed in the ReadMe, should you wish to operate MA-LIO with a different number of LiDARs, certain portions of the code need to be altered in accordance with the instructions provided in the ReadMe.

I appreciate your efforts in testing MA-LIO. Should you have any additional questions or concerns, please feel at ease to raise them in the issue tab.

@HIT-Ygq
Copy link
Author

HIT-Ygq commented Jun 28, 2023

Thanks, I'm testing a single LiDAR. Would you be able to write a detailed description?

@minwoo0611
Copy link
Owner

If your intention is to use a single LiDAR system, modifications need to be made in both the yaml file and the code. Here are the three key changes:

  1. Modify the yaml file. You should adjust each variable, as outlined in the ReadMe, to be a 1 size array with a single element.
  2. Update the laserMapping.cpp file. The ApproximateTime, Synchronizer, and cbk function should all be modified. Instructions on how to adapt the code for a single LiDAR in the MA-LIO can be found within the function. To find this information easily, you can search for the word "Especially" within laserMapping.cpp.
  3. Lastly, the use-ikfom.hpp needs to be adjusted. The extrinsic variable should match the number of your LiDARs, in this case, 1.

I sincerely hope that these instructions will be beneficial to your project. Thank you for your ongoing engagement.

@HIT-Ygq
Copy link
Author

HIT-Ygq commented Jun 28, 2023

I modified the following points, but the compilation error, can you provide comments?
101
102
103
104

@minwoo0611
Copy link
Owner

As I've noted in the code, the lidar_cbk_ function should contains a single function with two inputs. So, to implement your desired changes, your code adjustments would look like this:

  1. For the Synchronizer part:

    • Original:

      sync->registerCallback(boost::bind(&lidar_cbk_, _1, _1));

    • Modified for readability:

      sync->registerCallback(boost::bind(&lidar_cbk_, _1, _2));

  2. For the cbk function part:

    • Original:

      void lidar_cbk_(const sensor_msgs::PointCloud2::ConstPtr &scanMsg_)
      {
          standard_pcl_cbk(scanMsg_, 0);
          standard_pcl_cbk(scanMsg_, 0);
      }
    • Modified:

      void lidar_cbk_(const sensor_msgs::PointCloud2::ConstPtr &scanMsg_, const sensor_msgs::PointCloud2::ConstPtr &scanMsg2_)
      {
          standard_pcl_cbk(scanMsg_, 0);
      }

The registerCallback function has two variables. Therefore, lidar_cbk_ must have two inputs. However, since the two inputs are identical, only one LiDAR message needs to be processed.

These alterations should help you adjust the code for a single LiDAR setup.

@hr2894235132
Copy link

I modified the following points, but the compilation error, can you provide comments? 101 102 103 104

Hello, how did you test a single lidar?

@minwoo0611
Copy link
Owner

@hr2894235132
Hello HaoRui, can you give me a more information about your problem?

@minwoo0611 minwoo0611 reopened this Dec 5, 2023
@hr2894235132
Copy link

@hr2894235132 Hello HaoRui, can you give me a more information about your problem?

Thank you for your prompt reply! First of all, thank you very much for your excellent work for me to learn. in fact, I have been doing fast-lio and voxel_Map related tests before, and I saw that the friend above tested the MA-LIO single lidar, so I want to understand the effect of the MA-LIO single lidar first.

@minwoo0611
Copy link
Owner

You're welcome! It's great to hear about your interest and experiments with fast-lio and voxel_Map. Regarding the use of MA-LIO with a single LiDAR, here are some key points to consider:

  1. Undistortion of Points: MA-LIO enhances point undistortion by utilizing a continuous trajectory estimator. This approach provides a smoother outcome compared to traditional linear time interpolation, leading to more accurate point undistortion.

  2. Residual Weight Adjustment: In environments where the signal might be degenerate, MA-LIO adjusts the residual weight between the LiDAR and IMU based on localization weight, which could be beneficial even for a single LiDAR setup.

  3. Lidar Uncertainty: The concept of LiDAR uncertainty, a feature of MA-LIO, is also applicable to single LiDAR systems. This means each measurement can have a varying weight, enhancing the accuracy of the data.

It's important to note that while MA-LIO is primarily designed for asynchronous multiple LiDAR integration, these features can still be effectively applied to a single LiDAR setup, although the overall impact might be less pronounced compared to a multi-LiDAR configuration.

@hr2894235132
Copy link

You're welcome! It's great to hear about your interest and experiments with fast-lio and voxel_Map. Regarding the use of MA-LIO with a single LiDAR, here are some key points to consider:

  1. Undistortion of Points: MA-LIO enhances point undistortion by utilizing a continuous trajectory estimator. This approach provides a smoother outcome compared to traditional linear time interpolation, leading to more accurate point undistortion.
  2. Residual Weight Adjustment: In environments where the signal might be degenerate, MA-LIO adjusts the residual weight between the LiDAR and IMU based on localization weight, which could be beneficial even for a single LiDAR setup.
  3. Lidar Uncertainty: The concept of LiDAR uncertainty, a feature of MA-LIO, is also applicable to single LiDAR systems. This means each measurement can have a varying weight, enhancing the accuracy of the data.

It's important to note that while MA-LIO is primarily designed for asynchronous multiple LiDAR integration, these features can still be effectively applied to a single LiDAR setup, although the overall impact might be less pronounced compared to a multi-LiDAR configuration.

Thank you for your patient reply, it helped me a lot! I took the time to test the single lidar.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants