Skip to content
/ cs344 Public
forked from udacity/cs344

Introduction to Parallel Programming class code

Notifications You must be signed in to change notification settings

dontloo/cs344

 
 

Repository files navigation

cs344

Introduction to Parallel Programming class code and solutions

Building on OS X

These instructions are for OS X 10.9 "Mavericks".

  • Step 1. Build and install OpenCV. The best way to do this is with Homebrew. However, you must slightly alter the Homebrew OpenCV installation; you must build it with libstdc++ (instead of the default libc++) so that it will properly link against the nVidia CUDA dev kit. This entry in the Udacity discussion forums describes exactly how to build a compatible OpenCV.

  • Step 2. You can now create 10.9-compatible makefiles, which will allow you to build and run your homework on your own machine:

mkdir build
cd build
cmake ..
make

Building on Windows + Visual Studio

The code is tested on opencv 2 and cuda 11, for other versions it may require modification to the code.

Set up OpenCV paths in Visual Studio following this turtorial.

The source code might have linker errors, mostly becasue of .cpp file includes (see this SO question), troubleshooting can refer to Linker Tools Error LNK2005.

See this post to turn on dynamic parallelism compiliation for Visual Studio.

Results

problem set 1: color to grayscale

color grayscale

problem set 2: Gaussian blur

raw blur

problem set 3: histogram equalization

raw equalization

Looks weird but it's the expected results given buy the CPU version.

problem set 4: red eye removal

raw red eye removal

problem set 5: large scale histogram

no image output

problem set 6: image blending

source destination blend

About

Introduction to Parallel Programming class code

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Cuda 51.0%
  • C++ 37.7%
  • C 5.0%
  • Makefile 4.0%
  • CMake 2.3%