Aircraft recognition and attitude estimation method based on superpixel quadratic kernel geometric features

Through a method based on the geometric features of superpixel secondary cores, superpixel division and secondary core distribution characterization are performed using the color and structure information of the aircraft image, combined with template recognition and differential chain code accumulation, accurate aircraft attitude estimation in a single RGB image is achieved, and the inaccurate attitude estimation problem in the prior art is solved.

CN120259432BActive Publication Date: 2025-09-05JILIN UNIVERSITY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510733834.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-06-04
Publication Date
2025-09-05
Estimated Expiration
2045-06-04

AI Technical Summary

Technical Problem

In the absence of three-dimensional information, the angle calculation is not accurate enough, and depends on the scene additional three-dimensional information and high requirements for labeling data, making it difficult to achieve accurate aircraft attitude estimation.

Method used

The method based on the geometric features of the superpixel secondary core is adopted to divide and fusion through the color characteristics and regional complexity of the aircraft image, and the regional characterization is performed by combining the secondary core distribution, and the multi-angle fuselage and wing templates are used for identification, and the main structural inflection points are obtained through the accumulation of differential chain codes, and the aircraft area segmentation and attitude angle calculation are performed.

Benefits of technology

It realizes the accurate estimation of the attitude angle of the aircraft without three-dimensional information in a single RGB image, and improves the accuracy of attitude estimation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120259432B_ABST
    Figure CN120259432B_ABST
Patent Text Reader

Abstract

A method for aircraft recognition and attitude estimation based on superpixel quadratic kernel geometric features belongs to the field of computer vision and target detection and analysis in digital image processing. The method includes the following steps: using the color features of the aircraft image to perform superpixel segmentation; characterizing and fusing each image region based on a quadratic kernel distribution; identifying the aircraft based on a multi-angle fuselage and wing template; segmenting the aircraft region based on differential chain code cumulants and skeletons; and using attitude angles to characterize four reference angles that can be directly calculated from a single image to achieve attitude angle estimation. Using only a single two-dimensional RGB image, the method utilizes the aircraft's color, texture, and regional geometric features to accurately identify and estimate the three-dimensional attitude of the aircraft in the image without three-dimensional information, providing a basis for robust aircraft attitude estimation in the presence of non-cooperative targets and when internal equipment is disabled.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of computer vision and target detection and analysis in digital image processing, and specifically relates to an aircraft recognition and attitude estimation method based on superpixel secondary kernel geometric features. Background Art

[0002] Attitude estimation is crucial for adjusting an aircraft's attitude during flight. Excessive attitude adjustments can lead to loss of control, structural damage, or even stall. Attitude estimation uses three attitude angles—yaw, pitch, and roll—to describe an aircraft's attitude. In most cases, six-dimensional attitude information can be obtained from the Global Positioning System (GPS) and Inertial Navigation System (INS). However, this method is not feasible for non-cooperative targets. Therefore, it is necessary to design a new computer vision-based attitude estimation method for non-cooperative targets. This method is also crucial for cooperative targets when the INS fails.

[0003] In recent years, with the advancement of image processing technology, computer vision-based pose estimation methods have become a highly sought-after research topic. However, due to the complexity of aircraft pose estimation, there are relatively few pose estimation methods specifically designed for aircraft. Computer vision-based pose estimation methods can be roughly divided into two categories: (i) classical methods and (ii) deep learning-based methods.

[0004] (i) Classical method

[0005] According to different sensor systems, classical methods can be further divided into three categories: (1) RGB-D camera-based methods; (2) binocular system-based methods; and (3) monocular system-based methods.

[0006] RGB-D camera-based methods: The depth channel of an RGB-D camera can directly provide depth information of the aircraft. However, the depth resolution of RGB-D cameras is insufficient, making them incapable of analysing long-range or low-contrast scenes. Binocular-based methods can provide depth information through the parallax between two images. Some researchers have proposed the plane intersection method for pose estimation based on the depth information implicit in line features. The main limitation of binocular systems is the small parallax of distant objects, which increases depth estimation errors and leads to inaccurate pose estimation. Monocular-based methods are considered the most promising pose estimation methods due to their low cost. Some researchers have proposed a classic aircraft pose estimation method based on a single RGB image—the Pose Estimation with Keypoints and Structures (PEKS) method. This method uses a modified version of the Perspective-n-Point (PnP) algorithm to calculate pose angles. However, to ensure the accuracy of PnP-based methods, the 3D coordinates of at least six keypoints are required to estimate the rotation matrix, which is then used to calculate the pose angles. However, the rotation matrix represents the relative angle between the camera and the object. For an aircraft, the attitude angle represents the change in the aircraft's own attitude.

[0007] (ii) Deep learning-based methods

[0008] Deep learning methods have also been used to estimate the attitude angles of aircraft and other objects. To capture the global characteristics of an aircraft, researchers often combine super-resolution methods with attitude estimation methods in an end-to-end network. These end-to-end networks can directly estimate attitude angles. Among these deep learning-based methods, the method named DKPNet, which uses three small networks, has the highest attitude estimation accuracy. However, these angles are still calculated at the end of the network using a PnP-like method, which means that such methods still need to be provided with the three-dimensional (3D) coordinates of the key points.

[0009] This method can estimate an aircraft's attitude angle without 3D information. The entire attitude estimation is based entirely on the aircraft's structural information implicit in a single RGB image. The calculated angle represents the aircraft's attitude, not the relative angle between the camera and the aircraft. Summary of the Invention

[0010] Given the challenges of existing aircraft attitude estimation methods, including inaccurate angle calculation, high requirements for annotated data, and reliance on additional 3D scene information, the present invention provides an aircraft recognition and attitude estimation method based on superpixel quadratic kernel geometric features. This method is primarily applicable to aircraft attitude estimation using a single aircraft image, lacking additional 3D information, or requiring a large dataset. The present invention proposes an aircraft recognition method based on aircraft color and structural information, and designs an aircraft attitude estimation algorithm based on four reference angles.

[0011] The present invention provides an aircraft recognition and attitude estimation method based on superpixel secondary kernel geometric features, comprising the following steps:

[0012] S1 uses the color features and regional complexity of the aircraft image to divide the image region, including the following steps:

[0013] S1.1 uses the color features of the aircraft image to perform preliminary superpixel segmentation, including the following steps:

[0014] S1.1.1 Calculate the HSV color distance d between pixels in the image area c , its mathematical expression is:

[0015] ;

[0016] Where: H1, S1, V1, H2, S2, V2 are the hue, saturation and brightness of the two pixels respectively, where H1 is the hue with the larger value;

[0017] S1.1.2 Calculate the Euclidean distance d between pixels in the image area s , its mathematical expression is:

[0018] ;

[0019] Where: x1, y1, x2, y2 are the image coordinates of two pixels;

[0020] S1.1.3 HSV color distance d obtained from steps S1.1.1 and S1.1.2 c and the Euclidean distance d s , calculate the pixel similarity D, divide the image into superpixels, and the mathematical expression of pixel similarity D is:

[0021] ;

[0022] Where: s is the preset superpixel size;

[0023] S1.2 Based on the superpixel area obtained in step S1.1.3, superpixel fusion is performed based on the superpixel texture complexity, including

[0024] The following steps;

[0025] S1.2.1 Calculate the texture complexity f of all superpixels c , the mathematical expression is:

[0026] ;

[0027] Where: s represents the superpixel size; Indicates the binarization standard deviation calculated based on a 3×3 area. When the texture complexity is greater than 0.1 times the maximum texture complexity of the entire image, the binarization standard deviation of the area is 1, and otherwise it is zero.

[0028] S1.2.2 Superpixel texture complexity f obtained in step S1.2.1 c , the computational complexity difference , its mathematical expression is:

[0029] ;

[0030] Where: and Represents the texture complexity of two superpixel regions; is the minimum texture complexity;

[0031] S1.2.3 Complexity differences according to step S1.2.2 ,Will Superpixels with a value less than 1 are fused into one region;

[0032] S2 characterizes each image region based on a quadratic kernel distribution, which includes the following steps:

[0033] S2.1 Use three secondary kernel distributions to characterize the fused image region obtained in step S1.2.3, and iteratively calculate the secondary kernel distributions.

[0034] The mathematical expression of cloth parameters is:

[0035] ;

[0036] Where: 、 、 are the mean, prior probability and covariance matrix of the j-th quadratic kernel distribution respectively; is a vector representing a pixel point; It represents the posterior probability that the i-th pixel belongs to the j-th distribution. The mathematical expression is:

[0037] ;

[0038] Where: K represents the number of distributions; is the pixel position vector; is the mean of the position vector of the jth distribution; is the covariance matrix 2×2 part; is the probability density function of the quadratic kernel distribution, and its mathematical expression is:

[0039] ;

[0040] S2.2 performs eigendecomposition on the covariance matrix of the quadratic kernel distribution obtained in step S2.1. The mathematical expression is:

[0041] ;

[0042] Where: is the covariance matrix 2×2 part; is the eigenvalue matrix, is the eigenvector matrix, and its mathematical expression is:

[0043] ;

[0044] S2.3 Calculate the angular characteristics of the three distributions used to represent the fusion area based on the covariance matrix obtained in step S2.2.

[0045] The mathematical expression is:

[0046] ;

[0047] S3 identifies the aircraft based on multi-angle fuselage and wing templates, including the following steps:

[0048] S3.1 Establish basic templates for ten different types of aircraft and define them as , and further define the fuselage, left wing and right wing templates of each template as 、 and ;

[0049] S3.2 Based on the basic templates of the fuselage, left wing, and right wing of different aircraft models obtained in step S3.1, the templates of each part are further rotated to obtain fuselage and wing templates at different angles. The mathematical expression is:

[0050] ;

[0051] The matrix form of the above formula can also be expressed as:

[0052] ;

[0053] Where: x and y represent the horizontal and vertical coordinates of any pixel point in the fuselage and wing template before rotation; X and Y represent the horizontal and vertical coordinates of each point after rotation; and are the coordinates of the rotation center; L, LA and The corresponding vectors are: rotation matrix R j The mathematical expression is:

[0054] ;

[0055] S3.3 determines whether the target is an aircraft by minimizing the aircraft template coefficient. The mathematical expression is:

[0056] ;

[0057] Where: 、 and is the matrix composed of template vectors of all angles of the k-th template of the fuselage, left wing and right wing; 、 and are the template coefficient vectors of the fuselage, left wing, and right wing for the kth template. When only one element of the template coefficient vector among the k template coefficient vectors is 1, and the angles of the template coefficient vectors corresponding to the fuselage and the two wings are close, the target is determined to be an aircraft, and the pixels in this area are marked as 1 to obtain the aircraft mask image, which is marked as B;

[0058] S4 obtains the inflection points of the aircraft's main structures based on the differential chain code cumulant, including the following steps:

[0059] S4.1 calculates the gradient of all non-zero points in the aircraft mask image B obtained in step S3.3. Points with non-zero gradients are identified as edge points. All edge points are saved in the Edge mask image. The mathematical expression for gradient calculation is:

[0060] ;

[0061] Where: I is a 3×3 region of the mask image B, and is the gradient calculation kernel, and the mathematical expression is:

[0062] ;

[0063] S4.2 obtains the Freeman chain code of the aircraft based on the edge mask image Edge obtained in step S4.1. The mathematical expression is:

[0064] ;

[0065] Where: Or represents the number of directions of the chain code, which is set to 8; and Indicates the X and Y coordinates of the current edge point; and Indicates the X and Y coordinates of the next edge point, which is the edge point closest to the current edge point. The Freeman chain code is saved in the FrM set in order.

[0066] S4.3 calculates the differential chain code cumulant based on the Freeman chain code obtained in step S4.2. The mathematical expression is:

[0067] ;

[0068] Where: mod represents the remainder operation; p is the accumulation coefficient; Represents the differential chain code accumulation of the i-th edge point, selects the pixel point with the smallest differential chain code accumulation as the inflection point, and saves it to the inflection point mask image middle;

[0069] S5 performs an erosion operation on the aircraft mask image B obtained in step S3.3 to obtain the aircraft skeleton. Based on the skeleton, the aircraft region is segmented. The four inflection points closest to the center of the aircraft skeleton are found to segment the three main regions of the aircraft. The steps include:

[0070] S5.1 performs an erosion operation on the aircraft mask image B obtained in step S3.3 to obtain the aircraft skeleton mask image Gu, as shown in FIG.

[0071] The following formula:

[0072] ;

[0073] Where: erode is the erosion operation, which will erode the content of the aircraft mask image in the form of a binary image to a single pixel width. is a 3×3 matrix of all 1s;

[0074] S5.2 Calculate the number of adjacent points of each aircraft skeleton point based on the aircraft skeleton mask image Gu obtained in step S5.1.

[0075] As follows:

[0076] ;

[0077] Where: Gu{i} is the 3×3 neighborhood of the i-th point, Lin(i) is the number of adjacent points of the skeleton point, and when the number of adjacent points is greater than or equal to 3, the skeleton point is a candidate skeleton center point;

[0078] S5.3 calculates and finds the skeleton center point position based on the edge mask image Edge obtained in step S4.1 and the aircraft skeleton mask image Gu obtained in step S5.1. The mathematical expression is:

[0079] ;

[0080] Where GW is half the length of the outer edge of the skeleton, Gu(i) represents the skeleton center candidate point in the skeleton mask image, and Gm represents the mask image of the point where the edge intersects the skeleton, also known as the skeleton end mask image. The mathematical expression is:

[0081] ;

[0082] Where: It is the matrix element multiplication operation;

[0083] S5.4 Based on the aircraft mask image B obtained in step S3.3, the edge mask image Edge obtained in step S4.1, and the inflection point mask image obtained in step S4.3 The aircraft skeleton mask image Gu obtained in step S5.1 is used to obtain the inflection point mask image QB marked by the region segmentation result. The mathematical expression is:

[0084] ;

[0085] Where: is the matrix element multiplication operation, Qu represents the mask image of the region separated by the skeleton, and the mathematical expression is:

[0086] ;

[0087] S5.5 calculates the distance from the inflection point to the skeleton center one by one based on the skeleton center vector Center obtained in step S5.3 and the inflection point mask image QB marked by the region segmentation result obtained in step S5.4. The mathematical expression is:

[0088] ;

[0089] Where: QB{i, pa} represents the i-th inflection point of the pa-th aircraft region; represents the magnitude of a vector;

[0090] S5.6 Based on the distances from the inflection points on the edges of each region to the center of the skeleton obtained in step S5.5, the mathematical expressions for obtaining the four inflection points closest to the center of the skeleton are:

[0091] ;

[0092] S5.7 performs skeleton parallelism determination based on the skeleton center Center and skeleton end mask image Gm obtained in step S5.3. The mathematical expression is:

[0093] ;

[0094] Where: · is the matrix dot product; Represents the modulus of the vector; ε is a constant close to 1, set to 0.99; if two of the skeleton end points are parallel to the vector formed by the skeleton center, the corresponding two skeleton segments are the fuselage skeleton, and the coordinates of the other two skeleton end points in Gm, that is, the left and right wing endpoints, are saved and marked as and ;

[0095] S5.8 connects the inflection points closest to the center of the skeleton obtained in step S5.6 in the order of the chain code based on the Freeman chain code obtained in step S4.2, retaining only the lines that do not pass through the fuselage skeleton, and saves the lines to the segmentation line mask image Line;

[0096] S5.9 obtains the aircraft segmentation result mask image Seg and the fuselage and wing regions included therein based on the aircraft mask image B obtained in step S3.3, the edge mask image Edge obtained in step S4.1, and the segmentation line mask image Line obtained in step S5.8. The mathematical expression is:

[0097] ;

[0098] S6 obtains the area angles based on the fuselage and wing areas obtained in step S5.9, including the following steps:

[0099] S6.1 Use a single quadratic kernel distribution to fit the fuselage and wing regions obtained in step S5.9, and iteratively calculate the quadratic kernel distribution

[0100] Parameters, as follows:

[0101] ;

[0102] Where: 、 、 are the mean, prior probability and covariance matrix of the j-th quadratic kernel distribution respectively; is a vector representing a pixel point; The posterior probability that the i-th pixel belongs to the j-th distribution is calculated as follows:

[0103] ;

[0104] Where: K represents the number of distributions, is the pixel position vector, is the mean of the position vector of the jth distribution, is the covariance matrix The 2×2 part, is the probability density function of the quadratic kernel distribution, which is calculated as follows:

[0105] ;

[0106] S6.2 performs eigendecomposition on the covariance matrix of the quadratic kernel distribution obtained in step S6.1, as follows:

[0107] ;

[0108] Where: is the covariance matrix 2×2 part; is the eigenvalue matrix, is the eigenvector matrix, and its mathematical expression is:

[0109] ;

[0110] S6.3 Calculate the angle features of each region based on the eigenvector matrix obtained in step S6.2, and record the angles of the fuselage, left wing, and right wing as , , , where the angular characteristics of the fuselage It is the first attitude angle of the aircraft, that is, the yaw angle, and its mathematical expression is:

[0111] ;

[0112] S7 calculates the wing depth ratio to calculate a first reference angle, calculates a second reference angle using the first reference vector and the wing endpoint vector, and calculates the roll angle of the aircraft using the two reference angles, comprising the following steps S:

[0113] S7.1 Calculate the wing depth ratio based on the coordinates of the left and right wing endpoints obtained in step S5.7. The mathematical expression is:

[0114] ;

[0115] Where: x2, y2, x3 and y3 are the horizontal and vertical coordinates of the endpoints of the left and right wings of the aircraft on the image respectively, and x1 and y1 are the horizontal and vertical coordinates of the midpoint of the two wing endpoints of the aircraft on the image;

[0116] S7.2 Based on the wing depth ratio obtained in step S7.1 , calculate the first reference angle, the mathematical expression is:

[0117] ;

[0118] Where: f is the focal length of the camera;

[0119] S7.3 Based on the coordinates of the left and right wing endpoints obtained in step S5.7, calculate the wing endpoint vector. The mathematical expression is:

[0120] ;

[0121] S7.4 The fuselage angle obtained in step S6.3 , calculate the first reference vector, that is, the fuselage normal vector, the mathematical expression is:

[0122] ;

[0123] S7.5 Wing endpoint vector obtained from steps S7.3 and S7.4 and the fuselage normal vector , calculate the second reference angle, the mathematical expression is:

[0124] ;

[0125] S7.6 uses the roll angle and pitch angle to represent the first reference angle obtained in step S7.2 and the second reference angle obtained in step S7.5, and establishes a first relationship model between the pitch angle and the roll angle. The expression for calculating the roll angle is:

[0126] ;

[0127] Where: is the pitch angle; is the roll angle;

[0128] S8 calculates the two angles between the left and right wing vectors and the fuselage vector, establishes a second relationship model between the pitch angle and the roll angle, and calculates the pitch angle, including the following steps:

[0129] S8.1 The fuselage, left wing, and right wing angles obtained in step S6.3 、 、 , we can calculate the angles between the left wing and the right wing and the fuselage respectively. The mathematical expressions are:

[0130] ;

[0131] S8.2 Using the actual angle between the wing and the fuselage , roll angle , pitch angle represents the third reference angle obtained in step S8.1 , that is, the angle between the left wing and the fuselage, the mathematical expression is:

[0132] ;

[0133] Where: Represents the length of the two-dimensional vector of the left wing, and the mathematical expression is:

[0134] ;

[0135] S8.3 Using the actual angle between the wing and the fuselage , roll angle , pitch angle represents the fourth reference angle obtained in step S8.1 , that is, the angle between the right wing and the fuselage, the mathematical expression is:

[0136] ;

[0137] Where: Represents the length of the right wing two-dimensional vector, which is approximately equal to , the mathematical expression is:

[0138] ;

[0139] S8.4 Combine the two wing-fuselage angle formulas obtained in steps S8.2 and S8.3 to obtain the second angle of pitch and roll.

[0140] Relational model, mathematical expression is:

[0141] ;

[0142] S8.5 Calculate the pitch angle based on the second relationship model obtained in step S8.4. The mathematical expression is:

[0143] ;

[0144] S9 completes the aircraft identification and attitude estimation.

[0145] The beneficial effects of the present invention are:

[0146] The present invention first uses the color features and regional complexity of aircraft images to perform a preliminary fusion of superpixels with similar color and texture complexity. Each region is then characterized using a quadratic kernel distribution to preliminarily calculate the angle of the aircraft region. Morphological methods, including an inflection point extraction algorithm based on differential chain code cumulants, are then used to segment the aircraft's primary regions. Accurate two-dimensional regional angle calculations are then performed. Finally, based on the aircraft's structural information, accurate attitude estimation is achieved by calculating four reference angles. This method can achieve attitude estimation based on a single aircraft image and further improve the accuracy of attitude angle estimation. BRIEF DESCRIPTION OF THE DRAWINGS

[0147] Figure 1 This is a flowchart of the aircraft recognition and attitude estimation method based on superpixel secondary kernel geometric features;

[0148] Figure 2 is a schematic diagram of the aircraft attitude angle;

[0149] Where: (a) is the yaw angle; (b) is the pitch angle; (c) is the roll angle;

[0150] Figure 3 This is a schematic diagram of the aircraft image acquisition system based on Maya;

[0151] Among them: a is the aircraft image acquisition interface based on Maya; b is the schematic diagram of the aircraft model;

[0152] Figure 4 is a flow chart of the attitude estimation method based on aircraft structure;

[0153] Figure 5 Schematic diagram of aircraft region segmentation based on differential chain code accumulation and skeleton extraction;

[0154] Among them: (a) is the original image; (b) is the inflection point; (c) is the skeleton; (d) is the region segmentation;

[0155] Figure 6 Schematic diagram of aircraft structure vectors and two-dimensional rotation;

[0156] Figure 7 Representative test images. DETAILED DESCRIPTION

[0157] The present invention will be described below with reference to the accompanying drawings.

[0158] like Figure 1 As shown, the present invention proposes an aircraft recognition and attitude estimation method based on superpixel secondary kernel geometric features, which generally includes superpixel division and fusion based on color features and regional complexity, regional representation and fusion based on secondary kernel distribution, aircraft recognition based on multi-angle fuselage and wing templates, inflection point extraction based on differential chain code accumulation, aircraft region segmentation based on skeleton and inflection point, yaw angle calculation based on secondary kernel distribution, roll angle calculation based on the first relationship model and pitch angle calculation based on the second relationship model. The three attitude angles are as follows: Figure 2 The test images are collected based on Maya software. The collection system is as follows: Figure 3 shown.

[0159] The present invention provides an aircraft recognition and attitude estimation method based on superpixel secondary kernel geometric features, comprising the following steps:

[0160] S1 uses the color features and regional complexity of the aircraft image to divide the image region, including the following steps:

[0161] S1.1 uses the color features of the aircraft image to perform preliminary superpixel segmentation, including the following steps:

[0162] S1.1.1 Calculate the HSV color distance d between pixels in the image area c , its mathematical expression is:

[0163] ;

[0164] Where: H1, S1, V1, H2, S2, V2 are the hue, saturation and brightness of the two pixels respectively, where H1 is the hue with the larger value;

[0165] S1.1.2 Calculate the Euclidean distance d between pixels in the image area s , its mathematical expression is:

[0166] ;

[0167] Where: x1, y1, x2, y2 are the image coordinates of two pixels;

[0168] S1.1.3 HSV color distance d obtained from steps S1.1.1 and S1.1.2 c and the Euclidean distance d s , calculate the pixel similarity D, divide the image into superpixels, and the mathematical expression of pixel similarity D is:

[0169] ;

[0170] Where: s is the preset superpixel size;

[0171] S1.2 Based on the superpixel area obtained in step S1.1.3, superpixel fusion is performed based on the superpixel texture complexity, including

[0172] The following steps;

[0173] S1.2.1 Calculate the texture complexity f of all superpixels c , the mathematical expression is:

[0174] ;

[0175] Where: s represents the superpixel size; Indicates the binarization standard deviation calculated based on a 3×3 area. When the texture complexity is greater than 0.1 times the maximum texture complexity of the entire image, the binarization standard deviation of the area is 1, and otherwise it is zero.

[0176] S1.2.2 Superpixel texture complexity f obtained in step S1.2.1 c , the computational complexity difference , its mathematical expression is:

[0177] ;

[0178] Where: and Represents the texture complexity of two superpixel regions; is the minimum texture complexity;

[0179] S1.2.3 Complexity differences according to step S1.2.2 ,Will Superpixels with a value less than 1 are fused into one region;

[0180] S2 characterizes each image region based on a quadratic kernel distribution, which includes the following steps:

[0181] S2.1 Use three secondary kernel distributions to characterize the fused image region obtained in step S1.2.3, and iteratively calculate the secondary kernel distributions.

[0182] The mathematical expression of cloth parameters is:

[0183] ;

[0184] Where: 、 、 are the mean, prior probability and covariance matrix of the j-th quadratic kernel distribution respectively; is a vector representing a pixel point; It represents the posterior probability that the i-th pixel belongs to the j-th distribution. The mathematical expression is:

[0185] ;

[0186] Where: K represents the number of distributions; is the pixel position vector; is the mean of the position vector of the jth distribution; is the covariance matrix 2×2 part; is the probability density function of the quadratic kernel distribution, and its mathematical expression is:

[0187] ;

[0188] S2.2 performs eigendecomposition on the covariance matrix of the quadratic kernel distribution obtained in step S2.1. The mathematical expression is:

[0189] ;

[0190] Where: is the covariance matrix 2×2 part; is the eigenvalue matrix, is the eigenvector matrix, and its mathematical expression is:

[0191] ;

[0192] S2.3 Calculate the angular characteristics of the three distributions used to represent the fusion area based on the covariance matrix obtained in step S2.2.

[0193] The mathematical expression is:

[0194] ;

[0195] S3 identifies the aircraft based on multi-angle fuselage and wing templates, including the following steps:

[0196] S3.1 Establish basic templates for ten different types of aircraft and define them as , and further define the fuselage, left wing and right wing templates of each template as 、 and ;

[0197] S3.2 Based on the basic templates of the fuselage, left wing, and right wing of different aircraft models obtained in step S3.1, the templates of each part are further rotated to obtain fuselage and wing templates at different angles. The mathematical expression is:

[0198] ;

[0199] The matrix form of the above formula can also be expressed as:

[0200] ;

[0201] Where: x and y represent the horizontal and vertical coordinates of any pixel point in the fuselage and wing template before rotation; X and Y represent the horizontal and vertical coordinates of each point after rotation; and are the coordinates of the rotation center; L, LA and The corresponding vectors are: rotation matrix R j The mathematical expression is:

[0202] ;

[0203] S3.3 determines whether the target is an aircraft by minimizing the aircraft template coefficient. The mathematical expression is:

[0204] ;

[0205] Where: 、 and is the matrix composed of template vectors of all angles of the k-th template of the fuselage, left wing and right wing; 、 and The template coefficient vectors for the fuselage, left wing, and right wing of the kth template are as follows: When only one element of the template coefficient vector among the k template coefficient vectors is 1, and the angles of the template coefficient vectors corresponding to the fuselage and the two wings are close, the target is determined to be an aircraft, and the pixels in the area are marked as 1 to obtain the aircraft mask image and mark it as B; After accurately identifying the aircraft, the three attitude angles of the aircraft are calculated according to the structural information of the aircraft. The attitude estimation process is as follows Figure 4 shown.

[0206] S4 obtains the inflection points of the aircraft's main structures based on the differential chain code cumulant, including the following steps:

[0207] S4.1 calculates the gradient of all non-zero points in the aircraft mask image B obtained in step S3.3. Points with non-zero gradients are identified as edge points. All edge points are saved in the Edge mask image. The mathematical expression for gradient calculation is:

[0208] ;

[0209] Where: I is a 3×3 region of the mask image B, and is the gradient calculation kernel, and the mathematical expression is:

[0210] ;

[0211] S4.2 obtains the Freeman chain code of the aircraft based on the edge mask image Edge obtained in step S4.1. The mathematical expression is:

[0212] ;

[0213] Where: Or represents the number of directions of the chain code, which is set to 8; and Indicates the X and Y coordinates of the current edge point; and Indicates the X and Y coordinates of the next edge point, which is the edge point closest to the current edge point. The Freeman chain code is saved in the FrM set in order.

[0214] S4.3 calculates the differential chain code cumulant based on the Freeman chain code obtained in step S4.2. The mathematical expression is:

[0215] ;

[0216] Where: mod represents the remainder operation; p is the accumulation coefficient; Represents the differential chain code accumulation of the i-th edge point, selects the pixel point with the smallest differential chain code accumulation as the inflection point, and saves it to the inflection point mask image Inflection point detection results are as follows: Figure 5 (b)

[0217] S5 performs an erosion operation on the aircraft mask image B obtained in step S3.3 to obtain the aircraft skeleton, and performs the following operations based on the skeleton: Figure 5 The aircraft region segmentation shown in (c) finds the four inflection points closest to the center of the aircraft skeleton and segment the three main regions of the aircraft, including the following steps:

[0218] S5.1 performs an erosion operation on the aircraft mask image B obtained in step S3.3 to obtain the aircraft skeleton mask image Gu, as shown in FIG.

[0219] The following formula:

[0220] ;

[0221] Where: erode is the erosion operation, which will erode the content of the aircraft mask image in the form of a binary image to a single pixel width. is a 3×3 matrix of all 1s;

[0222] S5.2 Calculate the number of adjacent points of each aircraft skeleton point based on the aircraft skeleton mask image Gu obtained in step S5.1.

[0223] As follows:

[0224] ;

[0225] Where: Gu{i} is the 3×3 neighborhood of the i-th point, Lin(i) is the number of adjacent points of the skeleton point, and when the number of adjacent points is greater than or equal to 3, the skeleton point is a candidate skeleton center point;

[0226] S5.3 calculates and finds the skeleton center point position based on the edge mask image Edge obtained in step S4.1 and the aircraft skeleton mask image Gu obtained in step S5.1. The mathematical expression is:

[0227] ;

[0228] Where GW is half the length of the outer edge of the skeleton, Gu(i) represents the skeleton center candidate point in the skeleton mask image, and Gm represents the mask image of the point where the edge intersects the skeleton, also known as the skeleton end mask image. The mathematical expression is:

[0229] ;

[0230] Where: It is the matrix element multiplication operation;

[0231] S5.4 Based on the aircraft mask image B obtained in step S3.3, the edge mask image Edge obtained in step S4.1, and the inflection point mask image obtained in step S4.3 The aircraft skeleton mask image Gu obtained in step S5.1 is used to obtain the inflection point mask image QB marked by the region segmentation result. The mathematical expression is:

[0232] ;

[0233] Where: is the matrix element multiplication operation, Qu represents the mask image of the region separated by the skeleton, and the mathematical expression is:

[0234] ;

[0235] S5.5 calculates the distance from the inflection point to the skeleton center one by one based on the skeleton center vector Center obtained in step S5.3 and the inflection point mask image QB marked by the region segmentation result obtained in step S5.4. The mathematical expression is:

[0236] ;

[0237] Where: QB{i, pa} represents the i-th inflection point of the pa-th aircraft region; represents the magnitude of a vector;

[0238] S5.6 Based on the distances from the inflection points on the edges of each region to the center of the skeleton obtained in step S5.5, the mathematical expressions for obtaining the four inflection points closest to the center of the skeleton are:

[0239] ;

[0240] S5.7 performs skeleton parallelism determination based on the skeleton center Center and skeleton end mask image Gm obtained in step S5.3. The mathematical expression is:

[0241] ;

[0242] Where: · is the matrix dot product; Represents the modulus of the vector; ε is a constant close to 1, set to 0.99; if two of the skeleton end points are parallel to the vector formed by the skeleton center, the corresponding two skeleton segments are the fuselage skeleton, and the coordinates of the other two skeleton end points in Gm, that is, the left and right wing endpoints, are saved and marked as and ;

[0243] S5.8 connects the inflection points closest to the center of the skeleton obtained in step S5.6 in the order of the chain code based on the Freeman chain code obtained in step S4.2, retaining only the lines that do not pass through the fuselage skeleton, and saves the lines to the segmentation line mask image Line;

[0244] S5.9 obtains the following image based on the aircraft mask image B obtained in step S3.3, the edge mask image Edge obtained in step S4.1, and the segmentation line mask image Line obtained in step S5.8: Figure 5 The segmentation result mask image Seg of the aircraft shown in (d) and the fuselage and wing areas it contains are expressed as follows:

[0245] ;

[0246] S6 obtains the area angles based on the fuselage and wing areas obtained in step S5.9, including the following steps:

[0247] S6.1 Use a single quadratic kernel distribution to fit the fuselage and wing regions obtained in step S5.9, and iteratively calculate the quadratic kernel distribution

[0248] Parameters, as follows:

[0249] ;

[0250] Where: 、 、 are the mean, prior probability and covariance matrix of the j-th quadratic kernel distribution respectively; is a vector representing a pixel point; The posterior probability that the i-th pixel belongs to the j-th distribution is calculated as follows:

[0251] ;

[0252] Where: K represents the number of distributions, is the pixel position vector, is the mean of the position vector of the jth distribution, is the covariance matrix The 2×2 part, is the probability density function of the quadratic kernel distribution, which is calculated as follows:

[0253] ;

[0254] S6.2 performs eigendecomposition on the covariance matrix of the quadratic kernel distribution obtained in step S6.1, as follows:

[0255] ;

[0256] Where: is the covariance matrix 2×2 part; is the eigenvalue matrix, is the eigenvector matrix, and its mathematical expression is:

[0257] ;

[0258] S6.3 Calculate the angle features of each region based on the eigenvector matrix obtained in step S6.2, and record the angles of the fuselage, left wing, and right wing as , , , where the angular characteristics of the fuselage It is the first attitude angle of the aircraft, that is, the yaw angle, and its mathematical expression is:

[0259] ;

[0260] S7 calculates the wing depth ratio to calculate a first reference angle, calculates a second reference angle using the first reference vector and the wing endpoint vector, and calculates the roll angle of the aircraft using the two reference angles, comprising the following steps S:

[0261] S7.1 Calculate the wing depth ratio based on the coordinates of the left and right wing endpoints obtained in step S5.7. The mathematical expression is:

[0262] ;

[0263] Where: x2, y2, x3 and y3 are the horizontal and vertical coordinates of the endpoints of the left and right wings of the aircraft on the image respectively, and x1 and y1 are the horizontal and vertical coordinates of the midpoint of the two wing endpoints of the aircraft on the image;

[0264] S7.2 Based on the wing depth ratio obtained in step S7.1 , calculate the first reference angle, the mathematical expression is:

[0265] ;

[0266] Where: f is the focal length of the camera;

[0267] S7.3 Based on the coordinates of the left and right wing endpoints obtained in step S5.7, calculate the wing endpoint vector. The mathematical expression is:

[0268] ;

[0269] S7.4 The fuselage angle obtained in step S6.3 , calculate the first reference vector, that is, the fuselage normal vector, the mathematical expression is:

[0270] ;

[0271] S7.5 Wing endpoint vector obtained from steps S7.3 and S7.4 and the fuselage normal vector , calculate the second reference angle, the mathematical expression is:

[0272] ;

[0273] S7.6 uses the roll angle and pitch angle to represent the first reference angle obtained in step S7.2 and the second reference angle obtained in step S7.5, and establishes a first relationship model between the pitch angle and the roll angle. The expression for calculating the roll angle is:

[0274] ;

[0275] Where: is the pitch angle; is the roll angle;

[0276] S8 is calculated as Figure 6 The two included angles between the left and right wing vectors and the fuselage vector are shown, and a second relationship model between the pitch angle and the roll angle is established to calculate the pitch angle, including the following steps:

[0277] S8.1 The fuselage, left wing, and right wing angles obtained in step S6.3 、 、 , we can calculate the angles between the left wing and the right wing and the fuselage respectively. The mathematical expressions are:

[0278] ;

[0279] S8.2 Using the actual angle between the wing and the fuselage , roll angle , pitch angle represents the third reference angle obtained in step S8.1 , that is, the angle between the left wing and the fuselage, the mathematical expression is:

[0280] ;

[0281] Where: Represents the length of the two-dimensional vector of the left wing, and the mathematical expression is:

[0282] ;

[0283] S8.3 Using the actual angle between the wing and the fuselage , roll angle , pitch angle represents the fourth reference angle obtained in step S8.1 , that is, the angle between the right wing and the fuselage, the mathematical expression is:

[0284] ;

[0285] Where: Represents the length of the right wing two-dimensional vector, which is approximately equal to , the mathematical expression is:

[0286] ;

[0287] S8.4 Combine the two wing-fuselage angle formulas obtained in steps S8.2 and S8.3 to obtain the second angle of pitch and roll.

[0288] Relational model, mathematical expression is:

[0289] ;

[0290] S8.5 Calculate the pitch angle based on the second relationship model obtained in step S8.4. The mathematical expression is:

[0291] ;

[0292] S9 completes the aircraft identification and attitude estimation.

[0293] The feasibility of the aircraft recognition and attitude estimation method based on superpixel secondary kernel geometric features provided by the present invention is verified by specific tests below. The attitude angle estimation results of the present invention are compared with the PnP method and DKPNet method mentioned in the background technology section above.

[0294] 1. Working conditions

[0295] This experiment uses an Intel(R) Core(TM) i5-9400F CPU @ 2.90GHz, a PC running Windows 10, and a GeForce GTX 1060 graphics card. Python and MATLAB are used as programming languages.

[0296] 2. Experimental content and results analysis

[0297] The posture estimation results of this experiment are shown in Table 1-4, which correspond to Figure 7 The four test images shown. The first column in the table gives the true values ​​of the three attitude angles in brackets, and the second to fourth columns give the estimated values ​​of the present invention and the two reference algorithms. The relative error and the average relative error are also given in the table. The lower the relative error, the more accurate the estimation of the attitude angle. The bold indicates the best estimation result. It can be seen that in most cases, the estimated values ​​of the present invention are closest to the true values ​​of the attitude angles. DKPNet can only obtain a more accurate roll angle on one test image. It can be seen from the table that the present invention can accurately identify and estimate the attitude of the aircraft.

[0298] Table 1 Comparison of attitude angle estimation results of three algorithms. ( Figure 7 (a))

[0299] DKPNet PnP The present invention <![CDATA[Yaw angle (13 ˚ )]]> 11.350 4.460 13.550 <![CDATA[Pitch angle (15 ˚ )]]> 12.280 16.830 14.800 <![CDATA[Roll angle (15 ˚ )]]> 15.630 47.200 16.000 Relative error of yaw angle 0.127 0.657 0.042 Pitch angle relative error 0.209 0.122 0.013 Roll angle relative error 0.048 2.147 0.067 Average relative error 0.128 0.975 0.041

[0300] Table 2 Comparison of attitude angle estimation results of three algorithms. ( Figure 7 (b))

[0301] DKPNet PnP The present invention <![CDATA[Yaw angle (90 ˚ )]]> 86.48 80.4 88.51 <![CDATA[Pitch angle (90 ˚ )]]> 82.41 75.96 87.03 <![CDATA[Roll angle (45 ˚ )]]> 41.02 47.11 47.08 Relative error of yaw angle 0.039 0.107 0.017 Pitch angle relative error 0.084 0.156 0.033 Roll angle relative error 0.088 0.047 0.046 Average relative error 0.071 0.103 0.032

[0302] Table 3 Comparison of attitude angle estimation results of three algorithms. ( Figure 7 (c))

[0303] DKPNet PnP The present invention <![CDATA[Yaw angle (90 ˚ )]]> 85.95 78.33 88.46 <![CDATA[Pitch angle (25 ˚ )]]> 29.85 33.15 28.18 <![CDATA[Roll angle (30 ˚ )]]> 34.81 53.04 32.62 Relative error of yaw angle 0.045 0.130 0.017 Pitch angle relative error 0.194 0.326 0.127 Roll angle relative error 0.160 0.768 0.087 Average relative error 0.133 0.408 0.077

[0304] Table 4 Comparison of attitude angle estimation results of three algorithms. ( Figure 7 (d))

[0305] DKPNet PnP The present invention <![CDATA[Yaw angle (90 ˚ )]]> 85.10 74.14 88.76 <![CDATA[Pitch angle (90 ˚ )]]> 85.10 45.95 87.33 <![CDATA[Roll angle (15 ˚ )]]> 10.16 37.05 15.80 Relative error of yaw angle 0.045 0.176 0.014 Pitch angle relative error 0.054 0.489 0.030 Roll angle relative error 0.323 1.470 0.053 Average relative error 0.141 0.712 0.032

Claims

1. A method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features, characterized in that: The following steps are involved: S1 uses the color features and regional complexity of aircraft images to divide image regions; S2 characterizes each image region based on a quadratic kernel distribution; S3 identifies the aircraft based on multi-angle fuselage and wing templates; S4 obtains the inflection points of the aircraft's main structures based on the differential chain code accumulation; S5 performs an erosion operation on the aircraft mask image B to obtain the aircraft skeleton, and performs aircraft region segmentation based on the skeleton. The four inflection points closest to the center of the aircraft skeleton are found to segment the three main regions of the aircraft. S6 obtains the regional angle based on the fuselage and wing areas; S7 calculates the wing depth ratio to calculate a first reference angle, calculates a second reference angle using the first reference vector and the wing endpoint vector, and calculates the roll angle of the aircraft using the two reference angles; S8 calculates two angles between the left and right wing vectors and the fuselage vector, establishes a second relationship model between the pitch angle and the roll angle, and calculates the pitch angle; S9 completes the aircraft identification and attitude estimation.

2. The method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features according to claim 1 is characterized in that: The step S1 of dividing the image region by using the color features and region complexity of the aircraft image includes the following steps: S1.1 uses the color features of the aircraft image to perform preliminary superpixel segmentation, including the following steps: S1.1.1 Calculate the HSV color distance d between pixels in the image area c , its mathematical expression is: ; Where: H1, S1, V1, H2, S2, V2 are the hue, saturation and brightness of the two pixels respectively, where H1 is the hue with the larger value; S1.1.2 Calculate the Euclidean distance d between pixels in the image area s , its mathematical expression is: ; Where: x1, y1, x2, y2 are the image coordinates of two pixels; S1.1.3 HSV color distance d obtained from steps S1.1.1 and S1.1.2 c and the Euclidean distance d s , calculate the pixel similarity D, divide the image into superpixels, and the mathematical expression of pixel similarity D is: ; Where: s is the preset superpixel size; S1.2 Based on the superpixel area obtained in step S1.1.3, superpixel fusion is performed based on the superpixel texture complexity, including The following steps; S1.2.1 Calculate the texture complexity f of all superpixels c , the mathematical expression is: ; Where: s represents the superpixel size; Indicates the binarization standard deviation calculated based on a 3×3 area. When the texture complexity is greater than 0.1 times the maximum texture complexity of the entire image, the binarization standard deviation of the area is 1, and otherwise it is zero. S1.2.2 Superpixel texture complexity f obtained in step S1.2.1 c , the computational complexity difference , its mathematical expression for: ; Where: and Represents the texture complexity of two superpixel regions; is the minimum texture complexity; S1.2.3 Complexity differences according to step S1.2.2 ,Will Superpixels with a value less than 1 are fused into one region.

3. The method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features according to claim 2, wherein The characteristic is that the characterization of each image region based on the secondary kernel distribution in step S2 includes the following steps: S2.1 Use three secondary kernel distributions to characterize the fused image region obtained in step S1.2.3, and iteratively calculate the secondary kernel distributions. The mathematical expression of cloth parameters is: ; Where: 、 、 are the mean, prior probability and covariance matrix of the j-th quadratic kernel distribution respectively; is a vector representing a pixel point; It represents the posterior probability that the i-th pixel belongs to the j-th distribution. The mathematical expression is: ; Where: K represents the number of distributions; is the pixel position vector; is the mean of the position vector of the jth distribution; is the covariance matrix 2×2 part; is the probability density function of the quadratic kernel distribution, and its mathematical expression is: ; S2.2 performs eigendecomposition on the covariance matrix of the quadratic kernel distribution obtained in step S2.

1. The mathematical expression is: ; Where: is the covariance matrix 2×2 part; is the eigenvalue matrix, is the eigenvector matrix, and its mathematical expression is: ; S2.3 Calculate the angular characteristics of the three distributions used to represent the fusion area based on the covariance matrix obtained in step S2.

2. The mathematical expression is: 。 4. The method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features according to claim 1, wherein The characteristic is that the aircraft identification based on the multi-angle fuselage and wing templates in step S3 includes the following steps: S3.1 Establish basic templates for ten different types of aircraft and define them as , and further define the fuselage, left wing and right wing templates of each template as 、 and ; S3.2 Based on the basic templates of the fuselage, left wing, and right wing of different aircraft models obtained in step S3.1, the templates of each part are further rotated to obtain fuselage and wing templates at different angles. The mathematical expression is: ; The matrix form of the above formula can also be expressed as: ; Where: x and y represent the horizontal and vertical coordinates of any pixel point in the fuselage and wing template before rotation; X and Y represent the horizontal and vertical coordinates of each point after rotation; and are the coordinates of the rotation center; L, LA and The corresponding vectors are: rotation matrix R j The mathematical expression is: ; S3.3 determines whether the target is an aircraft by minimizing the aircraft template coefficient. The mathematical expression is: ; Where: 、 and is the matrix composed of template vectors of all angles of the k-th template of the fuselage, left wing and right wing; 、 and are the template coefficient vectors of the fuselage, left wing, and right wing for the kth template. When only one element of the template coefficient vector among the k template coefficient vectors is 1, and the angles of the template coefficient vectors corresponding to the fuselage and the two wings are relatively close, the target is determined to be an aircraft, and the pixels in this area are marked as 1 to obtain the aircraft mask image, which is marked as B.

5. The method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features according to claim 4, wherein The characteristic is that the step S4 of obtaining the inflection point of the main structure of the aircraft based on the differential chain code cumulative amount includes the following steps: S4.1 calculates the gradient of all non-zero points in the aircraft mask image B obtained in step S3.

3. Points with non-zero gradients are identified as edge points. All edge points are saved in the Edge mask image. The mathematical expression for gradient calculation is: ; Where: I is a 3×3 region of the mask image B, and is the gradient calculation kernel, and the mathematical expression is: ; S4.2 obtains the Freeman chain code of the aircraft based on the edge mask image Edge obtained in step S4.

1. The mathematical expression is for: ; Where: Or represents the number of directions of the chain code, which is set to 8; and Indicates the X and Y coordinates of the current edge point; and Indicates the X and Y coordinates of the next edge point, which is the edge point closest to the current edge point. The Freeman chain code is saved in the FrM set in order. S4.3 calculates the differential chain code cumulant based on the Freeman chain code obtained in step S4.

2. The mathematical expression is: ; Where: mod represents the remainder operation; p is the accumulation coefficient; Represents the differential chain code accumulation of the i-th edge point, selects the pixel point with the smallest differential chain code accumulation as the inflection point, and saves it to the inflection point mask image middle.

6. The method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features according to claim 5, wherein The characteristics are, Perform an erosion operation on the aircraft mask image B obtained in step S3.3 to obtain the aircraft skeleton. Based on the skeleton, perform aircraft region segmentation. Find the four inflection points closest to the center of the aircraft skeleton and segment the three main regions of the aircraft. This includes the following steps: S5.1 performs an erosion operation on the aircraft mask image B obtained in step S3.3 to obtain the aircraft skeleton mask image Gu, as shown in FIG. The following formula: ; Where: erode is the erosion operation, which will erode the content of the aircraft mask image in the form of a binary image to a single pixel width. is a 3×3 matrix of all 1s; S5.2 Calculate the number of adjacent points of each aircraft skeleton point based on the aircraft skeleton mask image Gu obtained in step S5.

1. As follows: ; Where: Gu{i} is the 3×3 neighborhood of the i-th point, Lin(i) is the number of adjacent points of the skeleton point, and when the number of adjacent points is greater than or equal to 3, the skeleton point is a candidate skeleton center point; S5.3 calculates and finds the skeleton center point position based on the edge mask image Edge obtained in step S4.1 and the aircraft skeleton mask image Gu obtained in step S5.

1. The mathematical expression is: ; Where GW is half the length of the outer edge of the skeleton, Gu(i) represents the skeleton center candidate point in the skeleton mask image, and Gm represents the mask image of the point where the edge intersects the skeleton, also known as the skeleton end mask image. The mathematical expression is: ; Where: It is the matrix element multiplication operation; S5.4 Based on the aircraft mask image B obtained in step S3.3, the edge mask image Edge obtained in step S4.1, and the inflection point mask image obtained in step S4.3 The aircraft skeleton mask image Gu obtained in step S5.1 is used to obtain the inflection point mask image QB marked by the region segmentation result. The mathematical expression is: ; Where: is the matrix element multiplication operation, Qu represents the mask image of the region separated by the skeleton, and the mathematical expression is for: ; S5.5 calculates the distance from the inflection point to the skeleton center one by one based on the skeleton center vector Center obtained in step S5.3 and the inflection point mask image QB marked by the region segmentation result obtained in step S5.

4. The mathematical expression is: ; Where: QB{i, pa} represents the i-th inflection point of the pa-th aircraft region; represents the magnitude of a vector; S5.6 Based on the distances from the inflection points on the edges of each region to the center of the skeleton obtained in step S5.5, the mathematical expressions for obtaining the four inflection points closest to the center of the skeleton are: ; S5.7 performs skeleton parallelism determination based on the skeleton center Center and skeleton end mask image Gm obtained in step S5.

3. The mathematical expression is: ; Where: · is the matrix dot product; represents the magnitude of a vector; ε is a constant close to 1 and is set to 0.

99. If two of the skeleton end points are parallel to the vector formed by the skeleton center, the corresponding two skeleton segments are the fuselage skeleton, and the coordinates of the other two skeleton end points in Gm, that is, the left and right wing end points, are saved and marked as and ; S5.8 connects the inflection points closest to the center of the skeleton obtained in step S5.6 in the order of the chain code based on the Freeman chain code obtained in step S4.2, retaining only the lines that do not pass through the fuselage skeleton, and saves the lines to the segmentation line mask image Line; S5.9 obtains the aircraft segmentation result mask image Seg and the fuselage and wing regions included therein based on the aircraft mask image B obtained in step S3.3, the edge mask image Edge obtained in step S4.1, and the segmentation line mask image Line obtained in step S5.

8. The mathematical expression is: 。 7. The method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features according to claim 6, wherein The method is characterized in that, according to the fuselage and wing regions obtained in step S5.9, obtaining the region angle comprises the following steps: S6.1 Use a single quadratic kernel distribution to fit the fuselage and wing regions obtained in step S5.9, and iteratively calculate the quadratic kernel distribution Parameters, as follows: ; Where: 、 、 are the mean, prior probability and covariance matrix of the j-th quadratic kernel distribution respectively; is a vector representing a pixel point; The posterior probability that the i-th pixel belongs to the j-th distribution is calculated as follows: ; Where: K represents the number of distributions, is the pixel position vector, is the mean of the position vector of the jth distribution, is the covariance matrix The 2×2 part, is the probability density function of the quadratic kernel distribution, which is calculated as follows: ; S6.2 performs eigendecomposition on the covariance matrix of the quadratic kernel distribution obtained in step S6.1, as follows: ; Where: is the covariance matrix 2×2 part; is the eigenvalue matrix, is the eigenvector matrix, and its mathematical expression is: ; S6.3 Calculate the angle features of each region based on the eigenvector matrix obtained in step S6.2, and record the angles of the fuselage, left wing, and right wing as , , , where the angular characteristics of the fuselage It is the first attitude angle of the aircraft, that is, the yaw angle, and its mathematical expression is: 。 8. The method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features according to claim 6 or 7, It is characterized by: Calculating the wing depth ratio to calculate a first reference angle, calculating a second reference angle using the first reference vector and the wing end point vector, and calculating the roll angle of the aircraft using the two reference angles, includes the following steps: S7.1 Calculate the wing depth ratio based on the coordinates of the left and right wing endpoints obtained in step S5.

7. The mathematical expression is: ; Where: x2, y2, x3 and y3 are the horizontal and vertical coordinates of the endpoints of the left and right wings of the aircraft on the image respectively, and x1 and y1 are the horizontal and vertical coordinates of the midpoint of the two wing endpoints of the aircraft on the image; S7.2 Based on the wing depth ratio obtained in step S7.1 , calculate the first reference angle, the mathematical expression is: ; Where: f is the focal length of the camera; S7.3 Based on the coordinates of the left and right wing endpoints obtained in step S5.7, calculate the wing endpoint vector. The mathematical expression is: ; S7.4 The fuselage angle obtained in step S6.3 , calculate the first reference vector, that is, the fuselage normal vector, mathematical expression for: ; S7.5 Wing endpoint vector obtained from steps S7.3 and S7.4 and the fuselage normal vector , calculate the second reference angle, the mathematical expression is: ; S7.6 uses the roll angle and pitch angle to represent the first reference angle obtained in step S7.2 and the second reference angle obtained in step S7.5, and establishes a first relationship model between the pitch angle and the roll angle. The expression for calculating the roll angle is: ; Where: is the pitch angle; is the roll angle.

9. The method for aircraft recognition and attitude estimation based on superpixel secondary kernel geometric features according to claim 7, wherein The method is characterized in that two angles between left and right wing vectors and a fuselage vector are calculated, a second relationship model between a pitch angle and a roll angle is established, and the pitch angle is calculated, including the following steps: S8.1 The fuselage, left wing, and right wing angles obtained in step S6.3 、 、 , we can calculate the angles between the left wing and the right wing and the fuselage respectively. The mathematical expressions are: ; S8.2 Using the actual angle between the wing and the fuselage , roll angle , pitch angle represents the third reference angle obtained in step S8.1 , that is, the angle between the left wing and the fuselage, the mathematical expression is: ; Where: Represents the length of the two-dimensional vector of the left wing, and the mathematical expression is: ; S8.3 Using the actual angle between the wing and the fuselage , roll angle , pitch angle represents the fourth reference angle obtained in step S8.1 , that is, the angle between the right wing and the fuselage, the mathematical expression is: ; Where: Represents the length of the right wing two-dimensional vector, which is approximately equal to , the mathematical expression is: ; S8.4 Combine the two wing-fuselage angle formulas obtained in steps S8.2 and S8.3 to obtain the second angle of pitch and roll. Relational model, mathematical expression is: ; S8.5 Calculate the pitch angle based on the second relationship model obtained in step S8.

4. The mathematical expression is: 。

Citation Information

Patent Citations

  • Unmanned aerial vehicle attitude estimation method and system based on three-color four-lamp mark recognition

    CN111784768A

  • Vision-based bionic flapping-wing unmanned aerial vehicle space pose estimation method

    CN117115252A