CS 194: Computational Image and Photography Spring 2020

Project 3: Face Morphing

Sherry Luo

Overview

The purpose of this project was to create morphing sequences between faces. I morphed my face into my roommate's face, the average Brazilian female's face, and my face in various emotions.

Defining Correspondences

Using matplotlib's ginput, I collected points to serve as the control points or vertices of triangles defining the shape of the image. I then used scipy's Delaunay triangulation function.

Computing the "Mid-way Face"

Now that I have triangulated both faces, for each pair of triangles between the two images, I calculated the affine transformation from the first triangle vertices to the others by transforming and changing the basis from each triangle to the mean triangle. Next, I set the image at the mean triangle shape to be the pixels of the mean of the transformed triangles.

My face
Half face
My roommate's face

The Morph Sequence

Using the same algorithm as above except with some t ranging between 0 and 1 instead of strictly 0.5, I created a morph sequence from my roommate's face to my face.

Video Link

The "Mean face" of a population

I grabbed out all female faces from the provided Brazilian dataset. I then computed the average face by using the same technique with the mid-way face except this time with all female faces instead of just two images.

Average female Brazilian face
Example 1 morph from one female Brazilian to average face
Example 2 morph from one female Brazilian to average face
Example 3 morph from one female Brazilian to average face
My face warped into average geometry
Average face warped into my geometry

Caricatures: Extrapolating from the mean

I extrapolated my face to the average face by about 0.3 so that it is still distinctly my face but a slight twist.

My face
My face extrapolated to Brazilian face
Average female Brazilian face

Bells and Whistles

I morphed myself into four different emotions

Morph from happy to neutral to annoyed to frustrated