GithubHelp home page GithubHelp logo

shuj11111 / gopro_ros Goto Github PK

View Code? Open in Web Editor NEW

This project forked from autonomousfieldroboticslab/gopro_ros

0.0 0.0 0.0 94 KB

Extacting synchronized Images and IMU data from GoPro Video for VIO

License: BSD 3-Clause "New" or "Revised" License

C++ 67.87% Python 1.40% C 30.34% CMake 0.39%

gopro_ros's Introduction

gopro_ros

This repository contains code for parsing GoPro telemetry metadata to obtain GoPro images with synchronized IMU measurements. The GoPro visual-inertial data can then be saved in rosbag or Euroc format. Thus, effectively paving the way for visual-inertial odometry/SLAM for GoPro cameras.

This repository use gpmf-parser from GoPro to extract metadata and timing information from GoPro cameras.

Installation

Tested on Ubuntu 18.04 (ros-melodic) & 20.04 (ros-noetic). The install instructions are for Ubuntu 18.04.

Prerequisites

Install Dependencies

  • Install ROS using this guide

  • System installation of OpenCV should work

sudo apt install libopencv-dev
  • Install FFmpeg
sudo apt install ffmpeg
  • Install Eigen3
sudo apt install libeigen3-dev

Install gopro_ros

Before proceeding, ensure all dependencies are installed. To install gopro_ros

mkdir -p ~/gopro_ws/src
cd gopro_ws/src
git clone https://github.com/joshi-bharat/gopro_ros.git
cd ~/gopro_ws/
catkin_make
source ~/gopro_ws/devel/setup.bash
# add this to ~/.bashrc to make this permanent 

Usage

GoPro splits video into smaller chunks. By splitting up the video it reduces the chance of you losing all your footage if the file gets corrupted somehow. It’s called chaptering, and the idea is that if one chapter gets corrupted the others should still be okay because they’re separate files.

Save to rosbag

To save GoPro video with IMU measurements to rosbag:

roslaunch gopro_ros gopro_to_rosbag.launch gopro_video:=<gopro_video_file> rosbag:=<bag_file>

If you have multiple files from a single session, put all videos in same folder you can use the following command to concatenate into a single rosbag:

roslaunch gopro_ros gopro_to_rosbag.launch gopro_folder:=<folder_with_gopro_video_files> multiple_files:=true rosbag:=<bag_file>

Save in Euroc format

To save GoPro video with IMU measurements in Euroc format:

roslaunch gopro_ros gopro_to_rosbag.launch gopro_video:=<gopro_video_file> asl_dir:=<asl_format_dir>

If you have multiple files from a single session, put all videos in same folder you can use the following command extract all videos in a single folder:

roslaunch gopro_ros gopro_to_rosbag.launch gopro_folder:=<folder_with_gopro_video_files> multiple_files:=true asl_dir:=<asl_format_dir>

TODO:

Extraction video takes a lot of time. Implement multi-threaded.

Calibration

Notes on camera-imu calibration for GoPro9 can be found at GoPro9 Camera-IMU calibration.

gopro_ros's People

Contributors

joshi-bharat 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.