Partition fusion positioning method based on WiFi and geomagnetic fingerprints

文档序号:11743 发布日期:2021-09-17 浏览:31次 中文

阅读说明:本技术 一种基于WiFi和地磁指纹的分区融合定位方法 (Partition fusion positioning method based on WiFi and geomagnetic fingerprints ) 是由 贾扬帅 于 2020-10-23 设计创作,主要内容包括:本发明一种基于WiFi和地磁指纹的分区融合定位方法,包括以下步骤:S1:利用堆叠自编码器对根据整个区域内的离线RSS数据按照均方误差最小原则进行重构;S2:对离线RSS数据重构完成后,将堆叠自编码器的解码层断开,保存编码层;按照BP算法微调整个网络,使得分类的精度得到优化;S3:将地磁信号从载坐标系转换为导航坐标系;S4:检验测试点。根据RSS的稀疏性,采用堆叠自编码器提取RSS的特征;然后将场景划分为特定的区域,即对RSS样本添加标签信息,根据堆叠自编码器提取RSS的特征进行分类;最后在每个区域内,将RSS和地磁作为混合指纹输入到回归神经网络内进行拟合。该算法在室内场景条件下能够取得非常好的重构、分类、拟合误差。(The invention relates to a partition fusion positioning method based on WiFi and geomagnetic fingerprints, which comprises the following steps of: s1: reconstructing the offline RSS data in the whole area according to the minimum mean square error principle by using a stacked self-encoder; s2: after the off-line RSS data is reconstructed, disconnecting a decoding layer of the stacked self-encoder and storing the encoding layer; finely adjusting the whole network according to a BP algorithm to optimize the classification precision; s3: converting the geomagnetic signal from a loading coordinate system to a navigation coordinate system; s4: and checking the test points. Extracting features of the RSS by adopting a stacking self-encoder according to sparsity of the RSS; then dividing the scene into specific areas, namely adding label information to the RSS samples, and classifying the RSS samples according to the features extracted from the stacked self-encoder; and finally, in each region, inputting RSS and geomagnetism as mixed fingerprints into a recurrent neural network for fitting. The algorithm can obtain good reconstruction, classification and fitting errors under the indoor scene condition.)

1. A partition fusion positioning method based on WiFi and geomagnetic fingerprints is characterized in that: the method comprises the following steps:

s1: reconstructing the offline RSS data in the whole area according to the minimum mean square error principle by using a stacked self-encoder to obtain the weight and the offset parameter of the stacked self-encoder network;

s2: after the off-line RSS data is reconstructed, disconnecting a decoding layer of the stacked self-encoder and storing the encoding layer; then, a classifier is connected behind the coding layer, the value N of the number of the regions is set, and the whole network is finely adjusted according to a BP algorithm according to a cross entropy principle, so that the classification precision is optimized;

s3: converting the geomagnetic signal from the loading coordinate system to the navigation coordinate system, and projecting the geomagnetic signal to the horizontal direction BhAnd a vertical direction BvAnd a modulus B of the geomagnetic signalpThe combination of | is a three-dimensional vector (B)h,Bv,||Bp| |) a fully connected regression network is connected behind the coding layer to convert the three-dimensional vector (B)h,Bv,||Bp| |) and RSS fit the coordinates of the off-line reference points in each class, and finely adjust the whole network according to the principle of minimum root mean square error whenStopping training when the off-line reference points in each class reach convergence;

s4: and (4) testing the test points, firstly dividing the test points into which class the test points are positioned according to the step S2, then solving the fitted coordinates according to the step S3, and finally calculating the average positioning error of the test points.

2. The partition fusion positioning method based on WiFi and geomagnetic fingerprints according to claim 1, wherein: the indoor positioning method based on the fingerprint comprises 2 stages of fingerprint mapping and positioning.

3. The partition fusion positioning method based on WiFi and geomagnetic fingerprints according to claim 2, wherein: and in the fingerprint mapping stage, relevant signal characteristics uniformly distributed at reference points in an indoor scene are collected and stored in a fingerprint database to form a fingerprint map.

4. The partition fusion positioning method based on WiFi and geomagnetic fingerprints according to claim 3, wherein: the fingerprint map comprises RSS fingerprints and geomagnetic signal fingerprints of WiFi.

5. The partition fusion positioning method based on WiFi and geomagnetic fingerprints according to claim 4, wherein: the RSS fingerprint is characterized in that firstly, an indoor scene is uniformly divided into a plurality of areas, a plurality of reference points are uniformly distributed in each area, RSS transmitted by a wireless access point is collected on the reference points, the RSS at the RPS forms an offline RSS fingerprint library, and the ith reference point RPiThe RSS fingerprint of (a) is expressed as:

wherein, labeliRepresents RPi(ii) category information of (x)i,yi) Represents RPiCoordinate information of, MACi,j,RSSi,jIs shown at RPiTo collect APMac Address is MACi,jRSS ofi,j,kiIs the number of APs that can be detected.

6. The partition fusion positioning method based on WiFi and geomagnetic fingerprints according to claim 4, wherein: the geomagnetic signal is a three-dimensional vector Bp=(Bpx,Bpy,Bpz) Acquired by a magnetometer integrated in the smart phone, wherein Bpx,Bpy,BpzRepresenting the three-axis components of the magnetometer, Bpx,BpyNorth and east, respectively, to geographypzIn line with the direction of gravity.

7. The partition fusion positioning method based on WiFi and geomagnetic fingerprints according to claim 6, wherein: b is measured by a mobile phone gravity sensorpProjected in the horizontal direction BhAnd a vertical direction BvForm a new two-dimensional geomagnetic fingerprint vector (B)h,Bv) To increase the dimensionality of the fingerprint, we will use a two-dimensional geomagnetic fingerprint vector (B)h,Bv) And BpThe | | fingerprints are mixed to form a three-dimensional vector (B)h,Bv,||Bp||)。

8. The partition fusion positioning method based on WiFi and geomagnetic fingerprints according to claim 2, wherein: and in the positioning stage, the signal characteristics acquired at the test point are matched with the fingerprints stored in the fingerprint map, so that the predicted position information of the test point is obtained.

9. The partition fusion positioning method based on WiFi and geomagnetic fingerprints according to claim 8, wherein: the solving of the geomagnetic fingerprint comprises the following steps of converting a coordinate system: converting the carrier coordinate system into a navigation coordinate system; with the rotation matrix method, for an indoor positioning system, the position on the map is defined by the X-axis and the Y-axis, and the height on the ground is defined by the Z-axis, and the matrix rotating around the XYZ directions is defined as follows:

wherein phi, theta and psi are respectively defined as rolling, pitching and yaw angles; the rotation sequence adopted is XYZ and is marked as Rxyz

Let the gravity accelerometer reading be denoted as Gp=(Gpx,Gpy,Gpz),Gpx,Gpy,GpzRespectively representing gravity accelerometers GpThe three-axis component of (a); setting the intensity of the earth magnetic field BrIn the environment, the environmental noise added to the earth's magnetic field is V ═ V (V)x,Vy,Vz) And g is the gravitational acceleration, then the following equation can be obtained:

Bp=Rx(φ)Ry(θ)Rz(θ)Br+V

from the above equation, phi, theta, psi can be solved as follows:

the solution of the yaw angle needs to know the orientation of the gyroscope, the rotation in the Z-axis direction is generally not considered, and a rotation matrix can be simplified into a matrix;

Bf=Ry(-θ)Rx(-φ)Bp

after the coordinate system conversion is completed, the three-dimensional magnetic field vector B is convertedf=(Bfx,Bfy,Bfz) Projected in the horizontal direction BhAnd a vertical direction BvThe compositional HV component, shown below;

to extend the fingerprint dimension, (B)h,Bv,||Bp| |) as a fingerprint of the magnetic field strength, the ith reference point RPiThe magnetic field fingerprint at is expressed as:

MFPi={labeli,(xi,yi),Bi,h,Bi,v,||Bi,p||}。

Technical Field

The invention belongs to the technical field of wireless communication, machine learning and indoor fingerprint positioning, and relates to a two-stage partition fusion positioning method based on WiFi and geomagnetic fingerprints.

Background

The rapid growth in the number of global mobile device users has prompted many new services and applications, where location Based services (lbs) have become ubiquitous and their demand is growing exponentially, with accurate location information playing an important role in practical applications. Compared with other technologies, the pervasive computing and position sensing capabilities of the mobile phone unit are the main factors for enabling the LBSs to be hastened quickly.

The Global Positioning System (GPS) can provide high-quality and stable outdoor positioning accuracy, but because of the blockage of the wall, the GPS signals reaching the indoor space are greatly attenuated, and the indoor environment has multipath effect and non-line-of-sight transmission, so that the GPS signals cannot provide accurate indoor positioning information, and the current indoor positioning technology is not suitable for being applied to indoor scenes.

In order to solve the indoor positioning problem, researchers have proposed solutions based on technologies such as WiFi, UWB, bluetooth, etc. The WiFi-based positioning technology can be used by means of public network facilities without adding extra hardware equipment, and gradually becomes a preferred solution for indoor positioning. Generally, a smart device can receive a certain number of WiFi signals in an indoor public place, and the Received Signal Strength (RSS) of the WiFi signals can provide rich location differentiation information as a fingerprint. However, the complex indoor environment makes the WiFi signal susceptible to signal attenuation, multipath effect, human body blockage, etc., resulting in limited positioning accuracy.

With more and more sensors integrated into smart phones, such as acceleration sensors, gyroscopes, magnetometers, barometers, etc., researchers pay more and more attention to the positioning technology of the inertial sensor due to the fact that the inertial sensor does not need any infrastructure and is not easily interfered by the environment. Wherein, earth magnetism ubiquitous in indoor environment, indoor location technique based on earth magnetism does not need extra equipment, low cost, and under same environment, the earth magnetism signal is more stable than the wiFi signal moreover, and is more sensitive to the change of position. However, the geomagnetic signals have low position resolution, and the geomagnetic signals at different sampling points in a large area may be the same, resulting in positioning errors.

The single indoor positioning technology can not meet the requirement of people on the position, the combination of various positioning technologies becomes the mainstream direction of indoor positioning, and the fusion type positioning algorithm based on WiFi and geomagnetic signals can complement the advantages, so that more accurate indoor positioning is realized.

Disclosure of Invention

The invention provides a partition fusion positioning method based on WiFi and geomagnetic fingerprints, and aims to solve the problems that the positioning result error is large under the conditions of a complex large indoor scene due to the existence of the following three problems: the fingerprint dimension space acquired in an indoor scene is large, and dimension disasters of local areas easily exist; WiFi signal propagation is easily influenced by a complex indoor environment, so that phenomena such as multipath effect, same frequency interference, non-line-of-sight transmission and the like are generated, namely, a signal space and a physical space are not in a simple linear mapping relation; and thirdly, the information acquisition function of the smart phone rich sensor cannot be utilized to the maximum extent only by relying on WiFi fingerprints, so that the positioning accuracy is not high.

In order to achieve the purpose, the technical scheme of the invention is as follows; the method comprises the following steps:

s1: reconstructing offline RSS data in the whole area according to the minimum mean square error principle by using a Stacked auto encoder (Stacked auto encoders) to obtain a weight and a bias parameter of a Stacked auto encoder (Stacked auto encoders) network;

s2: after the offline RSS data is reconstructed, disconnecting a decoding layer (Decoder) of a Stacked self-Encoder (Stacked Autoencoders) and storing an encoding layer (Encoder); then, connecting a classifier behind the Encoder, setting the value of the number N of the regions, and finely adjusting the whole network according to a BP algorithm according to a cross entropy principle so as to optimize the classification precision;

s3: converting the geomagnetic signal from the carrier coordinate system to a navigation coordinate system, and projecting the geomagnetic signal to a horizontal direction (horizontal plane) BhAnd vertical direction (vertical direction) BvAnd a modulus B of the geomagnetic signalpThe combination of | is a three-dimensional vector (B)h,Bv,||Bp| |) a fully connected regression network is connected behind the Encoder to convert the three-dimensional vector (B)h,Bv,||BpThe method comprises the following steps that (i) a mixed fingerprint composed of RSS fits the coordinates of an offline reference point in each class, the whole network is finely adjusted according to the minimum principle of Root Mean Square Error (RMSE), and training is stopped when the offline reference points in each class converge;

s4: for the test points, the test points are first classified according to step S2 in which class they are located, then the fitted coordinates are solved according to step S3, and finally the average positioning error of the test points is calculated.

As a further improvement of the above solution;

the indoor positioning method based on the fingerprint comprises 2 stages of fingerprint mapping (off-line) and positioning (on-line).

In the fingerprint mapping stage, relevant signal features uniformly distributed at Reference Points (RPs) in an indoor scene are collected and stored in a fingerprint database to form a fingerprint Map (Radio Map).

In the positioning stage, the signal characteristics acquired at the test point are matched with the fingerprints stored in the fingerprint map, so that the predicted position information of the test point is obtained.

The fingerprint mapping stage mainly comprises the step of constructing a Radio Map, wherein the Radio Map mainly comprises RSS fingerprints and geomagnetic signal fingerprints of WiFi.

The RSS fingerprint firstly uniformly divides an indoor scene into a plurality of regions, a plurality of Reference Points (RPs) are uniformly distributed in each region, RSS transmitted by wireless Access Points (APs) is collected on the Reference Points (RPs), the RSS at the RPS forms an offline RSS fingerprint library, and the ith reference point RPiRSS fingerprint table ofShown as follows:

wherein labelli represents RPi(ii) category information of (x)i,yi) Represents RPiCoordinate information of, MACi,j,RSSi,jIs shown at RPiWhere the MAC address of the collected AP is MACi,jRSS ofi,j,kiIs the number of APs that can be detected.

The geomagnetic signal is a three-dimensional vector Bp=(Bpx,Bpy,Bpz) Acquired by a magnetometer integrated in the smart phone, wherein Bpx,Bpy,BpzRepresenting the three-axis components of the magnetometer, Bpx,BpyNorth and east, respectively, to geographypzIn line with the direction of gravity. Even if the smartphone is in the same location, the magnitude of each component will vary as the terminal orientation changes. Therefore, a carrier coordinate system where the terminal is located needs to be converted into a navigation coordinate system, and a rotation matrix is adopted for coordinate system conversion.

B is measured by a mobile phone gravity sensorpProjected in the horizontal direction BhAnd a vertical direction BvForming a new two-dimensional geomagnetic fingerprint vector (B)h,Bv) Abbreviated HV fingerprint. To increase the dimensionality of the fingerprint, we sum the HV fingerprint and | | BpThe | | fingerprints are mixed to form a three-dimensional vector (B)h,Bv,||Bp||)。

And in the positioning stage, the signal characteristics acquired at the test point are matched with the fingerprints stored in the fingerprint map, so that the predicted position information of the test point is obtained.

The solving of the geomagnetic fingerprint comprises the following steps of converting a coordinate system: carrier coordinate system → navigation coordinate system. With the rotation matrix method, for an indoor positioning system, the position on a map is usually defined by an X axis and a Y axis, and the height on the ground is defined by a Z axis, and the system is mainly used for defining the position in the map. The smartphone can implement coordinate system conversion by rotating along XYZ axes, and a matrix rotating around XYZ directions is defined as follows:

where φ, θ, ψ are defined as roll (roll), pitch (pitch), and yaw (yaw) angles, respectively. The rotation sequence adopted is XYZ and is marked as Rxyz(rotation sequence).

Let the accelerometer reading of the cell phone be denoted as Gp=(Gpx,Gpy,Gpz),Gpx,Gpy,GpzRespectively representing gravity accelerometers GpThe three-axis component of (a). Setting the intensity of the earth magnetic field BrIn the environment, the environmental noise added to the earth's magnetic field is V ═ V (V)x,Vy,Vz) The gravity acceleration g is set to be 9.8ms-2Then the following formula can be obtained:

Bp=Rx(φ)Ry(θ)Rz(θ)Br+V

from the above equation, phi, theta, psi can be solved as follows:

the solution of the yaw angle requires knowledge of the orientation of the gyroscope, and generally does not consider rotation in the Z-axis direction, and the rotation matrix can be simplified.

Bf=Ry(-θ)Rx(-φ)Bp

After the coordinate system conversion is completed, the three-dimensional magnetic field vector B is convertedf=(Bfx,Bfy,Bfz) Projected in the horizontal direction (horizontal plane) BhAnd a vertical plane (vertical plane) BvThe HV component is composed as follows:

to extend the fingerprint dimension, (B)h,Bv,||Bp| |) as a fingerprint of the magnetic field strength, the ith reference point RPiThe magnetic field fingerprint at is expressed as:

MFPi={labeli,(xi,yi),Bi,h,Bi,v,||Bi,p||}。

has the advantages that: the partition fusion positioning method based on WiFi and geomagnetic fingerprints provided by the invention comprises the steps of firstly, extracting features of RSS by adopting a stacking self-encoder according to sparsity of the RSS; then dividing the scene into specific areas, namely adding label information to the RSS samples, and classifying the RSS samples according to the features extracted from the stacked self-encoder; and finally, in each region, inputting RSS and geomagnetism as mixed fingerprints into a recurrent neural network for fitting. The algorithm can obtain good reconstruction, classification and fitting errors under the indoor scene condition.

The staged Autoencoders learns the characteristics of low-level input data through a multilayer nonlinear hidden layer structure, can extract effective characteristics from a redundant noisy RSS fingerprint library, and construct a function mapping relation.

The positioning error of the traditional positioning model is easily influenced by the sampling interval of the reference point in the off-line stage, the scene is divided into different areas according to the physical limitation of a large scene, online test points are classified into the areas according to the characteristics of RSS, then regression is carried out in each class, and the increased class information can bring the gain on the positioning performance.

The data fusion of different characteristics is considered, the WiFi signals are high in large-range discrimination, the local discrimination is low, the geomagnetic signals are low in large-range discrimination, the local difference is obvious, the WiFi signals and the geomagnetic signals can be combined to make up respective defects, and the positioning effect is obviously improved.

Drawings

FIG. 1 is a flow chart of the present invention.

Fig. 2 is an experimental scenario diagram of the present invention.

Fig. 3 is a schematic view of a carrier and navigation coordinate system.

FIG. 4 is a graph of reconstruction errors for Stacked Autoencoders.

Fig. 5 is an experimental scene area division diagram.

Fig. 6 is a classification error map.

Fig. 7 is a final positioning result error map.

Detailed Description

The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.

Example 1: the indoor positioning method based on the fingerprint is specifically divided into two stages: fingerprint mapping (offline) and location (online). In a fingerprint mapping stage, collecting related signal characteristics uniformly distributed at Reference Points (RPs) in an indoor scene, and storing the signal characteristics in a fingerprint database to form a fingerprint Map (Radio Map); in the positioning stage, the signal characteristics acquired at the test point are matched with the fingerprints stored in the fingerprint map, so that the predicted position information of the test point is obtained.

Fingerprint mapping phaseMainly, a Radio Map is constructed, wherein the Radio Map mainly comprises RSS fingerprints and geomagnetic signal fingerprints of WiFi. For RSS fingerprints, firstly, an indoor scene is uniformly divided into a plurality of regions, a plurality of RPs are uniformly distributed in each region, RSS transmitted by wireless Access Points (APs) is collected on the RPs, the RSS at the RPs forms an offline RSS fingerprint library, and the ith reference point RPiThe RSS fingerprint of (a) is expressed as:

wherein, labeliRepresents RPi(ii) category information of (x)i,yi) Represents RPiCoordinate information of, MACi,j,RSSi,jIs shown at RPiWhere the MAC address of the collected AP is MACi,jRSS ofi,j,kiIs the number of APs that can be detected.

The geomagnetic signal is acquired by a magnetometer integrated in the smart phone and is a three-dimensional vector Bp=(Bpx,Bpy,Bpz) In which B ispx,Bpy,BpzRepresenting the three-axis components of the magnetometer, Bpx,BpyNorth and east, respectively, to geographypzIn line with the direction of gravity. Even if the smartphone is in the same location, the magnitude of each component will vary as the terminal orientation changes. Therefore, a carrier coordinate system where the terminal is located needs to be converted into a navigation coordinate system, and the coordinate system conversion is performed by using the rotation matrix in the embodiment.

As shown in fig. 1, a partition fusion positioning method based on WiFi and geomagnetic fingerprints includes the following steps:

firstly, in an indoor scene to be positioned, a positioning area, an off-line reference point and the number of receivable APs are determined. In this embodiment, a lobby of a main building of a university is selected as an experimental scene, the scene is a typical open area, the middle area is blocked by a barrier, and the overall experiment plan is shown in fig. 2. Total 41.26 × 26.1 ═ 1076.9m of sampling area2And the number of the black dots is 97, the distance between each reference point is 2.4 or 1.6m, the sampling time interval at each off-line reference point is 200ms, the sampling time is 30s, and the signal acquisition is repeated for 3 times. And (3) obtaining 262 APs by summing RSS signals collected by all off-line reference points according to Mac addresses, wherein the positions of the APs are uncertain. The RSS and geomagnetic signal data are acquired with time stamps, coordinate positions of corresponding points and label information. And uploading and storing the offline reference point coordinates, the tags, the RSS, the geomagnetic signals, the gravity accelerometer and the timestamp to form an original fingerprint map.

Aligning the time stamps of the gravity accelerometer and the geomagnetic signal, and combining the reading G of the gravity accelerometerp=(Gpx,Gpy,Gpz) The vector coordinate system is converted into a navigation coordinate system by adopting a rotation matrix method, the coordinate system is converted as shown in figure 3, and on the premise of neglecting the rotation in the Z-axis direction, phi and theta angles are solved so as to convert B into a navigation coordinate systemp=(Bpx,Bpy,Bpz) Conversion to Bf=(Bfx,Bfy,Bfz) Then B is addedfProjected in the horizontal direction (horizontal plane) BhAnd a vertical plane (vertical plane) BvComposition HV component:

to expand the dimensionality of the geomagnetic fingerprint, (B)h,Bv,||Bp| |) as a fingerprint of the magnetic field strength, the ith reference point RPiThe RSS, geomagnetic fingerprint of (a) can be expressed as:

MFPi={labeli,(xi,yi),Bi,h,Bi,v,||Bi,p||}

wherein, labeliRepresents RPi(ii) category information of (x)i,yi) Represents RPiCoordinate information of, MACi,j,RSSi,jIs shown at RPiWhere the MAC address of the collected AP is MACi,jRSS ofi,j,ki262 is the number of APs that can be detected.

Compared with the WiFi signal, the update scan frequency of the geomagnetic signal is faster, and 2000 samples can be acquired at each reference point under the same acquisition time parameter. In this embodiment, 3s is used as a group to solve | BPThe top 10 with the smallest variance of | is used as the final geomagnetic information.

The embodiment utilizes the gravity sensor of the mobile phone to convert B into BpProjected in the horizontal direction BhAnd a vertical direction BvForming a new two-dimensional geomagnetic fingerprint vector (B)h,Bv) Abbreviated HV fingerprint. To increase the dimensionality of the fingerprint, we sum the HV fingerprint and | | BpThe | | fingerprints are mixed to form a three-dimensional vector (B)h,Bv,||Bp||)。

The key step of solving the geomagnetic fingerprint is the transformation of a coordinate system: carrier coordinate system → navigation coordinate system. The embodiment adopts a rotation matrix method, and for an indoor positioning system, the position on a map is usually defined by an X axis and a Y axis, and the height on the ground is defined by a Z axis, and the system is mainly used for defining the position in the map. The smartphone can implement coordinate system conversion by rotating along XYZ axes, and a matrix rotating around XYZ directions is defined as follows:

where φ, θ, ψ are defined as roll (roll), pitch (pitch), and yaw (yaw) angles, respectively. The rotation sequence adopted is XYZ and is marked as Rxyz(rotation sequence).

Let the accelerometer reading of the cell phone be denoted as Gp=(Gpx,Gpy,Gpz),Gpx,Gpy,GpzRespectively representing gravity accelerometers GpThe three-axis component of (a). Setting the intensity of the earth magnetic field BrIn the environment, the environmental noise added to the earth's magnetic field is V ═ V (V)x,Vy,Vz) Let g be 9.8ms-2Then the following formula can be obtained:

Bp=Rx(φ)Ry(θ)Rz(θ)Br+V

from the above equation, phi, theta, psi can be solved as follows:

the solution of the yaw angle requires knowledge of the orientation of the gyroscope, and generally does not consider rotation in the Z-axis direction, and the rotation matrix can be simplified.

Bf=Ry(-θ)Rx(-φ)Bp

After the coordinate system conversion is completed, the three-dimensional magnetic field vector B is convertedf=(Bfx,Bfy,Bfz) Projected in the horizontal direction (horizontal plane) BhAnd a vertical plane (vertical plane) BvThe HV component is composed as follows.

To extend the fingerprint dimension, (B)h,Bv,||Bp| |) as a fingerprint of the magnetic field strength, the ith reference point RPiThe magnetic field fingerprint at is expressed as:

MFPi={labeli,(xi,yi),Bi,h,Bi,v,||Bi,p||}。

and thirdly, after all the scanned APs in the experimental area are subjected to union set according to Mac addresses, the missing AP value needs to be replaced by-110 dBm. In order to eliminate the dimensional influence between the RSS and the MF, the features need to be preprocessed, and a preceding normalization function is adopted, so that different features are unified into a same data interval [0,1] for analysis.

Wherein X is the original data matrix, Xmax,XminRespectively representing the maximum and minimum values in the X matrix.

Fourthly, as shown in FIG. 4, the network structure of the staged Autoencoders is designed to 262-i-1, 2, …, K, where K represents the number of samples and 262 represents the dimension of the RSS feature. Considering that the coordinates of the reference points need to be fitted subsequently, the activation functions of the Encoder and the Decoder both adopt a Sigmod function: (x) 1/(1+ e)-x). When the iteration number reaches 2000 times, the network tends to be stable, and the reconstruction error is 0.025.

And reconstructing the offline RSS data in the whole area according to the minimum mean square error principle by using a Stacked auto encoder (Stacked auto encoders) to obtain the weight and the offset parameter of the Stacked auto encoders network.

Fifthly, as shown in figure 5; according to the physical limitation of an experimental scene, the whole area is divided into 5 types, namely labels 1-5 are added to off-line training and on-line testing data samples, and the area is divided.

After all offline RSS data are reconstructed, a Decoder layer of the Stacked Autoencoders is disconnected, the structure and parameters of an Encoder layer are reserved, a classifier is added behind the Encoder layer to form a Deep Neural Network (DNN), and cross entropy is used as a loss function, which is shown in the following formula. And N is the number of categories, and the whole network is finely adjusted by using a BP algorithm, so that the classified positioning precision is optimal.

After the classification is finished, drawing a confusion matrix graph, checking the classification accuracy, wherein the classification result is shown in fig. 6, the abscissa represents the classification output by the classifier, the ordinate represents the actual classification information of the sample, and the lowest row represents the accuracy and the misjudgment rate of each classification. The confusion matrix chart shows that the average correct rate of the classification can reach 96.6%, and classification errors mainly occur when the 2 nd type is judged as the 5 th type and the third type is judged as the 2 nd type.

After all offline RSS data are reconstructed, the decoding layer (Decoder) of the Stacked Autoencoders is disconnected, and the encoding layer (Encoder) is saved. And then, connecting a classifier behind the Encoder, setting the value of the number N of the regions in advance, and finely adjusting the whole network according to a BP algorithm according to a cross entropy principle so as to optimize the classification precision.

Sixthly, considering the insufficient resolving power of the earth magnetism in a large range, after the classification is finished, a fully connected regression network is added behind the Encoder layer, and the RSS and the (B) are added in each classh,Bv,||BP| |) the 292-dimensional mixed fingerprints are used as the input of the recurrent neural network, and finally the final positioning error is solved according to the RMSE criterion:

converting the geomagnetic signal from the carrier coordinate system to a navigation coordinate system, and projecting the geomagnetic signal to a horizontal direction (horizontal plane) BhAnd vertical direction (vertical direction) BvAnd a modulus B of the geomagnetic signalpThe combination of | is a three-dimensional vector (B)h,Bv,||Bp| |), a fully connected regression network is connected after the Encoder, and (B)h,Bv,||BpAnd | | l) and RSS form a mixed fingerprint, the coordinate of an offline reference point is fitted in each class, the whole network is finely adjusted according to the minimum principle of Root Mean Square Error (RMSE), and the training is stopped when the offline reference points in each class converge.

For the test points, firstly, the test points are divided according to the second step, then, the fitted coordinates are solved according to the third step, and finally, the average positioning error of the test points is calculated.

Meanwhile, in order to verify the performance of the proposed positioning algorithm, the present embodiment selects four comparison schemes:

(1) WiFi classified positioning error: after classification is finished, only the RSS is used for estimating the positions of the online test points;

(2) WiFi unclassified positioning error: the method comprises the following steps of (1) directly forming a DNN network by using an Encoder layer and a regression function of a stacked self-Encoder to estimate the positions of online test points without dividing the whole experimental scene into regions;

(3) ISODATA: after clustering RSS features by adopting an ISODATA algorithm, estimating the positions of online test points by utilizing Support Vector Regression (SVR);

(4) autosvr: RSS is classified using a stacked auto-encoder and then the positions of the test points are estimated using Support Vector Regression (SVR).

The final positioning result is shown in fig. 7, and it can be seen from the figure that, in a large experimental scene, under the condition of high classification accuracy, the method can bring a gain in positioning performance, and a large positioning error is mainly caused by a classification error; the geomagnetic signal is used as auxiliary information of the RSS, and can bring gain in a low positioning error interval; whereas the ISODATA clustering algorithm is less suitable for sparse RSS signals. The average positioning error of the algorithm proposed by the present invention and the four algorithms mentioned in the patent literature are shown in table 1.

TABLE 1 comparison of Algorithm Performance

The partition fusion positioning method based on WiFi and geomagnetic fingerprints provided by the invention comprises the steps of firstly, extracting features of RSS by adopting a stacking self-encoder according to sparsity of the RSS; then dividing the experimental scene into specific areas, namely adding label information to the RSS samples, and classifying the RSS samples according to the features extracted from the stacked self-encoder; and finally, in each region, inputting RSS and geomagnetism as mixed fingerprints into a recurrent neural network for fitting. The experimental result is analyzed, and the algorithm can obtain good reconstruction, classification and fitting errors under the indoor scene condition.

In summary, the greatest advantage of the present invention compared with the above positioning model is:

firstly, the Stacked Autoencoders learn the characteristics of low-level input data through a multilayer nonlinear hidden layer structure, can extract effective characteristics from a redundant noisy RSS fingerprint library and construct a function mapping relation;

the positioning error of the traditional positioning model is easily influenced by the sampling interval of the reference point in the off-line stage, aiming at the physical limitation of a large-scale scene, the invention divides an experimental scene into different areas, classifies online test points into the areas according to the RSS characteristics, and then regresses in each class, and the increased class information can bring the gain on the positioning performance.

The data fusion of different characteristics has been considered, and to the wiFi signal on a large scale the discrimination is high, and the local discrimination is low, and the geomagnetic signal on a large scale the discrimination is lower, and the local difference is obvious, combines both to compensate respective shortcoming mutually, effectively improves the location effect.

The technical solutions of the embodiments of the present invention can be combined, and the technical features of the embodiments can also be combined to form a new technical solution.

While the invention has been described with reference to a preferred embodiment, various modifications may be made and equivalents may be substituted for elements thereof without departing from the scope of the invention. In particular, the technical features mentioned in the embodiments can be combined in any way as long as there is no structural conflict. It is intended that the invention not be limited to the particular embodiments disclosed, but that the invention will include all embodiments falling within the scope of the appended claims.

16页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种基于无线定位的工程机械控制方法、装置及系统

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类