All Projects â†’ sourishg â†’ Stereo Calibration

sourishg / Stereo Calibration

📷 📷 Stereo camera calibration using OpenCV and C++

Projects that are alternatives of or similar to Stereo Calibration

Lidar camera calibration
Light-weight camera LiDAR calibration package for ROS using OpenCV and PCL (PnP + LM optimization)
Stars: ✭ 133 (-64.63%)
Mutual labels:  camera-calibration, opencv
3dv tutorial
An Invitation to 3D Vision: A Tutorial for Everyone
Stars: ✭ 571 (+51.86%)
Mutual labels:  camera-calibration, opencv
Sltk
An OpenCV-based structured light processing toolkit.
Stars: ✭ 151 (-59.84%)
Mutual labels:  camera-calibration, opencv
Camera calibration api
A simple Python API for single camera calibration using opencv
Stars: ✭ 36 (-90.43%)
Mutual labels:  camera-calibration, opencv
Computer Vision Guide
📖 This guide is to help you understand the basics of the computerized image and develop computer vision projects with OpenCV. Includes Python, Java, JavaScript, C# and C++ examples.
Stars: ✭ 244 (-35.11%)
Mutual labels:  camera-calibration, opencv
Emotion
😄 Recognizes human faces and their corresponding emotions from a video or webcam feed. Powered by OpenCV and Deep Learning.
Stars: ✭ 324 (-13.83%)
Mutual labels:  opencv
Yoloface
Deep learning-based Face detection using the YOLOv3 algorithm (https://github.com/sthanhng/yoloface)
Stars: ✭ 339 (-9.84%)
Mutual labels:  opencv
Facemoji
😆 A voice chatbot that can imitate your expression. OpenCV+Dlib+Live2D+Moments Recorder+Turing Robot+Iflytek IAT+Iflytek TTS
Stars: ✭ 320 (-14.89%)
Mutual labels:  opencv
Face Landmark Android
Android AR Camera
Stars: ✭ 320 (-14.89%)
Mutual labels:  opencv
Pythonsift
A clean and concise Python implementation of SIFT (Scale-Invariant Feature Transform)
Stars: ✭ 374 (-0.53%)
Mutual labels:  opencv
Handeye calib camodocal
Easy to use and accurate hand eye calibration which has been working reliably for years (2016-present) with kinect, kinectv2, rgbd cameras, optical trackers, and several robots including the ur5 and kuka iiwa.
Stars: ✭ 364 (-3.19%)
Mutual labels:  camera-calibration
Fingers Detection Using Opencv And Python
A simple Fingers Detection (or Gesture Recognition) using OpenCV and Python with background substraction įŽ€å•æ‰‹åŠŋč¯†åˆĢ
Stars: ✭ 337 (-10.37%)
Mutual labels:  opencv
Poseflow
PoseFlow: Efficient Online Pose Tracking (BMVC'18)
Stars: ✭ 330 (-12.23%)
Mutual labels:  opencv
Delphi Opencv
Project Delphi-OpenCV. Translation of OpenCV library header files in Delphi
Stars: ✭ 354 (-5.85%)
Mutual labels:  opencv
Autocrop
😌 Automatically detects and crops faces from batches of pictures.
Stars: ✭ 320 (-14.89%)
Mutual labels:  opencv
Cmake Templates
Some CMake Templates (examples). Qt, Boost, OpenCV, C++11, etc 一äē›æ —子
Stars: ✭ 368 (-2.13%)
Mutual labels:  opencv
Mobilenet Ssd Realsense
[High Performance / MAX 30 FPS] RaspberryPi3(RaspberryPi/Raspbian Stretch) or Ubuntu + Multi Neural Compute Stick(NCS/NCS2) + RealSense D435(or USB Camera or PiCamera) + MobileNet-SSD(MobileNetSSD) + Background Multi-transparent(Simple multi-class segmentation) + FaceDetection + MultiGraph + MultiProcessing + MultiClustering
Stars: ✭ 322 (-14.36%)
Mutual labels:  opencv
Text Image Augmentation
Geometric Augmentation for Text Image
Stars: ✭ 333 (-11.44%)
Mutual labels:  opencv
Opencvforunity
OpenCV for Unity (Untiy Asset Plugin)
Stars: ✭ 359 (-4.52%)
Mutual labels:  opencv
Php Opencv Examples
Tutorial for computer vision and machine learning in PHP 7/8 by opencv (installation + examples + documentation)
Stars: ✭ 333 (-11.44%)
Mutual labels:  opencv

OpenCV C++ Stereo Camera Calibration

This repository contains some sources to calibrate the intrinsics of individual cameras and also the extrinsics of a stereo pair.

Dependencies

  • OpenCV
  • popt

Compilation

Compile all the files using the following commands.

mkdir build && cd build
cmake ..
make

Make sure your are in the build folder to run the executables.

Get images from webcams

This is a small helper tool to grab frames from two webcams operating as a stereo pair. Run the following command to use it.

./read -w [img_width] -h [img_height] -d [imgs_directory] -e [file_extension]

Once it is running, hit any key to grab frames. Images are saved with prefixes left and right in the desired directory.

Intrinsic calibration of a single camera

This is only for lenses which follow the pinhole model. If you have fisheye lenses with a very wide field of view then see this repository. The calibration saves the camera matrix and the distortion coefficients in a YAML file. The datatype for these matrices is Mat.

Once you have compiled the sources run the following command to calibrate the intrinsics.

./calibrate -w [board_width] -h [board_height] -n [num_imgs] -s [square_size] -d [imgs_directory] -i [imgs_filename] -e [file_extension] -o [output_filename]

For example, the command for the test images in calib_imgs/1/ would be

./calibrate -w 9 -h 6 -n 27 -s 0.02423 -d "../calib_imgs/1/" -i "left" -o "cam_left.yml" -e "jpg"

Stereo calibration for extrinisics

Once you have the intrinsics calibrated for both the left and the right cameras, you can use their intrinsics to calibrate the extrinsics between them.

./calibrate_stereo -n [num_imgs] -u [left_cam_calib] -v [right_cam_calib] -L [left_img_dir] -R [right_img_dir] -l [left_img_prefix] -r [right_img_prefix] -o [output_calib_file] -e [file_extension]

For example, if you calibrated the left and the right cameras using the images in the calib_imgs/1/ directory, the following command to compute the extrinsics.

./calibrate_stereo -n 27 -u cam_left.yml -v cam_right.yml -L ../calib_imgs/1/ -R ../calib_imgs/1/ -l left -r right -o cam_stereo.yml -e jpg

Undistortion and Rectification

Once you have the stereo calibration data, you can remove the distortion and rectify any pair of images so that the resultant epipolar lines become scan lines.

./undistort_rectify -l [left_img_path] -r [right_img_path] -c [stereo_calib_file] -L [output_left_img] -R [output_right_img]

For example

./undistort_rectify -l ../calib_imgs/1/left1.jpg -r ../calib_imgs/1/right1.jpg -c cam_stereo.yml -L left.jpg -R right.jpg
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].