CS 194-26 Project 3: Face Morphing

Lucy Liu

Overview

In this project, we explore warping and cross-dissolving techniques in order to change face images.

Defining Correspondences

First we align the photos for warping results using the same align functions from previous projects. Then, we use plt.ginput(0,0) to select keypoints on the aligned images in same sequence for both photos. Then use scipy.spatial.Delaunay to build triangulations from the selected points.

My face
Celebrity, Jennie's face
Me face with triangulation mesh
Jennie's face with triangulation mesh

Computing the "Mid-way Face"

To compute the mid-way face, we follow the following algorithm:

Warping algorithm:

Below are some of my results:

Me face to mid-way face shape
Jennie's face to mid-way face shape
Mid-way face cross-dissolved

The Morph Sequence

The morph sequence is essentially repeating the mid-face process except with differing weights at each frame, rather than an average. For mine, I did 20 frames and each frame decreases the weight of the first image from 1 to 0 in decrements of 5% while increasing the weight of the second image in the same manner. I used the same weights for calculating the faces at each frame and for the cross-dissolving.

Me to Jennie morphing sequence

The "Mean face" of a population

To find the mean face of the population, I took the IMM Face Database and selected the frontal facing images, both smiling and not. Reading in each image and points provided, I found the average of all the faces. Using the average points, warped each individual image to that average and cross-dissolved all the images together to get the below result:

Average face of dataset
Average face with triangulation mesh

Here are some other population faces warped to the average shape:

Person 1
Person 2
Person 3
Person 4

Finally, let's warp my face to the average shape and vice versa!

My face warped to average shape
Average face warped to my shape

Caricatures: Extrapolating from the mean

We can extrapolate by changing the warping weight of the images from [0,1] to <0 or >1. Below are two examples of -0.2 and 1.2 weight on the first image and 1.2 and -0.2 weights on the second image, respectively.

α = 1.2 weight on average face
α = -0.2 weight on average face

Bells and Whistles

For Bells and Whistles, I transformed my gender by warping to the average East Asian male.

Original my face
Original East Asian male face
My face with triangulation mesh
East Asian male with triangulation mesh
My face warped to East Asian male shape
East Asian male face warped to my shape
East Asian male face mid-way of me and male face
My face to mid-way of me and male face
Equal weighted cross-dissolve of two faces