ROS功能包:livox_camera_lidar_calibration提供了一个手动校准Livox雷达和相机之间外参的方法,已经在Mid-40,Horizon和Tele-15上进行了验证。其中包含了计算相机内参,获得标定数据,优化计算外参和雷达相机融合应用相关的代码。本方案中使用了标定板角点作为标定目标物,由于Livox雷达非重复性扫描的特点,点云的密度较大,比较易于找到雷达点云中角点的准确位置。相机雷达的标定和融合也可以得到不错的结果。
在前几篇中介绍了livox_camera_lidar_calibration功能包.以及在gazebo中搭建了标定场景.并进行外参标定,进行了简单的验证.
本篇使用标定的外参,进行R3live算法的验证,看下效果怎么样
将得到的内外参数进行R3live的配置
打开r3live_config.yaml文件
修改:
- camera_intrinsic
- camera_dist_coeffs
- camera_ext_t
- camera_ext_R
注意之前标定的是相机到雷达的,R3live下面配置的雷达到相机的,所以要把得到外参旋转矩阵求逆,再填入,平移矩阵则取负
//之前的
0.00199437 -0.999998 -0.000472109
-0.00306955 0.000465986 -0.999995
0.999993 0.00199581 -0.00306862
//求逆后
0.00199437 -0.00306956 0.99999360
-0.99999780 0.00046599 0.00199581
-0.00047211 -0.99999536 -0.00306862
Lidar_front_end:
lidar_type: 1 # 1 for Livox-avia, 3 for Ouster-OS1-64
N_SCANS: 6
using_raw_point: 1
point_step: 1
r3live_common:
if_dump_log: 0 # If recording ESIKF update log. [default = 0]
record_offline_map: 1 # If recording offline map. [default = 1]
pub_pt_minimum_views: 3 # Publish points which have been render up to "pub_pt_minimum_views" time. [default = 3]
minimum_pts_size: 0.01 # The minimum distance for every two points in Global map (unit in meter). [default = 0.01]
image_downsample_ratio: 1 # The downsample ratio of the input image. [default = 1]
estimate_i2c_extrinsic: 1 # If enable estimate the extrinsic between camera and IMU. [default = 1]
estimate_intrinsic: 1 # If enable estimate the online intrinsic calibration of the camera lens. [default = 1]
maximum_vio_tracked_pts: 600 # The maximum points for tracking. [default = 600]
append_global_map_point_step: 4 # The point step of append point to global map. [default = 4]
r3live_vio:
image_width: 1024
image_height: 960
camera_intrinsic:
[715.521, 0.0, 511.578,
0.0, 717.146, 481.681,
0.0, 0.0, 1.0 ]
camera_dist_coeffs: [0.000047, 0.000106, 0.000019, 0.000009, 0.000000] #k1, k2, p1, p2, k3
# Fine extrinsic value. form camera-LiDAR calibration.
camera_ext_R:
[ 0.00199437, -0.00306956, 0.99999360,
-0.99999780, 0.00046599, 0.00199581,
-0.00047211, -0.99999536, -0.00306862 ]
camera_ext_t: [-0.191228, 0.00300958, 0.0678278]
#camera_ext_t: [0,0,0]
# Rough extrinsic value, form CAD model, is not correct enough, but can be online calibrated in our datasets.
#camera_ext_R:
# [0, 0, 1,
# -1, 0, 0,
# 0, -1, 0]
# camera_ext_t: [0,0,0]
r3live_lio:
lio_update_point_step: 4 # Point step used for LIO update.
max_iteration: 2 # Maximum times of LIO esikf.
lidar_time_delay: 0 # The time-offset between LiDAR and IMU, provided by user.
filter_size_corner: 0.30
filter_size_surf: 0.30
filter_size_surf_z: 0.30
filter_size_map: 0.30
验证的场景如下:
gazebo中的场景是这样的
控制无人机做了些旋转和平移
建立的三维模型如下:
拼接效果还可以
其中厂房的管道细节: