CS 194-26: Image Manipulation and Computational Photography

CS 194-26: Image Manipulation and Computational Photography

Final Project 2: Focus on Miniatures

Daniel Shi - abl

We start by creating either a horizontal or vertical focus line. From this initial line, we create a rectangular mask that we use to blur our image. To simulate a depth of field effect, we repeatedly blur the image while increasing the dimensions of our rectangular mask. Finally, we convert our image to HSV in order to increase the saturation.

Internet Images from Google Images

Akihabara

San Francisco

City

Stockholm

Stockholm

My Less Interesting Images

Sproul

Sather Gate

Sather Gate

Bancroft

Final Project 4: Seam Carving

We start by defining an energy function as the sum of the x and y Sobel gradient of our image. Using this energy function, we create a cost matrix where each entry is the sum of the total minimum energy up to that index (essentially creating the seam path as we go through our image). In doing so, the last row of the cost matrix will contain the optimal seam path. Finally, we simply remove this seam from our image.

For horizontal seams, we first transpose our image.

For some images, more optimal seams were found by either converting our image to grayscale instead of simply averaging/summing the three color channels or gaussian blurring the image beforehand.

Internet Images from Google Images

Akihabara with vertical seams removed

Stockholm with horizontal seams removed

San Francisco with horizontal seams removed

New York with vertical seams removed

Taesung with vertical seams removed

Taesung with horizontal seams removed

My Less Interesting Images

Fountain by Upper Sproul with vertical seams removed

Bancroft with horizontal seams removed

Failed Images

Here, we had some issues with distortions/alignment that resulted in imperfect images