Sergey Mikhaylovich Prokudin-Gorsky (August 30, 1863 – September 27, 1944) was a Russian chemist and photographer. He is best known for pioneering colour photography and his effort to document early 20th-century Russia. He travelled across Russia in a railroad-car darkroom using three-image color photography to record the things he saw. He envisioned classrooms would have special projectors that would display his RGB negatives so he could bring color photographs to Russian children.

In this project, we are given the three exposures (RGB glass plates) for various photographs and asked to optimally align them to recover a single, colored photograph.

Main Project

Initial Approach

As described in the project spec, my initial, naive approach was to extract the individual RGB channels, calculate the SSDs produced by shifting the R and G photos through a [-15, 15] window, and align the RG channels to the B channel based on the minimum SSD found. However, in photos where one color was more predominant, the SSDs would be skewed and result in a misaligned photo.

Improvements

The following are improvements I made to my algorithm to improve the photo alignment (excluding bells and whistles):

Bells and Whistles

Better Features

I used the skimage.filters.roberts method to implement edge detection and remove bias in alignment that results from dominant colors.

On most of the images provided in class, the difference between what the image looks like with or without edge detection is not super significant. Since everyone is using Emir as an example, I'll show the result of what edge detection looks like on one of the extra photos I picked from the collection.

lake_no_edge
The predominantly blue image of the lake resulted in a wildly misaligned product.
lake_b lake_g lake_r
The lake's B, G, and R channels after using the roberts edge detection algorithm on the image.

Incorporating the edge detection into my algorithm, I get the following result:

lake
Lake is properly aligned.

Results Gallery

Here are the final results of my algorithm on the various input files, along with their respective displacements.