Final Project:

Seam Carving:

In this Project we want to resize a picture using seam carve. We use the Seam Carving for Content-Aware Image Resizing by Shai Avidan and Ariel Shamir Paper as a reference. In order to do the resizing we set our goal to be removing unnoticeable pixels that blend with their surroundings. we can create a energy_map using the gradiant in X and Y directions, and adding their absolute value:

Finding and removing the seams with thelowest energy:

In order to find the lowes seam in reasonable time we can treat this problem as a dynamic programming problems. In the paper they found The first step is to traverse the image from the second row to the last row and compute the cumulative minimum energy M for all possible connected seams for each entry (i, j):
We need to do this over and over again until we remove all the seams and resize our image. Since the paper only mentions how to do this in one dimention we can just repeat the process for rotated image.

Results:

the following result was achived: (left image is 500X333 and the right image is 450X250)

Failed Results:

Seam carving is very effective but the problem with is is you can only remove some of the seams if you remove alot then basically you are removing information and therefore the image is gonna lose some pixles. and if you get the wrong seam also you lose information

The image to the left is a fail case due to picking the wrong seam, but doing so intrestingly cropped the image. The image to the right is a fail case due to removing too many seams and therefore losing information as the result.

Here there are some other result:

What I learned?

After doing the project things that looked IMPOSIBLE are easy to do. I think there are alot of application that can be implemented using seam carving.

Light Field:

basically if we have a light filed camera you can take bunch of pictuers from multiple angles and then we can focuse on diffrent objects after we take the pictures but with a normal camera this is not pusible:

part I:

part II:

using the light fild data we can find the aperture by averaging a larger number of images over the grid by increasing the radius from the center

Bells And Whistles:

I took some images at my home but the result was not good, there could be many reason:s

1, the distance between each camera movement was not same

2, I didnt take 289 pictures only 25 pictures

3, I dont know the exact possion of the camera with respect to each pictuer