Classical boundary detection algorithms (including Canny and Sobel) date back to the '80s and use discontinuities in intensity to identify edges. The more recent and sophisticated pb boundary detection algorithm outperforms the classical methods by considering texture and color gradients in addition to intensity, as described in the work of Arbelaez, Maire, Fowlkes, and Malik. TPAMI 2011 (pdf). In this project we develop a simplified version of pb using Canny and Sobel as a baseline.
In the first steps of the algorithm we predefine:
- a filter bank of multiple scales and orientations.
- half-disc masks of multiple scales and orientations. The filter bank is created by convolving a Sobel filter and a Gaussian kernel and rotating the result by a given orientation. We perform these steps for a range of orientations(o) and scales(s), giving us a filter bank of size o x s. This filter bank is later used to measure texture properties and aggregate regional texture and brightness distributions. The half-disc masks are created by computing pairs of binary images of half-discs. We will use these half-discs to compute the chi-square distances using a filtering operation.
In the next part of the algorithm we take every image and:
- create a texton map by filtering and clustering the responses using kmeans.
- compute per pixel texture gradient and brightness gradient by comparing local half-disc distributions.
- output a per-pixel boundary score based on the magnitude of these gradients combined with a baseline edge detector (Canny or Sobel).
From left to right: (1) input image (2) boundary strength from baseline method based on Canny edge detection (3) our pb-lite result (notice that texture edges are less likely to be mistaken for boundaries in (3) vs. (2))
Evaluating boundary detection
We use a precision-recall curve to evaluate the success of our algorithm based on a dataset that consists of 200 test images:
(dotted lines are copied from figure 17 in Arbelaez et al. 2011 (pdf), solid lines come from actual implementations in MATLAB)