A method, device and storage medium for positioning in space
The AP measurement weight is optimized by using kernel density estimation method and maximum likelihood estimation combined with Bayesian algorithm, which solves the problem of low indoor positioning accuracy of FTM technology, achieves cost-effective meter-level precision positioning, and improves the scalability of the positioning system. sex and popularity.
Patent Information
- Application Number
- CN202011252061.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-11-11
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2040-11-11
AI Technical Summary
The existing FTM technology based on the IEEE 802.11mc protocol is difficult to achieve meter-level positioning accuracy in indoor complex multipath environments, resulting in low indoor positioning accuracy. Moreover, existing research methods have poor scalability and strong equipment specificity, making it difficult to popularize on a large scale.
Kernel density estimation method and maximum likelihood estimation combined with Bayesian algorithm are used to optimize AP measurement weights through linear least squares method and maximum likelihood estimation, improve positioning accuracy, and design a low-cost, easy-to-popular single-target network space. Internal positioning scheme.
It achieves cost-effective meter-level precision positioning in indoor environments, reduces positioning errors, improves the scalability and popularity of the positioning system, and is suitable for a variety of scenarios.
Smart Images

Figure CN112462325B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to, but is not limited to, the field of wireless network spatial positioning, and in particular to a spatial positioning method, device, and storage medium. Background Art
[0002] Wireless local area networks (WLANs) have been applied to all walks of life and have a wide range of AP device support. If accurate indoor positioning can be achieved in combination with mainstream AP devices on the market, it will be greatly beneficial to the development of indoor positioning-related services, monitoring and tracking tasks. Currently, the IEEE 802.11-2016 protocol (also known as 802.11mc) provides a precise time measurement scheme (FTM) based on round-trip time (RTT). The ranging module implemented according to this scheme can, in principle, provide measurement results with meter-level accuracy. Since it is part of the wireless network standard and does not require additional hardware configuration, the positioning technology based on 802.11mc has a very optimistic application prospect.
[0003] In the process of using FTM technology for measurement, due to the non-Gaussianity of the ranging error, it is still an unsolved problem to use ordinary commercial products to perform meter-level precision positioning in actual indoor places. The complex indoor multipath environment causes the ranging error of the FTM solution to be usually 1-2m or even higher, and the ranging accuracy will directly affect the positioning accuracy. The precise time measurement scheme of the 802.11mc protocol is used for ranging and positioning. Only through error calibration in an open outdoor environment can the ranging with meter-level accuracy be achieved to a certain extent. In an environment with complex multipath effects indoors, the FTM positioning effect is even less likely to achieve satisfactory ranging accuracy as in an outdoor environment. Typically, the Wi-Fi RTT Scan App, an application released by Google in April 2019 that can use Wi-Fi for indoor positioning, can only achieve an accuracy of 1 to 2 meters.
[0004] In order to solve the above problems, most of the current FTM-based positioning technology research focuses on improving indoor positioning accuracy. By combining a large number of APs, inertial sensors, building fingerprint databases, and client historical behavior information, a high-precision positioning effect can be achieved in a specific indoor environment. However, due to factors such as poor scalability, device specificity, and a large amount of offline data collection work in the early stage, its applicable scenarios are limited and it cannot be popularized on a large scale or put into commercial use. Therefore, the research of low-cost, easy-to-popularize, and high-precision single-target network positioning systems has become an urgent problem that researchers in this field need to solve. Summary of the invention
[0005] The following is a summary of the subject matter described in detail herein. This summary is not intended to limit the scope of the claims.
[0006] The embodiments of the present disclosure provide a spatial positioning method, device, system and storage medium, which can effectively improve the positioning accuracy in space based on a cost-effective solution.
[0007] The embodiment of the present disclosure provides a spatial positioning method, comprising:
[0008] Obtain the measured distances from at least three wireless access points (APs) to the site respectively;
[0009] According to the measured distance, based on a single target network positioning model, a linear least square method is used to perform coarse positioning to determine a coarse positioning result of the site;
[0010] Based on maximum likelihood estimation, determine the AP measurement weight objective function;
[0011] The rough positioning result is used as an iteration initial value, the AP measurement weight objective function is iterated according to a preset first optimization algorithm, and an optimal solution of the AP measurement weight objective function is determined; and the positioning result of the site is determined according to the optimal solution.
[0012] In some exemplary embodiments, the step of respectively obtaining a measured distance from at least three wireless access points AP to the station includes:
[0013] According to the precise time measurement FTM function, respectively obtain original FTM measurement data sets from each of the at least three APs to the site;
[0014] According to the original FTM measurement data set, a kernel density estimation method is used to determine the measurement distance from each AP to the site.
[0015] In some exemplary embodiments, before performing coarse positioning according to the measured distance and based on a single target network positioning model using a linear least squares method to determine the coarse positioning result of the site, the method further includes:
[0016] It is determined whether each measured distance is less than a preset first distance threshold. If so, a linear fit is performed on the measured distance to correct the measured distance.
[0017] In some exemplary embodiments, the performing rough positioning using a linear least squares method based on a single target network positioning model according to the measured distance to determine a rough positioning result of the site includes:
[0018] According to the location information of the at least three APs and the measured distance, based on the single target network positioning model, a site positioning error equation group is established;
[0019] The linear least square method is used to fit the station positioning error equation group and construct a normal equation;
[0020] The normal equation is solved to obtain a rough positioning result of the site.
[0021] In some exemplary embodiments, when the number of APs is greater than 3, the linear least square method is used to fit the site positioning error equation group to construct a normal equation, including:
[0022] Select an AP with the shortest measurement distance from the APs and record it as the nearest AP;
[0023] The equation corresponding to the nearest AP in the site positioning error equation group is used as a subtracted term, and the site positioning error equation group is fitted using a linear least squares method to construct the normal equation.
[0024] In some exemplary embodiments, determining the AP measurement weight objective function based on maximum likelihood estimation includes:
[0025] Based on maximum likelihood estimation, the distance measurement variance of each AP is used as a weight to optimize the minimum error square sum function to obtain the AP measurement weight objective function.
[0026] In some exemplary embodiments, the first optimization algorithm includes: a Bayesian algorithm.
[0027] In some exemplary embodiments, the first distance threshold is a threshold determined according to a line-of-sight environment from the AP to the site in a space.
[0028] An embodiment of the present disclosure also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program for performing intra-space positioning, and the processor is configured to read and run the computer program for performing intra-space positioning to execute any of the above-mentioned intra-space positioning methods.
[0029] An embodiment of the present disclosure further provides a storage medium, in which a computer program is stored, wherein the computer program is configured to execute any of the above-mentioned methods for positioning in space when running.
[0030] Other aspects will be apparent upon reading and understanding the drawings and detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 This is a schematic diagram of a positioning model in an embodiment of the present disclosure;
[0032] Figure 2 It is a flow chart of a method for positioning in space in an embodiment of the present disclosure;
[0033] Figure 3 It is a structural framework diagram of a spatial positioning system in an embodiment of the present disclosure;
[0034] Figure 4 is a flow chart of an LLS algorithm based on a close-proximity AP strategy in an embodiment of the present disclosure;
[0035] Figure 5 A schematic diagram of a kernel density estimation curve in an embodiment of the present disclosure;
[0036] Figure 6 This is a flow chart of a method for positioning in space in another embodiment of the present disclosure;
[0037] Figure 7 It is a structural framework diagram of a spatial positioning device in another embodiment of the present disclosure. DETAILED DESCRIPTION
[0038] To make the purpose, technical solution and advantages of the present invention clearer, the present invention will be further described in detail below in conjunction with the accompanying drawings and specific embodiments. It should be noted that the embodiments and features in the embodiments of the present application can be combined with each other arbitrarily without conflict.
[0039] The following step numbers do not limit a specific execution order, and the execution order of some steps can be adjusted according to the specific embodiment. The "first distance threshold" and "first optimization algorithm" involved in the following records are used to reflect the distance threshold or optimization algorithm in the determination step, but do not limit the priority, execution order or other attributes. It should be noted that the embodiments described here are only for illustration and are not intended to limit the solutions provided by the present disclosure. In the following description, in order to provide a thorough understanding of the present invention, a large number of specific details are explained. However, it is not necessary for a person of ordinary skill in the art to adopt these specific details to implement the solution of the present disclosure, and the relevant specific details can be implemented by using relevant technical solutions known to those skilled in the art.
[0040] Embodiment 1
[0041] The spatial positioning solution involved in the present disclosure mainly uses the precise time measurement solution FTM provided by the 802.11mc protocol and the Wi-Fi FTM Linux Tool open source tool to implement a single-target wireless network spatial positioning solution, wherein the FTM single-target positioning model is as follows: Figure 1 As shown, at least 3 APs are included.
[0042] The present disclosure provides a method for positioning in space, the process of which is as follows: Figure 2 As shown, including:
[0043] Step 1, FTM ranging: Obtain the original FTM measurement data set from each AP to the station (STA) according to the FTM solution.
[0044] Step 2, kernel density estimation: Based on the original FTM measurement data set obtained, the kernel density estimation method is used to determine the measurement distance from each AP to the STA;
[0045] Step 3, determine whether the kernel density estimation result is less than a preset first distance threshold; if less than, execute step 4; if greater than or equal to, execute step 5;
[0046] Step 4, linear fitting correction: when the measured distance from an AP to a STA obtained in step 2 is less than the first distance threshold, linear fitting corrects / modifies the measured distance;
[0047] Step 5, coarse positioning: Based on the close AP strategy, the linear least squares method (LLS) is used to perform coarse positioning to determine the coarse positioning result of the STA;
[0048] Step 6, determining an AP measurement weight objective function; determining an AP measurement weight objective function based on maximum likelihood estimation;
[0049] Step 7, solving the AP measurement weight objective function to determine the positioning result; using a preset first optimization algorithm, taking the coarse positioning result as an iteration initial value, to determine the optimal solution of the AP measurement weight objective function; and determining the positioning result of the STA according to the optimal solution.
[0050] In some exemplary embodiments, the first optimization algorithm is a Bayesian algorithm, that is, the Bayesian algorithm is used to iterate to find the optimal solution of the AP measurement weight objective function, and the optimal solution is the final positioning result of the STA.
[0051] In some exemplary embodiments, the spatial positioning method adopts a kernel density estimation method and an adaptive Bayesian algorithm of maximum likelihood estimation. Therefore, the spatial positioning method is also called an adaptive Bayesian positioning method based on kernel density and maximum likelihood estimation (Kernel Density and Maximum Likelihood Estimation-Adaptive Bayesian Algorithm, MLKB).
[0052] In some exemplary embodiments, step 1 includes: collecting an original measurement data set from the AP to the STA.
[0053] Currently, tools with open software support for accessing FTM measurements are available (an open source code with a Linux driver that implements the FTM ranging function, see http: / / www.winlab.rutgers.edu / ~gruteser / projects / ftm / Setups.htm), that is, wireless network cards that provide support for FTM measurement services include Intel Wireless-AC8260, Intel Dual Band Wireless-AC 8265, and Intel Wireless-AC 9260. Even though they can "support" FTM RTT, they are not allowed to act as access points and therefore cannot act as FTM RTT responders. In some exemplary embodiments, the Intel 8260ac wireless network card is selected for the STA as the access point (AP) to send FTM requests, so that it can operate well on channels 36, 40, 44, or 48 in the 5GHz band.
[0054] In the selection of AP devices, some routers have the function of responding to IEEE 802.11mc FTM RTT requests, but do not explicitly advertise this function in the beacon frame because they may not fully support FTM measurements in some cases, resulting in large measurement errors, frequent abnormal values, or crashes when the AP is required to respond "too frequently". Currently, popular routers on the market such as ASUS RT-ACRH13, ASUS RT-ACRH17, Netgear Orbi (RBR20), Linksys EA6350 v.3 AC 1200, Eero Pro, etc. can support FTM measurement functions. Among them, the ASUS RT-ACRH17 router is a high-performance wireless router for home users. It is a relatively cheap product among many routers that support the FTM function. Since the ASUS RT-ACRH13 is difficult to buy in the domestic market, the ASUS RT-ACRH17 router is selected as the AP in some exemplary embodiments.
[0055] It is worth noting that ASUS RT-ACRH17 uses Qualcomm IPQ4019 chip in the 2.4 GHz band and Qualcomm QCA9984 chip in the 5 GHz band. This embodiment chooses to perform FTM test on the 5 GHz band to obtain fine-grained ranging resolution.
[0056] When the hardware equipment and software configuration are ready, the FTM request can be initialized on the STA side. In some exemplary embodiments, the iw command line tool (iw is a CLI configuration tool based on nl80211 for configuring wireless device STA nodes in Linux) and the corresponding patch (see https: / / johannes.sipsolutions.net / Projects / ) are used to add the FTM function to the iw command, and the STA sends an FTM request to start the FTM process. Before issuing a request, specific information about the AP needs to be obtained in order to send an FTM request. This information includes the MAC address, supported bandwidth, and frequency. If the STA sends an FTM request to an AP that does not support the FTM function, the AP will not respond, and the STA must wait for a timeout to return an unsuccessful ranging state. To avoid this delay, in some exemplary embodiments, the FTM request is sent to an AP that supports the FTM protocol.
[0057] When the STA sends an FTM request to the AP, and the AP receives the request and reaches an agreement to return an ACK, the AP starts to automatically send FTM frames and waits for the ACK sent back by the STA to estimate the RTT. This process is implemented in the proprietary firmware. In order to remove the processing delay on the STA side from the RTT, the AP transmits the captured timestamp back to the STA, and the proprietary firmware in the STA calculates the RTT. By increasing the number of FTM samples in each burst, the AP can send FTM frames in sequence, and the STA estimates the RTT of each FTM / ACK message pair, but only returns the average RTT (ps) and the corresponding distance (cm) information in the end.
[0058] In some exemplary embodiments, step 2 includes: obtaining a measurement distance from each AP to the STA according to the original measurement data set from the AP to the STA obtained in step 1.
[0059] Among them, since the error of measuring distance is non-Gaussian, the error of estimating the actual distance by using simple statistical values such as average values of multiple distance measurement results is large. Due to the complexity of the environment in the space (such as indoors) (such as the placement and angle of the ceiling, floor, brick wall or furniture), different media will lead to Gaussian errors of different distributions, thereby affecting the final distance measurement distribution result. Therefore, it is impossible to use the mixed Gaussian model to solve the probability density distribution of the measured distance (the number of Gaussian mixture models K cannot be determined). The kernel density estimation method (KDE) is used in probability theory to estimate unknown density functions and is one of the non-parametric test methods. It does not use prior knowledge about data distribution and does not make any assumptions about data distribution. It is a method for studying data distribution characteristics from data samples, and is highly valued in both statistical theory and application fields. Therefore, it is different from the method of directly using the average or median of the measured distance as the result after removing outliers. The method provided in the present disclosure finally uses the kernel density estimation method to obtain the measured distance between STA and AP.
[0060] It is worth noting that kernel density estimation does not find the true distribution function. It uses a kernel function (such as Gaussian) to treat the data of each data point + bandwidth as the parameters of the kernel function, obtains N kernel functions, and then linearly superimposes them to form an estimation function of the kernel density. After normalization, it becomes the kernel density probability density function. Therefore, the core steps of the kernel density estimation algorithm are described as follows:
[0061] 1. Approximate each observation with a normal distribution curve;
[0062] 2. Superimpose the normal distribution curves of all observations;
[0063] 3. The normalized bandwidth parameter is used to approximate the width of the normal distribution curve.
[0064] The "observation" here can be understood as one of the multiple FTM distance measurement data at the same sampling point. The observation vicinity refers to the extremely small range of a measurement data result. By approximating the normal distribution of each extremely small range and then superimposing it, a complete normal distribution curve can be obtained (such as Figure 5 ). Figure 5 As shown in FIG. 1 , the measurement result of a sampling point (a point where the actual distance between an AP and a STA is 0.6 meters) has a negative value on the horizontal axis due to the AP's internal correction algorithm. Therefore, the result needs to be fitted to correct / amend the error.
[0065] The pseudo code description of the KDE kernel density estimation algorithm for spatial positioning scenarios is shown in Algorithm 1. After fitting, the x and y coordinates of the KDE estimation curve are returned. By finding the point point with the maximum value of the y coordinate, the horizontal coordinate kdefit_x of the peak value of the probability density function can be determined. This coordinate value is the measured distance from AP to STA obtained by the kernel density estimation method.
[0066] Algorithm 1. KDE kernel density estimation method.
[0067] Input: Dis_data matrix of the ranging data set from all APs to a STA
[0068] Output: The horizontal coordinates of the peak points of the fitting function of all APs, kdefit_x set
[0069] Initialize the peak point horizontal coordinate set list of all APs x_result = []
[0070] FOR i=1 to n,do
[0071] Extract the distance measurement data set dis_data[i] of APi
[0072] Select kernel function and bandwidth kernel = 'gau', bw = 'scott'
[0073] Create a new KDE_FIT object and substitute the APi range data list for kde.fit fitting
[0074] Calculate the KDE curve kdefit_x, kdefit_y values
[0075]
[0076]
[0077] Wherein, n represents the number of APs, n APs, and in the embodiment of the present disclosure, n is an integer greater than or equal to 3;
[0078] The x_result is the set of abscissas kdefit_x of the peak points of the fitting function of all APs.
[0079] In some exemplary embodiments, the kde.fit fitting includes:
[0080] The kde.fit function (function) in the Python third-party function library statamodels is used. This function is the main method for data fitting and obtains the KDE approximate fitting curve of the data set distribution. The example is as follows:
[0081] statsmodels.nonparametric.api.KDEUnivariate(Data).fit(self, kernel="gau", bw="scott", fft=True, weights=None, gridsize=None, adjust=1, cut=3, clip=(-np.inf, np.inf));
[0082] where Data refers to the dataset of measured distances collected by an AP at a sampling point (STA) in this article, that is, the above dis_data[i]. The dataset Data (dis_data[i]) includes the AP i The STA is measured m times to obtain m measurement results, each recorded as Data[j] (dis_data[i][j]), where 0 < j <= m and m is an integer greater than 0. The measurement results at least include the measured distance.
[0083] Among them, gau represents the Gaussian kernel function. In some exemplary embodiments, the kernel functions that can be cited also include: {'cos' | 'biw' | 'epa' | 'tri' | 'triw'}; when the bandwidth is the optimal choice, the kernel density estimation is not sensitive to the choice of the kernel function, and similar technical effects can be achieved by using other kernel functions.
[0084] In some exemplary embodiments, step 3 includes: by using the ranging data in the line-of-sight (LOS) environment, linearly fitting to correct / modify the measured distance when the distance from the AP to the STA is too close.
[0085] Previous studies and experiments have shown that even for a specific combination of AP and STA, there are different offsets when operating in different environments (such as the internal environment of the space, channel state, etc.), so it is necessary to calibrate the specific combination of AP and STA. In some exemplary embodiments, when the actual distance between the STA and the AP is within 10m, the measured distance is generally less than the actual distance, and when the distance is very close (for example, the STA and the AP are only 1m apart), the measured distance may even be negative. This is caused by the offset correction algorithm built into the FTM measurement firmware. Therefore, in order to avoid the measured result being too small or negative due to the distance being too close, when the measured distance data is less than 10m, it can be considered that there is a LOS environment between the STA and the AP. At the same time, the flight time is linearly related to the distance, and there is a certain fixed correction relationship caused by the firmware between the measured distance and the actual distance, which allows the ranging error to be almost independent of the distance. Therefore, it is necessary to fit the linear relationship between the actual distance and the measured distance through the historical measurement data obtained in the LOS environment and apply it to the actual positioning scenario.
[0086] In some exemplary embodiments, the 10 meters is an optional first distance threshold; the first distance threshold can be determined according to different LOS environments and is not limited to the 10 meters cited. When the distance from the AP to the STA is less than the first distance threshold, step 3 is executed to perform measurement distance correction (correction).
[0087] In some exemplary embodiments, step 5 includes: performing rough positioning using a linear least squares algorithm that constructs a normal equation based on adjacent APs as subtracted terms. The rough positioning coordinates are used as the iterative initial point coordinates of the subsequent positioning algorithm, and a better solution is found near the initial point to prevent the algorithm from falling into a local optimum during the iteration process.
[0088] For the naive linear least squares method (LLS), based on the single-target network positioning model, the following equation group (1) is established, which is recorded as the site positioning error equation group:
[0089]
[0090] Where n represents n APs, (x, y) is the position coordinates of the STA to be found, and AP i is the ith AP, AP i The position coordinates are (x i ,y i ), AP i The measured distance to STA is d i Since there is a deviation between the measured distance of the AP and the true distance, the equation system will have no solution. Therefore, it is necessary to fit the equation system by the least squares method to obtain the corresponding normal equation in order to obtain a similar solution close to the true solution. The normal equation form of the final solution is shown in (2):
[0091]
[0092] The coordinate matrix to be determined is have:
[0093]
[0094] In actual application, the equation group (1) is listed according to the number of APs, and then the AP position coordinates, measurement distance and other information are substituted into the A and B matrices, and the measurement coordinates of the unknown points can be obtained through the normal equations.
[0095] Since in the naive linear least squares method, the construction of the linear equation group requires selecting one of the equations in the equation group (1) as the subtracted term, the nth equation is generally selected, as shown in A and B above, and the nth equation in the equation group (1) is used as the subtracted term to construct the normal equation (2). In fact, in the spatial positioning scenario, any equation in the equation group can be selected to obtain a linear equation group by subtracting other equations, but when the number of anchor nodes (AP) is greater than 3, the error of the position estimation value is greatly affected by the selection of the equation group. At this time, the farther the point to be positioned (STA) is from the anchor node (AP), the lower the positioning accuracy. Therefore, in theory, the AP with the smallest measurement distance should be selected as the subtracted AP to improve the positioning accuracy of the linear least squares method.
[0096] In some exemplary embodiments, step 5 includes: firstly constructing an AP state matrix using known AP position information and ranging information obtained by linear fitting through kernel density estimation, where each row of the matrix represents an AP i Status information, including (x i ,y i ,d i ), respectively represent AP i The position (x i ,y i ) and ranging information d i , select the distance measurement result d i The smallest AP is used as the subtracted term, and the A and B matrices of the normal equation are constructed using the linear least squares method. Finally, the rough positioning coordinates of the STA can be obtained through the normal equation. Among them, the AP position information includes: the plane or spatial coordinates of the AP; the constructed A and B matrices are consistent with the matrices A and B shown in (2) in form, but the subtracted terms are different. The matrices A and B in (2) above are examples of the nth term being the subtracted term.
[0097] In the FTM single-target network positioning model, the minimum error square sum function is used as the optimization target of the positioning iteration algorithm in the embodiment of the present disclosure, because the measured distance from each AP to the STA obtained through the FTM basically has a certain error. In theory, when f(x, y) is smaller, it indicates that the distance from the predicted position to each AP is closer to the measured distance:
[0098]
[0099] Where n represents n APs, (x i ,y i ) indicates AP i The position coordinates, d i Indicates AP iThe measured distance to the STA to be measured, the parameters x and y represent the position coordinates of the point to be measured, then the goal of the Bayesian algorithm is to iteratively find the parameter x and y values when the function f(x, y) takes the minimum value.
[0100] According to the principle of least squares, when the square is taken, the estimate of the parameter is the maximum likelihood estimate under the current sample. Define sample d i , the prediction for the sample is This notation indicates that the prediction depends on the selection of the parameter θ. It is easy to know that in the spatial positioning scenario, θ is the position coordinate to be optimized, d i Indicates AP i The measured distance, represents the Euclidean distance calculated under the predicted coordinates, then:
[0101]
[0102] Where ε is the error function, which is usually assumed to satisfy the normal distribution:
[0103] ε i ~N(0,σ i 2 )
[0104] Then we have:
[0105]
[0106]
[0107] The maximum likelihood estimate of θ is required, that is, when d i The probability of occurrence is the highest under different values of θ.
[0108]
[0109] Simplify the calculation, let:
[0110]
[0111] Due to σ i Does not change with θ, but only with AP i The measured distance data is related to the measured distance data, so let the first two terms of l(θ) be constant C. To maximize L(θ), we can maximize l(θ), so Take the minimum value. i The estimated value std i , denoted as AP i The standard deviation of the distance result set after m measurements at a sampling point. In general, the standard deviation of each sample can be defined as:
[0112]
[0113] std i Indicates AP i The standard deviation of the measurement results.
[0114] Where x represents the sample measurement mean. In the spatial positioning scenario, the sample standard deviation represents the unbiased standard deviation obtained after m FTM measurements at a sampling point.
[0115] According to the above inference, in some exemplary embodiments, step 6 includes:
[0116] Further optimize the objective function (3) to determine the AP measurement weight objective function, as follows:
[0117]
[0118] When using variance as the denominator, it can be known that the greater the fluctuation of the measurement data, the greater the variance, which means that the multipath effect of the measurement environment where the AP is located may have a greater impact. In this case, it is necessary to reduce the "contribution" of the AP in the ranging process, that is, to reduce the result weight of the AP in the iterative objective function process.
[0119] In some exemplary embodiments, step 7 includes:
[0120] Taking the rough positioning result determined in step 5 as the initial point, adopting the Bayesian algorithm as the first optimization algorithm, and iteratively executing the determined AP measurement weight objective function (5) according to the set iteration range, iteration number, and iteration threshold, the optimal solution of the AP measurement weight objective function (5) is determined, and the optimal solution is the final positioning result of the STA.
[0121] In some exemplary embodiments, the iteration range is within the vicinity of the rough positioning point, such as within 10 meters; or, other ranges are determined according to the application environment, and are not limited to this example.
[0122] In some exemplary embodiments, the APs in step 1 include at least 4 APs.
[0123] Embodiment 2
[0124] The present disclosure also provides a spatial positioning system, the structure of which is as follows: Figure 3 As shown, it includes: an FTM ranging module 301, a KDE kernel density estimation module 302, a linear fitting correction module 303, an LLS coarse positioning module 304 based on a close AP strategy, an objective function module 305 based on maximum likelihood estimation, and a Bayesian optimization module 306.
[0125] The FTM ranging module 301 is used to collect the original FTM measurement data set from the AP to the STA.
[0126] In some exemplary embodiments, the FTM ranging module 301 performs the steps in step 1 in embodiment 1 to obtain (collect) the original FTM measurement data set from the AP to the station STA. The detailed steps are consistent with the embodiment, and the same aspects are not repeated here.
[0127] The KDE kernel density estimation module 302 is used to obtain the original FTM measurement data set of the FTM ranging module 301, and then use the KDE kernel density estimation method to determine the measurement distance from each AP to the STA.
[0128] In some exemplary embodiments, the KDE kernel density estimation module 302 performs the steps in step 2 in embodiment 1, and the detailed steps are consistent with the embodiment, and the same aspects are not repeated here.
[0129] Among them, the linear fitting correction module 303 is used to correct (correct) the measured distance from AP to STA when the distance is too close by linear fitting by utilizing the ranging data in the LOS environment; that is, when the measured distance from an AP to a STA is less than a first distance threshold, the measured distance is corrected (corrected) by linear fitting to obtain the corrected (corrected) measured distance.
[0130] In some exemplary embodiments, the linear fitting correction module 303 performs the steps in step 4 in the first embodiment, and the detailed steps are consistent with the embodiment, and the same aspects are not repeated here.
[0131] The LLS coarse positioning module 304 based on the close-in AP strategy is used to perform coarse positioning by using a linear least squares algorithm to construct a normal equation based on close-in APs as subtracted terms.
[0132] In some exemplary embodiments, the LLS coarse positioning module 304 based on the close-proximity AP strategy executes the steps in step 5 in the first embodiment, and the detailed steps are consistent with the embodiment, and the same aspects are not repeated here.
[0133] In some exemplary embodiments, the workflow of the LLS coarse positioning module 304 based on the close proximity AP strategy is as follows: Figure 4 As shown, including:
[0134] 401, inputting a state matrix T of an AP; wherein the state matrix includes: location information of each AP and a measured distance between each AP and a STA;
[0135] 402, extracting measurement results of all APs from the state matrix T to determine a ranging result vector;
[0136] 403, determining the nearest AP from the ranging result vector;
[0137] 404, constructing a normal equation by taking the equation term where the nearest AP is located as the subtracted term;
[0138] 405, solving the normal equations to obtain a rough positioning result of the STA.
[0139] The AP location information includes: the plane or space coordinates of the AP.
[0140] In some exemplary embodiments, step 404 includes:
[0141] Based on the single-target network positioning model, the site positioning error equation group (1) is established;
[0142] The equation term (equation) in the station positioning error equation group (1) of the nearest AP is used as the subtracted term, and the normal equation is constructed using the linear least squares method.
[0143] Among them, the objective function module 305 based on maximum likelihood estimation is used to optimize the minimum error square sum function; that is, the minimum error square sum function is used as the objective function to be optimized, and based on the maximum likelihood estimation method, the objective function is optimized to obtain the AP measurement weight objective function.
[0144] In some exemplary embodiments, the objective function module 305 based on maximum likelihood estimation performs the steps in step 6 in the first embodiment, and the detailed steps are consistent with the embodiment, and the same aspects are not repeated here.
[0145] In some exemplary embodiments, the AP measurement weight objective function obtained after optimization is shown in (5). It can be seen that when the variance is used as the denominator, it can be known that the larger the fluctuation of the measurement data, the larger the variance, which means that the multipath effect of the measurement environment where the AP is located may have a greater impact, and it is necessary to reduce the "contribution" of the AP in the ranging process, that is, to reduce the result weight of the AP in the iterative objective function process.
[0146] Among them, the Bayesian optimization module 306 is used to solve the AP measurement weight objective function and determine the positioning result; use the Bayesian algorithm (the preset first optimization algorithm) and the rough positioning result as the iteration initial value to determine the optimal solution of the AP measurement weight objective function; determine the positioning result of the STA based on the optimal solution.
[0147] In some exemplary embodiments, the Bayesian optimization module 306 performs the steps in step 7 in the first embodiment. The detailed steps are consistent with the embodiment, and the same aspects are not repeated here.
[0148] In some exemplary embodiments, in order to improve the scalability of the disclosed solution, the iterative algorithm interface module 307 may be used to replace the Bayesian optimization module 306, so that when a better algorithm appears in the future, there is no need to stick to the Bayesian algorithm.
[0149] The iterative algorithm interface module 307 is used to determine the optimal solution of the AP measurement weight objective function according to a preset first optimization algorithm, using the coarse positioning result as an iteration initial value.
[0150] In some exemplary embodiments, the iterative algorithm interface module 307 is configured to use the coarse positioning result determined by the LLS coarse positioning module 304 based on the adjacent AP strategy as the iteration starting point, and iteratively execute the AP measurement weight objective function according to the preset first optimization algorithm and the set iteration range, number of iterations and iteration threshold to obtain the optimal solution, which is the final positioning result.
[0151] In some exemplary embodiments, the spatial positioning system is deployed on a station STA; or on other terminals that can obtain measurement results of each AP, such as a mobile phone, a laptop computer, etc.
[0152] It can be seen that the FTM single-target positioning system is implemented by using mainstream general-purpose AP equipment and open source platform tools with a cost of only a few hundred yuan, ensuring the low cost and good popularity of the system; a new single-target network space positioning solution is designed to ensure that the system can achieve a high meter-level positioning accuracy in space scenarios.
[0153] The spatial positioning scheme involved in the present invention firstly uses the kernel density estimation method to pre-process the data set collected by the FTM ranging module, outputs the measured distance from each AP to the STA, and then linearly fits the data whose AP ranging results in the space are less than the first distance threshold (for example, 10m), substitutes the corrected ranging results into the linear least square method based on the adjacent AP strategy, and uses the output as the coarse positioning point input of the positioning algorithm, then designs the objective function based on the maximum likelihood estimation, assigns the AP ranging variance weight to examine the "contribution" of the AP according to the fluctuation range of the ranging results, and finally uses the Bayesian algorithm to iteratively optimize the objective function to obtain the final predicted position.
[0154] The gain effects of each submodule method in the solution provided by the present disclosure are as follows:
[0155] 1. Using the kernel density estimation module, the FTM ranging result data set can be cleaned and optimized;
[0156] 2. The linear fitting correction module can be used to perform adaptive correction fitting on the FTM ranging results in different environments;
[0157] 3. The system rough positioning result can be obtained by using the linear least squares module based on the adjacent AP strategy;
[0158] 4. Using the objective function module based on maximum likelihood estimation, we designed an objective function optimization method for maximum likelihood estimation. We examined the ranging reliability of each AP through the standard deviation weight and weakened the contribution of APs with large fluctuations in ranging results during the algorithm iteration process.
[0159] 5. Using the Bayesian optimization module, you can continue to iterate near the rough positioning point to find the global optimal solution as the final positioning result.
[0160] Embodiment 3
[0161] The present disclosure also provides a method for positioning in space, the process of which is as follows: Figure 6 As shown, including,
[0162] Step 601, respectively obtain the measured distances from at least three wireless access points AP to the site;
[0163] Step 602, according to the measured distance, based on a single target network positioning model, a linear least square method is used to perform coarse positioning to determine a coarse positioning result of the site;
[0164] Step 603, determining the AP measurement weight objective function based on maximum likelihood estimation;
[0165] Step 604, using the rough positioning result as an iteration initial value, iterating the AP measurement weight objective function according to a preset first optimization algorithm to determine an optimal solution of the AP measurement weight objective function; and determining the positioning result of the site according to the optimal solution.
[0166] In some exemplary embodiments, obtaining the measured distances from at least three wireless access points AP to the station in step 601 includes:
[0167] According to the precise time measurement FTM function, respectively obtain original FTM measurement data sets from each of the at least three APs to the site;
[0168] According to the original FTM measurement data set, a kernel density estimation method is used to determine the measurement distance from each AP to the site.
[0169] In some exemplary embodiments, further implementation details of step 601 are consistent with relevant details of step 1 and / or 2 in embodiment 1, and the repeated parts are not repeated here.
[0170] In some exemplary embodiments, before performing coarse positioning according to the measured distance and based on a single target network positioning model by using a linear least squares method to determine the coarse positioning result of the site in step 602, the method further includes:
[0171] Step 610, respectively determine whether each measured distance is less than a preset first distance threshold. If so, execute step 611 to perform linear fitting on the measured distance to correct the measured distance; if greater than or equal to, execute step 602.
[0172] In some exemplary embodiments, the step 602 of performing coarse positioning based on the measured distance and a single target network positioning model using a linear least squares method to determine a coarse positioning result of the site includes:
[0173] According to the location information of the at least three APs and the measured distance, based on the single target network positioning model, a site positioning error equation group is established;
[0174] The linear least square method is used to fit the station positioning error equation group and construct a normal equation;
[0175] The normal equation is solved to obtain a rough positioning result of the site.
[0176] In some exemplary embodiments, when the number of APs is greater than 3, the linear least square method is used to fit the site positioning error equation group to construct a normal equation, including:
[0177] Select an AP with the shortest measurement distance from the APs and record it as the nearest AP;
[0178] The equation corresponding to the nearest AP in the site positioning error equation group is used as a subtracted term, and the site positioning error equation group is fitted using a linear least squares method to construct the normal equation.
[0179] In some exemplary embodiments, further implementation details of step 602 are consistent with the relevant details of step 5 in embodiment 1, and the repeated parts are not repeated here.
[0180] In some exemplary embodiments, the constructed normal equation is in the form of (2), where the subtracted term is the equation corresponding to the nearest AP.
[0181] In some exemplary embodiments, determining the AP measurement weight objective function based on maximum likelihood estimation in step 603 includes:
[0182] Based on maximum likelihood estimation, the distance measurement variance of each AP is used as a weight to optimize the minimum error square sum function to obtain the AP measurement weight objective function.
[0183] In some exemplary embodiments, further implementation details of step 603 are consistent with the relevant details of step 6 in embodiment 1, and the repeated parts are not repeated here.
[0184] In some exemplary embodiments, the ranging variance of each AP is calculated according to the above formula (4); the minimum error square sum function is the function defined in the above formula (3); and the AP measurement weight objective function obtained after optimization is the function defined in the above formula (5).
[0185] In some exemplary embodiments, the first optimization algorithm includes: a Bayesian algorithm.
[0186] In some exemplary embodiments, the first distance threshold is a threshold determined according to a line-of-sight environment from the AP to the site in a space.
[0187] In some exemplary embodiments, the first distance threshold is 10 meters.
[0188] In some exemplary embodiments, the single-target network positioning model is a FTM single-target network positioning model.
[0189] In some exemplary embodiments, in step 601, the measured distances from at least four wireless access points AP to the station are respectively obtained.
[0190] Embodiment 4
[0191] The embodiment of the present disclosure also provides a spatial positioning device 70, the structure of which is as follows: Figure 7 As shown, including:
[0192] The distance measurement module 701 is configured to respectively obtain the measured distances from at least three wireless access points AP to the station;
[0193] The coarse positioning module 702 is configured to perform coarse positioning using a linear least squares method based on the measured distance and a single target network positioning model to determine a coarse positioning result of the site;
[0194] The measurement weight objective function determination module 703 is configured to determine the AP measurement weight objective function based on maximum likelihood estimation;
[0195] The precise positioning module 704 is configured to use the rough positioning result as an iteration initial value, iterate the AP measurement weight objective function according to a preset first optimization algorithm, and determine the optimal solution of the AP measurement weight objective function; and determine the positioning result of the site according to the optimal solution.
[0196] In some exemplary embodiments, the distance measurement module 701 respectively obtains the measured distances from at least three wireless access points AP to the station, including:
[0197] According to the precise time measurement FTM function, respectively obtain original FTM measurement data sets from each of the at least three APs to the site;
[0198] According to the original FTM measurement data set, a kernel density estimation method is used to determine the measurement distance from each AP to the site.
[0199] In some exemplary embodiments, the apparatus further includes a correction module 705;
[0200] Before the coarse positioning module 702 determines the coarse positioning result of the site, the correction module 705 is configured to respectively determine whether each measured distance is less than a preset first distance threshold, and if so, perform linear fitting on the measured distance to correct the measured distance.
[0201] In some exemplary embodiments, the coarse positioning module 702 performs coarse positioning based on the measured distance and a single target network positioning model using a linear least squares method to determine a coarse positioning result of the site, including:
[0202] According to the location information of the at least three APs and the measured distance, based on the single target network positioning model, a site positioning error equation group is established;
[0203] The linear least square method is used to fit the station positioning error equation group and construct a normal equation;
[0204] The normal equation is solved to obtain a rough positioning result of the site.
[0205] In some exemplary embodiments, when the number of APs is greater than 3, the coarse positioning module 702 uses a linear least squares method to fit the site positioning error equation group to construct a normal equation, including:
[0206] Select an AP with the shortest measurement distance from the APs and record it as the nearest AP;
[0207] The equation corresponding to the nearest AP in the site positioning error equation group is used as a subtracted term, and the site positioning error equation group is fitted using a linear least squares method to construct the normal equation.
[0208] In some exemplary embodiments, the measurement weight objective function determination module 703 determines the AP measurement weight objective function based on maximum likelihood estimation, including:
[0209] Based on maximum likelihood estimation, the distance measurement variance of each AP is used as a weight to optimize the minimum error square sum function to obtain the AP measurement weight objective function.
[0210] In some exemplary embodiments, the first optimization algorithm includes: a Bayesian algorithm.
[0211] In some exemplary embodiments, the first distance threshold is a threshold determined according to a line-of-sight environment from the AP to the site in a space.
[0212] An embodiment of the present disclosure also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program for performing intra-space positioning, and the processor is configured to read and run the computer program for performing intra-space positioning to execute any of the above-described intra-space positioning methods.
[0213] An embodiment of the present disclosure further provides a storage medium, in which a computer program is stored, wherein the computer program is configured to execute any of the above-mentioned methods for positioning within a space when running.
[0214] The positioning solution provided by the present disclosure can be implemented on all terminal devices or ranging systems of APs that support FTM measurement. Applicable indoor scenarios may include underground parking lots, large shopping malls, office buildings, libraries, airport halls, etc. It can also be applied to other fixed or mobile spaces.
[0215] It will be appreciated by those skilled in the art that all or some of the steps, systems, and functional modules / units in the methods disclosed above may be implemented as software, firmware, hardware, and appropriate combinations thereof. In hardware implementations, the division between the functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, a physical component may have multiple functions, or a function or step may be performed by several physical components in cooperation. Some or all components may be implemented as software executed by a processor, such as a digital signal processor or a microprocessor, or implemented as hardware, or implemented as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or non-transitory medium) and a communication medium (or temporary medium). As known to those skilled in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to store the desired information and can be accessed by a computer. In addition, it is well known to those of ordinary skill in the art that communication media typically contain computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.
Claims
1. A method for positioning in space, It is characterized in that include, Obtain the measured distances from at least three wireless access points (APs) to the site respectively; According to the measured distance, based on a single target network positioning model, a linear least square method is used to perform coarse positioning to determine a coarse positioning result of the site; Based on maximum likelihood estimation, determine the AP measurement weight objective function; Taking the rough positioning result as an iteration initial value, iterating the AP measurement weight objective function according to a preset first optimization algorithm to determine an optimal solution of the AP measurement weight objective function; Determining a positioning result of the site according to the optimal solution; The step of respectively obtaining the measured distances from at least three wireless access points AP to the site includes: According to the precise time measurement FTM function, respectively obtain original FTM measurement data sets from each of the at least three APs to the site; According to the original FTM measurement data set, a kernel density estimation method is used to determine the measurement distance from each AP to the site.
2. The method according to claim 1, It is characterized in that Before determining the rough positioning result of the site by using a linear least squares method to perform rough positioning according to the measured distance and based on a single target network positioning model, the method further includes: It is determined whether each measured distance is less than a preset first distance threshold. If so, a linear fit is performed on the measured distance to correct the measured distance.
3. The method according to claim 2, It is characterized in that The method of performing rough positioning according to the measured distance and based on a single target network positioning model by using a linear least squares method to determine a rough positioning result of the site includes: According to the location information of the at least three APs and the measured distance, based on the single target network positioning model, a site positioning error equation group is established; The linear least square method is used to fit the station positioning error equation group and construct a normal equation; The normal equation is solved to obtain a rough positioning result of the site.
4. The method according to claim 3, It is characterized in that When the number of APs is greater than 3, the linear least square method is used to fit the site positioning error equation group to construct a normal equation, including: Select an AP with the shortest measurement distance from the APs and record it as the nearest AP; The equation corresponding to the nearest AP in the site positioning error equation group is used as a subtracted term, and the site positioning error equation group is fitted using a linear least squares method to construct the normal equation.
5. The method according to claim 1, It is characterized in that The determining of the AP measurement weight objective function based on maximum likelihood estimation includes: Based on maximum likelihood estimation, the distance measurement variance of each AP is used as a weight to optimize the minimum error square sum function to obtain the AP measurement weight objective function.
6. The method according to claim 1 or 5, It is characterized in that The first optimization algorithm includes: a Bayesian algorithm.
7. The method according to claim 2, It is characterized in that The first distance threshold is a threshold determined according to a line of sight environment from the AP to the site in a space.
8. An electronic device comprising a memory and a processor, It is characterized in that The memory stores a computer program for performing in-space positioning, and the processor is configured to read and run the computer program for performing in-space positioning to execute the method described in any one of claims 1 to 7.
9. A storage medium, It is characterized in that The storage medium stores a computer program, wherein the computer program is configured to execute the method according to any one of claims 1 to 7 when executed.
Citation Information
Patent Citations
Indoor positioning method based on weighted surface fitting of crowd-source samples
CN109059919A
