Computer Vision for Busy Developers

Finding Edges

Vinny DaSilva
8 min readJun 25, 2019

This article is part of a series introducing developers to Computer Vision. Check out other articles in this series.

Finding Edges with the Sobel Operator

In human vision, one of the first steps in comprehending what we see is to learn and understand the outline of things we see.

We can tell a lot about what is happening in an image by focusing on the edges. (Image Source: Everton Vila)

Edge Detection is an important concept in computer vision where we attempt to extract the outline of objects. We can extract edges from an image when working with kernels and small chunks of pixels. In computer vision, Edges are defined as a region with high-contrast between adjacent pixels — a lighter pixel next to a darker pixel. The larger the difference between adjacent pixels, the higher the contrast and the more defined the edge.

Edges are identified by the difference of intensity of neighboring pixels

In the following examples, we are going to be using the grayscale version of following image to explore edges.

Image Source Simon Migaj

--

--

Vinny DaSilva

Developer Relations Engineer at Google. Passionate about AR & VR. Previously at Lenovo ThinkReality, Samsung NEXT, Vuforia