Colorizing the Prokudin-Gorskii Photo Collection

Background

Sergei Mikhailovich Prokudin-Gorskii travelled around the Russian Empire taking "color" photos by recording each scene three times, using a different red, blue, or green filter. Here, we attempt to produce color images from his negatives using image processing techniques.

Approach

We split the original image into three parts, the blue, red and green channels simply by taking the overall height of the image and dividing by three. We then attempt to align the red and green images to the blue image.

To accomplish this alignment we calculate value difference of the different color channels for possible displacements within a $[-n, n]$ window. We tried using both the L2 norm and the NCC (normalized cross-correlation), however the L2 norm was much faster and there was no visible difference.

This works fine for relatively small images, but in order to speed up processing for larger images, we utilize an image pyramid. For the most downscaled images, we use a larger window of displacement, then translate that to the next level of scaling, etc. Thus, when we align the original images, we only need to use a relatively small window to get a good result.

Because of the nature of the negatives, there tended to be a lot more noise around the borders, so we also performed alignment by cropping each side by about 5% to produce better results.

Some images with very colorful red, blue, and green portions were difficult to align using just by computing RGB differences of the pixels. This is because the values of red, green, and blue for the same pixel varied widely. Instead, we computed the $0.5|(x-1,y) - (x+1, y)|$ of every point in attempt to mimick the gradient of the image and then performed alignment using the filter image.

We also attempt to automatically crop out the border of the image, with varying degrees of success. We start at the edge rows and columns for each color channel and checking how much each pixel row or column differs from each other using the standard deviation. If the standard deviation is greater than a certain threshold, we stop cropping. This method worked well for the white edges, but did not work very well for the colored edges.

Results

The images were too large, so we rescaled the larger ones to be < 2 MB.

g vector: (56, -28)

r vector: (122, -62)

g vector: (5, 2)

r vector: (12, 3)

g vector: (48, 24)

r vector: (106, 40)

g vector: (32, 7)

r vector: (112, 16)

g vector: (82, -1)

r vector: (163, -14)

g vector: (60, 16)

r vector: (124, 14)

g vector: (40, 16)

r vector: (90, 22)

g vector: (56, 8)

r vector: (118, 12)

g vector: (83, 10)

r vector: (178, 12)

g vector: (-3, 2)

r vector: (3, 2)

g vector: (52, 26)

r vector: (108, 36)

g vector: (14, -8)

r vector: (133, -12)

g vector: (79, 29)

r vector: (176, 36)

g vector: (45, 12)

r vector: (96, 15)

g vector: (54, 13)

r vector: (112, 10)

g vector: (3, 3)

r vector: (6, 3)

g vector: (44, 6)

r vector: (87, 32)

g vector: (65, 12)

r vector: (138, 22)

g vector: (52, -1)

r vector: (104, -13)