Edge Detection. Computer Vision P. Schrater Spring 2003

Similar documents
Edge Detection PSY 5018H: Math Models Hum Behavior, Prof. Paul Schrater, Spring 2005

Edge Detection. CS 650: Computer Vision

Laplacian Filters. Sobel Filters. Laplacian Filters. Laplacian Filters. Laplacian Filters. Laplacian Filters

Lecture 6: Edge Detection. CAP 5415: Computer Vision Fall 2008

Filtering and Edge Detection

Edge Detection. Introduction to Computer Vision. Useful Mathematics Funcs. The bad news

Additional Pointers. Introduction to Computer Vision. Convolution. Area operations: Linear filtering

CS4495/6495 Introduction to Computer Vision. 2A-L6 Edge detection: 2D operators

Vlad Estivill-Castro (2016) Robots for People --- A project for intelligent integrated systems

Introduction to Computer Vision

Machine vision, spring 2018 Summary 4

Advanced Features. Advanced Features: Topics. Jana Kosecka. Slides from: S. Thurn, D. Lowe, Forsyth and Ponce. Advanced features and feature matching

I Chen Lin, Assistant Professor Dept. of CS, National Chiao Tung University. Computer Vision: 4. Filtering

Reading. 3. Image processing. Pixel movement. Image processing Y R I G Q

TRACKING and DETECTION in COMPUTER VISION Filtering and edge detection

Edges and Scale. Image Features. Detecting edges. Origin of Edges. Solution: smooth first. Effects of noise

Machine vision. Summary # 4. The mask for Laplacian is given

Advanced Edge Detection 1

CSE 473/573 Computer Vision and Image Processing (CVIP)

Edge Detection. Image Processing - Computer Vision

Feature extraction: Corners and blobs

Roadmap. Introduction to image analysis (computer vision) Theory of edge detection. Applications

Templates, Image Pyramids, and Filter Banks

Harris Corner Detector

Image matching. by Diva Sian. by swashford

Spatial Enhancement Region operations: k'(x,y) = F( k(x-m, y-n), k(x,y), k(x+m,y+n) ]

Detectors part II Descriptors

Lucas-Kanade Optical Flow. Computer Vision Carnegie Mellon University (Kris Kitani)

Lecture 3: Linear Filters

Lecture 3: Linear Filters

Introduction to Computer Vision

Lecture 04 Image Filtering

Edge Detection in Computer Vision Systems

Announcements. Filtering. Image Filtering. Linear Filters. Example: Smoothing by Averaging. Homework 2 is due Apr 26, 11:59 PM Reading:

Lecture 8: Interest Point Detection. Saad J Bedros

ECE Digital Image Processing and Introduction to Computer Vision

Computer Vision Lecture 3

INTEREST POINTS AT DIFFERENT SCALES

Corner detection: the basic idea

LoG Blob Finding and Scale. Scale Selection. Blobs (and scale selection) Achieving scale covariance. Blob detection in 2D. Blob detection in 2D

Image Analysis. Feature extraction: corners and blobs

Lecture 7: Edge Detection

CS4495/6495 Introduction to Computer Vision. 6B-L1 Dense flow: Brightness constraint

ITK Filters. Thresholding Edge Detection Gradients Second Order Derivatives Neighborhood Filters Smoothing Filters Distance Map Image Transforms

Achieving scale covariance

K-Means, Expectation Maximization and Segmentation. D.A. Forsyth, CS543

CHAPTER 4 PRINCIPAL COMPONENT ANALYSIS-BASED FUSION

Image Gradients and Gradient Filtering Computer Vision

Colorado School of Mines Image and Multidimensional Signal Processing

Properties of detectors Edge detectors Harris DoG Properties of descriptors SIFT HOG Shape context

CSCI 250: Intro to Robotics. Spring Term 2017 Prof. Levy. Computer Vision: A Brief Survey

Notes on Regularization and Robust Estimation Psych 267/CS 348D/EE 365 Prof. David J. Heeger September 15, 1998

Blobs & Scale Invariance

CS5540: Computational Techniques for Analyzing Clinical Data. Prof. Ramin Zabih (CS) Prof. Ashish Raj (Radiology)

NONLINEAR DIFFUSION PDES

Nonlinear Diffusion. Journal Club Presentation. Xiaowei Zhou

Computer Vision I. Announcements

CS 3710: Visual Recognition Describing Images with Features. Adriana Kovashka Department of Computer Science January 8, 2015

FILTERING IN THE FREQUENCY DOMAIN

Outline. Convolution. Filtering

CS4670: Computer Vision Kavita Bala. Lecture 7: Harris Corner Detec=on

SIFT: Scale Invariant Feature Transform

Lecture 8: Interest Point Detection. Saad J Bedros

Corners, Blobs & Descriptors. With slides from S. Lazebnik & S. Seitz, D. Lowe, A. Efros

Erkut Erdem. Hacettepe University February 24 th, Linear Diffusion 1. 2 Appendix - The Calculus of Variations 5.

Image Alignment and Mosaicing

Feature detectors and descriptors. Fei-Fei Li

Scale Space Smoothing, Image Feature Extraction and Bessel Filters

The Kernel Trick, Gram Matrices, and Feature Extraction. CS6787 Lecture 4 Fall 2017

Vectors [and more on masks] Vector space theory applies directly to several image processing/ representation problems

Lecture 7: Statistics and the Central Limit Theorem. Philip Moriarty,

Feature detectors and descriptors. Fei-Fei Li

Recap: edge detection. Source: D. Lowe, L. Fei-Fei

20 Unsupervised Learning and Principal Components Analysis (PCA)

Image as a signal. Luc Brun. January 25, 2018

ENGI Gradient, Divergence, Curl Page 5.01

SURF Features. Jacky Baltes Dept. of Computer Science University of Manitoba WWW:

Image Segmentation: Definition Importance. Digital Image Processing, 2nd ed. Chapter 10 Image Segmentation.

Image Filtering. Slides, adapted from. Steve Seitz and Rick Szeliski, U.Washington

Astronomical image reduction using the Tractor

NON-LINEAR DIFFUSION FILTERING

CITS 4402 Computer Vision

Extract useful building blocks: blobs. the same image like for the corners

CEE598 - Visual Sensing for Civil Infrastructure Eng. & Mgmt.

CS5670: Computer Vision

Overview. Harris interest points. Comparing interest points (SSD, ZNCC, SIFT) Scale & affine invariant interest points

Convolutional networks. Sebastian Seung

6.869 Advances in Computer Vision. Bill Freeman, Antonio Torralba and Phillip Isola MIT Oct. 3, 2018

Chapter 3 Salient Feature Inference

Today s lecture. Local neighbourhood processing. The convolution. Removing uncorrelated noise from an image The Fourier transform

Integration - Past Edexcel Exam Questions

Aperture Photometry in Band Limited. Data. Robert Lupton. March 4, Band limited data, that is, data that has non-zero Fourier components in

Review Smoothing Spatial Filters Sharpening Spatial Filters. Spatial Filtering. Dr. Praveen Sankaran. Department of ECE NIT Calicut.

Introduction to Computer Vision. 2D Linear Systems

Robert Collins CSE598G Mean-Shift Blob Tracking through Scale Space

Lecture 3 Math & Probability Background

Low-level Image Processing

Numerical differentiation

Differentiation Practice Questions

Transcription:

Edge Detection Computer Vision P. Schrater Spring 2003

Simplest Model: (Canny) Edge(x) = a U(x) + n(x) U(x)? x=0 Convolve image with U and find points with high magnitude. Choose value by comparing with a threshold determined by the noise model.

Probability of a filter response off an edge Probability of a filter response on an edge

Fundamental limits on edge detection

Need to take into account base edge rate.

Smoothing and Differentiation Issue: noise smooth before differentiation two convolutions to smooth, then differentiate? actually, no - we can use a derivative of Gaussian filter because differentiation is convolution, and convolution is associative

There are three major issues: 1) The gradient magnitude at different scales is different; which should we choose? 2) The gradient magnitude is large along thick trail; how do we identify the significant points? 3) How do we link the relevant points up into curves?

1 pixel 3 pixels 7 pixels The scale of the smoothing filter affects derivative estimates, and also the semantics of the edges recovered.

Computing Edges via the gradient

We wish to mark points along the curve where the magnitude is biggest. We can do this by looking for a maximum along a slice normal to the curve (non-maximum suppression). These points should form a curve. There are then two algorithmic issues: at which point is the maximum, and where is the next one?

Non-maximum suppression At q, we have a maximum if the value is larger than those at both p and at r. Interpolate to get these values.

Predicting the next edge point Assume the marked point is an edge point. Then we construct the tangent to the edge curve (which is normal to the gradient at that point) and use this to predict the next points (here either r or s).

Remaining issues Check that maximum value of gradient value is sufficiently large drop-outs? use hysteresis use a high threshold to start edge curves and a low threshold to continue them.

Edge Detection Algorithm Define Edge filter: Next Compute Gradient G = D x = I x = Dx ƒ I I y = Dy ƒ I È I(i, j) = I x (i, j) Í Î I y (i, j) G uv = exp(- 1 È (x u - N /2) 2 2 pixelwidth + (y v - M /2) 2 Í Î 2 pixelwidth 2 ) D ij = [-1 0 1] Dx = G ƒ D Dy = G ƒ D T Gradient Magnitude I(i, j) = I x (i, j) 2 + I y (i, j) 2 Ê I(i, j) = tan I -1 y (i, j) ˆ Á Ë I x (i, j) Gradient Direction

Edge Detection Algorithm Find an initial point (i,j) such that: I(i, j) > c Where c is relatively large Find nearby points in the direction of (i,j) s gradient r È n (i, j) = I x (i, j)/ I(i, j) Í Î I y (i, j)/ I(i, j) È Find nearby points u r Í such that n(u,v) T n (i, j) < e Î v È Choose u Í with maximal gradient magnitude Î v

Edge Detection Algorithm While set of (i,j) with I(i, j) not > c visited Find a start point, erasing points that have been checked. While possible, expand a chain through the current point by: 1) predicting a next set of points (not visited) using the direction perp. to gradient 2) Finding which of set (if any) is a local maximum 3) Test if grad mag for local max > k 4) Recording all the set as visited record point and set to current point. end end

Notice Something nasty is happening at corners Scale affects contrast Edges aren t bounding contours

fine scale high threshold

coarse scale, high threshold

coarse scale low threshold

Positive responses Zero mean image, -1:1 scale Zero mean image, -max:max scale

Positive responses Zero mean image, -1:1 scale Zero mean image, -max:max scale

Figure from Computer Vision for Interactive Computer Graphics, W.Freeman et al, IEEE Computer Graphics and Applications, 1998 copyright 1998, IEEE

The Laplacian of Gaussian Another way to detect an extremal first derivative is to look for a zero second derivative In 2D: Bad idea to apply a Laplacian without smoothing smooth with Gaussian, apply Laplacian this is the same as filtering with a Laplacian of Gaussian filter Now mark the zero points where there is a sufficiently large derivative, and enough contrast 2 I(x, y) = 2 I(x, y) + 2 I(x, y) x 2 y 2

sigma=4 contrast=1 LOG zero crossings contrast=4 sigma=2

We still have unfortunate behaviour at corners

Orientation representations The gradient magnitude is affected by illumination changes but it s direction isn t We can describe image patches by the swing of the gradient orientation Important types: constant window small gradient mags edge window few large gradient mags in one direction flow window many large gradient mags in one direction corner window large gradient mags that swing

Representing Windows Types constant Edge small eigenvalues one medium, one small Flow one large, one small corner two large eigenvalues H = Â I window ( )( I ) T

Filters are templates Applying a filter at some point can be seen as taking a dotproduct between the image and some vector Filtering the image is a set of dot products Insight filters look like the effects they are intended to find filters find effects they look like

Normalized correlation Think of filters of a dot product now measure the angle i.e normalised correlation output is filter output, divided by root sum of squares of values over which filter lies Tricks: ensure that filter has a zero response to a constant region (helps reduce response to irrelevant background) subtract image average when computing the normalizing constant (i.e. subtract the image mean in the neighbourhood) absolute value deals with contrast reversal