Code Monkey home page Code Monkey logo

canny_edge_detection_opencl's Introduction

Canny_edge_detection_opencl

This is the CPU and GPU(based on Opencl) implementation of canny edge detection for High Performance Computing with Graphic Cards praktikum.

Steps in Canny_edge_detection

Canny edge detection consists of 5 steps.

  1. Gaussian Filter
  2. Sobel Filter
  3. Non-Max Suppression
  4. Double Threshold
  5. Hysteresis edge tracking

image

Here is how you can use this code to determine edges in the images and the intermediate results.

Instructions to run this code in Visual Studio

Environment Configuration:

  1. Download NVIDIA CUDA Toolkit from https://developer.nvidia.com/cuda-downloads
  2. Download Boost library from https://sourceforge.net/projects/boost/files/boost-binaries/1.76.0_b1/boost_1_76_0_b1-msvc-14.2-64.exe

Project Configuration:

  1. Download the Canny_edge_detection_opencl project from the github.
  2. In the CMakeLists.txt change the boost include directory and boost library directory to system include folder.
    • set(BOOST_INC "C:/local/boost_1_76_0_b1_rc2")
    • set(BOOST_LIB "C:/local/boost_1_76_0_b1_rc2/lib64-msvc-14.2")

Building the project

  1. Open Visual Studio-> Choose "Open a local folder" -> and select "Canny_edge_detection_opencl" folder.
  2. CMake generation will automatically start.
  3. Build the project (Ctrl + Shift + B)
  4. In the solution explorer Choose "Switch between solutions and the available views" Choose "CMake Targets View" Expand "CannyEdgeDetection Project" Configure the "CannyEdgeDetection (executable)" as a startup item.

Execution

  1. Execution is started by clicking "CannyEdgeDetection.exe" play button.
  2. For each of these steps, a CPU and GPU output image will be generated and saved in out/build/x64-Debug.

Executing different example

  1. Different sample examples are placed in the images directory (src/InputImages).
  2. To run different example set we have to change the image name in the CannyEdgeDetection.cpp source file.
  3. Rebuid the project and execute.

canny_edge_detection_opencl's People

Contributors

mehrozkhan avatar swathi6698 avatar gopikar8 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.