The objective of this project is to create an animation that morphs from one face to another. In order to do so, point correspondences are manually labeled between images, using key facial features as data points in order to generate the smoothest transformation possible. A triangulation is then created from these points using Delaunay triangulation. In order to compute a "mid-way" face for the morph sequence, we first compute the average face shape (using the average keypoint location of a pair of corresponding points between the two faces). We then compute the affine transformations necessary to warp the triangles from the original image into the new mid-way face shape. We also blend the colors together. Here is a sample "mid-way" face:
In order to generate a complete morph sequence, we compute multiple intermediate shape configurations and respective cross-dissolve weights in between the two faces. Each intermediate face is used as a frame in the morph animation. Here is a sample triangulation and completed morph sequence using the same images above.
"Mean Face" of a the Danes
In order to compute the mean face of a population, the mean face shape is first computed by averaging all facial control points. Each face in the population is then morphed to the average face shape, and the resulting faces are cross-dissolved. Here is a sample of the "mean face" of the male faces from this dataset.
Here are the male faces from the dataset morphed into the average face shape. Notice that there are some pretty strange distortions, especially around the forehead area, likely caused by inconsistent control point labels.
Morphing between my face and the average face
The left animation and image pair is an example of my face warped into the average face shape. Because my face is quite long and skinny compared to the average face shape, the resulting morph can look a bit distorted (my key facial features are squashed into a fatter facial canvas). The right animation and image pair is an example of the average face warped into my face shape. Because of my irregular facial shape, the resulting morph looks a bit distorted and stretched.
The following caricature was generated by extrapolating the features of the population mean geometry and warping my face away from the average face shape with an outlier warping fraction value. Note how my facial features are stretched and exaggerated.
Bells and Whistles
Using the facial female averages from this article, I computed morphing sequences from my phase to the averages. By setting both the warp and dissolve fraction at 0.5, I can generate a visualization that changes my face's gender and ethnicity.
Here is an example of a morph sequence from my friend Jennifer to a T-rex.
What I Learned
The coolest thing that I learned from this project was that affine transformations could be quite useful in generating awesome image processing effects!