Development of a Real-Time Activity Classification and Stability Assessment System for Activity of Daily Living

Our daily life is composed of various human movements known as activities of daily living (ADLs), which include standing, sitting, and walking. Under standard conditions, these activities can be performed during daily life without conscious thought. However, an individual’s ability to complete ADLs can be jeopardized by environmental, physical, and biological conditions such as a slippery surfaces, uneven floors, or degeneration of movement control due to factors including chronic disease or increased age. This ultimately leads to a decrease in quality of life [1,2]. Under these circumstances, providing real-time stability assessments for real-life situations becomes crucial [3]. Activity classification is a recently developed concept utilizing wearable [4-6] sensing technology to automatically recognize different activities [7,8]. To extract authentic information on ADLs in real-life situations, wearable sensing technologies must be unobtrusive, reliable, and capable of continuous, long-term measuring and recording. One type of biomechanical sensor, the accelerometer, has been used to measure both tilt angles under static conditions and applied acceleration along sensitive axes in dynamic situations; a combination which makes them superior to another current sensor technology [8-11].


Introduction
Our daily life is composed of various human movements known as activities of daily living (ADLs), which include standing, sitting, and walking. Under standard conditions, these activities can be performed during daily life without conscious thought. However, an individual's ability to complete ADLs can be jeopardized by environmental, physical, and biological conditions such as a slippery surfaces, uneven floors, or degeneration of movement control due to factors including chronic disease or increased age.
This ultimately leads to a decrease in quality of life [1,2]. Under these circumstances, providing real-time stability assessments for real-life situations becomes crucial [3]. Activity classification is a recently developed concept utilizing wearable [4][5][6] sensing technology to automatically recognize different activities [7,8].
To extract authentic information on ADLs in real-life situations, wearable sensing technologies must be unobtrusive, reliable, and capable of continuous, long-term measuring and recording.
One type of biomechanical sensor, the accelerometer, has been used to measure both tilt angles under static conditions and applied acceleration along sensitive axes in dynamic situations; a combination which makes them superior to another current sensor technology [8][9][10][11].
Wireless accelerometer systems have also been used to measure postural sway [12,13], gait parameters [14], activity intensity [15,16], and metabolic energy expenditure [17]. Advances in integrated microelectromechanical technology have further improved accelerometers, significantly reducing their size and cost [7,[9][10][11]. Based on these parameters, accelerometers have  [15,18]. In many studies, accelerometer was placed on the sacrum or waist, close to the center of mass, to classify whole body movements [18][19][20][21][22][23]. Numerous studies have been able to assess and quantify movement stability during specific activities such as balance control during quiet standing [5], gait performance [2,5], and stair negotiation [6]; however, these studies have little application to real-life situations due to restrictions placed upon them, including experimental protocol, influencing devices, and spatial constraints.
Moreover, ADLs are conducted consecutively in real-life situations, with none of the intervening time seen in experiments when assessment methods are altered between activities. Given these facts, a more practical method is required to assess movement stability during consecutive ADLs without experimental constrains.
The stated purpose of this paper is to demonstrate the feasibility of assessing movement stability using multiple integrated methods with a real-time activity classification algorithm. A methodology is proposed that could classify the types of ADLs and alter activity stability assessment methods for the simultaneous assessment of consecutive movements' stability, as shown in Figure 1. As previous studies have indicated movement control varies between individuals [9], a quantification of relative stability was proposed to measure each individual's stability levels in given activities through comparison with a self-selected normal activity. This research adopted well-defined windowing techniques, dividing recorded acceleration signals into small time segments termed "sliding windows" [10,16,18,20,24]. In real-time activity classification, the duration between each window refers to the temporal resolution of activity classification. Certain features inside each window were extracted to characterize information, quantifying differences between activities. Following this extraction, activities could be successfully classified by identifying whether or not the extracted features exceed pre-set threshold values [10,19]. Hz. Acceleration signals from each accelerometer were transmitted through the wireless network (ISB Band: 2400-2480 MHz) to the system base before undergoing analog transmission from the system base into our proposed system.

Classification Algorithm
Signal Calibration: Since the accelerometers produced analog signals in V (voltage) on each axis, signal was used to calibrate voltages into accelerations (g). Assuming that analog signal and acceleration value are linearly related, as shown in Figure 3, their relation can be described by equation (1) and rearranged into equation (2).
(1 ) (0 ) (0 ) (1) and (2) indicate that the calibrated acceleration (g) can be calculated using the recorded voltage value when the vertical axis is aligned with downward gravitational acceleration, perpendicular to the horizontal axis, resulting in respective accelerations of 1g and 0g.

Structure of Experiment-Based Classification and Stability
Assessment System: In order to develop a valid, reliable classification algorithm using recorded acceleration signals, our group conducted a pre-experiment involving thirty subjects who performed nine ADLs, including standing, sitting, lying (facing left, right and upward), walking, jogging, and ascending and descending stairs. Acceleration signals were segmented into 0.5s-length windows, with a 0.25s interval between windows (sliding length). An illustration of window and sliding length is shown in Figure 4. According to a previous study [20], static postures (including standing, sitting, and lying down) are distinguishable from dynamic activities (walking, jogging, ascending and descending stairs) using the standard deviation (S.D.) value of resultant acceleration (superposition acceleration from each of the three axes). The static/dynamic threshold of the S.D. was calculated at 0.04g. In application, activities with S.D. values greater than this threshold are considered dynamic, while those with lesser values are considered static. The mean sacral acceleration over sliding windows was used to further classify each static posture. Primarily, static postures were classified into two categories: upright (standing and sitting) and recumbent (facing left, right and upward). Table 1    Finally, while ascendings, the anterior/posterior oscillation is much larger than when walking. Thus, the mean value of sacral Z-acceleration was chosen as the identifying feature for stair ascension see Appendix 6. In order to eliminate outliers created by abnormal activities such as initial and final steps, thresholds were set to encompass 90% of the distribution of each selected activity feature see Appendix 4-6. These thresholds vary with movement control ability and are therefore different between individuals.
Accordingly, a pre-recording process for recording self-selected normal activity, as described above, is required for calculating individualized thresholds. Table 2 presents the chosen features and applied individualized thresholds based on pre-experiment.
Once classification rules were established for static and dynamic activities, three stability assessment methods were chosen for integration into our system. First, a 95% confidence radius of postural sway was integrated during quiet standing, having been proven a reliable and sensible parameter in past studies [25]. Second, the RMS value of resultant sacral acceleration, widely investigated and discussed in prior research [2], was integrated during walking. Finally, the variance value of anterior/posterior and medial/lateral acceleration, previously applied and proven [6], was integrated during stair negotiation (ascending and descending).
In order to quantify the results of the stability assessment, we  The acceleration from both the sacrum and thigh were segmented into windows for further evaluation with this process.
Before each trial, a pre-recording process was performed to record chosen feature values from the individual's self-selected normal activities. The system then automatically extracted individualized thresholds and relative stability assessment standards from this data, as shown in Table 3. The overall procedure of the developed system is illustrated in Figure 6. First, two accelerometers were calibrated by aligning axes in the downward and horizontal directions. Second, self-selected normal activities (including standing, walking, jogging, and ascending and descending stairs) were pre-recorded, and individualized thresholds and relative stability assessment standards were calculated from extracted records. These values were used to normalize stability assessment results. Finally, we conducted real-time classification, comparing each activity's chosen feature with pre-determined (for static postures) and individualized (for dynamics activities) thresholds.
Stability assessments were performed by normalizing current stability levels, comparing current values to their relative stability standards based on classified activity types.

Experimental Setup
Five healthy, young and male subjects

Standing
In the first run-through, the five subjects performed the ADL series without constraints. During the second run-through, several types of environmental disturbances were introduced, as listed in Table 4. Subjects were instructed to perform each activity for at least five seconds.

Data Analysis
To quantify the classification accuracy provided by developed system, the concepts of sensitivity (true positive rate) and specificity (true negative rate) were introduced. Figure 7 presents a sample confusion matrix of actual activities and classified results for a hypothetical comparison test in which only three types of ADLs would be performed and classified. Activity A can be used as an example: sensitivity is defined as the probability that the developed system identifies activity A correctly during performance. Specificity is defined as the probability that the developed system identified non-A (activity B or C), given that the subject were actually performing non-A (activity B or C). Equations for sensitivity and specificity are listed in (4) and (5).

Experimental Results
Classification Accuracy: The classification accuracies, provided by our system during activity performance without environmental disturbances, are presented in Table 5. The developed system provided over 95% sensitivity with nearly 100% specificity for static postures, and approximately 90% sensitivity with greater than 95% specificity during dynamic activities.

Relative Stability Results with Environmental Disturbances:
In this study, normalized results represent how similar the current activity and self-selected normal activity were, as calculated by equation (3). Normalized values closer to zero indicate greater similarities between self-selected normal and current activities.  Table 5 presents the sensitivity and specificity evaluated in This conclusion was supported by previous studies, which have indicated that movement control ability varies between individuals [9], implying that using fixed stability standards to assess dynamic activities in different individuals is inappropriate and impractical. A pre-recording process, measuring self-selected normal activity and quantifying individualized thresholds, is crucial for this system.  Normalized results were consistent with expectations, showing that forward reaching, which pushes the center of mass (COM) toward the boundary of the base of support (BOS), caused larger postural sway than upward reaching. During walking, normalized results were greater than 0 during all disturbances except for walking over a slippery surface. This finding coincided with previous studies, which have indicated that subjects tend to apply conservative strategies including shortening step length and lowering impact force and angle during heel strike to avoid of slipand-falls incidents [26]. This study explored the possibility and feasibility of applying existing assessment methods to consecutive ADLs by automatically switching assessment methods based on the classification results. To determine the efficacy of this methodology, proposed in Figure 1, it was essential to investigate system performance through observation of the normalized relative stability values during consecutive ADLs. The upper part of Figure 9 presents these normalized results as assessed by single method during consecutive activities. For a more comprehensive description of this strategy, observe the 95% confidence radius of postural sway during performance of undisturbed activities.

Discussion
When the subject performed static upright standing, the normalized value was close to zero as expected. However, following standing, the subject performed dynamic activities including walking (W) and ascending (U) and descending (D) stairs. During these, recorded normalized values rocketed to approximately 100. This indicated current activity levels a hundred times higher than static standing. Initially, this seems illogical, as subjects were still performing normal activities during walking and stair negotiation. This phenomenon can be attributed to a mismatch between the activity being performed and the stability assessment method being applied. Our activity classification system was built to eliminate this mismatch by identifying types of activity and alternating assessment methods automatically. The lower part of Figure 9 presents the normalized value as calculated by switching assessment methods during consecutive activities. Obviously, the classification system was able to correctly identify types of ADL while subjects performed each activity without disturbance, and correctly applied the corresponding assessment methods.
The normalized value was kept between ±5 and oscillated around 0, implying normal activities were being performed. Therefore, by comparing two graphs in Figure 9, it can be seen that integrating an automatic activity classification system with multiple stability assessment methods is feasible and valid. In the lower part of Figure 9, fluctuations in normalized value were observed during transitions between activities. This may suggest that the risk of falling or loss of balance is higher during the transition phase than in a continuous activity. This finding coincides with definition of "initial gait" found in previous studies, which is distinct from a stable gait [27]. Unfortunately, it is impossible to continue performing one ADL while simultaneously performing or transferring to another; and as such, these destabilizing transition phases are unavoidable.

Conclusion
In this article, we presented a new methodology for assessing activity stability levels during ADLs and consecutive activities in real-time, based on the data of two triaxial accelerometers. The novel classification algorithm requires a pre-recording of subjects performing self-selected normal activities to extract individualized thresholds and stability assessment standards. During real-time evaluation, the developed system provided over 90% accuracy and successfully quantified subjects' level of stability during environmental disturbances. Moreover, our system proved effective during consecutive ADLs and suitable for utilization in real-life situations. We propose for consideration in future investigations the improvement of hardware, optimizing transmissions and processes, and functional integration, involving such aspects as energy expenditure or long-term monitoring.