Giter Club home page Giter Club logo

monocular-video-odometery's Introduction

Monocular Video Odometry Using OpenCV

This is an Python OpenCV based implementation of visual odometery.

An invaluable resource I used in building the visual odometry system was Avi Singh's blog post: http://avisingh599.github.io/vision/monocular-vo/ as well as his C++ implementation found here.

Demo Video

Algorithm

Steps of the algorithm are taken from Avi Singh's blog post mentioned above.

  1. Capture images: It and It + 1
  2. Undistort the captured images (not necessary for KITTI dataset)
  3. Use FAST algorithm to detect features in image It. Track these features using an optical flow methodology, remove points that fall out of frame or are not visible in It + 1. Trigger a new detection of points if the number of tracked points falls behind a threshold. Set to 2000 in this implementation.
  4. Apply Nister's 5-point algorithm with RANSAC to find the essential matrix.
  5. Estimate R, t from the essential matrix that was computed from Nister's algorithm.
  6. Obtain scale information from an external source and concatenate translation vectors t and rotation matrices R.

For each of the steps above, the line of code is provided to the exact location where this step is preformed in the code for easy understanding. Steps 1 and 2 are skipped as they are not necessary in the KITTI dataset.

  1. Line 80, monovideoodemetry.py
  2. Line 112, monovideoodemetry.py
  3. Line 113, monovideoodemtry.py
  4. Line 142, monovideoodemtry.py

The dataset used is: KITTI Visual Odometry

Running Program

  1. First clone repository
  2. In test.py change img_path and pose_path to correct image sequences and pose file paths
  3. Ensure focal length and principal point information is correct
  4. Adjust Lucas Kanade Parameters as needed
  5. Run command python ./test.py

monocular-video-odometery's People

Contributors

alishobeiri avatar

Stargazers

VirtualPierogi avatar

Forkers

thebricktop

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.