Project 1: Feature Detection and Matching

by Patrick McVittie

 

Feature Detection

            The features in the image were detected using a Harris Corner Detector.

 

            (1) Create a Pyramid of depth 5 from the original image

            (2) For each level:

                        a. Calculate the Harris Matrix for each band

                        b. Calculate a corner response image for each band

                        c. Convert the corner response to single band : root(r^2 + g^2 + b^2)

                        d. Threshold the image at two standard deviations above its mean

                        e. Find local maxima of radius 4

                        f.. Create a list of points that passed and sort them by corner response                                       value

                        g. Take the top 100 points and make them features

 

Feature Descriptors

 

Descriptor 1 : Square window

            The first descriptor takes a 7x7x1 window from the corner response image and stores what level of the pyramid the window was taken from.

            (1) Take a 7x7 window around the point from the corner response image.

            (2) Store the pyramid level

 

 

Descriptor 2 : Rotated Circular Window

            The second feature descriptor records a circular window of diameter 7 of the local corner response. This window is rotated to have the sum of the gradients lie in the x direction. Finally the window is normalized to have zero mean and a unit standard deviation.

 

            (1) Take a 7x7 window around the point from the corner response image.

            (2) Normalize this sub window to mean = 0, std = 1.

            (3) Find the dominate direction by summing the gradients over the window

            (4) Rotate the dominate direction to zero degrees

            (5) Store a circular version of the window: D = 7

            (6) Store the pyramid level

 

Testing

            Due to extensive difficulties in debugging and trouble shooting sufficient testing was not done.  On a superficial level the corner detection looks like it is accurately detecting corners. On a black and white test box image the detector successfully found one feature point at each corner of the box. Also the bench mark test returned a average error of 280 pixels on the graf/ data set.

 

Test image: pat.ppm