A New Method for Human Posture Recognition Using Principal Component Analysis and Artificial Neural Network

The recognition of human posture from images is currently a very active area of research in computer vision. This paper presents a novel recognition method to determine a human posture is of walking or sitting using Principal Component Analysis (PCA) and Artificial Neural Network (ANN). In this paper, two types of learning are used to recognize the human posture. One is unsupervised and another is supervised learning. We have used PCA for unsupervised learning and ANN for supervised learning. To evaluate the performance of the proposed method, we have considered four types of human posture; walking, sitting, right leg up-down and left leg up-down. The experimental results on the human action of walking, sitting, right leg up-down and left leg up-down database show that our approach produces accurate recognition.


Introduction
Recognition of human actions from images is very important area in computer vision.Recently, Human Activity Recognition (HAR) has got considerable interests from many researchers in distinguished research areas due to its potential use in proactive computing, which is a technology to proactively anticipate peoples' necessity in situations such as health-care and take requisite actions [1][2][3].The recognition of posture is one step in the global process of analyzing human behavior [4].Several human action recognition methods have been proposed in the past decades.A detailed survey can be found elsewhere [5].Action recognition by using shape is performed by several researchers.For example, [6,7], authors used 2D and 3D shape features for recognizing actions.Cohen et al. [6], presented view independent 3D shape description for classifying and identifying human posture using support vector machines.The edge data from Canny edge detector represented the shape, and each actions defined the key frames [7].Masoud et al. used the Principal Component Analysis (PCA) for obtaining the features and recognition is performed using distance measure [8].PCA is a way of identifying patterns in data, and expressing the data in such a way that highlight their similarities and differences [9,10].PCA is a useful statistical technique that has found application in fields such as face detection [11], face recognition [11,12], and gesture classification [13], and is a common technique for finding patterns in data of high dimension.Since patterns in data can be hard to find in data of high dimension, where the luxury of graphical representation is not available, PCA is a powerful tool for analyzing data [14].PCA is one of several statistical tools available for reducing the dimensionality of a data set [15].The extracted feature vectors in the reduced space are used to train the ANN Classifier.Basically, binary silhouettes of various activities are commonly used to represent different human activities [16].Shift-invariant sparse coding was used to perform unsupervised learning to train an auto encoder network [17].In a work, authors have presented "Action Bank", a high-level representation of video which is comprised of many individual action detectors sampled broadly in semantic space as well as view point space [18].
In this work, PCA is used to extract prominent activity features and Artificial Neural Network (ANN) is used for classification.For feature extraction, we are given some data x and the cost function to be minimized, that can be any function of the data x and the network's output, f.We are given a set of example pairs (x,y), xЄX and yЄY and the aim is to find a function f: X→Y in the allowed class of functions that matches the examples.
After extracting features and applying PCA to reduce the feature vector dimensionality, an ANN is trained on a set of given actions to recognize human activity.An ANN, usually called neural network (NN), is a mathematical model or computational model that is inspired by the structure and/or functional aspects of biological neural networks.It consists of an interconnected group of artificial neurons and processes information using a connectionist approach to computation.ANN is simple mathematical model defining a function f: X→Y or a distribution over X or both X and Y.
In this paper, four types of human actions like walking, sitting, right leg up-down and left leg up-down have been considered.The proposed human action recognition method consists of three major steps, human detection and tracking, feature extraction, and training or classification.The first step is to detect and track a human figure in an image sequence.Background subtraction is a simple method for human detection and tracking.For each image sequence, a background subtraction algorithm and a simple correspondence procedure are used for segmenting human action.The second step is feature extraction from each frame and to normalize the image size.PCA is then applied to reduce the dimensionality of input feature space.The third step is to recognize human actions using ANN in the lower-dimensional eigenspace.This paper is organized as follows: Section 2 presents the method to recognize human postures which include the extraction of region of interest (ROI), feature extraction using PCA and classification using ANN.Experimental results of the proposed approach is explained in section 3. Discussions and conclusions are presented in Section 4.

Extraction of Region of Interest (ROI)
We assume that each image includes only one person and performs a single activity like walking or sitting.The color value of each background pixel is modeled by using a single Gaussian distribution.The Gaussian probability density function of a pixel to be in foreground is The steps of ROI extraction are as follows: a. Compute the probability of each pixel.b.Choose a threshold, T. c. Classify all pixels as foreground when P (J(x,y)=k)<T.T is chosen by hand that seems to produce pleasing results.d.Convert the ROI to binary.e. Find the region from the whole image.

Feature extraction using PCA
The fundamental approach is to compute the eigenvectors of the covariance data matrix Q and then approximation is done using the linear combination of top eigenvectors.The covariance matrix of the sample training image vectors and the principle components of the covariance matrix can be calculated respectively as: Where E represents the matrix of orthonormal eigenvectors and A diagonal matrix of the eigenvalues.E reflects the original coordinate system onto the eigenvectors where the eigenvectors corresponding to the largest eigenvalue indicates the axis of the largest variance and the next largest one is the orthogonal axis of the largest one indicating second largest variance and so on.Fig. 2 shows the representation of new axis of two principal components.Usually, the eigenvalues that are about zero values carry negligible variance and hence can be excluded.So, several m eigenvectors corresponding to the largest eigenvalues can be used to define the subspace.Thus the full dimensional image vectors can be easily represented in reduced dimension.The steps of recognition of walking and sitting patterns using PCA are as follows: a. Convert every image as a single column vector and concatenate horizontally.b.Subtract the mean.For PCA to work properly, we have to subtract the mean from each of the data dimensions.The mean subtracted is the average across each dimension.c.Calculate the covariance matrix.d.Calculate the eigenvectors and eigenvalues from the matrix.Since the covariance matrix is square, we can calculate the eigenvectors and eigenvalues for this matrix.e. Plot the values and choose top components to reduce dimension.

Classification using ANN
After feature extraction and dimensions reduction, we used ANN for classification.Classification is a pattern recognition (PR) problem of assigning an object to a class.Thus, the output of the PR system is an integer label.The task of the classifier is to partition the feature space into class-labeled decision regions.Multilayer Perceptron (MLP) is chosen as our classifier in this study.A MLP is an ANN which is an extremely popular and widely documented architecture.It is a good tool for classification purposes.It can approximate almost any regularity between its input and output.The ANN weights are adjusted by supervised training procedure called back propagation.Back propagation is a kind of gradient descent method, which searches an acceptable local minimum in the neural network weight space in order to achieve minimal error.MLP comprises an input, output and one or more hidden layers.With the exception of the input layer, all layers compute their output with a weighted output formula, an optional bias and an activation function.For this study, only a single hidden layer was used.Fig. 3 shows the multi layer perceptron and back propagation net structure.

Results
The proposed method is evaluated by using the human action database containing different types of human actions like walking, sitting, right leg up-down and left leg updown activities.In Fig. 4a, the training data sets of 40 binary images of walking and sitting are shown.These are the couple of sequences of generalized of ROIs for walking and sitting.
To apply feature extraction, every normalized ROI image is represented as a row vector in a raster scan fashion where the dimension of the vector is equal to the number of pixels in the entire image.In this paper, every image is converted to (2500X1) vector.After applying PCA to the Image database the total feature space is (2500X2500).Image database is shown in Fig. 4b.Only 10 features are taken which represent the total database because the eigenvalues of other features are about to zero.So our final feature space is (2500X10) matrix.Fig. 5 shows the top 10 eigenvalues after applying PCA.Only 10 feature vectors from total PCA feature space have been taken where every vector is a co-ordinate.So 10 dimensions are available to project the images i.e. every image will be represented as a single point in the 10 dimensions.
The projection formula is = (Feature Space T X Image vector) So for image1, the projection = (2500X10) T X (2500X1) = (10X2500) X (2500X1) = (10X1) So every image has 10 co-ordinate values.For other images the projection can be calculated in the same way.for each image.If there are 40 training images then we have 40 patterns.Back propagation method is used.We have 10 input neurons.Only 2 output neurons to take decision of two activities.The data are trained by two hidden layers.We have given the test patterns and specified the output for every pattern.Values of 2 output neurons for every walking images are specified as (1 0).Values of 2 output neurons for every sitting images are specified as (0 1).Tables 1 and 2 represent the achieved output result for the training images of walking and sitting respectively.
Experiment for two more human activities like right leg up-down and left leg updown was also done.Our proposed system model using PCA for feature extraction and MLP ANN for classification resulted in an average recognition rate of 91.875% for four activities.Our proposed method was compared with the conventional human activity recognition approach based on Naive Bayes, AdaBoost and k-NN classifier, shown in Tables 3-5 respectively, where the maximum mean recognition rate was 77.375% using k-NN classifier.Table 6 shows the recognition result using our proposed method.It turns out from these experimental results that the proposed approach (recognition rate: 91.875%) shows the superior recognition performance over other approaches.

Discussions and Conclusion
A method for human body posture recognition based on PCA and ANN is presented.As can be seen from the experimental results, proposed method can be used for human posture recognition with high degree of accuracy.In future, it is possible to use multiple frames for recognition at a time, combine motion features with shape features for classification and motion features of the ROI can be calculated by optical flow of the consecutive frames.

Fig. 1 .
Fig. 1. shows the result of extraction of ROI from the image.

Fig. 2 .
Fig. 2. Representation of new axis of two principal components.

Table 5 .
Experimental result using k-NN classifier.

Table 6 .
Experimental result using proposed method.