Advanced Intelligent Fuzzy Systems Modeling Technologies for Smart Cities
View this Special IssueResearch Article  Open Access
Aichuan Li, Shujuan Yi, "An Indoor Positioning Algorithm for Wearable Device Using Deep Learning Regression Prediction Model in IoT Applications", Mathematical Problems in Engineering, vol. 2020, Article ID 8842784, 7 pages, 2020. https://doi.org/10.1155/2020/8842784
An Indoor Positioning Algorithm for Wearable Device Using Deep Learning Regression Prediction Model in IoT Applications
Abstract
To solve the problem of low positioning accuracy and ease environmental impact of wearable devices in the Internet of things, a wearable device indoor positioning algorithm based on deep learning was proposed. Firstly, a basic model of deep learning composed of an input layer, hidden layer, and output layer is proposed to realize the continuous prediction and positioning with higher accuracy. Secondly, the automatic stacking encoder is trained with signal strength data, and features are extracted from a large number of signal strength samples with noise to build the location fingerprint database. Finally, the stacking automatic coding machine is used to obtain the signal strength characteristics of the points to be measured, which are matched with the signal strength characteristics in the fingerprint database, and the location of the points to be measured is estimated by the nearest neighbor algorithm. The experimental results show that the indoor positioning algorithm based on the stacking automatic coding machine has higher positioning accuracy, and the average error of points on the complete path can reach within 3 m in 93% cases.
1. Introduction
With the development of computer technology, smart phones and other smart wearable devices with a variety of sensors have been popularized in everyday life, and people’s demand for indoor positioning services is increasingly strong. Indoor positioning is a position estimation technique for indoor environment [1–4]. Due to the influence of complex indoor radio transmission environment, indoor building layout, personnel mobility, and other factors, the indoor signal fading model cannot be established accurately, so its progress lags far behind the outdoor positioning technology. Outdoor Positioning technology based on GPS (Global Positioning System) and cellular base station has been very mature and has been widely deployed and applied [5]. Lowcost and highprecision indoor positioning solutions have become a research hotspot. WiFi is a widely used wireless communication technology, which can effectively solve the blocking problem with GPS and base station buildings. A large number of wireless Access Points (APs) are deployed in indoor environments such as schools, shopping malls, and airports [6, 7]. However, due to the indoor complex environment, the accuracy is affected by obstacles, nonlineofsight propagation, noise, and other factors, and there is a certain positioning error [8, 9]^{.} Therefore, it is of major practical significance and practical value to study indoor positioning algorithm of smart wearable devices.
Many domestic and foreign experts and scholars have conducted deep research on the indoor positioning algorithm of smart wearable devices. Literature [10] uses the knearest neighbor interpolation (KNN) method to search the most similar K location data from fingerprint database and average its location. Literature [11] improves it and uses the weighted KNN method. In [12], the random forest algorithm also achieves excellent positioning accuracy. In [13], deep learning algorithm is utilized to realize indoor positioning through WiFi. Zhihua et al. [14] proposed an indoor fingerprint system for deep learning of Channel state information (CSI), which verified the broad prospect of deep learning in the field of indoor positioning. However, traditional machine learning methods are very sensitive to data and often require data normalization, filtering, and other preprocessing. Moreover, they are easy to overfit and lead to bland generalization ability, which will affect the prediction performance of the network over time. However, with the increasing demand for positioning accuracy and the increasing amount of data, meaningful learning is a promising solution. Therefore, the above algorithms still have some room for innovation and improvement [15–18].
A wearable device indoor positioning algorithm based on arcane learning is proposed. By using deep learning and automatic encoder, the hidden structural features of data can be extracted by direct learning without preprocessing, and problems such as overfitting can be effectively avoided improving network generalization ability [19–22]. Its main innovations are as follows:(1)Most of the existing methods, continuous positioning, cannot achieve high accuracy, and the algorithm, using a basic deep learning model composed of input layer, hidden layer, and output layer, by setting the inputoutput approximately equal, learning the parameters of network weights, and then establishing the encoding mode, achieves a higher accuracy of continuous prediction location.(2)Most of the existing methods, easy from the problem of fitting result in weak generalization ability, and the algorithm using the signal strength data of stacked automatic coding machine for training, and from a lot of signal with noise characteristics, strength of samples is taken to establish the position fingerprint database, which effectively solves the fitting result in weak generalization ability problem.(3)Most of the existing methods do not estimate the location of the point to be measured, but the proposed algorithm uses the stack automatic coding machine to obtain the signal strength characteristics of the point to be measured, matches the signal strength characteristics with the fingerprint database of the location, and estimates the location of the point to be measured by the nearest neighbor algorithm.
Experimental results show that the proposed indoor positioning algorithm of wearable devices based on subconscious learning has higher positioning accuracy, and the average error of points on the complete path can reach within 3 m in 93% of cases.
2. Framework of Proposed Algorithm
Based on deep learning indoor location algorithm for wearable devices, the location information of mobile devices in the environment is described by the signal strength of various signal sources (such as routers, iBeacon, and RFID). Firstly, based on the principle of deep learning, the autoencoder compresses data, extracts feature or reduces noise, and trains with the autoencoder to establish the position fingerprint database. Finally, it matches the signal intensity features in the fingerprint database, uses the nearest neighbor algorithm to estimate the location of the points to be measured, and chooses the best matching position. Figure 1 shows the overall flow chart of the proposed algorithm.
3. Deep Learning Models
The profound learning model is similar to the threelayer structure of the traditional neural network. It is a multilayer network composed of an input layer, hidden layer, and output layer. Concentrated learning enables gradient to be transmitted effectively through the layerbylayer training method. Therefore, deep neural network usually contains multiple hidden layers, which improve network expression ability. As shown in Figure 2, the adopted model is mainly divided into the following three parts: auto encoder, multilayer perceptron, and deep learning regression prediction model [23].
3.1. Autoencoder
An autoencoder can be utilized to compress data, extract features, or reduce noise. The basic idea of deep learning and the characteristics of the network are utilized to directly construct a network structure that can express the original data. By setting the approximate equality of input and output, the parameters and weights of the network are drawn, and then the deep autoencoder model is constructed [24].
3.2. Multilayer Perceptron
Multilayer perceptron (MLP), also known as concentrated prefeedback network, is a typical deep learning model [25]. MLP has multiple layers of nodes, where each layer is fully connected to the next layer. Each node in the hidden layer is operated with a nonlinear activation function, and the network is trained using a backpropagation model.
3.2.1. Activation Function
Sigmoid function or Stype function is commonly used in neural networks. The Sigmoid function can compress the real number into the interval of [0, 1], which is under a strong explanatory power. However, when the neuron approaches 0 or 1, saturation will occur, leading to gradient dispersion. Therefore, the weight should be initialized carefully:
Tanh function: this function has good data control ability and maps real numbers to the interval of [−1, 1], but there is still saturation problem. The formula of Tanh function is
Relu function is a linear correction unit, which is 0 when x < 0 and 1 when x > 0. Relu converges faster, but Relu is also more fragile. Large gradient flow may lead to the permanent failure of neurons, which can be avoided by selecting an appropriate learning rate or interlayer batch regularization. The formula is as follows:
3.2.2. Backpropagation Algorithm
The training sample set is , where m is the number of samples and the sample set is utilized to train the neural network. The loss function in the experiment is
The key step of the gradient descent method is tantamount to calculate the partial derivatives, the weight W, and the bias item b of the network, and their iterative formulas arewhere is the learning rate.
3.3. Deep Learning Regression Prediction Model
Indoor fingerprint location scheme can only predict and estimate discrete fingerprint points [26]. In order to achieve more accurate continuous prediction location, a regression prediction model is built by using meaningful learning. The linear regression model can be expressed aswhere represents the input, represents the weight, and represents deviation. and are trained as minimized objective functions. The model first processes input data and then performs pretraining. When the output layer is achieved, the model will propagate back. The algorithm stops when it converges.
4. Positioning Algorithm
4.1. Stack Automatic Coding Machine
Stacking automatic coder is comprised of several autoencoders. An automatic encoder is an efficient encoding artificial neural network for unsupervised learning (as shown in Figure 3), which can extract features from highdimensional data and reduce the data dimension, so as to improve the positioning accuracy of location fingerprint method and reduce the time required for positioning.
The input layer of the automatic encoder to the hidden layer (encoding layer) is the encoding part, and the hidden layer to the output layer is the decoding part. The hidden layer is calculated from input layer and utilized to calculate reconstructed output layer . The calculation method is as follows:where and are, respectively, the connection weights between the input layer and the hidden layer and between the hidden layer and reconstructed output layer. In order to decrease the number of parameters and control the complexity of the model, the weight matrix is limited to the transpose of the weight matrix , that is, . and are the bias units of the hidden layer and reconstructed output layer, respectively; is the hidden layer unit data. The training of the automatic coding machine is to minimize the reconstruction error between and obtained through the input layer . The smaller the error is, the closer the reconstructed output layer is the input layer. The hidden layer can better express the information of the input layer to reach the purpose of feature extraction.
Multiple automatic encoders are stacked to form a stacked automatic encoder. Figure 4 shows the network with K1008050 structure, which consists of three automatic encoders stacked on top of each other. The first automatic encoder has K100K structure, the subsequent automatic encoder has 10080100 structure, and the third automatic encoder has 805080 structure. The input of the first automatic coding machine is the Kdimensional vector , and the input layer of the automatic coder is the hidden layer of the automatic coder . The number of stacked automatic encoders is 3 and the number of hidden layer neurons of each automatic encoder is empirical values.
is trained at the input of the stacking automatic coding machine of structure A in Figure 3. J is the amount of data strips collected in the offline phase, and each dimension of each piece of data corresponds to an RSS of fixed AP or iBeacon. After the training, the new fingerprint database data were obtained:, where n represents the dimension of data processed by the automatic stacking encoder.
4.2. Nearest Neighbor Method
Put online phase data as the input layer, and the structure in Figure 3(a) is used for a forward propagation, where the parameters and b are the DATA trained in the offline phase, and is the input data of the classifier nearest neighbor method.
The AP and iBeacon corresponding to the RSS of each dimension of the original fingerprint database and the phase DATA online are the same, and the information expressed by each dimension of the new fingerprint database and the online DATA is also corresponding. In the new fingerprint database DATA_{offline} and online DATA, the nearest neighbor method is used to calculate the online phase data and the Euclidean distance of the data in the new fingerprint database [27]:where represents the dimension data of the j data in the new fingerprint database, represents the dimension data in the online phase, and represents the dimension of the data processed by the stack automatic encoder. Finally, depending on the order of Euclidean distance from small to large (the smaller the distance, the higher the similarity of the two kinds of data), the coordinate of the sampling point with the smallest distance is the positioning result.
5. Experimental Results and Analysis
In order to verify the indoor effect of the wearable equipment indoor location algorithm proposed in this paper, the location area includes corridors and offices, and the office is equipped with desks, chairs, bookcases, and other office items. Seven Moto 360s were selected as the research objects. The signal was collected by a New Pad S97 tablet computer for 30 consecutive times. Two groups were collected at a time interval of 0.5 seconds. As a result, there are six groups of data in each location and 180 times of signal acquisition.
5.1. Regression Predictions by Using Deep Learning Model
Indoor location scene usually adopts the location method founded on fingerprint. 140 fingerprint points in indoor environment were collected and studied to estimate additional registration points. Fingerprintbased localization is a multiclassification problem. Traditional machine learning can achieve good results for binary classification problems but with the increase of data dimension of multiclassification problems. Machine learning becomes quite difficult. For better generalization, machine learning methods have a tendency to make strong taskspecific assumptions. At the same time, the saturation of S function limits the number of hidden layers, so the expression ability of a neural network is insufficient. The core idea of deep learning is tantamount to assume that data are composed of factors or features. Meaningful learning aims to overcome a series of difficulties such as “dimensional disaster” and “gradient dispersion” in machine learning, so as to achieve better results in multiclassification problems.
A multilayered neural network classifier with five hidden layers is constructed based on the deep learning framework. In order to prevent gradient dispersion, Relu is adopted as the activation function of the hidden layer and Xavier is used to initialize the weight. The number of samples in the test set is 100, and the simulation results have shown that the positioning accuracy can reach 90%.
5.1.1. Comparison between Single Hidden Layer and Three Hidden Layers
In both networks, the autoencoder is not used, and Relu is adopted as the activation function for the hidden layer. Regression fitting is carried out on the test set to predict the results of coordinate points, as shown in Table 1. It can be observed in the table that the prediction effect of multiple hidden layers is obviously better than that of single layer, but the positioning error is still large.

5.1.2. Autoencoder
As can be observed in the data distribution, in order to improve the positioning accuracy, it is necessary to carry out feature extraction and noise reduction processing for the data. Therefore, before the data are input into the profound learning regression network, the autoencoder processing is carried out to extract the highdimensional features of the data and reduce the impact of noise. Table 2 lists the comparison results of autoencoder positioning accuracy in the three hidden deep regression prediction networks using Tanh activation function.

5.1.3. Comparison of Activation Functions of Different Hidden Layers
The selection of the activation function of the hidden layer will also largely complete action on the positioning accuracy. Relu function, which performs well in the classification task, is not so effective as Sigmoid and other functions in the case of uneven data distribution due to its weak ability to control data. Since Tanh is equivalent to the extended form of Sigmoid function, its center is symmetric about the zero point. Tanh tends to achieve better results than Sigmoid. The specific results are presented in Table 3.

5.2. Comparisons of Positioning Accuracy with Several Other Algorithms
Under the same experimental conditions, the positioning algorithms in the literature [10, 12–14] are also implemented, which can be used to compare and verify the advantages of the proposed positioning algorithms in constructing the relationship between positioning features and positioning coordinates. The positioning effects of these algorithms are shown in Figure 5.
From Figure 5, we can see that the average positioning accuracies of algorithms in literature [13] and [14] and the algorithm based on deep learning are higher than those in literature [10] and [12], which reflects the advantages of deep learning in constructing positioning features and position relations. When the number of acquisitions is 60, the average positioning error of the proposed algorithm is 1.85 m, which is basically smaller than that of other algorithms when the number of samplings is 150. At this time, the average positioning errors of the algorithms in [6, 9, 10] and [8] are 1.87 m, 1.97 m, 1.99 m, and 2.29 m, respectively.
Figure 6 shows the cumulative probability distribution curve of the average positioning errors of several positioning algorithms when the number of signal sampling is 120. When the average positioning error is less than or equal to 2 m, the cumulative probability of indoor positioning algorithm combined with deep learning is 76.34%. The cumulative probabilities in the literature [13], [14], [10], and [12] are 69.44%, 66.67%, 63.90%, and 54.13%, respectively. When the average positioning error is less than or equal to 3 m, the cumulative probability of each algorithm is 93.67%, 83.11%, 81.37%, 79.57%, and 76.78%, respectively. Therefore, the proposed indoor positioning method can provide smaller errors and stable positioning results.
5.3. Comparisons of Calculation Time with Several Other Algorithms
In order to verify the realtime performance of the algorithm, the running time of several indoor location algorithms in references [10, 12–14] is tested. Table 1 shows the running time of these algorithms. From Table 4, we can see that the running time of the proposed algorithm and of algorithms in the literature [13] and [14] is longer than that in the traditional literature [10] and [12] and the algorithm in literature [12] is the shortest. However, the positioning accuracy of literature [12] algorithm is poor, which can be seen from Figures 5 and 6.

As can be seen from the comparison results of location accuracy and calculation time, the proposed algorithm can achieve the highest location accuracy while maintaining acceptable calculation time. Thus, compared with other algorithms, the proposed algorithm has the best comprehensive performance.
6. Conclusion
A wearable device indoor positioning algorithm based on subconscious learning was proposed to achieve continuous predictive positioning with higher accuracy. The stacking automatic coding machine was used to obtain the signal strength characteristics of the points to be measured, which were matched with the signal strength characteristics in the fingerprint database of the position, and the position of the points to be measured was estimated by the nearest neighbor algorithm. Experimental results show that in 93% of cases, the average error of points on the complete path can reach within 3 m. The future research direction is to continue to study the problem of large maximum positioning error and other fusion methods of WiFi and iBeacon to solve the problem of huge amount of computational data. Expand the richer positioning strategy to adapt to more diverse indoor application scenarios, and test and improve the proposed method to a wider range of practical environments.
Data Availability
The data included in this paper are available from the corresponding author without any restriction.
Conflicts of Interest
The authors declare that they have no conflicts of interest regarding the study.
Acknowledgments
This paper was supported by the Heilongjiang Provincial Natural Science Foundation of China (C2018050); Heilongjiang Agricultural Reclamation Administration’s Key Projects (HKKY 19020102); and School Innovative Talent Project (CXRC2017014); School Research Project for Accomplished Talents (XDB201813).
References
 Ó. BelmonteFernández, A. PuertasCabedo, J. TorresSospedra, R. MontoliuColás, and S. TrillesOliver, “An indoor positioning system based on wearables for ambientassisted living,” Sensors, vol. 17, no. 1, p. 36, 2016. View at: Publisher Site  Google Scholar
 C. Li, C. Z. Qiu, and C. Liu, “An improved weighted Knearest neighbor algorithm for indoor positioning,” Wireless Personal Communications, vol. 96, no. 2, pp. 2239–2251, 2017. View at: Publisher Site  Google Scholar
 S. Jiang, G. Li, P. yu et al., “Indoor positioning algorithm based on RSSI,” Ict, vol. 184, no. 4, pp. 70–79, 2018. View at: Google Scholar
 P. Davidson and R. Piche, “A survey of selected indoor positioning methods for smartphones,” IEEE Communications Surveys & Tutorials, vol. 19, no. 2, pp. 1347–1370, 2017. View at: Publisher Site  Google Scholar
 W. Y. Zhang, Q. X. Zeng, P. N. Zhang et al., “Vehicle GPS/cellular network seamless positioning algorithm based on UKF,” Journal of Chinese Inertial Technology, vol. 23, no. 1, pp. 76–80, 2015. View at: Google Scholar
 S. R. Doiphode, J. W. Bakal, and M. Gedam, “A hybrid indoor positioning system based on WiFi hotspot and WiFi fixed nodes,” in Proceedings of the IEEE International Conference on Engineering and Technology (ICETECH), Coimbatore, India, March 2016. View at: Google Scholar
 K. X. Guo, Y. L. Lu, T. Feng, C. Ruan, and M. Yu, “Study on indoor and outdoor seamless positioning technologybased on intelligent switching algorithm,” Transducer and Microsystem Technology, vol. 37, no. 7, pp. 49–51, 2018. View at: Google Scholar
 C. Chen, Y. Wang, Y. Zhang, and Y. Zhai, “Indoor positioning algorithm based on nonlinear PLS integrated with RVM,” IEEE Sensors Journal, vol. 18, no. 2, pp. 660–668, 2018. View at: Publisher Site  Google Scholar
 Y.L. Hsu, P.H. Chou, H.C. Chang et al., “Design and implementation of a smart home system using multisensor data fusion technology,” Sensors, vol. 17, no. 7, pp. 1631–1639, 2017. View at: Publisher Site  Google Scholar
 X. Du and K. Yang, “A mapassisted WiFi AP placement algorithm enabling mobile device’s indoor positioning,” IEEE Systems Journal, vol. 11, no. 3, pp. 1467–1475, 2017. View at: Publisher Site  Google Scholar
 W. Hongkai, C. Ronald, W. Sen et al., “Efficient indoor positioning with visual experiences via lifelong learning,” IEEE Transactions on Mobile Computing, vol. 18, no. 4, pp. 814–829, 2018. View at: Google Scholar
 X.L. Wang and Y. Zheng, “TinyLoc: An indoor positioning algorithm for wearable devices with limited energy consumption,” Journal of Computer Science, vol. 22, no. 8, pp. 91–106, 2017. View at: Publisher Site  Google Scholar
 H. Wang, D. Y. Wen, and D. Zhao, “Location verification algorithm of wearable sensors for wireless body area networks,” Technology and Health Care, vol. 26, no. 7, pp. 3–18, 2018. View at: Publisher Site  Google Scholar
 W. Zhihua, Y. Zhaochu, and D. Tao, “A review of wearable technologies for elderly care that can accurately track indoor position, recognize physical activities and monitor vital signs in real time,” Sensors, vol. 17, no. 2, pp. 341–350, 2017. View at: Google Scholar
 Y. Xiao and J. Wang, “A wireless indoor positioning method based on multidimensional scaling and regional refinement,” Acta Computicasinica, vol. 18, no. 8, pp. 196–210, 2017. View at: Google Scholar
 D. Ielmini and V. Milo, “Physicsbased modeling approaches of resistive switching devices for memory and inmemory computing applications,” Journal of Computational Electronics, vol. 16, no. 4, pp. 1121–1143, 2017. View at: Publisher Site  Google Scholar
 F. M. Roberto, A. Kasun, R. A. Juan, and M. Manic, “Deep learning and reconfigurable platforms in the Internet of things: challenges and opportunities in algorithms and hardware,” IEEE Industrial Electronics Magazine, vol. 12, no. 2, pp. 36–49, 2018. View at: Publisher Site  Google Scholar
 P. Li, Z. Chen, L. T. Yang et al., “Deep convolutional computation model for feature learning on big data in Internet of things,” IEEE Transactions on Industrial Informatics, vol. 14, no. 2, pp. 790–798, 2017. View at: Google Scholar
 X. Y. Wang, L. J. Gao, S. W. Mao, and S. Pandey, “CSIbased fingerprinting for indoor localization: a deep learning approach,” IEEE Transactions on Vehicular Technology, vol. 66, no. 1, pp. 763–776, 2017. View at: Publisher Site  Google Scholar
 Z. Yong, F. Li, and Y. Wang, “Indoor positioning algorithm for WLAN based on KDDA and SFLALSSVR,” Journal of Computer Research & Development, vol. 54, no. 5, pp. 979–985, 2017. View at: Google Scholar
 N. Ye, H. X. Li, and W. A LiuWang, “Deep learning aided grantfree NOMA toward reliable lowlatency access in tactile Internet of things,” IEEE Transactions on Industrial Informatics, vol. 15, no. 5, pp. 2995–3005, 2019. View at: Publisher Site  Google Scholar
 Z. Hou, W. Meiqing, and O.M. Joaquín, “Comparison of data preprocessing approaches for applying deep learning to human activity recognition in the context of industry 4.0,” Sensors, vol. 18, no. 7, pp. 2146–2159, 2018. View at: Google Scholar
 J. Chen, Y. Zhang, and W. Xue, “Unsupervised indoor localization based on smartphone sensors, iBeacon and wifi.,” Sensors, vol. 18, no. 5, pp. 1378–1385, 2018. View at: Publisher Site  Google Scholar
 J.W. Shang, C.K. Wang, X. Xin et al., “Community detection algorithm based on deep sparse autoencoder,” Journal of Software, vol. 28, no. 3, pp. 648–662, 2017, in Chinese. View at: Google Scholar
 Kurnianingsih, L. E. Nugroho, Widyawan, L. Lazuardi, and A. Satria Prabuwono, “A predictive positioning system using supervised learning for home care of older people,” in Proceedings of the International Conference on Computational Intelligence & Cybernetics, October 2017. View at: Google Scholar
 H. Wang, Z. Zhao, J. Hu et al., “Study on improvement of fingerprint matching algorithm in wireless LAN based indoor positioning system,” in Proceedings of the 17th IEEE/ACIS International Conference on Software Engineering, Artificial Intelligence, Networking and Parallel/Distributed Computing (SNPD), Shanghai, China, 2016. View at: Google Scholar
 Y. Wang, Q. Yang, G. Zhang et al., “Indoor positioning system using Euclidean distance correction algorithm with bluetooth low energy Beacon,” in Proceedings of the International Conference on Internet of Things and Applications (IOTA), Pune, India, January 2016. View at: Google Scholar
Copyright
Copyright © 2020 Aichuan Li and Shujuan Yi. This is an open access article distributed under the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.