A method, device and electronic device for processing non-cooperative target posture
Through depth camera and ellipse detection technology, the problem of accuracy of attitude estimation of non-African cooperation targets in drone technology is solved, accurate pose calculation of circular feature objects is achieved, and the capabilities of drone navigation and autonomous navigation are improved.
Patent Information
- Application Number
- CN202210689582.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-16
- Publication Date
- 2024-10-18
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
It is difficult to accurately achieve attitude estimation of non-cooperative targets with existing technology. Especially in UAV technology, ellipse recognition based on monocular vision has problems with binary and dimensional information loss.
Use a depth camera to acquire images of non-cooperative targets, perform ellipse detection, determine the correspondence between spherical curve equations and elliptic curves, calculate the attitude angle of the torus curve, and obtain image plane feature points, and then calculate the pose parameters of the non-cooperative targets.
It achieves accurate pose estimation of objects with unknown circular center and unknown radius, and improves the accuracy of pose estimation of non-cooperative targets.
Smart Images

Figure CN115131433B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of unmanned aerial vehicles, and in particular to a method, device and electronic equipment for processing the posture of a non-cooperative target. Background Art
[0002] Non-cooperative targets refer to the real position information of the detected target, which can only be directly measured by the sensor, and there is no other technical means to obtain the accurate position of the target. It is difficult to expand from the common two-dimensional cooperative target form to the spatial non-cooperative target in the actual environment, and then to achieve accurate drone pose estimation. As a common centrally symmetrical geometric body, the ring has long been valued for solving engineering problems using its geometric features. The projection of a spatial ring on the image plane at any angle is one of the three forms of a straight line, an ellipse and a circle, and the straight line and circle features are two extreme cases. Ellipse recognition based on monocular vision can theoretically reconstruct a spatial ring body in three dimensions, but it has binary properties and it is difficult to accurately eliminate false solutions through numerical calculations. At the same time, the rings in industrial production and engineering practice often have no obvious texture. When using their elliptical features for three-dimensional reconstruction, dimensional information will be lost, and accurate pose estimation cannot be achieved.
[0003] With respect to the problem that the above-mentioned related technologies cannot accurately realize the posture estimation of non-cooperative targets, no effective solution has been proposed yet. Summary of the invention
[0004] The embodiments of the present invention provide a method, device and electronic device for processing the posture of a non-cooperative target, so as to at least solve the technical problem that the posture estimation of a non-cooperative target cannot be accurately realized in the related art.
[0005] According to one aspect of an embodiment of the present invention, a method for processing the posture of a non-cooperative target is provided, comprising: acquiring an image of a non-cooperative target based on a depth camera, wherein the non-cooperative target includes an object with circular surface features; performing ellipse detection on the image to obtain an ellipse detection result, and obtaining ellipse parameters; determining the correspondence between a spherical curve equation and an elliptic curve equation, wherein the spherical curve equation is a parametric equation obtained by orthographically projecting a circular ring curve on a spherical surface onto a spherical coordinate system, and the elliptic curve equation is a parametric equation obtained by orthographically projecting an elliptic curve in the ellipse detection result onto the spherical coordinate system; calculating the posture angle of the circular ring curve in the spherical coordinate system according to the ellipse parameters and the corresponding relationship; acquiring image plane feature points, wherein the image plane feature points are projection points of feature points marked in the ellipse detection on the spherical surface; and calculating the posture parameters of the non-cooperative target according to the posture angle and the image plane feature points.
[0006] Optionally, an ellipse detection is performed on the image to obtain an ellipse detection result, including: performing edge extraction on the image and dividing the extracted edge lines into multiple arc segments; constructing an adjacency matrix based on the multiple arc segments, and sparsely processing the adjacency matrix using curvature constraints and area constraints to obtain a target matrix, wherein each element of the adjacency matrix is used to represent multiple different adjacency states; performing forward search, reverse search and bidirectional combined verification on the target matrix to obtain a set of candidate arc segments; generating a fitting matrix based on the set of candidate arc segments, and performing two eigendecompositions on the fitting matrix to obtain an ellipse curve; verifying the ellipse curve according to preset indicators, and taking the ellipse curve with a verification score greater than a verification threshold as the ellipse detection result, wherein the preset indicators include at least one of the following: a shape indicator, a position indicator, a gradient indicator, and a weighted indicator.
[0007] Optionally, determining the correspondence between the spherical curve equation and the elliptic curve equation includes: converting the elliptic curve into the torus curve, and establishing the correspondence between the spherical curve equation and the elliptic curve equation.
[0008] Optionally, obtaining image plane feature points includes: performing Hough line detection on the image to obtain candidate lines; determining the intersection of the candidate lines and the elliptic curve in the ellipse detection result as feature points; verifying the feature points and marking the feature points that have passed the verification to obtain target feature points; and determining the projection point of the target feature point on the spherical surface as the image plane feature point.
[0009] Optionally, the pose parameters of the non-cooperative target are calculated based on the attitude angle and the image plane feature point, including: obtaining the camera coordinate system of the depth camera, wherein the attitude angle is used as the Euler angle of the camera coordinate system relative to the ground coordinate system; respectively determining the coordinates of the center of the circular curve in the camera coordinate system, the coordinates of the center of the ellipse in the image principal point coordinate system in the camera coordinate system, and the coordinates of the center of the ellipse in the image principal point coordinate system; obtaining the coordinates of the image plane feature point corresponding to the point of the circular curve in the ground coordinate system; determining the pose parameters of the non-cooperative target based on the coordinates of the center of the ellipse in the image principal point coordinate system and the coordinates of the image plane feature point corresponding to the point of the circular curve in the ground coordinate system.
[0010] According to another aspect of an embodiment of the present invention, a device for processing the posture of a non-cooperative target is also provided, including: a first acquisition module, used to acquire an image of a non-cooperative target based on a depth camera, wherein the non-cooperative target includes an object with circular surface features; a detection module, used to perform ellipse detection on the image, obtain an ellipse detection result, and obtain ellipse parameters; a determination module, used to determine the correspondence between a spherical curve equation and an elliptic curve equation, wherein the spherical curve equation is a parametric equation obtained by projecting a circular ring curve on a spherical surface onto a spherical coordinate system, and the elliptic curve equation is a parametric equation obtained by projecting an elliptic curve in the ellipse detection result onto the spherical coordinate system; a first calculation module, used to calculate the posture angle of the circular ring curve in the spherical coordinate system according to the ellipse parameters and the corresponding relationship; a second acquisition module, used to acquire image plane feature points, wherein the image plane feature points are projection points of feature points marked in ellipse detection on the spherical surface; a second calculation module, used to calculate the posture parameters of the non-cooperative target according to the posture angle and the image plane feature points.
[0011] Optionally, the detection module includes: an extraction and segmentation unit, which is used to extract edges from the image and segment the extracted edge lines into multiple arc segments; a first processing unit, which is used to construct an adjacency matrix based on the multiple arc segments, and use curvature constraints and area constraints to perform sparse processing on the adjacency matrix to obtain a target matrix, wherein each element of the adjacency matrix is used to represent multiple different adjacency states; a second processing unit, which is used to perform forward search, reverse search and bidirectional combination verification on the target matrix to obtain a set of candidate arc segments; a fitting decomposition unit, which is used to generate a fitting matrix based on the set of candidate arc segments, and perform two eigendecompositions on the fitting matrix to obtain an elliptic curve; a verification unit, which is used to verify the elliptic curve according to preset indicators, and use the elliptic curve with a verification score greater than a verification threshold as the ellipse detection result, wherein the preset indicators include at least one of the following: shape indicator, position indicator, gradient indicator and weighted indicator.
[0012] Optionally, the determination module includes: an establishment unit, used to convert the elliptic curve into the torus curve, and establish the corresponding relationship between the spherical curve equation and the elliptic curve equation.
[0013] According to another aspect of an embodiment of the present invention, there is also provided an electronic device, comprising: a processor; and a memory for storing processor-executable instructions; wherein the processor is configured to execute any one of the method steps described above.
[0014] According to another aspect of an embodiment of the present invention, a computer-readable storage medium is further provided, wherein the computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute any one of the method steps described above.
[0015] In an embodiment of the present invention, a depth camera is used to obtain an image of a non-cooperative target, wherein the non-cooperative target includes an object with circular surface features; an ellipse detection is performed on the image to obtain an ellipse detection result, and the ellipse parameters are obtained; the correspondence between the spherical curve equation and the elliptic curve equation is determined, wherein the spherical curve equation is a parametric equation obtained by orthographically projecting the circular ring curve on the spherical surface to the spherical coordinate system, and the elliptic curve equation is a parametric equation obtained by orthographically projecting the elliptic curve in the ellipse detection result to the spherical coordinate system; according to the ellipse parameters and the corresponding relationship, the attitude angle of the circular ring curve in the spherical coordinate system is calculated; image plane feature points are obtained, wherein the image plane feature points are projection points of the feature points marked in the ellipse detection on the spherical surface; according to the attitude angle and the image plane feature points, the posture parameters of the non-cooperative target are calculated. In other words, the embodiment of the present invention can independently estimate the posture of an object with circular surface features whose center and radius are unknown, relying only on visual information, thereby solving the technical problem that the non-cooperative target posture estimation cannot be accurately realized in the related technology, and achieving the technical effect of improving the accuracy of the non-cooperative target posture estimation. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0017] Figure 1 A flowchart of a method for processing a non-cooperative target posture provided by an embodiment of the present invention;
[0018] Figure 2 A flowchart of an ellipse detection algorithm provided by an embodiment of the present invention;
[0019] Figure 3 A schematic diagram of a spherical coordinate system, a torus curve and the angular relationship between the two provided in an embodiment of the present invention;
[0020] Figure 4 A schematic diagram of a projection axis system corresponding to a spherical coordinate system and a torus curve provided in an embodiment of the present invention;
[0021] Figure 5 A flow chart of feature point marking in ellipse detection provided by an embodiment of the present invention;
[0022] Figure 6A schematic diagram of a non-cooperative target posture processing device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0023] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0024] It should be noted that the terms "first", "second" and the like in the specification, claims and drawings of the present invention are used to distinguish different objects rather than to limit a specific order.
[0025] According to one aspect of an embodiment of the present invention, a method for processing a non-cooperative target posture is provided. Figure 1 A flowchart of a method for processing a non-cooperative target posture provided by an embodiment of the present invention is shown in FIG. Figure 1 As shown, the method comprises the following steps:
[0026] Step S102, acquiring an image of a non-cooperative target based on a depth camera, wherein the non-cooperative target includes an object having a round surface feature;
[0027] The above-mentioned depth camera can be mounted on the target object, and it is used as a part of the target object structure to obtain images of non-cooperative targets. The target object can be a drone or other equipment.
[0028] Step S104, performing ellipse detection on the image to obtain an ellipse detection result and acquire ellipse parameters;
[0029] The above ellipse parameters include but are not limited to the ellipse semi-major axis, semi-minor axis and required angle.
[0030] Step S106, determining the correspondence between the spherical curve equation and the elliptic curve equation, wherein the spherical curve equation is a parametric equation obtained by orthographically projecting the torus curve on the sphere onto the spherical coordinate system, and the elliptic curve equation is a parametric equation obtained by orthographically projecting the elliptic curve in the ellipse detection result onto the spherical coordinate system;
[0031] Step S108, calculating the attitude angle of the torus curve in the spherical coordinate system according to the ellipse parameters and the corresponding relationship;
[0032] The above circular curve has at least two attitude angles in the spherical coordinate system.
[0033] Step S110, obtaining image plane feature points, wherein the image plane feature points are projection points of feature points marked in ellipse detection on the spherical surface;
[0034] It should be noted that the image plane is the imaging plane. For example, if a film camera is used to shoot, the film is the image plane; if a depth camera is used to shoot, the image plane is a photosensitive element such as a CCD.
[0035] Step S112, calculating the posture parameters of the non-cooperative target according to the posture angle and the image plane feature points.
[0036] In the specific implementation process, the attitude angle and the image plane feature point are used as the parameters of the coordinate system conversion. The posture parameters of the non-cooperative target are obtained through the conversion between the image principal point coordinate system, the camera coordinate system, the spherical coordinate system and the ground coordinate system. The posture parameters of the non-cooperative target include the coordinate position of the non-cooperative target in the ground coordinate system.
[0037] In an embodiment of the present invention, a depth camera is used to obtain an image of a non-cooperative target, wherein the non-cooperative target includes an object with circular surface features; an ellipse detection is performed on the image to obtain an ellipse detection result, and the ellipse parameters are obtained; the correspondence between the spherical curve equation and the elliptic curve equation is determined, wherein the spherical curve equation is a parametric equation obtained by orthographically projecting the circular ring curve on the spherical surface to the spherical coordinate system, and the elliptic curve equation is a parametric equation obtained by orthographically projecting the elliptic curve in the ellipse detection result to the spherical coordinate system; according to the ellipse parameters and the corresponding relationship, the attitude angle of the circular ring curve in the spherical coordinate system is calculated; image plane feature points are obtained, wherein the image plane feature points are projection points of the feature points marked in the ellipse detection on the spherical surface; according to the attitude angle and the image plane feature points, the posture parameters of the non-cooperative target are calculated. In other words, the embodiment of the present invention can independently estimate the posture of an object with circular surface features whose center and radius are unknown, relying only on visual information, thereby solving the technical problem that the non-cooperative target posture estimation cannot be accurately realized in the related technology, and achieving the technical effect of improving the accuracy of the non-cooperative target posture estimation.
[0038] It should be noted that the application scenarios of the above method include but are not limited to: industrial robots, aircraft, vehicles and drones. For example, many workpieces operated by industrial robots have circular surface features and no obvious textures; for another example, the plane of the oil pipe orifice of the receiving aircraft during aerial refueling is generally also a circular surface; for another example, due to the complex mission environment of drones, it is difficult to ensure the accuracy of various non-autonomous navigation methods. Using visual information to achieve navigation or autonomous landing is an important direction for the development of drones. Non-cooperative targets such as incoming air missiles, enemy aircraft or ground buildings within the visual range have obvious circular surface features. The above method of the present invention can rely solely on visual information to independently estimate the pose of objects with circular surface features with unknown center and radius, providing new ideas for autonomous navigation and perception of drones based on non-cooperative targets.
[0039] In an optional embodiment, an ellipse detection is performed on an image to obtain an ellipse detection result, including: performing edge extraction on the image and dividing the extracted edge lines into multiple arc segments; constructing an adjacency matrix based on the multiple arc segments, and sparsely processing the adjacency matrix using curvature constraints and area constraints to obtain a target matrix, wherein each element of the adjacency matrix is used to represent a plurality of different adjacency states; performing forward search, reverse search and bidirectional combined verification on the target matrix to obtain a set of candidate arc segments; generating a fitting matrix based on the set of candidate arc segments, and performing two eigendecompositions on the fitting matrix to obtain an ellipse curve; verifying the ellipse curve according to preset indicators, and taking the ellipse curve having a verification score greater than a verification threshold as the ellipse detection result, wherein the preset indicators include at least one of the following: a shape indicator, a position indicator, a gradient indicator and a weighted indicator.
[0040] The above-mentioned preset indexes include but are not limited to shape indexes, position indexes, gradient indexes, and weighted indexes, etc. In the specific implementation process, the preset indexes can be set according to the needs of the application scenario.
[0041] In the specific implementation process, it is first necessary to extract the edge of the image, and divide the extracted edge lines into multiple arc segments, then construct an adjacency matrix based on the multiple arc segments, and use curvature constraints and area constraints to sparse the adjacency matrix to obtain a target matrix, and then perform forward search, reverse search and two-way combination verification on the target matrix to obtain a candidate arc segment set, and then generate a fitting matrix based on the candidate arc segment set, and perform two eigendecompositions on the fitting matrix to obtain an elliptic curve, and finally verify the elliptic curve according to the preset index, and take the elliptic curve with a verification score greater than the verification threshold as the ellipse detection result. Through this ellipse detection method for images, false elliptic curves can be effectively eliminated to ensure the accuracy of elliptic curves.
[0042] In an optional implementation, determining the correspondence between the spherical curve equation and the elliptic curve equation includes: converting the elliptic curve into a torus curve, and establishing the correspondence between the spherical curve equation and the elliptic curve equation.
[0043] It should be noted that the conversion from a two-dimensional elliptic curve to a three-dimensional spherical curve not only needs to ensure the consistency of the parameter direction on the projection plane, so that any parallel projection of a plane elliptic curve onto a three-dimensional sphere is a ring, but also needs to establish a correspondence between the spherical curve equation and the elliptic curve equation. This correspondence is also the corresponding condition between the spherical curve equation and the elliptic curve equation, which can effectively ensure that any parallel projection of a plane elliptic curve onto a three-dimensional sphere is a ring, facilitating subsequent conversion between coordinate systems.
[0044] In an optional embodiment, obtaining image plane feature points includes: performing Hough line detection on the image to obtain candidate lines; determining the intersection of the candidate lines and the elliptic curve in the ellipse detection result as feature points; verifying the feature points and marking the verified qualified feature points to obtain target feature points; and determining the projection points of the target feature points on the sphere as image plane feature points.
[0045] In the specific implementation process, a grayscale image in the ellipse detection can be obtained, and then Hough line detection can be performed on the grayscale image to detect candidate lines. The intersection of the candidate lines and the ellipse curve in the ellipse detection result is used as a feature point; in order to ensure the accuracy of the feature points, the feature points can be verified, and the verified qualified feature points can be marked as target feature points; finally, the projection points of the target feature points on the sphere are recorded as image plane feature points. The image plane feature points can be accurately obtained through the above implementation method. It should be noted that the number of the above image plane feature points is at least two.
[0046] In an optional embodiment, the posture parameters of the non-cooperative target are calculated based on the posture angle and the image plane feature points, including: obtaining the camera coordinate system of the depth camera, wherein the posture angle is the Euler angle of the camera coordinate system relative to the ground coordinate system; respectively determining the coordinates of the center of the circular curve in the camera coordinate system, the coordinates of the center of the ellipse in the image principal point coordinate system in the camera coordinate system, and the coordinates of the center of the ellipse in the image principal point coordinate system; obtaining the coordinates of the image plane feature points corresponding to the points on the circular curve in the ground coordinate system; determining the posture parameters of the non-cooperative target based on the coordinates of the center of the ellipse in the image principal point coordinate system and the coordinates of the image plane feature points corresponding to the points on the circular curve in the ground coordinate system.
[0047] In the specific implementation process, it is necessary to obtain the camera coordinate system of the depth camera. At this time, the attitude angle is used as the Euler angle of the camera coordinate system relative to the ground coordinate system, and then the coordinates of the center of the circular curve in the camera coordinate system, the coordinates of the center of the ellipse in the image principal point coordinate system in the camera coordinate system, and the coordinates of the center of the ellipse in the image principal point coordinate system are determined respectively. Then, the coordinates of the points on the circular curve corresponding to the image plane feature points in the ground coordinate system are obtained, and then the pose parameters of the non-cooperative target are obtained according to the coordinates of the center of the ellipse in the image principal point coordinate system and the coordinates of the points on the circular curve corresponding to the image plane feature points in the ground coordinate system.
[0048] Through the above implementation, the position conversion between coordinate systems can be directly used to determine the pose parameters of the non-cooperative target, thus avoiding the loss of dimensional information and greatly improving the accuracy of the non-cooperative target pose estimation.
[0049] An optional implementation manner of the present invention is described in detail below.
[0050] An optional embodiment of the present invention provides a method for estimating the posture of a drone using ellipse detection of axonometric projection of a space ring, and the specific implementation process includes the following steps:
[0051] 1. Fast ellipse detection based on arc adjacency matrix
[0052] Figure 2 A flowchart of an ellipse detection algorithm provided by an embodiment of the present invention is shown in FIG. Figure 2 As shown in the figure, the input image is firstly edge extracted using the Canny adaptive algorithm to extract isolated edge pixels, and then the extracted edge lines are divided into elliptical arcs. Then a directed arc segment adjacency matrix is constructed. Each element of the matrix represents three adjacency states, and the curvature constraint and area constraint are used to make the active appearance model (AAM) matrix sparse. Secondly, arc segment selection is performed, which is divided into three steps: forward search, reverse search and bidirectional combination verification of the AAM matrix, to obtain all candidate arc segment sets that may be real ellipses. Then, ellipse fitting is performed, and each arc segment corresponds to an accumulation matrix. Then an arc segment combination is the sum of several arc segment accumulation matrices, so as to obtain a fitting matrix (Connection Matrix, CM) required for a combination. The Jacobi method is used to perform two feature decompositions on the CM to effectively fit the ellipse. Finally, the ellipse verification is performed, and the comprehensive verification score is obtained based on the shape index, position index, gradient index and weighted index, and the verification threshold is set to eliminate false ellipses and obtain the final ellipse detection result.
[0053] 2. Establish the axonometric projection model of the spherical ring
[0054] For the surface of a sphere, the radius R of the sphere and the two angles θ, The only representation is that, with the center O as the origin (0,0,0), a spherical coordinate system is established, and the parametric equation of the sphere S with a radius of R is:
[0055]
[0056] Let C be a circular curve on the sphere, with radius r and center O C , O′ C is called the spherical center of the torus C. In order to derive the expression of the torus C, Figure 3 A schematic diagram of a spherical coordinate system, a circular curve and the angle relationship between the two provided in an embodiment of the present invention, such as Figure 3 As shown, establish the space ring coordinate system O C x′y′z′, and make O C The z′ axis is coplanar with the Oz axis. Using the rotation transformation, the coordinates of any point on the circular curve C [X C Y C Z C ] can be rotated clockwise around the y′ axis Then rotate θ counterclockwise around z′ to obtain.
[0057]
[0058] Where [x′ y′ z′] T is any point on the ring in the ring coordinate system O C x′y′z′ coordinates, [x′ 0 y′ 0 z′ 0 ] T O is the origin C Coordinates in spherical coordinate system.
[0059] Therefore, the parametric equation of curve C is:
[0060]
[0061] Project the torus onto the xOz surface of the spherical coordinate system to obtain the quadratic curve S. It is easy to obtain the parametric equation of S:
[0062]
[0063] Figure 4 A schematic diagram of a projection axis system corresponding to a spherical coordinate system and a torus curve provided by an embodiment of the present invention, such as Figure 4 As shown, the plane xOz coordinate system is Figure 3As shown in the figure, the projection of any spherical ring is a perfect circle or ellipse, and no irregular circle will appear. Assume that the rectangular coordinate system is established with the semi-major and minor axes a and b of the projected ellipse The angle between the axis and the x-axis of the spherical coordinate system is β. In the axis system, it can be expressed as:
[0064]
[0065] Among them, 0≤t≤2π.
[0066] Then the expression of the ellipse equation in the xOz axis system can be obtained through a rotation transformation.
[0067]
[0068] The conversion from a two-dimensional elliptic curve to a three-dimensional torus requires the consistency of the parameter direction on the projection plane, that is, u=t, u∈[0,2π). When a planar elliptic curve is parallel projected onto a three-dimensional sphere, the criterion for ensuring that it is a torus is that the equation of the spherical curve can correspond to the planar ellipse. The corresponding conditions are as follows:
[0069]
[0070] The information from the airborne visual sensor combined with the ellipse detection algorithm can be used to obtain the ellipse's semi-major axis a, semi-minor axis b, and the required angle β, and then the above formula can be used to solve the attitude angle of the ring in the spherical coordinate system. θ.
[0071] 3. Calculation of pose parameters
[0072] It should be noted that in the process of 3D reconstruction of the torus projection, it is projected onto the xOz surface of the spherical coordinate system, so the camera coordinate system O′ C x C y C z C The camera optical axis direction O C y C It should be parallel to the y direction of the spherical coordinate system, that is, the camera coordinate system x C O′ C z C The plane coincides with the xOz plane of the spherical coordinate system. Then the conversion relationship between the camera coordinate system and the spherical coordinate system is:
[0073]
[0074] Among them, [x 0 y 0 z 0 ] Tis the coordinate of the origin of the camera coordinate system (i.e. the camera focus) in the spherical coordinate system.
[0075] Since the ring is a centrally symmetrical figure with the center of the circle as the symmetry center, the drone attitude estimation by identifying the space ring will lose information. This is also the reason why only the spherical coordinate system can be used. The two angles θ represent the posture of the space ring. Figure 5 A flowchart of feature point marking in ellipse detection provided by an embodiment of the present invention is as follows: Figure 5 As shown, for specific scenarios, feature point annotation during ellipse detection can effectively solve this problem.
[0076] The projection points of the two feature points on the sphere are recorded as P and P′. The transformation relationship between the spherical coordinate system and the ground coordinate system is determined by the placement of the space ring. For simplicity, it is assumed that the center of the space ring is the axis of the ground coordinate system O g , the plane where the ring is located is the ground coordinate system y g O g z g Plane, O C P direction is O g y g Axis. Then the three Euler angles of the camera coordinate system relative to the ground coordinate system are θ, ψ, where ψ is the circular coordinate system O g y′ axis and O C The angle of P, and θ, ψ∈(-π,π).
[0077] The center of the ellipse in the image principal point coordinate system is the projection of the center of the ring on the image plane, let its coordinates be [uw] T , then the coordinates of the point in the camera coordinate system are [udw] T , d is the equivalent focal length, obtained by camera calibration. The corresponding ring center O C The coordinate in the ground coordinate system is
[000] T .O C The coordinates in the camera coordinate system are obtained by the following formula:
[0078]
[0079] Among them, T gs is the coordinate transformation matrix of the ground coordinate system relative to the spherical coordinate system, [x 1 y 1 z 1 ] T is the position of the axis of the camera coordinate system in the ground coordinate system.
[0080] The coordinates in the camera coordinate system are:
[0081]
[0082] and then The coordinates in the image principal point coordinate system are:
[0083]
[0084] The coordinates of the image plane feature points P and P′ corresponding to the points of the space ring in the ground coordinate system are [0 r 0] T , [0 -r 0] T , substituting into the above formula, we get:
[0085]
[0086]
[0087] The least squares solution of the above equation is:
[0088]
[0089] in,
[0090]
[0091]
[0092] It should be noted that this method only uses the sensor data of the airborne depth camera to identify the circular surface features of the space ring to achieve its own posture solution. At the same time, it can also combine the posture calculation results of this method with other schemes for combined navigation to obtain a more accurate algorithm.
[0093] According to another aspect of an embodiment of the present invention, a device for processing a non-cooperative target posture is also provided. Figure 6 A schematic diagram of a non-cooperative target posture processing device provided by an embodiment of the present invention, such as Figure 6 As shown, the non-cooperative target posture processing device includes: a first acquisition module 602, a detection module 604, a determination module 606, a first calculation module 608, a second acquisition module 610 and a second calculation module 612. The non-cooperative target posture processing device is described in detail below.
[0094] A first acquisition module 602 is used to acquire an image of a non-cooperative target based on a depth camera, wherein the non-cooperative target includes an object with a round surface feature;
[0095] The detection module 604 is connected to the first acquisition module 602 and is used to perform ellipse detection on the image, obtain ellipse detection results, and obtain ellipse parameters;
[0096] A determination module 606, connected to the detection module 604, is used to determine the correspondence between the spherical curve equation and the elliptic curve equation, wherein the spherical curve equation is a parametric equation obtained by orthographically projecting the torus curve on the sphere onto the spherical coordinate system, and the elliptic curve equation is a parametric equation obtained by orthographically projecting the elliptic curve in the ellipse detection result onto the spherical coordinate system;
[0097] A first calculation module 608, connected to the determination module 606, is used to calculate the attitude angle of the torus curve in the spherical coordinate system according to the ellipse parameters and the corresponding relationship;
[0098] A second acquisition module 610, connected to the first calculation module 608, is used to acquire image plane feature points, wherein the image plane feature points are projection points of feature points marked in ellipse detection on the spherical surface;
[0099] The second calculation module 612 is connected to the second acquisition module 610 and is used to calculate the posture parameters of the non-cooperative target according to the posture angle and the image plane feature points.
[0100] In an embodiment of the present invention, the processing device for the posture of the non-cooperative target adopts a depth camera to obtain an image of the non-cooperative target, wherein the non-cooperative target includes an object with circular surface features; performs ellipse detection on the image to obtain an ellipse detection result, and obtains ellipse parameters; determines the correspondence between the spherical curve equation and the elliptic curve equation, wherein the spherical curve equation is a parameter equation obtained by orthographically projecting the circular ring curve on the spherical surface to the spherical coordinate system, and the elliptic curve equation is a parameter equation obtained by orthographically projecting the elliptic curve in the ellipse detection result to the spherical coordinate system; calculates the posture angle of the circular ring curve in the spherical coordinate system according to the ellipse parameters and the corresponding relationship; obtains image plane feature points, wherein the image plane feature points are projection points of the feature points marked in the ellipse detection on the spherical surface; calculates the posture parameters of the non-cooperative target according to the posture angle and the image plane feature points. In other words, the embodiment of the present invention can independently estimate the posture of an object with circular surface features whose center and radius are unknown only by relying on visual information, thereby solving the technical problem that the non-cooperative target posture estimation cannot be accurately realized in the related technology, and achieving the technical effect of improving the accuracy of the non-cooperative target posture estimation.
[0101] It should be noted here that the above-mentioned first acquisition module 602, detection module 604, determination module 606, first calculation module 608, second acquisition module 610 and second calculation module 612 correspond to steps S102 to S112 in the method embodiment, and the examples and application scenarios implemented by the above-mentioned modules and corresponding steps are the same, but are not limited to the contents disclosed in the above-mentioned method embodiment.
[0102] Optionally, the above-mentioned detection module 604 includes: an extraction and segmentation unit, which is used to extract edges of the image and segment the extracted edge lines into multiple arc segments; a first processing unit, which is used to construct an adjacency matrix based on the multiple arc segments, and use curvature constraints and area constraints to perform sparse processing on the adjacency matrix to obtain a target matrix, wherein each element of the adjacency matrix is used to represent a plurality of different adjacency states; a second processing unit, which is used to perform forward search, reverse search and bidirectional combination verification on the target matrix to obtain a set of candidate arc segments; a fitting decomposition unit, which is used to generate a fitting matrix based on the set of candidate arc segments, and perform two eigendecompositions on the fitting matrix to obtain an elliptic curve; a verification unit, which is used to verify the elliptic curve according to preset indicators, and take the elliptic curve with a verification score greater than a verification threshold as the ellipse detection result, wherein the preset indicators include at least one of the following: shape indicator, position indicator, gradient indicator and weighted indicator.
[0103] Optionally, the determination module 606 includes: an establishment unit, configured to convert the elliptic curve into a torus curve, and establish a corresponding relationship between the spherical curve equation and the elliptic curve equation.
[0104] Optionally, the second acquisition module 610 includes: a detection unit, used to perform Hough line detection on the image to obtain candidate lines; a first determination unit, used to determine the intersection of the candidate line and the elliptic curve in the ellipse detection result as a feature point; a labeling unit, used to verify the feature points and label the feature points that have passed the verification to obtain target feature points; a second determination unit, used to determine the projection point of the target feature point on the spherical surface as the image plane feature point.
[0105] Optionally, the above-mentioned second calculation module 612 includes: a first acquisition unit, used to acquire the camera coordinate system of the depth camera, wherein the posture angle is used as the Euler angle of the camera coordinate system relative to the ground coordinate system; a third determination unit, used to respectively determine the coordinates of the center of the circular curve in the camera coordinate system, the coordinates of the center of the ellipse in the image principal point coordinate system in the camera coordinate system, and the coordinates of the center of the ellipse in the image principal point coordinate system; a second acquisition unit, used to acquire the coordinates of the image plane feature point corresponding to the point of the circular curve in the ground coordinate system; a fourth determination unit, used to determine the posture parameters of the non-cooperative target according to the coordinates of the center of the ellipse in the image principal point coordinate system and the coordinates of the image plane feature point corresponding to the point of the circular curve in the ground coordinate system.
[0106] According to another aspect of an embodiment of the present invention, there is further provided an electronic device, comprising: a processor; and a memory for storing instructions executable by the processor; wherein the processor is configured to execute any one of the above method steps.
[0107] According to another aspect of an embodiment of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium including a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute any one of the above method steps.
[0108] It should be noted that the above-mentioned computer-readable storage medium can be located in any computer terminal in a computer terminal group in a computer network, and / or located in any mobile terminal in a mobile terminal group, and the above-mentioned computer-readable storage medium includes a stored program.
[0109] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention.
Claims
1. A method for processing non-cooperative target pose, characterized in that: include: Acquiring an image of a non-cooperative target based on a depth camera, wherein the non-cooperative target includes an object having a round surface feature; Performing ellipse detection on the image to obtain an ellipse detection result and acquire ellipse parameters; Determine a correspondence between a spherical curve equation and an elliptic curve equation, wherein the spherical curve equation is a parametric equation obtained by orthographically projecting a torus curve on a sphere onto a spherical coordinate system, and the elliptic curve equation is a parametric equation obtained by orthographically projecting an elliptic curve in the ellipse detection result onto the spherical coordinate system; Calculating the attitude angle of the torus curve in the spherical coordinate system according to the ellipse parameters and the corresponding relationship; Acquire image plane feature points, wherein the image plane feature points are projection points of feature points marked in ellipse detection on the spherical surface; The posture parameters of the non-cooperative target are calculated according to the posture angle and the image plane feature points.
2. The method according to claim 1, characterized in that Performing ellipse detection on the image to obtain an ellipse detection result includes: Extracting edges from the image, and dividing the extracted edge lines into a plurality of arc segments; An adjacency matrix is constructed according to the plurality of arc segments, and the adjacency matrix is sparsely processed by using a curvature constraint and an area constraint to obtain a target matrix, wherein each element of the adjacency matrix is used to represent a plurality of different adjacency states; Performing forward search, backward search and bidirectional combination verification on the target matrix to obtain a set of candidate arc segments; Generate a fitting matrix according to the candidate arc segment set, and perform two eigendecompositions on the fitting matrix to obtain an elliptic curve; The elliptic curve is verified according to a preset indicator, and the elliptic curve with a verification score greater than a verification threshold is used as the ellipse detection result, wherein the preset indicator includes at least one of the following: a shape indicator, a position indicator, a gradient indicator, and a weighted indicator.
3. The method according to claim 1, characterized in that Determine the correspondence between the spherical curve equation and the elliptic curve equation, including: The elliptic curve is converted into the torus curve, and the corresponding relationship between the spherical curve equation and the elliptic curve equation is established.
4. The method according to claim 1, characterized in that: Get image plane feature points, including: Performing Hough line detection on the image to obtain candidate lines; Determine an intersection point between the candidate straight line and the elliptic curve in the ellipse detection result as a feature point; Verifying the feature points, and marking the feature points that pass the verification, to obtain target feature points; The projection point of the target feature point on the spherical surface is determined as the image plane feature point.
5. The method according to any one of claims 1 to 4, characterized in that Calculating the posture parameters of the non-cooperative target according to the posture angle and the image plane feature point includes: Acquire a camera coordinate system of a depth camera, wherein the attitude angle is used as the Euler angle of the camera coordinate system relative to a ground coordinate system; Determine the coordinates of the center of the circular curve in the camera coordinate system, the coordinates of the center of the ellipse in the image principal point coordinate system in the camera coordinate system, and the coordinates of the center of the ellipse in the image principal point coordinate system respectively; Obtaining the coordinates of the point on the image plane corresponding to the circular curve in the ground coordinate system; The pose parameters of the non-cooperative target are determined according to the coordinates of the center of the ellipse in the image principal point coordinate system and the coordinates of the image plane feature point corresponding to the point of the circular curve in the ground coordinate system.
6. A device for processing non-cooperative target posture, characterized in that: include: A first acquisition module is used to acquire an image of a non-cooperative target based on a depth camera, wherein the non-cooperative target includes an object with a round surface feature; A detection module, used to perform ellipse detection on the image, obtain ellipse detection results, and acquire ellipse parameters; A determination module, used to determine the correspondence between a spherical curve equation and an elliptic curve equation, wherein the spherical curve equation is a parametric equation obtained by orthographically projecting a torus curve on a sphere onto a spherical coordinate system, and the elliptic curve equation is a parametric equation obtained by orthographically projecting an elliptic curve in the ellipse detection result onto the spherical coordinate system; A first calculation module, used for calculating the attitude angle of the circular curve in the spherical coordinate system according to the ellipse parameters and the corresponding relationship; A second acquisition module is used to acquire image plane feature points, wherein the image plane feature points are projection points of feature points marked in ellipse detection on the spherical surface; The second calculation module is used to calculate the posture parameters of the non-cooperative target according to the posture angle and the image plane feature points.
7. The device according to claim 6, characterized in that The detection module comprises: An extraction and segmentation unit, used for performing edge extraction on the image and segmenting the extracted edge lines into a plurality of arc segments; A first processing unit is used to construct an adjacency matrix according to the plurality of arc segments, and perform sparse processing on the adjacency matrix using a curvature constraint and an area constraint to obtain a target matrix, wherein each element of the adjacency matrix is used to represent a plurality of different adjacency states; A second processing unit is used to perform forward search, backward search and bidirectional combination verification on the target matrix to obtain a candidate arc segment set; A fitting decomposition unit, used for generating a fitting matrix according to the candidate arc segment set, and performing two eigendecompositions on the fitting matrix to obtain an elliptic curve; A verification unit is used to verify the elliptic curve according to a preset indicator, and take the elliptic curve with a verification score greater than a verification threshold as the ellipse detection result, wherein the preset indicator includes at least one of the following: a shape indicator, a position indicator, a gradient indicator, and a weighted indicator.
8. The device according to claim 6, characterized in that The determination module comprises: An establishing unit is used to convert the elliptic curve into the torus curve and establish the corresponding relationship between the spherical curve equation and the elliptic curve equation.
9. An electronic device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to execute the method steps described in any one of claims 1 to 5.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the method steps described in any one of claims 1 to 5.
Citation Information
Patent Citations
Measuring method for relative pose of non-cooperative spatial circular object
CN105509733A
Marker-based non-cooperative target pose measuring method
CN108562274A
