COMPSCI 194-26: Project 3

Kaijie Xu

nortrom@berkeley.edu

Background

In this project, I create morphs between images and play around with image warping. My first morphing animation entails a picture of myself morphed into Depp.

Defining Correspondences

The first step is to define points for the two images I am trying to morph

I define 33 points all over the face making sure to highlight main features such as the eyes, nose, mouth, face boundaries, and corners of the image

Here is the helper image for my definition of points

Creating the triangulation

The next step is to use the selected points to create triangulations. For simplification, I use the Delaunay triangulation on the mid points of two images directly. And here is the result.

triangulation of Depp                              triangulation of me

Computing the "Mid-way Face"

Before creating the full morphing video, I want to create the midway image to see the blend of the two faces. Firstly we compute the average of the two images. After that we compute the Delaunay triangulation and warp both images separately with the average shape.

In order to warp the image to the average, I use the process of affine transformation. Specifically, I use the inverse of the affine transformation matrix T that maps the source image to the midway image.

target image                     mid way image                     source image

As you can see in the result, both Depp and me share very similar features which made the morphed image look smooth

The Morph Sequence

Now I can create the video of the morph sequence from my face to Depp’s face. Similar to the previous part, we want to create a weighted average of images and repeatedly warp the images to that weighted average.

And the formula is : weighted avg image = source image + frac * (target image - source image)

I change the frac from 0 to 1, which means that the morph starts from my face to Depp's face, as the morph continues, the parameter will increment slowly and finally end on Depp's face

The "Mean face" of a population

I compute the “mean face” of a population of the Danes dataset. I take the average of the pre annotated points from the asf files, and then warp all of the faces into the average shape.

I warp some of the faces into the average shape. Here are a few samples of the warped images:

Sample Danish male warped to average

Sample Danish smiling male warped to average

Sample Danish female warped to average

Sample Danish smiling female warped to average

I also warp my face into average shape(and warp average faces into mine):

My face vs average Danish male

My face vs average smiling Danish male

My face vs average Danish female

My face vs average smiling Danish female

Caricature of my face by extrapolating from the population mean:

I created some caricatures of my face using the average face of the danish male. To intensify my features, I set the warp factor as 1.4 and -0.4 separately.

Extra Credit:

For the extra credit part, I make a morphing music video with the images of my different ages and some of my girlfriends' images(cuz she looks similar to me)