A contour-based method for tracking spatial targets
Through the contour-based method and the use of monocular camera calibration and image processing technology, the problem of visual measurement difficulty in tracking space targets in the space environment is solved, and stable pose tracking under complex lighting conditions is achieved.
Patent Information
- Application Number
- CN202411156526.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-22
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2044-08-22
AI Technical Summary
In the complex space environment, especially under extreme lighting conditions such as strong light and weak light, visual measurement technology is difficult to stably extract and track the characteristic points and lines of space targets, resulting in huge challenges in visual measurement work.
The contour-based spatial target pose tracking method is adopted. By calibrating the monocular camera, the internal parameters of the camera are obtained. The monocular camera is used to capture sequence images of the spatial target, convert the three-dimensional point cloud into a two-dimensional point cloud of the image, and extract the outer contour. For the optical flow of a point, the pixel points in the optical flow direction are calculated as corresponding points, the linear velocity and angular velocity between image frames are solved according to the geometric relationship, and an error function is constructed to solve the pose of the spatial target.
It can stably track fast-moving space targets under complex lighting conditions and achieve continuous pose tracking of space targets.
Smart Images

Figure CN118691647B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a contour-based spatial target posture tracking method. Background Art
[0002] The on-orbit attitude measurement of space targets is one of the key technologies for space observation, on-orbit service, rendezvous and docking and other tasks. The attitude parameters refer to the attitude and position relationship between the space target coordinate system and the observation coordinate system, including the three-degree-of-freedom rotation transformation and the three-degree-of-freedom translation transformation, which are key indicators for measuring and locating the target's motion state. Among the many attitude measurement technologies, such as radar, inertial navigation, star sensors and visual measurement, visual measurement technology stands out with its full autonomy and intuitive visualization characteristics, and has gradually evolved into one of the mainstream means of attitude measurement. However, due to the complexity of the space environment and the influence of extreme lighting conditions such as strong light and weak light, it has become extremely difficult to stably extract and track the feature points and lines of space targets, which undoubtedly brings great challenges to visual measurement. Summary of the invention
[0003] Based on this, it is necessary to provide a contour-based space target posture tracking method that can achieve continuous posture tracking of fast-moving space targets in response to the above technical problems.
[0004] A contour-based space target posture tracking method, the method comprising:
[0005] Step 1: Calibrate the monocular camera and the intrinsic parameters of the camera, including focal length, principal point and distortion coefficient, and use the calibrated monocular camera to observe the moving space target;
[0006] Step 2: Use a monocular camera to shoot the moving space target to obtain a sequence of images of the space target in continuous motion; the sequence of images includes multiple image frames;
[0007] Step 3: For the image frame at the current moment, given the initial posture of the space target, the 3D point cloud of the space target is converted into a 2D point cloud of the image; the outer contour of the 2D point cloud is extracted, and the optical flow of the contour points in the outer contour is solved, including:
[0008] The contour points exist The gray value at the moment is recorded as ,exist The gray value at the moment is recorded as , assuming that the grayscale value of pixels between adjacent frames remains unchanged, we get
[0009]
[0010] Will Perform Taylor expansion:
[0011]
[0012] We can get:
[0013]
[0014] in, represents optical flow;
[0015] Step 4: Search the corresponding pixel points on the image frame along the optical flow direction of the contour points as corresponding points; solve the linear velocity and angular velocity between the image frames according to the geometric relationship between the contour points and the corresponding points;
[0016] Step 5: Define the error function according to the linear velocity and angular velocity between image frames and the distance between the contour point and the corresponding point, and solve the error function to obtain the current position and posture of the space target;
[0017] Step 6: Repeat steps 3 to 5 to process the image frame at the next moment and solve the position and posture of the space target at the next moment.
[0018] In one embodiment, converting a three-dimensional point cloud of a space target into a two-dimensional point cloud of an image includes:
[0019] Assume that the posture and 3D point cloud of the space target are known, at the initial moment The position of is known, using the rotation matrix and translation vectors Indicates that, according to the perspective projection relationship, the three-dimensional model of the target is converted into a two-dimensional point cloud. and the corresponding two-dimensional point , the relationship is as follows:
[0020]
[0021] in, It is a three-dimensional point Depth.
[0022] In one embodiment, solving the linear velocity and angular velocity between image frames according to the geometric relationship between the contour points and the corresponding points includes:
[0023] Assume the three-dimensional velocity of the space target is , then the solutions for linear velocity and angular velocity are and , the object speed formula is
[0024]
[0025] According to the three-dimensional point of the space target and the corresponding two-dimensional point The relationship is derived with respect to time, and the derivative formula is
[0026]
[0027] Using the object velocity formula and the derivative formula, the relationship between the contour point and the corresponding point is established:
[0028]
[0029] in, Represents optical flow, establishes the association between contour points and corresponding points along the direction of optical flow, and solves the linear velocity between image frames and angular velocity .
[0030] In one embodiment, an error function is defined according to the linear velocity and angular velocity between image frames and the distance between the contour point and the corresponding point, and the error function is solved to obtain the position and posture of the space target at the current moment, including:
[0031] Convert the linear velocity and angular velocity between image frames into the posture change between image frames to obtain the relative rotation matrix and the relative translation vector; set the initial posture at the next moment according to the relative rotation matrix and the relative translation vector;
[0032] The error function is defined according to the initial posture at the next moment and the distance between the contour point and the corresponding point, and the posture of the space target at the current moment is obtained by solving the error function.
[0033] In one embodiment, setting the initial posture at the next moment according to the relative rotation matrix and the relative translation vector includes:
[0034] According to the relative rotation matrix and relative translation vector, the initial pose at the next moment is set as
[0035]
[0036] in, is the relative rotation matrix, is the relative translation vector, For the initial moment The rotation matrix of For the initial moment The translation vector of represents the initial rotation matrix at the next moment, Represents the initial translation vector at the next moment.
[0037] In one embodiment, an error function is defined according to an initial pose at a next moment and a distance between a contour point and a corresponding point, including:
[0038] The error function is defined according to the initial pose at the next moment and the distance between the contour point and the corresponding point:
[0039]
[0040] in, Indicates i The contour points, Indicates i The corresponding points of the contour points, Indicates distance, represents the optimized rotation matrix, Represents the optimized translation vector.
[0041] The above-mentioned contour-based space target posture tracking method first calibrates the monocular camera to obtain the camera's internal parameters; uses the monocular camera to collect sequential images of the space target's motion; projects the three-dimensional model of the space target onto the image according to a preset projection relationship; finds the outer contour points of the projection model, extracts the outer contour of the two-dimensional point cloud, solves the optical flow of the contour points in the outer contour, searches for the corresponding pixel points on the image frame along the optical flow direction of the contour points as corresponding points; solves the linear velocity and angular velocity between image frames according to the geometric relationship between the contour points and the corresponding points; calculates the distance between the contour points and the corresponding points as an error term, and constructs an error function according to the linear velocity and angular velocity between image frames and the distance between the contour points and the corresponding points to solve the posture of the space target. In a space environment with complex lighting, the present application can stably track fast-moving space targets. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] Figure 1 The figure is a flowchart of a contour-based space target posture tracking method in one embodiment. DETAILED DESCRIPTION
[0043] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0044] In one embodiment, Figure 1 As shown, a contour-based space target posture tracking method is provided, comprising the following steps:
[0045] Step 1: Calibrate the monocular camera and the intrinsic parameters of the camera, including focal length, principal point and distortion coefficient, and use the calibrated monocular camera to observe the moving space target;
[0046] Step 2: Use a monocular camera to shoot the moving space target and obtain a sequence of images of the space target in continuous motion; the sequence of images includes multiple image frames.
[0047] Due to the complexity of the space environment and the influence of extreme lighting conditions such as strong light and weak light, it becomes extremely difficult to stably extract and track the feature points and lines of space targets. This application uses a monocular camera to observe the moving space target. First, the internal parameters of the camera are calibrated, including focal length, principal point and distortion coefficient, etc., and the monocular camera is used to shoot the moving space target to obtain a sequence of images of the continuous movement of the space target.
[0048] Step 3: For the image frame at the current moment, given the initial posture of the space target, the three-dimensional point cloud of the space target is converted into a two-dimensional point cloud of the image; the outer contour of the two-dimensional point cloud is extracted, and the optical flow of the contour points in the outer contour is solved.
[0049] Assume that the posture and 3D point cloud of the space target are known, at the initial moment The position of is known, using the rotation matrix and translation vectors According to the perspective projection relationship, the three-dimensional model of the target is converted into a two-dimensional point cloud. and the corresponding two-dimensional point , the relationship is as follows:
[0050] (1)
[0051] in, It is a three-dimensional point Depth.
[0052] The contour points exist The gray value at the moment is recorded as ,exist The gray value at the moment is recorded as , assuming that the grayscale value of pixels between adjacent frames remains unchanged, we get:
[0053]
[0054] Taylor expansion of the above formula:
[0055]
[0056] We can get:
[0057]
[0058] in, Represents optical flow. Optical flow can be solved by the least squares method.
[0059] Step 4: Search the corresponding pixel points on the image frame along the direction of the optical flow for the contour points as corresponding points; solve the linear velocity and angular velocity between the image frames based on the geometric relationship between the contour points and the corresponding points.
[0060] Assume the three-dimensional velocity of the space target is , the linear speed is and the angular velocity is , according to the object speed formula:
[0061] (2)
[0062] Formula (1) is derived with respect to time:
[0063] (3)
[0064] Combining formula (2) and (3) we can deduce:
[0065] (4)
[0066] in, express The optical flow is used to establish the association between contour points and corresponding points along the direction of the optical flow, and the linear velocity between frames is obtained. and angular velocity .
[0067] Step 5: Define the error function according to the linear velocity and angular velocity between image frames and the distance between the contour point and the corresponding point, and solve the error function to obtain the current position and posture of the space target.
[0068] According to the linear velocity and angular velocity , converted into the pose change between frames: relative rotation matrix and the relative translation vector , then at the next moment The initial value of the pose (rotation matrix and translation vectors ) can be set to:
[0069] (5)
[0070] Suppose a three-dimensional point of the space target is , the corresponding pixel is , represents the distance. Then the error function is defined as:
[0071] (6)
[0072] By solving formula (6), we can get The position and posture of the space target, that is, the rotation matrix and translation vectors .
[0073] Step 6: Repeat steps 3 to 5 to process the image frame at the next moment and solve the position and posture of the space target at the next moment.
[0074] In a space environment with complex lighting, the present application is not affected by the complexity of the space environment and extreme lighting conditions such as strong light and weak light, and can stably and continuously track fast-moving space targets.
[0075] In the above-mentioned contour-based spatial target posture tracking method, the monocular camera is first calibrated to obtain the camera's internal parameters; the monocular camera is used to collect sequential images of the motion of the spatial target; the three-dimensional model of the spatial target is projected onto the image according to a pre-set projection relationship; the outer contour points of the projection model are found, the outer contour of the two-dimensional point cloud is extracted, the optical flow of the contour points in the outer contour is solved, and the contour points are searched along the optical flow direction for the corresponding pixel points on the image frame as corresponding points; the linear velocity and angular velocity between image frames are solved according to the geometric relationship between the contour points and the corresponding points; the distance between the contour points and the corresponding points is calculated as an error term, and the error function is constructed according to the linear velocity and angular velocity between image frames and the distance between the contour points and the corresponding points to solve the posture of the spatial target. In a space environment with complex lighting, the present application can stably track fast-moving spatial targets.
[0076] In one embodiment, converting a three-dimensional point cloud of a space target into a two-dimensional point cloud of an image includes:
[0077] Assume that the posture and 3D point cloud of the space target are known, at the initial moment The position of is known, using the rotation matrix and translation vectors According to the perspective projection relationship, the three-dimensional model of the target is converted into a two-dimensional point cloud. and the corresponding two-dimensional point , the relationship is as follows:
[0078]
[0079] in, It is a three-dimensional point Depth.
[0080] In one embodiment, solving the linear velocity and angular velocity between image frames according to the geometric relationship between the contour points and the corresponding points includes:
[0081] Assume the three-dimensional velocity of the space target is , then the solutions for linear velocity and angular velocity are and , the object speed formula is
[0082]
[0083] According to the three-dimensional point of the space target and the corresponding two-dimensional point The relationship is derived with respect to time, and the derivative formula is
[0084]
[0085] Using the object velocity formula and the derivative formula, the relationship between the contour point and the corresponding point is established:
[0086]
[0087] in, Represents optical flow, establishes the association between contour points and corresponding points along the direction of optical flow, and solves the linear velocity between image frames and angular velocity .
[0088] In one embodiment, an error function is defined according to the linear velocity and angular velocity between image frames and the distance between the contour point and the corresponding point, and the error function is solved to obtain the position and posture of the space target at the current moment, including:
[0089] Convert the linear velocity and angular velocity between image frames into the posture change between image frames to obtain the relative rotation matrix and the relative translation vector; set the initial posture at the next moment according to the relative rotation matrix and the relative translation vector;
[0090] The error function is defined according to the initial posture at the next moment and the distance between the contour point and the corresponding point, and the posture of the space target at the current moment is obtained by solving the error function.
[0091] In one embodiment, setting the initial posture at the next moment according to the relative rotation matrix and the relative translation vector includes:
[0092] According to the relative rotation matrix and relative translation vector, the initial pose at the next moment is set as
[0093]
[0094] in, is the relative rotation matrix, is the relative translation vector, For the initial moment The rotation matrix of For the initial moment The translation vector of represents the initial rotation matrix at the next moment, Represents the initial translation vector at the next moment.
[0095] In one embodiment, an error function is defined according to an initial pose at a next moment and a distance between a contour point and a corresponding point, including:
[0096] The error function is defined according to the initial pose at the next moment and the distance between the contour point and the corresponding point:
[0097]
[0098] in, Indicates i The contour points, Indicates i The corresponding points of the contour points, Indicates distance, represents the optimized rotation matrix, Represents the optimized translation vector.
[0099] It should be understood that although Figure 1 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 1 At least part of the steps may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least part of the sub-steps or stages of other steps.
[0100] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0101] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A contour-based spatial target posture tracking method, It is characterized in that The method comprises: Step 1: calibrate the monocular camera, calibrate the intrinsic parameters of the camera, the intrinsic parameters include focal length, principal point and distortion coefficient, and use the calibrated monocular camera to observe the moving space target; Step 2: photographing the moving space target using a monocular camera to obtain a sequence of images of the space target in continuous motion; the sequence of images includes a plurality of image frames; Step 3: For the image frame at the current moment, given the initial posture of the space target, the 3D point cloud of the space target is converted into a 2D point cloud of the image; the outer contour of the 2D point cloud is extracted, and the optical flow of the contour points in the outer contour is solved, including: The contour points exist The gray value at the moment is recorded as ,exist The gray value at the moment is recorded as , assuming that the grayscale value of pixels between adjacent frames remains unchanged, we get Will Perform Taylor expansion: We can get: in, represents optical flow; Step 4: Search the corresponding pixel points on the image frame along the optical flow direction of the contour points as corresponding points; solve the linear velocity and angular velocity between the image frames according to the geometric relationship between the contour points and the corresponding points; Step 5: Define an error function based on the linear velocity and angular velocity between image frames and the distance between the contour point and the corresponding point, and solve the error function to obtain the current position and posture of the space target, including: Convert the linear velocity and angular velocity between image frames into the posture change between image frames to obtain a relative rotation matrix and a relative translation vector; set the initial posture at the next moment according to the relative rotation matrix and the relative translation vector; An error function is defined according to the initial posture at the next moment and the distance between the contour point and the corresponding point, and the posture of the space target at the current moment is obtained by solving the error function; Step 6: Repeat steps 3 to 5 to process the image frame at the next moment and solve the position and posture of the space target at the next moment.
2. The method according to claim 1, It is characterized in that Convert the 3D point cloud of the space target into a 2D point cloud of the image, including: Assume that the posture and 3D point cloud of the space target are known, at the initial moment The position of is known, using the rotation matrix and translation vectors Indicates that, according to the perspective projection relationship, the three-dimensional model of the target is converted into a two-dimensional point cloud. and the corresponding two-dimensional point , the relationship is as follows: in, It is a three-dimensional point Depth.
3. The method according to claim 2, It is characterized in that The linear velocity and angular velocity between image frames are solved based on the geometric relationship between contour points and corresponding points, including: Assume the three-dimensional velocity of the space target is , then the solutions for linear velocity and angular velocity are and , the object speed formula is According to the three-dimensional point of the space target and the corresponding two-dimensional point The relationship is derived with respect to time, and the derivative formula is Using the object velocity formula and the derivation formula, the relationship between the contour point and the corresponding point is established as follows: in, Represents optical flow, establishes the association between contour points and corresponding points along the direction of optical flow, and solves the linear velocity between image frames and angular velocity .
4. The method according to claim 1, It is characterized in that The initial posture at the next moment is set according to the relative rotation matrix and the relative translation vector, including: According to the relative rotation matrix and relative translation vector, the initial posture at the next moment is set as in, is the relative rotation matrix, is the relative translation vector, For the initial moment The rotation matrix of For the initial moment The translation vector of represents the initial rotation matrix at the next moment, Represents the initial translation vector at the next moment.
5. The method according to claim 4, It is characterized in that The error function is defined according to the initial pose at the next moment and the distance between the contour point and the corresponding point, including: The error function is defined according to the initial pose at the next moment and the distance between the contour point and the corresponding point: in, Indicates i The contour points, Indicates i The corresponding points of the contour points, Indicates distance, represents the optimized rotation matrix, Represents the optimized translation vector.
Citation Information
Patent Citations
Aircraft horizontal attitude determination method based on skyline imaging
CN103697883A
Information processing device, information processing method, and program
JP2021113760A
