Git Product home page Git Product logo

advanced-computer-vision's Introduction

Using Optical Flow to Estimate Robot State

EECS432 Advanced Computer Vision Final Project

Adam Pollack & Nate Kaiser
Northwestern University, Winter 2017

Overview

This package provides basic state (i.e. linear and angular position, velocity, acceleration) estimation functionality using optical flow data from a camera rigidly mounted to the chassis of the robot. The camera data is fused with IMU data using an Extended Kalman Filter to improve accuracy. Keep reading for specifics.

Installation

Make sure you have ROS indigo and OpenCV 2.4 installed and working on the host computer and robot. Then, to install this package:

  1. Clone this repo into a workspace and buildโ€ 
  2. SSH into Jackal and repeat the process

โ€ I highly recommend using [catkin_tools][11], which has a modernized version of the catkin_make command and other useful command line tools for working with ROS/catkin packages

Instructions For Use

Navigate to your workspace and source your setup file: source devel/setup.bash. Then run roslaunch eecs432_project <launch file name> for any of the launch files below.

Launch Files:

project.launch Launches both ekf_robot_localization.launch and ekf_robot_localization_imu.launch. Publishes nav_msgs/Odometry messages to /odometry/visual and /odometry/imu topics.

ekf_robot_localization.launch Launches nodes necessary to extract motion from a camera feed (flow.cpp), converts that output to usable data (twist_data.py), and fuses visual and IMU data to create visual-inertial odometry (robot_localization). Publishes a nav_msgs/Odometry message to /odometry/visual.

ekf_robot_localization_imu.launch Launches only the robot_localization node to convert IMU data to odometry data to be consistent in format with the other odometry outputs (position and velocity in x, y, z, roll, pitch, yaw). Publishes a nav_msgs/Odometry message on topic /odometry/imu.

Source Code:

flow.cpp Extracts features, calculates optical flow, and performs perspective transform on a live camera feed. Publishes a geometry_msgs/Twist message to /optical_flow/twist which contains twist data in the form of velocity in x, y, z, roll, pitch, and yaw.

twist_data.py Converts output of flow.cpp from a geometry_msgs/Twist message to a nav_msgs/Odometry message which contains measurement covariances in addition to the original Twist data. This message is published to the /optical_flow topic.

robot_localization ROS package used to perform fusion of multiple streams of sensor data. Converts the output to position and velocity in x, y, z, roll, pitch, and yaw. Publishes to /odometry/filtered by default. The documentation can be found here.

advanced-computer-vision's People

Contributors

njkaiser avatar apollack11 avatar

Watchers

 avatar

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.