This simple Torch7 deep neural network, is designed to determine if an image is a picture of George W. Bush's face.
I am using a subset of the "Labeled Faces in the Wild" dataset. Found here: http://vis-www.cs.umass.edu/lfw/
The two subsets of the data I downloaded were "people with names starting with A" and "George_W_Bush".
In the image_pre_proccess.lua
file, I prepare each input image so it is compatable with the network. This mainly consists of resizing the image to the correct number of pixels.
The topology of the network is based on this well known convolutional neural network.
To train the network, I use the first letter in the filename of each image. If it is a "G" I expect the output [1, 0], and if its an "A" I expect the output [0, 1]. In other words, this network is meant to classify images as "GWB" or "Not GWB".
The network is created in CNN3.lua
as is the network training.
After the network is trained, testingCNN3.lua
will try classifying some images.