Project 1 - Colorizing the Prokudin-Gorskii Photo Collection

Overview


Each set of images from the Prokudin-Gorskii photo collection contains the grayscale equivalent of the red, green, and blue channels. The goal of this assignment is to take the digitized Prokudin-Gorskii glass plate images and, using image processing techniques, automatically produce a color image with as few visual artifacts as possible.

Single Scale Implementation


For the small images, I used single scale implementation. I lined up both the green and red layer to the blue layer based on SSD and NCC metric, and I chose the better of the two metric for each image. I iterated through shifts of 15 pixels both left and right, up and down ([-15, 15]) to find the best displacement vector. These shifted green and red layers are then stacked on top of the blue layer to form a colored image.

Multi-Scale Pyramid Implementation


For the larger images, I implemented a 5-layer image pyramid. Starting from the top of the pyramid where the image is 1/32 of its orginal image size, I calculated the best displacement vector through iteration of 5 pixels both left and right, up and down. I then iteratively in pass the shifted coordinates (multiply by 2) down the pyramid to get finer estimations until the bottom where the image is back to the original size.

Bells & Whistles


Auto-Cropping


Because of the displacement of green and red layer, there are areas near the edges of stacked image that are not perfectly covered by all three. Using the displacement vector, the edges can be automaticly cropped.




Edge Detection


Image Pyramid works very well for most of the image but not on Emir.  My hypothesis is that there is a large area of blue in the image of Emir so that Raw Pixel Matching does not work well. Therefore, I used Roberts cross operator to detect the edge to find the best displacement vector.



After Auto-Cropping

Before Auto-Cropping

Extras


Here are some other images from the Prokudin-Gorskii Photo Collection.




G: [-3, 2]

R: [3, 2]

G: [5, 2]

R: [12, 3]

G: [3, 3]

R: [6, 3]

G: [60, 18]

R: [124, 13]

G: [49, 24]

R: [107, 40]

G: [41, 17]

R: [90, 23]

G: [57, 9]

R: [120, 13]

G: [80, 10]

R: [177, 13]

G: [78, 29]

R: [175, 37]

G: [54, 12]

R: [111, 8]

G: [42, 2]

R: [85, 29]

G: [64, 10]

R: [137, 21]

G: [53, -1]

R: [105, -12]

G: [52, 25]

R: [107, 35]

After Edge Detection

G: [49, 24]

R: [107, 40]

Before Edge Detection

G: [49, 24]

R: [99, -211]

G: [47, 24]

R: [109, 39]

G: [38, 0]

R: [80, -13]

G: [-13, 9]

R: [13, 15]