Next Article in Journal
luxS Mutant Regulation: Quorum Sensing Impairment or Methylation Disorder?
Previous Article in Journal
An Event Driven Hybrid Identity Management Approach to Privacy Enhanced e-Health
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Using LS-SVM Based Motion Recognition for Smartphone Indoor Wireless Positioning

Department of Navigation and Positioning, Finnish Geodetic Institute, FIN-02431 Masala, Finland
*
Author to whom correspondence should be addressed.
Sensors 2012, 12(5), 6155-6175; https://doi.org/10.3390/s120506155
Submission received: 20 March 2012 / Revised: 17 April 2012 / Accepted: 28 April 2012 / Published: 10 May 2012
(This article belongs to the Section Physical Sensors)

Abstract

: The paper presents an indoor navigation solution by combining physical motion recognition with wireless positioning. Twenty-seven simple features are extracted from the built-in accelerometers and magnetometers in a smartphone. Eight common motion states used during indoor navigation are detected by a Least Square-Support Vector Machines (LS-SVM) classification algorithm, e.g., static, standing with hand swinging, normal walking while holding the phone in hand, normal walking with hand swinging, fast walking, U-turning, going up stairs, and going down stairs. The results indicate that the motion states are recognized with an accuracy of up to 95.53% for the test cases employed in this study. A motion recognition assisted wireless positioning approach is applied to determine the position of a mobile user. Field tests show a 1.22 m mean error in “Static Tests” and a 3.53 m in “Stop-Go Tests”.

Graphical Abstract

1. Introduction

Nowadays, with the explosive growth of the capabilities in handheld devices, various components are embedded into smartphones, such as GPS, WLAN (a.k.a. Wi-Fi), Bluetooth, accelerometers, magnetometers, cameras, etc. Because of their locating capabilities, which are quickly becoming one of the standard features in mobile devices, more and more people are getting used to the location-enabled life. Employing Global Navigation Satellites Systems (GNSS), the applications in the “smart” devices can greatly enrich the end users' outdoor activities. However, given the nature of GNSS design, they are clearly not well-suited for applications in urban canyons and indoor environments. Satellite-based positioning technologies continue to struggle indoors, due to well known issues, such as the weak signal or non-line-of-sight (NLOS) conditions between the mobile user and satellites.

To address positioning and navigation in GNSS-degraded or denied areas, various technologies are broadly researched [1]. Most research topics focus on the high-sensitivity GNSS [2], optical navigation systems [3,4], ultrasound solutions [5], WLAN [6], Bluetooth [7,8], Zig Bee [9], Ultra Wide Band [10], cellular networks [2], RFID [11], magnetic localization [12], inertial measurement units [13,14], signals of opportunity [15], biosensor [16,17], and also hybrid solutions [1821].

Benefiting from the existing infrastructure, RF-based technologies, such as WLAN, Bluetooth, cellular network, and RFID, are definitely one of highest potential alternatives. RADAR [6] was one of the first WLAN-based positioning systems to compute the mobile device's location based on radio signal strength (RSS) from many access points (APs). Skyhook wireless is a system that depends on information about the AP's coordinates in a database in order to predict location [22]. Ekahau [23] provides an easy and cost-effective solution for locating people, assets, inventory and other objects using Wi-Fi. The Active Badge [24] system uses ceiling-mounted infrared sensor detectors to detect signals from a mobile active badge. Place Lab [25] has even more ambitious goals as seeking to create a comprehensive location database that uses fixed-commodity Wi-Fi, GSM and Bluetooth devices as global beacons.

Meanwhile, human physical activity recognition using MEMS sensors has been extensively applied for health monitoring, emergency services, athletic training, navigation, etc. [26,27]. Since motion sensors such as accelerometers, gyroscopes and magnetometers are integrated into a smartphone, they bring the opportunity to assist navigation with knowledge about the motion of a pedestrian [28,29].

Since mobile devices are becoming smarter and smarter nowadays, the smartphone already contains the potential for indoor navigation and positioning within the existing infrastructures [19]. This paper presents an indoor pedestrian navigation solution relying on motion recognition in an office environment utilizing the existing WLAN infrastructure.

2. Motivation

Related research indicates that utilizing opportunistic signals of, e.g., WLAN, is an efficient locating alternative in GPS-denied environments. However, in order to minimize a smartphone's battery drain, the WLAN scanning interval is always limited. For instance, most of the Nokia mobile phones refresh the scanned WLAN information proximately every 8–10 s. The default scanning interval of most Android devices is 15 s. On the other hand, other built-in sensors such as accelerometers are always turned on, in order that the physical orientation of the smartphone is always known to the system. These sensors provide an alternative for positioning while WLAN positioning is unavailable.

During the gaps where no wireless signal is updated, the most essential elements for navigation are the movement speed and orientation (i.e., heading). As long as they are determined, it is possible to estimate the position of the user every second using dead-reckoning. Therefore, this paper presents a method to use the built-in tri-axial accelerometer and magnetometer on a smartphone to recognize the user's movement parameters. The proposed solution detects the physical movements using simple acceleration and orientation features throughout the navigation process. With the recognized motions, it is possible to reasonably estimate the speed and position over the period between wireless scans.

Human motion has been widely studied for decades, especially in recent years using computer vision technology. Poppe gives an overview of vision based human motion analysis in [30]. Aside from vision-based solutions, sensor-based approaches are also extensively adopted in biomedical systems [3134]. Most of the previous motion recognition related research assumed that the Micro-Electro-Mechanical Systems (MEMS) inertial sensors used are fixed on a human body [3538] (e.g., in a pocket, clipped to a belt or on a lanyard) and that an inference model can be trained according to a handful of body positions. Some of them use phones as a sensor to collect activities for off-line analysis purposes [39]. Compared to the daily activities, such as “Sitting”, “Walking”, “Running”, “Jumping”, the motions of a pedestrian who is using a smartphone for navigation in three-dimensional indoor structures are far more complicated due to the arbitrary gestures while a phone is kept in hand. Hence this paper primarily focuses on the possible motion states of a user with a phone in hand while navigating. References [28] and [29] have briefly presented the preliminary results of our previous research in this topic.

3. Motion States

Unlike the solution with sensors fixed on the body, a smartphone in hand has more degrees of freedom (DOF) during the navigation process. Even if we only consider the case where the user holds the phone in hand, the motion behaviour is still complicated. For this reason, we defined eight most common motion states during pedestrian navigation in this paper. In order to classify the motion states, twenty-seven features are investigated in this section.

3.1. Motion Definition

The motion states, as defined in Table 1, are grouped into four series as follows:

  • S-series motion states (Figure 1) refer to the stationary behavior during a navigation process. ST is a state where a user keeps a phone in hand without any movement. In contrast, SS is a category of the movement where user's location does not change, but the phone is moving in a swinging.

  • W-series is relevant to walking. After observing the walking behaviour of the user when navigating, three types of walking motion states have been defined. As shown in the left image of Figure 2, WH represents the motion state where the user is using the navigation application on the handset while walking. The user often keeps his or her eyes on the screen of a smartphone in this state. WS stands for the normal walking behaviour, when the user is not using the navigation application but is holding the smartphone in his or her hand. As the center image of Figure 2 indicates, a small arm swinging motion exists when the user is walking in normal speed, while the right image of Figure 2 shows the WF state, which represents a fast walking behaviour with significantly arm swinging.

  • T-series is related to turning motions. UT represents so-called U-turning, which is a spot turn without any horizontal displacement. As shown in Figure 3, a UT motion results in a heading change of 180° after turning.

  • V-series concerns motions in the vertical dimension. In Figure 4, US and DS are going up/down the stairs, respectively.

3.2. Feature Definition

When using tri-axis accelerometer sensors, the sensor orientation determines the local coordinate system of each (x, y, z) reading. Most previous research work on motion recognition has used body-worn accelerometer sensors, i.e., sensors attached to the body in a constrained orientation. When smartphones are used as portable sensors, the orientation of the sensors is not known a priori. Figure 5 gives a typical example of the accelerometer readings after filtering from a smartphone while different motion states are performed.

To avoid this orientation problem, the magnitude of the accelerometer signal (see the ‘Acc Filter’ line of Figure 5) can be used. This solution, however, will cause the three-directional acceleration information to be lost. Therefore, we use an estimated gravity vector as a reference to compute the dynamics of the smartphone's orientation. The gravity vector is trained with the data obtained in the static status (see the left image of Figure 1) in a calibration phase (e.g., 10 s). When the estimated gravity vector is known, it enables the estimation of the vertical component and the magnitude of the horizontal component of a user's motion [39].

The gravity vector is denoted as:

G = ( g x , g y , g z )
where gx, gy, gz are the mean values of the gravity vector along the respective axes over the calibration phase.

The acceleration vector can be expressed as:

A = ( a x , a y , a z )
where ax, ay, az are the accelerometer readings along the respective axes at the given time.

The projection of A (denoted as Ap) onto the gravity vector G can be calculated as the vertical component inside of A. The vertical component of A can be calculated as the projection of A onto the gravity vector G:

A p = ( A G G G ) G

Then the horizontal component Ah can be computed using vector subtraction:

A h = A - A p

The direction of Ah relative to the horizontal axis in the global 3-axis coordinate system, however, still cannot be obtained. For this reason, we use the magnitude of the acceleration in the horizontal plane, which is orthogonal to the estimated gravity vector G. In this paper, the mean of the acceleration in the horizontal plane (MeanAccH), variance of the acceleration in the horizontal plane (VarAccH), and the variance of the magnitude of the acceleration (VarAcc) are selected as the simple features to detect the motion states.

In addition to the accelerometer sensors, a magnetometer, also known as a digital compass, is another data source that can be utilized for motion recognition in a smartphone. The magnetometer, however, has some significant drawbacks. Indeed, magnetic disturbances are numerous, particularly in indoor environments. Figure 6 shows the corresponding heading readings from a built-in magnetometer for the same example readings presented above in Figure 5. Even though the user was in the ST state (0–200 s), the mean error introduced during this time period is still more than 20°. This large level of error means the magnetometer readings cannot be used directly for positioning in indoor navigation applications. Filtering and map matching are always demanded in the practical application. Instead of using the heading readings for navigation directly, in this paper we focus on applying them for recognizing the motion state of the user.

After analyzing the physical characteristics of the motion behavior, twenty-seven features are defined for the motion state estimation, including time-domain features of acceleration (Features 1–18) and heading (Features 19–21) and frequency domain features of acceleration (Features 22–27). Note that in Table 2 the dynamic acceleration denotes the real-time acceleration reading from smartphone minus the acceleration due to gravity.

4. LS-SVM Based Motion Recognition

The motion recognition method presented in this paper aims at determining which of the eight motions have caused the above twenty-seven simple features. The possible classification algorithms include k-Nearest Neighbour (kNN), Linear Discriminant Analysis (LDA), Quadratic Discriminant Analysis (QDA), Naïve Bayesian Classifier (NBC), Bayesian Network (BN), Decision Tree (DT), Artificial Neural Networks (ANN), Support Vector Machines (SVMs) and so forth. Thanks to the efficient pattern reorganization performance for the non-linear multi-class scenarios, in this study, we adopt the Least Square-Support Vector Machines (LS-SVM) [40] based classification algorithm, which is a class of kernel-based learning methods widely used for classification and regression analysis.

4.1. Support Vector Machines (SVMs)

The concept of SVMs, which was originally developed for binary classification problems, is the use of hyperplanes to define decision boundaries separating data points of different classes. SVMs are able to handle both simple, linear classification tasks, as well as more complex, i.e., nonlinear, classification problems [41]. The idea behind SVMs is to map the original data points from the input space to a high dimensional, or even infinite-dimensional, feature space such that the classification problem becomes simpler in the feature space, as shown in Figure 7.

When the data are linearly separable, the separating hyperplane can be defined in many ways. SVMs are based on the maximal margin principle, where the aim is to construct a hyperplane with maximal distance between the two classes. In most of real life applications, however, data of both classes overlap, which makes a perfect linear separation impossible. Therefore, a restricted number of misclassifications should be tolerated around the margins. The resulting optimization problem for SVMs, where violation of the constraints is penalized, is written as:

min ω , ξ , b J 1 ( ω , ξ ) = 1 2 ω T ω + C i = 1 N ξ i
such that:
y i ( ω T ϕ ( x i ) + b ) 1 - ξ i , i = 1 , , N , ξ i 0 , i = 1 , , N ,
y i = sign ( ω T φ ( x i ) + b
where J1 is the cost function, ω is termed the weight vector, and the C is a positive regularization constant. The regularization constant in the cost function defines the tradeoff between a large margin and a misclassification error (i.e., empirical risk minimization). SVMs are based on the principle of structural risk minimization which balances model complexity and empirical error. The first set of constraints corresponds to Equation (5), while the second set imposes positive slack variables ξi, tolerating misclassifications. The value ξi indicates the distance of xi with respect to the decision boundary, as follows:
  • ξi ≥ 0: yi(ωTφ(xi) + b) < 0 implies that the decision function and the target have a different sign, indicating that xi is misclassified,

  • 0 < ξi < 1: xi is correctly classified, but lies inside the margin,

  • ξi = 0: xi is correctly classified and lies outside the margin or on the margin boundary.

Typically, the problem formulation in Equations (5)(7) is referred to as the primal optimization problem. Alternatively, however, the optimization problem for SVMs can be written in the dual space using the Lagrangian with Lagrange multipliers αi ≥ 0 for the first set of constraints shown in Equation (6). This alternative but equivalent formulation is useful in the cases where the original data are nonlinear.

The solution for the Lagrange multipliers is obtained by solving a quadratic programming problem. The SVM classifier takes the form:

y ( x ) = sign ( i = 1 N α i y i K ( x , x i ) + b )
where the kernel function K(·,·) is positive definite. It satisfies Mercer's condition then, meaning that K(x,xi) equals φ(x)Tφ(xi). Using this so-called kernel trick, no explicit construction of the mapping φ(·) is needed. This enables SVMs to work in a high-dimensional (or infinite-dimensional) feature space, without actually performing calculations in this space. Various types of kernel functions can be chosen:
  • Linear SVM : K ( x , z ) = x T z ,

  • Polynomial SVM of degree d : K ( x , z ) = ( τ + x T z ) d , τ 0

  • Radial basis function ( RBF ) : K ( x , z ) = exp ( - x - z 2 2 / δ 2 ) ,

  • Multi-layer perceptron ( MLP ) : K ( x , z ) = tanh ( κ 1 x T z + κ 2 ) d ,

where K(·,·) is positive definite for all δ values in the RBF kernel case and τ ≥ 0 values in the polynomial case, but not for all possible choices of κ1, κ2 in the MLP case. Such kernels transform the original data into a higher dimensional feature space, where they are separable by a hyperplane in this feature space.

4.2. LS-SVM

The classification technique used in this work is the LS-SVM. LS-SVM tackles linear systems rather than solving convex optimization problems, typically quadratic programs, as in standard support vector machines (SVM) [40]. This is done by both introducing a least squares loss function and working with equalities, instead of the intrinsic inequalities of SVM formulations. One advantage of this reformulation is complexity reduction. In the training phase, the LS-SVM classifier constructs a hyperplane in a high-dimensional space aiming to separate the data according to the different classes. This data separation should occur in such a way that the hyperplane has the largest distance to the nearest training data points of any class. These particular training data points define the so-called margin.

These parameters can be found by solving the following optimization problem having a quadratic cost function and equality constraints:

min ω , e , b J 2 ( ω , e ) = 1 2 ω T ω + 1 2 γ i = 1 N e i
subject to:
y i ( ω T ϕ ( x i ) + b ) 1 - e i , i = 1 , , N
with e = [e1eN]T a vector of error variables to tolerate misclassifications, φ(·): ℝd→ℝdh mapping from the input space into a high-dimensional (e.g., infinite dimensional) feature space of dimension dh, ω a vector of the same dimension as φ(·), γ is a positive regularization parameter, determining the trade-off between the margin size maximization and the training error minimization. b is a bias term. In this equation, the standard SVM formulation is modified using a least squares loss function with error variables ei and replacing the inequality constraints with equality constraints. Since, the value 1 in the equality constraints is a target value instead of a threshold value, the method is related to kernel Fisher discriminant analysis [40]. The Lagrangian for the problem in Equations (13) and (14) is:
L ( ω , b , e , α ) = J 2 ( ω , e ) - i = 1 N α i ( y i [ ω T ϕ ( x i ) + b ] - 1 + e i )
where α ∈ ℝ are the Lagrange multipliers, or support values.

Taking the conditions for optimality, we set:

{ L ω = 0 ω = i = 1 N α i y i ϕ ( x i ) , L b = 0 i = 1 N α i y i = 0 , L e i = 0 α i = γ e i , L α i = 0 y i [ ω T ϕ ( x i ) + b ] - 1 + e i = 0 , i = 1 , , N .

Whereas the primal problem is expressed in terms of the feature map, the linear optimization problem in the dual space is expressed in terms of the kernel function:

( 0 y T y Ω + 1 γ I n ) ( b α ) = ( 0 1 n )
where y = [y1yN]Tα = [α1αN]T 1n = [1…1]T1×N and Ω ∈ ℝN×N is a matrix with elements Ωij = yiyjφ(xi)Tφ(xj), with i, j = 1, …, N. Provided with an input vector x, the resulting LS-SVM classifier in the dual space is similar to the standard SVM classifier:
y ( x ) = sign ( i = 1 N α i y i K ( x , x i ) + b )
where K(x,xi) = φ(x)Tφ(xi) is a positive definite kernel matrix. The support values αi are proportional to the error of the corresponding training data points. This implies that usually every training data point is a support vector and no sparseness property remains in the LS-SVM formulation. However, high support values indicate a high contribution of the data point to the decision boundary. The choice of the regularization parameter and the kernel hyperparameter δ in case of an RBF kernel, is out of the scope for discussion in this paper. Hospodar gives an example of the kernel parameters selection in [42].

As shown in Figure 8, in this research we label the eight motion states as classes 1 to 8. These states are difficult to separate linearly in the original feature space. In order to classify the states, we apply a LS-SVM classifier using a RBF kernel function. The Nelder-Mead Simplex algorithm [43] is applied for tuning parameter optimization. The cross validation as a cost function is used for estimating the performance of the selected parameters [44]. As the optimized result, the regularization parameter γ equals 23.7002 and the kernel hyperparameter δ2 equals 0.21229. Figure 8 presents the projection of the hyperplanes in the original feature space, which shows that the states are separable in the high dimensional feature space. The accuracy of the LS-SVM classifier for motion recognition will be fully discussed in Section 6.

5. Positioning Algorithms

In this paper, the motion recognition assisted indoor navigation solution interpolates the locations calculated by wireless positioning which uses the fingerprinting approach described below. Provided with the discrete locations from wireless positioning and recognized motion states, a grid-based filter based on the hidden Markov model is applied to compute the continuous positions of a smartphone user.

5.1. Fingerprinting Based Wireless Positioning

Received signal strength indicators (RSSIs) are the basic observables in this approach. The process consists of a training phase and a positioning phase. During the training phase, a radio map of probability distributions of the received signal strength is constructed for the targeted area. The targeted area is divided into a grid, and the central point of each cell in the grid is referred to as a reference point. The probability distribution of the received signal strength at each reference point is represented by a Weibull function [7], and the parameters of the Weibull function are estimated with the limited number of training samples.

During the positioning phase, the current location is determined using the measured RSSI observations in real time and the constructed radio map. The Bayesian theorem and Histogram Maximum Likelihood algorithm are used for positioning [45,46].

Given the RSSI measurement vector O⃗= {O1, O2Ok} from APs, the problem is to find the location l with the conditional probability P(l| O⃗) being maximized. Using the Bayesian theorem:

arg max i [ P ( l | O ) ] = arg max l [ P ( O | l ) P ( l ) P ( O ) ]
where P(O⃗) is constant for all l. Therefore, the Equation (19) can be reduced as:
arg max i [ P ( l | O ) ] = arg max l [ P ( O | l ) P ( l ) ]

We assume that the mobile device has equal probability to access each reference point, thus P(l) can be considered as constant in this case, Equation (20) can be simplified as:

arg max i [ P ( l | O ) ] = arg max l [ P ( O | l ) ]

Now it becomes a problem of finding the maximum conditional probability of:

P ( O | l ) = n = k k P ( O n | l )
where the conditional probability P(On |l) is derived from the RSSI distribution stored in the fingerprint database.

5.2. Grid-Based Filter of HMM

The grid-based filter of hidden Markov model (HMM) is implemented to produce an optimal estimation based on the previous state. The transit probability matrix of HMM is computed according to the travelled distance which can be estimated by the knowledge about the motion over time. For instance, the travelled distance is zero if the current motion mode is static. The user travel distance while navigating can be calculated each second as:

d t = v t t
where vt is the velocity output based on the recognized motion state and t is the time.

The velocity estimation models vary in different motion states. These estimations are out of the scope of this paper. More details about velocity estimation can be found in [27].

The grid-based filter produces an optimal estimation if the state space is discrete and consists of a finite number of states. If a numerical approximation is employed to obtain a discrete and finite state space, the grid-based filter produces a suboptimal estimation [47].

Given measurements up to epoch t-1, let the conditional probability of each state Si be denoted by ωit-1|t-1, that is ωit-1|t-1 = P(Xt-1 = Si|o1,…,ot-1), i = 1,…, N. Then, given a hidden Markov model Λ = (A,B,π) [48], the posterior probability related to each state Si at epoch t-1 can be written as:

P ( X t - 1 ) = S j | o 1 , , o t - 1 ) = t = 1 N ω t - 1 | t - 1 i δ ( S j - S i ) , j = 1 , , N
where δ(·) is the Dirac delta function.

The grid-based filter consists of prediction and update stages as follows, similar to those used in other recursive Bayesian filters.

Prediction stage:

P ( X t = S j | o 1 , , o t - 1 , Λ ) = t = 1 N ω t | t - 1 i δ ( S j - S i ) , j = 1 , , N

Update stage:

P ( X t = S j | o 1 , , o t , Λ ) = t = 1 N ω t | t i δ ( S j - S i ) , j = 1 , , N
where
ω t | t - 1 i j = 1 N ω t - 1 | t - 1 j P ( S t i | S t - 1 j )
ω t | t i ω t | t - 1 i P ( o t | S t i ) j = 1 N ω t | t - 1 i P ( o t | S t j )

Once the posterior probabilities of all states are estimated, the filter solution is given by the state with the maximum probability.

In the tests described in the following section, we applied magnetometer readings via map-matching instead of using the heading directly obtained from a magnetometer since the magnetic disturbances are numerous, particularly in indoor environments. With the heading input from the magnetometer and current position estimate, matched direction is derived from the segment vector in the topological network of the fingerprint database. In addition, the cumulative travel distance over the duration without WLAN positioning is used as an observation in the HMM grid-based filter for determining the position.

6. Test Results

To verify the solution proposed in this paper, some field tests were carried out in the Finnish Geodetic Institute (FGI) office building, which has three floors. A smartphone application was developed for collecting sensor data, labeling the motion state, and locating the smartphone position. Five persons collected the data for motion recognition in one day. Each person performed eight motion states respectively. Testers made marks at the beginning and end of the motion to separate the samples of motion states. All the collected data were divided into two groups. One was selected as a training data set. The other was utilized as a testing data set. The training data sets were used for learning the parameters of the classification algorithm. The testing data sets were used for validating the recognition rate of a classifier.

In order to evaluate the performance of LS-SVM classifier for motion recognition, the same data sets are also applied in four other classification algorithms for comparison: Bayesian Network using the Gaussian Mixture Model (BN-GMM), Decision Tree (DT), Linear Discriminant Analysis (LDA) and Quadratic Discriminant Analysis (QDA). Table 3 illustrates the recognition rates for the five classifiers with varying feature combinations. The bold and italic number indicates the best recognition rate in each feature combination in five classifiers. The bold and underlined number stands for the best recognition rate in each classifier.

The test results indicate that:

  • LS-SVM classifier has the best performance in different feature combinations.

  • Including all features does not help the recognition rate.

  • Feature 4 and 5 are the most efficient features for the tested motion recognition.

Another test was carried out by a tester who travelled around in the FGI office building for 20 min. As shown in Figure 9, eight motion states, including DS, SS, ST, US, UT, WF, WH, and WS, were performed in order. The confusion matrix for the motion recognition from the LS-SVM classifier is listed in Table 4. In the results for this test, 18.75% of ST motions and 22.22% of US motions are mistaken for UT using LS-SVM. The W-series motion states achieve a perfect success rate in this test.

To prove the advantage of wireless positioning combined with motion recognition, two positioning tests were conducted in the FGI building. A WLAN fingerprint database covers three floors of FGI was beforehand generated and used in the following tests. The first test, called a “Static Test,” was carried out in a static state—a user stood on a reference point while holding the phone in hand (ST) for ten minutes. The results are summarized in Table 5, where the average error is 3.43 m when the Maximum Likelihood (ML) algorithm was applied in wireless positioning. The mean error is reduced to 1.22 m when applying a motion-awareness assisted HMM algorithm. Furthermore, compared to the ML algorithm, the RMSE (Root Mean Square Error) and maximum error are all significantly decreased when using motion recognition assisted HMM algorithm.

The second test is called the “Stop-Go Test”. In the FGI office building, a tester stopped at each reference point to obtain the wireless positioning estimation, then moved to another reference point while randomly performing varying motion states between two stops. Table 6 compares the positioning results derived from ML and motion recognition assisted HMM algorithm. Some improvements can be found in motion recognition assisted HMM algorithm compared to the ML algorithm. Meanwhile, the motion recognition also raises the floor detection rate from 89.93% to 95.95%. The details are shown in Tables 7 and 8.

7. Conclusions and Future Work

In this paper, the motion recognition assisted wireless positioning method is presented. The raw data from the accelerometer and magnetometer on a smartphone are processed into twenty-seven features. Then eight motion states are predicted by separately applying the LS-SVM, BN-GMM, DT, LDA and QDA classifiers. The test results indicate that the LS-SVM classifier has an efficient performance of motion recognition rate compared with the other four classifiers. The recognition rates of T-series and V-series motions are lower than those of S-series and W-series motions. Furthermore, both positioning accuracy and floor detection rate are significantly improved by applying motion recognition in the wireless positioning algorithms.

Despite the fact that the motion recognition solution proposed in this paper provides correct motion recognition for up to 95.53% of the test cases, the motion behavior varies from person to person. In the future we will involve more persons for testing the motion recognition algorithms and determine the most useful features for classification. In addition, more motion states will be considered for indoor navigation. For instance, we currently only consider the “using-stairs” motion in the V-series motions. Other V-series motions such as “using-elevator” will be studied in the future. Lastly, the T-series motions introduce much more confusion because it is possible to combine them with the other motions simultaneously. Therefore, more efforts will be concentrated on the T-series motions in the future. For instance, we are currently studying the use of gyroscopes inside smartphones, which provide heading change rate.

Acknowledgments

This work is a part of the Indoor Outdoor Seamless Navigation for Sensing Human Behavior (INOSENSE) project, funded by the Academy of Finland.

References and Notes

  1. Kraemer, I.; Eissfeller, B. A-GNSS: A Different Approach. Inside GNSS 2009, 4, 52–61. [Google Scholar]
  2. Syrjärinne, J. Studies on Modern Techniques for Personal Positioning. Ph.D. Thesis, Tampere University of Technology, Tampere, Finland, 2001. [Google Scholar]
  3. Mulloni, A.; Wagner, D.; Schmalstieg, D.; Barakonyi, I. Indoor Positioning and Navigation with Camera Phones. IEEE Pervas. Comput. 2009, 8, 22–31. [Google Scholar]
  4. Rouzaud, D.; Skaloud, J. Rigorous Integration of Inertial Navigation with Optical Sensors by Dynamic Networks. J. Navig. 2011, 58, 141–152. [Google Scholar]
  5. Priyantha, N.B.; Chakraborty, A.; Balakrishnan, H. The Cricket Location-Support System. Proceedings of the 6th Annual International Conference on Mobile Computing and Networking, Boston, MA, USA, 6–11 August 2000; pp. 32–43.
  6. Bahl, P.; Padmanabhan, V.N. Radar: An In-Building RF Based User Location and Tracking System. IEEE INFOCOM 2000, 2, 775–784. [Google Scholar]
  7. Pei, L.; Chen, R.; Liu, J.; Tenhunen, T.; Kuusniemi, H.; Chen, Y. Inquiry-Based Bluetooth Indoor Positioning via RSSI Probability Distributions. Proceedings of The Second International Conference on Advances in Satellite and Space Communications (SPACOMM 2010), Athens, Greece, 13–19 June 2010; pp. 151–156.
  8. Pei, L.; Chen, R.; Liu, J.; Kuusniemi, H.; Tenhunen, T.; Chen, Y. Using Inquiry-Based Bluetooth RSSI Probability Distributions for Indoor Positioning. J. Global Position. Syst. 2010, 9, 122–130. [Google Scholar]
  9. Gomes, G.; Sarmento, H. Indoor Location System Using ZigBee Technology. Proceedings of Third International Conference on Sensor Technologies and Applications, Athens, Greece, 18–23 June 2009; pp. 152–157.
  10. Pahlavan, K.; Akgul, O.F.; Heidari, M.; Hatami, A.; Elwell, M.J.; Tingley, D.R. Indoor Geolocation in the Absence of Direct Path. IEEE Trans. Wireless Comm. 2006, 13, 50–58. [Google Scholar]
  11. Hightower, J.; Want, R.; Borriello, G. SpotON: An Indoor 3D Location Sensing Technology Based on RF Signal Strength; UW-CSE 00-02-02; Department of Computer Science and Engineering, University of Washington: Seattle, WA, USA, 2000. [Google Scholar]
  12. Storms, W.; Shockley, J.; Raquet, J. Magnetic Field Navigation in an Indoor Environment. Proceedings of Ubiquitous Positioning Indoor Navigation and Location Based Service (UPINLBS), Kirkkonummi, Finland, 3–4 October 2010.
  13. Foxlin, E. Pedestrian Tracking with Shoe-Mounted Inertial Sensors. IEEE Comput. Graph. Appl. 2005, 25, 38–46. [Google Scholar]
  14. Chen, W.; Chen, R.; Chen, Y.; Kuusniemi, H.; Wang, J.; Fu, Z. An Effective Pedestrian Dead Reckoning Algorithm Using a Unified Heading Error Model. Proceedings of IEEE/ION PLANS 2010 Conference, Palm Springs, CA, USA, 4–6 May 2010.
  15. Mathews, M.B.; Macdoran, P.F.; Gold, K.L. SCP Enabled Navigation Using Signals of Opportunity in GPS Obstructed Environments. J. Navig. 2011, 58, 91–110. [Google Scholar]
  16. Chen, R.; Chen, W.; Chen, X.; Zhang, X.; Chen, Y. Sensing Strides Using EMG Signal for Pedestrian Navigation. GPS Solutions 2011, 15, 161–170. [Google Scholar]
  17. Chen, W.; Chen, R.; Chen, X.; Zhang, X.; Chen, Y.; Wang, J.; Fu, Z. Comparison of EMG-Based and Accelerometer-Based Speed Estimation Methods in Pedestrian Dead Reckoning. J. Navig. 2011, 64, 265–280. [Google Scholar]
  18. Chen, R.; Chen, Y.; Pei, L.; Chen, W.; Kuusniemi, H.; Liu, J.; Leppäkoski, H.; Takala, J. A DSP-Based Multi-Sensor Multi-Network Positioning Platform. Proceedings of the 22nd International Technical meeting of the Satellite Division of the Institute of Navigation ION GNSS 2009, Savannah, GA, USA, 22–25 September 2009; pp. 615–621.
  19. Pei, L.; Chen, R.; Chen, Y.; Leppäkoski, H.; Perttula, A. Indoor/Outdoor Seamless Positioning Technologies Integrated on Smart Phone. Proceedings of the International Conference on Advances in Satellite and Space Communications, Colmar, France, 20–25 July 2009; pp. 141–145.
  20. Liu, J.; Chen, R.; Pei, L.; Chen, W.; Tenhunen, T.; Kuusniem, H.; Kröger, T.; Chen, Y. Accelerometer Assisted Wireless Signals Robust Positioning Based on Hidden Markov Model. Proceedings of the IEEE/ION Position, Location and Navigation Symposium (PLANS) 2010, Indian Wells, CA, USA, 3–6 May 2010; pp. 488–497.
  21. Kuusniemi, H.; Liu, J.; Pei, L.; Chen, Y.; Chen, L.; Chen, R. Reliability Considerations of Multi-Sensor Multi-Network Pedestrian Navigation. Radar Sonar Navig. IET 2012, 6, 157–164. [Google Scholar]
  22. Pahlavan, K.; Akgul, F.; Ye, Y.; Morgan, T.; Alizadeh-Shabdiz, F.; Heidari, M.; Steger, C. Taking Positioning Indoors Wi-Fi Localization and GNSS. Inside GNSS 2010, 5, 40–47. [Google Scholar]
  23. Ekahau Inc. Available online: http://www.ekahau.com/ (accessed on 4 September 2011).
  24. Want, R.; Hopper, A.; Falcao, V.; Gibbons, J. The Active Badge Location System. ACM Trans. Inform. Syst. 1992, 10, 91–102. [Google Scholar]
  25. Schilit, B.N.; LaMarca, A.; Borriello, G.; Griswold, W.G.; McDonald, D.W.; Lazowska, E.D.; Balachandran, A.; Hong, J.I.; Iverson, V. Challenge: Ubiquitous Location-Aware Computing and the “Place Lab” Initiative. Proceedings of the 1st ACM International Workshop on Wireless Mobile Applications and Services on WLAN Hotspots (WMASH 2003), San Diego, CA, USA, 19 September 2003; pp. 29–35.
  26. Frank, K.; Nadales, M.J.V.; Robertson, P.; Angermann, M. Reliable Real-Time Recognition of Motion Related Human Activities Using MEMS Inertial Sensors. Proceedings of the 23rd International Technical Meeting of the Satellite Division of the Institute of Navigation, Portland, OR, USA, 21–24 September 2010.
  27. Susi, M.; Borio, D.; Lachapelle, G. Accelerometer Signal Features and Classification Algorithms for Positioning Applications. Proceedings of International Technical Meeting, San Diego, CA, USA, 24–26 January 2011.
  28. Pei, L.; Chen, R.; Liu, J.; Chen, W.; Kuusniemi, H.; Tenhunen, T.; Kröger, T.; Chen, Y.; Leppäkoski, H.; Takala, J. Motion Recognition Assisted Indoor Wireless Navigation on a Mobile Phone. Proceedings of the 23rd International Technical Meeting of The Satellite Division of the Institute of Navigation, Portland, OR, USA, 21–24 September 2010; pp. 3366–3375.
  29. Pei, L.; Chen, R.; Liu, J.; Kuusniemi, H.; Chen, Y.; Tenhunen, T. Using Motion-Awareness for the 3d Indoor Personal Navigation on a Smartphone. Proceedings of the 24rd International Technical Meeting of The Satellite Division of the Institute of Navigation, Portland, OR, USA, 19–23 September 2011; pp. 2906–2912.
  30. Poppe, R. Vision-Based Human Motion Analysis: An Overview. Comput. Vision Image Understand. 2007, 108, 4–18. [Google Scholar]
  31. Chung, T.Y.; Chen, Y.-M.; Hsu, C.-H. Adaptive Momentum-Based Motion Detection Approach and Its Application on Handoff in Wireless Networks. Sensors 2009, 9, 5715–5739. [Google Scholar]
  32. Fong, D.T.-P.; Chan, Y.-Y. The Use of Wearable Inertial Motion Sensors in Human Lower Limb Biomechanics Studies: A Systematic Review. Sensors 2010, 10, 11556–11565. [Google Scholar]
  33. Yang, C.-C.; Hsu, Y.-L. A Review of Accelerometry-Based Wearable Motion Detectors for Physical Activity Monitoring. Sensors 2010, 10, 7772–7788. [Google Scholar]
  34. Zeng, H.; Zhao, Y. Sensing Movement: Microsensors for Body Motion Measurement. Sensors 2011, 11, 638–660. [Google Scholar]
  35. Musleh, B.; García, F.; Otamendi, J.; Armingol, J.M.; De la Escalera, A. Identifying and Tracking Pedestrians Based on Sensor Fusion and Motion Stability Predictions. Sensors 2010, 10, 8028–8053. [Google Scholar]
  36. Kavanagh, J.J.; Menz, H.B. Accelerometry: A Technique for Quantifying Movement Patterns During Walking. Gait Posture 2008, 28, 1–15. [Google Scholar]
  37. Baek, J.; Lee, G.; Park, W.; Yun, B. Accelerometer Signal Processing for User Activity Detection. Knowl. Based Intell. Inform. Eng. Syst. 2004, 3215, 610–617. [Google Scholar]
  38. Chen, W.; Fu, Z.; Chen, R.; Chen, Y.; Andrei, O.; Kröger, T; Wang, J. An Integrated GPS and Multi-Sensor Pedestrian Positioning System for 3D Urban Navigation. Proceedings of Joint Urban Remote Sensing Event, Shanghai, China, 20–22 May 2009; pp. 1–6.
  39. Yang, J. Toward Physical Activity Diary: Motion Recognition Using Simple Acceleration Features with Mobile Phones. Proceedings of the 1st International Workshop on Interactive Multimedia for Consumer Electronics (IMCE), Beijing, China, 19–23 October 2009; pp. 1–10.
  40. Suykens, J.A.K.; Vandewalle, J. Least Squares Support Vector Machine Classifiers. Neur. Process. Lett. 1999, 9, 293–300. [Google Scholar]
  41. Boser, B.E.; Guyon, I.M.; Vapnik, V.N. A Training Algorithm for Optimal Margin Classifiers. Proceedings of the 5th Annual Workshop on Computational Learning Theory, Pittsburgh, PA, USA, 27–29 July 1992; pp. 144–152.
  42. Hospodar, G.; Gierlichs, B.; Mulder, E.D.; Verbauwhede, I.; Vandewalle, J. Machine Learning in Side-Channel Analysis: A First Study. J. Cryptograph. Eng. 2011, 1, 293–302. [Google Scholar]
  43. Nelder, J.A.; Mead, R. A Simplex Method for Function Minimization. Comput. J. 1965, 7, 308–313. [Google Scholar]
  44. Cohen, G.; Ruch, P.; Hilario, M. Model Selection for Support Vector Classifiers via Direct Simplex Search. Proceedings of the FLAIRS Conference, Clearwater Beach, FL, USA, 15–17 May 2005; pp. 431–435.
  45. Youssef, M.; Agrawala, A.; Shankar, A.U. WLAN Location Determination via Clustering and Probability Distributions. Proceedings of the First IEEE International Conference on Pervasive Computing and Communications (PerCom 2003), Dallas Fort-Worth, TX, USA, 23–26 March 2003; pp. 143–150.
  46. Roos, T.; Myllymaki, P.; Tirri, H.; Misikangas, P.; Sievänen, J. A Probabilistic Approach to WLAN User Location Estimation. Int. J. Wirel. Inform. Netw. 2002, 9, 155–164. [Google Scholar]
  47. Ristic, B.; Arulampalam, S.; Gordon, N. Beyond the Kalman Filter; Artech House: Boston, MA, USA, 2004. [Google Scholar]
  48. Rabiner, L.R. A Tutorial on Hidden Markov Models and Selected Applications in Speech Recognition. Proc. IEEE 1989, 77, 257–286. [Google Scholar]
Figure 1. S-series (left and middle: ST, right: SS).
Figure 1. S-series (left and middle: ST, right: SS).
Sensors 12 06155f1 1024
Figure 2. W-series (left: WH, middle: WS, and right: WF).
Figure 2. W-series (left: WH, middle: WS, and right: WF).
Sensors 12 06155f2 1024
Figure 3. T-series (UT).
Figure 3. T-series (UT).
Sensors 12 06155f3 1024
Figure 4. V-series (left: US and right: DS).
Figure 4. V-series (left: US and right: DS).
Sensors 12 06155f4 1024
Figure 5. Accelerometer readings.
Figure 5. Accelerometer readings.
Sensors 12 06155f5 1024
Figure 6. Magnetometer readings.
Figure 6. Magnetometer readings.
Sensors 12 06155f6 1024
Figure 7. Mapping of the data from the input space to a high-dimensional feature space.
Figure 7. Mapping of the data from the input space to a high-dimensional feature space.
Sensors 12 06155f7 1024
Figure 8. The projections of LS-SVM hyperlanes in the original feature space. (Class 1: ST, 2: SS, 3: WH, 4: WS, 5: WF, 6: UT, 7: US, 8: DS).
Figure 8. The projections of LS-SVM hyperlanes in the original feature space. (Class 1: ST, 2: SS, 3: WH, 4: WS, 5: WF, 6: UT, 7: US, 8: DS).
Sensors 12 06155f8 1024
Figure 9. LS-SVM Motion state predictions (Motion state 1: ST, 2: SS, 3: WH, 4: WS, 5: WF, 6: UT, 7: US, 8: DS).
Figure 9. LS-SVM Motion state predictions (Motion state 1: ST, 2: SS, 3: WH, 4: WS, 5: WF, 6: UT, 7: US, 8: DS).
Sensors 12 06155f9 1024
Table 1. Motion state definition.
Table 1. Motion state definition.
StateSeriesDefinition
STSA state where a user keeps a phone in hand without any movement.
SSSUser's location does not change but the phone is in a swinging.
WSWWalking with a small arm swinging.
WHWUsing the navigation application on the handset while walking.
WFWFast walking with a significantly arm swinging.
UTTMaking a U-turn.
USVGoing up stairs.
DSVGoing down stairs.
Table 2. Feature definition.
Table 2. Feature definition.
Feature No.Feature NameFeature Definition
1MeanAccXMean value of the acceleration along x-axis.
2MeanAccYMean value of the acceleration along y-axis.
3MeanAccZMean value of the acceleration along z-axis.
4MeanAccMean value of the acceleration.
5MeanDynAccVMean value of the dynamic acceleration in the vertical plane.
6MeanDynAccHMean value of the dynamic acceleration in the horizontal plane.
7MeanAccHMean value of the horizontal acceleration.
8MeanAccVMean value of the vertical acceleration minus gravity acceleration.
9MeanDynAccMean value of the dynamic acceleration.
10VarAccXVariance of the acceleration along x-axis.
11VarAccYVariance of the acceleration along y-axis.
12VarAccZVariance of the acceleration along z-axis.
13VarAccVariance of the acceleration.
14VarDynAccVVariance of the dynamic acceleration in the vertical plane.
15VarDynAccHVariance of the dynamic acceleration in the horizontal plane.
16VarAccHVariance of the horizontal acceleration.
17VarAccVVariance of the vertical acceleration.
18VarDynAccVariance of the dynamic acceleration.
19MeanMagMean value of the heading.
20DiffMagHeading change.
21VarMagVariance of the heading.
221stFreqAcc1st dominant frequency of the acceleration.
23Amp1stFreqAccAmplitude of the1st dominant frequency of the acceleration.
242ndFreqAcc2nd dominant frequency of the acceleration.
25Amp2ndFreqAccAmplitude of the 2nd dominant frequency of the acceleration.
26FreqDiffAccDifference between two dominant frequencies.
27AmpScaleAccAmplitude scale of two dominant frequencies.
Table 3. Classifier vs. Recognition Rate vs. Features.
Table 3. Classifier vs. Recognition Rate vs. Features.
ClassifierRecognition Rate

LS-SVMBN-GMMDTLDAQDA
Feature 487.15*167.0477.6675.9874.30
Feature 586.0353.0756.4362.0163.13
Feature 4,595.5373.7483.8086.5986.03
Feature 4,5,2292.1779.3388.83*287.1586.03
Feature 4,5,22,2392.1886.5988.8384.3683.24
Feature 4,5,24,2591.6264.8085.4873.74null*3
Feature 4,5,22,2492.1875.9888.8374.86null
Feature 4,5,2692.7473.1885.4873.1887.71
Feature 4,5,2792.7478.2183.8083.2488.25
Feature 4,5,26,2794.9777.1085.4877.10null
Feature 4,5,19,20,2188.2768.7286.0383.24null
Feature 4,5,19,2187.7174.8682.1284.92null
Feature 4,5,2188.2377.1083.2487.15*480.45
Feature 4,5,21,2793.8681.0184.9286.03null
Feature 1,2,390.5067.6065.36nullnull
Feature 1,2,3,4,592.7476.5482.68nullnull
Feature 5,6,7,8,988.2772.0782.12nullnull
Feature 13,1483.8047.4976.5464.2564.80
Feature 17,1893.3048.0470.3959.7868.72
Feature 10-1880.4551.4082.12nullnull
Feature 1885.4842.4653.0752.5158.10
All Features53.6368.1664.25nullnull

*1The bold and italic number indicates the best recognition rate in each feature combination.*2The bold and underlined number indicates the best recognition rate in each classifier.*3The null value is caused by the features which do not satisfy the requirements of the classifier.*4The recognition rates of combination feature 4, 5, 21 and feature 4, 5, 22 are the equally best in LDA classifier.

Table 4. Confusion Matrix for the motion recognition from LS-SVM classifier (Unit: %).
Table 4. Confusion Matrix for the motion recognition from LS-SVM classifier (Unit: %).
Labelled Motion StateRecognized Motion State

STSSWHWSWFUTUSDS
ST81.25000018.7500
SS0100000000
WH0010000000
WS0001000000
WF0000100000
UT0000010000
US0000022.2277.780
DS0000000100
Table 5. Static Test (Unit: m).
Table 5. Static Test (Unit: m).
Static TestMLHMM (Motion-assisted)
Mean3.431.22
RMSE5.982.55
MaxErr219
MinErr00
Table 6. Stop-Go Test (Unit: m).
Table 6. Stop-Go Test (Unit: m).
Stop-Go TestMLHMM (Motion- assisted)
Mean4.383.53
RMSE6.024.55
MaxErr189
MinErr00
Table 7. Confusion matrix for floor detection using ML wireless positioning (Unit: %).
Table 7. Confusion matrix for floor detection using ML wireless positioning (Unit: %).
Estimated FloorLabelled Floor

1st2nd3rd
1st93.946.060
2nd4.0092.004.00
3rd017.9582.05
Table 8. Confusion matrix for floor detection using motion-assisted HMM wireless positioning (Unit: %).
Table 8. Confusion matrix for floor detection using motion-assisted HMM wireless positioning (Unit: %).
Estimated FloorLabelled Floor

1st2nd3rd
1st96.973.030
2nd4.0096.000
3rd05.1394.87

Share and Cite

MDPI and ACS Style

Pei, L.; Liu, J.; Guinness, R.; Chen, Y.; Kuusniemi, H.; Chen, R. Using LS-SVM Based Motion Recognition for Smartphone Indoor Wireless Positioning. Sensors 2012, 12, 6155-6175. https://doi.org/10.3390/s120506155

AMA Style

Pei L, Liu J, Guinness R, Chen Y, Kuusniemi H, Chen R. Using LS-SVM Based Motion Recognition for Smartphone Indoor Wireless Positioning. Sensors. 2012; 12(5):6155-6175. https://doi.org/10.3390/s120506155

Chicago/Turabian Style

Pei, Ling, Jingbin Liu, Robert Guinness, Yuwei Chen, Heidi Kuusniemi, and Ruizhi Chen. 2012. "Using LS-SVM Based Motion Recognition for Smartphone Indoor Wireless Positioning" Sensors 12, no. 5: 6155-6175. https://doi.org/10.3390/s120506155

Article Metrics

Back to TopTop