Blog

Implementing Harris Detectors and MOPS Descriptors

Features on the image of a crowd (Woodstock '68).

For my computer vision class, we were to implement Harris detectors and MOPS descriptors. Like before, much of the basic skeleton gui and basic functionality has been setup.

Compute Harris Values
We implemented this function formulating most the calculations as a convolution.
First we generate the x-, and y-derivatives with Sobel’s filters.
Then we calculate the coefficients of the H matrix convolving the images of dx*dx, dx*dy and dy*dy with a Gaussian with the size of the window , obtaining respectively A, B and C elements, as H=Sum wk hk = G convolved hk if w is the gaussian window
Finally we generate the approximates minimal eigenvalues as defined by the formulas det / trace.

Select Maximum Values.
We first select the points above threshold, then we scan the image one by one and we keep the pixel if it is largest value in its 3×3 neighborhood.

Simple Descriptors
Straightforward implementation of the specs by taking a 5×5 square patch

MOPS descriptor
In this case, we need to define a direction of the feature: we select it as the angle of the gradient at the location of the pixel. Subpatches are rotated and resampled using the given ImageLib functions.

Ratio Match

Ratio match works by making the score equal to the SSD from the best feature divided by the SSD of the second best feature. This required that every iteration of featureset 1 to keep track of the best and second best of featureset 2. In the end, the scores are added up as in SSD score.

Harris filter for the test image yosemite

Harris filter for the test image Graffiti1

 

 

 

 

 

 

 

 

 

 

 

.

.

Here are the AUC benchmarks, as you can see MOPS+Ratio had the best results.

leuven wall bikes
Simple+SSD 0.29 0.3 0.35
Simple+Ratio 0.5 0.53 0.43
MOPS+SSD 0.73 0.66 0.52
MOPS+Ratio 0.74 0.68 0.56

ROC curves for graf data set

 

 

 

 

 

 

 

 

 

 


ROC curve for yosemite

 

 

 

 

 

 

 

 

 

 

 

 

.

.

Strengths and Weaknesses

Strengths are that this method is intensity, rotation and translation invariant. But, our descriptor is not scale invariant since we did not implement that aspect for this project.

Additional pictures

Features on an Italian landscape. Note as features are mostly found around the lake, due to the underexposure.

Features on the image of a crowd (Woodstock ’68).

Where’s Wally and features. There are more features (around 20’000) than the software can handle. We overlap the threshold-ed Harris filter.

Here is Wally

Be Sociable, Share!
    Google+

    This Post Has 0 Comments

    Leave A Reply

    Logged in as Le Zhang. Log out »


    Google