RealSense D400 series utilities
- Records bags with a camera or multiple cameras.
- Plays a bag recorded with this library
- Converts bag files to image files
- Converts bag files to video files
- Captures point cloud created from recorded RGBD frames
- Python 3.8.10
- numpy >= 1.22.2
- open3d >= 0.14.1
- pickle-mixin >= 1.0.2
- opencv-python >= 4.5.5.62
- pyrealsense2 >= 2.50.0.3812
git clone https://github.com/takuya-ki/realsense-d400.git && cd realsense-d400 && python setup.py install
python record_bag.py --save_type [save_type] --is_rsopt --rectime 10 --bag_path [path_to_bag_file] --cfg_path [path_to_cfg_file]
python record_bag.py --save_type RGBD --is_rsopt --rectime 5 --bag_path data/bag/record/record.bag --cfg_path data/cfg/auto.pkl
python play_bag.py --save_type [save_type] --is_rsopt --bag_path [path_to_bag_file] --cfg_path [path_to_cfg_file]
python play_bag.py --save_type RGBD --is_rsopt --bag_path data/bag/record/record.bag --cfg_path data/cfg/auto.pkl
python bag2img.py --save_type [save_type] --indir [path_to_bags_dir] --outdir [path_to_imgs_dir] --cfg_path [path_to_cfg_file] --save_mode [save_mode] (--save_fps [float less than 1.0])
python bag2img.py --save_type RGBD --is_rsopt --indir data/bag/record --outdir data/img/record --cfg_path data/cfg/auto.pkl --save_mode one-scene --img_ext png
python bag2video.py --save_type [save_type] --indir [path_to_bags_dir] --outdir [path_to_mp4s_dir] --cfg_path [path_to_cfg_file]
python bag2video.py --save_type RGBD --is_rsopt --indir data/bag/record --outdir data/video/record --cfg_path data/cfg/auto.pkl --video_ext mp4
python capture_pcd.py --is_rsopt --pcd_path [path_to_pcd_file] --cfg_path [path_to_cfg_file]
python capture_pcd.py --is_rsopt --pcd_path data/pcd/record/record.pcd --cfg_path data/cfg/auto.pkl
python record_bag.py --save_type RGBD --is_rsopt --rectime 5 --bag_path data/bag/record/record.bag --cfg_path data/cfg/auto.pkl --num_camera 2
python capture_pcd.py --is_rsopt --pcd_path data/pcd/record/record.pcd --cfg_path data/cfg/auto.pkl --num_camera 2
- Modify the parameters written in data/cfg/gen_config.py
- Generate configuration file
python data/cfg/gen_config.py
This software is released under the MIT License, see LICENSE.