Skip to content


Subversion checkout URL

You can clone with
Download ZIP
making machines generate faces
Pull request Compare This branch is 10 commits ahead, 3 commits behind phl:master.
Latest commit 0be42f6 @vhf Update

About this fork

This fork displays imagemagick crop argument to easily crop the rendered image to the face detected only.

It also displays these value during rendering.

Useful if you want to crop the rendered image to get only the "face" part as detected by ccv.


  • Output size : 1000
  • File name is 617x617+158+57.png
  • imagemagick -crop 617x617+158+57 617x617+158+57.png face.png
  • face.png contains face as seen highlighted under "fittest generation", at full resolution

What you can do with this fork

I first generated the 30 faces you can see below : (already "face-cropped" here)

sample cropped faces

Then I overlayed them to generate a less cubist face :

overlayed faces overlayed faces

  1. generate images
  2. crop them to get only the "facial" part of generated images (imagemagick)
  3. resize all of them to size of the smallest one (imagemagick)
  4. overlay them (imagemagick)


  1. generate random polygons
  2. feed them into a face detector
  3. mutate to increase recognition confidence

difficult stuff (the cv lib) by liuliu

idea via roger alsing's evolution of mona lisa, and greg borenstein's machine pareidolia


  • try out a demo
  • currently tested only in chrome (v 21)
  • hangs firefox in some cases, on some OSes
  • "autosave images" only works in chrome (uses a@download attribute)
  • large output sizes result in corrupt images (data:// URLs too long?)
  • probably a bunch of other bugs in there
  • have patience - let it churn away for a few hours and see what you get
  • annealing simulation from russellmcc
Something went wrong with that request. Please try again.