A Human Body Gait Recognition System Based on Fourier Transform and Quartile Difference Extraction

A research method of gait recognition based on feature combination is proposed, which includes the wavelet transform (WT), Fourier transform (FT) and the quartile difference, to explore the gait recognition system in Internet of things human body sensor based on smart phone. It can extract the lowdimensional gait parameters of the acceleration signal, and these gait parameters can reflect the movement characteristics. Then, they are combined into feature vector to identify by a pattern recognition algorithm. Finally, the experimental verification is carried out in the experimental system. The results show that this gait recognition method simplifies the processing flow to a certain extent, and improves the recognition accuracy. In conclusion, the algorithm has a good effect, and can identify the gait behavior with high precision. Keywords—Internet of things, body area network, sensor, gait recognition


Introduction
IOT (Internet of Things) has the ability of recognition, sensing and communication, which is convenient for people's daily life, so it has been paid more and more attention and research [1]. While the BAN (Body Area Network) belongs to the Internet of things related to the human body, which is widely used in the field of remote diagnosis, medical care and special population monitoring and so has a very important significance and a huge demand [2][3]. It has become a hot spot of scientific research and practical application. Biometrics refers to the physiological and behavioral characteristics unique to each individual, and biometric recognition is the use of these features for motion recognition or identification, the gait recognition is the biometric recognition method being widely concerned in recent years [4]. A lot of experiments have been done on the combination of gait recognition and application of the body area network [5].
Intelligent terminal equipment has been widely used in various research because of its advantages such as easy to carry. This paper designs and realizes gait recognition system in body area network based on smart phone. The data collected by the sensor can be transmitted to the remote server through the smart phone for data analysis and processing, so as to realize the remote transmission of data. In this paper, we use the wavelet transform (WT), Fourier transform (FT) [6] and the quartile difference to extract the low-dimensional gait parameters of the acceleration signal, but these gait parameters can reflect the movement characteristics. Then, they are combined into feature vector and identified by a pattern recognition algorithm. Finally, the experimental verification is carried out in the experimental system.

State of the Art
In this paper, we studied a set of experiments based on acceleration sensor body network test system. The system has the functions of data acquisition, data collection, data transmission and data processing [7]. The three-axis acceleration signal acquired by the sensor is the data source for the subsequent data analysis. Through the analysis and processing of the acceleration signal, the recognition of human gait and the fall detection are realized. The experimental verification system uses Shimmer sensor platform, Android smart phone and computer-side signal analysis and processing software components [8]. The Shimmer sensor is fixed in the middle position of the waist of the subject and used to acquire the three-axis acceleration signal of the subject during the movement. Then, the data will be sent to the Bluetooth smart phone Android, and then transmitted via 3G / WiFi to the server / database, and save filter rules as file to subsequent data processing. In order to make the collected data can better reflect the movement of the human body, Shimmer was fixed in the middle of the waist of the subjects, and the sampling frequency was set to 50Hz [9]. Once the data has been analyzed and processed, the results are displayed on the front page. Therefore, the users can query the results of the analysis on the terminal device. The three-axis direction of the sensor is the x-axis, the y-axis, and the z-axis, respectively, in the vertical direction.
The data processing flow chart of this paper is shown in figure 1. Because the acceleration signal is high frequency fluctuation, it is difficult to use the original acceleration signal to identify the basic gait pattern, and thus need to find a relatively stable, able to characterize the gait characteristics of the characteristic parameters. Before extracting a feature, it is necessary to remove any interfering signals, such as noise, that may have an effect. After the signal preprocessing, we began to feature extraction. In this experiment, a small number of low-dimensional and easy-tocalculate parameters are selected from the acceleration signals, and these are combined into feature vectors. Finally, the feature vector is trained and classified by the decision tree algorithm and the Bayesian network algorithm in pattern recognition.  If the function f (t) satisfies the condition: it has a finite number of discontinuities; it has a finite number of extremum points; absolutely integrable. Then, the the formula (1) is workable. The F (w) is called the Fourier transform of the integral operation f (t). (1) is a continuous Fourier transform formula, a lot of data is not continuous, but in a discrete way. Therefore, the discrete Fourier transform is required, and the formula (2) is the discrete Fourier transform.
Among them, x (n) is a discrete sequence, and x (k) is called a discrete Fourier transform of x (n).
The acceleration signal in the vertical direction is subjected to Fast Fourier Transform (FFT). The frequency of the gait is the frequency corresponding to the maximum energy in the spectrum, which is used to characterize the speed of human gait behavior. Under normal circumstances, the normal frequency of walking between 1 ~ 3Hz.
Gait cycle. People walking is an alternating movement of the feet, and feet before the line is a regular alternating, which is a cyclical repetitive action. Thus the gait cycle refers to a periodic change in the gait signal (acceleration signal) obtained from the human body, which begins at one foot touching the ground and ending at the same foot again touching the ground.
In order to better understand the gait cycle, gait phase must be used to describe a complete gait cycle. Through different stages of gait mode analysis, it can more directly identify the individual joints of different functional significance of movement. In this paper, the normal gait cycle is divided into eight different phases: initial contact period, load-bearing reaction period, standing middle stage, standing stage, early stage, starting swing phase, moving mid-stage.
There are many calculation methods of gait cycle, the current mainstream method of calculation is periodic detection [5], but the cycle detection is more complex. Because the wavelet transform can transform the signal well and retain the characteristics of this paper, and compared to the cycle detection is more simple. Therefore, this paper uses the discrete wavelet transform (DWT) of the acceleration signal. It makes the signal waveform becomes smooth and cyclical obvious, and thus extract the gait cycle.
Discrete wavelet transform referred to as DWT. The scale factor a and the translation factor b are discretized to obtain a set of discrete wavelet bases: Among them, a = a 0 m , b = ka 0 n b 0 , a 0 >l, b!0, m and n are integers. By properly choosing the parameters such as ", a 0 , b 0 , a canonical orthonormal basis of " m,n (t) can be formed. Usually use a0 = 2, b0 = l constitute a discrete dyadic wavelet.
Quartile difference. QuartileDeviation are also known as Inter-QuartileRange. The four point difference between the 50% reflects the degree of discrete data, the greater the value, indicating the data more dispersed, the smaller the value, indicating the data more concentrated. Quartiles are not affected by extremes.
A set of data from (or from large to small) after sorting, with three points of all the data is divided into four equal parts, and the three point numerical position is called the four percentile, which were recorded as Q1 (the first four percentile), Q2 (the 24 percentile, namely median) Q3, (the three or four percentile). The distance difference between Q3 and Q1 is called the quartile difference.
x, z axis cross correlation coefficient. The cross-correlation function represents the degree of correlation between the values of the two time series at any two different moments, that is, the cross-correlation function is the degree of correlation between the values of the random signals x (t), y (t) at any two different times t1, t2.
Suppose that the length of the discrete signal x (n), y (n) is N, the cross-correlation coefficient of x (n), y (n) can be calculated from (4), where x (n), y (n) are not 0 at the same time.

Extraction of gait features
At present, most of the gait feature extraction is the multiple transformation of the acceleration signal, making the dimension of the feature parameter is very high, and finally had to reduce the dimension or optimization to simplify the feature. This chapter calculates more than 10 low-dimensional, easy-to-calculate parameters from the acceleration signal, such as step, pace, step frequency, pitch frequency error, cycle, frequency, peak, quartile, cross correlation coefficient and son on. They are then combined into a series of features to obtain multiple feature combinations.
In this series of feature combinations, how to select the optimal combination of features? In this paper, the merge method is adopted. The merge method uses a bottom-up approach, which combines the features gradually, until the newly added features can no longer cause the improvement of the classification performance. The specific steps can be divided into the following steps: 1. The candidate feature set is X ={x 1 ,...,x n }. Each feature in X is taken as training set. There are n training sets, namely{x 1 },...,{x n }. The n training sets are trained and tested one by one, and the best training set is selected as the feature vector Y. Suppose that the training set is {x k }, then Y={x k }. In this case, the candidate feature set is the set X ={x 1 ,...,x k-1 ,x k+1 ,...,x n } with x k removed. 2. For candidate feature set X ={x 1 ,...,x k-1 ,x k+1 ,...,x n }, each of these features is combined with the feature vector Y to form a training set. There are n-1 training sets, namely {{x 1 } Y},...,{{x k -1 } Y},{{x k+1 } Y},...,{{x n } Y}. The n-1 training set is trained and tested one by one, and the training set with the best result is chosen, which is assumed to be Z ={{x i } Y}. 3. The results of classification and recognition of the set Z and the feature vector K are compared. If the recognition result of the set Z is superior to the classification result of the feature vector y, Z is given to Y as the feature vector, that is, the feature vector is Y = Z. 4. If the classification result of feature vector Y is superior to the classification result of set Z, it is considered that the optimal solution is the optimal solution.

Gait feature alignment
This paper uses the decision tree classifier (C4.5) and the Bayesian network classifier (BayesNet) to carry on the polymerization experiment to these nine characteristic. Decision tree, also known as decision tree or multi-class classifier, is a tree structure used for classification and prediction, which is particularly convenient for solving multi-class or multi-peak distribution problems. C4.5 algorithm is one of the more classic algorithm. Bayesian network classifier is also a widely used classifier algorithm.
According to the procedure described in the previous section, the results of each experiment were recorded, select the set of results, and compare it with the best results from the previous experiment until the end. Table 1 shows some of the features of the decision tree algorithm selection process. Table 1 (a) records the results of the first experiment, from which the recognition rate of feature 3 is the highest, so feature 3 is selected as the first feature of the feature vector. Table 1 (b) records the results of the second experiment. It can be seen that the combination of feature 1 and feature 3 has the highest recognition rate, and then compared with the best results of the first experiment, that is, compared with the recognition rate of feature 3. As a result, the recognition rate of the combination of feature 1 and feature 3 is higher, so feature 1 is selected as the second feature of the feature vector. Table 1 (c) records the results of the last experiment. It can be seen that the recognition rate of feature combinations 3, 1, 8, 7, 5, 4 is the highest, and then compared with the best results of the last experiment, that is, compared with the recognition rate of the feature combinations 3, 1, 8, 7, 5. As a result, the recognition rate of the feature combinations 3, 1, 8, 7, 5 is higher, and the polymerization is completed. And the best feature combination is the best combination of the previous experimental results, namely the feature combination 3, 1, 8, 7, 5.
The feature selection process of Bayesian network algorithm is also the same. Table 2 and Table 3 briefly describe the decision tree and Bayesian network algorithm selection process. Each combination listed in the table is a set of features with the highest overall correctness rate for each experiment.  Therefore, the characteristic parameters of the decision tree are chosen as 3, 1, 8, 7, 5, and BayesNet's characteristic parameter selection is 3, 1, 8, 6, 2, 9, 7. Therefore, equation (5) and equation (6) are defined as the decision tree and BayesNet feature vector:

Results and Analysis
Subjects selected healthy young people, 30 volunteers participated in the experiment, including 15 men, 15 women, aged 22 to 30 years old. The data acquisition and analysis were carried out using the experimental system designed in this paper. The Shimmer sensor was fixed in the middle of the volunteer's waist and allowed the volunteers to collect data outside the lab for a while. Volunteers in the experiment to complete a total of four daily actions, namely "walking", "running", "upstairs", "downstairs." Volunteers will be told to pause for 1 ~ 2 seconds before switching to gait mode before the start of the experiment, in order to extract different gait behavioral acceleration signals.Each volunteer performed four gait behaviors at the normal speed they used and repeated 10 times. A total of 1200 samples were collected. After collecting all the data collected in a good order, specifically the establishment of a gait database.  Table 4 shows the Bayesian network algorithm and decision tree algorithm classification test results. From the comparison of Table 4, the decision tree algorithm is better than the Bayesian network algorithm in the overall performance, the former is 97%, the latter is 95.1%, the former has higher recognition rate and better effect. In addition to a slight decline in running, the other three have a greater increase, especially upstairs has significantly improved, from 86.5% to 93.3%, the recognition rate increased by 6.8 percentage points. Figure 2 shows the DET (Detection Error Trade-off) curve. The horizontal axis indicates the false match rate (FMR), that is, the type of the error is mistaken for the correct type. The vertical axis represents the False Non-Match Rate (FNMR), that is, the correct type is mistaken for the wrong type. The intersection point represents the Equal Error Rate (EER). From the figure, we can see that the EER is about 2%, the running EER is about 1%, the EER is about 5%, and the EER is 2.8%. This shows that the best recognition is running, followed by the downstairs, walking and upstairs, and Table 3 results are very consistent. At the same time from Table 4 shows that in addition to the effect of slightly worse, the rest of the results are more satisfactory.

Conclusion
In the realization of the gait recognition algorithm, the relevant experimental verification is carried out in this paper, and the experimental results show that the algorithm has a good effect, and can identify the gait behavior with high precision. However, there are still some problems, so it still needs to be further improved. For example, only a single triaxial acceleration sensor is used in gait recognition, but in more complex scenarios, the acceleration sensor alone cannot achieve the overall monitoring, and other types of sensors need to be added in future work to make the scope of the detection more wide.