User:Nonreason

Gender Recognition by Face is an application of computer vision techniques to the problem of gender recognition, that is, the problem of determining genders of people presented in images or videos. This problem is solved by a 2-step process. The first step is to detect and localise human faces. This is achieved by a face detection algorithm. The second step is then to determine genders of those detected faces i.e. to separate his faces or her faces and is achieved by a gender classification algorithm.



Introduction
It is observable that our behaviour and social interaction are greatly influenced by genders of people whom we intend to interact with. Hence a successful gender recognition system could have great impact in improving human computer interaction systems in such a way as to make them be more user-friendly and acting more human-like.

Moreover, there are a number of applications where gender recognition can play an important role including biometric authentication, high-technology surveillance and security systems, image retrieval, and passive demographical data collections.

It is unarguable that face is one the most important feature that characterises human beings. By only looking ones’ faces, we are not only able to tell who they are but also perceive a lot of information such as their emotions, ages and genders.

This is why gender recognition by face has received much interest in computer vision research community over past two decades.

Technical Progress
Over the past decades, there have been significant advances in facial image processing, especially, in a face detection area where a number of fast and robust algorithms have been proposed for practical applications. As a result, a number of research areas attempting to extend the works have been emerging, face recognition, facial expression recognition and gender recognition, for example.

Since gender recognition can be considered as an extended work to face detection, this is why most research on gender recognition has focused on gender classification aspect and assumed the existence of face detection tools.

With regard to gender classification, the techniques, tools and algorithms employed originate from fields such as computer vision, pattern recognition, statistics and machine learning.

Technique
There are 2 main steps involved in recognising genders of humans presented in an image. These are face detection and gender classification, which are applied consecutively.

Face Detection

 * Main article: Face Detection

In order to exploit uniqueness of faces in gender recognition, the first step is to detect and localise those faces in the images. This is the task achieved by face detection systems.

As face detection is one of popular research areas, many algorithms have been proposed for it. Most of them are based on the same idea considering the face detection as a binary classification task. That is, given a part of image, the task is to decide whether it is a face or not. This is achieved by first transforming the given region into features and then using classifier trained on example images to decide if these features represent a human face.

As faces can appear in various locations and can also show themselves in various sizes, often, a window-sliding technique is also employed. The idea is to have the classifier classifying the portions of an image, at all location and scales, as face or non-face.

Gender Classification
After faces are detected by face detection algorithm, they need to be decided if they are his or her faces. This is the task achieved by gender classification systems.

Similar to the face detection task, the gender classification task is also considered as a binary classification problem but now with the result being male or female instead of face or non-face.

Essentially, gender classification consists of 4 main steps: (1) pre-processing, (2) feature detection, (3) feature selection and (4) classification.

Pre-Processing
Since, in real-life, it is unlikely that people will face directly and frontally towards the camera, face images often consist of some in-plane and out-of-plane rotations. Moreover, it is also unlikely that the light condition will be the same for all images. These variations greatly affect an accuracy of gender classifiers (see   for the studies of rotation, scaling and illumination change effects on classifier performance). The purpose of pre-processing step is thus to remove these variations as much as possible.

As with other computer vision applications, there is no unique solution to this problem. The common techniques involved in pre-processing step are face alignment, and light normalisation. Face alignment tries to align faces such that they are closed to a common or specified pose of face as much as possible, whereas light normalisation tries to get rid of the variation in illumination. One of the common employed normalisation techniques in the gender classification field is histogram equalisation.

Feature Detection
Working directly on raw pixel values can be very slow as one small face image can contain a thousand of pixels. Furthermore, not all the pixels will be useful. There can be an underlying structure that describes the differences between male and female faces better. Thus the feature detection module is employed here.

Generally there are two types of features presented in the gender classification context, geometric-based features and appearance-based features.


 * Geometric-based features (also called local features) came from psychophysical explorations. They represent high-level face descriptions such as distances between nose, eyes and mouth, face width, face length, eyebrow thickness and so on. (See video for examples of differences between male and female faces.)


 * Appearance-based features (also called global features) use low-level information about face image areas based on pixel values.


 * Among appearance-based features the popular ones are
 * various texture features: e.g. Local Binary Pattern (LBP), Local Directional Pattern (LDP) and Pixel-Pattern-Based Texture Feature (PPBTF).
 * histogram of gradients: e.g. Scale-Invariant Feature Transform (SIFT)
 * coefficients of wavelet transformation of image: e.g. Gabor wavelet and Haar wavelet

Feature Selection
Since not all the detected features are useful, the feature selection (or dimensionality reduction) module is employed here to choose only a subset of representative features. Doing feature selection not only gives us the relevant features and thus the more accurate result but also give us an additional advantage of faster computation time as the dimensionality of data is reduced.

The popular feature selection techniques often employed in gender classification task are Prinicipal Component Analysis (PCA), Independent Component Analysis(ICA), Adaboost and Genetic Algorithm.

Classification
With all necessary features have been extracted, the final task is to decide whether or not those features represent female or male face. As there are obviously two decisions to make this is essentially binary classification task, that is, the classifier is trained on the female and male example face images so that it learns the decision boundary between these two classes. After that it uses what it learn to make a decision on the given face images.

Among the binary classifiers, the most popular classifiers which give better performance than the others are a variation of Support Vector Machine (SVM), a variant of Adaboost and different Neural Network architectures. And among these classifiers, a number of comparative studies have been carried out and have suggested the best performance is obtained from the SVM.

Example
As there are increasing interests in gender recognition area, many algorithms have been proposed to solve the task. The differences of these algorithms are mainly in face detection methods they employed, features used in gender classification and the types of gender classifiers.

The most well-known and employed face detection algorithm is the one proposed by Viola and Jones. The features they used resemble Haar basis function and are extracted with the help of an integral image representation to speed up the process. The variants of Adaboost learning algorithm are then used to both select the best features and to train the classifier. One of available face detector based on Viola and Jones framework is provided by OpenCV.



In previous section, when the techniques are introduced, the examples of gender classification systems are also given (as references to papers for people who are interested). For a review of recent gender recognition algorithms, please see the study ).

Apart from those introduced in previous sections, the following 3 papers are also worth mentioned as they introduced new approaches to the task. To the best of my knowledge, Golomb et al., is the earliest attempt to gender classification using computer vision techniques. They employed a Neural Network architecture as their classifiers. The next one is Wu et al. which proposed a classifier based on Adaboost. Finally, Moghaddam and Yang investigated the use of SVMs as gender classifiers. They achieved the accuracy as high as 96.6% on the FERET database.

There is also interesting work from CVisionLab on gender classification where they use LBP features along with RBF-kernel SVM classifiers in achieving better than 95% accuracy on both male and female faces. In their website, apart from the result of their system on still images, they also provide video clips illustrating the result of their algorithm on the video and hand-drawn faces. Interested readers are encouraged to have a look at the given link.

Applications
One of the obvious possible applications of gender recognition is in human computer interaction system. Since by knowing gender of user, the system can be made user-friendlier with more human-like acting.

Advertisement and marketing is another field that can benefit from a successful gender recognition system. For example, superstore can fit the camera on the advertising screen such that it recognises genders of people passing by and advertising appropriate items e.g. cars for men and perfumes for women.

Gender recognition can also play important role in improving image retrieval and indexing. For example, when user searches for person’s face, it would be faster if images in database were first filtered by gender since this will reduce the need to do face recognition.

Following is the list of potential application of gender recognition system


 * passive demographic data collection
 * vision based human monitoring
 * human-robot interaction
 * biometric authentication
 * high-technology surveillance and security systems
 * automatic psychophysiology inspection
 * augmented reality