The purpose of this assignment is to take three greyscale images of the same object and produce a color image. Each image given represents the scene with respect to the red, green, and blue color channels. My goal was to align these images on top of eachother to show what the image should look like in true color.

There are two approaches to aligning three images together to create an RGB image. One is a single-exhastive search through across the image to find a possible match. This was implemented by using a window with a size specified by the user. The algorithm tries translating one of the images and checks its accuracy relative to the basis image using the Sum of Squared Differences (SSD). The chosen displacement is picked based on the smallest result of the SSD.

The second approach involves using an image pyramid to find the correct alignment of the images. The image pyramid shrinks the original image into coarser copies. The algorithm then performs an exhaustive search to determine the offset of the image from the basis, and then applies this knowledge to the next level and continues until it obtains an accurate offset for all the images.

Not all of the images correctly align using my algorithm. I found this to be especially prominent with the larger, .tif files. It is possible that my matlab implementation is not fully accurate in the aligning the images, but when evaluating smaller images, the discrepancy seems to be minor. However, when the same implementaiton is applied to larger images, the imperfection also becomes magnified. One possible approach that could reduce the margin for error would be to evaluate a sub-area of the basis and translated image instead of the full images. This will remove any issues due to edges and also create a more accurate sum of squared differences result for the window. Other images required the window to change to create a more accurate result.

The following are images that have been aligned by my matlab function to create an accurate color image.