Canny Edge Detection Using an NVIDIA GPU and CUDA Alex Wade CAP6938 Final Project.

Slides:



Advertisements
Similar presentations
3-D Computer Vision CSc83020 / Ioannis Stamos  Revisit filtering (Gaussian and Median)  Introduction to edge detection 3-D Computater Vision CSc
Advertisements

Boundary Detection - Edges Boundaries of objects –Usually different materials/orientations, intensity changes.
Spatial Filtering (Chapter 3)
Edges and Contours– Chapter 7
EDGE DETECTION ARCHANA IYER AADHAR AUTHENTICATION.
Instructor: Mircea Nicolescu Lecture 6 CS 485 / 685 Computer Vision.
1Ellen L. Walker Edges Humans easily understand “line drawings” as pictures.
Edge Detection CSE P 576 Larry Zitnick
Edge Detection. Our goal is to extract a “line drawing” representation from an image Useful for recognition: edges contain shape information –invariance.
EE663 Image Processing Edge Detection 1
Edge detection Goal: Identify sudden changes (discontinuities) in an image Intuitively, most semantic and shape information from the image can be encoded.
Lecture 4 Edge Detection
Filtering and Edge Detection
Computer Vision Group Edge Detection Giacomo Boracchi 5/12/2007
Canny Edge Detector.
1 Image filtering Hybrid Images, Oliva et al.,
Edge detection. Edge Detection in Images Finding the contour of objects in a scene.
Announcements Mailing list: –you should have received messages Project 1 out today (due in two weeks)
Filtering and Edge Detection. Local Neighborhoods Hard to tell anything from a single pixelHard to tell anything from a single pixel – Example: you see.
Canny Edge Detector1 1)Smooth image with a Gaussian optimizes the trade-off between noise filtering and edge localization 2)Compute the Gradient magnitude.
Edge Detection Today’s reading Forsyth, chapters 8, 15.1
1 Image Filtering Readings: Ch 5: 5.4, 5.5, 5.6,5.7.3, 5.8 (This lecture does not follow the book.) Images by Pawan SinhaPawan Sinha formal terminology.
1 Image filtering Images by Pawan SinhaPawan Sinha.
1 Image filtering
Filters and Edges. Zebra convolved with Leopard.
EE663 Image Processing Edge Detection 3 Dr. Samir H. Abdul-Jauwad Electrical Engineering Department King Fahd University of Petroleum & Minerals.
Announcements Since Thursday we’ve been discussing chapters 7 and 8. “matlab can be used off campus by logging into your wam account and bringing up an.
Edge Detection Today’s readings Cipolla and Gee –supplemental: Forsyth, chapter 9Forsyth Watt, From Sandlot ScienceSandlot Science.
3-D Computational Vision CSc Canny Edge Detection.
Image Filtering. Problem! Noise is a problem, even in images! Gaussian NoiseSalt and Pepper Noise.
CAP 5415 Computer Vision Fall 2004
Edge Detection (with implementation on a GPU) And Text Recognition (if time permits) Jared Barnes Chris Jackson.
Discrete Images (Chapter 7) Fourier Transform on discrete and bounded domains. Given an image: 1.Zero boundary condition 2.Periodic boundary condition.
Image Processing Edge detection Filtering: Noise suppresion.
Edges. Edge detection schemes can be grouped in three classes: –Gradient operators: Robert, Sobel, Prewitt, and Laplacian (3x3 and 5x5 masks) –Surface.
Edge Detection Today’s reading Cipolla & Gee on edge detection (available online)Cipolla & Gee on edge detection From Sandlot ScienceSandlot Science.
Lecture 6: Edge Detection CAP 5415: Computer Vision Fall 2008.
G52IVG, School of Computer Science, University of Nottingham 1 Edge Detection and Image Segmentation.
CSC508 What You Should Be Doing Code, code, code –Programming Gaussian Convolution Sobel Edge Operator.
Edge detection Goal: Identify sudden changes (discontinuities) in an image Intuitively, most semantic and shape information from the image can be encoded.
Many slides from Steve Seitz and Larry Zitnick
CSC508 Convolution Operators. CSC508 Convolution Arguably the most fundamental operation of computer vision It’s a neighborhood operator –Similar to the.
October 7, 2014Computer Vision Lecture 9: Edge Detection II 1 Laplacian Filters Idea: Smooth the image, Smooth the image, compute the second derivative.
Edge Based Segmentation Xinyu Chang. Outline Introduction Canny Edge detector Edge Relaxation Border Tracing.
Chapter 9: Image Segmentation
CSE 6367 Computer Vision Image Operations and Filtering “You cannot teach a man anything, you can only help him find it within himself.” ― Galileo GalileiGalileo.
Digital Image Processing Lecture 17: Segmentation: Canny Edge Detector & Hough Transform Prof. Charlene Tsai.
Canny Edge Detection. 5 STEPS 5 STEPS Apply Gaussian filter to smooth the image in order to remove the noise Apply Gaussian filter to smooth the image.
Machine Vision Edge Detection Techniques ENT 273 Lecture 6 Hema C.R.
Edge Segmentation in Computer Images CSE350/ Sep 03.
Lecture 8: Edges and Feature Detection
September 26, 2013Computer Vision Lecture 8: Edge Detection II 1Gradient In the one-dimensional case, a step edge corresponds to a local peak in the first.
Spatial Filtering (Chapter 3) CS474/674 - Prof. Bebis.
April 21, 2016Introduction to Artificial Intelligence Lecture 22: Computer Vision II 1 Canny Edge Detector The Canny edge detector is a good approximation.
Sobel edge detector: Review
Sobel edge detector: Review
Fourier Transform: Real-World Images
Edge Detection The purpose of Edge Detection is to find jumps in the brightness function (of an image) and mark them.
Computer Vision Lecture 9: Edge Detection II
Edge detection Goal: Identify sudden changes (discontinuities) in an image Intuitively, most semantic and shape information from the image can be encoded.
Levi Smith REU Week 1.
Dr. Chang Shu COMP 4900C Winter 2008
Canny Edge Detector.
Greg Yoblin & Joseph Marino
CS 565 Computer Vision Nazar Khan Lecture 9.
Canny Edge Detector Smooth image with a Gaussian
Image Filtering with GLSL
IT472 Digital Image Processing
IT472 Digital Image Processing
CAP 5415 Computer Vision Fall 2004
Presentation transcript:

Canny Edge Detection Using an NVIDIA GPU and CUDA Alex Wade CAP6938 Final Project

Introduction GPU based implementation of A Computational Approach to Edge Detection by John Canny Paper presents an accurate, localized edge detection method

Purpose Canny’s edge detection algorithm involves a large number of matrix and floating point operations Edge detection used as the first step for many computer vision tasks Speeding up edge detection will increase computer vision performance, beneficial in cases such as live video feed processing

Algorithm Steps Image smoothing Gradient computation Edge direction computation Nonmaxmimum suppression Hysteresis

Image Smoothing Reduces image noise that can lead to erroneous output Performed by convolution of the input image with a Gaussian filter ― 159 σ=1.4

Image Smoothing

Gradient Computation Determines intensity changes High intensity changes indicate edges Performed by convolution of smoothed image with masks to determine horizontal and vertical derivatives xx yy

Gradient Computation Gradient magnitude determined by adding X and Y gradient images  =  x  +  y 

Edge Direction Computation Edge directions are determined from running a computation on the X and Y gradient images Edge directions are then classified by their nearest 45 ° angle  x Θ x,y = tan -1   y

Edge Direction Computation 0 °90 ° 45 °135 °

Nonmaximum Suppression Used to localize edges Uses edge direction classifications and gradient intensity values For each pixel, determine whether its intensity value is higher than both of its perpendicular neighbors All pixels that are not local maxima have their intensity values set to 0

Nonmaximum Suppression

Hysteresis Determines final edge pixels using a high and low threshold Image is scanned for pixels with a gradient intensity higher than the high threshold Pixels above the high threshold are added to the edge output All of the neighbors of a newly added pixel are recursively scanned and added if they fall below the low threshold

Hysteresis

Implementation Status Currently Implemented on GPU ◦ Image Smoothing ◦ Gradient Computation To be Implemented (currently use CPU) ◦ Edge Direction Computation ◦ Nonmaximum Suppression May be Implemented (currently use CPU) ◦ Hysteresis Will not be Implemented (done by CPU) ◦ File I/O

GPU Implementation Details Convolution kernels are sent to device global memory only once at initialization Input and intermediate matrices are currently sent round trip from host to device texture memory for each step ◦ Three round trips Kernel functions use fixed 256x256 block size

Improvements to be Made Implement edge direction computation and nonmaximal suppression Improve GPU performance ◦ Eliminate unnecessary round trips ◦ Evaluate GPU memory use and correct as needed ◦ Combine steps to reduce computation ◦ Experiment further with block size Try to implement hysteresis General code optimization

Performance Evaluation Host ◦ Intel Core 2 Quad ◦ 2.66 GHz ◦ 3.25 MB RAM Device ◦ NVidia GeForce 8800 GT ◦ 512 MB Video Memory

Performance Evaluation Verified correctness of CPU only and GPU based implementations Collected performance metrics on 256x256, 412x512, 1024x1024, and 2048x2048 input images ◦ Image smoothing time ◦ Gradient computation time (including transfer to GPU and back) ◦ Overall time excluding file I/O operations

Performance Results