Package: bob.paper.SCIA2015
This package provides the source code to run the experiments published in thePaperGender Classification by LUT based boosting of Overlapping Block Patterns.
The gender classification pipeline consists of two main steps:  feature extraction and classification.
OBP features are used in our method along with boosting of look-up tables as weak classifiers.
This package relies onBobto execute both feature extraction and classification.NoteCurrently, this package only works in Unix-like environments and under MacOS.
Due to limitations of theBoblibrary, MS Windows operating systems are not supported.
We are working on a port ofBobfor MS Windows, but it might take a while.WarningWe have lately detected a small issue in the I/O of the LFW annotations that would rotate the aligned faces upside-down.
We have fixed these issues in version 1.0.3.
Due to the wrong alignment, the algorithms on the LFW database might now have slightly different results.
However, since the algorithms are not sensitive to the rotation of the face – as long as we have the same rotation in both the training and the test set – the results should be very similar.Installation:This package uses severalBoblibraries, which will be automatically installed locally using the command lines as listed below.
However, in order for theBobpackages to compile, certainDependenciesneed to be installed.This packageThe installation of this package relies on theBuildOutsystem.
By default, the command line sequence:$ python bootstrap-buildout.py
$ ./bin/buildoutshould download and install all required packages ofBobin the versions that we used to produce the results.
Other versions of the packages might generate sightly different results.NoteTo use the latest versions of allBobpackages, please remove the strict version numbers that are given in thebuildout.cfgfile in the main directory of this package.DatabasesExperiments are executed based on two publicly available image databases.
The evaluation protocols for both databases are included into this package:To get a copy of theMOBIO database, please follow theDownload Instructions, and download theIMAGES_PNG.tar.gzand theIMAGE_ANNOTATIONS.tar.gz.The images of theLabeled Faces in the Wild databasecan be downloaded from the database URL.
Our experiments rely on theimages aligned with funneling(not the ones aligned with deep funneling), andautomatic annotations.The Experiments:Protocol:The test are performed on two face data sets: MOBIO and Labeled Faces in Wild (LFW).MOBIO: The evaluation protocol we use consists of training, development and test sets.
The number of images in each set are: 9598 in Training set, 9586 in Development set and 9592 in Test set.LFW: The data set consists of more than 13,000 images collected from web.
The images are split into 5 non-overlapping partitions and on each test round four partition are used for training and the fifth one is used for testing.
The accuracy is reported as the mean over the five sets.Algorithms:The following algorithms are implemented:PCA + LDA: PCA is used with 98% variance and Linear Discriminant Analysis is used as the classifier.LBPHS + LDA: Uniform Local Binary Patterns (LBP) features are extracted from the images by dividing it into 6x6 cells.
The LBP features from different cells are concatenated and the same PCA + LDA classifier is used.MB-LBP + LUT Boosting: Multi Block- LBP features of square shape are extracted from face images.
The block size is varied from 1 to 7.
The features are boosted with LUT as the weak classifier.OBP + LUT Boosting: OBP features of square shape are extracted from the images.
The block size is varied from 1 to 7.
The features are boosted with LUT as the weak classifier.LBP + LUT Boosting (not part of the paper): LPB features in a single scale are extracted from the images.
The features are boosted with LUT as the weak classifier.User Guide:To reproduce the results from the paper use the following commands:Image preprocessing:$ ./bin/preprocess.py -d mobio -i <MOBIO-IMAGE-DIRECTORY> -a <MOBIO-ANNOTATION-DIRECTORY> -vv
$ ./bin/preprocess.py -d lfw -i <LFW-FUNNELED-IMAGE-DIRECTORY> -a <LFW-FUNNELED-ANNOTATION-DIRECTORY> -vvPCA+LDA on raw pixel values:$ ./bin/pca_lda.py -d mobio lfw -vvPCA+LDA on LBPHS features:$ ./bin/pca_lda.py -d mobio lfw -vv -lBoosting with three types of features: MB-LBP, OBP, and LBP (just for comparison, not in the paper):$ ./bin/lbp_boosting.py -d mobio lfw -vv
$ ./bin/lbp_boosting.py -d mobio lfw -vv -o
$ ./bin/lbp_boosting.py -d mobio lfw -vv -b 1Evaluation:$ ./bin/evaluate.py -d mobio lfw -vvThe last command will print out the results as they are reported in Table 1 of thePaperand generate the ROC curves as shown in Figure 5 of thePaper.