Pedestrian dead reckoning and ultra-wideband positioning fusion method and system based on adaptive gradient descent
By integrating PDR and UWB positioning in LOS/NLOS mixed scenarios, and adjusting the loss function weight using the adaptive gradient descent method, the problems of PDR accumulation error and UWB non-horizontal error in indoor positioning are solved, and a high-precision positioning effect is achieved.
Patent Information
- Application Number
- CN202510474406.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-16
- Publication Date
- 2025-07-11
AI Technical Summary
In complex indoor environments, GNSS positioning is poor, PDR has problems with unknown initial location and long-distance positioning error accumulation, while UWB positioning is susceptible to NLOS signals, resulting in a decrease in positioning accuracy and stability.
In the LOS/NLOS hybrid scenario, the PDR and UWB positioning method are integrated, and the loss function weight is adjusted by arranging the UWB base station and labels, and the adaptive gradient descent method is used to adjust the loss function weight, and the PDR position is corrected and the accumulated error is eliminated.
The accuracy and reliability of indoor positioning are improved, and the UWB non-sight error and PDR accumulation error are effectively suppressed. The positioning trajectory basically coincides with the actual trajectory.
Smart Images

Figure CN120302232A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of indoor positioning, and particularly relates to a method and system for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent. Background Art
[0002] With the development of intelligent devices and the Internet of Things, location information plays an important role in more and more services. In outdoor open environments, the Global Navigation Satellite System (GNSS) has been able to meet most positioning needs. However, in complex indoor environments, due to factors such as multipath effects, signal attenuation, and obstacle occlusion, the positioning effect of GNSS will be greatly weakened or even unavailable. Therefore, how to achieve high-precision positioning in indoor environments remains a challenging problem.
[0003] Among them, PDR (Pedestrian Dead Reckoning) and UWB (Ultra-Wideband) technologies have become the mainstream technologies for indoor positioning due to their unique positioning advantages and high precision. However, the current PDR has problems such as unknown pedestrian initial positions and long-distance positioning error accumulation, and needs to be combined with other positioning technologies. And ultra-wideband is vulnerable to the influence of non-line-of-sight (NLOS) signal transmission in complex indoor environments, resulting in a significant increase in ranging errors, thus seriously affecting the positioning performance. How to accurately identify LOS (Line-of-Sight) and NLOS scenarios and improve the accuracy and stability of wireless positioning in NLOS scenarios is the difficulty of UWB positioning.
[0004] Therefore, it is urgent for this field to fuse PDR and UWB positioning methods in LOS / NLOS mixed scenarios to provide better positioning performance and reliability for practical applications. Summary of the Invention
[0005] To solve the above problems existing in the prior art, the present invention provides a method and system for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent. The present invention fuses PDR and UWB positioning methods in LOS / NLOS mixed scenarios and makes complementary advantages, improving the accuracy and reliability of positioning.
[0006] To achieve the above object, the present invention provides the following technical solutions:
[0007] A method for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent, comprising the following steps:
[0008] S1: Arrange ultra-wideband UWB base stations and UWB tags to establish a UWB positioning system;
[0009] S2: Obtain the measured distance from the positioning location to the base station through the UWB positioning system, and obtain the pedestrian dead reckoning (PDR) information from the sensor data;
[0010] S3: Obtain the predicted position for the next step through PDR;
[0011] S4: Utilize the PDR positioning result and the UWB ranging information of the pedestrian's front and rear steps to evaluate the line-of-sight and non-line-of-sight propagation characteristics of the UWB signal;
[0012] S5: According to the line-of-sight and non-line-of-sight evaluation results of the base station UWB signal, adaptively adjust the weight of the loss function, and use the gradient descent method to correct the pedestrian position obtained by PDR.
[0013] Preferably, step S1: Arrange the base stations and tags to establish a positioning system
[0014] Arrange N UWB base stations (N≥3) and a movable UWB tag with an embedded IMU chip to establish a UWB positioning system. Place the N UWB base stations at the same height, and the distance information is received by two-way wireless communication between the UWB base stations and the movable UWB tag.
[0015] Preferably, step S2: Data acquisition and preprocessing
[0016] Obtain the positioning distance through the UWB positioning system, and obtain the PDR information from the IMU sensor data; Use the least squares method to process the UWB ranging data to determine the initial position of the pedestrian. The initial position of the pedestrian, the position of the base station, and the base station ranging value satisfy the following formula:
[0017]
[0018] Among them, (x0, y0) is the initial position coordinate to be measured of the pedestrian, (x j , y j ) is the position coordinate of the jth base station, and dj is the ranging value from the jth base station to the position to be measured of the pedestrian. Due to the interference of multipath effects and the complex indoor environment, there will be a certain error in the ranging value of the base station. Therefore, directly solving the above formula is generally an empty solution. The present invention uses the least squares method to solve the approximate solution of the above formula, specifically as follows:
[0019] X = (A T A) -1 A T B
[0020] Among them, X is the position coordinate vector [x0, y0] of the pedestrian to be measured T , and the expressions of A and B are as follows:
[0021]
[0022]
[0023] Preferably, in step S3: The PDR obtains the next predicted position
[0024] According to the characteristic that the PDR has relatively high accuracy in a short time, the next pedestrian position calculated by the PDR is used as the predicted position.
[0025] Preferably, in step S4: UWB signal line-of-sight / non-line-of-sight discrimination
[0026] In this step, the PDR positioning result and the UWB ranging information of the pedestrian's front and rear steps are used to evaluate the line-of-sight and non-line-of-sight propagation characteristics of the UWB signal. The specific steps are as follows:
[0027] Step 4.1: Ranging error analysis
[0028] Calculate the distance from the predicted position to each base station as the predicted distance, and perform a difference operation with the UWB ranging distance from the next pedestrian position to each base station. The ranging error of the UWB signal in a line-of-sight environment follows a Gaussian distribution, and the ranging error in a non-line-of-sight environment will deviate significantly from this Gaussian distribution.
[0029] Approximate the ranging error ε of the UWB signal as the difference between the predicted distance d p and the UWB measured distance d a :
[0030] ε≈|d p -d a |
[0031] Define the predicted distance d p as the Euclidean distance from the next pedestrian position calculated by the PDR to the base station:
[0032]
[0033] where (x i , y i ) is the predicted position of the pedestrian's i-th step estimated by the PDR, and (x j , y j ) is the actual position of the j-th UWB base station. The first scoring function for evaluating the line-of-sight / non-line-of-sight degree of the UWB signal:
[0034]
[0035] where μ d is the mean of the ranging error, σ d is the standard deviation of the ranging error, and N(d) is the normalization coefficient used to adjust the range of the scoring function to [0,1], and its formula is as follows:
[0036]
[0037] Step 4.2: Step length consistency analysis
[0038] Since the step length of a pedestrian in each step is limited, the difference between the UWB signal measurement distances obtained at the positions of the pedestrian's front and rear steps should be within [-L i , L i . When the base station and the positions of the pedestrian's front and rear steps are on the same straight line, the maximum and minimum values in the range can be obtained. Otherwise, the three positions can form a triangle, and the triangle inequality needs to be satisfied, that is, other values within the range of [-L i , L i can be obtained. Therefore, under the condition that the previous step is a line-of-sight transmission, if the absolute value of the difference between the current front and rear steps is lower than the pedestrian's step length, it is considered that the current step UWB signal is still line-of-sight; otherwise, the non-line-of-sight degree of the UWB signal is relatively serious.
[0039] The second scoring function for evaluating the line-of-sight / non-line-of-sight degree of the UWB signal:
[0040]
[0041] δ = |d i-1 - d i |
[0042] where δ is the absolute value of the difference between the UWB ranging values at the positions of the pedestrian's front and rear steps; d i is the UWB ranging value at the position of the pedestrian's i-th step; L i is the step length of the pedestrian's i-th step. When the δ value is greater than the pedestrian's step length, δ follows a Gaussian distribution of N(L i , σ δ 2 ).
[0043] Step 4.3: Joint scoring function
[0044] Combining the previous two scoring functions, define the joint scoring function Score for the line-of-sight degree of the UWB signal:
[0045] Score i = ω1·g1(ε, i) + ω2·g2(δ, i)
[0046] where ω1 and ω2 are the weights of the two features, reflecting their importance, and can be adjusted according to the actual scenario. If the previous step is in a non-line-of-sight state, the weight of ω1 is appropriately increased to strengthen the constraint on the step length consistency condition.
[0047] Step 4.4: State discrimination
[0048] Define the propagation state of the UWB signal according to the joint scoring function:
[0049] S1: LOS (Line of Sight), the signal is unobstructed, and the ranging error is small;
[0050] S2: Weak LOS, the signal has partial obstruction, and the ranging error is medium;
[0051] S3: NLOS (Non-Line of Sight), the signal is severely obstructed or affected by multipath interference, and the ranging error is large.
[0052] State set: S = {S1, S2, S3}
[0053] State transition rule:
[0054] ① If the joint scoring function Score i > T1, then the state of the current step transfers to S1;
[0055] ② If the joint scoring function T1 > Score i > T2, then the state of the current step transfers to S2;
[0056] ③ If the joint scoring function Score i < T2, then the state of the current step transfers to S3;
[0057] where T1 and T2 are the thresholds of the joint scoring function.
[0058] Step 4.5: Dynamically update the state:
[0059] ① Initialization: Assume the initial state of the pedestrian is S1;
[0060] ② According to the joint scoring function and the state transition rule, iteratively update the state of each step.
[0061] Preferably, in step S5: Adaptively adjust the gradient descent coefficient, and use the gradient descent method to solve the next position
[0062] According to the LOS / NLOS evaluation results of the UWB signals of each base station, adaptively adjust the weights of the loss function, and finally use the gradient descent method to correct the pedestrian position obtained by PDR.
[0063] After using the least squares method to solve the initial position of the pedestrian, PDR can be used to estimate the next position of the pedestrian. However, PDR has the problem of cumulative error. As the positioning time goes by, the estimated pedestrian trajectory will gradually deviate from the actual movement route. To solve this problem, the present invention uses UWB ranging information to correct the pedestrian position and eliminate the PDR cumulative error. Considering the estimation error of PDR and the ranging information error of the base station, it is reasonable to take any position in the intersection of the PDR and UWB error regions as the next position of the pedestrian. Therefore, it is necessary to set a suitable loss function and find the position that can minimize this loss function in the intersection region as the refined position of the pedestrian.
[0064] Take the sum of the squares of the ranging errors of N UWB base stations and the PDR estimation error as the loss function. Considering that non-line-of-sight errors may occur in UWB ranging, different weights are assigned to the ranging errors based on the state output obtained in S4. The optimization objective function is as follows:
[0065]
[0066] where N is the number of base stations, p i is the estimated position of the pedestrian at the i-th step; μ i,j is the weight of the ranging error of the j-th UWB base station when the pedestrian is at the i-th step position; is the ranging error of the j-th UWB base station when the pedestrian is at the i-th step position; is the PDR estimation error of the pedestrian at the i-th step. and The specific definitions of are as follows:
[0067]
[0068] where ||·||2 represents the Euclidean distance between two points, A j is the position of the j-th base station, d i,j is the UWB ranging value of the j-th base station when the pedestrian is at the i-th step position, and l i is the step length of the pedestrian at the i-th step.
[0069] To find the optimal position p i that minimizes the objective function, the gradient descent method is used for solution. The specific process is as follows:
[0070] First, take the derivative of the objective function and calculate the gradient direction of the function at .
[0071]
[0072] where, is the starting position of the pedestrian at the i-th step, that is, the pedestrian positioning position obtained according to PDR; is the gradient direction of the objective function at ; p i-1 is the optimal position of the pedestrian at the (i - 1)-th step after position refinement.
[0073] Secondly, the pedestrian position is iteratively updated along the obtained opposite direction of the gradient, and the latest gradient direction and loss function value are calculated.
[0074]
[0075] Among them, is the position of the pedestrian at the i-th step after the (k + 1)-th iteration update; λ k is the learning rate of the (k + 1)-th iteration and also the amplitude of position iteration. The larger the learning rate, the larger the amplitude of each position iteration and the faster the convergence speed. However, too large a learning rate may also cause the gradient descent method to fail. Therefore, to balance the efficiency and accuracy of the algorithm, this paper sets the learning rate to gradually decrease as the number of iterations increases. The specific formula is as follows:
[0076] λ k+1 =αλ k
[0077] Among them, α is the adjustment coefficient, and its value is within (0, 1).
[0078] Finally, it is judged whether the termination condition is satisfied. If the termination condition is satisfied, the iteration is stopped and the minimum value of the objective function and the corresponding optimal position of the pedestrian are obtained. The present invention sets two termination conditions in total:
[0079] 1) The learning rate is lower than the set threshold, as shown in the following formula:
[0080] λ k <λ threshold
[0081] Among them, λ threshold is the lower threshold of the learning rate.
[0082] 2) The objective function value of the next iteration is greater than the current objective function value, as shown in the following formula:
[0083]
[0084] As long as any one of the two termination conditions is satisfied, the iteration is stopped.
[0085] The present invention also discloses a pedestrian dead reckoning and ultra-wideband positioning fusion system based on adaptive gradient descent for executing the above method, including the following modules:
[0086] UWB positioning system establishment module: Deploy ultra-wideband (UWB) base stations and UWB tags to establish a UWB positioning system;
[0087] PDR information calculation module: Obtain the measured distance from the positioning location to the base station through the UWB positioning system, and obtain pedestrian dead reckoning (PDR) information from sensor data;
[0088] Next-step position prediction module: Obtain the predicted position of the next step through PDR;
[0089] Evaluation module: Utilize the PDR positioning result and the UWB ranging information of the pedestrian's front and back steps to evaluate the line-of-sight (LOS) and non-line-of-sight (NLOS) propagation characteristics of the UWB signal;
[0090] Positioning module: According to the LOS and NLOS evaluation results of the base station UWB signal, adaptively adjust the weight of the loss function, and use the gradient descent method to correct the pedestrian position obtained by PDR.
[0091] Compared with the prior art, the present invention combines the PDR and UWB positioning methods in a LOS / NLOS hybrid scenario and complements their advantages, improving the accuracy and reliability of positioning. Brief Description of the Drawings
[0092] Figure 1 is a flowchart of a method for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent according to a preferred embodiment of the present invention.
[0093] Figure 2 is a schematic diagram of the distance from the base station to the tag.
[0094] Figure 3 is a scenario diagram of UWB signal ranging for two steps forward and backward.
[0095] Figure 4 is a schematic diagram of the principle of refining the PDR position based on UWB ranging information.
[0096] Figure 5 is a floor plan of the experimental scenario.
[0097] Figure 6 is a comparison diagram of the technical effects between the preferred embodiment of the present invention and the prior art.
[0098] Figure 7 is a block diagram of a system for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent according to a preferred embodiment of the present invention. Detailed Description of the Embodiment
[0099] For a more detailed description of the present invention and for the convenience of those skilled in the art to understand, the following describes the present invention in further detail in conjunction with the drawings and embodiments, taking the number of base stations N = 3 as an example.
[0100] Please refer to Figure 1 , a preferred embodiment of the present invention provides a method for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent, including the following steps:
[0101] S1: Arrange base stations and tags to establish a positioning system;
[0102] S2: Data collection and preprocessing;
[0103] S3: PDR obtains the next predicted position;
[0104] S4: Use the PDR positioning result and the UWB ranging information of the previous and next steps to evaluate the non-line-of-sight degree of the UWB signal;
[0105] S5: According to the non-line-of-sight evaluation results of the UWB signals of each base station, adaptively adjust the weights of the loss function, and finally use the gradient descent method to correct the pedestrian position obtained by PDR to reduce the positioning error.
[0106] Specifically, in step S1, three UWB base stations are placed at the same height, about 1.8 m above the ground. The pedestrian holds a movable UWB tag, which is about 1.2 m above the ground. The two-way wireless communication receives the distance information between the UWB base station and the movable UWB tag. The tag is held in the operator's hand, and then the operator starts walking according to the planned walking route. During the walking process, the tag will transmit the position information of the operator's walking to the computer.
[0107] Step S2, the data collection and preprocessing process includes the following steps:
[0108] Step 2.1: The ranging distance h from the base station to the tag is as Figure 2 shown. During the algorithm processing, the horizontal distance d from the tag to the base station needs to be obtained:
[0109]
[0110] For the convenience of description, in other parts of the present invention, the horizontal ranging distance from the tag to the base station is simply referred to as the ranging distance.
[0111] Step 2.2: Process the data obtained by the sensor accelerometer, gyroscope, and magnetometer to obtain gait detection, step length estimation, and heading angle estimation of the pedestrian.
[0112] Step 2.3: Use the least squares method to process the UWB ranging distance to determine the initial position of the pedestrian. The pedestrian's initial position, the positions of the three base stations, and the base station ranging values satisfy the following formula:
[0113]
[0114] Among them, (x0, y0) is the initial position coordinate of the pedestrian to be measured, (x j , y j ) is the position coordinate of the j-th base station, and dj is the ranging value from the j-th base station to the position of the pedestrian to be measured. Due to the multipath effect and the interference of the complex indoor environment, there will be certain errors in the ranging values of the three base stations. Therefore, directly solving the above formula generally results in an empty solution. The present invention uses the least squares method to solve the approximate solution of the above formula, specifically as follows:
[0115] X = (A T A) -1 A T B
[0116] Among them, X is the position coordinate vector [x0, y0] of the pedestrian to be measured T , and the expressions of A and B are as follows:
[0117]
[0118] In step S3, use the step size l i and the heading angle to calculate the displacement at the current moment:
[0119]
[0120] Among them, (x i , y i ) is the current position of the pedestrian, and (x i-1 , y i-1 ) is the position at the previous moment.
[0121] According to the characteristic that PDR has higher accuracy in a short time, the present invention uses the next pedestrian position deduced by PDR as the predicted position.
[0122] The execution process of step S4 includes the following steps:
[0123] Step 4.1: Ranging error analysis
[0124] Calculate the distance from the predicted position to each base station as the predicted distance, and perform a difference operation with the UWB ranging distance between the next pedestrian position and each base station. The ranging error of the UWB signal in the line-of-sight environment follows a Gaussian distribution, and the ranging error in the non-line-of-sight environment will deviate significantly from this Gaussian distribution.
[0125] Approximate the ranging error ε of the UWB signal as the difference between the predicted distance d p and the UWB measured distance d a :
[0126] ε ≈ |d p - d a |
[0127] Define the predicted distance d p as the Euclidean distance from the next predicted pedestrian position calculated by PDR to the base station:
[0128]
[0129] where (x i , y i ) is the predicted position of the i-th step of the pedestrian estimated by PDR, and (x j , y j ) is the actual position of the j-th UWB base station. The first scoring function for evaluating the LOS / NLOS degree of UWB signals:
[0130]
[0131] where μ d is the mean ranging error, σ d is the standard deviation of the ranging error, and N(d) is a normalization coefficient used to adjust the range of the scoring function to [0,1], and its formula is as follows:
[0132]
[0133] Step 4.2: Step length consistency analysis
[0134] Since the step length of a pedestrian in each step is limited, the difference between the UWB signal measurement distances obtained at the positions of the previous and next steps of the pedestrian should be within the range of [-L i , L i . As shown in Figure 3 , when the base station and the positions of the previous and next steps of the pedestrian are on the same straight line, the maximum and minimum values in the range can be obtained. Otherwise, the three positions can form a triangle, and the triangle inequality needs to be satisfied, that is, other values in the range of [-L i , L i can be obtained. Therefore, under the condition that the previous step is a LOS transmission, if the absolute value of the difference between the current previous and next steps is lower than the pedestrian's step length, it is considered that the current step of the UWB signal is still LOS; otherwise, the NLOS degree of the UWB signal is more serious. The second scoring function for evaluating the LOS / NLOS degree of UWB signals:
[0135]
[0136] δ = |d i-1 - d i |
[0137] where δ is the absolute value of the difference between the UWB ranging values at the positions of the previous and next steps of the pedestrian; d i is the UWB ranging value at the i-th step position of the pedestrian; L iis the step length of the pedestrian's i-th step. When the δ value is greater than the pedestrian's step length, δ follows a Gaussian distribution of N(L i ,σ δ 2 ).
[0138] Step 4.3: Joint scoring function
[0139] Combining the previous two scoring functions, define the joint scoring function Score for the LOS degree of the UWB signal:
[0140] Score i = ω1·g1(ε, i) + ω2·g2(δ, i)
[0141] where ω1 and ω2 are the weights of the two features, reflecting their importance, and can be adjusted according to the actual scenario. If the previous step is in the non-LOS state, the weight of ω1 is appropriately increased to strengthen the constraint on the step length consistency condition.
[0142] Step 4.4: State discrimination
[0143] According to the joint scoring function, define the propagation state of the UWB signal:
[0144] S1: LOS (Line of Sight), the signal is unobstructed and the ranging error is small;
[0145] S2: Weak LOS, the signal has partial obstruction and the ranging error is medium;
[0146] S3: NLOS (Non-Line of Sight), the signal is severely obstructed or affected by multipath interference, and the ranging error is large.
[0147] State set: S = {S1, S2, S3}
[0148] State transition rules:
[0149] ④ If the joint scoring function Score i > T1, then the state of the current step transfers to S1;
[0150] ⑤ If the joint scoring function T1 > Score i > T2, then the state of the current step transfers to S2;
[0151] ⑥ If the joint scoring function Score i < T2, then the state of the current step transfers to S3;
[0152] where T1 and T2 are the thresholds of the joint scoring function.
[0153] Step 4.5: Dynamically update the state:
[0154] ③ Initialization: Assume the initial state of the pedestrian is S1;
[0155] ④Iteratively update the state at each step according to the combined scoring function and the state transition rules.
[0156] In step S5, according to the evaluation results of the UWB signals of each base station in step S4, adaptively adjust the weights of the loss function, and finally use the gradient descent method to correct the pedestrian position obtained by PDR. The specific implementation process is as follows:
[0157] The present invention corrects the pedestrian position by using UWB ranging information to eliminate the cumulative error of PDR. The specific principle is shown as Figure 4 shown. The current position of the pedestrian is p i-1 , and the known displacement of the pedestrian in the next step is Δx i and Δy i . The position of the pedestrian in the next step p i can be deduced. Considering the estimation errors q x and q y of PDR, the actual position of the pedestrian in the next step should be within the rectangular frame area. A i is the position of the i-th UWB base station, and r i is the ranging information error of the i-th base station. The ranging information of the three base stations can estimate that the position of the pedestrian in the next step should be at the intersection of the three circular areas. Using the ranging information of the three base stations to constrain the positioning position of PDR, finally, the actual position of the pedestrian should be in Figure 4 the shaded area S. It can be seen that it is reasonable to take any position in the shaded area S as the position of the pedestrian in the next step. Therefore, it is necessary to set a suitable loss function and find the position in the shaded area S that can minimize this loss function as the refined position of the pedestrian.
[0158] Take the sum of the squares of the ranging errors of the three UWB base stations and the PDR estimation error as the loss function. Considering that non-line-of-sight errors may occur in UWB ranging, use the state output obtained in S4 as the weight of the ranging error:
[0159] ①If the state of the j-th base station at the i-th step is S1, then the corresponding weight μ i,j =1;
[0160] ②If the state of the j-th base station at the i-th step is S2, then the corresponding weight μ i,j =0.5;
[0161] ③If the state of the j-th base station at the i-th step is S3, then the corresponding weight μ i,j =0.1.
[0162] The optimization objective function is as follows:
[0163]
[0164] where N is the number of base stations. In the present invention, N = 3 is taken as an example, and p i is the estimated position of the pedestrian at the i-th step; is the ranging error of the j-th UWB base station when the pedestrian is at the i-th step position; is the PDR estimation error of the pedestrian at the i-th step. and are specifically defined as follows:
[0165]
[0166] where ||·||2 represents calculating the Euclidean distance between two points, and A j is the position of the j-th base station, d i,j is the UWB ranging value of the j-th base station when the pedestrian is at the i-th step position, and l i is the step length of the pedestrian at the i-th step.
[0167] To obtain the optimal position p that minimizes the objective function i , the present invention uses the gradient descent method to solve it. The specific process is as follows:
[0168] First, take the derivative of the objective function and calculate the gradient direction of the function at .
[0169]
[0170] where is the starting position of the pedestrian at the i-th step, that is, the pedestrian positioning position obtained according to PDR; is the gradient direction of the objective function at ; p i-1 is the optimal position of the pedestrian at the (i - 1)-th step after position refinement.
[0171] Secondly, iteratively update the pedestrian position along the opposite direction of the obtained gradient, and calculate the latest gradient direction and loss function value.
[0172]
[0173] where is the position of the pedestrian at the i-th step after the (k + 1)-th iteration update; λ k is the learning rate of the (k + 1)-th iteration, and also the amplitude of position iteration. The larger the learning rate, the larger the amplitude of each position iteration and the faster the convergence speed. However, too large a learning rate may also cause the gradient descent method to fail. Therefore, to balance the efficiency and accuracy of the algorithm, this paper sets the learning rate to gradually decrease as the number of iterations increases. The specific formula is as follows:
[0174] λk+1 =αλ k
[0175] where α is an adjustment coefficient with a value within (0, 1).
[0176] Finally, it is determined whether the termination condition is satisfied. If the termination condition is satisfied, the iteration is stopped and the minimum value of the objective function and the corresponding optimal position of the pedestrian are obtained. In this embodiment, two termination conditions are set in total:
[0177] 1) The learning rate is lower than the set threshold, as shown in the following formula:
[0178] λ k <λ threshold
[0179] where λ threshold is the lower threshold of the learning rate.
[0180] 2) The objective function value of the next iteration is greater than the current objective function value, as shown in the following formula:
[0181]
[0182] As long as any one of these two termination conditions is satisfied, the iteration is stopped.
[0183] Next, the preferred embodiment of the present invention is tested.
[0184] The experiment uses a UWB positioning development kit with the model number RTLS1-LD150. This device uses the STM32F103CBT6 single-chip microcomputer as the main control microcontroller unit, and is built-in with a UWB chip of the DW1000 model and an IMU chip of the MPU-9250 model (internally integrated with three-axis acceleration, three-axis gyroscope, and three-axis magnetometer), which can meet the requirements for data acquisition. The sampling frequency of the data is set to 50Hz. A total of four devices of the same type are used in this experiment to construct a positioning scenario, where three are used as base stations and one is used as a tag. The three base stations are deployed around the positioning scenario. To reduce the interference of ground reflection, they are placed 1.8m above the ground using brackets. The pedestrian holds the tag device horizontally in front of the chest, 1.2m above the ground.
[0185] The floor plan of the experimental scenario is as shown in Figure 5 (a) and (b). In the figure, the red nodes are the positions of the three deployed base stations, the blue nodes are the starting point and turning points of the pedestrian, and the black line segments are the actual movement routes of the pedestrian. The operator is required to start from the starting point, repeat three laps along the experimental route, and then return to the starting point, and each route is repeated three times. Figure 5The route shown in (a) is a rectangular route with a length of 18 m and a width of 10.6 m. The characteristic of this route is that during the walking process of pedestrians, the UWB signal will not be significantly blocked by obstacles, but the UWB signal may be blocked by the pedestrians' own bodies. Generally, the non-line-of-sight degree of the UWB signal is relatively low. Figure 5 The route in (b) is a square route with both length and width of 12 m. The characteristic of this route is that there are two columns in the positioning scenario, and during the walking process of pedestrians, the UWB signal will be significantly blocked by obstacles or the pedestrians' own bodies. Generally, the non-line-of-sight degree of the UWB signal is relatively serious.
[0186] The experimental results are as Figure 6 shown in (a), (b), (c), and (d), where AGD-PDR-UWB is the method proposed in the present invention, and EKF-PDR-UWB is a PDR / UWB fusion positioning algorithm based on the extended Kalman filter (EKF). Figure 6 As can be seen from (a), (b), (c), and (d), although the PDR / UWB fusion positioning algorithm based on EKF can utilize the PDR positioning information to suppress the non-line-of-sight error of the UWB signal and eliminate the PDR cumulative error, the reduced non-line-of-sight error of the UWB is limited. The AGD-PDR-UWB algorithm proposed in the present invention can identify the non-line-of-sight degree of the UWB signal, effectively suppress the non-line-of-sight error of the UWB signal in both positioning scenarios, eliminate the PDR cumulative error, and the positioning trajectory basically coincides with the actual trajectory of the pedestrian.
[0187] As Figure 7 shown, this embodiment discloses a pedestrian dead reckoning and ultra-wideband positioning fusion system based on adaptive gradient descent for implementing the above method, including the following modules:
[0188] UWB positioning system establishment module: Arrange ultra-wideband UWB base stations and UWB tags to establish a UWB positioning system;
[0189] PDR information calculation module: Obtain the measured distance from the positioning position to the base station through the UWB positioning system, and obtain the pedestrian dead reckoning PDR information through sensor data;
[0190] Next position prediction module: Obtain the predicted position of the next step through PDR;
[0191] Evaluation module: Utilize the PDR positioning result and the UWB ranging information of the pedestrians' front and rear steps to evaluate the line-of-sight and non-line-of-sight propagation characteristics of the UWB signal;
[0192] Positioning module: According to the line-of-sight and non-line-of-sight evaluation results of the base station UWB signal, adaptively adjust the weight of the loss function, and use the gradient descent method to correct the pedestrian position obtained by PDR.
[0193] For other content of this embodiment, reference may be made to the above method embodiment.
[0194] The above embodiments are used to explain the present invention for the purpose of easy understanding, and do not limit the present invention thereby.
Claims
1. A pedestrian dead reckoning and ultra-wideband positioning fusion method based on adaptive gradient descent, characterized in that, It includes the following steps: S1: Arrange ultra-wideband (UWB) base stations and UWB tags to establish a UWB positioning system; S2: Obtain the measured distances from the positioning positions to the base stations through the UWB positioning system, and obtain the pedestrian dead reckoning (PDR) information from the sensor data; S3: Obtain the predicted position for the next step through PDR; S4: Utilize the PDR positioning results and the UWB ranging information of the pedestrian's front and back steps to evaluate the line-of-sight (LOS) and non-line-of-sight (NLOS) propagation characteristics of the UWB signal; S5: According to the LOS and NLOS evaluation results of the base station UWB signal, adaptively adjust the weights of the loss function, and use the gradient descent method to correct the pedestrian position obtained by PDR.
2. The method for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent according to claim 1, wherein The specific steps of S1 are as follows: Arrange N UWB base stations and a movable UWB tag to establish the described UWB positioning system, where N≥3; Place the UWB base stations at the same height, and the two-way wireless communication receives the distance information between the UWB base stations and the movable UWB tag.
3. The method for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent according to claim 1 or 2, characterized in that The specific steps of S2 are as follows: Obtain the positioning distances through the UWB positioning system and obtain the PDR information from the sensor data; Use the least squares method to process the UWB ranging data to determine the initial position of the pedestrian; The initial position of the pedestrian, the positions of N base stations, and the base station ranging values satisfy the following formula: Among them, (x0,y0) is the initial position coordinate of the pedestrian to be measured, (x j ,y j ) is the position coordinate of the j-th base station, and d j is the ranging value from the j-th base station to the position of the pedestrian to be measured; the approximate solution of the above formula is solved by the least squares method, specifically as follows: X = (A T A) -1 A T B where X is the position coordinate vector [x0, y0] to be measured for the pedestrian T , and the expressions of A and B are as follows:
4. The method for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent according to claim 3, wherein, The specific steps of S4 are as follows: Step 4.1: Calculate the distances from the predicted position to each base station as the predicted distances, and perform a difference operation with the UWB ranging distances between the next pedestrian position and each base station; Approximate the ranging error ε of the UWB signal as the predicted distance d p and the UWB measured distance d a The difference is: ε≈|d p -d a | Define the predicted distance d p as the Euclidean distance from the next pedestrian position estimated by PDR to the base station: where (x i , y i ) is the predicted position of the i-th step of the pedestrian estimated by PDR, and (x j , y j ) is the actual position of the j-th UWB base station; the first scoring function for evaluating the line-of-sight and non-line-of-sight degrees of UWB signals: where μ d is the mean ranging error, σ d is the standard deviation of the ranging error, and N(d) is the normalization coefficient used to adjust the range of the scoring function to [0, 1], and its formula is as follows: Step 4.2: The second scoring function for evaluating the LOS and NLOS degrees of the UWB signal: δ = |d i-1 - d i | Among them, δ is the absolute value of the difference between the UWB ranging values of the pedestrian at the front and rear step positions of the UWB signal; d i is the UWB ranging value of the pedestrian at the i-th step position; L i is the step length of the i-th step of the pedestrian; when the δ value is greater than the pedestrian's step length, δ follows the Gaussian distribution of N(L i , σ δ 2 ). Step 4.3: Combine the two scoring functions to define the joint scoring function Score of the LOS degree of the UWB signal: Score i = ω1·g1(ε, i) + ω2·g2(δ, i) where ω1 and ω2 are the weights of the two features; Step 4.4: Define the propagation state of the UWB signal according to the joint scoring function: S1: LOS, the ranging error is less than the set value; S2: Weak LOS, the ranging error is equal to the set value; S3: NLOS, the ranging error is greater than the set value; State set: S = {S1, S2, S3} State transition rules: ① If the combined scoring function Score i > T1, then the state of the current step transfers to S1; ② If the combined scoring function T1 > Score i > T2, then the state of the current step transfers to S2; ③ If the combined scoring function Score i < T2, then the state of the current step transfers to S3; where T1 and T2 are the thresholds of the joint scoring function; Step 4.5: Dynamically update the state: ① Initialization: Set the initial state of the pedestrian as S1; ② According to the joint scoring function and the state transition rules, iteratively update the state of each step.
5. The method for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent according to claim 4, wherein Take the sum of the squares of the ranging error of the UWB base station and the PDR estimation error as the loss function, and assign different weights to the ranging error according to the state output obtained in step S4; The optimization objective function is as follows: where N is the number of base stations, p i is the estimated position of the pedestrian at the i-th step; μ i,j is the weight of the ranging error of the j-th UWB base station when the pedestrian is at the i-th step position; is the ranging error of the j-th UWB base station when the pedestrian is at the i-th step position; is the PDR estimation error of the pedestrian at the i-th step; and are specifically defined as follows: Among them, ||·||2 represents the Euclidean distance between two points, and A j is the location of the j-th base station, and d i,j is the UWB ranging value of the j-th base station when the pedestrian is at the i-th step position, and l i is the step length of the pedestrian at the i-th step.
6. The method for fusing pedestrian dead reckoning and ultra-wideband positioning based on adaptive gradient descent according to claim 5, characterized in that In step S5, the gradient descent method is used for solution, and the specific steps are as follows: First, take the derivative of the objective function and calculate the gradient direction of the function at ; Among them, is the starting position of the pedestrian at the i-th step; is the gradient direction of the objective function at ; p i-1 is the optimal position of the pedestrian at the (i - 1)-th step after position refinement; Secondly, iteratively update the pedestrian position along the opposite direction of the obtained gradient, and calculate the latest gradient direction and the loss function value; Among them, is the position of the pedestrian at the $i$-th step after the $(k + 1)$-th iteration update; $\lambda$ k is the learning rate of the $(k + 1)$-th iteration; the learning rate is set to gradually decrease as the number of iterations increases, and the specific formula is as follows: λ k+1 =αλ k where α is the adjustment coefficient; Finally, determine whether the termination condition is met. If the termination condition is met, stop the iteration and obtain the minimum value of the objective function and the corresponding optimal pedestrian position; The termination condition is one of the following two: 1) The learning rate is lower than the set threshold, as shown in the following formula: λ k <λ threshold Among them, λ threshold is the lower threshold of the learning rate; 2) The objective function value of the next iteration is greater than the current objective function value, as shown in the following formula:
7. A pedestrian dead reckoning and ultra-wideband positioning fusion system based on adaptive gradient descent, for performing the method according to any one of claims 1-6, characterized in that, It includes the following modules: UWB positioning system establishment module: Deploy ultra-wideband (UWB) base stations and UWB tags to establish a UWB positioning system; PDR information calculation module: Obtain the measured distance from the positioning location to the base station through the UWB positioning system, and obtain the pedestrian dead reckoning (PDR) information from sensor data; Next-step position prediction module: Obtain the predicted position of the next step through PDR; Evaluation module: Utilize the PDR positioning results and the UWB ranging information of the pedestrian's front and back steps to evaluate the line-of-sight and non-line-of-sight propagation characteristics of the UWB signal; Positioning module: According to the line-of-sight and non-line-of-sight evaluation results of the base station UWB signal, adaptively adjust the weights of the loss function, and use the gradient descent method to correct the pedestrian position obtained by PDR.