复现FAST_LIVO2【Ubuntu 20.04.6 LTS】
目录
- 准备
- 1 Ubuntu 和 ROS
- 2 其他库
- 2.1 PCL
- 2.2 Eigen
- 2.3 OpenCV
- 3 Sophus
- 3.1 安装
- 3.2 `make`报错
- 4 Vikit
- 5 livox_ros_driver
- 5.1 Livox-SDK
- 5.2 livox_ros_driver
- FAST-LIVO2
- 运行
- 参考
准备
1 Ubuntu 和 ROS
依据开源介绍,Ubuntu 16.04~20.04。
复现版本为:Ubuntu 20.04.6 LTS,ROS noetic。
ROS安装可参考之前的一片博客: ROS安装含检测——鱼香ROS
2 其他库
2.1 PCL
依据开源介绍,PCL>=1.6。
2.2 Eigen
依据开源介绍,Eigen>=3.3.4。
2.3 OpenCV
依据开源介绍,OpenCV>=3.2。
3 Sophus
3.1 安装
git clone https://github.com/strasdat/Sophus.git
cd Sophus
git checkout a621ff
mkdir build && cd build && cmake ..
make
sudo make install
3.2 make
报错
修改Sophus/sophus/so2.cpp文件 修改为:
SO2::SO2()
{
unit_complex_.real(1.);
unit_complex_.imag(0.);
}
重新cmake
并执行后续命令,最终成功安装。
4 Vikit
Vikit contains camera models, some math 和 interpolation functions that we need. Vikit is a catkin project, therefore, download it into your catkin workspace source folder.[作者的说明]
# Different from the one used in fast-livo1
cd catkin_ws/src
git clone https://github.com/xuankuzcr/rpg_vikit.git
5 livox_ros_driver
5.1 Livox-SDK
git clone https://github.com/Livox-SDK/Livox-SDK.git
cd Livox-SDK
cd build && cmake ..
make
sudo make install
5.2 livox_ros_driver
git clone https://github.com/Livox-SDK/livox_ros_driver.git ws_livox/src
cd ws_livox
catkin_make
FAST-LIVO2
在此之前首先把livox_ros_driver添加到source[注意位置]:
source ./devel/setup.sh
cd ~/catkin_ws/src
git clone https://github.com/hku-mars/FAST-LIVO2
cd ../
catkin_make
source ~/catkin_ws/devel/setup.bash
运行
roslaunch fast_livo mapping_avia.launch
rosbag play YOUR_DOWNLOADED.bag
#改变速度
rosbag play -r YOUR_DOWNLOADED.bag
参考
[1]: FAST-LIVO2 : https://github.com/hku-mars/FAST-LIVO2
[2]: 「 Linux调试错误 」Sophus/sophus/so2.cpp:33:26:error: lvalue required as left operand of assignment: https://blog.csdn.net/Robot_Starscream/article/details/88132050