CS 194-26 Project 1
Images of the Russian Empire: Colorizing the Prokudin-Gorskii photo collection
Phoebe So
Overview
The objective of the project is to produce color images from the digitized Prokudin-Gorskii glass plate images. This is achieved by extracting the three RGB color channel images and aligning them to form a single colorized image.
Approach
Basic Method
The basic approach was to split the digitized glass plate image into three channels and then align the R and G channels to the B channel. To align the R to B, we exhaustively searched over a window of possible displacements and saved the displacement that yielded the lowest Sum of Squared Differences score. We then repeated the procedure to align G to B. 10% of the width and height were cropped from the channels prior to alignment to decrease noise at the edges.
Image Pyramid
However, the exhaustive search procedure was very slow for larger and higher resolution images, so an image pyramid method was implemented. This process recursively aligns the images at multiple scales (by factors of 2), beginning with the coarsest image and going to the finest image. By estimating the displacement at each level of the pyramid, we can use a smaller range of displacement when aligning the finer images and therefore decrease run time.
Problems
For the Emir image, aligning the channels on the B channel was not as effective as the other photos because the B channel is significantly brighter than the R and G channels. To fix this issue, the R and B channels were aligned to the G channel.
Aligning to B: R[103,57], G[49,24]
Aligning to G: R[57,17], B[-49,-24]
Bells and Whistles
Automatic White Balancing
Automatic white balancing was achieved by rescaling all the pixel intensities of the RGB channels such that the brightest pixel is white.
Original
With automatic white balancing
Automatic Contrasting
Automatic contrasting was achieved by rescaling the pixel intensities so that the brightest 99th percentile of pixels is white, the brightest 1st percentile of pixels is black, and all other pixels were linearly rescaled.
Original
With automatic contrasting
Final Images
Cathedral: R[12,3], G[5,2]
Emir: R[57,17], B[-49,-24]
Harvesters: R[124,13], G[59,16]
Icon: R[90,23], G[41,17]
Lady: R[116,11], G[56,8]
Monastery: R[3,2], G[-3,2]
Nativity: R[8,0], G[3,1]
Self portrait: R[176,37], G[79,29]
Settlers: R[15,-1], G[7,0]
Three generations: R[112,11], G[53,14]
Train: R[87,32], G[43,6]
Turkmen: R[116,28], G[56,21]
Village: R[138,22], G[65,12]
Extra Images
Boat yard: R[126,60], G[24,43]
Svet: R[164,66], G[77,39]
Waterfall: R[89,30], G[18,17]