Robust Foot Clearance Estimation Based on the Integration of Foot-Mounted IMU Acceleration Data

This paper introduces a method for the robust estimation of foot clearance during walking, using a single inertial measurement unit (IMU) placed on the subject’s foot. The proposed solution is based on double integration and drift cancellation of foot acceleration signals. The method is insensitive to misalignment of IMU axes with respect to foot axes. Details are provided regarding calibration and signal processing procedures. Experimental validation was performed on 10 healthy subjects under three walking conditions: normal, fast and with obstacles. Foot clearance estimation results were compared to measurements from an optical motion capture system. The mean error between them is significantly less than 15% under the various walking conditions.


Introduction
Foot clearance, defined as the foot elevation during the stride phase, is an important indicator of gait quality and safety in subjects with disabilities [1]. The minimum foot clearance is one of common gait deviations in people with stroke, which increase the risk of unsuccessful foot clearance (trips) and then of falls [2,3]. In a previous study, we showed that this parameter could be used to adapt the applied functional electrical stimulation in the context of drop foot correction in subjects with post-stroke hemiplegia [4]. In the present study, foot clearance (FC) is defined as the continuous heel height relative to the ground, whereas in other previous studies, maximum or minimum FC values during the stride phase were used instead [5].
Optical motion capture systems (OMCS) are the most commonly-used devices for measuring foot elevation during walking, providing high accuracy and direct measurement of the position of reflective markers located on body landmarks. However, these devices present multiple drawbacks, such as limited operating space and high cost, making their clinical use technically and financially difficult to implement.
The use of wearable devices, such as inertial measurement units (IMU) presents a promising alternative for gait analysis in outdoor and clinical contexts [6,7]. Such devices typically include three-axis accelerometers, three-axis gyroscopes and three-axis magnetometer sensors.
Raw data provided by IMU sensors requires complex post-processing, creating a source of errors in the estimation of IMU displacement and orientation. A major IMU raw data processing issue is the integration of acceleration signals and angular velocity signals (provided by gyroscopes). It is well known that the numerical integration of such data suffers from a high drift error rate, introducing significant errors in the estimation of IMU position and orientation. Magnetometers, on the other hand, requirements [4], our goal was to obtain a foot clearance estimation error of less than 2 cm (minimum foot clearance [3]) and to make our method robust to misalignment of IMU axes and foot axes. The proposed IMU-based foot clearance estimation algorithm is detailed in Section 2 below. Experimental setup and validation methods are described in Section 3. Estimation results and the performance evaluation are presented and discussed in Section 4. Conclusions and future prospects are given in Section 5. Figure 1 shows sagittal and frontal views of IMU placement for foot clearance estimation (FCE). Possible misalignment of the IMU with respect to the vertical axis is also illustrated ( Figure 1b). As mentioned earlier, we defined foot clearance as the continuous heel clearance (Figure 1a). Estimation of ankle joint clearance (where the IMU is placed) is adequate, since there is only one bias to be added, corresponding to the distance between IMU-based estimated clearance and heel clearance. Moreover, this ankle joint clearance is most appropriate in the context of drop foot correction [4].   Figure 2. IMU-based foot clearance estimation algorithm.

IMU-Based Foot Clearance Estimation
The proposed FCE algorithm (illustrated in Figure 2) uses only acceleration in the global frame. However, since acceleration is measured in the sensor frame, gyroscope-based angular rate data are used to estimate foot acceleration in the global frame. Each step of the method is detailed below.

Accelerometer Calibration
An efficient calibration procedure is essential for ensuring accurate accelerometer-based acceleration measurement. The proposed calibration procedure is based on a previous study [25] and consists of optimizing the three-axis accelerometer output, such that, under stationary conditions, the norm of the acceleration vector is equal to the norm of the gravity vector (i.e., 9.81 m/s 2 ). For this purpose, the IMU sensor was placed in N (>20) different random orientations, and each corresponding acceleration vector was measured under static conditions. The mathematical model of calibrated accelerometer output is described as follows [25]: where A is the calibrated acceleration, A m is the measured acceleration prior to calibration and S and B are, respectively, the scale matrix and bias vector identified during the calibration procedure. S and B were identified using a Newton iterative optimization algorithm that minimizes quadratic errors between the norm of the calibrated acceleration vector and the norm of the gravity vector for each static orientation. This calibration was performed once, and the resulting calibration matrices (S, B) were used to correct measured acceleration data ( Figure 2) using Equation (1).

Data Filtering and Bias Removing
Since IMU data were post-processed offline, there were no real-time constraints. We therefore chose a data acquisition frequency of 200 Hz. However, frequency sampling should be optimized for future real-time applications, so as to ensure sufficient measurement quality and compliance with real-time constraints.
Three-axis gyroscope data were band-pass filtered between 0.001 Hz and 5 Hz using a first-order Butterworth filter to remove constant and high frequency components. The angular rate in the stationary state (subjects were asked to remain static at the start of each trial) was considered as a bias and, therefore, automatically detected, quantified and removed from the entire gyroscope signal. For three-axis acceleration data, a first-order low-pass Butterworth filter with a 10-Hz cutoff frequency was applied to remove high-frequency noise. However, the bias was not subtracted from the acceleration signal at this stage, since it corresponds to the gravity acceleration, which changes according to IMU orientation.

Gyroscopic Data Integration
As illustrated in Figure 2, processing of gyroscopic data is crucial for processing of gravity-free acceleration (due to the movement only), since the measured acceleration also includes the gravity effect. Therefore, proper processing and integration of gyroscopic data was required to expect proper acceleration-based displacement estimation (Section 2.4).
The filtered angular rate Sθ (see Figure 2) was then integrated using a 3D strapdown integration method [11,26]. This integration method has the advantage of considering rotations around all three axes, since IMU rotation exclusively in the sagittal plane cannot be ensured during walking. This is based on a recursive equation (Equation (2)) that updates the 3D orientation matrix of the IMU: where G R i is the 3D orientation matrix in the global frame at sample i, the initial transformation matrix G R 0 is the identity matrix (I), ∆t is the time interval between two successive samples (i − 1, i) and Sθ i is the angular rate vector at sample i.
[a×] is the skew-symmetric matrix representing the cross-product operator, such that: where a x , a y , a z are the elements of a.
At each time instant, the transformation matrix G R i represents the IMU frame transformation with respect to the initial IMU configuration. In practice, IMU orientation is never absolutely vertical in the initial position, and as a result, the initial frame is not the global frame. Therefore, in order to define the transformation matrix with respect to a global frame independently of initial placement, we made the initial matrix G R 0 equal to a transformation matrix between the initial IMU position and the global frame (vertical orientation).
This initial transformation matrix consists of a rotation about the Z-axis (pitch) with an angle of θ z0 , followed by another rotation about the Y-axis (roll) with an angle of θ y0 , where the sign of rotation is as shown in Figure 1. This initial transformation matrix is therefore defined as follows: where θ z0 and θ y0 were estimated based on the projection of the gravity vector on the three axes [11], measured by accelerometers during the stationary period, i.e., prior to the start of movement.
Considering the order of rotation defined above (Equation (4)), these initial angles (tilt angles) were calculated using the following equations: where S G = S G X S G Y S G Z is the gravity vector measured on the three IMU axes during the stationary period. Based on our measurements, the drift in gyroscopic data integration was neglected, and as a result, no drift cancellation was required at this level.

Displacement Estimation
The proposed displacement estimation method is based on double integration of foot acceleration data on the global frame axes. To achieve this objective and thereby overcome the integration drift problem, the following steps are applied.

3D Frame Transformation and Gravity Removing
It is well known that IMU-based acceleration measurements correspond to the acceleration in the sensor frame, whereas the useful acceleration should be the acceleration with respect the global frame. Moreover, the measured acceleration includes gravitational acceleration, which should be removed to obtain gravity-free acceleration due to movement only. Therefore, the acceleration in the sensor frame S A was first transformed to the global frame ( G A in Figure 2) using the strapdown transformation matrix (Equation (2)): Gravitational acceleration was then removed to obtain the gravity-free acceleration in the global frame G a: To obtain the vertical foot displacement (foot clearance), the vertical component of the gravity-free acceleration G a needs to be integrated twice (Equation (7)).

Foot-Flat Phase Detection
One of the main problems with the integration of acceleration data is the significant integration drift, which is further increased by double integration. The proposed solution to overcome this problem is an adaptation of the ZVU principle [27]. The proposed ZDU principle consists of detecting when the foot is flat on the ground and setting the vertical velocity and displacement to zero. These particular events are detected by the foot-flat phase detection algorithm (illustrated in Figure 2), which uses the angular rate about the Z-axis ( Sθ z ) to automatically detect when the foot is flat on the ground [20,28]. Such events are detected based on the detection of the minimum angular velocity at each stride cycle. This foot-flat phase corresponds to the period of time between heel-strike and heel-off.

Drift Cancellation
The foot-flat phase detection algorithm segments walking into several strides. This segmentation avoids the accumulation of drift error between different strides. However, at the end of each stride, a local drift (occurring only during a current stride) appears as an error between integrated and theoretical data, corresponding to the foot-flat phase. In the proposed method, we applied a drift cancellation on the vertical foot velocity for each stride, based on the error accumulated at the end of each stride and the zero vertical velocity assumption. This correction used the following model [19]: where V x (t) is the vertical foot velocity obtained using trapezoidal integration of gravity-free acceleration on the X-axis ( G a x ), V x (T) is the calculated velocity at the end of the stride phase, t is the time instant of the current stride, T is the entire duration of the current stride and V x_corrected (t) is the vertical foot velocity after correction for the entire stride phase.
To estimate the vertical foot displacement (foot clearance), we first integrated the driftless corrected vertical velocity (V x_corrected ) and then applied the same drift cancellation on this vertical foot displacement, assuming zero foot clearance at the end of the stride (foot-flat phase). This second correction used the following model: where D x (t) is the vertical foot displacement obtained by trapezoidal integration of the corrected velocity V x_corrected (t), D x (T) is the calculated displacement at the end of the stride phase and D x_corrected (t) is the vertical foot displacement after correction during the stride phase, corresponding to the estimated foot clearance. Since the drift cancellation was applied during the swing phase, the foot clearance was set to zero during the foot-flat phase in agreement with our assumptions.

Experimental Validation
For validation of our foot clearance estimation method, an experimental procedure was applied on both feet of ten healthy participants whose characteristics are summarized in Table 1 below. Two IMU sensors (HikoB Fox c Villeurbanne, France) were strapped to both feet of each subject (at the ankle joint), as shown in Figure 3.
Each subject stood upright, remained still for a few seconds and then walked a distance of approximately 10 m on flat horizontal ground. Each subject covered this distance four times walking normally, four times walking fast and two times crossing obstacles. The fast walk was to test a higher level of acceleration and then to increase the drift level. The purpose of walking with obstacles was to test the estimation of a higher level of clearance and nonsymmetrical and nonperiodic walking. The obstacle heights range from 20 cm to 50 cm and were placed to influence normal walking, increase the foot clearance and test the robustness of our estimation method. As illustrated in Figure 3, foot clearance estimation was validated with a BONITA VICON motion capture system, using reflective markers located on the IMUs. Measured and estimated peak foot clearance values were automatically detected and used to synchronize the two datasets. Foot clearance data for the entire movement, measured with the motion capture system and estimated using the proposed method, was then compared (Figure 3). Subsequently, the RMS value of foot clearance errors (RMSE) was quantified for the evaluation of foot clearance estimation performance, using the following criterion: where X m and X e are respectively the measured and estimated foot clearance, discretized to Nsamples throughout the walking cycle duration. This number of samples (N) was associated with the walking cycle duration and discretization (sampling) frequency, i.e., approximately 200 Hz for both VICON and IMU signals.
To compare the foot clearance estimation performance under different walking conditions, it was necessary to calculate another error criterion, since foot clearance values obtained during walking with obstacles were three-times higher than during normal walking. A normalized RMSE percentage value was therefore calculated for each subject and walking type by normalizing the RMSE with respect to the maximum foot clearance during the current walking test as follows: Figure 4 shows a typical set of foot clearance measurements obtained with a VICON motion capture system and compared to estimated values generated by the proposed algorithm (Section 2). Normal and fast walking data (Figure 4a,b) was obtained on the left and right foot, respectively, of Subject 1 (35 years old, 1.85 m), and walking-with-obstacles data ( Figure 4c) were obtained on the right foot of Subject 10 (23 years old, 1.58 m).  Foot clearance measurements obtained with the VICON system and estimated using the IMU-based algorithm for both feet of all 10 participating subjects are shown as histograms in Figure 5.

Results
These three histograms correspond to results obtained during normal walking (Figure 5a), fast walking ( Figure 5b) and walking with obstacles ( Figure 5c). In each histogram, the height of each bar corresponds to the maximum foot clearance measured with the VICON system on each foot of each subject. The bracket centered at the top of each bar represents the RMS value of foot clearance errors (Equation (10)) between VICON measurements and the proposed algorithm. The individual step error rate between VICON measurements and IMU-based foot height estimates was analyzed using a Student t-test. Benjamini-Hochberg correction was applied to limit the false positive rate. The mean error is significantly (p-value < 0.05) lower than 15% under the various walking conditions. A Spearman test showed that walking speed affects the error-rate.
The results shown in Figure 4 exhibit very good correspondence between foot clearance values estimated with the proposed method and those measured with the VICON motion capture system. In these particular examples, the good results obtained are illustrated by a low RMS of foot clearance estimation errors, i.e., approximately 0.35 cm during normal walking (Figure 4a), approximately 0.62 cm during fast walking (Figure 4b) and approximately 0.89 cm during walking with obstacles ( Figure 4c).
Results obtained in all subjects and summarized in Figure 5 show on the whole a good estimation of foot clearance compared to a measured one with VICON motion capture, which is considered as a reference due to its high accuracy. Indeed, the average of all normalized errors (NRMSE) is approximately 6.5%, and in 96% of all experiment cases, these normalized errors are less than 15%. In addition, in 83% of all experiment cases, these normalized errors are less than 10%, which correspond to 2 cm if the maximum foot clearance is approximately 20 cm.
The results obtained during the normal walking experiments, summarized by the histogram in Figure 5a, show that all RMS values of foot clearance estimation errors are less than 1.13 cm, whereas the average value of all of these errors is approximately 0.74 cm. This shows very good foot clearance estimation using the proposed method during normal walking for various subjects with different heights.
The estimation results declined during the fast walking experiments (Figure 5b), since the average of RMS errors increase to 1.3 cm, whereas there maximum value is approximately 3.5 cm (left foot, Subject 7). However, even in these experiment sets, the results are good, since in 85% of the experiments, the RMS errors remained less than 1.5 cm with an average of RMS errors around 1 cm.
Walking with obstacles is experimented on here to test the limits and the strength of our foot clearance estimation method. The results of these experiments for all subjects, summarized in Figure 5c, show larger RMS values of foot clearance estimation, which reached 10 cm (right foot, Subject 3). However, these results in cm cannot be compared to the previous results, since the maximum foot clearances are not comparable. Therefore, normalized RMS errors (Equation (11)) are used hereinafter for the purposes of comparison and discussion. Table 2 summarizes the subject average speed during each walking type using VICON data measurements. This brings numerical information about speed and, thereby, acceleration levels involved during each walking type.

Discussion
From the results, in walking with obstacles, 85% of the normalized RMS errors are lower than 15%. The average value of NRMSE in these 85% is approximately 6.9%, which correspond to 1.4 cm if the maximum foot clearance is approximately 20 cm. This result is therefore comparable to previous results and shows better foot clearance estimation performance if we compare it to the average RMS errors obtained in the fast walking case (1.3 cm). The estimation performance decrease in this case cannot be related to the speed difference with normal walking, since their speeds are close (see Table 2). This performance degradation is mainly due to the foot-flat phase detection algorithm (Figure 2), which presents some limits when the walking gait is not very natural, as in the case of walking with obstacles. Indeed, the accuracy of walking segmentation has an important impact on the foot clearance estimation, which decreased the estimation performances in the case of walking with obstacles.
In the foot-flat phase detection algorithm, the detection of the first events can be a source of errors in the case of the foot, which stands at the beginning, when the other foot begins the swing phase. Indeed, the motion start of this foot, detected from gyroscope data, is not the real start, since the ankle rotates around the heel before heel-off. To overcome this problem, we have combined the segmentation method with the linear acceleration start to make the detection of this first event more robust. Assuming that each subject starts walking with the same foot for all experiments, it seems interesting to compare for each subject the difference between the RMS errors obtained on the right and left foot. The average of all subjects of absolute variation between right and left foot estimation error is approximately 0.19 cm during normal walking and approximately 0.63 cm during fast walking. This small variation shows the robustness of the proposed segmentation to the choice of starting foot during walking. This comparison cannot be made in the case of walking with obstacles, since obstacles make the gait nonsymmetrical, and thus, the error produced in the right foot and left foot cannot be compared.
In addition to its good accuracy, the originality of the proposed foot clearance estimation method lies in its robustness to errors in IMU sensor placement on the foot around the Y-axis and Z-axis ( Figure 1). This was facilitated by initial tilt angles (Equation (5)) measured under initial stationary conditions and included in the gravity-free acceleration calculation.
As mentioned in the experimental validation section (Section 3), data obtained from the IMU sensors cannot be used online. This IMU sensors technology was however enough to validate our method and quantify its performance by comparing results to measurements with the VICON motion capture system, which is known for its high accuracy.
As in the current work, we assumed walking occurs on a flat and horizontal floor, some modifications should be made in the future in order to consider other types of walking, like climbing stairs. In this case, the height of each stair should be known and included in the correction model (Equation (9)) Another future prospect consists of the online estimation of the foot clearance. This requires using another IMU technology.
The difference in accuracy estimation between normal and fast walking can be due to the limit of the acquisition frequency in the presence of a higher acceleration, related to a higher walking speed (see Table 2). A study comparing the acquisition frequency and its effect on different walking speeds can be interesting to explore and is planned in future works.

Conclusions
In the present work, a single mounted inertial measurement unit (IMU) was used to estimate the foot clearance, from the double integration and de-drift correction of acceleration. An original algorithm of foot clearance estimation is proposed, which is robust to misalignment of IMU axes with respect to the foot axes. Our foot clearance estimation method was validated on both feet of 10 healthy subjects, with different sizes and gaits (normal walking, fast walking and walking with obstacles). For this experimental validation, an optical measurement of IMU position through a motion capture system was used as the reference. Then, the deviation between the IMU-based foot clearance estimation and the one measured with the motion capture system was quantified and discussed.
Experimental validation results obtained for all subjects showed good foot clearance estimation performance, where the average of all normalized RMSE values, including all walking types, is approximately 6.5%, which corresponds to 1.3 cm, if the maximum foot clearance is approximately 20 cm.
Detailed results showed the best estimation performance during normal walking, with an average of RMS error around 0.74 cm, where this average of RMS errors is around 1.3 cm in the case of the fast walking. This performance degradation can be due to the limitation of acquisition frequency in the presence of a higher acceleration. The results obtained during walking with obstacles show a decrease in estimation performance, even when normalized with a higher foot clearance than for other walking types. However, even in this case, the average of normalized RMS errors in 85% of experiments is approximately 6.9%, which presents a good estimation performance. This performance loss can be due to a decrease of segmentation walking accuracy, since this walking type is not as usual and periodic as normal and fast walking types.
Our foot clearance estimation method was performed offline, since IMU data were acquired locally on the SD card of the sensor. Regarding potential prospects for IMU wireless data transmission, an adaptation of this method will be required for an online version of the proposed foot clearance estimation algorithm.
Some of the proposed algorithms are included in a Python toolkit devoted to developments regarding acquisition, analysis and visualization of IMU-based motion capture. Open access to this toolkit is available via the link [29].