This repo contains a stereo VO implementation from scratch using OpenCV implementations of Harris, SIFT, and BRISK.
A report of the results from the experimentation using the 3 feature detectors can be viewed in 'Feature-Based Visual Odometry Investigation.pdf'.
- Python>=3.6
- Install additional packages
pip install -r requirements.txt
- If desired to run the code in a docker environment, install docker. Instructions for Linux (Ubuntu): https://docs.docker.com/engine/install/ubuntu/
This repo uses the Canadian Planetary Emulation Terrain Energy-Aware Rover Navigation Dataset available at https://starslab.ca/enav-planetary-dataset/.
- Set up input and output folders
mkdir input mkdir output
- Download the rover frame transforms file, camera intrinsics file, and human-readable base data folder for Run #1 (note: this folder is 16.8 GB)
cd ./input wget ftp://128.100.201.179/2019-enav-planetary/rover_transforms.txt wget ftp://128.100.201.179/2019-enav-planetary/cameras_intrinsics.txt wget ftp://128.100.201.179/2019-enav-planetary/run_1/new_data/run1_base_hr.tar.gz
- Extract data folder
tar -xzf run1_base_hr.tar.gz
The default settings run the visual odometry on the first ~80 seconds of Run #1. All outputs will be automatically saved to the output folder.
- To run inside a docker container, run the following command in the main directory of the repo:
docker-compose up
- Instead, to run manually, run the following command in the main directory of the repo:
python3 ./src/rob501_project.py --input_dir=./input --output_dir=./output