A local gradient fitting method for generating KeyNet sub-pixel feature points

By using the local gradient fitting method in the KeyNet network, the positioning accuracy of feature points is improved, the problem of changes in the number of feature points caused by changes in scene features in UAV visual navigation is solved, and the detection of sub-pixel level feature points is achieved, significantly Improved image matching performance and accuracy.

CN114187358BActive Publication Date: 2024-09-20DALIAN UNIV OF TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111515423.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-13
Publication Date
2024-09-20
Estimated Expiration
2041-12-13

AI Technical Summary

Technical Problem

In UAV visual navigation tasks, the scene features in aerial images change greatly, which causes the number of feature points extracted by the traditional SIFT algorithm to change greatly, affecting the image matching performance. KeyNet can only detect pixel-level feature points, which is lower than SIFT. The sub-pixel level accuracy cannot meet the needs of high-precision visual navigation.

Method used

By detecting pixel-level feature points in the KeyNet network and using the local gradient fitting method, we calculate the gradient relationship between the response strengths of feature points and their adjacent points, generate sub-pixel-level coordinates, and improve the positioning accuracy of feature points to achieve the same goal. SIFT-like sub-pixel accuracy.

Benefits of technology

The image matching performance is significantly improved, and the positioning accuracy of feature points is improved. The matching accuracy reaches sub-pixel level, the maximum error is less than 0.05 pixels, and the average error is 0.019 pixels, which significantly improves the accuracy and quantity of image matching.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114187358B
    Figure CN114187358B
Patent Text Reader

Abstract

A local gradient fitting method for generating KeyNet sub-pixel feature points belongs to the field of image processing. The KeyNet network is used to detect all pixel-level precision feature points of an input image in each scale plane, and a response intensity map of each scale plane is generated; for each pixel-level precision feature point, the gradient relationship between the response intensity of the feature point and its eight adjacent points is calculated, and the sub-pixel coordinates of the feature point are fitted, thereby improving the positioning accuracy of the KeyNet feature point from the pixel level to the sub-pixel level. The maximum sub-pixel error of the present invention is 0.030 pixels, and the average error is 0.019 pixels. For image matching tasks in which the SIFT algorithm only detects 3 pairs of correct matching points, the present invention can detect 41 pairs of correct matching points. The present invention matches low-quality aerial images that are difficult to match with the SIFT algorithm, and significantly improves image matching performance.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of image processing and relates to a local gradient fitting method for generating KeyNet sub-pixel feature points. Background Art

[0002] Image matching is the core technology for many tasks such as visual navigation and image retrieval. SIFT (scale-invariant feature transform) is a classic image matching method that detects and locates feature points at different scales by constructing a Gaussian pyramid and detecting extreme points in the scale space. The advantage of SIFT is that it is robust to changes in scale, rotation, illumination, etc., and its positioning accuracy reaches sub-pixel level. However, in visual navigation tasks, the aerial images acquired by drones have the problem of large changes in scene features, which will cause large changes in the number of feature points extracted by SIFT. When the number of feature points is small, it may lead to a serious decline in image matching performance.

[0003] With the rapid development of deep learning, convolutional neural networks (CNN) have shown advantages in feature extraction. When the scene features in the image vary greatly, the CNN feature point extraction method represented by KeyNet exceeds the traditional SIFT algorithm in the number of feature points. Moreover, the KeyNet network has a multi-scale structure similar to the Gaussian pyramid, so the KeyNet network can also detect feature points with scale invariance. However, KeyNet can only detect pixel-level feature points, which is lower than the sub-pixel accuracy of the SIFT algorithm.

[0004] In the aerial images obtained by the UAV visual navigation mission, the geographical scene contained in one picture is often very large, and the actual distance error caused by a pixel error is also very large. For example, in the 15-level tile of Google Maps, one pixel corresponds to an actual area of ​​8m×8m. Therefore, if visual navigation is performed with pixel-level accuracy, the positioning accuracy of the UAV is low, which obviously cannot meet the growing high-precision visual navigation needs of military and civilian applications. Summary of the invention

[0005] The present invention provides a local gradient fitting method for generating KeyNet sub-pixel feature points, which can improve the positioning accuracy of KeyNet feature points from pixel level to sub-pixel level to meet the high-precision positioning requirements of visual navigation. For an input image, all pixel-level precision feature points are detected in each scale plane of KeyNet, and a response intensity map of the scale plane is generated. For each feature point, the sub-pixel coordinates of the feature point are fitted through the gradient relationship between the response intensity of the feature point and its eight adjacent points.

[0006] The technical solution of the present invention is as follows (see Figure 1 ):

[0007] Step 1: Input a grayscale image Q of size w×h, where w and h are the length and width of image Q respectively.

[0008] Step 2: KeyNet detects and outputs all pixel-level feature points. The image Q is fed into a trained KeyNet network, with the scale factor set to θ i , i = 1, ..., N, N is the number of different scales, N can be any integer between 3 and 8. The KeyNet network detects all pixel-level feature points in N scale planes, and the number of feature points in each scale plane is m i ,i=1,…,N。

[0009] Step 3: Generate pixel-level feature point response intensity map. For the i-th scale plane, use the response intensity of all pixels in the scale plane to generate the response intensity map R of the scale plane. i ,i=1,...,N,size is w×θ i ×h×θ i .

[0010] Step 4: Calculate m in a certain scale plane i i The sub-pixel offset of pixel-level feature points, i = 1, ..., N. Let the current feature point be p j ,j=1,...,m i , corresponding to the response intensity map R i The pixel-level coordinates on are (x0, y0); the discrete feature points are fitted into a two-dimensional continuous function by performing Taylor expansion at the point (x0, y0), and the derivative of the function is made equal to 0, and the sub-pixel offset (x-x0, y-y0) is obtained, which is recorded as The specific calculation formula is as follows: Where C is the coordinate of each pixel level in the response intensity map R i The corresponding response intensity value. According to the current feature point p jThe difference between the response intensities of the eight adjacent points (x0+1,y0), (x0-1,y0), (x0,y0+1), (x0,y0-1), (x0+1,y0+1), (x0-1,y0-1), (x0+1,y0-1), (x0-1,y0+1), and (x0-1,y0+1) is used to calculate the first-order and second-order local gradients in equation (1) as follows:

[0011]

[0012]

[0013]

[0014]

[0015]

[0016] Step 5: Generate sub-pixel feature points. If the feature point offset calculated by equations (1)-(6) or The absolute value of is greater than 0.5, indicating that the function extreme point has shifted to the neighboring point of the current feature point (x0, y0) in Indicates rounding down; switch this neighboring point to the new (x0, y0), and perform the calculation in step 4 again. If the number of neighboring point switching times is greater than 5 times or exceeds the response intensity graph R i The boundary of the feature point p is discarded. j If the offset and are all less than 0.5, then according to the pixel-level coordinates (x0, y0), offset and scale factor θ i , generate the current feature point p j Sub-pixel precision coordinates on the grayscale image Q as follows:

[0017]

[0018] Step 6: Output the set of all sub-pixel feature points of the grayscale image Q

[0019] While retaining the powerful feature detection capability of KeyNet, the present invention improves the positioning accuracy of feature points and achieves sub-pixel accuracy similar to SIFT, with the highest error less than 0.05 pixels. The sub-pixel error calculated by SIFT is up to 0.026 pixels, and the average error is 0.011 pixels; the maximum sub-pixel error of the present invention is 0.030 pixels, and the average error is 0.019 pixels. Although the matching accuracy of the present invention is slightly lower than that of the SIFT algorithm, it has obvious advantages over the SIFT algorithm in matching ability. When matching a group of low-quality aerial images and detecting images with a contrast threshold of 0.012, the SIFT algorithm only found 3 pairs of correct matching points, while the present invention found 41 pairs of correct matching points (as shown in Figure 2). Therefore, the present invention significantly improves the image matching performance. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] Figure 1 It is a flow chart of the present invention.

[0021] Figure 2 (a) The SIFT algorithm finds 3 pairs of correct matching points and 1 pair of incorrect matching points.

[0022] FIG2( b ) shows that the present invention finds 41 pairs of correct matching points. DETAILED DESCRIPTION

[0023] There are two actual aerial grayscale images with a size of 500×500. The following describes an embodiment of the present invention in detail in conjunction with a matching task of the two images.

[0024] Step 1: Input two grayscale images Q1 and Q2, both with a size of 500×500.

[0025] Step 2: KeyNet detects and outputs all pixel-level feature points. Images Q1 and Q2 are sent to a trained KeyNet network respectively, and their scale factor is set to θ i ={0.4, 0.6, 0.8, 1.0, 1.2, 1.4}, i = 1, ..., 6, that is, N = 6. The KeyNet network detects all pixel-level feature points in 6 scale planes, and the number of feature points of the two images in each scale plane is A total of 178 pixel-level feature points were detected in image Q1 in all scale planes, and a total of 227 pixel-level feature points were detected in image Q2.

[0026] Step 3: Generate pixel-level feature point response intensity map. Taking image Q1 as an example, for the i-th scale plane of Q1, the response intensity map R of the scale plane is generated using the response intensity of all pixels in the scale plane. i ,i=1,...,6,size is 500×θ i ×500×θi .

[0027] Step 4: Calculate m in a certain scale plane i i The sub-pixel offset of each pixel-level feature point, i=1,...,6. Take the pixel-level feature point p on the response intensity map R3 of image Q1, scale factor θ3=0.8, and size 400×400 as an example, its pixel-level coordinates are (217,179). According to formulas (1)-(6), the sub-pixel offset is (-0.3256,0.6721).

[0028] Step 5: Generate sub-pixel feature points. The absolute value of the offset calculated in step 4 is greater than 0.5 in the y direction, indicating that the function extreme point has shifted to the neighboring point (217, 180) of the current feature point (217, 179); (217, 180) is used as the new point p, and the calculation in step 4 is performed again. The sub-pixel offset obtained by the second calculation is (-0.3227, 0.3251). The absolute values ​​of the offsets in both dimensions are less than 0.5. Then, according to formula (7), the sub-pixel precision coordinates of the current feature point p on the grayscale image Q1 are generated (270.8466, 225.4064).

[0029] Step 6: Output the set of all sub-pixel feature points of grayscale images Q1 and Q2. After the above calculation, 174 sub-pixel feature points are detected in all scale planes for image Q1, and 223 sub-pixel feature points are detected for image Q2.

[0030] Step 7: Use SIFT feature description method to construct feature descriptors, and apply RANSAC algorithm to remove wrong matching point pairs. Finally, the present invention obtains 41 correct matching point pairs and completes the matching of two aerial images; SIFT only obtains 3 correct matching point pairs, which does not meet the minimum matching requirement of 10 matching point pairs, and the matching fails.

Claims

1. A local gradient fitting method for generating KeyNet sub-pixel feature points. For an input image, all pixel-level precision feature points are detected in each scale plane of KeyNet, and a response intensity map of the scale plane is generated; for each feature point, the sub-pixel coordinates of the feature point are fitted through the gradient relationship between the response intensity of the feature point and its eight adjacent points; it is characterized in that Here are the steps: Step 1: Input a grayscale image Q of size w×h, where w and h are the length and width of image Q respectively; Step 2: KeyNet detects and outputs all pixel-level feature points; the image Q is fed into a trained KeyNet network, whose scale factor is set to θ i , i = 1, ..., N, N is the number of different scales, N is any integer from 3 to 8; the KeyNet network detects all pixel-level feature points in N scale planes, and the number of feature points in each scale plane is m i ,i=1,...,N; Step 3: Generate a pixel-level feature point response intensity map; for the i-th scale plane, use the response intensity of all pixels in the scale plane to generate the response intensity map R of the scale plane i ,i=1,...,N,size is w×θ i ×h×θ i ; Step 4: Calculate m in a certain scale plane i i The sub-pixel offset of pixel-level feature points, i = 1, ..., N; let the current feature point be p j ,j=1,...,m i , corresponding to the response intensity map R i The pixel-level coordinates on are (x0, y0); the discrete feature points are fitted into a two-dimensional continuous function by performing Taylor expansion at the point (x0, y0), and the derivative of the function is made equal to 0, and the sub-pixel offset (x-x0, y-y0) is obtained, which is recorded as The specific calculation formula is as follows: Where C is the pixel-level coordinate in the response intensity map R i The corresponding response intensity value; according to the current feature point p j The difference between the response intensities of the eight adjacent points (x0+1,y0), (x0-1,y0), (x0,y0+1), (x0,y0-1), (x0+1,y0+1), (x0-1,y0-1), (x0+1,y0-1), (x0-1,y0+1), and (x0-1,y0+1) is used to calculate the first-order and second-order local gradients in equation (1) as follows: Step 5: Generate sub-pixel feature points; if the feature point offset calculated by equations (1)-(6) or The absolute value of is greater than 0.5, indicating that the function extreme point has shifted to the neighboring point of the current feature point (x0, y0) in Indicates rounding down; switch this neighboring point to the new (x0, y0), and perform the calculation in step 4 again; if the number of neighboring point switching times is greater than 5 times or exceeds the response intensity graph R i The boundary of the feature point p is discarded. j ; If the offset and are all less than 0.5, then according to the pixel-level coordinates (x0, y0), offset and scale factor θ i , generate the current feature point p j Sub-pixel precision coordinates on the grayscale image Q as follows: Step 6: Output the set of all sub-pixel feature points of the grayscale image Q