https://github.com/pyaf/nuscenes_viz
mayavi based 3D visualization tool for Nuscenes dataset.
Requirements
$pip install -U lyft_dataset_sdk
$pip install vtk==8.1.2
$pip install mayavi
$pip install PyQt5
Data
Nuscenes dataset 이용.
./dataroot 내부에 maps, samples, sweeps, data(==v1.0-mini) 넣음.
Run
#한 sample만 보기(한 frame)
$python lyft_viz.py -d ./dataroot/ --sample [sample_token]
#scene 단위로 보기(key 입력 시 다음 frame으로 넘어감)
$python lyft_viz.py -d ./dataroot/ --scene [scene_token]
Result
#nuscenes visualize with matplotlib
from nuscenes.nuscenes import NuScenes
nusc = NuScenes(version='v1.0-mini', dataroot='data/', verbose=True)
first_sample_token = '3e8750f331d7499e9b5123e9eb70f2e2'
my_sample = nusc.get('sample', first_sample_token)
#draw lidar_top
nusc.render_sample_data(my_sample['data']['LIDAR_TOP'], nsweeps=5, underlay_map=True)
#draw image
nusc.render_sample_data(my_sample['data']['CAM_FRONT'])
nusc.render_sample_data(my_sample['data']['CAM_BACK'])
'Dataset > Nuscenes' 카테고리의 다른 글
Nuscenes Tracking Metric (1) | 2023.11.26 |
---|