A method for MR fingerprint localization based on dynamic WKNN.
By expanding the neighbor set in the signal domain and shrinking the set in the spatial domain using the dynamic WKNN method, and combining it with exponential weighted fusion, the positioning error and robustness problems of the WKNN method in complex environments are solved, achieving high-precision and stable positioning results.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- CHONGQING UNIV OF POSTS & TELECOMM
- Filing Date
- 2026-05-11
- Publication Date
- 2026-07-31
AI Technical Summary
Existing weighted k-nearest neighbor (WKNN) methods based on a fixed number of neighbors K suffer from large localization errors and low robustness in complex environments. They cannot adapt to environmental changes and also suffer from uneven signal matching, sparsity, and outlier interference.
The dynamic WKNN method is adopted, which expands the neighbor set in the signal domain according to the matching quality, shrinks the set in the spatial domain according to the consistency, and performs exponential weighted fusion to dynamically determine the number of neighbors K, so as to adapt to environmental changes, reduce positioning errors and enhance robustness.
It significantly improves positioning accuracy and robustness, reduces the probability of false matches, provides indicators reflecting the uncertainty of positioning estimation, and supports upper-layer systems in making fusion decisions and detecting anomalies.
Smart Images

Figure CN122496780A_ABST
Abstract
Description
[0001] This invention relates to the field of wireless communication positioning technology, and in particular to a fingerprint positioning method based on cellular network measurement report (MR) data and employing a dynamic weighted K-nearest neighbor algorithm. Background Technology
[0002] With the widespread adoption of mobile communication networks (such as LTE and NR) and the increasing demand for location services in complex urban environments, utilizing network-side measurement reports or drive-test fingerprints for positioning has significant engineering value due to its ability to reuse existing communication infrastructure and eliminate the need for additional sensors on the terminal. The general approach to fingerprint positioning is as follows: first, an offline fingerprint database is established, mapping each geographical unit (e.g., grid) to its corresponding wireless signal characteristics; then, during the positioning phase, the real-time measured signal characteristics are matched against the fingerprints in the database to output a location estimate.
[0003] However, existing weighted k-nearest neighbor (WKNN) methods based on a fixed number of neighbors K often suffer from the following contradictions in engineering applications: On the one hand, signal propagation is highly time-varying due to multipath propagation, obstruction, antenna directivity, and network load, and the signal fingerprint at the same location will drift with time, terminal model, and network status; on the other hand, fingerprint data naturally has unevenness and sparsity, with some grid samples being insufficient or not updated for a long time. Fixed k may introduce candidate points that are far away but have similar costs in dense sample areas, while it may not be able to form a stable location estimate in sparse sample areas; in addition, outliers often appear in the candidate set, and fixed k tends to include these samples, which leads to an increase in positioning error.
[0004] In summary, this invention proposes a dynamic weighted K-nearest neighbor (KNN)-based MR fingerprint localization method. The core of this method lies in constructing a dynamic K-value determination mechanism. First, a candidate set is initially screened in the signal domain based on matching quality. Then, the set is shrunk in the spatial domain based on distribution consistency. Finally, exponential weighted fusion is performed. This method aims to systematically solve the engineering problems of existing fixed K-value methods, which cannot adapt to environmental changes and struggle to balance signal matching and spatial consistency, leading to increased localization errors and reduced robustness. Summary of the Invention
[0005] This invention proposes a dynamic WKNN-based MR fingerprint localization method. The core mechanism of this method is to first expand the neighbor set in the signal domain according to matching quality, then shrink the neighbor set in the spatial domain according to consistency, and finally perform exponential weighted fusion based on relative cost. This ensures that the number of neighbors K is no longer a fixed constant, but rather adapts to the matching quality and spatial distribution of each localization attempt, thus adapting to environmental changes, reducing localization errors, and enhancing the robustness of the algorithm.
[0006] The MR fingerprint localization method based on dynamic WKNN described in this invention specifically includes the following steps:
[0007] Step 1: Divide the area to be located into several grids, and create a fingerprint record for each grid containing latitude and longitude coordinates and signal feature vectors to form a fingerprint database.
[0008] Specifically, the area to be located is discretized according to a preset grid scale, resulting in several grid cells and each grid cell. Corresponding center latitude and longitude Establish a fingerprint record for each grid. It contains a location field. and the signal feature vector corresponding to the MR field in the network measurement report. .
[0009] The signal feature vector The serving cell feature vector and the neighboring cell feature vector are respectively composed of serving cell information and neighboring cell information:
[0010] (1) Serving cell feature vector: represents the identifier and measurement value of the serving cell that the terminal is actually connected to at the grid location, including at least the serving cell identifier (base station ID, cell ID) and the reference signal received power (RSRP) and timing advance (TA) of the serving cell.
[0011] (2) Neighboring cell feature vector: represents the identifiers of several neighboring cells that the terminal can measure at this grid location and their RSRP measurement values. TA is replaced by -1 to represent the neighboring cell.
[0012] For multiple historical samples in the same grid, different fingerprint vectors are formed by statistically summarizing samples from different cells during the fingerprint database construction stage. The mean value of RSRP of the same cell is taken as the representative value, and the sample number and variance are recorded as confidence information. Abnormal samples are removed to obtain more stable grid fingerprints.
[0013] Step 2: Receive the MR reported by the terminal to be located, and extract the target signal feature vector from the measurement report.
[0014] Specifically, a single location request corresponds to one or several MR records reported by the terminal within a time window. Each MR record contains serving cell observation data and neighboring cell observation data: the serving cell includes the serving cell identifier, the serving cell RSRP measurement value, and the TA measurement value; the neighboring cells include multiple neighboring cell identifiers and their respective RSRP measurement values. The observed cells in the MR are then organized into a cell set. And constitute the target feature vector. .
[0015] Step 3: Calculate the cost value between the target signal feature and the fingerprint features of each grid in the fingerprint database, and generate a candidate grid sequence set in ascending order of cost value.
[0016] Specifically, to improve positioning speed, a portion of the grids is initially selected based on the cell identifiers of the MR to be located, and then each of these grids is... Calculate its relationship with the target feature vector The value between and apply the following to all grids: Sort the candidate sequences in ascending order to form a set of candidate sequences. And let the cost of the first item after sorting be the base cost. .
[0017] Within a single location request, for each observation cell in MR Calculate its relationship to the grid separately Local value And sum to get ,Right now , Smaller indicates a smaller grid size. The higher the match with the current MR.
[0018] Among them, observation cell This includes: RSRP observations for the serving cell and RSRP observations for several neighboring cells. For RSRP observations, if a grid exists in the fingerprint database... The RSRP value of the fingerprint on the corresponding cell identifier Then let As a measure of difference: when This indicates that the description of the cell's signal characteristics by the grid is largely consistent with the current MR. ,in Empirically, a value of 3dB to 5dB can be used. Otherwise, it indicates that the fingerprint signal of the cell in that grid differs too much from the current MR (the causes may include noise interference, multipath propagation, signal time-varying characteristics, and fingerprint drift). To avoid mismatches in a few abnormal dimensions, a penalty is imposed on the observation, adding a significant cost to the grid and thus reducing its probability of entering the candidate set. As a penalty contribution; if the corresponding fingerprint value does not exist in the fingerprint database, then the contribution is also taken. As a penalty for absence.
[0019] Step 4: Based on the candidate grid sequence set, perform K-value expansion in the signal domain and K-value contraction in the spatial domain to adaptively determine the candidate grid set for weighted estimation, calculate the weight of the set according to the relative cost value, and perform weighted summation of the latitude and longitude of the candidate grids to obtain the estimated position.
[0020] Specifically, step four includes three sub-processes: signal domain expansion, spatial domain contraction, and weighted fusion.
[0021] First, determine the initial number of candidate grids in the signal domain. Set signal difference threshold With the maximum number of candidate grids Calculate the upper limit of the allowed cost And use this upper limit value to filter candidate grids:
[0022]
[0023] Scan sequentially from the second-best candidate sequence, including those that satisfy... And serial number The candidate grids are used to obtain the initial candidate grid set. and The purpose of this process is to adaptively introduce more candidate grids with values close to the optimal value when the overall signal matching quality is good, and to automatically limit the size of the candidate grids when the matching quality is insufficient.
[0024] Subsequently, in the spatial domain Perform uniform shrinkage: for Computational geometric center And calculate the Haversine distance from the center of each candidate grid to the geometric center. (Unit: meters), from which the average spatial dispersion is obtained:
[0025]
[0026] Set spatial consistency threshold ,when If candidate grids are deemed too dispersed in the spatial domain and may contain outliers, then candidate grids are eliminated according to a strategy of decreasing computational value. Furthermore, the geometric center is repeatedly calculated and until Or, only one candidate grid remains, resulting in the final candidate grid set. With the number of candidate grids .
[0027] Finally, perform weighted fusion positioning: for Each candidate grid Calculate relative cost And calculate the unnormalized weights accordingly. The formula is ,in Weighting adjustment factor and , Normalization yields The estimated location is obtained by weighting the latitude and longitude coordinates with normalized weights and then summing the results.
[0028]
[0029]
[0030] Beneficial effects
[0031] Compared with existing fixed-K WKNN localization methods, this invention has the following advantages: First, this method dynamically determines the candidate grid set in each localization request. When the matching quality is good and candidate points are spatially clustered, it can introduce more high-quality reference grids to improve the stability of localization estimation. Conversely, when candidate points are discretely distributed or exhibit obvious anomalies, it automatically shrinks the candidate set to reduce interference, thereby significantly improving localization accuracy and robustness. Second, this method constructs a dual screening mechanism by introducing a threshold constraint based on baseline cost in the signal domain and a consistency constraint based on average dispersion in the spatial domain. This effectively reduces the probability of false matches that may result from relying solely on signal similarity. Finally, this method uses exponential weights based on relative cost values for fusion, which naturally highlights the contribution of high-confidence candidate points and suppresses the influence of low-confidence candidate points. Furthermore, this weight structure facilitates the derivation of indices reflecting the uncertainty of the current localization estimation, supporting upper-level systems in fusion decision-making or anomaly detection. Attached Figure Description
[0032] Figure 1 This is the algorithm flowchart. Detailed Implementation Plan
[0033] This invention proposes a dynamic WKNN-based MR fingerprint localization method. The core mechanism of this method is to first expand the neighbor set in the signal domain according to matching quality, then shrink the neighbor set in the spatial domain according to consistency, and finally perform exponential weighted fusion based on relative cost. This ensures that the number of neighbors K is no longer a fixed constant, but rather adapts to the matching quality and spatial distribution of each localization attempt, thus adapting to environmental changes, reducing localization errors, and enhancing the robustness of the algorithm.
[0034] The MR fingerprint localization method based on dynamic WKNN described in this invention specifically includes the following steps:
[0035] Step 1: Divide the area to be located into several grids, and create a fingerprint record for each grid containing latitude and longitude coordinates and signal feature vectors to form a fingerprint database.
[0036] Specifically, the area to be located is discretized according to a preset grid scale, resulting in several grid cells and each grid cell. Corresponding center latitude and longitude Establish a fingerprint record for each grid. It contains a location field. and the signal feature vector corresponding to the MR field in the network measurement report. .
[0037] The signal feature vector The serving cell feature vector and the neighboring cell feature vector are respectively composed of serving cell information and neighboring cell information:
[0038] (1) Serving cell feature vector: represents the identifier and measurement value of the serving cell that the terminal is actually connected to at the grid location, including at least the serving cell identifier (base station ID, cell ID) and the serving cell's RSRP and TA;
[0039] (2) Neighboring cell feature vector: represents the identifiers of several neighboring cells that the terminal can measure at this grid location and their RSRP measurement values. TA is replaced by -1 to represent the neighboring cell.
[0040] For multiple historical samples in the same grid, different fingerprint vectors are formed by statistically summarizing samples from different cells during the fingerprint database construction stage. The mean value of RSRP of the same cell is taken as the representative value, and the sample number and variance are recorded as confidence information. Abnormal samples are removed to obtain more stable grid fingerprints.
[0041] Step 2: Receive the MR reported by the terminal to be located, and extract the target signal feature vector from the measurement report.
[0042] Specifically, a single location request corresponds to one or several MR records reported by the terminal within a time window. Each MR record contains serving cell observation data and neighboring cell observation data: the serving cell includes the serving cell identifier, the serving cell RSRP measurement value, and the TA measurement value; the neighboring cells include multiple neighboring cell identifiers and their respective RSRP measurement values. The observed cells in the MR are then organized into a cell set. And constitute the target feature vector. .
[0043] Step 3: Calculate the cost value between the target signal feature and the fingerprint features of each grid in the fingerprint database, and generate a candidate grid sequence set in ascending order of cost value.
[0044] Specifically, to improve positioning speed, a portion of the grids is initially selected based on the cell identifiers of the MR to be located, and then each of these grids is... Calculate its relationship with the target feature vector The value between and apply the following to all grids: Sort the candidate sequences in ascending order to form a set of candidate sequences. And let the cost of the first item after sorting be the base cost. .
[0045] Within a single location request, for each observation cell in MR Calculate its relationship to the grid separately Local value And sum to get ,Right now , Smaller indicates a smaller grid size. The higher the match with the current MR.
[0046] Among them, observation cell This includes: RSRP observations for the serving cell and RSRP observations for several neighboring cells. For RSRP observations, if a grid exists in the fingerprint database... The RSRP value of the fingerprint on the corresponding cell identifier Then let As a measure of difference: when This indicates that the description of the cell's signal characteristics by the grid is largely consistent with the current MR. ,in Empirically, a value of 3dB to 5dB can be used. Otherwise, it indicates that the fingerprint signal of the cell in that grid differs too much from the current MR (the causes may include noise interference, multipath propagation, signal time-varying characteristics, and fingerprint drift). To avoid mismatches in a few abnormal dimensions, a penalty is imposed on the observation, adding a significant cost to the grid and thus reducing its probability of entering the candidate set. As a penalty contribution; if the corresponding fingerprint value does not exist in the fingerprint database, then the contribution is also taken. As a penalty for absence.
[0047] Step 4: Based on the candidate grid sequence set, perform K-value expansion in the signal domain and K-value contraction in the spatial domain to adaptively determine the candidate grid set for weighted estimation, calculate the weight of the set according to the relative cost value, and perform weighted summation of the latitude and longitude of the candidate grids to obtain the estimated position.
[0048] Specifically, step four includes three sub-processes: signal domain expansion, spatial domain contraction, and weighted fusion.
[0049] First, determine the initial number of candidate grids in the signal domain. Set signal difference threshold With the maximum number of candidate grids Calculate the upper limit of the allowed cost And use this upper limit value to filter candidate grids:
[0050]
[0051] Scan sequentially from the second-best candidate sequence, including those that satisfy... And serial number The candidate grids are used to obtain the initial candidate grid set. and The purpose of this process is to adaptively introduce more candidate grids with values close to the optimal value when the overall signal matching quality is good, and to automatically limit the size of the candidate grids when the matching quality is insufficient.
[0052] Subsequently, in the spatial domain Perform uniform shrinkage: for Computational geometric center And calculate the Haversine distance from the center of each candidate grid to the geometric center. (Unit: meters), from which the average spatial dispersion is obtained:
[0053]
[0054] Set spatial consistency threshold ,when If candidate grids are deemed too dispersed in the spatial domain and may contain outliers, then candidate grids are eliminated according to a strategy of decreasing computational value. Furthermore, the geometric center is repeatedly calculated and until Or, only one candidate grid remains, resulting in the final candidate grid set. With the number of candidate grids .
[0055] Finally, perform weighted fusion positioning: for Each candidate grid Calculate relative cost And calculate the unnormalized weights accordingly. The formula is ,in Weighting adjustment factor and , Normalization yields The estimated location is obtained by weighting the latitude and longitude coordinates with normalized weights and then summing the results.
[0056]
[0057]
Claims
1. A method for MR fingerprint localization based on the dynamic WKNN method, comprising the following steps: Step 1: Divide the area to be located into several grids, and create a fingerprint record for each grid containing latitude and longitude coordinates and signal feature vectors to form a fingerprint database; Step 2: Receive the measurement report (MR) reported by the terminal to be located, and extract the target signal feature vector from the measurement report; Step 3: Calculate the cost between the target signal feature vector and the fingerprint feature vectors of each grid in the fingerprint database. and according to value Generate a set of candidate grid sequences in ascending order; Step 4: Based on the candidate grid sequence set, perform K-value expansion in the signal domain and K-value contraction in the spatial domain to adaptively determine the candidate grid set for weighted estimation. Calculate the weights of the set according to relative cost values and perform weighted summation on the latitude and longitude of neighboring grids to obtain the estimated location.
2. The MR fingerprint localization method based on the dynamic WKNN method according to claim 1, wherein in steps three and four, firstly, candidate grid matching and sorting are performed to generate a candidate sequence; secondly, the number of candidate grids K is dynamically determined in the signal domain and spatial domain based on the sequence; and finally, grid weighting is performed to obtain a location estimate, comprising the following steps: In the offline phase, the positioning area is divided into several grids, and a fingerprint record containing latitude and longitude coordinates and signal feature vectors is created for each grid to form a fingerprint database. In the online phase, the cost value between the target signal feature vector of the MR to be located and the fingerprint feature vector of each grid in the fingerprint database is calculated, and a candidate grid sequence set is generated in ascending order of cost value. To improve positioning speed, a portion of the grids are initially selected based on the cell identifiers of the MR to be located. Then, for each of these grids... Calculate its relationship with the target feature vector The value between and apply the following to all grids: Sort the candidate sequences in ascending order to form a set of candidate sequences. And let the cost of the first item after sorting be the base cost. ; Within a single location request, for each observation cell in MR Calculate its relationship to the grid separately Local value And sum to get ,Right now , Smaller indicates a smaller grid size. The higher the match with the current MR; Among them, observation cell This includes: RSRP observations for the serving cell and RSRP observations for several neighboring cells. For RSRP observations, if a grid exists in the fingerprint database... The RSRP value of the fingerprint on the corresponding cell identifier Then let As a measure of difference: when This indicates that the description of the cell's signal characteristics by the grid is largely consistent with the current MR. ,in Empirically, a value of 3dB to 5dB can be used. Otherwise, it indicates that the fingerprint signal of the cell in the grid differs too much from the current MR (possibly due to noise, multipath, time-varying, or fingerprint drift). To avoid mismatches in the grid due to a few abnormal dimensions, a penalty is imposed on the observation, adding a significant cost to the grid and thus reducing its probability of entering the candidate set. As a penalty contribution; if the corresponding fingerprint value does not exist in the fingerprint database, then the contribution is also taken. As a penalty for deficiency; The next step is to determine the initial number of candidate grids in the signal domain. Set signal difference threshold with the maximum number of neighbors Calculate the upper limit of the allowed cost And use this upper limit value to filter candidate grids: ; Scan sequentially from the second-best candidate sequence, including those that satisfy... And serial number The candidate grids are used to obtain the initial candidate grid set. and The purpose of this process is to adaptively introduce more candidate grids with "cost values close to optimal" when the overall signal matching quality is good, and to automatically limit the candidate size when the matching quality is insufficient. Subsequently, in the spatial domain Perform uniform shrinkage, for Computational geometric center And calculate the Haversine distance from the center of each candidate grid to the geometric center. (Unit: meters), from which the average spatial dispersion is obtained: ; Set spatial consistency threshold ,when If candidate grids are deemed too dispersed in the spatial domain and may contain outliers, then candidate grids are eliminated according to a strategy of decreasing computational value. Furthermore, the geometric center is repeatedly calculated and until Or, only one candidate grid remains, resulting in the final candidate grid set. Number of neighbors ; Finally, weighted fusion positioning is performed for... Each candidate grid Calculate the relative cost: ; And calculate the unnormalized weights accordingly. : ; in Weighting adjustment factor and ,Will Normalization yields The estimated location is obtained by weighting the latitude and longitude coordinates with normalized weights and then summing the results. ; 。