Abstract
In pedestrian navigation systems, the position of a pedestrian is computed using an inertial navigation algorithm. In the algorithm, the zero velocity updating plays an important role, where zero velocity intervals are detected and the velocity error is reset. To use the zero velocity updating, it is necessary to detect zero velocity intervals reliably. A new zero detection algorithm is proposed in the paper, where only one gyroscope value is used. A Markov model is constructed using segmentation of gyroscope outputs instead of using gyroscope outputs directly, which makes the zero velocity detection more reliable.
Keywords: hidden Markov model, pedestrian navigation system, zero velocity update method, Kalman filter
1. Introduction
A pedestrian or personal navigation system provides position information about a person indoors or outdoors. For example, if a firefighter carrying a personal navigation system is injured in the line of duty, we can know her/his position from the information transmitted by a pedestrian navigation system. Pedestrian navigation systems using inertial sensors are proposed in [1–6]. The main advantage of inertial sensor-based systems is that they are environment-independent; pedestrian navigation systems using vision or wireless communication require that landmarks or wireless nodes be installed in the environments [7,8].
There are many different pedestrian navigation systems using inertial sensors. They use similar inertial navigation algorithms to compute the position [9,10]. Also they all use zero velocity updating algorithms. When an inertial navigation algorithm is used, the position and velocity errors diverge by a few seconds without error resetting. During normal walking cycles, a foot touches the ground almost periodically and stays on the ground for a short time (usually about 0.1∼0.3 s), which is called the zero velocity interval. In the zero velocity updating algorithm, this zero velocity interval is detected and thus the velocity error is reset to zero. Accordingly the position and velocity errors diverge very slowly, and consequently being able to reliably detect this zero velocity interval is an important issue.
Slightly different zero detection algorithms are used in [1–3,5,6]. In [1], the zero velocity interval is determined based on gyroscope and accelerometer output norms. If the outputs are less than some threshold for a predetermined time, the zero velocity interval is decided. In [2,3], similar algorithms are used, where the main difference is which sensor values are used. In [2], the zero velocity interval is determined based on z-axis accelerometer and y-axis gyroscope outputs (see Figure 1 for the coordinate frame). In [3], the zero velocity interval is determined based on norms of gyroscope outputs. In [5], the zero velocity interval is detected based on the variance of accelerometer values. In [6], the zero velocity interval is detected based on norms of accelerometers and gyroscopes along with variance of accelerometers.
To use the zero velocity algorithms in [1–3,5,6], some threshold values (both for sensor values and time duration) must be assigned. These threshold values could differ significantly when a person is walking and running. The sensor values tend to become large and the interval duration tend to become shorter when a person is running. If we choose the threshold values too small, then we cannot detect zero velocity intervals when a person is running. On the other hand, if the threshold values are too large, then we could detect wrong zero velocity intervals. In general, the methods in [1–3,5,6] are relatively good for walking scenarios, but not for both walking and running.
In this paper, we propose a new zero velocity detection algorithm using a hidden Markov model [11,12]. The most relevant result is [4], where a zero velocity detection algorithm using a hidden Markov model is also used. The main differences are twofold. One is that only one gyroscope value is used in this paper while a foot sensor is also used in [4], which makes the zero detection problem relatively easy. The other difference is that a Markov model is constructed using segmentation of gyroscope outputs instead of using gyroscope outputs directly, which makes the zero velocity detection more reliable.
2. Inertial Sensor-Based Pedestrian Navigation Systems and Zero Velocity Intervals
In inertial sensor-based pedestrian navigation systems, inertial sensors are installed on a shoe, as can be seen in Figure 1. Note that the y-axis is nearly perpendicular to the sagittal plane. Thus, when a person walks or runs, the dominant rotation axis is the y-axis. We use y-axis gyroscope value to determine the zero velocity intervals. The gyroscope measures angular rate of foot rotations, and y-axis gyroscope output in our system has positive values when a foot is rotating clockwise.
Figure 2 shows the y-axis gyroscope output of two walking steps. From experiments, we found that a typical pattern is given as in Figure 3, where the pattern consists of four segments. The pattern starts with the zero value segment and it has two positive value segments and one negative value segment between them. These four segments are related to the foot movement. When a foot is on the ground, the output value is near upon zero. As a foot takes off the ground, the gyroscope output has positive values. And then it has negative values when a foot is swinging. Lastly, gyroscope output has positive values once more when the heel of a foot (or shoe) contacts the ground. This pattern is repeated in walking and running. We assign four states (1,2,3, and 4) to each segment, as in Figure 3. The details are discussed in Section 3.
Figure 3 shows how the y-axis gyroscope value changes during the normal walking cycles. A foot touches the ground almost periodically for a short interval. During this short interval, a foot is fixed on the ground and not moving. These short intervals are called “zero velocity intervals”. Due to sensor noises in the real data, it is not always easy to determine the zero velocity interval. Similar patterns can be observed during running cycles. In the running cycles, the zero velocity interval becomes shorter and it is more difficult to detect the zero velocity interval. We divided the gait pattern into four states based on the features of the y-axis gyroscope output. At this time, the state 1 is zero velocity interval.
3. Hidden Markov Model
In this section, we introduce a hidden Markov model for the zero velocity detection. The walking states are modeled as a finite state machine (see Figure 4), whose states can be observed through y-axis gyroscope value zi Instead of using zi directly as in [4], Yk (a series of segments derived from zi) is used as an output in the hidden Markov model.
The segmentation of y-axis gyroscope value zi is explained. First three regions (Region 1, 2, and 3) are defined depending on zi values (see Figure 5). To formally state this, we define a function f(zi):
(1) |
If zi values stay in the region j more than Nj (j = 1,2,3) (that is, at least Nj consecutive zi values have the same f(zi)), those zi values make a segment.
A segmentation example of is given in Figure 6 with N1=N2=N3=3. Since six consecutive zi (2≤i≤7) values have the same f(zi) =3 (that is 6≥ N3 = 3), they form the first segment. We will use Yk (k is the segment index) to denote the segment value, which is defined by Yk =f(zi), where zi belongs to the k-th segment. In Figure 6, we note that Y1=3. Similarly, the second segment is Y2=1. Also note that some zi values do not belong to any segments. For example, z8 and z9 do not belong to any segments and these values are ignored.
In Figure 6, sk and ek denote the starting and ending indices of the k-th segment, respectively: note that s1 = 2, e1 = 7, s2 =10 and e2 =15.
We will identify each segment using the finite state hidden Markov model. We assume that there is a Markov process Xk, which represents four walking states in Figure 3. Xk assumes one of four states: 1, 2, 3, and 4. When a person is walking, a typical state transition is 1→2→3→4→1→…. The Markov process Xk cannot be obtained directly but is estimated through the output Yk (that is, segment output), which can be observed. An example of state transitions of Xk and output Yk is given in Figure 7.
From experimental results, we determined the state transition probability as in Figure 8. A typical state transition is 1→2→3→4→1. However, there are also other possible transition patterns. For example, 4→3→2 transition (state 1 is missing) is possible. In this case, output data corresponding to state 1 is too short to be recognized as Yk and state 1 is considered to be missing.
From Figure 8, the state transition probability matrix A is given by:
(2) |
where the (m,n) -th element of A is given by:
The determination of A is a trial-and-error process, which is explained in the following. A normal state transition is 1→2→3→4→1→2→3→4. If walking and running cycles consist of only normal transitions, A should be as follows:
However, we found that some states are missing during walking and running. A person walked or ran 30 steps and we examined Yk. If no state is missing, Yk should be 1→2→3→2 for one walking or running cycle. If Yk is 1→2→3→1, then we know state 4 is missing. The results are summarized in Table 1.
Table 1.
Number of missing states in walking |
Number of missing states in running |
Missing probability [%] | |||||
---|---|---|---|---|---|---|---|
1st | 2nd | 3rd | 1st | 2nd | 3rd | ||
State 1 | 0 | 0 | 0 | 20 | 28 | 14 | 34.4 |
State 2 | 0 | 0 | 0 | 0 | 0 | 0 | 0.0 |
State 3 | 0 | 0 | 0 | 0 | 0 | 0 | 0.0 |
State 4 | 0 | 0 | 0 | 13 | 14 | 3 | 16.7 |
From Table 1, we can draw the following conclusions:
- State 1 is sometimes missing (in particular, when a person is running)
- State 2 and 3 are not missing
- State 4 is sometimes missing (in particular, when a person is running).
Thus we modified A1 to allow the following state transitions: 1→2→3→1 (state 4 is missing), 1→2→3→4→2 (state 1 is missing), and 1→2→3→2 (state 1 and 4 are missing):
If we choose large p1 (for example p1= 0.9 and p2= 0.1), it tends to estimate the transition 1→2→3→4 (normal cycle) as 1→2→3→2 (state 1 and 4 are missing). On the other hand, if we choose small p1 (for example, p1 = 0.1 and p2 = 0.9), it tends to estimate the transition 1→2→3→2 (state 1 and 4 are missing) as 1→2→3→4 (normal cycle). If difference between p1 and p2 is not large, the estimation results are similar.
Finally, we added small values for most transitions to allow unusual transitions. For example, when a person is standing and idly moving foot, unusual transitions (such as 2→1) could happen.
We have explained guidelines of how A are determined. Some values (such as 0.01 and 0.09) are determined by changing values and testing the results. We note that the proposed A is by no means an optimal A. As far as we know there is no analytic design procedure to derive the optimal A as stated in [13]. It is possible that extensive tuning of the parameters could produce better results and to derive a better tuning method is one of future topics.
If the output Yk=1, then we can assume Xk=1 from Figure 7. Also if YK=2 then Xk is either 2 or 4. If Yk= 3, then Xk is 3. This observation is contained in a matrix C, which represents the link between the output process Yk and the state process Xk. Matrix C is defined by:
In this paper, we use the following C matrix:
(3) |
Once A and C are defined, we can estimate Xk from the output Yk using HMM filters or smoothers [11–14]. Let Πk|k+l ∈R4×1 be a probability vector whose i-th element is given by Pr[Xk=i|Y1,⋯,Yk+l]. If l=0, then the problem becomes an HMM filter. If l>0, the problem becomes an HMM (fixed-lag) smoother problem. It is known that an HMM smoother gives a more reliable result than an HMM filter [11]. We found an HMM smoother with l=1 gives a significantly much more reliable results in our case (see the experimental results in Table 1). For example, suppose the state 4 and 1 are missing and the state transitions are given by 1→2→3→2→3 (Xk). In the case, the outputs are given by 1→2→3→2→3(Yk). If we use an HMM filter, the estimated first four states are likely to be 1→2→3→4 (Xk) since it only uses the current outputs 1→2→3→2(Yk). On the other hand, an HMM smoother gives the correct estimates using the outputs 1→2→3→2→3(Yk). When an HMM smoother with l=1, we can obtain an estimation result only after the current and the next outputs are available. Thus the estimation result is delayed by the combined duration of the current and next segments: typical delay is 1 second.
4. Zero Velocity Detection Algorithm
After Xk is estimated, the next step is to determine zero velocity intervals. We decide that the time i belongs to zero velocity intervals if |zi|≤α3 with anti-chattering algorithm and i satisfies the following conditions:
The |zi|≤α3 condition is used as a safeguard to prevent false identification of the zero velocity interval.
Case 1 corresponds to the normal walking cycles, where the state transition is 3→4→1→2 (see Figure 7). Since the zero velocity interval belongs to the state 1, the interval is chosen inside state 1. The parameters β1 and γ1 are used to discard time intervals near edges of the interval whose state is 1:
Since a foot is moving before and after state 1, the foot velocity cannot be zero in the edge regions. Thus we cut 10% (corresponding to 0.1) off the interval at both edges. If we choose larger values (for example, 0.2), the chance that a non-zero velocity interval is mistakenly identified as a zero velocity interval is reduced. However, we could obtain narrower zero velocity intervals, which is not desirable.
Case 2 and 3 correspond to walking or running cycles, where state 1 and/or state 4 are missing. Case 2 is when state 1 is missing. This could happen if the zero velocity interval is too short to form a segment. For example, state 1 is missing in Figure 9: state transition is 2→3→4→2→3. However, we can identify an interval corresponding to state 1 in Figure 9 by the manual inspection. This interval is identified as state 1 in the manual inspection. Thus the state classifications by the manual inspection and by Xk are different: even if some states are missing in Xk transition, they can be identified in the manual inspection.
We manually inspected the data and found the average duration ratio of each state is given as follows:
The ratio was computed from a weighted average of walking (weighting 0.1) and running (weighting 0.9) data. More weighting was given to running since missing states (like in case 2 and 3) are more likely to happen in running.
In case 2, the state 1 is missing. We assume the interval of missing state 1 is (sk–1+bk,sk). Note that the average duration percentage of state 4 and state 1 are 18.5% and 11.3%, respectively. Thus the duration ratio between sk–1 and sk is 0.621:0.379. Thus we choose β2 and γ2 as follows (see Figure 10):
In other words, the interval [sk–1, sk] is divided into [sk−1,sk−1+β2] and [sk−1 +β2,sk], where the latter is considered as state 1 interval.
Case 3 is when state 4 and 1 are missing. In this case, interval [sk–1, sk] includes the state 3 and missing states (4 and 1). Note that the average duration percentage of state 3, 4, and state 1 are 42.8%, 18.5%, and 11.3%, respectively. Thus the duration ratio among state 3:state 4:state 1 is 0.589 : 0.255 : 0.156. Thus we choose β3 and γ3 as follows:
When the interval [sk–1+βj, ek–1−γj] is determined, we checked whether zi, i∈[sk–1+βj, ek–1−γj] satisfies |zi|<α3 condition. Let U = {i| |zi| < α3, i ∈ [sk−1 + βj,ek−1−γj]}. If the set U consists of more than one intervals as in Figure 11, the interval whose duration is the largest is chosen as the zero velocity interval.
5. Experiments
In this section, the proposed method is verified using experiment data, which are obtained from an inertial sensor unit (Xsens Mti) attached on a shoe. The sampling rate is 100 Hz. In Figure 12, sensor outputs are given when a person walked and then ran slowly. We note that only gyroscope output is used in the proposed algorithm. The z-axis accelerometer output is also given since it is used by other existing algorithms. The proposed algorithm along with other existing algorithms [1–3] are applied to the experiment data. The parameters of the proposed algorithm are given by:
The parameters αj and Nj are determined from the experimental data so that normal walking gives four different states. For example, if we use a smaller α2 value, it becomes sensitive to noises so that states 2/3/4 could be falsely identified. On the other hand, if we use larger α2 value, states 2/3/4 could be lost. The parameter Nj is closely related to αj. For example, smaller N2 has a similar effect of using smaller α2 in the sense that state 2/3/4 could be falsely identified.
As a reference, zero velocity interval is determined by manually analyzing gyroscope data. When data are analyzed manually from the plot, the sensor noises and irregularities can be easily spotted and thus we can consider the detected interval as a true zero velocity interval.
The result is given in Figure 13. The algorithm in [1] failed to detect the zero velocity interval when a person is running. The algorithm in [3] is not reliable in the sense that there are false zero velocity detections.
In Figure 14, sensor outputs are given when a person ran slowly and then ran fast. The speeds of “walk”, “run slowly” and “run fast” are about 1.05 m/s, 2.14 m/s, and 3.50 m/s, respectively, which are computed by dividing the distance by the elapsed time. The zero detection results are given in Figure 15. It can be seen that the methods in [1] and [2] cannot detect the zero velocity intervals when a person ran fast. In all cases (Figures 13 and 15), the proposed algorithm reliably detected the zero velocity intervals.
To compare performance of each method quantitatively, a person walked or ran 30 steps at different speed. Since there is one zero velocity interval in each step, 30 zero velocity intervals should be detected. The number of detected zero velocity intervals by different methods is given in Table 2. We can see when a person is walking, all methods give a good result. When a person is running, method 1 and 2 failed to detect the zero velocity intervals most times. The method [3] and the proposed method with an HMM smoother are able to detect all the zero velocity intervals. When counting the number of detected zero velocity intervals, we counted one even if there are more than two detection during the same zero velocity interval. For example, see the two detected zero velocity intervals by the method [3] between 24 and 25 s. These two intervals are counted as one interval. We note that there is a zero velocity interval between the two detected zero velocity intervals, but it is not detected by the method [3]. On the other hand, the proposed method detects almost the whole range of a zero velocity interval. Thus the proposed method can detect the zero velocity intervals more reliably.
Table 2.
Experiments | Speed [m/s] |
Number of detected zero velocity intervals by different methods |
|||||
---|---|---|---|---|---|---|---|
[1] | [2] | [3] | Proposed method with an HMM filter | Proposed method with an HMM smoother | |||
Walking | 1st | 1.3 | 28 | 30 | 30 | 30 | 30 |
2nd | 1.4 | 22 | 29 | 30 | 30 | 30 | |
3rd | 1.4 | 28 | 30 | 30 | 30 | 30 | |
Running | 1st | 2.4 | 0 | 2 | 30 | 10 | 30 |
2nd | 2.8 | 0 | 1 | 30 | 1 | 30 | |
3rd | 2.5 | 0 | 0 | 30 | 16 | 30 |
We also investigated whether there is false zero velocity detection (an interval is identified as a zero velocity interval while a foot is not in the zero velocity interval). The result is given in Table 3, where the same experiment data were used as in Table 2. It can be seen that the method in [3] sometimes falsely identifies the zero velocity intervals: we found the method in [3] sometimes falsely identifies zero crossing points of gyroscope norm as zero velocity intervals. There was no false zero velocity detection in other methods.
Table 3.
Experiments | Speed [m/s] |
Number of detected non zero velocity intervals by different methods |
|||||
---|---|---|---|---|---|---|---|
[1] | [2] | [3] | Proposed method with an HMM filter | Proposed method with an HMM smoother | |||
Walking | 1st | 1.3 | 0 | 0 | 5 | 0 | 0 |
2nd | 1.4 | 0 | 0 | 1 | 0 | 0 | |
3rd | 1.4 | 0 | 0 | 1 | 0 | 0 | |
Running | 1st | 2.4 | 0 | 0 | 0 | 0 | 0 |
2nd | 2.8 | 0 | 0 | 0 | 0 | 0 | |
3rd | 2.5 | 0 | 0 | 3 | 0 | 0 |
6. Conclusions
In this paper, we have proposed a new zero velocity detection algorithm, which can be used in inertial sensor based pedestrian navigation systems.
Existing zero detection methods usually work well for normal walking cycles, but the detection is not reliable for running cycles, in particular when the running speed is high. Using a hidden Markov model, the proposed algorithm can analyze both walking and running cycles and the zero velocity interval is thus more reliably detected.
The actual state transition probabilities differ depending on speed of a person. In this paper, we used one averaged transition probability. It is a future work to derive a zero velocity detection algorithm that uses multiple state transition probability matrices.
Acknowledgments
This work was supported by National Research Foundation of Korea Grant funded by the Korean Government (No. 2010-0016230).
References
- 1.Foxlin E. Pedestrian tracking with shoe-mounted inertial sensors. IEEE Comp. Graph. Appl. 2005;25:38–46. doi: 10.1109/mcg.2005.140. [DOI] [PubMed] [Google Scholar]
- 2.Yun X, Bachmann ER, IV HM, Calusidan J. Self-contained position tracking of human movement using small inertial/magnetic sensor modules. Proceedings of IEEE International Conference on Robotics and Automation; Rome, Italy. April 10–14, 2007; pp. 2526–2533. [Google Scholar]
- 3.Ojeda L, Borenstein J. Non-GPS navigation for security personnel and first responders. J. Navigation. 2007;60:391–407. [Google Scholar]
- 4.Suh YS, Park SK. Pedestrian inertial navigation with gait phase detection assisted zero velocity updating. Proceedings of the 4th International Conference on Autonomous Robots and Agents; Wellington, New Zealand. February 10–12, 2009; pp. 336–341. [Google Scholar]
- 5.Stirling RG. 2003. Development of A Pedestrian Navigation System Using Shoe Mounted Sensors. Master of Science, University of Alberta, Edmonton, AB, Canada.
- 6.Jiménez AR, Seco F, Prieto C, Guevara J. Indoor Pedestrian Navigation using an INS/EKF framework for Yaw Drift Reduction and a Foot-mounted IMU. Proceedings of 7th Workshop on Positioning, Navigation and Communication, WPNC 2010; Dresden, Germany. March 11–12, 2010. [Google Scholar]
- 7.Millonig A, Schechtner K. Developing landmark-based pedestrian navigation systems. Proceedings of IEEE Conference on Intelligent Transportation Systems; Vienna, Austria. September 13–16, 2005; pp. 197–202. [Google Scholar]
- 8.Wendlandt K, Berbig M, Robertson P. Indoor localization with probability density functions based on Bluetooth. Proceedings of the 16th International Symposium on Personal, Indoor and Mobile Radio Communications; Berlin, Germany. September 2005; pp. 2040–2044. [Google Scholar]
- 9.Chatfield AB. Fundamentals of High Accuracy Inertial Navigation. AIAA; Richmond, VA, USA: 1997. [Google Scholar]
- 10.Yang CK, Shim DS. Best sensor configuration and accommodation rule based on navigation performance for INS with seven inertial sensors. Sensors. 2009;9:8456–8472. doi: 10.3390/s91108456. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 11.Shue L, Andeson BDO, Dey S. Exponential stability of filters and smoothers for Hidden Markov models. IEEE Trans. Acoustics, Speech, Signal Proc. 1998;46:2180–2194. [Google Scholar]
- 12.Anderson BDO. From Winer to hidden Markov models. IEEE Control Syst. Mag. 1999;19:41–51. [Google Scholar]
- 13.Rabiner LR. A tutorial on hidden Markov models and selected applications in speech recognition. IEEE. 1989;77:257–286. [Google Scholar]
- 14.Seo DJ, Ko NY, Son JE. A method for combining odometry and distance sensor information for Effective obstacle avoidance of autonomous mobile robots. Int. J. Cont. Auto. Syst. 2010;8:597–603. [Google Scholar]