An aerial visual navigation positioning method based on semantic topological feature matching
By constructing an aviation visual navigation and positioning method based on semantic topological features, and utilizing the relative distance ratio, angle difference, and semantic labels of visual reference objects, combined with semantic segmentation and centroid calculation, the problems of large storage requirements and unstable accuracy in aviation visual navigation are solved, achieving efficient and accurate navigation and positioning.
Patent Information
- Application Number
- CN202411084909.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-08
- Publication Date
- 2026-11-24
- Estimated Expiration
- 2044-08-08
AI Technical Summary
Existing scene matching methods require a large amount of storage space in aerial visual navigation, and changes in scale, orientation, and illumination have a significant impact on matching accuracy, resulting in insufficient robustness.
A semantic topology feature matching method is adopted. By calculating the relative distance ratio, angle difference and digital semantic labels of visual reference objects in the image, a high-level semantic topology relation feature vector is constructed. Combined with semantic segmentation and centroid calculation, efficient matching navigation and positioning is performed.
It significantly reduces storage requirements, improves matching accuracy and robustness, enables precise navigation and positioning in complex environments, and reduces the impact of scale, orientation, and lighting variations.
Smart Images

Figure CN118864906B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of aerial visual navigation scene matching technology, specifically relating to an aerial visual navigation positioning method based on semantic topological feature matching. Background Technology
[0002] Existing scene matching methods typically employ image matching based on features such as points, lines, and regions. While performing well in many scenarios, the image databases used for matching require substantial storage space, impacting the practicality of scene matching. Furthermore, changes in scale, orientation, and illumination during the matching process can significantly affect matching accuracy. To achieve a more reliable visual navigation system, a more robust scene matching technique is needed. Summary of the Invention
[0003] The purpose of this invention is to provide an aviation visual navigation and positioning method based on semantic topological feature matching. This method uses the semantic and topological structural relationship features of visual reference objects in an applied image for association searching, thus solving the problems existing in current aviation navigation and positioning technologies.
[0004] The implementation process of this invention is as follows: An aviation visual navigation and localization method based on semantic topological feature matching includes the following steps: (1) Design of high-level semantic topological relation feature vectors: A high-level semantic topological relationship feature vector is constructed by calculating the relative distance ratio, angle difference, and digital semantic labels between the lines connecting each visual reference object in the image and the image center point. The vector structure is shown in Equation 1.1. (1.1) In the formula The set representing distance ratios, The set representing the normalized angle difference, A collection representing digital semantic tag information; (2) Extraction of high-level semantic topological relation feature vectors: Advanced semantic topological relation feature vectors are extracted through semantic segmentation, centroid calculation, and feature vector calculation. (3) Matching, navigation, and localization are performed based on the extracted high-level semantic topological relation feature vectors: By comparing route images with high-level semantic topological relationship feature vectors in a pre-generated benchmark database, the most similar database image is found to achieve aerial visual navigation and positioning.
[0005] Furthermore, the method for constructing the set of distance ratios mentioned in step (1) includes the following steps: (S1) First, select the center M of the image as the center of the entire aerial image, and calculate the distance of the center of gravity of each visual reference object in the image from the center point. Select several visual reference objects that are closest to the center point as matching objects and fix the number of reference objects. (S2) Compare the distances of each visual reference object to the center with the distances of the selected visual reference objects that are farthest from the center. , , ... Thus, the set of original distance ratios between each visual reference object and the center is obtained. ,Right now (1.2); (S3) For several selected visual references, calculate their respective pixel coordinates. Then, calculate the angle between the line connecting these coordinates and the center point of the image and the positive direction of the X-axis of the image. For negative angle values in the calculation results, convert them into positive values in the range of 0° to 360° by adding 360° for subsequent processing. (S4) Sort the elements in the distance ratio set in ascending order based on the calculated angle values; (S5) Identify the index value corresponding to the visual reference object farthest from the center. By cyclically shifting the set of index values, place the distance ratio index value corresponding to the farthest visual reference object at the first position to obtain the sorted set of index values. ; (S6) Based on the sorted set of index values For the original distance ratio set Reorder the distance ratios to obtain a new set. .
[0006] Furthermore, the method for constructing the set of angle differences mentioned in step (1) includes the following steps: (SI) First, select the center point M of the aerial image and calculate the angle between the line connecting these coordinates and the center point of the image and the positive direction of the X-axis of the image; (SII) The set of index values obtained through step (S5) The original set of angles was reordered to obtain a new set of angles arranged in clockwise order, starting from the farthest visual reference. Then, the angle difference between each adjacent line was calculated sequentially. ,Right now (1.3); (SIII) By normalizing the angle differences, the ratio of each angle difference to the maximum angle difference is used as a matching element to obtain a set of normalized angle differences. ,Right now (1.4).
[0007] Furthermore, the method for constructing the set of digital semantic tag information in step (1) includes the following steps: (Si) For each visual reference, its semantic type label will be added as an additional feature to the matching feature vector. When matching, not only the spatial configuration of the visual references, but also the type of the visual references must be considered. (Sii) Digitizes semantic type labels, with each label having a value range of 0-1; (Siii) The set of index values obtained through step (S5) The original set of labels was reordered to obtain a new set of labels arranged in a clockwise order, starting from the farthest visual reference. .
[0008] Furthermore, the semantic segmentation process described in step (2) includes the following steps: (A1) Input the route image into the trained semantic segmentation model to obtain the classification result for each pixel; (A2) Binarize the image based on the classification results to separate the flight path area from the background area; (A3) The binarized image is further processed through morphological operations to remove noise and interference, resulting in accurate route segmentation results, and different labels are assigned to different types of visual reference objects.
[0009] Furthermore, the process of calculating the centroid in step (2) includes the following steps: (AI) takes the image after semantic segmentation of the aerial image as input, and then converts the image from the common RGB color space to the HSV color space.
[0010] (AII) Based on the different color labels of each designed visual reference object, set different HSV ranges to select the appropriate type of visual reference object to match; (AIII) Use OpenCV's InRange function to create a mask for the color range, call the findContours function based on the mask to find the contours of the image in the HSV space, and then call the ContourArea function to calculate the area of the contours and apply an area threshold to filter out contours that are too small. (AIV) After obtaining the contours that meet the conditions, the OpenCV moments function is used to calculate the moments of each contour. The moment information is used to calculate the centroid of the contours that meet the requirements and obtain their pixel coordinates on the aerial image.
[0011] Furthermore, the process of calculating the feature vector in step (2) is to calculate the high-level semantic topological relation feature vector according to the formula (1.1) constructed in step (1).
[0012] Furthermore, the most similar database image mentioned in step (3) is obtained by calculating the Euclidean distance between the high-level semantic topological relation feature vector of the image to be matched and the high-level semantic topological relation feature vectors of all database images, and selecting the database image with the smallest Euclidean distance as the matching result. (B1) For two points A and B in n-dimensional space, where the coordinates of point A are (x1, x2, ..., x...), n The coordinates of point B are (y1, y2, ..., y). n The Euclidean distance d(A, B) can be calculated using Equation 1.5.
[0013] (1.5) Formula (1.5) calculates the straight-line distance between two points in n-dimensional space, which can directly reflect the similarity between two feature vectors of different high-level semantic topological relationships. Finally, the algorithm outputs the database image with the smallest Euclidean distance to the image to be matched as the matching result. (B2) introduces a maximum distance threshold to distinguish between true matches and false matches. That is, a maximum distance threshold is set. When the Euclidean distance between two high-level semantic topology relation feature vectors is less than the threshold, they are considered to be a successful match; otherwise, they are considered to be a failed match.
[0014] Furthermore, the step (B2) of integrating the maximum distance threshold into the matching algorithm is as follows: (BI) Calculate Euclidean distance: Calculate the Euclidean distance between the high-level semantic topological relation feature vector of the image to be matched and the high-level semantic topological relation feature vector of each image in the database; (BII) Find the minimum distance: Find the minimum value among all calculated Euclidean distances. This value represents the highest similarity between the image to be matched and an image in the database. (BIII) Apply the maximum distance threshold: Set a maximum distance threshold. If the minimum Euclidean distance is less than or equal to this threshold, it is considered that a matching image has been found, and the image and its corresponding geographic coordinates are output as the matching result. If the minimum Euclidean distance is greater than the threshold, it is considered that no matching image has been found, and the matching is considered to have failed.
[0015] The positive effects of this invention: (1) In view of the robustness, real-time performance and limited computer resource requirements of feature extraction for aerial visual navigation and positioning, the present invention proposes a method to extract advanced features from aerial images and map databases. That is, semantic segmentation technology is used to extract obvious visual reference marks in aerial images, and advanced feature matching is performed by using the topological positional relationship between visual reference marks, thereby locating the position of the aircraft itself.
[0016] (2) The method of the present invention simplifies the image-based localization problem into a topological relationship feature matching problem, thereby significantly reducing the impact of changes in scale, orientation and lighting on matching accuracy, and further improving the accuracy and robustness of matching.
[0017] (3) The method of the present invention combines semantic segmentation and topological relationship feature matching, which can not only achieve accurate understanding of complex environments, but also provide more reliable and stable results in scene matching.
[0018] (4) The method of the present invention uses a high-level feature vector of the storage reference image, which is one-thousandth of the original storage method, and achieves a significant reduction in storage volume. Attached Figure Description
[0019] Figure 1 A schematic diagram showing the distance ratios between various visual reference objects; Figure 2 A schematic diagram showing the angular differences between various visual reference objects; Figure 3 A diagram illustrating the classification of different types of visual reference objects; Figure 4 The images are semantically segmented; where a is the original image from the database, and b is the semantically segmented image. Figure 5 Here is a flowchart of the centroid calculation method; Figure 6 This is a diagram showing the results of the centroid calculation; where a is... Figure 4 b is the image after semantic segmentation algorithm. b is the result of the centroid calculation method for the three types of visual reference objects, namely "buildings", "bare land" and "rivers", when the image is fed into the centroid calculation method. The black dots represent the centroids of different contours. Figure 7 This is a schematic diagram of semantic topological feature matching; Figure 8 The images to be matched are the original images and the images after semantic segmentation. Figure 9 The final output image for each image; Figure 10 Images transformed at different scales; Figure 11Minimum Euclidean distance maps for matching at different scales; Figure 12 These are images obtained by transforming the original label image from different angles; Figure 13 This is a minimum Euclidean distance graph for matching at different angles. Detailed Implementation
[0020] The present invention will be further described below with reference to the embodiments. Example
[0021] The method of this invention mainly includes three parts: the first part is the design of high-level semantic topological relation feature vectors; the second part is the method for extracting high-level semantic topological relation feature vectors; and the third part is the method for matching, navigation and positioning based on the extracted high-level semantic topological relation feature vectors.
[0022] 1. Advanced Feature Vector Design for Semantic Topological Relationships To meet the requirements of scale invariance, rotation invariance, and semantic recognition, this invention selects the distance ratio, angle difference, and digital semantic labels between visual reference objects in the image to construct a high-level semantic topological relationship feature vector, the vector structure of which is shown in Equation 1.1.
[0023] (1.1) In the formula The set representing distance ratios, The set representing the normalized angle difference, A collection representing digital semantic tag information.
[0024] 1) Distance ratio To address the scale invariance requirement in matching algorithms, this invention characterizes the configuration information of visual references by calculating the relative distance ratio between each visual reference and the image center point. The key advantage of this method is that the relative distance ratio between visual references remains constant regardless of image scale changes, thus ensuring the robustness of the extracted features to scale variations in the target object's configuration information.
[0025] like Figure 1 As shown in the figure, the red pentagrams represent the positions of various visual reference objects. First, the center M of the image is selected as the center of the entire aerial image. Then, the distance of the centroid of each visual reference object in the image from the center point is determined by calculation. Several visual reference objects closest to the center point are selected as matching objects. The number of reference objects is fixed to reduce the matching error introduced by the change in the number of visual reference objects in the image due to scale changes.
[0026] Visual reference objects within a certain distance from the center are selected as matching objects. The distance of each visual reference object from the center is compared with the distance of the farthest visual reference object from the center among the selected visual reference objects. , , ... This yields the set of distance ratios between each visual reference object and the center. ,Right now (1.2) However, because the storage order of visual reference information may differ in different image processing flows, even the same image may produce distance ratio sets with identical elements but different arrangement orders. This difference in arrangement order can lead to inaccuracies in the matching process. To address this issue, this invention defines a clear rule for ordering the elements within the set, ensuring that for the same image, the same distance ratio set can be obtained even if the visual reference information is processed in different orders.
[0027] ① For a set of selected visual references, calculate their respective pixel coordinates. Then, calculate the angle between the line connecting these coordinates and the image center point and the positive X-axis of the image. For negative angle values in the calculation results, convert them to positive values within the range of 0° to 360° by adding 360° for subsequent processing.
[0028] ② Based on the calculated angle values, the element indices in the distance ratio set are sorted in ascending order. This step ensures that the visual references are arranged in a clockwise direction, thus providing a unified order for subsequent matching. However, at this point, the first element in the sorted set is the visual reference with the smallest angle to the X-axis, which is not uniquely determined for images with different rotation angles.
[0029] ③ Identify the index value corresponding to the visual reference object farthest from the center. This index value is crucial in the sorting process because it determines that the sorted set starts from the farthest point. By cyclically shifting the set of index values, the distance ratio index value corresponding to the farthest visual reference object is placed first.
[0030] ④ Based on the sorted set of index values For the original distance ratio set Reorder the distance ratios to obtain a new set. .
[0031] Through the above four steps, the matching visual references were successfully sorted, resulting in a new set of distance ratios arranged in clockwise order, starting from the farthest visual reference. This method provides a unified sorting rule, facilitating subsequent analysis and comparison.
[0032] (2) Angle difference To address the rotation invariance requirement in matching algorithms, this invention characterizes the configuration information of visual references by calculating the angular differences between the lines connecting each visual reference to the image center. The key advantage of this method is that the angular differences between the lines connecting the visual references to the image center remain constant regardless of changes in the image angle, thus ensuring the robustness of the extracted features to rotational changes in the target object's configuration information.
[0033] like Figure 2 As shown, first, the center point M of the aerial image is selected, and the angle between the line connecting these coordinates to the image center point and the positive X-axis of the image is calculated. This is done using the index value set obtained earlier. The original set of angles was reordered to obtain a new set of angles arranged in clockwise order, starting from the farthest visual reference. Then, the angle difference between each adjacent line was calculated sequentially. ,Right now (1.3) During the calculation, be sure to calculate the angle difference between the last point and the first point and add the angle difference to the list.
[0034] For different visual references in the image, the set of angles between them and the center line is calculated as a second matching element. Since the distance value is smaller than that used as a matching element, it is more suitable for... In general, the weight of the angle difference influencing the matching result is much greater than that of the distance ratio. This invention normalizes the angle difference and uses the ratio of each angle difference to the maximum angle difference as the matching element according to the formula. (1.4) (3) Digital semantic tags Since different types of visual references may have similar distance ratios and angular differences, relying solely on these geometric features can lead to incorrect matching. Therefore, visual reference label information is introduced into the high-level semantic topological relation feature vector for visual reference matching. This helps distinguish visual references with similar geometric features but different actual types, thereby reducing matching errors. Specifically, for each visual reference, its semantic type label is added as an additional feature to the matching feature vector. In this way, during matching, the algorithm considers not only the spatial configuration of visual references but also their type, thus improving matching accuracy.
[0035] Because there are many types of visual references in the image, and some types of visual references are too large to be used as matching objects, three types of visual references—"buildings," "bare land," and "rivers"—were selected as targets for centroid calculation. Different numbers were used to represent different visual reference labels: 1 for "buildings," 2 for "rivers," and 3 for "bare land." To ensure that the weights of each element are equal during the matching process, the digital semantic labels need to be normalized to generate a set of labels with values between 0 and 1. For example, "buildings" was assigned a value of 1 / 3, "rivers" was assigned a value of 2 / 3, and "bare land" was assigned a value of 1.
[0036] like Figure 3 The image shows a classification diagram of different types of visual reference objects. Different colored blocks are used to represent different visual reference objects in the scene. Red blocks represent houses, purple blocks represent bare land, blue blocks represent rivers and waterways, green blocks represent woodlands, dark blue blocks represent farmland, and black blocks represent others.
[0037] Using the set of index values obtained above The original set of labels was reordered to obtain a new set of labels arranged in a clockwise order, starting from the farthest visual reference. .
[0038] 2. Methods for Extracting Feature Vectors of High-Level Semantic Topological Relations (1) Semantic segmentation Since the distance ratio and angle difference in the high-level semantic topology feature vector need to be obtained from the coordinates of the visual reference, and since the high-level semantic topology feature vector contains the element of digital semantic labels, semantic segmentation is a key step in route visual navigation, used to accurately segment different objects in route images.
[0039] First, the flight path image is input into a trained semantic segmentation model to obtain the classification result for each pixel. Then, the image is binarized based on the classification results to separate the flight path region from the background region. Finally, morphological operations are used to further process the binarized image to remove noise and interference, resulting in accurate flight path segmentation results, and different labels are assigned to different visual reference types.
[0040] The final semantic segmentation result is as follows: Figure 4 As shown, Figure a is the original image from the database, and Figure b is the image after semantic segmentation. Different colored blocks are used in the image to represent different visual references in the scene. Red blocks represent houses, purple blocks represent bare land, blue blocks represent rivers and waterways, green blocks represent woodlands, and dark blue blocks represent farmland.
[0041] By performing semantic segmentation on flight path images, it is possible to accurately distinguish and identify different visual references in the images, such as mountains, buildings, roads, lakes, etc., and each visual reference is assigned a specific pixel-level classification label.
[0042] (2) Calculation of the center of gravity In the semantic segmentation and classification results, each visual reference object is not only assigned a category label, but its shape, size, boundary, and other features are also clearly presented. These shape features are crucial for understanding and analyzing the spatial layout, distribution patterns, and relationship of visual reference objects with flight paths.
[0043] To further utilize these shape features, this invention employs a centroid calculation method. A block diagram of the centroid calculation method is shown below. Figure 5 As shown, the input of the entire algorithm is the aerial image after semantic segmentation, and the output is the centroid position of different visual reference objects that meet certain requirements and their pixel coordinates on the aerial image.
[0044] The specific process is as follows: The image, after semantic segmentation of the aerial photograph, is used as input. The image is then converted from the common RGB color space to the HSV color space. This is to better adapt to the color feature extraction and processing requirements of different visual reference types. Based on the different color labels of each designed visual reference, different HSV ranges are set to select suitable visual reference types for matching. A reasonable area threshold is set to filter out contours that are too small or do not meet the requirements. The OpenCV `InRange` function is used to create a mask for this color range. Based on the mask, the `findContours` function is called to find the contours of the image in the HSV space. Then, the `ContourArea` function is called to calculate the area of the contours and apply the area threshold to filter out contours that are too small. After obtaining the contours that meet the conditions, the OpenCV `cv2.moments()` function is used to calculate the moments of each contour. Finally, the algorithm uses this moment information to calculate the centroid of the contours that meet the requirements and obtain their pixel coordinates on the aerial photograph.
[0045] like Figure 6 As shown, Figure a is Figure 4 Image b is the result of semantic segmentation algorithm. Image b shows the result of center of gravity calculation for three types of visual references, namely "buildings", "bare land" and "rivers", when fed into the center of gravity calculation method. The black dots represent the center of gravity of different contours.
[0046] After processing using the centroid calculation method, the centroid coordinates of specific visual references such as "buildings," "bare ground," and "water flow" can be obtained for each aerial image. These coordinates not only provide the positional information of the visual references in the image, but also allow for the calculation of the relative distance or direction between two visual references using only their centroid coordinates, without considering the specific shape or boundaries of the visual references. This greatly reduces the difficulty of extracting the positional configuration information of visual references.
[0047] (3) Calculation of eigenvectors The set of distance ratios and the set of angle differences are calculated according to formulas (1.2)-(1.4) in "Semantic Topological Relationship Advanced Feature Vector Design". The set of digital semantic labels is obtained according to the method of "(3) Digital Semantic Labels" in "Semantic Topological Relationship Advanced Feature Vector Design". The advanced semantic topological relationship feature vector is calculated according to formula (1.1).
[0048] 3. Matching navigation and positioning methods The algorithm finds the most similar database image by comparing route images with high-level semantic topological relationship feature vectors in a pre-generated benchmark database.
[0049] Figure 7 For the matching illustration, the black dot in the image represents the center of a fixed visual reference. The location of the object in the image is compared with the object configuration information in the map database, using this point to represent the position of the visual reference. During the matching process, the location of the aircraft is obtained by searching the database for the corresponding image most similar to the observed high-level feature vector.
[0050] To find the database image most similar to the image to be matched, it is necessary to calculate the Euclidean distance between the high-level semantic topological relation feature vector of the image to be matched and the high-level semantic topological relation feature vectors of all database images, and select the database image with the smallest Euclidean distance as the matching result.
[0051] For two points A and B in n-dimensional space, where the coordinates of point A are (x1, x2, ..., xn) and the coordinates of point B are (y1, y2, ..., yn), the Euclidean distance d(A, B) can be calculated using Equation 1.5. (1.5) This formula calculates the straight-line distance between two points in n-dimensional space, which in this invention directly reflects the similarity between two feature vectors of different high-level semantic topological relationships. Finally, the algorithm outputs the database image with the smallest Euclidean distance to the image to be matched as the matching result.
[0052] This invention introduces a maximum distance threshold to distinguish between true matches and false matches. Specifically, a maximum distance threshold is set; if the Euclidean distance between two high-level semantic topological relation feature vectors is less than this threshold, they are considered a successful match; otherwise, they are considered a failed match. The following are the steps for integrating the maximum distance threshold into the matching algorithm.
[0053] (1) Calculate the Euclidean distance: First, calculate the Euclidean distance between the high-level semantic topological relation feature vector of the image to be matched and the high-level semantic topological relation feature vector of each image in the database.
[0054] (2) Find the minimum distance: Find the minimum value among all the calculated Euclidean distances. This value represents the highest similarity between the image to be matched and an image in the database.
[0055] (3) Applying a maximum distance threshold: A maximum distance threshold is set. If the minimum Euclidean distance is less than or equal to this threshold, a matching image is considered to have been found, and the image and its corresponding geographic coordinates are output as the matching result. If the minimum Euclidean distance is greater than the threshold, no matching image is considered to have been found, i.e., the matching fails. By adding a maximum distance threshold, false matching caused by various factors can be effectively avoided, thus improving the robustness of the algorithm.
[0056] To verify the algorithm's ability to perform matching well, three images were selected from the database, their high-level semantic topological relation feature vectors were extracted, and Euclidean distance was calculated between these vectors and the high-level semantic topological relation feature vectors in the database to obtain the final matching results. Figure 8 As shown, Figures a, b, and c are the original images of 0_1400.png, 5950_2100.png, and 3150_3150.png, respectively, while d, e, and f are the images after semantic segmentation. These three images are used as the images to be matched.
[0057] These three images each contain three types of visual references for matching, with varying sparsity, size, and number of references, effectively representing different distribution scenarios. The images to be matched are fed into the algorithm to obtain high-level semantic topological relation feature vectors from the aerial images. These vectors are then compared with 276 high-level semantic topological relation feature vectors from the database images using Euclidean distance calculations. The final output matching results are shown below. Figure 9 As shown in the figure. Figure a shows the matching results for 0_1400.png, Figure b shows the matching results for 5950_2100.png, and Figure c shows the matching results for 3150_3150.png.
[0058] The matching results of the three images 0_1400.png, 5950_2100.png, and 3150_3150.png are shown in Tables 1, 2, and 3, respectively.
[0059] (1) Output matching results for 0_1400.png: Table 1. Figure a outputs the matching results. High-level semantic topological relation feature vector [ [1.000000 0.925630 0.001234 0.716060 0.732092 0.165848 0.342144 0.3437560.033705 0.380274][0.073462 0.026459 0.013638 0.305121 0.399297 1.000000 0.3177410.338328 0.454024 0.024538][0.333333 1.000000 0.333333 1.000000 0.666667 0.3333330.333333 1.000000 1.000000 1.000000] ] Matching results 0_1400.png Euclidean distance 0.0 Position coordinates (640,2040) Confidence 1.0 (2) Output matching results for 5950_2100.png: Table 2. Figure b shows the output matching results. High-level semantic topological relation feature vector [ [1.000000 0.184404 0.411843 0.352495 0.086955 0.291872 0.927204 0.0410380.627555 0.159472][0.227083 0.487791 0.274062 0.371198 0.394118 1.000000 0.2545010.496597 0.472215 0.187912][0.333333 0.333333 1.000000 0.333333 1.000000 0.3333330.333333 0.333333 1.000000 0.333333] ] Matching results 5950_2100.png Euclidean distance 0.0 Position coordinates (6590,2740) Confidence 1.0 (3) Output matching results for 3150_3150.png: Table 3, Figure c, outputs the matching results. High-level semantic topological relation feature vector [ [1.000000 0.247319 0.05641 0.12042 0.470764 0.292487 0.816305 0 0 0][0.6251640.393803 0.61707 0.511061 1.000000 0.079733 0.045671 0 0 0][0.666667 0.3333330.666667 0.666667 1.000000 0.333333 1.000000 0 0 0] ] Matching results 3150_3150.png Euclidean distance 0.0 Position coordinates (3790,3790) Confidence 1.0 In the above experiment, to verify the matching performance of the algorithm, three images were randomly selected from the database as aerial images, and pattern matching experiments were conducted. The final result showed that the Euclidean distance was almost 0, while the Euclidean distances to other images differed significantly. Furthermore, the final output image matched the input image, indicating that the matching result was very accurate. This result demonstrates that, under ideal conditions such as image center, constant scale, and constant angle, the studied pattern matching algorithm can achieve near-perfect matching.
[0060] To verify the scale invariance of the pattern matching algorithm used in this paper, a reference image from the database was randomly selected and subjected to a series of scale transformations. The image was enlarged or reduced by a factor of 2, 1.8, 1.5, 1.2, 0.8, 0.75, 0.65, 0.6, and 0.5 respectively, generating nine images at different scales.
[0061] For each transformed image, its high-level semantic topological relation feature vector is extracted, and Euclidean distance is calculated between it and the high-level semantic topological relation feature vectors in the database. For example... Figure 10 In the image, images a, b, c, d, e, f, g, h, and i are generated by enlarging or reducing the view radius of 5950_2100.png by 2, 1.8, 1.5, 1.2, 0.8, 0.75, 0.65, 0.6, and 0.5 times, respectively.
[0062] Label images at different scales were fed into the pattern matching system, and the matching results are shown in Table 4.
[0063] Table 4 Matching results at different scales Scale of Change 2 1.8 1.5 1.2 1 Minimum Euclidean distance 2.6748821305944874 1.650056716062922 1.4043905616772323 0.20993225946496435 0 Matching results Match failed Match successful Match successful Match successful Match successful Confidence 0 0.17 0.30 0.90 1 Scale of Change 0.8 0.75 0.65 0.6 0.5 Minimum Euclidean distance 0.08699312191993924 0.15123916368469975 0.27665581653444293 0.30310706599847126 2.720949729968728 Matching results Match successful Match successful Match successful Match successful Match failed Confidence 0.96 0.92 0.86 0.85 0 like Figure 11The figure shows the minimum Euclidean distance for matching at different scales. As mentioned above, the smaller the distance, the closer the match. The results show that the algorithm perfectly achieves scale invariance within a certain scale range. However, beyond this range, such as when the image is enlarged by 2 times or reduced to 0.5 times its original size, the matching accuracy is significantly affected. To address the problem of inaccurate matching accuracy at excessively large scales, a larger area threshold can be set. This filters out smaller visual references while limiting the volume range of larger visual references, effectively avoiding the inaccurate matching caused by excessively large scales. To address the problem of inaccurate matching accuracy at smaller scales, the number of matching visual references can be limited, ensuring that the number of visual references involved in the matching remains constant at smaller scales, thereby improving matching accuracy.
[0064] To verify the rotation invariance of the pattern matching algorithm used in this invention, taking 5950_2100.png as an example, a series of angle transformations were performed on it to generate images at different angles. Pattern extraction and matching were then performed on each of these images.
[0065] For each transformed image, its high-level semantic topological relation feature vector is extracted and Euclidean distance is calculated between it and the high-level semantic topological relation feature vector in the database.
[0066] like Figure 12 The images shown are the original label images after being transformed by different angles. Figures a, b, c, d, e, f, g, h, i, j, k, and l are the original image of 5950_2100.png and the images after being rotated by 30, 60, 90, 120, 150, 180, 210, 240, 270, 300, and 330 degrees, respectively.
[0067] The label images at different rotation angles were fed into the pattern matching system, and the matching results are shown in Table 5.
[0068] Table 5 Matching results at different angles Rotation angle 0 30 60 90 120 150 Matching minimum Euclidean distance 0 0.031209421754695276 0.10370131341289837 0.00040361639307504856 0.05972138866546101 0.10887841406180353 Matching results Match successful Match successful Match successful Match successful Match successful Match successful Confidence 1 0.98 0.95 1 0.97 0.95 Rotation angle 180 210 240 270 300 330 Matching minimum Euclidean distance 0.0007545054911507947 0.04447321077090738 0.10018604934700073 0.0006792984145394316 0.04210090086707925 0.10775912237853719 Matching results Match successful Match successful Match successful Match successful Match successful Match successful Confidence 1 0.98 0.95 1 0.98 0.95 like Figure 13 The figure shows the minimum Euclidean distance for matching at different angles. The results show that the algorithm satisfies the scale invariance requirement well.
[0069] The method of this invention achieves a significant reduction in storage size by employing a high-level feature vector of the stored reference image, which is only one-thousandth of the original storage method.
[0070] The above description, in conjunction with specific preferred embodiments, provides a further detailed explanation of the present invention. It should not be construed that the specific implementation of the present invention is limited to these descriptions. For those skilled in the art, various simple deductions or substitutions can be made without departing from the concept of the present invention, and all such modifications and substitutions should be considered within the scope of protection of the present invention.
Claims
1. An aviation visual navigation and localization method based on semantic topological feature matching, characterized in that, Includes the following steps: (1) Design of high-level semantic topological relation feature vectors: A high-level semantic topological relationship feature vector is constructed by calculating the relative distance ratio, angle difference, and digital semantic labels between the lines connecting each visual reference object in the image and the image center point. The vector structure is shown in Equation 1.
1. (1.1) In the formula The set representing distance ratios, The set representing the normalized angle difference, A collection representing digital semantic tag information; (2) Extraction of high-level semantic topological relation feature vectors: Advanced semantic topological relation feature vectors are extracted through semantic segmentation, centroid calculation, and feature vector calculation. (3) Matching, navigation, and localization are performed based on the extracted high-level semantic topological relation feature vectors: By comparing route images with high-level semantic topological relationship feature vectors in a pre-generated benchmark database, the most similar database image is found to achieve airborne visual navigation and positioning. The method for constructing the set of distance ratios mentioned in step (1) includes the following steps: (S1) First, select the center M of the image as the center of the entire aerial image, and calculate the distance of the center of gravity of each visual reference object in the image from the center point. Select several visual reference objects that are closest to the center point as matching objects and fix the number of reference objects. (S2) Compare the distances of each visual reference object to the center with the distances of the selected visual reference objects that are farthest from the center. , , ... Thus, the set of original distance ratios between each visual reference object and the center is obtained. ,Right now (1.2); (S3) For several selected visual references, calculate their respective pixel coordinates. Then, calculate the angle between the line connecting these coordinates and the center point of the image and the positive direction of the X-axis of the image. For negative angle values in the calculation results, convert them into positive values in the range of 0° to 360° by adding 360° for subsequent processing. (S4) Sort the elements in the distance ratio set in ascending order based on the calculated angle values; (S5) Identify the index value corresponding to the visual reference object farthest from the center. By cyclically shifting the set of index values, place the distance ratio index value corresponding to the farthest visual reference object at the first position to obtain the sorted set of index values. ; (S6) Based on the sorted set of index values For the original distance ratio set Reorder the distance ratios to obtain a new set. ; The method for constructing the set of angle differences mentioned in step (1) includes the following steps: (SI) First, select the center point M of the aerial image and calculate the angle between the line connecting these coordinates and the center point of the image and the positive direction of the X-axis of the image; (SII) The set of index values obtained through step (S5) The original set of angles was reordered to obtain a new set of angles arranged in clockwise order, starting from the farthest visual reference. Then, the angle difference between each adjacent line was calculated sequentially. ,Right now (1.3); (SIII) By normalizing the angle differences, the ratio of each angle difference to the maximum angle difference is used as a matching element to obtain a set of normalized angle differences. ,Right now (1.4); The method for constructing the set of digital semantic tag information in step (1) includes the following steps: (Si) For each visual reference, its semantic type label will be added as an additional feature to the matching feature vector. When matching, not only the spatial configuration of the visual references, but also the type of the visual references must be considered. (Sii) Digitizes semantic type labels, with each label having a value range of 0-1; (Siii) The set of index values obtained through step (S5) The original set of labels was reordered to obtain a new set of labels arranged in a clockwise order, starting from the farthest visual reference. .
2. The method according to claim 1, characterized in that: The semantic segmentation process described in step (2) includes the following steps: (A1) Input the route image into the trained semantic segmentation model to obtain the classification result for each pixel; (A2) Binarize the image based on the classification results to separate the flight path area from the background area; (A3) The binarized image is further processed through morphological operations to remove noise and interference, resulting in accurate route segmentation results, and different labels are assigned to different types of visual reference objects.
3. The method according to claim 1, characterized in that: The process of calculating the center of gravity in step (2) includes the following steps: (AI) takes the image after semantic segmentation of the aerial image as input, and then converts the image from the common RGB color space to the HSV color space; (AII) Based on the different color labels of each designed visual reference object, set different HSV ranges to select the appropriate type of visual reference object to match; (AIII) Use OpenCV's InRange function to create a mask for the HSV range, call the findContours function based on the mask to find the contours of the image in the HSV space, and then call the ContourArea function to calculate the area of the contours and apply an area threshold to filter out contours that are too small. (AIV) After obtaining the contours that meet the conditions, the OpenCV moments function is used to calculate the moments of each contour. The moment information is used to calculate the centroid of the contours that meet the requirements and obtain their pixel coordinates on the aerial image.
4. The method according to claim 1, characterized in that: The process of calculating the feature vector in step (2) is to calculate the high-level semantic topological relation feature vector according to the formula (1.1) constructed in step (1).
5. The method according to claim 1, characterized in that: The most similar database image mentioned in step (3) is obtained by calculating the Euclidean distance between the high-level semantic topological relation feature vector of the image to be matched and the high-level semantic topological relation feature vectors of all database images, and selecting the database image with the smallest Euclidean distance as the matching result; (B1) For two points A and B in n-dimensional space, where the coordinates of point A are (x1, x2, ..., x...), n The coordinates of point B are (y1, y2, ..., y). n The Euclidean distance d(A, B) can be calculated using Equation 1.5; (1.5) Formula (1.5) calculates the straight-line distance between two points in n-dimensional space, which can directly reflect the similarity between two feature vectors of different high-level semantic topological relationships. Finally, the algorithm outputs the database image with the smallest Euclidean distance to the image to be matched as the matching result. (B2) introduces a maximum distance threshold to distinguish between true matches and false matches. That is, a maximum distance threshold is set. When the Euclidean distance between two high-level semantic topology relation feature vectors is less than the threshold, they are considered to be a successful match; otherwise, they are considered to be a failed match.
6. The method according to claim 5, characterized in that: The steps in step (B2) to integrate the maximum distance threshold into the matching algorithm are as follows: (BI) Calculate Euclidean distance: Calculate the Euclidean distance between the high-level semantic topological relation feature vector of the image to be matched and the high-level semantic topological relation feature vector of each image in the database; (BII) Find the minimum distance: Find the minimum value among all calculated Euclidean distances. This value represents the highest similarity between the image to be matched and an image in the database. (BIII) Apply the maximum distance threshold: Set a maximum distance threshold. If the minimum Euclidean distance is less than or equal to this threshold, it is considered that a matching image has been found, and the image and its corresponding geographic coordinates are output as the matching result. If the minimum Euclidean distance is greater than the threshold, it is considered that no matching image has been found, and the matching is considered to have failed.
