CN113163484B - Indoor positioning method - Google Patents
Indoor positioning method Download PDFInfo
- Publication number
- CN113163484B CN113163484B CN202110023808.1A CN202110023808A CN113163484B CN 113163484 B CN113163484 B CN 113163484B CN 202110023808 A CN202110023808 A CN 202110023808A CN 113163484 B CN113163484 B CN 113163484B
- Authority
- CN
- China
- Prior art keywords
- area
- fingerprint
- rssi
- positioning
- reference point
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W64/00—Locating users or terminals or network equipment for network management purposes, e.g. mobility management
- H04W64/006—Locating users or terminals or network equipment for network management purposes, e.g. mobility management with additional information processing, e.g. for direction or speed determination
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01S—RADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
- G01S5/00—Position-fixing by co-ordinating two or more direction or position line determinations; Position-fixing by co-ordinating two or more distance determinations
- G01S5/02—Position-fixing by co-ordinating two or more direction or position line determinations; Position-fixing by co-ordinating two or more distance determinations using radio waves
- G01S5/0252—Radio frequency fingerprinting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/23—Clustering techniques
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/044—Recurrent networks, e.g. Hopfield networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/045—Combinations of networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
- G06N3/084—Backpropagation, e.g. using gradient descent
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04B—TRANSMISSION
- H04B17/00—Monitoring; Testing
- H04B17/30—Monitoring; Testing of propagation channels
- H04B17/309—Measuring or estimating channel quality parameters
- H04B17/318—Received signal strength
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Data Mining & Analysis (AREA)
- General Physics & Mathematics (AREA)
- Evolutionary Computation (AREA)
- Life Sciences & Earth Sciences (AREA)
- Artificial Intelligence (AREA)
- General Engineering & Computer Science (AREA)
- Computational Linguistics (AREA)
- General Health & Medical Sciences (AREA)
- Molecular Biology (AREA)
- Computing Systems (AREA)
- Biophysics (AREA)
- Biomedical Technology (AREA)
- Mathematical Physics (AREA)
- Software Systems (AREA)
- Health & Medical Sciences (AREA)
- Signal Processing (AREA)
- Computer Networks & Wireless Communication (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Evolutionary Biology (AREA)
- Bioinformatics & Computational Biology (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Quality & Reliability (AREA)
- Electromagnetism (AREA)
- Radar, Positioning & Navigation (AREA)
- Remote Sensing (AREA)
- Position Fixing By Use Of Radio Waves (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
Description
技术领域technical field
本发明涉及一种定位方法,尤其是指一种室内定位方法。The invention relates to a positioning method, in particular to an indoor positioning method.
背景技术Background technique
由于室内环境复杂以及墙壁遮挡等的天然隔离原因,卫星信号在室内衰减严重,无法满足室内定位对于精度的需求甚至无法完成室内定位。Due to the complex indoor environment and natural isolation reasons such as wall occlusion, satellite signals are severely attenuated indoors, which cannot meet the accuracy requirements of indoor positioning or even complete indoor positioning.
传统的超声波和红外线定位技术在视距范围内定位反应良好,但非视距情况下也无法定位,更适合小范围视距情况下定位;而可见光和UWB(超宽带)可以实现非视距情况下定位,但需要安装额外的软硬件来辅助定位,成本高且可见光易受其他光源影响;至于室内磁场在不同地点磁场强度因环境原因会出现相同的情况,定位精度无法满足要求。The traditional ultrasonic and infrared positioning technology responds well to positioning within the line-of-sight range, but it cannot be positioned under non-line-of-sight conditions, and is more suitable for positioning in small-scale line-of-sight conditions; while visible light and UWB (ultra-wideband) can achieve non-line-of-sight conditions Positioning, but additional software and hardware need to be installed to assist positioning, which is costly and visible light is easily affected by other light sources; as for the indoor magnetic field, the magnetic field strength at different locations will be the same due to environmental reasons, and the positioning accuracy cannot meet the requirements.
现有的基于无线信号的RSSI(接收信号强度指示,Received Signal StrengthIndication)指纹定位方法直接将待定位点的RSSI与指纹库中的指纹进行计算比较得到待定位点的位置坐标或利用神经网络实现RSSI与位置坐标的映射。由于指纹库本身没有及时更新,以及没有考虑设备软硬件差异对于定位结果的影响,进而导致定位实时性差以及指纹库定位精度降低。The existing RSSI (Received Signal Strength Indication) fingerprint positioning method based on wireless signals directly calculates and compares the RSSI of the point to be positioned with the fingerprint in the fingerprint database to obtain the position coordinates of the point to be positioned or uses a neural network to realize RSSI Mapping with location coordinates. Since the fingerprint database itself is not updated in time, and the impact of device software and hardware differences on the positioning results is not considered, the real-time positioning performance is poor and the positioning accuracy of the fingerprint database is reduced.
发明内容Contents of the invention
本发明的目的在于针对上述问题,提供一种室内定位方法。该方法利用室内的结构及布局实现区域划分,从而在在线定位时先进行区域判定,再进行位置坐标判定,层层递进提高定位精度同时降低定位时间;并且利用BP神经网络实现不同软硬件设备之间的映射,消除设备差异带来的定位影响;同时通过指纹库存储多方向指纹,使得定位更具有方向性;引入反馈机制,使得指纹库可以得到及时更新,指纹库的实时性得到增强。The object of the present invention is to provide an indoor positioning method to solve the above problems. This method utilizes the structure and layout of the room to achieve regional division, so that the regional judgment is first performed during online positioning, and then the position coordinates are judged. The positioning accuracy is improved layer by layer and the positioning time is reduced; and the BP neural network is used to realize different software and hardware devices. The mapping between devices eliminates the positioning impact caused by device differences; at the same time, the fingerprint database stores multi-directional fingerprints to make positioning more directional; the introduction of a feedback mechanism enables the fingerprint database to be updated in time, and the real-time performance of the fingerprint database is enhanced.
本发明的目的可采用以下技术方案来达到:The purpose of the present invention can adopt following technical scheme to reach:
一种室内定位方法,包括以下步骤:An indoor positioning method, comprising the following steps:
步骤1、在离线阶段,根据室内结构和布局,对室内进行区域划分,建立相应的坐标轴,并且在区域内设定参考点,在参考点处使用不同类型设备采集无线信号的RSSI,形成指纹向量,以构建指纹数据库;
步骤2、BP神经网络拟合所述不同类型设备采集的无线信号的RSSI;
步骤3、构建电子地图,将信息存储到数据库中;
步骤4、在在线定位阶段,首先进行区域定位,确定待定位点区域;再在区域内进行位置定位,确定待定位点位置坐标;
步骤5、根据目标信息,确定到达目标位置所需经过的参考点集合,然后结合当前位置信息确定当前位置是否在向目标位置行进;
步骤6:根据各种反馈信息,对指纹库进行实时更新。Step 6: Update the fingerprint library in real time according to various feedback information.
进一步地,步骤1中所述的构建指纹库的具体内容包括:Further, the specific content of constructing the fingerprint library described in
1)选定目标设备,将采集的指纹向量用于构建指纹库;1) Select the target device, and use the collected fingerprint vectors to build a fingerprint library;
2)构建一级指纹库,对处于同一区域内的参考点,采用聚类算法,将聚类的结果作为区域标记保存到数据库,作为一级指纹库;2) Build a first-level fingerprint library, use a clustering algorithm for the reference points in the same area, and save the clustering results to the database as a regional mark, as a first-level fingerprint library;
3)构建二级指纹库,对每个区域内的参考点,在参考点处不同方向选取多次采集的RSSI的众数作为参考点处的RSSI值,每个参考点有多个指纹向量对应多个不同方向,将其保存到数据库,作为二级指纹库。3) Construct a secondary fingerprint library. For reference points in each area, select the mode of RSSI collected multiple times in different directions at the reference point as the RSSI value at the reference point. Each reference point has multiple fingerprint vectors corresponding to Multiple different directions, save it to the database as a secondary fingerprint library.
进一步地,所述步骤2的具体内容为:BP神经网络的输入及输出神经元个数相等,其数值为用于室内定位的无线信号发射端的个数;其中,输出为步骤1所选定的目标设备采集的指纹向量,输入为其他设备采集的指纹向量。Further, the specific content of
进一步地,所述步骤3的构建电子地图包含了区域划分结果、部分参考点信息和参考点间路径信息。Further, the construction of the electronic map in
进一步地,步骤1中,在每个参考点的多个方向均多次采集无线信号的RSSI;Further, in
进一步地,所述参考点间路径信息,表示到达某参考点时所需要经过的参考点集合。Further, the path information between reference points indicates a set of reference points that need to pass through when arriving at a certain reference point.
进一步地,步骤4中,所述的在线定位包括以下步骤:Further, in
1)将采集到的待定位点处RSSI值作为输入,经BP神经网络得到映射后的RSSI值;1) The collected RSSI value at the point to be located is used as input, and the mapped RSSI value is obtained through the BP neural network;
2)区域定位,利用近邻算法将映射后的RSSI值与一级指纹库中指纹进行计算,确定待定位点的区域;2) Regional positioning, using the nearest neighbor algorithm to calculate the mapped RSSI value and the fingerprint in the first-level fingerprint database to determine the area of the point to be located;
3)位置定位,在区域内进行二次定位,利用近邻算法将映射后的RSSI值与二级指纹库中指纹进行计算,得到待定位点的位置坐标,确定位置坐标的同时也可以得到当前朝向,然后结合电子地图,将位置信息及朝向显示在电子地图上。3) Position positioning, carry out secondary positioning in the area, use the nearest neighbor algorithm to calculate the mapped RSSI value and the fingerprint in the secondary fingerprint database, and obtain the position coordinates of the point to be located. When determining the position coordinates, the current orientation can also be obtained , and then combined with the electronic map, the location information and direction are displayed on the electronic map.
进一步地,所述步骤5中的判断是否朝目标位置行进的具体内容为:Further, the specific content of judging whether to move towards the target position in the
根据目标位置的参考点路径信息,得到所需经过的参考点集合,将当前位置信息与集合中的参考点做计算,若当前位置隶属于参考点集合,则正朝着目标位置前进。According to the reference point path information of the target position, the set of reference points to be passed is obtained, and the current position information is calculated with the reference points in the set. If the current position belongs to the set of reference points, it is moving towards the target position.
进一步地,步骤1中,所述无线信号包括Wi-Fi、RFID和蓝牙。Further, in
进一步地,步骤1中,所述区域内参考点依据区域大小和实际定位精度需求确定。Further, in
实施本发明,具有如下有益效果:Implement the present invention, have following beneficial effect:
1、本发明利用室内的结构及布局实现区域划分,从而在在线定位时先进行区域判定,再进行位置坐标判定,层层递进提高定位精度同时降低定位时间;并且利用BP神经网络实现不同软硬件设备之间的映射,消除设备差异带来的定位影响。1. The present invention utilizes the indoor structure and layout to realize area division, so that the area is judged first during online positioning, and then the position coordinates are judged, and the positioning accuracy is progressively improved layer by layer while reducing the positioning time; and the BP neural network is used to realize different software The mapping between hardware devices eliminates the impact of positioning caused by device differences.
2、本发明通过指纹库存储多方向指纹,使得定位更具有方向性;引入反馈机制,使得指纹库可以得到及时更新,指纹库的实时性得到增强2. The present invention stores multi-directional fingerprints through the fingerprint library, making positioning more directional; introducing a feedback mechanism, so that the fingerprint library can be updated in time, and the real-time performance of the fingerprint library is enhanced
3、本发明充分考虑设备软硬件差异,引入BP神经网络,定位的同时消除设备软硬件差异对定位结果的影响,并且考虑不同方向对定位影响,每个参考点采集多方向指纹并存入指纹库;同时引入反馈机制,实现对指纹库更新,指纹库实时性高。3. The present invention fully considers the difference of equipment software and hardware, introduces BP neural network, eliminates the influence of equipment software and hardware differences on the positioning results while positioning, and considers the impact of different directions on positioning, and collects multi-directional fingerprints for each reference point and stores them in fingerprints library; at the same time, a feedback mechanism is introduced to update the fingerprint library, and the fingerprint library has high real-time performance.
附图说明Description of drawings
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the present invention. Those skilled in the art can also obtain other drawings based on these drawings without creative work.
图1是本发明室内定位方法的离线建库流程示意图;Fig. 1 is the schematic diagram of the off-line database construction flow chart of the indoor positioning method of the present invention;
图2为本发明室内定位方法在线定位流程示意图;Fig. 2 is a schematic diagram of the online positioning process of the indoor positioning method of the present invention;
图3为本发明室内定位方法的具体实施例的区域坐标化示意图;3 is a schematic diagram of regional coordinates of a specific embodiment of the indoor positioning method of the present invention;
图4为本发明室内定位方法的具体实施例的电子地图示意图;4 is a schematic diagram of an electronic map of a specific embodiment of the indoor positioning method of the present invention;
图5为本发明室内定位方法的具体实施例的区域某一无线路由器(WirelessPoint,WP)的RSSI分布直方图示意图;5 is a schematic diagram of an RSSI distribution histogram of a certain wireless router (WirelessPoint, WP) in an area of a specific embodiment of the indoor positioning method of the present invention;
图6为本发明室内定位方法的具体实施例的参考点某一无线路由器(WP)的RSSI分布直方图示意图;6 is a schematic diagram of an RSSI distribution histogram of a wireless router (WP) at a reference point of a specific embodiment of the indoor positioning method of the present invention;
具体实施方式Detailed ways
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.
实施例:Example:
参见图1和图2,本实施例涉及室内定位方法,包括以下步骤:Referring to Figure 1 and Figure 2, this embodiment relates to an indoor positioning method, including the following steps:
步骤1、在离线阶段,根据室内结构和布局,对室内进行区域划分,建立相应的坐标轴,并且在区域内设定参考点,在参考点处使用不同类型设备在每个参考点的多个方向均多次采集无线信号的RSSI,形成指纹向量,以构建指纹数据库;所述无线信号包括Wi-Fi、RFID和蓝牙。所述区域内参考点依据区域大小和实际定位精度需求确定。所述的构建指纹库的具体内容包括:
1)选定目标设备,将采集的指纹向量用于构建指纹库;1) Select the target device, and use the collected fingerprint vectors to build a fingerprint library;
2)构建一级指纹库,对处于同一区域内的参考点,采用聚类算法,将聚类的结果作为区域标记保存到数据库,作为一级指纹库;2) Build a first-level fingerprint library, use a clustering algorithm for the reference points in the same area, and save the clustering results to the database as a regional mark, as a first-level fingerprint library;
3)构建二级指纹库,对每个区域内的参考点,在参考点处不同方向选取多次采集的RSSI的众数作为参考点处的RSSI值,每个参考点有多个指纹向量对应多个不同方向,将其保存到数据库,作为二级指纹库。3) Construct a secondary fingerprint library. For reference points in each area, select the mode of RSSI collected multiple times in different directions at the reference point as the RSSI value at the reference point. Each reference point has multiple fingerprint vectors corresponding to Multiple different directions, save it to the database as a secondary fingerprint library.
步骤2、BP神经网络拟合所述不同类型设备采集的无线信号的RSSI;BP神经网络的输入及输出神经元个数相等,其数值为用于室内定位的无线信号发射端的个数;其中,输出为步骤1所选定的目标设备采集的指纹向量,输入为其他设备采集的指纹向量。
步骤3、构建电子地图,将信息存储到数据库中;所述电子地图包含了区域划分结果、部分参考点信息和参考点间路径信息。所述参考点间路径信息,表示到达某参考点时所需要经过的参考点集合。
步骤4、在在线定位阶段,首先进行区域定位,确定待定位点区域;再在区域内进行位置定位,确定待定位点位置坐标;所述的在线定位包括以下步骤:
1)将采集到的待定位点处RSSI值作为输入,经BP神经网络得到映射后的RSSI值;1) The collected RSSI value at the point to be located is used as input, and the mapped RSSI value is obtained through the BP neural network;
2)区域定位,利用近邻算法将映射后的RSSI值与一级指纹库中指纹进行计算,确定待定位点的区域;2) Regional positioning, using the nearest neighbor algorithm to calculate the mapped RSSI value and the fingerprint in the first-level fingerprint database to determine the area of the point to be located;
3)位置定位,在区域内进行二次定位,利用近邻算法将映射后的RSSI值与二级指纹库中指纹进行计算,得到待定位点的位置坐标,确定位置坐标的同时也可以得到当前朝向,然后结合电子地图,将位置信息及朝向显示在电子地图上。3) Position positioning, carry out secondary positioning in the area, use the nearest neighbor algorithm to calculate the mapped RSSI value and the fingerprint in the secondary fingerprint database, and obtain the position coordinates of the point to be located. When determining the position coordinates, the current orientation can also be obtained , and then combined with the electronic map, the location information and direction are displayed on the electronic map.
步骤5、根据目标信息,确定到达目标位置所需经过的参考点集合,然后结合当前位置信息确定当前位置是否在向目标位置行进;根据目标位置的参考点路径信息,得到所需经过的参考点集合,将当前位置信息与集合中的参考点做计算,若当前位置隶属于参考点集合,则正朝着目标位置前进。
步骤6:根据各种反馈信息,对指纹库进行实时更新。Step 6: Update the fingerprint library in real time according to various feedback information.
具体的,下面以Wi-Fi作为无线信号为例和附图进行详细说明:Specifically, the following uses Wi-Fi as a wireless signal as an example to describe in detail with the accompanying drawings:
本发明的室内定位方法分为离线建库,在线定位和指纹库更新三个阶段。The indoor positioning method of the present invention is divided into three stages: offline database construction, online positioning and fingerprint database update.
1、离线建库阶段,如图1:1. Offline database construction stage, as shown in Figure 1:
(1)根据室内结构及布局,不同区域间有墙壁等自然遮挡物,划分不同区域,使同一区域内部是连通的(没有墙壁等阻碍),不同区域之间无法连通(有墙壁等阻碍),假设可以划分5个区域,如图3;(1) According to the indoor structure and layout, there are natural shelters such as walls between different areas, and different areas are divided so that the interior of the same area is connected (without obstacles such as walls), and different areas cannot be connected (with obstacles such as walls), Assume that 5 areas can be divided, as shown in Figure 3;
(2)将区域坐标化,为说明方便,用边长为1米的网格对区域划分,选定左下角为坐标原点,坐标化后如图3所示;(2) Coordinate the area. For the convenience of explanation, use a grid with a side length of 1 meter to divide the area, select the lower left corner as the coordinate origin, and coordinate as shown in Figure 3;
(3)在区域内根据实际需求确定参考点,参考点为网格顶点或网格中心点,如图3中黑色点表示参考点;(3) Determine the reference point in the area according to the actual needs, the reference point is the grid vertex or the grid center point, as shown in Figure 3, the black point represents the reference point;
(4)在每个参考点处按每2s采集东南西北四个朝向的无线路由器(WP)的RSSI值,室内假设一共有12个无线路由器,这样每一个参考点的指纹向量可以表示为一个四元组即APi=((xi,yi),Di,Ai,RSSIi),其中(xi,yi)表示参考点i坐标,Di表示参考点i的朝向Di={0,1,2,3}分别表示东南西北,Ai表示参考点i所在对应的区域Ai={1,2,3,4,5}表示5个不同区域,表示参考点i采集的RSSI向量,其中表示在参考点i采集的第j个无线路由器的RSSI的值,i表示参考点总数,j为无线路由器总数;(4) At each reference point, the RSSI values of wireless routers (WP) in four orientations are collected every 2s. Assuming that there are 12 wireless routers in the room, the fingerprint vector of each reference point can be expressed as a four The tuple is AP i = ((xi , y i ), D i , A i , RSSI i ), where (xi , y i ) represents the coordinates of reference point i, and D i represents the orientation of reference point i D i = {0, 1, 2, 3} respectively represent the southeast and northwest, and A i represents the area corresponding to the reference point i. A i = {1, 2, 3, 4, 5} represents 5 different areas, Indicates the RSSI vector collected at reference point i, where Represent the value of the RSSI of the jth wireless router collected at reference point i, i represents the total number of reference points, and j is the total number of wireless routers;
(5)使用三个不同型号手机进行采集,手机型号标为A,B,C;每一个参考点每个朝向采集25次,每个参考点对于采集不到的无线路由器其RSSI值我们设定为-100dB。如某次采集结果:AP={(4,8);0;1;{-45,-39,-50,-32,-65,-100.-70,-77,-100,-100,-48,,-100,}},表示某次采集到的参考点坐标为(4,8),朝向为东,区域号为1,RSSI向量为{-45,-39,-50,-32,-65,-100.-70,-77,-100,-100,-48,-100,}。采集示例如下所示:(5) Use three different models of mobile phones for collection, and the mobile phone models are marked as A, B, and C; each reference point is collected 25 times in each direction, and each reference point is set for the RSSI value of the wireless router that cannot be collected -100dB. Such as a collection result: AP={(4,8);0;1;{-45,-39,-50,-32,-65,-100.-70,-77,-100,-100, -48,,-100,}}, indicating that the coordinates of the reference point collected in a certain time are (4,8), the orientation is east, the area number is 1, and the RSSI vector is {-45,-39,-50,-32 ,-65,-100.-70,-77,-100,-100,-48,-100,}. An example collection is as follows:
表1:采集的指纹向量示例Table 1: Example of fingerprint vectors collected
(6)选取手机型号A采集的RSSI向量作为BP神经网络的输出,手机型号B,C采集的RSSI向量作为BP神经网络的输入,隐藏层神经元个数为10;隐藏层神经元传输函数选择“tansig”,输出层神经元传输函数选择“purelin”,反向传播训练函数选择“traingd”,训练次数为10000,训练目标为10-7,其余默认,利用MATLAB自带的BP神经网络函数进行训练,得到训练好的模型,在定位阶段使用。(6) Select the RSSI vector collected by mobile phone model A as the output of the BP neural network, and the RSSI vector collected by mobile phone models B and C as the input of the BP neural network. The number of neurons in the hidden layer is 10; the transfer function of the hidden layer neurons is selected "tansig", select "purelin" for the neuron transfer function of the output layer, select "trainingd" for the backpropagation training function, set the number of training times to 10000, and set the training target to 10 -7 , and use the BP neural network function that comes with MATLAB as the default Training, get the trained model and use it in the positioning phase.
(7)以手机型号A采集得到的指纹向量为标准,构建指纹库。(7) Using the fingerprint vector collected by the mobile phone model A as the standard, construct the fingerprint database.
(8)构建每个参考点的RSSI向量,对于同一朝向同一无线路由器我们以25次采集过程中RSSI值的众数作为在该参考点无线路由器的RSSI值,如参考点(4,8)处,朝向东,采集25次,无线路由器的值为{-65,-63,-65,-65,-65,-65,-65,-65,-65,-65,-65,-65,-65,-65,-65,-65,-63,-64,-64,-66,-59,-66,-64,-64,-64},则在参考点(4,8)处,朝向东,无线路由器的RSSI值为-65,同理得到每个参考点对应的无线路由器的RSSI向量,形成二级指纹库,二级指纹库示例如下:(8) Construct the RSSI vector of each reference point. For the same wireless router in the same direction, we use the mode of the RSSI value in the 25 acquisitions as the RSSI value of the wireless router at the reference point, such as reference point (4,8) , facing east, collecting 25 times, the value of the wireless router is {-65,-63,-65,-65,-65,-65,-65,-65,-65,-65,-65,-65, -65,-65,-65,-65,-63,-64,-64,-66,-59,-66,-64,-64,-64}, at the reference point (4,8) , facing east, and the RSSI value of the wireless router is -65. Similarly, the RSSI vector of the wireless router corresponding to each reference point is obtained to form a secondary fingerprint library. The example of the secondary fingerprint library is as follows:
表2:二级指纹库Table 2: Secondary Fingerprint Library
(9)对于同一区域内的参考点,基于K-means(K均值)进行聚类,得到每个区域的一级指纹库,具体过程为:(9) For the reference points in the same area, cluster based on K-means (K-means) to obtain the first-level fingerprint library of each area. The specific process is as follows:
1)随机地选择K个RSSI向量,每个RSSI向量代表一个簇中心,即选择K个初始中心;1) Randomly select K RSSI vectors, each RSSI vector represents a cluster center, that is, select K initial centers;
2)对剩余的每个RSSI向量,根据其与各簇中心的相似度(欧几里得距离),rssij表示参考点处测得的第j个Wi-Fi路由器的值,表示在簇中心i处的第j个Wi-Fi路由器的RSSI的值,将它赋给与其最相似的簇中心所对应的簇;2) For each remaining RSSI vector, according to its similarity (Euclidean distance) with each cluster center, rssi j represents the value of the jth Wi-Fi router measured at the reference point, Represent the value of the RSSI of the jth Wi-Fi router at the cluster center i, and assign it to the cluster corresponding to the cluster center most similar to it;
3)然后重新计算每个簇中所有RSSI向量的平均值,作为新的簇中心。3) Then recalculate the mean value of all RSSI vectors in each cluster as the new cluster center.
4)不断重复2),3),直到准则函数收敛,也就是簇中心不发生明显的变化。采用均方差作为准则函数,即最小化每个点到最近簇中心的距离的平方和。4) Repeat 2) and 3) until the criterion function converges, that is, the cluster center does not change significantly. mean square error As a criterion function, i.e. minimize the sum of the squares of the distances of each point to the nearest cluster center.
在同一区域内对于同一个无线路由器其采集的RSSI值符合高斯分布,构建RSSI的分布直方图,如图5,根据2δ原则,δ为高斯分布的标准差,我们可以得到该区域内同一个无线路由器的RSSI值的上限和下限,如上限为-57dB,下限为-68dB,按相差1dB计算,进一步确定每个区域聚类个数K=11,一级指纹库示例如表3所示In the same area, the RSSI value collected by the same wireless router conforms to the Gaussian distribution, and the RSSI distribution histogram is constructed, as shown in Figure 5. According to the 2δ principle, δ is the standard deviation of the Gaussian distribution, and we can get the same wireless router in the area. The upper limit and lower limit of the RSSI value of the router, such as the upper limit is -57dB, the lower limit is -68dB, calculated according to the difference of 1dB, further determine the number of clusters in each area K = 11, the example of the first-level fingerprint library is shown in Table 3
表3:一级指纹库示例Table 3: Example of a first-level fingerprint library
2、构建电子地图,电子地图如图4所示;2. Build an electronic map, as shown in Figure 4;
3、在线定位阶段,如图2:3. Online positioning stage, as shown in Figure 2:
(1)用户手持手机假设型号为B,采集得到用户的RSSI向量;(1) The user holds the mobile phone assuming that the model is B, and collects the user's RSSI vector;
(2)将用户采集到的RSSI向量经过训练后的BP神经网络,得到对应新的RSSI值向量;(2) The RSSI vector collected by the user is trained through the BP neural network to obtain a corresponding new RSSI value vector;
(3)进行区域判定,利用KNN(K近邻)算法将新的RSSI向量与一级指纹库中指纹进行计算,确定用户所在的区域。在一级指纹库KNN算法中采用欧几里得作为距离判定:即rssij表示待定位点的第j个无线路由器的值,表示在一级指纹库中指纹i的第j个无线路由器的RSSI的值。在计算后选取距离d最小的K个点,此处取K=1,即取查看距离d最小的点对应区域作为待测点的区域,设计算后区域判定结果取区域号1。(3) Carry out regional determination, use the KNN (K nearest neighbor) algorithm to calculate the new RSSI vector and the fingerprint in the first-level fingerprint database, and determine the user's area. In the KNN algorithm of the first-level fingerprint library, Euclidean is used as the distance judgment: that is rssi j represents the value of the jth wireless router of the point to be located, Indicates the RSSI value of the jth wireless router with fingerprint i in the first-level fingerprint database. After the calculation, select K points with the smallest distance d, where K=1 is taken, that is, the area corresponding to the point with the smallest viewing distance d is taken as the area of the point to be measured, and the
(4)在区域号为1的区域内,利用KNN(K近邻)算法进行二次定位,得到待定位点的位置坐标。在二级指纹库中考虑到朝向,采用余弦相似度算法作为距离判定:RSSI·RSSIi表示待测点和参考点i的RSSI向量的点积(数量积),表示待测点和参考点i的RSSI向量模的乘积。每个参考点计算四次(对于四个方向),我们取余弦相似度值最大的结果作为该点距离,说明待定位点当前朝向与其最接近,取前K个参考点计算其坐标的平均值作为待定位点的最终位置坐标,即根据参考点处RSSI直方分布图如图6,结合高斯分布的2δ原则,δ为高斯分布的标准差,取K=4,计算后位置坐标判定结果为(4,8)。(4) In the area whose area number is 1, use the KNN (K nearest neighbor) algorithm to perform secondary positioning to obtain the position coordinates of the point to be located. Considering the orientation in the secondary fingerprint library, the cosine similarity algorithm is used as the distance judgment: RSSI RSSI i represents the dot product (quantity product) of the RSSI vector of the point to be measured and the reference point i, Indicates the product of the RSSI vector modulus of the point to be measured and the reference point i. Each reference point is calculated four times (for the four directions), and we take the result with the largest cosine similarity value as the point distance, indicating that the current orientation of the point to be located is closest to it, and take the first K reference points to calculate the average value of their coordinates As the final position coordinates of the point to be located, that is According to the RSSI histogram distribution at the reference point as shown in Figure 6, combined with the 2δ principle of Gaussian distribution, δ is the standard deviation of Gaussian distribution, K=4, and the position coordinate judgment result after calculation is (4,8).
4、如图4所示,当前位置信息1,搜索的位置信息为2,则参考点集合构成的行进路线为图2中红色路径。4. As shown in Figure 4, the current location information is 1, and the searched location information is 2, then the travel route formed by the set of reference points is the red path in Figure 2.
5、用户对定位结果进行评价,满意则将用户采集的RSSI值向量加入到二级指纹库对应的位置坐标处,更新指纹库,不满意则放弃此次更新。用户采集的RSSI={-45,-39,-50,-32,-65,-100.-70,-77,-100,-100,-48,,-100,},最后定位结果的位置坐标为(4,8),若用户对此次定位结果满意,将二级指纹库中指纹向量{(4,8);0;1;{-45,-39,-50,-32,-63,-100.-70,-79,-100,-100,-45,,-100,}}更新为指纹向量{(4,8);0;1;{-45,-39,-50,-32,-65,-100.-70,-77,-100,-100,-48,,-100,}}。5. The user evaluates the positioning results. If satisfied, the RSSI value vector collected by the user is added to the corresponding position coordinates of the secondary fingerprint database, and the fingerprint database is updated. If not satisfied, the update is abandoned. RSSI collected by the user={-45,-39,-50,-32,-65,-100.-70,-77,-100,-100,-48,,-100,}, the position of the final positioning result The coordinates are (4,8), if the user is satisfied with the positioning result, the fingerprint vector {(4,8);0;1;{-45,-39,-50,-32,- 63,-100.-70,-79,-100,-100,-45,,-100,}} update to fingerprint vector {(4,8);0;1;{-45,-39,-50 ,-32,-65,-100.-70,-77,-100,-100,-48,,-100,}}.
以上所揭露的仅为本发明一种较佳实施例而已,当然不能以此来限定本发明之权利范围,因此依本发明权利要求所作的等同变化,仍属本发明所涵盖的范围。The above disclosure is only a preferred embodiment of the present invention, which certainly cannot limit the scope of the present invention. Therefore, equivalent changes made according to the claims of the present invention still fall within the scope of the present invention.
Claims (7)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110023808.1A CN113163484B (en) | 2021-01-08 | 2021-01-08 | Indoor positioning method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110023808.1A CN113163484B (en) | 2021-01-08 | 2021-01-08 | Indoor positioning method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113163484A CN113163484A (en) | 2021-07-23 |
CN113163484B true CN113163484B (en) | 2022-11-18 |
Family
ID=76878618
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110023808.1A Expired - Fee Related CN113163484B (en) | 2021-01-08 | 2021-01-08 | Indoor positioning method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113163484B (en) |
Families Citing this family (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113613167B (en) * | 2021-08-05 | 2022-07-12 | 广东工业大学 | An indoor positioning method and device based on transfer learning |
CN113612555B (en) * | 2021-08-19 | 2022-06-07 | 江西赛柏科技有限公司 | Intelligent calibration method and system based on wireless radio frequency signal strength of mobile terminal |
CN114745660B (en) * | 2022-04-01 | 2024-07-26 | 北京航空航天大学 | FM indoor fingerprint library online construction method based on signal propagation model |
CN114760586A (en) * | 2022-04-20 | 2022-07-15 | 国网电力科学研究院有限公司 | Indoor positioning method, device and system |
CN115665852B (en) * | 2022-12-14 | 2023-05-05 | 深圳开鸿数字产业发展有限公司 | Indoor positioning method, device, equipment and storage medium |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106851571A (en) * | 2017-01-20 | 2017-06-13 | 华南理工大学 | WiFi localization methods in a kind of quick KNN rooms based on decision tree |
Family Cites Families (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
GB201222376D0 (en) * | 2012-12-12 | 2013-01-23 | Al Najjar Ahmad | System and method for determining a postion of a mobile unit |
CN103634901B (en) * | 2013-11-05 | 2016-08-17 | 上海交通大学 | Novel location fingerprint based on Density Estimator gathers extracting method |
CN103885030A (en) * | 2014-03-07 | 2014-06-25 | 电子科技大学 | Locating method of mobile node in wireless sensor network |
CN108882363A (en) * | 2018-06-14 | 2018-11-23 | 贵州大学 | A kind of multi-direction acquisition combines the WiFi fingerprint indoor orientation method of cluster |
CN110958583B (en) * | 2019-10-31 | 2021-02-09 | 西南科技大学 | Indoor positioning method based on position and strength dual clustering |
-
2021
- 2021-01-08 CN CN202110023808.1A patent/CN113163484B/en not_active Expired - Fee Related
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106851571A (en) * | 2017-01-20 | 2017-06-13 | 华南理工大学 | WiFi localization methods in a kind of quick KNN rooms based on decision tree |
Also Published As
Publication number | Publication date |
---|---|
CN113163484A (en) | 2021-07-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN113163484B (en) | Indoor positioning method | |
CN106023587B (en) | Track data road network fine matching method based on Multi-information acquisition | |
CN107071743B (en) | Rapid KNN indoor WiFi positioning method based on random forest | |
CN106912105B (en) | Three-dimensional positioning method based on PSO _ BP neural network | |
CN105263113B (en) | A kind of WiFi location fingerprints map constructing method and its system based on crowdsourcing | |
CN106851571B (en) | Decision tree-based rapid KNN indoor WiFi positioning method | |
CN107703480B (en) | A hybrid kernel function indoor localization method based on machine learning | |
CN108534779A (en) | One kind is corrected based on track and the improved indoor positioning map constructing method of fingerprint | |
CN104320759B (en) | Based on fixedly target indoor locating system fingerprint base construction method | |
CN105120479B (en) | Signal strength difference correction method for Wi-Fi signals between terminals | |
CN106851573A (en) | Joint weighting k nearest neighbor indoor orientation method based on log path loss model | |
CN104703143A (en) | Indoor positioning method based on WIFI signal strength | |
Yang et al. | DeepWiPos: A deep learning-based wireless positioning framework to address fingerprint instability | |
CN104066058B (en) | A kind of WLAN indoor orientation methods based on double set fingerprint superpositions | |
CN105223546A (en) | Based on the indoor orientation method of received signal strength and reference point locations double focusing class | |
CN109558902A (en) | A kind of fast target detection method | |
CN105813194A (en) | Indoor positioning method based on fingerprint database secondary correction | |
CN104581644B (en) | Indoor WLAN fingerprint databases multiple spot adaptive updates method based on radial base interpolation | |
CN110636437B (en) | An Assisted Location Method Based on Fingerprint Pairs | |
CN108882363A (en) | A kind of multi-direction acquisition combines the WiFi fingerprint indoor orientation method of cluster | |
CN110673090A (en) | Passive multi-station multi-target positioning method based on DBSCAN | |
CN109195104A (en) | A kind of indoor orientation method combined based on support vector regression and Kalman filtering | |
WO2022242018A1 (en) | Indoor target positioning method based on improved cnn model | |
CN108303672A (en) | WLAN indoor positionings error correcting method based on location fingerprint and system | |
CN107135541A (en) | Ultra-Wideband Indoor Positioning Method Based on OPTICS Density Clustering and BP Neural Network |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20221118 |
|
CF01 | Termination of patent right due to non-payment of annual fee |