Visual navigation surveying and mapping positioning method and device based on semantic reference library and medium

Through the visual navigation surveying and mapping positioning method based on the semantic reference library, the YOLOv5s network and semantic road sign matching algorithm are used to solve the problem of low vehicle positioning accuracy in satellite signal denial environment, and high-precision outdoor navigation is realized, reducing the cost and manpower of map surveying and mapping Material consumption.

CN118730078AActive Publication Date: 2024-10-01NANJING UNIV OF AERONAUTICS & ASTRONAUTICS

Patent Information

Application Number
CN202410629306.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-21
Publication Date
2024-10-01
Estimated Expiration
2044-05-21

AI Technical Summary

Technical Problem

In the environment of satellite signal denial, it is difficult for traditional vehicles to ensure long-distance and high-precision positioning, especially the cumulative error of inertial devices cannot be effectively corrected. The existing semantic map research is mainly focused on indoor or lidar-based outdoor environments , lack of high-precision positioning methods suitable for outdoor scenes.

Method used

Using the visual navigation surveying and mapping method based on the semantic benchmark library, the image semantic information is extracted through the YOLOv5s network, dynamic feature point removal algorithm and semantic road sign matching algorithm are built to build a semantic road sign reference library with geographic information, and to correct visual odometer errors to achieve high Precision geographic coordinate output.

Benefits of technology

It realizes high-precision positioning for long-distance flights without lidar assistance in outdoor scenarios, improves the construction accuracy of semantic road sign reference database and navigation positioning accuracy, reduces manpower and material losses, and reduces costs in map surveying and mapping.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118730078A_ABST
    Figure CN118730078A_ABST
Patent Text Reader

Abstract

The invention discloses a visual navigation surveying and mapping positioning method and device based on a semantic reference library and a medium, and the method comprises the steps: collecting high-precision geographic position information and environment image information based on a surveying and mapping vehicle, extracting image semantic information through a YOLOv5s network, and dividing the image semantic information into high-dynamic semantic information and high-static semantic information; eliminating feature points on the dynamic object by adopting a dynamic feature point elimination algorithm; constructing a semantic road sign benchmark library with geographic information based on the high static semantic information; matching with a semantic road sign reference library according to the image semantic information and the camera pose Twc; after matching succeeds, correcting accumulative errors of the visual odometer through a pose optimization algorithm to obtain an accurate camera pose; and outputting high-precision geographic coordinates of the vehicle through coordinate system transformation. The method is suitable for long-endurance high-precision positioning in an outdoor scene, laser radar assistance is not needed, and high-precision positioning in a geographic coordinate system of the vehicle is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of map surveying and navigation positioning, and in particular relates to a visual navigation surveying and positioning method, device and medium based on a semantic reference library. Background Art

[0002] Traditional vehicle autonomous navigation uses a combination of inertial and satellite navigation. However, in satellite signal denial conditions, the accumulated errors of inertial devices cannot be corrected, making it difficult to ensure long-range, high-precision positioning of the vehicle. With the development of computer science and data processing technology, the introduction of digital maps and map-assisted navigation through environmental landmark matching have become an effective positioning method in satellite-denied environments.

[0003] Existing digital maps primarily include road network maps, point cloud maps, and semantic maps. Road network maps contain information such as road width and turning points, and can constrain the cumulative error of vehicle navigation through road network matching algorithms. They have the advantages of small data volumes and ease of storage, but cannot correct for cumulative errors on long straight sections. Point cloud maps contain information about feature points in the environment and their descriptors, and through point cloud matching, achieve high-precision positioning. They offer the advantages of rich visual information and precise positioning, but suffer from large data volumes and high storage costs. In comparison, semantic maps require less storage space and, through semantic landmark matching algorithms, assist navigation, capable of correcting cumulative errors on long straight sections. Currently, research on semantic map-assisted navigation primarily focuses on indoor or LiDAR-based outdoor environments. Summary of the Invention

[0004] Purpose of the invention: The present invention proposes a visual navigation, mapping and positioning method, device and medium based on a semantic reference library, which is suitable for long-duration, high-precision positioning in outdoor scenes and does not require the assistance of lidar.

[0005] Technical solution: The present invention provides a method for visual navigation, surveying, and positioning based on a semantic reference library, comprising the following steps:

[0006] (1) Based on the high-precision geographic location information and environmental image information collected by the surveying and mapping vehicle, the image semantic information is extracted through the YOLOv5s network and divided into high dynamic semantic information and high static semantic information;

[0007] (2) Using dynamic feature point elimination algorithm to eliminate highly dynamic semantic feature points;

[0008] (3) Constructing a semantic landmark benchmark library with geographic information based on highly static semantic information;

[0009] (4) According to the image semantic information and camera pose T w c Matching with the semantic landmark benchmark library;

[0010] (5) The semantic category of the current frame is consistent with that of the semantic landmark frame, and the semantic frame coordinate deviation and Euclidean distance meet the set threshold, which is considered a successful match. Then, the accumulated error of the visual odometry is corrected through the pose optimization algorithm to obtain the accurate camera pose.

[0011] (6) Output the high-precision geographic coordinates of the vehicle through coordinate system transformation.

[0012] Furthermore, the implementation process of step (1) is as follows:

[0013] The surveying and mapping vehicle uses the RTK device to collect its own high-precision geographic location information, which includes the vehicle's longitude, latitude, altitude, and the time of collection. The surveying and mapping vehicle uses the front binocular camera to collect environmental image information, including the collected left and right eye images and the collection time. The image-specified semantic information is extracted through the YOLOv5s network. The semantic information includes semantic categories and semantic pixel frame coordinates. The semantic information is divided into high-dynamic semantics and high-static semantics. The high-dynamic semantics include people and vehicles, and the high-static semantics include street lights and traffic landmarks, which are used to build a semantic landmark benchmark library.

[0014] Furthermore, the implementation process of step (2) is as follows:

[0015] The feature points inside the human pixel frame are directly eliminated, and the dynamic and static state of the vehicle are further judged based on the optical flow algorithm;

[0016] Track feature points using the optical flow algorithm to obtain matching feature points in the previous and next frames;

[0017] Calculate the average pixel deviation of matching feature points between two frames:

[0018]

[0019] Where pixd is the average pixel deviation, (u 1t ,v 1t ) is the pixel coordinate of the t-th feature point in the current frame, (u 2t ,v 2t ) is the coordinate of the matching point in the previous frame, and N is the total number of successfully matched feature points;

[0020] Traverse the depth of the feature points inside the vehicle detection frame and calculate the average depth as the distance between the vehicle and the camera:

[0021]

[0022] Among them, dep is the distance between the vehicle and the camera, m is the number of feature points inside the detection frame, and d i is the depth value of the i-th feature point;

[0023] Traverse the feature points inside the vehicle detection frame. If they satisfy formula (4), they are considered dynamic feature points. If not, they are static feature points. Calculate the ratio of dynamic feature points to the total number of feature points in the vehicle detection frame. If it is greater than the set threshold Th, the vehicle is considered to be a dynamic vehicle and the feature points are removed. Otherwise, it is a static vehicle and the feature points are retained:

[0024]

[0025]

[0026] Among them, c_pix i is the absolute value of the difference between the pixel offset of the i-th matching feature point in the vehicle detection frame and the average pixel offset, and Y is the set threshold.

[0027] Furthermore, the implementation process of step (3) is as follows:

[0028] The timestamp is used to associate the camera pose and the vehicle's northeast celestial coordinates to give the current frame real geographic information, and the YOLOv5s network is used to identify high static semantics and extract the corresponding semantic information Sem j =(n j ,l j ,t j ,r j ,b j ),j=1,2,3,....m, m is the number of semantics contained in the current frame, n j is the semantic category, l j is the coordinate value of the left boundary of the semantic pixel box, t j is the coordinate value of the upper boundary of the semantic pixel box, r j is the coordinate value of the right boundary of the semantic pixel box, b j The coordinate value of the lower boundary of the semantic pixel frame is used to assign semantic information to the current frame. The coordinates of the semantic pixel frame and the pixel coordinates of the image frame are based on the pixel coordinate system. Geographical coordinates E i and the semantic information contained in the current frame {Sem1, Sem2, ..., Sem m}Build a semantic landmark benchmark library with geographic information.

[0029] Furthermore, the implementation process of step (4) is as follows:

[0030] During the positioning phase, the vehicle's front-mounted binocular camera obtains real-time environmental image information, and the image information is input into the visual SLAM system to obtain the current camera pose. Input YOLOv5s network to obtain pixel semantic information, {Sem'1,Sem'2,…,Sem' w},Sem'o =(n' o ,l' o ,t' o ,r o ',b' o ),o=1,2,3,…,w; the specific steps of semantic landmark frame matching algorithm are as follows:

[0031] Eliminate semantic landmark frames in the semantic landmark benchmark library that do not correspond to the semantic category and semantic quantity of the current frame; and semantic landmark frame pose Get and In the semantic landmark benchmark library, the semantic landmark frames that satisfy formula (5) are brute-force retrieved as candidate semantic landmark matching frames {l a1 ,l a2 ,l a3 ,…,l ak}:

[0032]

[0033] Where dis_p is the set distance threshold; let l ai ,i=1,2,3,…,k frames correspond to the semantic information {Sem1,Sem2,…,Sem w},Sem j =(n j ,l j ,t j ,r j ,b j ),j=1,2,3,…,w), retrieve {l a1 ,l a2 ,l a3 ,…,l ak} and the semantic information of the current frame {Sem'1, Sem'2, ..., Sem' w},Sem' j =(n' j ,l' j ,t' j ,r j ',b' j ),j=1,2,3,…,w, the semantic landmark frame that satisfies formula (6) is used as the final candidate semantic landmark matching frame {l b1 ,l b2 ,l b3 ,…,l bk}:

[0034]

[0035] Where pfe is the set pixel frame deviation threshold; retrieval {lb1 ,l b2 ,l b3 ,…,l bk The semantic landmark frame closest to the current frame is taken as the successfully matched semantic landmark matching frame l s , the semantic landmark matching frame pose is The geographical coordinates are E s =(x s ,y s ,z s ) T .

[0036] Furthermore, the implementation process of step (5) is as follows:

[0037] The semantic landmark matching frame l in the semantic landmark benchmark library is retrieved through the semantic landmark frame matching algorithm s , the posture is The camera pose of the current frame is If the distance between the two frames is greater than the threshold dis_d, the cumulative error of the camera pose inferred by the visual odometry is large. The pose of the semantic landmark matching frame is directly assigned to the current frame, and the visual odometry is initialized with the current frame as the first frame to significantly correct the cumulative error. If the distance between the two frames is less than the threshold dis_d, the improved bundle adjustment method is used to slightly correct the key frame pose and map point coordinates. The specific steps are as follows:

[0038] Construct the reprojection observation equation and record the i-th map point as The matching pixel coordinates are are the coordinates of the feature points in the left image, is the horizontal coordinate of the feature point in the right image, and the camera pose in the current frame is By using formula (7), the map points Convert from the world coordinate system to the camera coordinate system, and use the camera intrinsic parameter matrix K according to the pinhole imaging principle to convert Projected to the pixel coordinate system as shown in formula (8), and based on the binocular model, the coordinate constraints of the feature points on the left and right are constructed. Where b is the camera baseline;

[0039]

[0040]

[0041] Construct the reprojection observation equation based on the pinhole camera model and binocular model:

[0042]

[0043]

[0044] Among them, F s is the constraint function, ω x,i is the noise, Σ x,i is the covariance matrix;

[0045] The semantic landmark matching frame pose is The corresponding translation vector is The current frame pose is The corresponding translation vector is The semantic landmark matching frame pose is used to constrain the current frame pose and construct the semantic landmark matching frame observation equation:

[0046]

[0047] Among them, v S is the noise, Σ SEM_L is the covariance matrix;

[0048] Based on the classic bundle adjustment method, a new error term is introduced to optimize the camera pose and map point coordinates and construct the objective function:

[0049]

[0050]

[0051]

[0052] Among them, E per (x,i) is the error term constructed based on the reprojection error, E Ser (s,k) is the error term constructed based on the semantic landmark matching frame, ρ, ρ s is a robust kernel function, which is used to weaken the influence of poor quality error edges on the optimization results and make the optimization algorithm more robust; L is the map point set, K L is a set of local key frames, K s is a key frame with a corresponding semantic landmark matching frame, T s is a set of semantic landmark frames, where there are observation constraints between map points and key frames, K s With T s There are observation constraints between Σ, Σ SEM_L They are the covariance matrices of the reprojection error term and the covariance matrix of the semantic landmark frame error term added in this section, respectively, which represent the estimation of the accuracy of each constraint.

[0053] Furthermore, the implementation process of step (6) is as follows:

[0054] For accurate camera pose Find the coordinates of the current vehicle in the world coordinate system:

[0055]

[0056] According to the current vehicle coordinates Ow, search the semantic landmark reference library for the closest vehicle position. n semantic landmark frames, and construct a set P = {p1, p2, ..., p n}, construct a set D = {d1, d2, ..., d n}, and finally construct a least squares problem to solve the transformation matrix from the world coordinate system to the geographic coordinate system:

[0057]

[0058] Using formula (16) we can get Convert Ow to the geographic coordinate system and output the vehicle's position coordinates in the geographic coordinate system to achieve high-precision navigation and positioning of the vehicle.

[0059] A device according to the present invention includes a memory and a processor, wherein:

[0060] a memory for storing computer programs capable of running on the processor;

[0061] The processor is configured to execute the steps of the above-mentioned visual navigation, surveying and positioning method based on the semantic reference library when running the computer program.

[0062] The present invention provides a storage medium having a computer program stored thereon, which, when executed by at least one processor, implements the steps of the visual navigation, surveying and positioning method based on a semantic reference library as described above.

[0063] Beneficial effects: Compared with the prior art, the advantages and beneficial effects of the present invention are:

[0064] The proposed automated mapping solution for the semantic reference library uses on-board sensors and the YOLOv5s network to collect vehicle geographic data, image information, and semantic information. It then uses a designed algorithm to automatically construct the semantic reference library, reducing the loss of manpower and material resources during map mapping and improving map construction efficiency.

[0065] This paper adopts a dynamic feature point elimination algorithm to identify highly dynamic objects (people, vehicles) through the YOLOv5s network. Combined with the designed dynamic object discrimination algorithm, dynamic feature points are eliminated to reduce the pose solution error, thereby improving the accuracy of the semantic landmark reference library construction and the positioning accuracy of the navigation stage.

[0066] This paper proposes a semantic landmark frame matching algorithm. It uses the semantic information (semantic category, semantic pixel box coordinates) detected by the YOLOv5s network and the current frame camera pose as input information, and retrieves matching semantic landmark frames from the semantic landmark reference library. It can quickly and accurately locate semantic landmark matching frames.

[0067] The present invention proposes an algorithm for correcting the cumulative error of the visual odometry through the semantic landmark matching frame. The cumulative error is corrected in two ways. The distance difference between the current frame and the semantic landmark matching frame is used as a condition. If the distance is too large, the semantic landmark matching frame pose is directly assigned to the current frame and the system is initialized. Otherwise, the key frame pose and map point coordinates are optimized according to the semantic landmark matching frame pose through the designed improved bundle adjustment method. Finally, through the coordinate system transformation, high-precision positioning of the vehicle in the geographic coordinate system is achieved. BRIEF DESCRIPTION OF THE DRAWINGS

[0068] Figure 1 This is a flow chart of the visual navigation, mapping and positioning method based on the semantic reference library;

[0069] Figure 2 Renderings of highly dynamic object detection and feature point extraction;

[0070] Figure 3 Schematic diagram of the relationship between semantic pixel boxes and image frames;

[0071] Figure 4 Schematic diagram of the graph optimization constraint model;

[0072] Figure 5 A diagram of the Tiger Claw sports car platform constructed in an embodiment of the present invention;

[0073] Figure 6 It is a surveying and mapping trajectory and a positioning trajectory diagram in an embodiment of the present invention;

[0074] Figure 7 This is a positioning error curve diagram in an embodiment of the present invention. DETAILED DESCRIPTION

[0075] The present invention will be described in further detail below with reference to the accompanying drawings.

[0076] like Figure 1As shown, the present invention proposes a visual navigation surveying and positioning method based on a semantic reference library, which is divided into a surveying stage and a navigation stage: in view of the fact that there are a large number of dynamic objects in the surveying and navigation process, the construction accuracy of the semantic landmark reference library in the surveying stage and the positioning accuracy in the navigation stage are reduced, and a dynamic feature point elimination algorithm is used to eliminate feature points on dynamic objects to reduce the impact of dynamic objects. In the surveying stage, vehicle geographic data, environmental image information, and semantic information (semantic categories, semantic pixel frame coordinates) are obtained respectively through a high-precision geographic information acquisition device, an image information acquisition device, and a YOLOv5s network. The semantic categories selected by the present invention are street lights and traffic landmarks, because they exist for a long time and are not easy to change, thereby ensuring that the semantic landmark reference library constructed in the surveying stage is long-term valid. The present invention is based on the image frame camera pose The vehicle's high-precision geographic location and semantic information automatically build a semantic landmark benchmark library. During the navigation phase, real-time images are collected and the semantic information obtained through the YOLOv5s network is used to calculate the current camera pose. The semantic information is matched with the semantic landmark reference library built during the surveying and mapping phase. After the match is successful, the designed pose optimization algorithm is used to correct the accumulated error of the visual odometry. The vehicle's geographic coordinates are then output through coordinate system transformation to achieve high-precision navigation and positioning in the vehicle's geographic coordinate system. The specific implementation process is as follows:

[0077] Step 1: The surveying vehicle collects its own high-precision geographic location information and environmental image information, and extracts image semantic information through the YOLOv5s network.

[0078] The surveying vehicle collects its own high-precision geographic location information through the RTK device. The information includes the longitude, latitude, altitude and time of the vehicle's collection. The surveying vehicle collects environmental image information through the front binocular camera, including the collected left and right eye images and the collection time. The present invention extracts the specified semantic information of the image through the YOLOv5s network. The semantic information includes semantic categories and semantic pixel frame coordinates. The semantic categories of the present invention are divided into two categories: high dynamic semantics and high static semantics. High dynamic semantics include people and vehicles, which are used for dynamic feature point removal algorithms. High static semantics include street lights and traffic landmarks, which are used to build a semantic road sign benchmark library. The present invention aligns high-precision geographic information and image information through time.

[0079] Step 2: Dynamic feature point removal algorithm:

[0080] During surveying and navigation, it is inevitable to encounter a large number of dynamic objects, such as people and vehicles. Feature points on dynamic objects will reduce the accuracy of camera pose calculation, thereby affecting the accuracy of semantic landmark reference library construction in the surveying phase and positioning accuracy in the navigation phase. This paper designs a dynamic feature point removal algorithm to avoid the influence of dynamic feature points on camera pose calculation. The specific steps of the algorithm are as follows:

[0081] 1) Use the YOLOv5s network to identify vehicles and people in the image and mark the pixel boxes in the image. Use the ORB feature point extraction algorithm to extract image feature points, such as Figure 2 As shown, the blue box is the vehicle semantic box, the pink box is the human semantic box, the red points are the feature points inside the semantic box, the blue points are the feature points corresponding to the map points that can only be observed in the current frame, and the green points are the feature points corresponding to the map points in the map.

[0082] 2) Feature points inside the human pixel frame are directly eliminated, and the dynamic and static state of the vehicle is further judged based on the optical flow algorithm.

[0083] 3) Track the feature points through the optical flow algorithm to obtain the matching feature points of the previous and next frames.

[0084] 4) Calculate the average pixel deviation of the matching feature points between the two frames, as shown in formula (1):

[0085]

[0086] Where, (u 1t ,v 1t ) is the pixel coordinate of the t-th feature point in the current frame, (u 2t ,v 2t ) is the coordinate of the matching point in the previous frame, N is the total number of successfully matched feature points, and pixd is the average pixel deviation.

[0087] 5) Because the distance between the object and the camera affects the pixel offset, we traverse the depth of the feature points inside the vehicle detection frame and calculate the average depth as the distance between the vehicle and the camera, as shown in formula (2):

[0088]

[0089] Where dep is the distance between the vehicle and the camera, m is the number of feature points inside the detection frame, and d i is the depth value of the i-th feature point.

[0090] 6) Traverse the feature points inside the vehicle detection frame. If they satisfy formula (4), they are considered dynamic feature points. If not, they are static feature points. Calculate the ratio of the dynamic feature points of the vehicle detection frame to the total number of feature points inside the frame. If it is greater than the set threshold Th, the vehicle is considered to be a dynamic vehicle and the feature points are removed. Otherwise, it is a static vehicle and the feature points are retained.

[0091]

[0092]

[0093] In formula (3), c_pix iis the absolute value of the difference between the pixel offset of the i-th matching feature point in the vehicle detection frame and the average pixel offset, and Y is the set threshold.

[0094] Step 3: Build a semantic landmark benchmark library with geographic information.

[0095] The classic visual SLAM (Simultaneous localization and mapping) method includes front-end odometer, back-end optimization, loop detection and construction. Figure 4 A module that uses the camera coordinate system of the first frame as the world coordinate system and can obtain the camera pose in real time The vehicle-mounted high-precision geographic information acquisition device can obtain the vehicle's latitude and longitude data, and further solve the northeast celestial coordinate E of the vehicle based on its initial position. i =(x i ,y i ,z i ) T , i=1,2,3,...n, the present invention uses the neighborhood interpolation algorithm to associate the camera pose and the northeast coordinate of the vehicle. The present invention uses the YOLOv5s network to identify high static semantics (street lights, traffic landmarks) and extract the corresponding semantic information (semantic category, semantic pixel box coordinates) Sem j =(n j ,l j ,t j ,r j ,b j ),j=1,2,3,....m, where m represents the number of semantics contained in the current frame, n j is the semantic category, l j is the u-axis coordinate value of the left boundary of the semantic pixel box, t j is the coordinate value of the v-axis of the upper boundary of the semantic pixel box, r j is the u-axis coordinate value of the right boundary of the semantic pixel box, b j is the v-axis coordinate value of the lower boundary of the semantic pixel frame, which gives semantic information to the current frame; the relationship between the semantic pixel frame and the image frame is as follows Figure 3 As shown, the semantic pixel frame coordinates and image frame pixel coordinates are based on the pixel coordinate system. Geographical coordinates E i and the semantic information contained in the current frame {Sem1, Sem2, ..., Sem m}Build a semantic landmark benchmark library with geographic information.

[0096] Step 4: Based on image semantic information and camera pose Matching with the semantic landmark benchmark library.

[0097] During the positioning phase, the vehicle's front-mounted binocular camera is used to obtain real-time environmental image information. This image information is input into the visual SLAM system to obtain the current camera pose. Input YOLOv5s network to obtain pixel semantic information, {Sem'1,Sem'2,…,Sem' w},Sem' o =(n' o ,l' o ,t' o ,r o ',b' o ), o = 1, 2, 3, ..., w. The present invention designs a semantic landmark frame matching algorithm, the specific steps are as follows:

[0098] 1) Remove semantic landmark frames in the semantic landmark benchmark library that do not correspond to the semantic category and semantic quantity of the current frame.

[0099] 2) Pass and semantic landmark frame pose Get and In the semantic landmark benchmark library, the semantic landmark frames that satisfy formula (5) are brute-force retrieved as candidate semantic landmark matching frames {l a1 ,l a2 ,l a3 ,…,l ak}:

[0100]

[0101] Where dis_p is the set distance threshold.

[0102] 3) Search {l a1 ,l a2 ,l a3 ,…,l ak}(Assume l ai ,i=1,2,3,…,k frames correspond to the semantic information {Sem1,Sem2,…,Sem w},Sem j =(n j ,l j ,t j ,r j ,b j ),j=1,2,3,…,w) and the semantic information of the current frame {Sem'1,Sem'2,…,Sem' w},Sem' j =(n' j ,l' j ,t' j ,r j ',b' j),j=1,2,3,…,w, the semantic landmark frame that satisfies formula (6) is used as the final candidate semantic landmark matching frame {l b1 ,l b2 ,l b3 ,…,l bk}:

[0103]

[0104] Where pfe is the set pixel box deviation threshold, and w is the semantic quantity.

[0105] 4) Search {l b1 ,l b2 ,l b3 ,…,l bk The semantic landmark frame closest to the current frame is taken as the successfully matched semantic landmark matching frame l s , the semantic landmark matching frame pose is The geographical coordinates are E s =(x s ,y s ,z s ) T .

[0106] Step 5: The current frame and the semantic landmark frame have the same semantic category, and the semantic frame coordinate deviation and Euclidean distance meet the set threshold, which is considered a successful match. Then, the pose optimization algorithm is used to correct the accumulated error of the visual odometry to obtain the accurate camera pose.

[0107] The semantic landmark matching frame l in the semantic landmark benchmark library is retrieved through the semantic landmark frame matching algorithm s , the posture is The camera pose of the current frame is If the distance between the two frames is greater than the threshold dis_d, the cumulative error of the camera pose inferred by the visual odometry is large. The pose of the semantic landmark matching frame is directly assigned to the current frame, and the visual odometry is initialized with the current frame as the first frame, significantly correcting the cumulative error. If the distance between the two frames is less than the threshold dis_d, the improved bundle adjustment method is designed to slightly correct the key frame pose and map point coordinates. The algorithm steps are as follows:

[0108] 1) Construct the reprojection observation equation and record the i-th map point as The matching pixel coordinates are are the coordinates of the feature points in the left image, is the horizontal coordinate of the feature point in the right image, and the camera pose in the current frame is By using formula (7), the map points Convert from the world coordinate system to the camera coordinate system, and use the camera intrinsic parameter matrix K according to the pinhole imaging principle to convert Projected to the pixel coordinate system as shown in formula (8), and based on the binocular model, the coordinate constraints of the feature points on the left and right are constructed. Where b is the camera baseline.

[0109]

[0110]

[0111] The reprojection observation equation is constructed based on the pinhole camera model and the binocular model as shown in the formula. In formula (9), F s The constraint function is defined as shown in formula (10):

[0112]

[0113]

[0114] Among them, ω x,i is the noise, Σ x,i is the covariance matrix.

[0115] Construct the semantic landmark matching frame observation equation, and the semantic landmark matching frame pose is The corresponding translation vector is The current frame pose is The corresponding translation vector is Because the semantic landmark matching frame pose is associated with high-precision geographic information during the mapping process and the semantic landmark frame pose is used as a reference during navigation, the semantic landmark matching frame pose is used to constrain the current frame pose. The constructed observation equation is shown in Equation (11):

[0116]

[0117] Among them, v S is the noise, Σ SEM_L is the covariance matrix.

[0118] 2) Based on the classical bundle adjustment method, this paper introduces a new error term to optimize the camera pose and map point coordinates. The constructed objective function is as follows:

[0119]

[0120]

[0121]

[0122] Among them, E per (x,i) is the error term constructed based on the reprojection error, E Ser(s,k) is the error term constructed based on the semantic landmark matching frame, ρ, ρ s is a robust kernel function, which is used to weaken the influence of poor quality error edges on the optimization results and make the optimization algorithm more robust; L is the map point set, K L is a set of local key frames, K s is a key frame with a corresponding semantic landmark matching frame, T s is a semantic landmark frame set, and the corresponding relationship between each data is as follows Figure 4 As shown, there is an observation constraint between the map points and the key frames, K s With T s There are observation constraints between Σ, Σ SEM_L They are the covariance matrix of the reprojection error term and the covariance matrix of the semantic landmark frame error term added by the present invention, representing the estimation of the accuracy of each constraint.

[0123] Step 6: Output the vehicle's high-precision geographic coordinates through coordinate system transformation.

[0124] After the above steps, the present invention obtains accurate camera posture According to formula (15), the coordinates of the current vehicle in the world coordinate system are calculated:

[0125]

[0126] According to the current vehicle coordinates Ow, search the semantic landmark reference library for the closest vehicle position. n semantic landmark frames, and construct a set P = {p1, p2, ..., p n}, construct a set D = {d1, d2, ..., d n}, and finally construct the least squares problem to solve the transformation matrix from the world coordinate system to the geographic coordinate system, as shown in formula (16):

[0127]

[0128] Using formula (16) we can get Convert Ow to the geographic coordinate system and output the vehicle's position coordinates in the geographic coordinate system to achieve high-precision navigation and positioning of the vehicle.

[0129] The present invention also proposes a device, including a memory and a processor, wherein: the memory is used to store a computer program that can be run on the processor; the processor is used to execute the steps of the visual navigation, surveying and positioning method based on the semantic reference library as described above when running the computer program.

[0130] The present invention also provides a storage medium having a computer program stored thereon. When the computer program is executed by at least one processor, the steps of the visual navigation, surveying and positioning method based on the semantic reference library as described above are implemented.

[0131] The present invention has carried out the sports car experiment, and the tiger claw sports car platform built is as follows Figure 5 The mapping trajectory and positioning trajectory are shown in Figure 6 As shown, the black curve is the semantic landmark reference library trajectory collected by RTK during the surveying and mapping phase, the gray curve is the true value trajectory collected by RTK during the positioning phase, and the dotted line is the positioning trajectory of the algorithm of the present invention. In the figure, the positioning trajectory of the algorithm of the present invention basically coincides with the true value trajectory. Figure 7 The positioning error curves shown in the figure show that the three-axis error curve and distance error curve of the Northeast Sky using the algorithm of the present invention fluctuate consistently within a certain range, with a maximum distance error of 9.27m and a root mean square error of 3.03m. Experiments show that the algorithm of the present invention can effectively suppress the divergence of the cumulative error of the visual odometry, achieving positioning accuracy at the meter level.

[0132] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above and that the invention can be embodied in other specific forms without departing from the spirit or essential characteristics of the invention. Therefore, the embodiments should be considered in all respects as illustrative and non-restrictive, and the scope of the invention is defined by the appended claims rather than the foregoing description, and it is intended that all variations that come within the meaning and range of equivalents of the claims be embraced therein.

Claims

1. A visual navigation surveying and positioning method based on a semantic reference library, characterized in that: The following steps are involved: (1) Based on the high-precision geographic location information and environmental image information collected by the surveying and mapping vehicle, the image semantic information is extracted through the YOLOv5s network and divided into high dynamic semantic information and high static semantic information; (2) Using dynamic feature point elimination algorithm to eliminate feature points with high dynamic semantic information; (3) Construct a semantic landmark benchmark library with geographic information based on highly static semantic information; (4) Based on the image semantic information and camera pose T w c is matched with the semantic landmark benchmark library; (5) The semantic category of the current frame is consistent with that of the semantic landmark frame, and the semantic image frame coordinate deviation and Euclidean distance meet the set threshold, which means the match is successful. Then, the accumulated error of the visual odometer is corrected through the pose optimization algorithm to obtain the accurate camera pose. (6) Output the high-precision geographic coordinates of the vehicle through coordinate system transformation.

2. The method for visual navigation, surveying and positioning based on a semantic reference library according to claim 1, characterized in that: The implementation process of step (1) is as follows: The surveying and mapping vehicle collects its own high-precision geographic location information through the RTK device. The information includes the vehicle's longitude, latitude, altitude and the time of collection. The surveying and mapping vehicle collects environmental image information through the front binocular camera, including the collected left and right eye images and the collection time. The image-specified semantic information is extracted through the YOLOv5s network. The semantic information includes semantic categories and semantic pixel frame coordinates. The semantic information is divided into high-dynamic semantics and high-static semantics. The high-dynamic semantics include people and vehicles. The high-static semantics include street lights and traffic landmarks, which are used to build a semantic road sign benchmark library.

3. The method for visual navigation, surveying and positioning based on a semantic reference library according to claim 1, characterized in that: The implementation process of step (2) is as follows: The feature points inside the human pixel frame are directly eliminated, and the dynamic and static state of the vehicle are further judged based on the optical flow algorithm; Track feature points through optical flow algorithm to obtain matching feature points of previous and next frames; Calculate the average pixel deviation of matching feature points between two frames: Where pixd is the average pixel deviation, (u 1t ,v 1t ) is the pixel coordinate of the tth feature point in the current frame, (u 2t ,v 2t ) is the coordinate of the matching point in the previous frame, and N is the total number of successfully matched feature points; Traverse the depth of feature points inside the vehicle detection frame and calculate the average depth as the distance between the vehicle and the camera: Among them, dep is the distance between the vehicle and the camera, m is the number of feature points inside the detection frame, and d i is the depth value of the i-th feature point; Traverse the feature points inside the vehicle detection frame. If they satisfy equation (4), they are considered dynamic feature points. If not, they are static feature points. Calculate the ratio of the dynamic feature points of the vehicle detection frame to the total number of feature points in the frame. If it is greater than the set threshold Th, the vehicle is considered to be a dynamic vehicle and the feature points are removed. Otherwise, it is a static vehicle and the feature points are retained: Among them, c_pix i is the absolute value of the difference between the pixel offset of the ith matching feature point in the vehicle detection frame and the average pixel offset, and Y is the set threshold.

4. The method for visual navigation, surveying and positioning based on a semantic reference library according to claim 1, characterized in that: The implementation process of step (3) is as follows: The timestamp is used to associate the camera pose and the northeast celestial coordinates of the vehicle to give the current frame real geographic information, and the YOLOv5s network is used to identify high static semantics and extract the corresponding semantic information Sem j =(n j ,l j ,t j ,r j ,b j ),j=1,2,3,....m, m is the number of semantics contained in the current frame, n j is the semantic category, l j is the left boundary coordinate value of the semantic pixel box, t j is the coordinate value of the upper boundary of the semantic pixel box, r j is the coordinate value of the right edge of the semantic pixel box, b j is the coordinate value of the lower boundary of the semantic pixel frame, which gives semantic information to the current frame; the coordinates of the semantic pixel frame and the pixel coordinates of the image frame are based on the pixel coordinate system; according to the camera pose of each frame Geographical coordinates i and the semantic information contained in the current frame {Sem1, Sem2, …, Sem m }Build a semantic landmark benchmark library with geographic information.

5. The method for visual navigation, surveying and positioning based on a semantic reference library according to claim 1, characterized in that: The implementation process of step (4) is as follows: During the positioning phase, the vehicle-mounted front binocular camera is used to obtain real-time environmental image information, and the image information is input into the visual SLAM system to obtain the current camera position. Input YOLOv5s network to obtain pixel semantic information, {Sem'1, Sem'2, ..., Sem' w },Sem' o =(n' o ,l' o ,t' o ,r′ o ,b' o ),o=1,2,3,…,w; The specific steps of semantic landmark frame matching algorithm are as follows: Eliminate semantic landmark frames in the semantic landmark benchmark library that do not correspond to the semantic category and semantic quantity of the current frame; and semantic landmark frame pose Get and In the semantic landmark benchmark library, the semantic landmark frames that satisfy equation (5) are brute-force retrieved as candidate semantic landmark matching frames {l a1 ,l a2 ,l a3 ,…,l ak }: Where dis_p is the set distance threshold; let l ai , i=1,2,3,…,k frames correspond to the semantic information {Sem1,Sem2,…,Sem w },Sem j =(n j ,l j ,t j ,r j ,b j ),j=1,2,3,…,w), retrieve {l a1 ,l a2 ,l a3 ,…,l ak } and the current frame semantic information {Sem'1, Sem'2, ..., Sem' w },Sem' j =(n' j ,l' j ,t' j ,r′ j ,b' j ),j=1,2,3,…,w, the semantic landmark frames satisfying equation (6) are taken as the final candidate semantic landmark matching frames {l b1 ,l b2 ,l b3 ,…,l bk }: Where pfe is the set pixel frame deviation threshold; retrieval {l b1 ,l b2 ,l b3 ,…,l bk The semantic landmark frame closest to the current frame in the} is taken as the semantic landmark matching frame l that matches successfully. s , the semantic landmark matching frame pose is The geographical coordinates are E s =(x s ,y s ,z s ) T .

6. The method for visual navigation, surveying and positioning based on a semantic reference library according to claim 1, characterized in that: The implementation process of step (5) is as follows: Through the semantic landmark frame matching algorithm, the semantic landmark matching frame l in the semantic landmark benchmark library is retrieved. s , the posture is The camera pose of the current frame is If the distance between the two is greater than the threshold dis_d, the cumulative error of the camera pose inferred by the visual odometer is large. The semantic landmark matching frame pose is directly assigned to the current frame, and the current frame is used as the first frame to initialize the visual odometer and significantly correct the cumulative error. If the distance between the two frames is less than the threshold dis_d, the key frame pose and map point coordinates are slightly corrected through the designed improved bundle adjustment method. The specific steps are as follows: Construct the reprojection observation equation and record the i-th map point as The matching pixel coordinates are is the coordinate of the feature point in the left figure, is the horizontal coordinate of the feature point in the right image, and the camera pose in the current frame is By using formula (7), the map points Convert from the world coordinate system to the camera coordinate system, and use the camera intrinsic parameter matrix K according to the pinhole imaging principle Projected to the pixel coordinate system as shown in formula (8), and the coordinate constraints of the feature points on the left and right are constructed according to the binocular model Where b is the camera baseline; Construct the reprojection observation equation based on the pinhole camera model and the binocular model: Among them, F s is the constraint function, ω x,i is the noise, Σ x,i is the covariance matrix; The semantic landmark matching frame pose is The corresponding translation vector is The current frame pose is The corresponding translation vector is The semantic landmark matching frame pose is used to constrain the current frame pose and construct the semantic landmark matching frame observation equation: Among them, v S is the noise, Σ SEM_L is the covariance matrix; On the basis of the classic bundle adjustment method, a new error term is introduced to optimize the camera pose and map point coordinates and construct the objective function: Among them, E per (x,i) is the error term constructed based on the reprojection error, E Ser (s,k) is the error term constructed based on the semantic landmark matching frame, ρ, ρ s is a robust kernel function, which is used to weaken the influence of poor quality error edges on the optimization results and make the optimization algorithm more robust; L is the map point set, K L is a local keyframe set, K s is a key frame with a corresponding semantic landmark matching frame, T s is a set of semantic landmark frames, where there are observation constraints between map points and key frames, K s With T s There are observation constraints between them; Σ, Σ SEM_L They are respectively the covariance matrix of the reprojection error term and the covariance matrix of the semantic landmark frame error term added by the present invention, representing the estimation of the accuracy of each constraint.

7. The method for visual navigation, surveying and positioning based on a semantic reference library according to claim 1, characterized in that: The implementation process of step (6) is as follows: For accurate camera pose Find the coordinates of the current vehicle in the world coordinate system: According to the current vehicle coordinates Ow, the semantic landmark frames closest to the vehicle position are searched in the semantic landmark reference library, and the set P = {p1, p2, ..., p n }, and construct a set D = {d1, d2, ..., d n }, and finally construct a least squares problem to solve the transformation matrix from the world coordinate system to the geographic coordinate system: Using formula (16) we can get Convert Ow to the geographic coordinate system and output the vehicle's position coordinates in the geographic coordinate system to achieve high-precision navigation and positioning of the vehicle.

8. A device, characterized in that: comprising a memory and a processor, wherein: A memory for storing computer programs that can be run on the processor; A processor is used to execute the steps of the visual navigation, surveying and positioning method based on a semantic reference library as described in any one of claims 1 to 7 when running the computer program.

9. A storage medium, characterized in that: The storage medium stores a computer program, which, when executed by at least one processor, implements the steps of the visual navigation, surveying and positioning method based on a semantic reference library as described in any one of claims 1 to 8.

Citation Information

Patent Citations

  • Dynamic scene-oriented point-line fusion semantic SLAM (Simultaneous Localization and Mapping) method

    CN114283199A

  • Visual surveying and mapping navigation positioning method based on lightweight point cloud map

    CN116839600A

  • Automatic safe-landing-site selection for unmanned aerial systems

    US20220121836A1

  • Visual slam method applicable to indoor dynamic environment

    WO2022041596A1

Cited By

  • Visual odometer positioning correction method based on environmental object as semantic road sign

    CN119904519A

  • A visual odometry positioning correction method based on environmental objects as semantic landmarks

    CN119904519B

  • Dynamic environment rapid positioning method and system based on visual odometer

    CN121564680A

  • Semantic label information-based positioning error correction method and device, and storage medium

    CN121632206A