15-463: Computational Photography

Project 2 Hybrid Images

Jiaqi Xing

09/18/2012

 

Description

The goal of this lab is to create hybrid images, which is a clever blend of two images. It is done by blending the high frequency portion of one image and the low frequency portion of another.

My Approach

For every pair of images, I first converted them into grayscale and aligned them. Then I created the low pass image by generating a gaussian filter and apply that to one image, and for the high pass image I also created a gaussian filter and take the result of the original image minus the filtered image. Adding together these filtered images gives the resulting hybrid image.

Experimenting with the result of different "front/back" images, the sigma and matrix size for the gaussian filters I find that the low pass gaussian filter looks better using a smaller matrix such as size 5 or 9 together with small sigma value, while the gaussian filter used for generating the high pass image works better with larger matrix size and sigma values.

Bells and Whistles

Applying color to the images turns out to be a good way of emphasizing the closer (high pass) image. When we look closely the color really helps to bring out the content of the image and it also fade away when we look at a certain distance, while the far (low pass) image does not actually need the color definition that much, since it is already blurred and looking at some distance we will only be able to see a silhouette of the image. Hence I tried to apply color only to the low pass image.

Results

Here are the results of the four pairs of images that I experimented on.

Result 1

Cute baby face appear while looking closely, turning into dog face at far distance.

Original Picture



Hybrid Results


grayscale hybrid

colored low pass image hybrid

Log Magnitude of The Fourier Transform


fft for original dog image

fft for original baby image

fft for filtered dog image

fft for filtered baby image

fft for hybrid image

Gaussian and Laplacian Pyramids


Gaussian pyramid at level 1.

Gaussian pyramid at level 2.

Gaussian pyramid at level 3.

Gaussian pyramid at level 2.

Gaussian pyramid at level 5.

Laplacian pyramid at level 1.

Laplacian pyramid at level 2.

Laplacian pyramid at level 3.

Laplacian pyramid at level 4.

Laplacian pyramid at level 5.

Result 2

Original Picture



Hybrid Results


grayscale hybrid

colored low pass image hybrid

Result 3

Original Picture



Hybrid Results


grayscale hybrid

colored low pass image hybrid

Result 4

Original Picture



Hybrid Results


grayscale hybrid

colored low pass image hybrid