CS194-26: Image Manipulation and Computational Photography, Fall 2017

Project 1: Images of the Russian Empire

Khoa Hoang - 3033239978 - cs194-26-aaq



Overview

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. In order to do this, you will need to extract the three color channel images, place them on top of each other, and align them so that they form a single RGB color image.

Section I: Implementation

Part 1: Single-Scale

I chose SSD to calculate the differences between the RGB channels as it is the simplest working method in my opinion. The processing involves shifting the R and G over B in the range of [-15, 15] and selecting the displacements that have the smallest SSD.

Since the borders really affect the SSD, so all the .jpg images are cropped by 20 px and all .tif images are cropped by 800 px on each side at the beginning.

The only problem that I faced in this part is just the negative effect of the borders and it was solved by cropping as described above.


Monastery G: [-3, 2], R: [3, 2]
Cathedral G: [5, 2], R: [12, 3]
Settlers G: [7, 0], R: [14, -1]
Nativity G: [3, 1], R: [7, 1]

Part 2: Multi-Scale

When the images become large, they take tremendously long time to be processed the same way as small jpg images are as the resolutions are much bigger, hence SSD will become very expensive to calculate. The problem was solved with pyramid method by scaling the images into different lower-resolution layers and using SSD at each level. The searching range is still [-15, 15] but at every level, not all the pixels are taken into account because it will be very costly for SSD, so only 200 px square at the center of each layer are considered.

A few problems that I ran into includes not knowing how many levels of pyramid I should use, what searching range should be and the alrorithm took so long to process. All the problems were solved as described above.


Harvesters G: [60, 16], R: [124, 16]
Icon G: [40, 16], R: [88, 24]
Lady G: [52, 8], R: [112, 12]
Nativity G: [76, 28], R: [168, 36]

Three Generations G: [48, 12], R: [108, 12]
Train G: [44, 8], R: [88, 32]
Turkmen G: [56, 20], R: [116, 28]

Section II: Bells and Whistles

Edge Detection

These two pictures gave me a hard time as they have big difference in brightness and the method above was not enough to produce a precise alignment. The problem was solved by using edge detection algorithm by Roberts as the brightness are taken out of the equation and only the edges matter.


After G: [48, 24], R: [108, 40]
After G: [64, 12], R: [136, 24]

Additional Images

Chasovnia G: [60, 8], R: [124, 4]
Ostrechiny G: [12, -8], R: [132, -12]