Mobile Quantification and Therapy Course Tracking for Gait Rehabilitation

07/07/2017 ∙ by Javier Conte Alcaraz, et al. ∙ 0

This paper presents a novel autonomous quality metric to quantify the rehabilitations progress of subjects with knee/hip operations. The presented method supports digital analysis of human gait patterns using smartphones. The algorithm related to the autonomous metric utilizes calibrated acceleration, gyroscope and magnetometer signals from seven Inertial Measurement Unit attached on the lower body in order to classify and generate the grading system values. The developed Android application connects the seven Inertial Measurement Units via Bluetooth and performs the data acquisition and processing in real-time. In total nine features per acceleration direction and lower body joint angle are calculated and extracted in real-time to achieve a fast feedback to the user. We compare the classification accuracy and quantification capabilities of Linear Discriminant Analysis, Principal Component Analysis and Naive Bayes algorithms. The presented system is able to classify patients and control subjects with an accuracy of up to 100%. The outcomes can be saved on the device or transmitted to treating physicians for later control of the subject's improvements and the efficiency of physiotherapy treatments in motor rehabilitation. The proposed autonomous quality metric solution bears great potential to be used and deployed to support digital healthcare and therapy.



There are no comments yet.


page 2

This week in AI

Get the week's most popular data science and artificial intelligence research sent straight to your inbox every Saturday.

I Introduction

Developing an autonomous system to assess rehabilitation progress and sport performance is of great importance in sport and clinical treatment. Usually the rehabilitation process is performed in clinics and hospitals where the patients have to accomplish different treatments and trainings. Providing an ambulatory gait system for automatic recognition and assessment of human movement patterns is of great benefit in high-quality and flexible patient care as well as on-line follow-up of the treatment’s success by healthcare providers. The use of new technologies in the health care and sport sectors is common [1]. There are some applications to track, for example, the course of running training and the technique of the athletes [2, 3]. Nevertheless, there are no such applications for the rehabilitation process. Due to an aging society, increasing industrialization, and environmental factors the number of patients with knee/hip operations will grow rapidly in the coming decades [4]. Motivated by this background, the need for an autonomous quality grading system solution bears a great potential to be used and deployed to support digital healthcare and therapy. In this direction, in this paper different methods in time, frequency and time-frequency domain are utilized to extract relevant gait features. The classification accuracy of attained features is investigated using the LDA, PCA and NB algorithms. A grading system is established enabling to quantify the gait rehabilitation progress.
The paper is organized as follows. In Section II the methodology for the sensor platform, data collection and the mobile platform are presented. Section III introduces the applied methods for feature extraction and selection as well as the classifiers used in this study. In Section IV different grading systems are explained. In Section V the results of the classifiers and grading systems are presented. Finally, the main outcomes of this work are concluded in Section VI.

Ii Measurements and Mobile platform

In this section, we introduce the measurement setup we used in this study. In particular, we present the hardware part, consisting of different motion sensors attached to the lower part of the body, and the software part, which is an Android-based application. Moreover, we discuss the way that data were collected for further processing.

Ii-a Sensor Platform

We use a set of seven IMU integrated into a sensor platform developed by the company Shimmer. In detail, we utilize the sensor platform (Shimmer 3)[5], which is capable of providing real-time motion sensing. The data acquisition is performed through Bluetooth and transmitted to an Android application, which we developed for this purpose. The sensor units were attached to the feet, lower legs, upper legs and Pelvis, as seen in Fig. 1. To provide comparable conditions, the same sensors were attached at the same positions for each subject, who can be either patient or a healthy participant111In this paper, we use the terms subject and participant interchangeably.. The data was captured synchronously at a sampling rate of 100 Hz. The sensor configuration is depicted in Table I

. The transmitted data was processed in real-time to estimate of the biomechanical parameters of the lower body, feature extraction, classification, and quality assessment.

Sensor type Range Resolution
3DoF Accelerometer g (m/) 16 bit
3DoF Gyroscope dps () 16 bit
3DoF Magnetometer Gs (100 T) 16 bit
TABLE I: Sensor configuration for data acquisition
Fig. 1: Sensor setup for data capturing.

Ii-B Data Collection

The data was acquired from 15 patients, with an age of 655 years, who had knee/hip operations. For a testing purpose, the data of a reference group, consisted of 15 healthy persons with an age of 336 years, was also collected. After attaching the sensor to the lower body, the calibration of the sensor system was performed during a standing phase where the joint angles were set to 0. Afterwards, the measurements in a distance of 10 m straight walking were performed at the preferred speed of the patients and control subjects. Additional information such gender, age, weight and time after the operation were gathered. Seven trials were performed for each subject in each group starting with the left foot.

Ii-C Android Application

The developed Android application was designed based on the Android programming principles and the basic features and design concepts of Shimmer [6]. The connection between the IMU and the smartphone is performed over the Bluetooth API and threads. These threads establish and maintain the connection with the sensors. As depicted in Fig. 2, the handler accomplishes the inter-thread communication using messages that contain the information of accelerometer data and the algorithm results. The second step is the real-time processing. In order to avoid blocking the UI and to ensure the proper function of the application, a background service is executed, where the gait patter algorithms are running and all calculations are performed. All algorithms utilize a sample-based moving window to collect and process the accelerometer and joint angle data. The last step is the visual feedback by graphical representation of the feature values and quantification progress. It is possible to choose and display a certain set of signals and features on the UI. Additionally, the application menu offers the facility to configure the sensors.

Fig. 2: Design concept of the Android application

Iii Feature extraction and Classification

As mentioned earlier, the main purpose of this paper is to develop a sensor-based grading system for gait analysis to distinguish between healthy and unhealthy persons. To that end, in this section we describe the signal processing steps applied on the data collected from the participants. Before proceeding, we remark that all signal processing tasks are performed in a real-time sense.

Iii-a Joint Angle Estimation

Joint angle estimation is known to be an important biomechanical parameter to learn the walking pattern of a person. To perform such an estimation, the sagital plane information can be accomplished using the difference between the gyroscope and acceleration angles (Fig. 3

). Even with very well calibrated sensors, the joint angle obtained from the integration of angular velocity will drift after a short period of time. This drift is normally due to the temperature bias of the gyroscopes. To compensate for the drift error, an indirect KF is applied. The state vector

of the KF is defined as , where and denote the error of the joint angle and the bias of the gyroscope measurement, respectively. The KF uses the angle of acceleration measurements () as a correction to the already estimated joint angle based on the integration of the gyroscope measurement () [7]. The KF estimates the joint angle error and subtracts it from the integrated angle to get the corrected estimation. The related state transition matrix and the measurement matrix of the KF are given by

Fig. 3: Block diagram of the indirect Kalman Filter.

where is the sampling period of the IMU. In Fig. 4, we demonstrate the estimation angle when a participant is walking in a straight line for a distance of 10 m. We further show the result for a data collected from another sensor platform, which we denote as reference. It is clearly shown that both results have a good matching, which means that the angle estimation algorithm discussed herein is independent of the hardware platform used for data collection.

Fig. 4: Measured Knee joint angle compared to the reference system.

Iii-B Feature Extraction and Selection

Now having the joint angle estimations, we perform the feature extraction step where we utilize the acceleration signals from the sensors and the KF output signals. Prior to that, a rotation of the acceleration signals from the sensor frame S into the global frame G is required [8]. In principle, a three-dimensional vector can be rotated by a quaternion , using the following relationship [9]:


where and denote the quaternion multiplication and the conjugate operation, respectively. The quaternions are calculated using an optimised gradient-descent algorithm described in [9]. Above, and are the same acceleration described in the sensor frame and the global frame, respectively. After removing the gravity component, the acceleration signal is filtered using a Butterworth low-pass filter with a cuttoff frequency of 7 Hz to reduce the noise and the high frequency components [10].

In order to develop a reliable grading system and an accurate classification, different feature extraction methods are considered in the literature. While time domain features specify the signal shape and statistics as reported in [11, 12], frequency domain features are mainly based on the periodic structure of the data, such as spectral properties and entropy [13]. In this paper, the main concern is made on features that can be extracted from walking data as listed in Table II. As we computed the features for each accelerometer sensor, direction and joint angle, this procedure results in total features, where ’directions’ refer to the Cartesian coordinates of the global frame.

Name Type Description
MI Time analysis Characterization of the movement intensity
PAF Time analysis Measure of the signal symmetry
Step period Time analysis Time between steps
Stride period Time analysis Time between two steps of the same side
Regularity Time analysis Characterizes the signal rhythmic and periodicity
APC Frequency analysis Mechanical power of the signal[12]
SE Frequency analysis Derived from information theory, a measure of the uncertainty of a signal[14]
SMNR Frequency analysis Characterizes the random variation relative to the periodicity [15]
WE Time-Frequency analysis Measure of the signal distortion and provide knowledge on the dynamic process
TABLE II: Signal Features

The features mentioned above can be treated as significant if they allow for a differentiation between normal and abnormal gait. The utilization of the paired t-test allows to distinguish the relevance of the features

[16]. In this part of the study two groups, each consisting of eight subjects, are involved. The first group includes subjects with normal gait patterns, while the second group includes subjects with knee and hip operations. The above-mentioned features are calculated for all the subjects and those features with p-values less than are considered significant [16]. Subsequently, the optimal feature set is obtained using SNR ranking. The SNR for each feature can be obtained from [17]:


where and are the mean of features for subjects with the normal and abnormal walk, respectively. and are the corresponding standard derivations. Intuitively, a more efficient classification is expected to be achieved using features of higher SNR values. Subsequently, after several trails we selected a total of 26 features with high SNR to be used for the further investigations in this paper.

Iii-C Classification

Based on the final feature set, a classification approach is applied such that the goal is to classify each participant has either a normal or an abnormal gait pattern. In this context, supervised and unsupervised classification schemes are considered. As a result of the theorem of “No Free Lunch”[18], there is no optimal classifier. Alternatively, three different classifiers are evaluated in this study: LDA, PCA and NB. The final feature set is used for the classification of eight patients and eight control subjects in the training phase to define the decision boundaries for the group separation. Once the decision boundaries are specified, the test data from seven patients and seven control subject is used to verify the classification efficiency.

Classifier Accuracy Sensitivity Specificity
PCA 85.7% 85.7% 85.7%
LDA 100% 100% 100%
NB 100% 100% 100%
TABLE III: Classification results

Iv Grading System

After classifying the gait pattern into normal or abnormal, in this section a grading system is proposed to quantify how normal or abnormal each patient is. This grading system can be used to track the rehabilitation progress of patients. Based on the final feature set, three different grading systems for the rehabilitation tracking are proposed. The basic concept of grading system is based on the MRC, performed by


where is the number of the selected features, is the feature value, and is the weight of the contribution of each feature [19]. The first grading system utilizes the SNR values as the weight vector. The two other grading systems are based on the separation principal used by LDA and PCA. Here, the grading value G, is calculated using the eigen vectors of the LDA/PCA as the weight values instead of the SNR values. LDA and PCA mainly differ in the related orthogonal basis used for. LDA looks for a feature space on which to project all data, such that the samples are maximally separated. PCA finds a feature space based on the festures’s deviation from the global mean in the primary directions of variation in feature space [20].

Fig. 5: Efficiency of the grading system based on SNR
Fig. 6: Efficiency of the grading system based on LDA
Fig. 7: Efficiency of the grading system based on PCA

V Results

In this section, we validate the performance of the proposed grading systems. For this purpose, we first have a training phase in which the grading boundaries are defined in terms of maximum, minimum and average values, i.e., , , and as shown in Fig. 5 to 7. Next, a test phase takes place in which we evaluate the performance of the classification and the grading systems. Table III compares the three considered classifiers in terms of the accuracy, sensitivity, and specificity. These results are also reflected in Fig. 5 to 7, where the participants with grades between and are considered as healthy (control) ones. Finally, Fig. 8 depicts the time correlation between the grades and the days after the operation. It is clearly seen that the grades increase with the days after the operation with all considered grading systems. This means that the proposed grading systems are able to objectively quantify the gait performance and the rehabilitation progress based on the final features set derived from the gait analysis. Moreover, it is possible to provide a numerically performance comparison of patients. From Fig. 5 to 8, we can conclude that the LDA-based grading system is preferred for two reasons: First, it has a high classification accuracy, and second, it has the highest grading-time correlation, and hence it has a better tracking capability. Additionally, we can obtain an individual profile by calculating the grade of each feature separately.

Fig. 8: Correlation between the grades and the time after the operation.

Vi Conclusion

The main objectives investigated in this work are twofold: First, differentiation between patient and control group to track the therapy course. Second, objective quantification of the subject performance. For both of these tasks a high system accuracy is required. Therefore, we proposed an application for IMU platforms which is able to precisely quantify the rehabilitation progress associated with knee/hip operations and to objectively classify between the patient and control groups. Our proposed approach allows a mobile and comfortable therapy. The assessment of therapy methods, the verification of the accuracy for the proposed grading system and an extended statistical analysis is the subject of future investigations. The final goal is to come up with a medically approved system that can be implemented into everyday clinical practice.


This work is carried out in the scope of the Central Innovation Programme SME research project in cooperation with the company MediTECH Electronic GmbH and the Institute of Sports Science of Leibniz Universität Hannover.


  • [1] R. LeMoyne, T. Mastroianni, M. Cozza, C. Coroian, and W. Grundfest, “Implementation of an iphone as a wireless accelerometer for quantifying gait characteristics,” in 2010 Annual International Conference of the IEEE Engineering in Medicine and Biology, Aug 2010, pp. 3847–3851.
  • [2] Y. S. Can and M. Y. Dönmez, “Sport sense: A mobile sensor data collection, labeling and display application for sport centers,” in 2015 23nd Signal Processing and Communications Applications Conference (SIU), May 2015, pp. 624–627.
  • [3] M. Kos and I. Kramberger, “A wearable device and system for movement and biometric data acquisition for sports applications,” IEEE Access, vol. PP, no. 99, pp. 1–1, 2017.
  • [4] Centers for Disease Control and Prevention (CDC) and others, “Racial disparities in total knee replacement among medicare enrollees–united states, 2000-2006.” MMWR. Morbidity and mortality weekly report, vol. 58, no. 6, p. 133, 2009.
  • [5] “Shimmer3: Wireless sensor platform,”, accessed: 2017-04-07.
  • [6] “Android developer,”, accessed: 2017-04-07.
  • [7] H. Saito and T. Watanabe, “Kalman-filtering-based joint angle measurement with wireless wearable sensor system for simplified gait analysis,” IEICE Transactions on Information and Systems, vol. E94.D, no. 8, pp. 1716–1720, 2011.
  • [8] J. Kuipers, Quaternions and Rotation Sequences: A Primer with Applications to Orbits, Aerospace, and Virtual Reality, ser. Princeton paperbacks.   Princeton University Press, 2002.
  • [9] S. O. H. Madgwick, A. J. L. Harrison, and R. Vaidyanathan, “Estimation of imu and marg orientation using a gradient descent algorithm,” in 2011 IEEE International Conference on Rehabilitation Robotics, June 2011, pp. 1–7.
  • [10] B. Najafi, K. Aminian, A. Paraschiv-Ionescu, F. Loew, C. J. Bula, and P. Robert, “Ambulatory system for human motion analysis using a kinematic sensor: monitoring of daily physical activity in the elderly,” IEEE Transactions on Biomedical Engineering, vol. 50, no. 6, pp. 711–723, June 2003.
  • [11] A. Avci, S. Bosch, M. Marin-Perianu, R. Marin-Perianu, and P. Havinga, “Activity recognition using inertial sensing for healthcare, wellbeing and sports applications: A survey,” in 23th International Conference on Architecture of Computing Systems 2010, Feb 2010, pp. 1–10.
  • [12] J. C. Alcaraz, S. Moghaddamnia, and J. Peissig, “An android-based application for digital gait performance analysis and rehabilitation,” in 2015 17th International Conference on E-health Networking, Application Services (HealthCom), Oct 2015, pp. 640–643.
  • [13] A. Avci, S. Bosch, M. Marin-Perianu, R. Marin-Perianu, and P. Havinga, “Activity recognition using inertial sensing for healthcare, wellbeing and sports applications: A survey,” in 23th International Conference on Architecture of Computing Systems 2010, Feb 2010, pp. 1–10.
  • [14] S. Haykin, Communication systems.   New York : Wiley, 1978.
  • [15] S. Moghaddamnia, J. Peissig, G. Schmitz, and A. O. Effenberg, “A simplified approach for autonomous quality assessment of cyclic movements,” in 2013 18th International Conference on Digital Signal Processing (DSP), July 2013, pp. 1–5.
  • [16] D. Montgomery and G. Runger,

    Applied Statistics and Probability for Engineers

    .   John Wiley & Sons, 2010.
  • [17] M. Yang, H. Zheng, H. Wang, S. McClean, J. Hall, and N. Harris, “Assessing accelerometer based gait features to support gait analysis for people with complex regional pain syndrome,” pp. 48:1–48:7, 2010. [Online]. Available:
  • [18] R. O. Duda, P. E. Hart, and D. G. Stork, Pattern Classification (2Nd Edition).   Wiley-Interscience, 2000.
  • [19] S. Moghaddamnia, J. Peissig, G. Schmitz, and A. Effenberg, “On the efficiency of an autonomous cyclic motion grading system,” in Statistical Signal Processing (SSP), 2014 IEEE Workshop on, June 2014, pp. 512–515.
  • [20] S. Theodoridis and K. Koutroumbas, Pattern Recognition, Fourth Edition, 4th ed.   Academic Press, 2008.