As the development of Indoor Location Based Service (Indoor LBS), a timely localization and smooth tracking with high accuracy are desperately needed. Unfortunately, any single method cannot meet the requirement of both high accuracy and real-time ability at the same time. In this paper, we propose a fusion location framework with Particle Filter using Wi-Fi signals and motion sensors. In this framework, we use Extreme Learning Machine (ELM) regression algorithm to predict position based on motion sensors and use Wi-Fi fingerprint location result to solve the error accumulation of motion sensors based location occasionally with Particle Filter. The experiments show that the trajectory is smoother as the real one than the traditional Wi-Fi fingerprint method.

1. Introduction

Nowadays, indoor location and tracking are very important in our daily life. Indeed, many applications require timely and accurate location information of the mobiles (context-aware application, emergency situation…) [1, 2]. But Global Positioning System (GPS), Assisted GPS (AGPS), and Mobile Base Station (MBS) cannot be used in indoor areas, as the signals cannot reach indoor area.

Fortunately, now many buildings are equipped with WLAN Access Points (APs), such as office buildings, hospitals, shopping malls, museums, and airports. It becomes easy to offer indoor location services without any other infrastructure investment. A common idea of Wi-Fi based indoor location is fingerprint method [38]. It is a classical classification problem where different supervised machine learning techniques have been used. A lot of researches show that Wi-Fi signal can generate good prediction for indoor localization [9], but it will spend some time to scan the Wi-Fi signal around so that it cannot offer continuous location service.

Nowadays, the smartphone is the most wildly used device, in part due to its abundant inertial sensors, such as accelerometer, magnetometer and gyroscope. They can be used to measure people’s motion state, including walking speed and orientation. Based on this information, we can estimate the relative changing of position by determining a pedestrian’s movement. This kind of methods is based on the Inertial Navigation System (INS) [10] method, which can offer continuous localization. But due to its iterative process, we can only estimate the position with high accuracy in a short time. The error accumulation will lead the gap between the movement and the estimated result increases continuously.

By the way, the power consumption is also important. As far as we know, the battery usage of Wi-Fi and communication module is several dozen times higher than the Inertial Measurement Unit (IMU) that consists of gyroscopes and accelerometers. Carroll and Heiser [11] also did some analysis of power consumption in smartphones and the same conclusions can be seen.

Therefore, in this paper, we combine the advantages of two methods and present real-time and accurate indoor localization based on fusion model of Wi-Fi fingerprint and motion Particle Filter. We take use of the accurate Wi-Fi location result to modify the motion Particle Filter in the correction step, so to eliminate the error accumulation caused by motion sensors based location. And this system includes three main modules: sensors data based location model (ELM regression); Wi-Fi based location model (ELM + -NN classification); and the fusion Particle Filter model.

The rest of the paper is organized as follows. We firstly review some related works of indoor location and tracking in Section 2. Then we give a brief introduction of proposed method in Section 3. Section 4 demonstrates the feature selection for sensors data. In Section 5, we introduce ELM algorithm. After that, we introduce Particle Filter for sensors based location in Section 6. In Section 7, we introduce the fusion model of Wi-Fi fingerprint and motion Particle Filter. Experiments and performance evaluation are given in Section 8. In the end, we make a short conclusion in Section 9.

As the basic support of Indoor LBS application, a timely localization with high-accuracy and low power consumption is very important. At present, one of the most popular techniques is Wi-Fi fingerprint based location [38]. References [38] take use of the existing wireless network infrastructures to avoid extra deployment costs.

Wi-Fi fingerprint based locations contain two phrases: offline training and online mapping. During the offline phase, a fingerprint information map will be built. In this map, there are some registered points and corresponding Received Signal Strength (RSS) from the APs around. On the online phase, people receive the Wi-Fi signals, and then some machine learning algorithms will be used to predict the position based on fingerprint dataset. It becomes a classical classification problem where different supervised machine learning techniques have been used to train classifiers, using the signal strength from different APs as the feature and providing the location estimation as their output estimation. Nearest Neighbor (-NN), Decision Tree (DT), Bayesian, Support Vector Machine (SVM), and ELM [12] are most frequently used by location fingerprint. Among all the algorithms above, ELM is more and more widely used for its competitive fast learning speed during both offline and online phrases.

Although Wi-Fi signals can generate good prediction model for indoor position estimation, it will take a while to scan the Wi-Fi signals so that it cannot offer continuous location service. As shown in Figure 1, we select four different android smartphones (HTC G12, Sony LT26ii, HTC G10, and Xiaomi 1S). With each smartphone, we scan the Wi-Fi for 10 times (Test. 1–10). We can conclude that every time we collect the Wi-Fi signals, it will take more than 1 second on average. That is to say, Wi-Fi based location cannot offer immediately location result due to the time consumption of signals scanning.

According to the experiments on Wi-Fi based location system developed by our lab, shown in Figure 2, we can get one location result in every 2 seconds including some other time consumption of transmission and calculation.

In order to overcome the shortcoming of Wi-Fi based location, we can take other measures which can offer continuous location service. Nowadays, as a lot of sensors are integrated in smart phones, so that we can use them to measure people’s motion state, including distance and orientation. Distance estimation mainly based on pedestrian model, including step detection and a step model. Step detection typically relies on peak detection over accelerometer [13]. But the result is not good enough, because it is sensitive to noise and other irrelevant motions, producing a high rate of false positives. And there are also some other methods that rely on detecting features such as zero-cross point [14]. Orientation is relatively easier to get via magnetometer, gyroscope, and accelerometer data so that we can get user heading orientation information with high accuracy easily. The orientation of smartphones themselves can be obtained from the motion sensors Application Programming Interface (API) [15] or computed from the raw sensors data.

But based on motion sensors, we can only estimate the position with high accuracy in a short time; it is difficult to locate independently for a long time period because of the error accumulation. To solve this problem, a lot of previous works have been done. Li et al. [16] not only developed an algorithm for reliable detection of steps, heading directions, and accurate estimation of step length, but also built an end-to-end location system integrating these models. But they still did not solve the problem of location error accumulation. Evennou et al. [1] applied a developed Particle Filter method to WLAN location determination technique and proposed an indoor mobile positioning system. They used the Particle Filter and its constraint on a Voronoi diagram to represent an interesting, so as to handle the variations of the signal strength measurements. It can also aggregate different information like signal strength and the map to obtain correct trajectories without wall-crossings. But in real applications, it is difficult to get the geography Information.

From the related works above, we can see that Wi-Fi based location can offer high accuracy, but it needs high time and power consumptions. Inertial sensors based location estimates the position with high accuracy in a short time, but the shortage is the error accumulation. Thus, in this paper, we present real-time and accurate indoor location based on fusion model of Wi-Fi fingerprint method and motion Particle Filter.

3. Overview of Our Method

The architecture of our method is shown in Figure 3. It contains three main parts. (1) Sensors data based short-time location with ELM regression: we can determine the orientation and velocity to tracking users, but as every location result is based on the former one, it will cause error accumulation. (2) Wi-Fi based location with ELM classification and -NN: we can get high location accuracy with this method, but as the time consumption of Wi-Fi signals scanning and data transmission, we can only get discrete result in every several seconds. (3) Fusion Particle Filter model: in order to solve the problems in the two methods mentioned above, we add a fusion Particle Filter model to eliminate the error accumulation caused by motion sensors based location with Wi-Fi location result in the correction step and offer a smooth location trajectory.

4. Feature Selection for Sensors Data

Currently, there are a lot of sensors integrated in smartphones. Some previous methods only directly use the API data, such as orientation. But sometimes, the API data cannot offer high precision. As shown in Figure 4, the orientation directly offered by API has a big bias with the real one caused by the environment changing. So in this paper, we use regression learning algorithm with a variety of sensors data to determine the motion state.

In order to find the strong correlation between movement state and sensors data, we investigate the existing sensors on the smartphone [15]. Generally, there are seven sensors that can reflect motion state, shown in Table 1.

When we mention localization, we want to get the orientation and velocity from sensors data. Among all the sensors above, the accelerometer, magnetic field, orientation, gyroscope, and gravity sensors have correlation with the orientation and velocity. We tried different combinations of them to predict the orientation and velocity. Finally, we find that velocity has a strong relationship with accelerometer , , and axes and gyroscope , , and axes, as seen in the following formula:And we use orientation , , and axes, magnetic field , , and axes as the features to determine orientation, as seen in the following formula:The reason why we choose as the feature to predict is that different walking speed causes different shaking degree, which can be observed from the accelerometer readings. As shown in Figure 5, we can conclude that this user walks faster and faster.

We use the same way to choose as the feature vector to predict orientation . Although orientation sensor’s output cannot match the real orientation very well, it can still offer some positive effect. Magnetic field measures the ambient geomagnetic field which has strong relationship with orientation.

In order to use machine learning algorithm to predict velocity and orientation, we firstly prepare training data.

Firstly, experiment participants walk along a fixed route with a smart phone. Motion sensor data will be collected, and participants will label the time at given points. The frequency of sensors is different in each smartphone. In our experiments  Hz.

Secondly, we use Cubic Spline Interpolation [17] to smooth the trajectory.

Thirdly, we use slide-window to segment the trajectory with window length . The will be determined in the experiment, but we must keep so that in every single slide-window there is at least one integrated data. Let us take component of acceleration in th window as an example; we use the average of the sensors data as the feature according towhere is the data number collected by the smartphone.

According to the smooth trajectory, in the th stage, we can measure the orientation and velocity , which can be treated as the label for regression algorithm.

5. ELM Algorithm

After feature selection, we are going to predict the motion state. Commonly, the accelerometer has been used to count the number of steps. Then estimate the distance with the user’s steps stride [18]. But it depends on the assumption that user’s steps strides are always the same, which is hard to satisfy in practical applications.

To avoid this assumption, we adopt ELM to train an effective model which can offer real-time prediction of orientation and walking speed.

ELM [12] is an Artificial Neutral Network (ANN), especially Single Layer Feedforward Networks (SLFN), developed by Huang et al. Given arbitrary distinct samples , . Here, is an input vector and is an target vector . The network with hidden nodes is shown in Figure 6. The output function of this network can be represented as follows:where and are the learning parameters of hidden nodes and is the weight connecting the th hidden node to the output node. is the output of the th hidden node with respect to the input . For additive hidden node with the activation function (e.g., sigmoid and threshold), is given blow:If an SLFN with hidden nodes can approximate these samples with zero errors, this then implies that there exist , , and such thatEquation (6) can be summarized aswhereAccording to [12], the hidden node parameters and (input weights and biases or centers and impact factors) of SLFNs need not be tuned during training and may simply be assigned with random values. Equation (7) then becomes a linear system and the output weights are estimated aswhere is the Moore-Penrose generalizes inverse of hidden layer output matrix . Equation (10) can be seen as a linear system; the least-squares solution of (8) is the answer of ELM.

By now, ELM and some other related algorithms such as OS-ELM [19, 20], SELM [21, 22], and Unsurprised-ELM [22] have been developed and wildly applied in some real applications. Huang [23] made a further insight into ELM, including some discussion about random neurons, random features, and kernels. And in [24, 25], Cao et al. made some improvement to the basic ELM and achieved a good performance. Because of the fast learning speed and good learning ability, ELM has been wildly used in ubiquitous computing applications, such as activity recognition [2629]. That is why we use ELM model both in offline learning and in online prediction. Our lab has done a lot of Wi-Fi indoor location research based on it and achieved good performance [21, 30].

From all the information above, we can see that ELM model can be used in regression and classification problems. In our application, the velocity and orientation are all continuous variable. So we use ELM as a regression model.

(i) ELM Model for Velocity. For velocity, the input vector is a vector with six features:and the output vector is only a scalar value .

(ii) ELM Model for Orientation. For orientation, the input is a vector with four features:and the output vector in also a scalar value .

According to [31], we also have offline and online phases. During offline phases, we will collect the sensors data and the trajectory to train these two models mentioned above. During the online phases, we will use sensors data and models to determine and . Then we can use (13) to calculate the current position. ConsiderAs our method is based on an iterative process, so the initial position should be given.

By now, we can already track the trace, given the initial position, in every second; we collect the sensors data and use these two ELM models to determine and . So that, the current position will be calculate by (13). But unfortunately, sensors on smart phone are not accurate enough to offer data with high confidence. For a short time, it is really a reliable method, but as time goes on, error accumulation will destroy the reliability.

6. Particle Filter for Sensors Based Location

Particle Filter [32] is an on-line posterior density estimation algorithm estimating the posterior density of the state-space by directly implementing the Bayesian recursion equations. It provides a well-established methodology for generating samples from the required distribution without requiring assumptions about the state-space model or the state distributions. The state-space model can be nonlinear and the initial state and noise distributions can take any form required. For a lot of position and navigation problems, common motion model based filters can be applied. Models that are linear in the state dynamics and nonlinear in the measurements are considered [33].

State Transition Equation. Consider

Observation Equation. Considerwhere : state vector, : measured inputs, : process noise, : measurements, and : measurement error.

In our application, we turn the model, (14) and (15), into a specific one, as shown in In (16), denotes the state vector associated to each particle (position). is the elapsed time between the th and the th measurements. is the process noise. Here the used process is a zero mean Gaussian noise with a 0.1 m/s2 variance which is a realistic model of pedestrian movement.

Equation (17) is observation equation, which denotes the relationship between the hidden states and the observation states . Because we directly observe the coordinate point from ELM regression algorithm, there is no measurement error in this process, so we set to be 0.

A Particle Filter approximates the position at time by a set of particles. Each particle contains a position and a weight . indicates the importance of the th particle. In the case of an indoor movement, the following law has been retained:With the position returned by the ELM regression algorithm, the position of the th particle at time , and the measurement confidence. The smaller will be, the more confident the user is in the measurement. That would mean that there is very little variation in the measurements for the same position. Here, was chosen.

According to the process of Particle Filter algorithm, there are four steps in a circle: prediction, correction, particle update, and resampling. At each second, we will determine a new position by the following steps.

(i) Feature Selection(1)We collect sensors data from mobile and calculate the feature vector according to (3).(2)Then we use two ELM regression models to calculate the orientation and velocity .

(ii) Then We Go to Particle Filter Phase(3)Prediction: during this step, every particle will propagate to a new one based on state transition equation (16). After that, all the particles move to new places.(4)Correction: now, we have all the particles and we must give them the weight; according to , , and location of last moment, we can calculate the observed value by (17). Then we can use (18), from which we can see that the more particle far away from the observed value, the less value the particle has.(5)Particle Update: the weight update equation is given in [33, 34]:To obtain the posterior density function, we have to normalize those weights. After a few iterations, only a few particles can still alive. So we should go to resampling step to avoid having few remaining particles.(6)Resampling: the resampling step is the critical point for the PF. The fundamental idea is to remove the particles which have too low weight. Various resampling algorithms can be chosen. We choose the Sequential Importance Resampling (SIR) for the reason that it is a simple one which is wildly used in SLAM (Simultaneous Location and Mapping) [35]. Take samples with replacement from the set , where the probability to take th sample is . Let .(7)Finally, we can calculate the new location result by . And then go to step (1) until stop.

7. Fusion Model of Wi-Fi Fingerprint and Motion Particle Filter

By now, only the sensors data are used for localization. But they cannot offer long time location service with high accuracy due to the error accumulation. To solve this problem, we present a fusion Particle Filter model, combining the advantages of motion sensors based location and Wi-Fi based location.

Wi-Fi fingerprint based location methods include offline learning and online prediction. During the offline phrase, we collect fingerprints, including coordinate and Wi-Fi Received Signal Strength Indication (RSSI) measured at . Actually, we do not know the total number of Wi-Fi Aps and their position. We firstly calibrate all the location area and then choose the several most frequent APs as the feature. After that, we change all the fingerprints to only contain these frequent APs and supplement the missing items with default value −95 dB.

According to [36], during the online phase, we use ELM classification and -NN algorithm.

With ELM, we can find the Nearest Neighbor points, but we do not know the distance because the ELM only offers the nearest points but not the weights. So we use the Euclidean distance of signal strength to determine the weight according toWhen we use smart phone to do Wi-Fi based indoor location, it takes a little while to collect Wi-Fi data. So we can only get a location result in every second. To eliminate the error accumulation caused by sensors based location, we add the Wi-Fi location result in particle update step and resampling step of Particle Filter.

As shown in Figure 7, once the smartphone begins to locate, the Wi-Fi signals and motion sensors data will be collected. By using the motion sensors data, we get a location result in every 200 milliseconds. And Wi-Fi based location data will arrive in about every 2 seconds.

We promote the Particle Filter mentioned in last section to a fusion one by adding the Wi-Fi location result in the correction step. When we go to the correction step, we should check whether there comes a Wi-Fi location result. If yes, we use the Wi-Fi location point as the observation value to calculate all particles’ weight. And if not, we still use the result predicted by motion sensors data. With the fusion model, our system can offer a highly accurate location result with limited time.

8. Experiments and Performance Evaluation

In this section, we do several experiments to evaluate the performance of our method. All the experiments are running on smartphones and a computer with following configuration.

Smart Mobile Phones. See Table 2. 

ComputerOperation System: Windows XP Professional SP3.CPU: Intel Pentium(R) 4 CPU.Main frequency: 3.2 GHz.RAM: 2 G.

8.1. Experimental Design and Data Preparing

In order to evaluate the performance, we build a test platform in our work space, as shown in Figure 8. Including the aisle, it is about 100 m2 ().

For the reason that we apply ELM algorithm in both Wi-Fi based location and senor based location, we will collect data to train the model during offline phase.

Concerning sensors data, we plan a fixed route including straights and curves, shown in Figure 9. People walk along this trajectory with any speed: slow, middle, fast, and even run. And they record the time at every label point by touching the volume key. As shown in Figure 10. In order that we can measure different types of motion, there are four persons doing the collection work, and each person walks five times. Every smart phone will be used once by each person.

After collecting the original sensors data, we use Cubic Spline Interpolation to smooth the trajectory. Thirdly, we use slide-window to segment the trajectory with window length , shown in Figure 11. The will be determined in the experiment, but we must make sure so that in every single slide-window there is independent data. In every window, we will calculate feature by (1). And measure the orientation and speed from the red points.

For the Wi-Fi based location part, we use the fingerprint method. So we also have to build a signal distribution map. We select 36 points that can cover the test area, shown in Figure 12. Between every two adjacent points, it is about 1.5 m~2 m. We do not strictly require label points equally distributed in this area. We register four times at each point, collect Wi-Fi data for three times, and then use the mean value.

During the online phase, people were walking along the trajectory, shown in Figure 9, to collect testing data. We let a user to carry a smart phone to collect sensors data and get the Wi-Fi location result from the server. Then we will use these raws to predict the trajectory. After that, we can evaluate the performance by comparing with groundtruth.

8.2. Parameters Selection
8.2.1. Determine the Time Window Length

Firstly, we will determine the window length . For the reason that the sensors frequency is  Hz. In order to void the influence caused by noise, we use the mean value as the features. So we should ensure that there are about ten samples in each window. That is to say the should be bigger than 160 milliseconds.

We use Mean Square Error (MSE) [37] to measure the accuracy in ELM regression algorithms. The results are shown in Table 3. We can see that we can get lowest MSE in both orientation and velocity. So we set to be 200 ms.

8.2.2. Parameters of ELM Regression Models

For basic ELM, we only need to determine the number of hidden nodes . The input weights and biases of hidden nodes can be generated randomly. We have collected 5316 training samples and divided them into 10 parts. Then we use 10-fold cross validation to select best parameter; the results are shown in Figure 13.

From Figure 13, we can come to conclusions that, for the ELM regression model of velocity, 500 hidden nodes are suitable and, for orientation regression, we can minimize test error when the model has 1000 hidden nodes. Finally, we set to be 500 for velocity and 1000 for orientation. And we chose Sigmoid [38] function for orientation and Hardlim [39] function for velocity.

8.3. Experimental Performance

In this section, in order to validate the proposed method, the comparisons to the existing methods are necessary. As the proposed method contains Wi-Fi and sensors information and takes use of ELM and Particle Filter algorithms, comparison experiments with some related methods should be involved. We firstly consider the Wi-Fi based location only and tried four different methods (-NN, ELM, ELM + Kalman filter, and ELM + Particle Filter). Then we measure the location error of some sensors based methods and proposed method. Also the error accumulation tests have been considered as it is the key factor of location accuracy. Finally, we give a statistical result of the time consumption in our experiment to state that our proposed method is real practical.

8.3.1. Evaluate the Location Accuracy

Firstly, we compare the location performance of -NN, ELM, Kalman filter, and Particle Filter based on Wi-Fi fingerprint. As shown in Figure 14, ELM performs better than -NN, but it is still not very good as expected. We can explain the reason as that every location process is separated with each other. They are not treated as a sequence; thus some relevant information has been missed. So we apply Kalman filter and Particle Filter to the location results of ELM. Fortunately, both of them can raise the accuracy by big percentages. But, Particle Filter performs much better as it is a nonlinear system, which is more effective to simulate the walking pattern.

Besides the Wi-Fi information, sensors data is also very useful for indoor location. It is usually used to detect gait and then use a default step length to estimate the walking distance. In proposed method, we use ELM model to build a mapping relationship of sensors data and walking pattern. Moreover, Kalman filter and Particle Filter also can be used to smooth the initial location results. To evaluate their performance, we not only compare the location mean error, but also calculate the location trajectory using Matlab. From Table 4, we can conclude that, comparing to gait detection based method mentioned in [40], ELM based methods can get better results. And with the Particle Filter, mean error becomes smaller. But we can see that when we apply the Kalman filter to the ELM location result, the mean error is bigger than before. We explain it as the function of Kalman filter is to make the trajectory smoother, not to minimize the mean error, which can be seen in Figure 14. But filters can only make the trajectory smoother; they cannot solve the error accumulation problem. In order to solve the error accumulation, we combine the Wi-Fi location with the sensors data based location to come into being proposed method, which indeed can offer a small mean error.

From Figure 15(a), we can see that trajectory of sensors based location is not very good. As time goes on, the trajectory is getting more and more far away from groundtruth. The reason is that, within a short period of time, the sensors can offer good valuation of walking orientation and speed, but the bias also exists. The next result is based on the previous step, so the bias will cumulate to unbearable error after a period of time. Figure 15(b) shows the trajectory of sensors based location with ELM and Kalman filter. We can see it making the trajectory smoother in some turnings. But it is a little more far from the groundtruth. We explain it as that the function of Kalman filter is to smooth the trajectory, but not to minimize the location error. Figure 15(c) indicates the sensors based location with ELM and Particle Filter. From it, we can conclude that the Particle Filter can make the trajectory smoother than before, but it does not improve the error accumulation by a large scale. The proposed method can be seen in Figure 15(d). It is really better than those methods mentioned above. It can offer a timely and highly accurate location result.

8.3.2. Experiments on Error Accumulation

In order to value the error accumulation existing in sensors based location and how our method improved the accuracy with the help of Wi-Fi based location and positive impact of Particle Filter, we calculate the distance error between the predicted position and the real one. And the result is shown in Figure 16. From that, we can conclude that when we use sensors only, the location error will accumulate into unbearable distance as time goes on. When we added Kalman filter to it, the location error increases more than before, which can be explained as that Kalman filter’s function is to smooth the trajectory, not to minimize the location error. Fortunately, when we add Particle Filter, the location error decreases, but the error accumulation still leads the location accuracy divergence. When we use the Wi-Fi based location result to calibrate it within the Particle Filter framework, it will eliminate the error accumulation and keep the predicted position high precision.

8.3.3. Evaluate the Location Time Consumption

We also did the experiment of the time consumption of Wi-Fi based location and our methods.

From Figure 17 we can see that when we use Wi-Fi based location method on each kind of smart phone, it will take about 4.5 seconds. We can see the point indicating the location result jumping on the map. But using our method, the time consuming is almost 200 milliseconds, so that we can get a smoothly trajectory on the map.

9. Conclusion and Future Work

In this paper, we have presented a real-time and accurate indoor localization based on fusion model of Wi-Fi fingerprint and motion Particle Filter. The reason we raised this problem is that: a lot of sensors are integrated in smart phones, so we can easily get sensors data and Wi-Fi signals which can be used for indoor localization. But any single method cannot get satisfactory result. So we combine Wi-Fi based location and sensors based inertial navigation. And we also use Particle Filter and ELM algorithm to improve the location accuracy. From the experiments result, we can see that our method has achieved a good performance. But to get a better accuracy, we think that another technology should be taken into account. RFID may be the suitable candidate. On the other hand, in order to speed up the localization service, maybe MapReduce framework [41] or Parallel Framework [4246] can be involved.

Conflict of Interests

The authors declare that there is no conflict of interests regarding the publication of this paper.


This work is supported by NSFC General Program under Grant nos. 61173066 and 41201410 and Guangdong Province Funds Supported Project for the Development of Strategic Emerging Industry no. 2011912030.