In this project, animations of morphing faces into other faces were produced, although the techniques do work in general for non-face shapes as well. A morph is definied as a simultaneous weighted warp and cross dissolve of a sources images to a desired destination. The warp is controlled by chosen corespondence points. Additionally, a mean face of a population was created from an annotated face data set and used to create a caricature by extrapulating from the mean.
The first step in the morph procedure is to define a set of corresponding points between the two images to be morphed. These corresponding points are averaged to get a mean shape and used to define a Delaunay triangulation. This triangulation remains constant and will be used for all warps in the morph sequence.
As an excercise, the mid-way point of the morph was created first. In order to accomplish this, the source images must be 1) warped into the mean shape and 2) cross dissolved to their mean colors. The warping procedure involves defining inverse affine transforms from each destination triangle to the corresponding source image triangles. Then for each triangle in the destination, we apply the corresponding affine transformations to get the points in the corrsepond to that triangle in both source images. These points are in the source image are color averaged and filled into the destination triangle. This completes the mid-way morph image.
Generating a complete morph sequence is simply a generalization of the previous part. Now instead of simply averaging the corresponding points and colors, we use some arbitrary value t (0 <= t <= 1) to define the proportional contribution of one source image to the morph (with 1-t being the contribution of the other image). We pick many t's equally spaced between 0 and 1 and save the intermediate morphed images at each step. These images are then combined into a gif to create nice morphing animation.
Next a "mean face" of a population was created using only the female faces of a faces dataset. This was done by computing the average shape of the whole population and then morphing each of the faces into the average shape and color.
Below are some examples of faces in the dataset being morphed into the average population shape.
Using the results from the previous part, it is possible to extrapolate from the population mean to create a sort of caricature. This was done by first getting the distance between my face shape and the average population face shape (corresponding points). Then some scalar times that distance would be added onto the average population face shape to extrapolate a version of my face that emphasizes the features of the population more.
Using the average population faces of African American males and Asian females, it is possible to morph a face into another ethnicity. Below results are shown by applying just the cross dissolve, just the warp, and both the cross dissolve and the warp (morph).
Below are the morph animations for the ethnicity / gender changes.