Dual-ring micro-motion monitoring method and system based on monocular camera
By combining a monocular camera with a pinhole imaging model and sub-pixel edge detection, the problems of small measurement range and easy introduction of interference in traditional measurement methods in precision instruments are solved, high-precision micro-motion monitoring and analysis are achieved, and operational efficiency and accuracy are improved.
Patent Information
- Application Number
- CN202411054425.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2024-06-18
- Filing Date
- 2024-08-02
- Publication Date
- 2025-09-05
- Estimated Expiration
- 2044-08-02
AI Technical Summary
Traditional contact measurement methods have limitations in precision instruments, such as small measurement range and easy introduction of additional interference, making it difficult to achieve high-precision measurement of small displacements.
A dual-ring micro-motion monitoring method based on a monocular camera is adopted. The projection point relationship of the dual-ring center points on the image plane and the normalized plane is established through the pinhole imaging model. The center points are extracted by combining sub-pixel edge detection. The pixel offset is calculated and converted into the real offset to determine the dual-ring motion.
It achieves high-precision micro-motion monitoring, improves operational efficiency and accuracy, simplifies operating procedures, reduces dependence on expensive equipment, and supports instant control and motion adjustment.
Smart Images

Figure CN119672095B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of machine vision technology, and in particular to a dual-circle micro-motion monitoring method and system based on a monocular camera. Background Art
[0002] In precision instruments such as microscopes, optical platforms, coordinate measuring machines and other equipment, high-precision measurement of tiny displacements of objects is often required to achieve precise positioning, alignment, tracking and other functions.
[0003] Traditional contact measurement methods, such as electrical or mechanical sensors, have limitations such as small measurement range and easy introduction of additional interference. Therefore, a solution is needed to address the shortcomings of existing technologies.
[0004] The double-ring marker consists of two concentric rings, one inside and one outside. The center of each ring reflects the spatial position of the marker. By tracking the displacement of the ring center on the image, the three-dimensional motion of the marker can be estimated. Compared with other marker shapes, rings have advantages such as good symmetry, strong rotational invariance, and prominent image features. Summary of the Invention
[0005] The embodiments of the present invention provide a dual-circle micro-motion monitoring method and system based on a monocular camera, which can at least solve some of the problems in the prior art.
[0006] A first aspect of an embodiment of the present invention provides a method for monitoring micro-motion of a double-circle ring based on a monocular camera, comprising:
[0007] Acquire an image of the dual-ring locator through a monocular camera, establish the dual-ring center point in combination with a pinhole imaging model, determine the relationship between the projection points of the dual-ring center point on the image plane and the normalized plane, convert the plane coordinates corresponding to the dual-ring center point into pixel coordinates and determine the conversion relationship;
[0008] Based on the conversion relationship, the pixel offset of the center point of the double ring is determined in pixel coordinates, based on the pixel offset, the real offset in real coordinates is solved, and based on the real offset, the double ring action is determined.
[0009] In an optional embodiment,
[0010] The method of establishing the center point of the double rings in combination with the pinhole imaging model, determining the relationship between the projection points of the center point of the double rings on the image plane and the normalized plane, converting the plane coordinates corresponding to the center point of the double rings into pixel coordinates and determining the conversion relationship includes:
[0011] In combination with the pinhole imaging model, the projection point of the center point of the double ring on the normalized plane is established, and the projection calculation expression is determined based on the coordinates corresponding to the projection point;
[0012] Determine the relationship between the normalized plane coordinates and the image plane physical coordinates based on the camera focal length, and determine a first conversion relationship between the image plane physical coordinates and the pixel coordinates in combination with the physical pixel size;
[0013] Based on the projection calculation expression and the first conversion relationship, the normalized plane coordinates are eliminated through mathematical calculation and the conversion relationship between the center point of the double ring and the pixel coordinates is determined.
[0014] In an optional embodiment,
[0015] The conversion relationship between the center point of the double ring and the pixel coordinates is shown in the following formula:
[0016]
[0017] Among them, u represents the horizontal coordinate of the center point of the double ring in the pixel coordinate system, f x represents the focal length of the camera in the x direction, x represents the horizontal coordinate of the center point of the double ring in the three-dimensional space, z represents the vertical coordinate of the center point of the double ring in the three-dimensional space, d x Indicates the physical length of the pixel in the x direction, c x represents the horizontal coordinate of the origin of the pixel coordinate system in the image plane coordinate system, v represents the vertical coordinate of the center point of the double ring in the pixel coordinate system, and f y Indicates the focal length of the camera in the y direction, y represents the vertical coordinate of the center point of the double ring in three-dimensional space, d y Indicates the physical length of the pixel in the y direction, c y Represents the vertical coordinate of the origin of the pixel coordinate system in the image plane coordinate system.
[0018] In an optional embodiment,
[0019] Determining a pixel offset of the center point of the double ring in pixel coordinates based on the conversion relationship, solving a real offset in real coordinates based on the pixel offset, and determining a double ring action based on the real offset includes:
[0020] When the double rings move slightly, the coordinates of the center points of the double rings are determined in the image taken by the monocular camera, and the pixel offset of the center points of the double rings is determined based on the coordinates;
[0021] Adding the pixel offset to a pre-constructed functional relationship, and solving the real offset of the center point of the double ring in the real coordinate system through the simultaneous relationship;
[0022] Based on the actual offset, the offset position of the center point of the double ring is verified to obtain the corresponding double ring action.
[0023] In an optional embodiment,
[0024] The relationship between the image plane and the normalized plane is shown in the following formula:
[0025]
[0026] Among them, Z represents the distance from the midpoint of the three-dimensional world to the optical center of the camera, f represents the focal length of the camera, X represents the horizontal coordinate of the midpoint of the three-dimensional world in the camera coordinate system, Y represents the vertical coordinate of the midpoint of the three-dimensional world in the camera coordinate system, X ’ Indicates the horizontal coordinate of the point in the three-dimensional world on the image plane, Y ’ Represents the vertical coordinate of the point in the three-dimensional world on the image plane.
[0027] In an optional embodiment,
[0028] The method further includes extracting the center point of the double ring based on sub-pixel edge detection:
[0029] For the original image captured by the monocular camera, smoothing is performed and an edge detection operator is applied to obtain initial edge pixels. For each initial edge pixel, a pixel intensity gradient corresponding to the pixel intensity is obtained by taking an arbitrary line segment along the edge normal direction in the original image and calculating the pixel intensity value of each point on the line segment.
[0030] Based on the pixel intensity gradient, a one-dimensional Gaussian function is combined to perform parameter fitting, determine the peak value corresponding to the Gaussian function, calculate the fitting residual and the coefficient of determination, and evaluate the Gaussian fitting quality. If the Gaussian fitting quality is greater than a preset fitting quality threshold, the fit is considered accepted, and the peak position of the Gaussian model is extracted as the final edge position corresponding to the image;
[0031] For each initial edge pixel of the original image, fitting is repeated until all pixels are processed to obtain the image edge contour. Based on the image edge contour, the center point corresponding to the double ring is calculated by the least squares method.
[0032] In an optional embodiment,
[0033] The one-dimensional Gaussian model expression is shown in the following formula:
[0034]
[0035] Where G(n) represents the Gaussian function value at n, A represents the amplitude factor, exp represents the natural exponential function, μ represents the mean, σ represents the standard deviation, and B represents the background value.
[0036] A second aspect of an embodiment of the present invention provides a dual-circle micro-motion monitoring system based on a monocular camera, comprising:
[0037] The first unit is used to obtain an image of the dual-ring locator through a monocular camera, establish the center point of the dual-ring in combination with the pinhole imaging model, determine the relationship between the projection points of the dual-ring center point on the image plane and the normalized plane, convert the plane coordinates corresponding to the dual-ring center point into pixel coordinates and determine the conversion relationship;
[0038] The third unit is used to determine the pixel offset of the center point of the double ring in pixel coordinates based on the conversion relationship, solve the real offset in real coordinates based on the pixel offset, and determine the double ring action based on the real offset.
[0039] According to a third aspect of the embodiments of the present invention,
[0040] An electronic device is provided, comprising:
[0041] processor;
[0042] a memory for storing processor-executable instructions;
[0043] The processor is configured to call the instructions stored in the memory to execute the aforementioned method.
[0044] According to a fourth aspect of the embodiments of the present invention,
[0045] A computer-readable storage medium is provided, on which computer program instructions are stored. When the computer program instructions are executed by a processor, the method described above is implemented.
[0046] In the present invention, the monocular camera is precisely fixed to the end of the robotic arm through a specially designed fixing frame, flange and L-shaped slide rail, thereby ensuring the stability and repeatability of the imaging system, thereby providing a guarantee for the acquisition of high-quality images, and accurately establishing the mapping relationship between the center point of the double ring in three-dimensional space and the two-dimensional image plane, and further converting the three-dimensional space coordinates into pixel coordinates of the two-dimensional image, thereby ensuring the accuracy and efficiency of image analysis, and measuring the offset of the center point of the double ring in the pixel coordinate system, and calculating the real offset in the real-world coordinate system based on this pixel offset, thereby greatly improving the accuracy and reliability of motion analysis. In summary, the present invention realizes precise monitoring and analysis of double-ring motions through precise hardware configuration and efficient image processing algorithm, thereby improving the efficiency and accuracy of operation. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] Figure 1 Schematic diagram of the process of a dual-circle micro-motion monitoring method based on a monocular camera according to an embodiment of the present invention;
[0048] Figure 2The figure is a schematic structural diagram of a dual-ring micro-motion monitoring system based on a monocular camera according to an embodiment of the present invention.
[0049] Figure 3 Schematic diagram of the three-dimensional structure of a dual-ring micro-motion monitoring device based on a monocular camera according to an embodiment of the present invention. DETAILED DESCRIPTION
[0050] To make the objectives, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying 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 making creative efforts shall fall within the scope of protection of the present invention.
[0051] The following specific embodiments are used to describe the technical solution of the present invention in detail. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments.
[0052] Figure 1 FIG is a flow chart of a method for monitoring micro-motion of a double-ring based on a monocular camera according to an embodiment of the present invention. Figure 1 As shown, the method includes:
[0053] S1. Acquire an image of the dual-ring locator using a monocular camera, establish the dual-ring center point based on the pinhole imaging model, determine the relationship between the projection points of the dual-ring center point on the image plane and the normalized plane, convert the plane coordinates corresponding to the dual-ring center point into pixel coordinates and determine the conversion relationship;
[0054] The double-ring center point refers to the center of the structure formed by two concentric circles. In the image or physical space, this point represents the center position shared by the two rings. In image processing and machine vision applications, identifying and accurately locating the double-ring center point is an important task, especially when performing object positioning, navigation or image-based measurement. The image plane is a virtual plane used to represent the image formation position in the optical imaging system. The normalized plane refers to the conversion of the coordinates on the image plane into a dimensionless coordinate system through the camera intrinsic parameters. The pixel coordinates refer to the position of each pixel point in the image matrix in the digital image.
[0055] In an optional embodiment,
[0056] The pinhole imaging model, establishing the double-circle center point, determining the relationship between the projection points of the double-circle center point on the image plane and the normalized plane, converting the plane coordinates corresponding to the double-circle center point into pixel coordinates and determining the conversion relationship includes:
[0057] In combination with the pinhole imaging model, the projection point of the center point of the double ring on the normalized plane is established, and the projection calculation expression is determined based on the coordinates corresponding to the projection point;
[0058] Determine the relationship between the normalized plane coordinates and the image plane physical coordinates based on the camera focal length, and determine a first conversion relationship between the image plane physical coordinates and the pixel coordinates in combination with the physical pixel size;
[0059] Based on the projection calculation expression and the first conversion relationship, the normalized plane coordinates are eliminated through mathematical calculation and the conversion relationship between the center point of the double ring and the pixel coordinates is determined.
[0060] The physical pixel size refers to the physical size of a single pixel on a camera sensor, describing the actual physical width and height of the pixel on the sensor, usually expressed in microns.
[0061] Use a monocular camera to capture an image containing a double-ring target, use an image processing algorithm (such as an edge detection algorithm) to identify the edges of the double-ring in the image, calculate the rough pixel coordinates of the center points of the double-ring, calculate the projection of the center points of the double-ring on a normalized plane through a pinhole imaging model, and convert the three-dimensional world coordinates of the center points of the double-ring into two-dimensional coordinates on the normalized plane, wherein the optical center of the camera is considered as the origin, and the distance is normalized according to the focal length of the camera. Based on the focal length of the camera, the coordinates on the normalized plane are converted into a physical coordinate system of the image plane by multiplying the normalized coordinates by the focal length and taking into account the specific position and orientation of the image sensor;
[0062] Using the physical pixel size of the camera sensor (i.e., the actual physical width and height of each pixel), the image plane physical coordinates are converted to pixel coordinates. Specifically, the physical coordinates are divided by the physical size of each pixel and added to the pixel coordinates of the image center to obtain the final pixel coordinates.
[0063] By integrating the above steps into a mathematical formula, the corresponding pixel coordinates are directly calculated from the three-dimensional coordinates of the center point of the double ring, thereby avoiding the explicit use of normalized plane coordinates in the calculation process, and obtaining the above conversion relationship.
[0064] In this embodiment, through mathematical modeling and calculation, an accurate mapping between the position of an object in three-dimensional space and the pixel coordinates on a two-dimensional image is achieved, thereby improving the accuracy of positioning. By eliminating the intermediate normalized plane coordinates, the mapping process from three-dimensional space to two-dimensional image is simplified, and the computational efficiency is improved. By establishing the relationship between physical pixel size and pixel coordinates, the technology can be directly applied to real-world imaging equipment and analysis software, thereby enhancing the feasibility and convenience of practical applications. In summary, this embodiment, by combining a dual-ring locator and a pinhole imaging model, accurately converts the position of an object in three-dimensional space into pixel coordinates on a two-dimensional image, providing powerful technical support for fields such as precise imaging, target tracking, and spatial positioning.
[0065] In an optional embodiment,
[0066] The conversion relationship between the center point of the double ring and the pixel coordinates is shown in the following formula:
[0067]
[0068] Among them, u represents the horizontal coordinate of the center point of the double ring in the pixel coordinate system, f x represents the focal length of the camera in the x direction, x represents the horizontal coordinate of the center point of the double ring in the three-dimensional space, z represents the vertical coordinate of the center point of the double ring in the three-dimensional space, d x Indicates the physical length of the pixel in the x direction, c x represents the horizontal coordinate of the origin of the pixel coordinate system in the image plane coordinate system, v represents the vertical coordinate of the center point of the double ring in the pixel coordinate system, and f y Indicates the focal length of the camera in the y direction, y represents the vertical coordinate of the center point of the double ring in three-dimensional space, d y Indicates the physical length of the pixel in the y direction, c y Represents the vertical coordinate of the origin of the pixel coordinate system in the image plane coordinate system.
[0069] In this embodiment, the three-dimensional coordinates of the physical world and the two-dimensional pixel coordinates of the digital image are directly linked, providing a reliable mathematical model for converting actual physical scenes into computable and analyzable digital images. By adjusting the focal length, pixel physical size, and camera center offset, the calculation formula can be applied to different cameras and imaging systems, demonstrating a high degree of flexibility and wide applicability. In summary, this embodiment makes the conversion from the three-dimensional world to the two-dimensional image both accurate and efficient, thereby supporting a wide range of technological applications and developments.
[0070] S2. Based on the conversion relationship, determine the pixel offset of the center point of the double ring in pixel coordinates, solve the real offset in real coordinates based on the pixel offset, and determine the double ring action based on the real offset.
[0071] The pixel offset generally refers to the offset measured in the image pixel coordinate system. When an object or feature point moves in an image, the difference between its new position on the image and its original position (in the horizontal and vertical directions) is the pixel offset. The real offset refers to the offset measured in the physical world coordinate system, which reflects the actual movement distance of the object in three-dimensional space.
[0072] In an optional embodiment,
[0073] Determining a pixel offset of the center point of the double ring in pixel coordinates based on the conversion relationship, solving a real offset in real coordinates based on the pixel offset, and determining a double ring action based on the real offset includes:
[0074] When the double rings move slightly, the coordinates of the center points of the double rings are determined in the image taken by the monocular camera, and the pixel offset of the center points of the double rings is determined based on the coordinates;
[0075] Adding the pixel offset to a pre-constructed functional relationship, and solving the real offset of the center point of the double ring in the real coordinate system through the simultaneous relationship;
[0076] Based on the actual offset, the offset position of the center point of the double ring is verified to obtain the corresponding double ring action.
[0077] The captured image is preprocessed, including noise removal and contrast adjustment, to enhance image quality. Image processing techniques are used to identify the double ring in the image and calculate the coordinates of the double ring's center point on the image. The pixel coordinates of the double ring's center point are extracted from the recognition results. Before the double ring moves, the reference pixel coordinates of its center point are determined and recorded. The pixel offset is calculated by comparing the current pixel coordinates of the double ring's center point with the reference coordinates.
[0078] Based on the camera model (such as the pinhole camera model) and imaging parameters (focal length, distance between the camera and the target, etc.), a functional relationship is pre-constructed to convert the pixel offset into the real-world offset. The calculated pixel offset is substituted into the functional relationship and solved by mathematical methods to obtain the real offset of the center point of the double ring in the real coordinate system. According to the size and direction of the real offset, the specific movement of the double ring is analyzed. Based on the analysis of the offset position, the specific action of the double ring is obtained.
[0079] In this embodiment, the pixel coordinates of the center points of the double circular rings are accurately identified through image processing technology. Combined with the camera model and imaging parameters, high-precision spatial positioning and measurement of small offsets can be achieved. The image data is processed by software algorithms to infer the object's movement, avoiding the need for complex physical measurements and expensive equipment, simplifying the operation process, and improving efficiency. By processing image data in real time, real-time motion feedback of the object can be quickly obtained, supporting immediate control decisions and motion adjustments, and enhancing the interactivity and responsiveness of the system. In summary, this embodiment provides an effective, low-cost, and highly flexible solution for achieving high-precision motion monitoring and analysis by accurately extracting and analyzing the object's micro-motion information from image data.
[0080] In an optional embodiment,
[0081] The relationship between the image plane and the normalized plane is shown in the following formula:
[0082]
[0083] Among them, Z represents the distance from the midpoint of the three-dimensional world to the optical center of the camera, f represents the focal length of the camera, X represents the horizontal coordinate of the midpoint of the three-dimensional world in the camera coordinate system, Y represents the vertical coordinate of the midpoint of the three-dimensional world in the camera coordinate system, X ’ Indicates the horizontal coordinate of the point in the three-dimensional world on the image plane, Y ’ Represents the vertical coordinate of the point in the three-dimensional world on the image plane.
[0084] In this embodiment, points in three-dimensional space are converted to the image plane through geometric projection, providing a concise and clear mathematical description of the imaging process, laying the foundation for understanding and implementing image acquisition. The relationship between points in three-dimensional space and their projection points on the image plane is defined through clear mathematical relationships, so that the position in three-dimensional space corresponding to each pixel point on the image can be accurately calculated, which helps to achieve accurate spatial positioning and measurement. In summary, this embodiment provides strong support for image analysis, three-dimensional model reconstruction, robot vision system design, etc. in practical applications.
[0085] In an optional embodiment,
[0086] The method further includes extracting the center point of the double ring based on sub-pixel edge detection:
[0087] For the original image captured by the monocular camera, smoothing is performed and an edge detection operator is applied to obtain initial edge pixels. For each initial edge pixel, a pixel intensity gradient corresponding to the pixel intensity is obtained by taking an arbitrary line segment along the edge normal direction in the original image and calculating the pixel intensity value of each point on the line segment.
[0088] Based on the pixel intensity gradient, a one-dimensional Gaussian function is combined to perform parameter fitting, determine the peak value corresponding to the Gaussian function, calculate the fitting residual and the coefficient of determination, and evaluate the Gaussian fitting quality. If the Gaussian fitting quality is greater than a preset fitting quality threshold, the fit is considered accepted, and the peak position of the Gaussian model is extracted as the final edge position corresponding to the image;
[0089] For each initial edge pixel of the original image, fitting is repeated until all pixels are processed to obtain the image edge contour. Based on the image edge contour, the center point corresponding to the double ring is calculated by the least squares method.
[0090] Apply a smoothing filter (such as a Gaussian filter) to the original image to reduce noise. Use an edge detection operator (such as Sobel, Canny, etc.) to process the smoothed image to identify the initial edge pixels in the image. For each initial edge pixel, take a line segment in the original image along its edge normal direction, calculate the pixel intensity value of each point on the taken line segment, and then obtain the pixel intensity gradient;
[0091] Based on the obtained pixel intensity gradient, a one-dimensional Gaussian function is applied for parameter fitting to determine the accuracy of the edge position. The fitting residual and determination coefficient are calculated to evaluate the Gaussian fitting quality. If the fitting quality exceeds the preset threshold, the fitting result is accepted and the peak position of the Gaussian model is extracted as the corresponding final edge position in the image.
[0092] The above fitting process is repeated for each initial edge pixel of the original image until all pixels are processed to obtain the edge contour of the image. Based on the extracted image edge contour, the center point position of the double ring is calculated by the least squares method.
[0093] The fitting residual refers to the difference between the actual observed value and the model predicted value. In image processing, this may refer to the difference between the actual intensity value of a pixel and the intensity value predicted by the model (such as a one-dimensional Gaussian function). The coefficient of determination is a statistic that measures the proportion of the variability of the model's explanatory variables, and its value ranges from 0 to 1. The one-dimensional Gaussian function is a common function used for edge detection and image smoothing. The fitting quality threshold is a pre-set standard used to evaluate the quality of model fitting.
[0094] In this embodiment, by calculating the pixel intensity gradient and using a one-dimensional Gaussian function for precise fitting, the edges in the image can be more accurately identified and located, the details at the edge of the image can be better processed, and the accuracy of edge positioning can be improved. By calculating the fitting residual and the determination coefficient and evaluating the quality of the Gaussian fitting according to a preset fitting quality threshold, the accuracy and reliability of the final edge position are ensured, thereby providing a solid foundation for subsequent image processing and analysis. By applying the least squares method to calculate the center point corresponding to the double ring, the accuracy of the center point positioning is improved. In summary, this embodiment not only improves the accuracy of image edge detection and center point positioning, but also ensures the reliability of the results through strict fitting quality evaluation.
[0095] In an optional embodiment,
[0096] The one-dimensional Gaussian model expression is shown in the following formula:
[0097]
[0098] Where G(n) represents the Gaussian function value at n, A represents the amplitude factor, exp represents the natural exponential function, μ represents the mean, σ represents the standard deviation, and B represents the background value.
[0099] In this function, by adjusting the amplitude factor and standard deviation, the pixel intensity changes at the edges of the image can be accurately simulated, so that the model can adapt to images with different edge features. By adding background values, it helps to more accurately fit and identify image edges in the presence of background noise. By fitting the image data to a one-dimensional Gaussian model, meaningful physical quantities can be extracted from the image, thereby supporting more complex data analysis and image reconstruction tasks. In summary, this embodiment, through its parameterized characteristics, allows for accurate modeling and identification of edge features under various image conditions, providing a flexible and powerful analysis tool.
[0100] Figure 2 FIG. 1 is a structural diagram of a dual-ring micro-motion monitoring system based on a monocular camera according to an embodiment of the present invention. Figure 2 As shown, the system includes:
[0101] The first unit is used to obtain an image of the dual-ring locator through a monocular camera, establish the center point of the dual-ring in combination with the pinhole imaging model, determine the relationship between the projection points of the dual-ring center point on the image plane and the normalized plane, convert the plane coordinates corresponding to the dual-ring center point into pixel coordinates and determine the conversion relationship;
[0102] The second unit is used to determine the pixel offset of the center point of the double ring in pixel coordinates based on the conversion relationship, solve the real offset in real coordinates based on the pixel offset, and determine the double ring action based on the real offset.
[0103] Figure 3 Schematic diagram of the three-dimensional structure of a double-ring micro-motion monitoring device based on a monocular camera according to an embodiment of the present invention, the device comprises: (1) a monocular camera, (2) a fixing frame, (3) a flange, (4) an L-shaped slide rail, and (5) a double-ring locator, wherein the monocular camera fixing frame is composed of a fixing frame, a flange and an L-shaped slide rail, the fixing frame is connected to the monocular camera by screws, the flange is connected to the fixing frame by screws and fixed to the end of the robot arm, and the double-ring locator is connected to the L-shaped slide rail by a bayonet;
[0104] The monocular camera refers to a system that uses a single lens or camera to capture images. It is the most basic image acquisition device, similar to the human eye, which obtains a two-dimensional image of the scene through an optical lens. The flange is a mechanical component used to connect pipes, pipes or equipment, usually in the shape of a disc, providing a convenient connection and disassembly method. The double-ring locator is a device or system specifically used to accurately locate and fix double-ring shaped objects, used to ensure the accurate position of objects during processing, inspection or assembly.
[0105] The present invention may be a method, an apparatus, a system and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for executing various aspects of the present invention.
[0106] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the above embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A double-ring micro-motion detection method based on a monocular camera, characterized in that: include: The method includes: acquiring an image of the dual-ring locator through a monocular camera, establishing the center point of the dual-ring in combination with a pinhole imaging model, determining the relationship between the projection points of the dual-ring center point on the image plane and the normalized plane, converting the plane coordinates corresponding to the dual-ring center point into pixel coordinates, and determining the conversion relationship, including: In combination with the pinhole imaging model, the projection point of the center point of the double ring on the normalized plane is established, and the projection calculation expression is determined based on the coordinates corresponding to the projection point; Determine the relationship between the normalized plane coordinates and the image plane physical coordinates based on the camera focal length, and determine a first conversion relationship between the image plane physical coordinates and the pixel coordinates in combination with the physical pixel size; Based on the projection calculation expression and the first conversion relationship, eliminating the normalized plane coordinates and determining the conversion relationship between the center point of the double ring and the pixel coordinates through mathematical calculation; Based on the conversion relationship, the pixel offset of the center point of the double ring is determined in pixel coordinates, based on the pixel offset, the real offset in real coordinates is solved, and based on the real offset, the double ring action is determined.
2. The method according to claim 1, characterized in that The conversion relationship between the center point of the double ring and the pixel coordinates is shown in the following formula: ; in, u Indicates the horizontal coordinate of the center point of the double ring in the pixel coordinate system, f x Indicates that the camera is x focal length in the direction, x represents the horizontal coordinate of the center point of the double ring in three-dimensional space, z Represents the vertical coordinate of the center point of the double ring in three-dimensional space, d x Indicates that the pixel is x The physical length in the direction, c x Represents the horizontal coordinate of the origin of the pixel coordinate system in the image plane coordinate system, v Indicates the vertical coordinate of the center point of the double ring in the pixel coordinate system, f y represents the focal length of the camera in the y direction, y represents the vertical coordinate of the center point of the double ring in three-dimensional space, d y Indicates the physical length of the pixel in the y direction, c y Represents the vertical coordinate of the origin of the pixel coordinate system in the image plane coordinate system.
3. The method according to claim 1, characterized in that Determining a pixel offset of the center point of the double ring in pixel coordinates based on the conversion relationship, solving a real offset in real coordinates based on the pixel offset, and determining a double ring action based on the real offset includes: When the double rings move slightly, the coordinates of the center points of the double rings are determined in the image taken by the monocular camera, and the pixel offset of the center points of the double rings is determined based on the coordinates; Adding the pixel offset to a pre-constructed functional relationship, and solving the real offset of the center point of the double ring in the real coordinate system through the simultaneous relationship; Based on the actual offset, the offset position of the center point of the double ring is verified to obtain the corresponding double ring action.
4. The method according to claim 1, wherein The relationship between the image plane and the normalized plane is shown in the following formula: ; in, Z Indicates the distance from the point in the three-dimensional world to the optical center of the camera, f represents the focal length of the camera, X Indicates the horizontal coordinate of the midpoint of the three-dimensional world in the camera coordinate system, Y Indicates the vertical coordinate of the midpoint of the three-dimensional world in the camera coordinate system, X ’ represents the horizontal coordinate of the point in the three-dimensional world on the image plane, Y ’ Represents the vertical coordinate of the point in the three-dimensional world on the image plane.
5. The method according to claim 1, wherein The method further includes extracting the center point of the double ring based on sub-pixel edge detection: For the original image captured by the monocular camera, smoothing is performed and an edge detection operator is applied to obtain initial edge pixels. For each initial edge pixel, a pixel intensity gradient corresponding to the pixel intensity is obtained by taking an arbitrary line segment along the edge normal direction in the original image and calculating the pixel intensity value of each point on the line segment. Based on the pixel intensity gradient, a one-dimensional Gaussian function is combined to perform parameter fitting, determine the peak value corresponding to the Gaussian function, calculate the fitting residual and the coefficient of determination, and evaluate the Gaussian fitting quality. If the Gaussian fitting quality is greater than a preset fitting quality threshold, the fit is considered accepted, and the peak position of the Gaussian model is extracted as the final edge position corresponding to the image; For each initial edge pixel of the original image, fitting is repeated until all pixels are processed to obtain the image edge contour. Based on the image edge contour, the center point corresponding to the double ring is calculated by the least squares method.
6. The method according to claim 1, characterized in that The one-dimensional Gaussian model expression is shown in the following formula: ; in, G(n) Indicates n The Gaussian function value at A represents the amplitude factor, exp represents the natural exponential function, μ represents the mean, σ represents the standard deviation, B Represents the background value.
7. A dual-circle micro-motion detection system based on a monocular camera, used to implement the method according to any one of claims 1 to 6, characterized in that: include: The first unit is used to obtain an image of the dual-ring locator through a monocular camera, establish the center point of the dual-ring in combination with the pinhole imaging model, determine the relationship between the projection points of the dual-ring center point on the image plane and the normalized plane, convert the plane coordinates corresponding to the dual-ring center point into pixel coordinates and determine the conversion relationship; The second unit is used to determine the pixel offset of the center point of the double ring in pixel coordinates based on the conversion relationship, solve the real offset in real coordinates based on the pixel offset, and determine the double ring action based on the real offset.
8. An electronic device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to call the instructions stored in the memory to execute the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Method and system for double-circle marker location based on monocular vision
CN107330936A
Robotc based on concentric annulus template
CN108908399A