数据集与工具包kitti_nuscen

工具包

pyquaternion ----> w x y z  pyquaternion.Quaternion  r = Quaternion([w, x, y, z]).rotation_matrix
scipy.spatial.transform.Rotation.as_quat() ----> x y z w
当需要使用四元数,或将四元数传入其他轮子的函数时,需要注意相关约定(w在前还是在后)		  

kitti数据集

参考历史收集整理资料

nus

nuScenes数据集存在四个坐标系:
    全局坐标系,车身坐标系,相机坐标系,雷达(Rader,Lidar)坐标系。因为标注信息是在全局坐标系下
	共有4种坐标系: 全局(Global)、车身(Ego) 、相机(Cam), 雷达(Lidar) 坐标系
nus 中标注,默认的box的wlh对应是dy,dx,dz, 宽长高
rotation wxyz

v1.0-mini文件夹	-数据格式
    nus中的雷达系为右手系,x向右,y向前,z向上
     原始token中3D的标注框是基于world系的
    原始的nus标注是global系下 
      anno_size = annotation['size']
      category_name = annotation['category_name'].split('.')[1]		  
说明-- 传感器 sensor  标定参数 calibrated_sensor
     map 和 ego_pose 位姿
 scene.json  全量数据--场景
 sample.json 抽帧数据
 	 sample和scene的关系,前面说到,每个scene大约持续20s,
      那sample就是每0.5秒进行一次采样。也可以这样理解sample和scene,
      sence相当于20s的视频,sample就是每0.5s取一帧的图像	
	传感器采集到的信息、标注信息
  样本数据 sample_data	
  样本标注 sample_annotation.json
     标注的实例对象-- 实例 instance  类别 categories 属性 attributes
 
 数据集包含1000个驾驶场景(城市是波士顿和新加坡),
    每个场景20s(from 15h data),其中850个场景是训练和验证数据,150个场景是测试数据
 以2Hz(1s两个关键帧)的频率标注了23类目标的3D框(世界坐标系下)
 
 时间同步
    LIDAR sweeps across the center of the camera’s FOV. 
	The timestamp of the image is the exposure trigger time;
	and the timestamp of the LIDAR scan is the time when the full rotation of the current LIDAR frame is achieved

opendet3d

opendet3d和mmdetection3d框架都是统一坐标系,使用常规的lidar坐标系
7维的量表示 box自身中心为原点, 运动方向为x方向的右手系,确定x,y,z,dx,dy,dz
  x, y, z, dx, dy, dz, yaw

MMDetection3D/3D目标检测中的边界框和坐标系介绍
   center_to_corner_box3d
  mmdet3d提供了定义好的边界框数据类型
   LiDARPoints(位于mmdet3d/core/points/lidar_points.py下) 激光雷达坐标系下的点云
  和CameraPoints(位于mmdet3d/core/points/camera_points.py下)相机坐标系下的点云数据类型,
  
 设bboxes为大小(M,7)的Tensor,其中M为边界框数量,7代表x,y,z坐标,x,y,z尺寸以及朝向角,若有速度等其它参数,需放置在最后
    bboxes = LiDARInstance3DBoxes(bboxes)

 边界框数据类型LiDARInstance3DBoxes(位于mmdet3d/core/bbox/structure/lidar_box3d.py下)
 以及CameraInstance3DBoxes(位于mmdet3d/core/bbox/structure/cam_box3d.py下),
 分别是激光雷达坐标系下的3D边界框以及相机坐标系下的3D边界框数据类型

自有数据集

 自定义的数据集的 ann info 保存成 pkl 文件

参考

 https://github.com/linClubs/nuscenes2kitti/blob/main/scripts/nus2common.py	
 nuscenes 数据集可视化 https://zhuanlan.zhihu.com/p/669269204
 https://github.com/nutonomy/nuscenes-devkit/blob/master/python-sdk/nuscenes/scripts/export_kitti.py
 https://www.nuscenes.org/nuscenes#data-collection
基于nuscence激光3D目标检测3Dbox可视化 https://blog.csdn.net/laukal/article/details/139016682
nuscenes2kitti/scripts/nus_vis.py  https://github.com/linClubs/nuscenes2kitti/blob/main/scripts/nus_vis.py
posted @ 2024-08-20 10:10  辰令  阅读(6)  评论(0编辑  收藏  举报