Programming Project #4
15-463: Computational Photography

Assignment

The assignment results were quite good. I followed the implementation of the paper, and was able to compute feature matched points fairly precisely. I chose one set of images from the last assignment, and the image warps into the mosiac program. It is important to note that because the same blending algorithm was used as the last assignment, similar blending artifacts are present in the final mosaic. However, the feature matching and point selection resulted in much better warps

The program consists of five main files and one helper file

  • createWarp(im1, im2) - this is the "main" program. This consists of each step to do the feature matching and point extraction. It also contains code to display the point selection results.
  • select(x, y, v, n) - this takes in the inputs from the harris algorithm provided, along with the number of feature points to select. This then implements adaptive non-maximal suppression to return the best n points.
  • descriptors(imrgb, x, y) - this takes in the image, and the set of x/y points from the previous function and returns a set of all feature descriptors. It uses a gaussian pyramid to blur the image, extract 40x40 squares, normalize the intensity, and returns a final 8x8 image.
  • match(M1, M2, x, y, x2, y2) - this attempts to match the feature descriptors gathered from each image. It takes in both feature descriptor sets, along with each point set, and returns a set of matched points, using the 1-NN/2-NN threshold algorithm.
  • matchRansac(im1_pts, im2_pts) - this uses RANSAC to further narrow down the point selections to choose more robust and precise matches.
  • flatten(M) - this merely takes in a set of feature descriptors, which is 8x8xN, and creates a flatted image that allows all of them to be displayed on screen. This is used for display purposes.
To execute the programs, run createWarp with each image pair. For each set of images, I chose a "middle" image and warped each image to that one, just as in the last assignment. This will create a warped image that can be fed into the mosaic program.

Point Results

The following is an example of the point results. This was done for each pair of images of the chosen mosaic set. The red points are part of the initial n=500 selected points, the blue points are points that fell into the 1-NN/2-NN threshold, and the yellow points are the final set of RANSAC points.

Feature Descriptor Results

The following is an example of the feature descriptor sets. Only the first set is shown here, but it is trivial to compute it for each pair of images.

Mosaic Results

The following is the final warped mosaic. This can be compared to the mosaic results from last assignment. Note again, that the same blending artifacts appear in both, but the feature matching resulted in better warps.

Note: all images can be found here: Images
All intermediate warps and the final mosaic can be found here: Warp