My Submission: Southside Mosaic!

I used my southside photos 2 and 3 for my mosaics.

Part 1: Detecting Corner Features

I used Prof. Efros' starter code on harris corner detection to find harris corners in each image.


Nice! I then implemented Adaptive Non-Maximal Suppression to find the strongest corner points, keeping the best 250 points from each image.


A quick optimization: I removed all points except the right side of the first image and the left side of the second one. This makes later computations much faster, and we shouldn't affect computational accuracy since we are effectively removing corner points that don't have correspondences in the other image.


Part 2: Feature Descriptors

Here are the features extracted from each corner point.

Image 1:

Image 2:

Part 3: Matching the Features

I computed pairings between features using Lowe's method, whereby for each feature Xi in the first image, we compute the SSD between Xi and each Xj in the second image.

I then compute the best feature pairing (Xi, Xj), the second best feature pairing (Xi, Xk) and the score SSD(Xi, Xj)/SSD(Xi, Xk).

If that score is below a threshold (in my computations, I used 0.7), the pairing (Xi, Xj) is added to the list of pairings.

My computations outputted 12 feature pairs:

        
        
        
        
        
        

Out of all the points in the image, it appears that only pairing 0 is wrong. pretty good, I think :D

Part 4: RANSAC

I implemented 4-point RANSAC. At each step of the iteration, the algorithm selects 4 pairs and uses them to compute a homography H between the images. RANSAC then evaluates the homography by evaluating each pairing and seeing how many inliers are generated using H (point pairs for which the homography's estimate of a point in im2 and the actual point in im2 are within a certain bound of error). The homography that generates the most inliers is returned.

My RANSAC algorithm ran for 5000 iterations, and the error threshold for inliers was 4 pixels. I also implemented a safeguard--the algorithm would re-run with an increased error thresholds if no suitable H was computed--but it did not end up being necessary.

Part 5: The Mosaic

Finally, the time has come to blend the images. I used the sigmoid blending function that I implemented in project 4A. If you play with the centering of the sigmoid function and its x-scaling, you can get pretty seamless-looking transitions.

while there is some messiness near the transition, the majority of the image looks amazing!!!

I really enjoyed the project. I think homographies and harris corners are very cool--definitely my favorite concepts from this project.