Fall Detection with the Support Vector Machine during Scripted and Continuous Unscripted Activities

In recent years, the number of proposed fall-detection systems that have been developed has increased dramatically. A threshold-based algorithm utilizing an accelerometer has been used to detect low-complexity falling activities. In this study, we defined activities in which the body's center of gravity quickly declines as falling activities of daily life (ADLs). In the non-falling ADLs, we also focused on the body's center of gravity. A hyperplane of the support vector machine (SVM) was used as the separating plane to replace the traditional threshold method for the detection of falling ADLs. The scripted and continuous unscripted activities were performed by two groups of young volunteers (20 subjects) and one group of elderly volunteers (five subjects). The results showed that the four parameters of the input vector had the best accuracy with 99.1% and 98.4% in the training and testing, respectively. For the continuous unscripted test of one hour, there were two and one false positive events among young volunteers and elderly volunteers, respectively.


Introduction
In 2010, 10.7% of Taiwan's population was age 65 or older. According to the government's evaluation, this proportion will become over 20% by 2025. Among the elderly, falls are not only life OPEN ACCESS threatening [1] but also herald an inability to live independently [2]. Injuries from falls include broken bones, superficial cuts and abrasions to the skin as well as connective and soft tissue damage [3][4][5]. Detection of a fall would help to reduce the time between the fall and the arrival of medical attention [6,7], which could be realized either through an automatic fall-detection system or through a Personal Emergency Response System (PERS). However, the most common existing PERS using the push-button pendant is not always a satisfactory fall-detection method when elderly people lose consciousness or faint [8].
In recent years, the number of proposed fall-detection systems developed has increased dramatically [1,9]. The waist is a popular location for a fall-detection system because it provides reliable indications of full-body movements [10][11][12]. Studies have evaluated a set of fall-detection algorithms on data that recorded from 20 middle-aged volunteers (40-65 years old), performing six different falls and four scripted activities of daily living (ADL) [10,11]. The same ADLs were also recorded from 21 adults (aged 58-98 years) in a residential care unit. The results showed that a threshold on the impact and posture can achieve 97.5% sensitivity and 100% specificity. Chao et al. [13] recorded seven male subjects performing eight different types of falls and 17 functional ADLs. Using a combination algorithm of acceleration cross-products and post-fall postures, a sensitivity of 100% and a specificity of 49.8% were obtained. Bourke et al. [14] recorded 10 young healthy volunteers performing 240 falls and 120 ADLs and 10 elderly healthy volunteers performing 240 scripted ADLs; they employed thresholds on the velocity, impact and posture to achieve 100% specificity and sensitivity with a false-positive rate of 0.6 FP/day for continuous unscripted activities.
In previous studies, the signals of a tri-axial accelerometer were combined to produce many action parameters, such as the total sum vector, the dynamic sum vector, the sliding sum vector, the velocity and the tilting angle. Prior studies [14,15] have defined thresholds as criteria for fall-detection systems. A falling ADL is considered as falling down, such as forward fall, backward fall and lateral fall with both legs straight or with knee flexion [9][10][11][12][13][14][15][16]. The ADLs consist of sitting on a bed or chair, lying on a bed, walking up and down the stairs and walking [9][10][11][12][13][14][15][16]. However, the acts of standing and falling down are not classified as falling ADLs. Falling ADLs also include sitting at the bedside and slipping on the ground, sitting on a wheelchair and slipping on the ground, rolling off a bed or falling out of bed [17]. Support vector machine (SVM)-based classification methods represent a major development in pattern recognition research, for which innovation is the ability to find a hyperplane dividing samples into two classes and having the widest margin between them. Moreover, the hyperplane concept can extend a higher dimensional set with a kernel function to make a nonlinear separating hyperplane. This hyperplane, with maximum margins, can be formulated as a quadratic optimization problem in feature space. The subsets of patterns that are closest to the decision boundary are called support vectors. Therefore, SVMs have been applied to many pattern recognition and classification problems in bioinformatics [18][19][20][21][22]. Brown et al. [23] described a successful use of SVMs applied to gene expression data for the task of classifying unseen genes. Dehmeshki et al. [24] used SVMs for the classification of lung data. Chu et al. [25] applied SVMs for cancer diagnosis based on micro-array gene expression data and protein secondary structure prediction. Guler and Ubeyli [26] used SVMs on the classification of EEG signals. SVMs are also applied to ECG signal analysis and arrhythmia classification [27][28][29]. SVMs can also be used as criteria to detect the QRS complexes in 12-lead electrocardiograms [30].
In this study, we will first define falling ADLs as actions in which the center of gravity of the body quickly descends. These activities include, but are not limited to, slipping while ascending stairs, slipping while descending stairs, stumbling and falling down forwards, backwards falling down, lateral falling down, and falling down with a weak leg but also sitting on a bedside and slipping onto the ground, sitting in a wheelchair and slipping onto the ground, rolling down from a bed, and falling down on a bed. Moreover, the accelerometer measures the moving acceleration. If a non-falling ADL does not include the body's center of gravity falling down, then it is certain to be distinguished from the falling ADLs. Thus, our studies focus on non-falling ADLs in which the action involves the center of gravity falling. The non-falling ADLs include walking up stairs, walking down stairs, sitting down on a bed, standing up from a bed, sitting down in a wheelchair, standing up from a wheelchair, walking, lying down, sitting up from lying, squatting down, and standing up. Second, we used the hyperplane of the SVM as the separating plane to replace the traditional threshold method for the detection of falling ADLs on a comprehensive dataset containing simulated falling ADLs, non-falling ADLs, and continuously scripted ADLs, including falling ADLs and continuous unscripted ADLs performed by young and elderly volunteers with our designed device. Figure 1 shows the flow diagram of our method. Subjects wore our designed device at the waist, which had a tri-axial accelerometer (Kionix Inc., KXPA4-2050, Range: ±2 g), a Bluetooth module (Atrie Inc., BTM-204B), and a microprocessor (Texas Instruments Inc., MSP430 F5438). The resolution was 12 bits and the sampling rate was 200 Hz for the signals of the tri-axial accelerometer. Digital accelerometer signals were then transferred to a Bluetooth chip and transmitted wirelessly to a remote server. A Visual Basic-based interface system was used to receive a Bluetooth transmitted signal and also to display and store information. Furthermore, feature extraction and falling ADL detection were performed by a program coded in Matlab.

Feature Extraction
Four different parameters that are associated with falling ADLs were examined: total sum vector, fast changed vector, vertical acceleration, and posture angle [14][15][16]. First, the total sum vector, SV Total (t), containing both the dynamic and static acceleration components is calculated from the sampled data, as indicated below: where A x (t), A y (t), and A z (t) is the acceleration in the x-, y-, and z-axes at time t, respectively. Second, the fast changed vector, CV Fast (t), is calculated using the differences between the maximum and minimum acceleration in a 0.1 s sliding window for each axis, as follows: where A max and A min are the maximum and minimum acceleration values in a 0.1 s sliding window. Next, the vertical acceleration, VA(t), is calculated as follows: where SV D (t) is calculated similar to the high pass filtered data, by using Equation (1), and G is the gravitational component. Finally, the Posture angle, Φ z (t), is defined as the angle between the VA(t) and gravity, as follows:

Support Vector Machines
Considering a linearly separable dataset {X i , D i }, i = 1, …, m, where X i is the input pattern for the ith example and D i is the corresponding desired output (1, or −1), a hyperplane could be identified as the decision surface. This hyperplane can be written as follows: where W is the coefficients' vector of the hyperplane function and b is the distance from the origin perpendicular to the hyperplane. The margin between the hyperplane and the nearest point is maximized and can be considered as a quadratic optimization problem: When W and b are rescaled, the point nearest to the hyperplane has a distance of 1/||w||. By the use of Lagrange multipliers α i ≥ 0, and the Kuhan-Tuker theorem, the solution is given by the following: Only a small fraction of the α j coefficient is nonzero. The corresponding pairs of X j are known as support vectors (SV) and they define the decision boundary. All of the other input patterns with corresponding zero α j values are rendered irrelevant.
If the data are noisy, there will, in general, be no separation in the feature space. To optimize the margin slack vector, we need to introduce slack variables to allow the margin constraints to be violated. We can rewrite the objective function of the quadratic optimization problem as the following: The solution given is similar to Equation (8) and the Lagrange multipliers are 0 ≤ α i ≤ C, i = 1, …, m. Finally, the hyperplane decision function for the input pattern vector X can be written as follows: By replacing the inner product X T j X with the kernel function K(X, X j ), the input patterns are mapped to a higher dimensional space [31]. In this higher dimension, a separating hyperplane is constructed to maximize the margin.
We used LIBSVM software to detect the falling ADLs. LIBSVM is an integrated software package for support vector classification, regression and distribution estimation [32]. In the present problem, the Gaussian radial basis function was used to construct the kernel function, which is given below: where parameter γ can be viewed as the radial's size, which is set at 5.3. The cost parameter C is 4.7.

Experimental Results
There are three experimental procedures, including simulated ADL-based young volunteers, continuous unscripted ADL without falling ADL-based young and elderly volunteers, and continuous unscripted ADL with three falling ADL-based young volunteers. The classification performances were examined based on the sensitivity, specificity, and total classification accuracy. The sensitivity is the number of true positive (TP) decisions divided by the number of actual positive cases; the specificity is the number of true negative (TN) decisions divided by the number of actual negative cases. The total classification accuracy is the number of correct decisions divided by the total number of cases.

Simulated ADL
In this experiment, the two-fold cross-validation was used on half of the recorded data for training and the second half of the data from the same individuals for testing. Another testing was used on half of the subjects for training and half of the subjects for testing. However, much personal equipment has to be calibrated before use for the user; therefore using the user's behavior to train personal equipment is a more feasible method.
Ten healthy young volunteers (Set 1 in Table 1), five male and five female, performed 10 simulated falling ADLs and 11 simulated non-falling ADLs. Each ADL was repeated 10 times for the first experiment. The volunteers ranged from 24 to 35 years (27.2 ± 3.6 years), with a body mass of 68-111 kg (84.27 ± 14.4 kg) and a height of 1.65 to 1.96 m (1.81 ± 0.1 m). Simulated falling ADLs and non-falling ADLs were organized and are numbered in Table 2. The height of the bed was 62 cm, and the height of the wheelchair was 50 cm. In simulated ADLs, we randomly chose five recorded signals of every ADL for each subject as the training input. Thus, the falling ADLs have 500 datasets, and the non-falling ADLs have 550 dataset. We extracted the ADL parameters described in Section 3 from the recorded signals. The training dataset were transformed into the format of LIBSVM. A training instance matrix is an m by n matrix. In this study, n is the ADL parameter's number. The number of training instances was equal to the sampled number of 1,050 selected datasets. The profile of the CV Fast parameter was used to mark the falling range. We found the maximum value of the CV Fast of each falling ADL. This value multiplied by 0.87 was set as the threshold. The elements of the training label vector were set to 1 when the training instance was over this threshold and were set to −1 when it was not over the threshold or belonged to a non-falling ADL. Table 3 shows the optimal training results with different parameters' combinations. We found that the combination of four parameters has the best results, with an accuracy of 99.14%, a sensitivity of 99.60%, and a specificity of 98.73%. Therefore, we used this SVM model to test the three experimental procedures. The first phase is the test of the simulated ADL.  Another 1,050 datasets were used to test the performance of the SVM. Table 4 shows the testing of the optimal results with different parameter combinations with the same criteria in training the SVM models. We also find that the results of four parameters are best, with an accuracy of 98.38%, a sensitivity of 97.40%, and a specificity of 99.27%. In addition, the pieces of equipment used in the test include one Intel i5 M480 2.67 GHz processor, 4 GB memory and Windows 7 operating system while the Matlab software 2009 version was used for development. The computation time was mainly spent on calculating the feature vectors as well as the kernel function and weight sum of the support vector. The experimental results showed that it takes about 1ms to calculate the feature vector, while the number of support vectors is about 10% of that of the training samples. Moreover, it takes about 3 ms to calculate the kernel function, so the computation time is about 4 ms which is less than the sampling time 5 ms. Therefore, this proves that the proposed method could be effective in real applications. To analyze what actions are easily misclassified, Table 5 shows the frequency of the false classification of each ADL and the accuracy. The action of slipping when ascending stairs has the worst classification. The reason likely has to do with the procedure of the simulated action.  Figure 2 shows the decomposition of the motion, with the subject walking up the stairs, slipping and forward and falling down with a knee flexion, and the body lying on the stairs. We could find that the falling acceleration of the body's center of gravity and the falling distances are all lower than the other falling ADLs. Moreover, in continuous action including three falling ADLs, the types of missing detection are very similar to the types of worse classification in the simulated actions when the action of slipping and ascending stairs was excluded. These results show that the SVM method has a unified approach for the falling ADLs.

Continuous Unscripted ADL without Falling Activities
In continuous unscripted studies, five elderly volunteers, one male and four female (Set 2 in Table 1), who ranged from 70 to 83 years (74.3 ± 2.9 years), with a body mass of 46 to 65 kg (54.5 ± 4.7 kg) and a height from 148 to 158 cm (152.7 ± 2.3 cm), wore the device continuously for up to one hour. In this group, one subject had apoplexy and one subject had fallen down twice and broken his right leg bone and left humerus. During this time, volunteers conducted their normal activities, including sitting, lying, walking, walking up and down stairs, and doing house work. These studies took place at the volunteers' homes. Second, the same young volunteers (Set 1 in Table 1), including three males and two females, who executed the simulated experiment also performed continuous unscripted ADL, the same as the elderly volunteers, for up to one hour. These studies took place at the volunteers' school.
There are two conditions under which continuous action contains only non-falling ADLs for one hour. The four parameter combination in the input vector was used to test the SVM model. The false positive (FP) quantity and false positive rate (FP/h) were utilized to show the performance. The results from the same five young volunteers are shown in Table 6. The total time is 385.1 minutes and the FPs occurred three times. The false positive rate is 0.48 FP/h. The result from the five elderly volunteers is shown in Table 7. The total time is 363.8 minutes and there is one FP. The false positive rate is 0.18 FP/h. Figure 3 shows the SV Total signal for the continuous action of the EF_3 subject. There is one FP during the act of walking down the stairs. The above results show that elderly people with slow and moderate activities have a lower FP rate than young people with intense and fast activities. On the other hand, the falling definition that we detected in this paper is different from that of previous studies. Therefore, the FP rate we obtained is relatively high than the threshold-based algorithm in unscripted continuous experiments.  Time(s)

Continuous Unscripted ADL
In continuous action, including three times falling ADLs, another ten young volunteers conducted this experiment (Set 3 in Table 2). Five males and five females, who ranged from 24 to 28 years  1 cm), continued to wear the device for 5 minutes. They not only conducted the non-falling ADLs, like the elderly volunteers, but also conducted falling ADLs three times during this period. Because the action of slipping and ascending stairs is a more difficult action, we only conducted nine falling ADLs. The results show, in Table 8, that FP is zero, but there are three false negatives (FN). We analyzed the TP and TN of each falling ADL in Table 9. Falling down from a wheelchair, rolling down from a bed, and falling down to a bed all have one missing detection. Figure 4(a) shows the SV Total signal for the continuous action of the CM_3 subject whose falling ADLs were falling down to a bed, falling down from a bed, and lateral falling down; these falling ADLs were all correctly detected. Figure 4(b) shows the SV Total signal for the continuous action of the CM_1 subject whose falling ADLs were falling down from a wheelchair, forward falling down, and falling down from a bed; these falling ADLs had one missing detection.

The Comparison with the Threshold-Based Algorithm
Previous studies have frequently used a threshold-based algorithm with the impact and posture after the fall as the most popular method for fall detection [10,11,[13][14][15][16]. The falling ADLs are described by calculating an action's parameters, such as the SV Total , CV Fast , VA, Φ z , or velocity, and defining their upper and lower falling thresholds with respect to the impact and the posture. A boxplot (see Figure 5 or Figure 6) was used to set the thresholds of these parameters. Moreover, previous studies have focused on the actions of standing and falling down as the falling ADLs. We know that these falling actions are all encompassed in the body's center of gravity as it quickly falls down, and the falling distances are the highest compared to the non-falling ADLs. Thus, the upper or lower fall threshold could be used to separate the falling ADL and the non-falling ADL, for which the sensitivity and specificity all are 100%. However, the falling ADLs must also include sitting on a bedside and slipping onto the ground, sitting in a wheelchair and slipping onto the ground, rolling down from a bed, or falling down to a bed. The falling acceleration of the body's center of gravity in these falling ADLs is not larger than the actions of standing and falling down, and the falling distances are close to the moving distances of the non-falling ADLs. Under these conditions, the threshold-based method is not expected to have very good results.   We used boxplots to define the upper and lower falling thresholds of four parameters that were used to separate the falling ADLs and the non-falling ADLs. The results of the simple threshold-based method in our study are shown in Table 10. The best threshold was the upper falling threshold of CV Fast , of which the specificity was 81.9%. Figure 5 shows the boxplot of CV Fast ; the upper and lower falling thresholds were 0.8 and 1.26, respectively. If we considered the upper and lower falling thresholds of all the parameters, the specificity only reached 82.5%. They were much lower than our proposed SVM method. If we only considered forward falling down, backward falling down, literal falling down and falling down with leg weakness as falling ADLs, then the results of the SVM could attain an accuracy of 100% in the training and testing. The simple threshold-based method was used to detect these falling actions, with the results shown in Table 11. The best threshold was the upper falling threshold of CV Fast , of which the specificity was 98.5% and the whole specificity was 98.6%. This result was very close to the results of previous studies. However, the result was also lower than the SVM method. Figure 6 shows the boxplot of CV Fast ; the upper and lower falling thresholds were 1.25 and 1.29, respectively.

Conclusions
We used the hyperplane of the SVM as the threshold for detecting the 21 ADLs, including 10 falling ADLs and 11 non-falling ADLs. The most successful parameter combination, SV Total + CV Fast + VA + Φ z , achieved a training sensitivity and specificity of 99.60% and 98.73%, and a testing sensitivity and specificity of 97.40% and 99.27%, respectively If the threshold-based method was used to detect the falling ADLs, then the specificity was only 82.5%. Thus, the conclusion is that when the parameters of falling and non-falling ADLs are very close, the results of the SVM method are better than the threshold-based algorithm. In unscripted continuous experiments, the FP rates were 0.48 FP/h, 0.18 FP/h and 0 FP/h for the same young volunteers, for elderly volunteers and for different young volunteers, respectively. In continuous action, including three times falling ADLs, the sensitivity also became 90%. On the other hand, the falling definition that we detected in this paper is different from that of previous studies. Therefore, the FP rate we obtained is relatively high than the threshold-based algorithm in unscripted continuous experiments.