Project 3: Face Morphing

Part 1. Defining Correspondences

Using Adobe Photoshop, I first cropped, rescaled, and removed the background of headshot images of Barack Obama and Will Smith. I then created a function that I could use to select a total of 61 correspondence points. Finally, I generated a Delaunay Triangulation for each set of points. Here are the results.

Obama Triangulation.
Will Triangulation.

Part 2. Computing the "Mid-way Face"

To create the Mid-way Face between Barack Obama and Will Smith, I followed these steps:

  1. Compute the Average Face Shape:
average_shape=obama_keypoints+smith_keypoints2\text{average\_shape} = \frac{\text{obama\_keypoints} + \text{smith\_keypoints}}{2}
  1. Warp Each Face to the Average Shape:
    • Compute Affine Transformations: For each triangle in the mesh, I calculated an affine transformation matrix that maps the vertices of the triangle from the original face to the corresponding triangle in the average shape.
    • Warping the Triangles: I applied these affine transformations to warp each triangle from the original face to the average shape.
  1. Blend the warped faces by averaging the warped images. Below is the results.
    mid_face=warped_obama+warped_smith2\text{mid\_face} = \frac{\text{warped\_obama} + \text{warped\_smith}}{2}

Part 3. The Morph Sequence

Using the function from the previous part and blending and warping weights between [0, 1], I created a gif with 45 frames rendered at 30 fps, we get the following result:


Part 4. The "Mean face" of a population

For this part, I took 200 faces from the FEI dataset which had and manually labeled the gender of each face (we got 100 males and 100 females). I used these faces to compute some interesting-looking average faces. Here was the process behind how it was done.

  1. Computing the average face of the specific population.
  1. Morph each face to the average shape
  1. Average the morphed faces to obtain the overall average for all the faces in the population.

Here are examples of two male faces from the dataset being warped to the average male face shape.

Below is the result of averaging the faces when morphed with their respective population.

As we can see, surprisingly the average faces look decently good actually. The reason for this is because of the symmetry and clearness in their skin which occurs because the blemishes and asymmetry in every other face vanishes as we average the faces together.

Let's see what happens when we morph Obama's face to the average happy male face shape:

What about the average happy male face morphed into Obama's face shape?

Yikes.

Part 5. Caricatures - Extrapolating from the mean

In this part I create caricatures of Obama's face by extrapolating from the population mean calculated in the previous part. I create the caricatures by choosing an constant α\alpha  outside the normal range of [0,1][0, 1], to exaggerate either my Obama features (α>0.5\alpha > 0.5) or the average face's features (α<0.5\alpha < 0.5). Here are the results:

alpha = -0.2

alpha = 1.5

Bells and Whistles

I also created a morphing music video of my face at different ages. This was accomplished by stacking multiple morph animations (100 frames with 30 fps) together and converting the result to a mp4 video.