Welcome to My CS180 Portfolio!

Project 1: Image Alignment

Two algorithms are implemented for this project, the naive one and the multi-pyramid one. For the naive one, exhaustive search is used in a square area of edge length 30. L2 distance was used first but altered to Normalized Cross-Correlation so that the difference of overall lightness will not affect the matching.

Here are some small images processed using this algorithm (as it would take forever to search in a huge area for large pictures):

The multi-pyramid algorithm handles large images. It first resizes each image several times—each time reducing the height and width by half—until the image is small enough (e.g., width < 64 pixels). Next, the naive algorithm is applied to the smallest image to get the best shifting vector v. Then, the algorithm searches bigger images based on the previous shifting vector scaled by 2 (2 • v), but within a small search area (-2 to 2). This process continues until we get the best shifting vector for the original image.

Here are some large images processed with this algorithm: