Skip to content

C++/CUDA solutions, slides, and resources for Udacity's Intro to Computer Vision (UD810) course.

License

Notifications You must be signed in to change notification settings

Firststep2014/IntroToComputerVision

 
 

Repository files navigation

Intro to Computer Vision (Udacity UD810)

Lecture slides, problem sets, and C++ solutions to UD810.

Prerequisites

I try to accelerate all of the assignments with CUDA, so you will need an Nvidia GPU along with CUDA toolkit installed. This repository is developed on:

  • Ubuntu 17.10 + CUDA 9.1; Intel Core i7 6800k + GeForce GTX 1080

You will need:

From here, there are two options: building in Docker or just building locally on a host machine.

Containerized Build in Docker (Recommended!)

This is the suggested approach to building this project since all of the dependencies are included in the Docker image.

  • Install Docker-CE as described for your distribution on the Docker docs.
  • Install nvidia-docker2 as described in the nvidia-docker docs. The container provided in this repo needs the nvidia Docker runtime to run.
  • Clone this repo and build/run the Docker container:
git clone --recursive https://github.com/tanmaniac/IntroToComputerVision.git
cd IntroToComputerVision/Docker
# Build the Docker container
./build.sh
# Run the container
./run.sh

This will drop you into a shell where you can follow the build steps below. The IntroToComputerVision directory (this one) is mapped to ${HOME}/IntroToComputerVision in the Docker container.

Build on host

  • Build OpenCV 3.4.1 as directed in the OpenCV documentation. Make sure to add the -DWITH_CUDA=ON CMake flag to compile CUDA features.
  • Install Eigen as described in its documentation.
  • gnuplot, which you can install from your distro repository. On Ubuntu:
sudo apt install gnuplot

Building

# Navigate to wherever you cloned this repo first
mkdir build && cd build
cmake ..
make -j

If you want to use NVIDIA debugging tools, like cuda-memcheck or the NVIDIA Visual Profiler, compile with Debug flags:

mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Debug ..
make -j

Note that this increases runtime of some kernels by around 100x, so only compile in debug mode if you need it.

Running

Build outputs are placed in the bin directory. All of the executables are configured with YAML files in the config directory. You can edit these to change the input parameters to each of the assignments. For example, with Problem Set 0, all you need to do (after building) is:

cd bin
./ps0

About

C++/CUDA solutions, slides, and resources for Udacity's Intro to Computer Vision (UD810) course.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 80.6%
  • Cuda 17.6%
  • CMake 1.6%
  • Shell 0.2%