SOTA 激光相机标定velo2cam_calibration(待完成)

一、实验前提

1.github上velo2cam_calibration源码
2.标定板制作,定制钢板材质
在这里插入图片描述
3. ArUco打印贴上去即可
AprilTag标记跟踪
请添加图片描述

二、传感器调试

1.1 相机(Kinect DK)

Ubuntu18.04下Azure Kinect DK 调试(SDK源码+ROS)无比详细踩坑教程

roslaunch azure_kinect_ros_driver driver.launch

此处我继续用之前做实验用的kinect,自己调试选择自己用的其他摄像头都是可以的

1.2 激光雷达(Velodyne 16)

Ubuntu18.04+ROS melodic+VLP-16激光雷达环境配置

roslaunch velodyne_pointcloud VLP16_points.launch

这里的地址ip自己用ifconfig查看
在这里插入图片描述

1.3 调试

![在这里插入图片描述](https://img-blog.csdnimg.cn/8592844d23164f8a89960aa12c39bedb.png在这里插入图片描述/home/nj/catkin_ws/src/velo2cam_calibration/include路径下velo2cam_utils.h 第30行改为#define DEBUG 1

三、通过ROS发布相机内参消息

3.1 调试相机

l连接好相机,roslaunch azure_kinect_ros_driver driver.launch
然后再开一个终端,输入rostopic list
在这里插入图片描述修改launch文件中话题
在这里插入图片描述

source devel/setup.bash
roslaunch velo2cam_calibration mono_pattern.launch

此处本应该会自动弹出一个opencv窗口进而检测到标定版的ArUco,但不知是时间戳未同步还是DK相机畸变个数问题(我的畸变参数只有5个,但是DK内有8个,不知道是不是这对应不上的原因)
换了D455i相机测试,直接就检测到了
下面就先改时间戳呐

3.2 相机内参标定获得内参文件

参考:根据相机内参向ROS发布camera_info

image_width: 720
image_height: 1280
camera_name: narrow_stereo
camera_matrix:
  rows: 3
  cols: 3
  data: [  977.1364 ,     0.     ,  1028.06099,
             0.     ,   978.37511,   773.36348,
             0.     ,     0.     ,     1.     ]
camera_model: plumb_bob
distortion_coefficients:
  rows: 1
  cols: 5
  data: [0.079672, -0.036074, -0.001217, -0.001615, 0.000000]
rectification_matrix:
  rows: 3
  cols: 3
  data: [ 1.,  0.,  0.,
          0.,  1.,  0.,
          0.,  0.,  1.]
projection_matrix:
  rows: 3
  cols: 4
  data: [ 1020.93921,     0.     ,  1023.06419,     0.     ,
             0.     ,  1023.7868 ,   770.68412,     0.     ,
             0.     ,     0.     ,     1.     ,     0.     ]

(这两行略过,不用管
c++读取yaml文件

git clone https://github.com/jbeder/yaml-cpp.git

猜你喜欢

转载自blog.csdn.net/weixin_48924581/article/details/126274035