Calibration plate image processing method and device

By adding calibration patterns to the calibration board image and performing distortion correction, the calibration failure problem caused by poor image quality of the calibration board was solved, and the calibration success rate was improved.

CN116597017BActive Publication Date: 2025-12-26SUZHOU MEGAROBO TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310553648.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-17
Publication Date
2025-12-26
Estimated Expiration
2043-05-17

AI Technical Summary

Technical Problem

Existing machine vision platforms are prone to calibration failures due to poor image quality on calibration boards or environmental factors.

Method used

By obtaining the center point position and angular offset of the calibration pattern in the calibration board image, the calibration pattern is supplemented to the calibration board image according to the preset rules, and a vector map of image pixel coordinates and physical space coordinates is generated for distortion correction.

Benefits of technology

It improves the quality of calibration board images and enhances the success rate of camera calibration. Especially when the shooting effect is poor or there are obstructions, tilts, or the camera's field of view cannot be filled, it can reasonably increase the number of calibration patterns and improve the calibration success rate.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116597017B_ABST
    Figure CN116597017B_ABST
Patent Text Reader

Abstract

The application discloses a kind of processing method and device of calibration board image, wherein the method comprises: obtaining the center point position of multiple calibration patterns of calibration board in calibration board image, and the angle offset of the calibration board, wherein the calibration board has calibration pattern distributed according to preset rule;According to the angle offset, the preset rule and the center point position of the multiple calibration patterns, the calibration board image is supplemented calibration pattern.The application can supplement calibration pattern for the image of calibration board, so as to reasonably increase the number of calibration pattern in the case where shooting effect is not good or there is blocking, inclination, camera field of view cannot be filled and other adverse factors, obtain better quality calibration pattern, help to improve the success rate of camera calibration subsequently.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of machine vision, and in particular, to a method and device for processing a calibration board image. BACKGROUND

[0002] In the field of machine vision, camera calibration is usually performed. Camera calibration is actually a process of solving the parameters of a geometric model of camera imaging, which determines the relationship between the three-dimensional geometric position of a point on the surface of a space object and the corresponding point in the image. With the help of the geometric model, the imaging distortion caused by the camera due to distortion and other reasons can be corrected, so camera calibration is a very important link.

[0003] In the calibration process, a calibration board is often used. For example, common calibration boards on the market include checkerboard calibration boards, circular grid calibration boards, etc. By imaging the calibration board to obtain a calibration board image, based on the actual position of the markers on the calibration board and their position in the image, combined with the calibration algorithm, the geometric model of camera imaging can be constructed.

[0004] However, the calibration algorithm used by the mature machine vision platform on the market has high requirements for the imaging effect of the calibration board image. Once the calibration board is blocked, tilted, or cannot completely fill the camera field of view, the calibration will fail.

[0005] At present, there is no effective solution to the above problem. SUMMARY

[0006] In order to solve the above problem, the present application provides a processing scheme for a calibration board image, which can realize the supplement of calibration patterns, improve the quality of the calibration board image, and avoid the problem that the calibration board image cannot complete camera calibration due to poor shooting effect or environmental factors.

[0007] According to one aspect of the present application, a method for processing a calibration board image is provided. The method includes the following steps: obtaining the center point positions of a plurality of calibration patterns of a calibration board in a calibration board image and the angle offset of the calibration board, wherein the calibration board has calibration patterns distributed according to a preset rule; supplementing calibration patterns to the calibration board image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns.

[0008] Wherein, the above-mentioned preset rule distribution refers to that the calibration patterns on the calibration board are linearly arranged along the first direction and the second direction, and are distributed at a preset interval in the first direction and the second direction, wherein the first direction is perpendicular to the second direction.

[0009] And, when supplementing the calibration patterns to the calibration board image, the supplement of the calibration patterns is preferentially performed along the first direction, and then the supplement of the calibration patterns is performed along the second direction.

[0010] The first direction is a row direction, and the second direction is a column direction, or the first direction is a column direction, and the second direction is a row direction.

[0011] In addition, when supplementing the calibration patterns to the calibration board image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns, the method specifically comprises the following steps.

[0012] The calibration board image is traversed for each calibration pattern of the calibration board, and for each calibration pattern, if the number of adjacent calibration patterns of the calibration pattern does not reach a preset number, the supplement is performed according to the direction of the missing calibration pattern and the spacing between the calibration patterns in the direction; wherein after supplementing one calibration pattern each time, it is judged whether the distance of the current supplemented calibration pattern beyond the preset boundary line reaches a preset distance, and in the case that the judgment result is yes, the supplemented calibration pattern is deleted, and it is determined that the calibration pattern has no newly added supplemented calibration pattern, until it is determined that all the calibration patterns have no newly added supplemented calibration pattern.

[0013] In the traversal of each calibration pattern of the calibration board in the calibration board image, each existing calibration pattern of the calibration board in the calibration board image is added to a traversal group, and the traversal is performed based on the calibration patterns in the traversal group.

[0014] And, after each traversal, the calibration pattern supplemented in the current traversal process is added to the traversal group, and the next traversal is performed based on the traversal group of the supplemented calibration pattern, until the number of traversals reaches a preset number or all the calibration patterns have no newly added supplemented calibration pattern.

[0015] In addition, after supplementing the calibration patterns to the calibration board image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns, the above method further comprises the following steps.

[0016] For each row or each column of calibration patterns, the first calibration pattern and the second calibration pattern located at the end of the row or the column of calibration patterns are determined.

[0017] The first distance between the first calibration pattern and the preset boundary line closest to the first calibration pattern is determined, and the second distance between the second calibration pattern and the preset boundary line closest to the second calibration pattern is determined, and in the case that the first distance is greater than the second distance, the calibration pattern is supplemented on the side of the first calibration pattern away from the second calibration pattern.

[0018] In addition, after supplementing the calibration patterns to the calibration board image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns, the above method further comprises the following steps.

[0019] determining pixel coordinates of the center points of the respective calibration patterns in the augmented calibration board image;

[0020] generating a vector map between the image pixel coordinates and the physical space coordinates according to the pixel coordinates of the center points of the respective calibration patterns and the actual physical space coordinates of the center points of the respective calibration patterns on the calibration board;

[0021] performing distortion correction on the calibration board image according to the vector map.

[0022] And, before performing distortion correction on the calibration board image according to the vector map, the method further comprises:

[0023] generating a first real value map corresponding to a row direction and a second real value map corresponding to a column direction according to the vector map;

[0024] cutting the first real value map and the second real value map according to a preset resolution requirement;

[0025] stitching the cut first real value map and the cut second real value map to obtain the vector map, and confirming that the stitched vector map is used for performing distortion correction on the calibration board image.

[0026] According to another aspect of the present application, a processing device for a calibration board image is provided, comprising: an acquisition module configured to acquire the center point positions of a plurality of calibration patterns of a calibration board in a calibration board image and the angle offset of the calibration board, wherein the calibration board has calibration patterns distributed according to a preset rule; and an augmentation module configured to augment the calibration board image with calibration patterns according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns.

[0027] The preset rule distribution refers to that the calibration patterns on the calibration board are linearly arranged in a first direction and a second direction, and are distributed at a preset interval in the first direction and the second direction, wherein the first direction is perpendicular to the second direction.

[0028] And, when augmenting the calibration board image with calibration patterns, the augmentation module will preferentially augment the calibration board image with calibration patterns along the first direction, and then augment the calibration board image with calibration patterns along the second direction.

[0029] The first direction is a row direction and the second direction is a column direction, or the first direction is a column direction and the second direction is a row direction.

[0030] In addition, when augmenting the calibration board image with calibration patterns according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns, the augmentation module is specifically configured to perform the following processing:

[0031] The calibration plate image is traversed for each calibration pattern of the calibration plate, and for each calibration pattern, if it is determined that the number of adjacent calibration patterns of the calibration pattern does not reach a preset number, the calibration pattern is supplemented according to the direction of the missing calibration pattern and the spacing between the calibration patterns in the direction; wherein after each time the calibration pattern is supplemented, it is determined whether the distance of the current supplemented calibration pattern from the preset boundary line reaches a preset distance, and in the case of a positive determination result, the supplemented calibration pattern is deleted, and it is determined that the calibration pattern has no newly added supplemented calibration pattern, until it is determined that all the calibration patterns have no newly added supplemented calibration pattern.

[0032] In the traversal of each calibration pattern of the calibration plate in the calibration plate image, each existing calibration pattern of the calibration plate in the calibration plate image is added to the traversal group, and the traversal is performed based on the calibration patterns in the traversal group.

[0033] And after each traversal, the calibration pattern supplemented in the current traversal process is added to the traversal group, and the next traversal is performed based on the traversal group of the supplemented calibration pattern, until the number of traversals reaches a preset number or all the calibration patterns have no newly added supplemented calibration pattern.

[0034] In addition, the supplementing module is further configured to, after supplementing the calibration patterns in the calibration plate image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns, perform the following steps:

[0035] For each row or each column of calibration patterns, determine a first calibration pattern and a second calibration pattern located at the end of the row or the column of calibration patterns;

[0036] Determine a first distance between the first calibration pattern and a preset boundary line closest to the first calibration pattern, and a second distance between the second calibration pattern and a preset boundary line closest to the second calibration pattern, and in the case that the first distance is greater than the second distance, supplement calibration patterns on the side of the first calibration pattern away from the second calibration pattern.

[0037] In addition, the above-mentioned device according to the embodiments of the present application can further include a correction module configured to, after supplementing the calibration patterns in the calibration plate image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns, perform the following processing:

[0038] Determine the pixel coordinates of the center points of each calibration pattern in the calibration plate image after the supplementing is completed;

[0039] Generate a vector diagram between image pixel coordinates and physical space coordinates according to the pixel coordinates of the center points of each calibration pattern and the actual physical space coordinates of the center points of each calibration pattern on the calibration plate;

[0040] According to the vector diagram, the calibration plate image is corrected for distortion.

[0041] And the correction module is further used to perform the following processing before performing distortion correction on the calibration plate image according to the vector diagram:

[0042] According to the vector diagram, a first real value diagram corresponding to the row direction and a second real value diagram corresponding to the column direction are generated;

[0043] According to the preset resolution requirement, the first real value diagram and the second real value diagram are cropped;

[0044] The cropped first real value diagram and the second real value diagram are spliced to obtain a vector diagram, and it is confirmed that the spliced vector diagram is used for distortion correction on the calibration plate image.

[0045] According to another aspect of the present application, an electronic device is provided, comprising a processor and a memory, wherein the memory stores computer program instructions, and the computer program instructions are used to execute the above-mentioned calibration plate image processing method when executed by the processor.

[0046] According to another aspect of the present application, a storage medium is also provided, and program instructions are stored on the storage medium, and the program instructions are used to execute the above-mentioned calibration plate image processing method when executed.

[0047] By means of the scheme of the present application, the calibration pattern can be supplemented for the image of the calibration plate, so that in the case of poor shooting effect or existence of blocking, tilting, inability to fill the camera field of view and other adverse factors, the number of calibration patterns can be reasonably increased, better quality calibration patterns are obtained, and the subsequent success rate of camera calibration is improved. BRIEF DESCRIPTION OF DRAWINGS

[0048] Figure 1 is a flowchart of the calibration plate image processing method of the embodiment of the present application;

[0049] Figure 2 is a block diagram of the calibration plate image processing device of the embodiment of the present application. DETAILED DESCRIPTION

[0050] In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, the present application will be further described in detail below with reference to the drawings and specific embodiments.

[0051] According to the embodiment of the present application, a calibration plate image processing method is provided. The method can be used to process the calibration plate image, so as to eliminate the image distortion. The scheme of the present application can be used for various calibration plates, and the calibration pattern in the calibration plate image shot by the camera can come from the graphic mark sprayed or drawn on the calibration plate, or come from the hole or boss on the calibration plate.

[0052] AsFigure 1 As shown, the processing method of the calibration board image according to the embodiment of the application comprises the following steps:

[0053] In step S101, the center point positions of a plurality of calibration patterns in the calibration board image and the angle offset of the calibration board are obtained, wherein the calibration board has calibration patterns distributed according to a preset rule.

[0054] In step S103, the calibration patterns are supplemented in the calibration board image according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns.

[0055] The shape of the calibration pattern can be circular, rectangular, square, triangular, trapezoidal or irregular, and the center position of the shape pattern can be determined by various known methods. Moreover, the distribution of the calibration pattern only needs to satisfy a certain rule. With the determination of the calibration pattern position and the preset rule of the calibration pattern distribution, the missing calibration pattern in the calibration board image can be supplemented, thereby solving the problem of calibration failure caused by the occlusion, inclination or incomplete filling of the camera field of view of the calibration board.

[0056] In order to facilitate the explanation of the technical scheme of the application, in an embodiment, the shape of the calibration pattern can be circular, the center point of the calibration pattern is the center of the circle, the preset rule of the distribution can be linear arrangement along the first direction and the second direction, and the distribution is according to a preset interval in the first direction and the second direction, wherein the first direction is perpendicular to the second direction.

[0057] In addition, in an embodiment, in the process of supplementing the calibration pattern according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns, each calibration pattern of the calibration board in the calibration board image can be traversed (the actual captured calibration pattern is traversed, and the starting position of the traversal can be arbitrarily selected, for example, the calibration pattern located at the upper left corner can be selected as the starting position of the traversal), and for each calibration pattern, if it is determined that the number of adjacent calibration patterns of the calibration pattern does not reach a preset number, the missing calibration pattern is supplemented according to the direction of the missing calibration pattern and the interval between the calibration patterns in the direction. If the calibration patterns are arranged in rows and columns, the number of adjacent calibration patterns of each calibration pattern should be four, and if the number of other calibration patterns around the calibration pattern does not reach four, it is necessary to determine which direction among the four directions of up, down, left and right is missing the calibration pattern, and then supplement a new calibration pattern in the direction.

[0058] In the above scheme, not only the middle position of the calibration plate image will be supplemented with the calibration pattern, but also the edge position of the calibration plate image will be supplemented with the calibration pattern. For the calibration pattern at the edge of the original calibration plate image, the number of adjacent calibration patterns cannot reach the preset number. For example, for the calibration pattern at the leftmost column, there is no other calibration pattern to the left of it. By traversing, it is determined that there is a missing calibration pattern to the left of the calibration pattern, and the calibration pattern will be supplemented in the left direction according to the preset distribution rule. By setting the number of traversals, not only the edge of the calibration plate can be supplemented, but also the area outside the real edge of the calibration plate can be supplemented with the calibration pattern. Even if the number of calibration patterns of the calibration plate is insufficient, it can also be expanded to improve the success rate of calibration. However, this supplementing process is not unlimited. After supplementing other calibration patterns around a calibration pattern each time, it is determined whether the distance of the currently supplemented calibration pattern from the preset boundary line reaches the preset distance (or, it can also be directly determined whether it exceeds the boundary line). If the result is yes, the supplemented calibration pattern is deleted, and it is determined that the calibration pattern has no new supplemented calibration pattern. This process is repeated until it is determined that all calibration patterns have no new supplemented calibration pattern. In this way, after the supplementing is completed, all supplemented calibration patterns and original calibration patterns are located within the preset area range (which can correspond to the effective field of view range of the camera), and will not exceed the effective range.

[0059] In the preferred embodiment of the present application, in order to improve the effect of supplementing and ensure the accuracy of calibration after supplementing, the supplementing of the calibration pattern is preferentially performed along the first direction, and then the supplementing of the calibration pattern is performed along the second direction. The first direction is the row direction, and the second direction is the column direction. Alternatively, the first direction is the column direction, and the second direction is the row direction. By this scheme, the situation that the local distortion correction error is large when mixed completion is removed, the distribution fluctuation of the distance between the center positions of adjacent calibration patterns after correction is smaller, and the correction result is more accurate.

[0060] Suppose that the first direction is the row direction and the second direction is the column direction. In this case, when traversing, the supplementing in the row direction is first completed, and then the supplementing in the column direction is completed.

[0061] Specifically, when the supplement is performed in the row direction, the supplement can be performed in the following way: starting from the calibration pattern at the starting position, sequentially traversing each calibration pattern, for each calibration pattern, if it is determined that the number of adjacent calibration patterns of the calibration pattern does not reach the preset number, it is determined whether the adjacent position of the calibration pattern in the row direction is missing a calibration pattern, and a new calibration pattern is supplemented in the corresponding direction. Similarly, after each supplement, it is necessary to determine whether the supplemented calibration pattern exceeds the boundary, and if it exceeds, the currently supplemented calibration pattern is deleted, until all the calibration patterns have no newly supplemented calibration pattern in the row direction, and the supplement in the row direction is completed.

[0062] Similarly, when the supplement is performed in the column direction, the supplement can also be performed in the following way: starting from the calibration pattern at the starting position, sequentially traversing each calibration pattern, for each calibration pattern, if it is determined that the number of adjacent calibration patterns of the calibration pattern does not reach the preset number, it is determined whether the adjacent position of the calibration pattern in the column direction is missing a calibration pattern, and a new calibration pattern is supplemented in the corresponding direction. Similarly, after each supplement, it is necessary to determine whether the supplemented calibration pattern exceeds the boundary, and if it exceeds, the currently supplemented calibration pattern is deleted, until all the calibration patterns have no newly supplemented calibration pattern in the column direction, and the supplement in the column direction is completed.

[0063] In an embodiment, in the implementation of the above process of traversing each calibration pattern of the calibration board in the calibration board image, each existing calibration pattern of the calibration board in the calibration board image can be added to a traversal group in advance, and the traversal is performed based on the calibration patterns in the traversal group;

[0064] And after each traversal, the calibration pattern supplemented in the current traversal process is added to the traversal group, and the next traversal is performed based on the traversal group of the supplemented calibration pattern, until the number of traversals reaches a preset number or all the calibration patterns have no newly supplemented calibration pattern.

[0065] Through the above traversal scheme, the calibration patterns in the calibration board image can be supplemented in a reliable and reasonable manner.

[0066] In addition, in actual application, it is possible that due to shooting or environment and other reasons, a large area of calibration patterns is missing, and after multiple cycles of traversal and supplement of calibration patterns, the region where the calibration patterns are located is still relatively far from the preset boundary. For this situation, after the supplement is completed, the following verification and completion can be performed, and the specific process is as follows:

[0067] For each row or column of calibration patterns, if the number of calibration patterns in the row or column is less than the minimum number threshold, it indicates that the completion degree of the row or column is low, and the row or column belongs to a relatively peripheral region (because of inclination and other reasons, the calibration patterns of these rows or columns will exceed the effective region and be deleted), and the row or column should be deleted.

[0068] For each row or each column reserved after the deletion process, determine the first fiducial pattern and the second fiducial pattern located at the end of the row or the column;

[0069] Determine the first distance between the first fiducial pattern and the preset boundary line closest to the first fiducial pattern, and determine the second distance between the second fiducial pattern and the preset boundary line closest to the second fiducial pattern, and if the first distance is greater than the second distance, supplement fiducial patterns on the side of the first fiducial pattern away from the second fiducial pattern. Here, the number of fiducial patterns supplemented each time can be pre-set, which can be one or multiple. For example, in actual implementation, the center positions of the leftmost fiducial pattern and the rightmost fiducial pattern can be obtained for any row of fiducial patterns, the distance L1 of the leftmost fiducial pattern from the left boundary is determined, and the distance L2 of the rightmost fiducial pattern from the right boundary is determined. Assuming that L1 is greater than L2, one or more fiducial patterns need to be supplemented on the left side of the leftmost fiducial pattern.

[0070] For each column, the above similar processing can also be performed, with the difference being that the positions of the two fiducial patterns at the top and bottom of each column need to be obtained, and the positions of the fiducial patterns at the top and bottom are compared with the upper boundary and the lower boundary, respectively.

[0071] The above supplement of the fiducial patterns at the end of each row and each column can be understood as follows: if a row or a column is missing only a small number of fiducial patterns, and other fiducial patterns of the row or the column are accurate, then the row or the column should not be deleted, but should be completed to further improve the effect of calibration.

[0072] In addition, after the supplement process is completed, the method according to the embodiment of the application can further include:

[0073] Determine the pixel coordinates of the center points of each fiducial pattern in the fiducial plate image after the supplement is completed;

[0074] Generate a vector diagram between image pixel coordinates and physical space coordinates according to the pixel coordinates of the center points of each fiducial pattern and the actual physical space coordinates of the center points of each fiducial pattern on the fiducial plate;

[0075] According to the vector diagram, perform distortion correction on the fiducial plate image, which can be understood as generating an image without distortion at this time.

[0076] Optionally, before performing distortion correction on the fiducial plate image according to the vector diagram, a first real value diagram corresponding to the row direction and a second real value diagram corresponding to the column direction can be generated according to the vector diagram;

[0077] cutting the first real value graph and the second real value graph according to the preset resolution requirement;

[0078] splicing the first real value graph and the second real value graph after cutting to obtain a vector graph, and confirming that the spliced vector graph is used for distortion correction of the calibration board image.

[0079] According to the embodiment of the present application, a processing device for a calibration board image is also provided. As shown in the figure, the processing device for a calibration board image according to the embodiment of the present application comprises: Figure 2

[0080] The acquisition module 21 is configured to acquire the center point positions of the plurality of calibration patterns of the calibration board in the calibration board image and the angle offset of the calibration board, wherein the calibration board has calibration patterns distributed according to a preset rule.

[0081] The supplement module 22 is configured to supplement calibration patterns to the calibration board image according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns.

[0082] The preset rule distribution refers to that the calibration patterns on the calibration board are linearly arranged in a first direction and a second direction, and are distributed at a preset interval in the first direction and the second direction, wherein the first direction is perpendicular to the second direction.

[0083] In addition, when supplementing calibration patterns to the calibration board image, the supplement module 22 will preferentially supplement calibration patterns along the first direction, and then supplement calibration patterns along the second direction.

[0084] The first direction is the row direction and the second direction is the column direction, or the first direction is the column direction and the second direction is the row direction.

[0085] In addition, when supplementing calibration patterns to the calibration board image according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns, the supplement module 22 is specifically configured to perform the following processing:

[0086] traverse each calibration pattern of the calibration board in the calibration board image, and for each calibration pattern, if it is determined that the number of adjacent calibration patterns of the calibration pattern does not reach a preset number, supplement according to the direction of the missing calibration pattern and the interval between the calibration patterns in the direction; wherein after supplementing one calibration pattern each time, it is determined whether the distance of the currently supplemented calibration pattern beyond the preset boundary line reaches a preset distance, and if the determination result is yes, the supplemented calibration pattern is deleted, and it is determined that the calibration pattern has no newly added supplemented calibration pattern, until it is determined that all calibration patterns have no newly added supplemented calibration pattern.

[0087] ​In the process of traversing each calibration pattern of the calibration board in the calibration board image, each existing calibration pattern of the calibration board in the calibration board image is added to a traversal group, and the traversal is performed based on the calibration patterns in the traversal group;

[0088] And after each traversal, the calibration pattern supplemented in the current traversal process is added to the traversal group, and the next traversal is performed based on the traversal group of the supplemented calibration pattern, until the number of traversals reaches a preset number or all calibration patterns have no new supplemented calibration patterns.

[0089] In addition, the supplement module 22 is further configured to perform the following steps after supplementing the calibration patterns in the calibration board image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns:

[0090] For each row or each column of calibration patterns, determine the first calibration pattern and the second calibration pattern located at the end of the row or the column of calibration patterns;

[0091] Determine a first distance between the first calibration pattern and a preset boundary line closest to the first calibration pattern, and a second distance between the second calibration pattern and a preset boundary line closest to the second calibration pattern, and supplement a calibration pattern on a side of the first calibration pattern away from the second calibration pattern if the first distance is greater than the second distance.

[0092] In addition, the above-mentioned device according to the embodiments of the present application can further include a correction module (not shown) configured to perform the following processing after supplementing the calibration patterns in the calibration board image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns:

[0093] Determine the pixel coordinates of the center points of each calibration pattern in the calibration board image after the supplement is completed;

[0094] Generate a vector diagram between image pixel coordinates and physical space coordinates according to the pixel coordinates of the center points of each calibration pattern and the actual physical space coordinates of the center points of each calibration pattern on the calibration board;

[0095] According to the vector diagram, perform distortion correction on the calibration board image.

[0096] And the correction module is further configured to perform the following processing before performing distortion correction on the calibration board image according to the vector diagram:

[0097] According to the vector diagram, generate a first real value diagram corresponding to a row direction and a second real value diagram corresponding to a column direction;

[0098] According to a preset resolution requirement, cut the first real value diagram and the second real value diagram;

[0099] The first real value graph and the second real value graph after cutting are spliced to obtain a vector graph, and it is confirmed that the spliced vector graph is used for distortion correction of the calibration plate image.

[0100] According to still another aspect of the present application, an electronic device is provided, comprising a processor and a memory, wherein the memory stores computer program instructions, which, when executed by the processor, are used to perform the above-mentioned calibration plate image processing method, the specific process and multiple embodiments of which have been described in the foregoing and will not be repeated here.

[0101] According to still another aspect of the present application, a storage medium is also provided, on which program instructions are stored, which, when executed, are used to perform the above-mentioned calibration plate image processing method, the specific process and multiple embodiments of which have been described in the foregoing and will not be repeated here.

[0102] The above is only a specific embodiment of the present application, and it should be understood that the above embodiment is only used to help understand the method of the present application and its core idea, and does not limit the protection scope of the present application. Any modification, equivalent replacement, etc. within the spirit and principles of the present application should be included in the protection scope of the present application.

Claims

1. A method of processing a calibration plate image, characterized by, The method comprises the following steps: obtaining the center point positions of a plurality of calibration patterns of a calibration board in a calibration board image and an angle offset of the calibration board, wherein the calibration board has calibration patterns distributed according to a preset rule; supplementing calibration patterns to the calibration board image according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns; wherein the preset rule distribution refers to that the calibration patterns on the calibration board are linearly arranged in a manner along a first direction and a second direction, and are distributed at a preset interval in the first direction and the second direction, wherein the first direction is perpendicular to the second direction; and supplementing calibration patterns to the calibration board image according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns comprises: traversing each calibration pattern of the calibration board in the calibration board image, and for each calibration pattern, if it is determined that the number of adjacent calibration patterns of the calibration pattern does not reach a preset number, then supplementing calibration patterns according to the direction of the missing calibration pattern and the interval between the calibration patterns in the direction; wherein after supplementing one calibration pattern each time, it is determined whether the distance of the current supplemented calibration pattern from the preset boundary line reaches a preset distance, and in the case that the determination result is yes, the supplemented calibration pattern is deleted, and it is determined that the calibration pattern has no newly added supplemented calibration pattern, until it is determined that all calibration patterns have no newly added supplemented calibration pattern.

2. The treatment method according to claim 1, characterized in that, When supplementing calibration patterns to the calibration board image, the supplementing of calibration patterns is preferentially performed along the first direction, and then the supplementing of calibration patterns is performed along the second direction; wherein the first direction is the row direction, and the second direction is the column direction; or the first direction is the column direction, and the second direction is the row direction.

3. The treatment method of claim 1, wherein When traversing each calibration pattern of the calibration board in the calibration board image, each existing calibration pattern of the calibration board in the calibration board image is added to a traversal group, and the traversal is performed based on the calibration patterns in the traversal group; and after each traversal, the calibration patterns supplemented in the current traversal process are added to the traversal group, and the next traversal is performed based on the traversal group of the supplemented calibration patterns, until the number of traversals reaches a preset number or all calibration patterns have no newly added supplemented calibration patterns.

4. The treatment method of claim 1, wherein After supplementing calibration patterns to the calibration board image according to the angle offset, the preset rule and the center point positions of the plurality of calibration patterns, the method further comprises: for each row or each column of calibration patterns, determining a first calibration pattern and a second calibration pattern located at the end of the row or the column of calibration patterns; determining a first distance between the first calibration pattern and a preset boundary line closest to the first calibration pattern, and a second distance between the second calibration pattern and a preset boundary line closest to the second calibration pattern, and in the case that the first distance is greater than the second distance, supplementing calibration patterns on the side of the first calibration pattern away from the second calibration pattern.

5. The treatment method of claim 1, wherein After the calibration pattern is supplemented to the calibration board image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns, the method further comprises: determining the pixel coordinates of the center points of each calibration pattern in the calibration board image after the supplement is completed; generating a vector diagram between image pixel coordinates and physical space coordinates according to the pixel coordinates of the center points of each calibration pattern and the actual physical space coordinates of the center points of each calibration pattern on the calibration board; performing distortion correction on the calibration board image according to the vector diagram.

6. The treatment method according to claim 5, characterized in that, Before the distortion correction is performed on the calibration board image according to the vector diagram, the method further comprises: generating a first real value diagram corresponding to a row direction and a second real value diagram corresponding to a column direction according to the vector diagram; cutting the first real value diagram and the second real value diagram according to a preset resolution requirement; splicing the cut first real value diagram and the second real value diagram to obtain a vector diagram, and confirming that the spliced vector diagram is used for the distortion correction on the calibration board image.

7. A processing device of a calibration plate image, characterized by, comprises: an acquisition module configured to acquire the center point positions of a plurality of calibration patterns of a calibration board in a calibration board image and an angle offset of the calibration board, wherein the calibration board has calibration patterns distributed according to a preset rule; a supplement module configured to supplement calibration patterns to the calibration board image according to the angle offset, the preset rule, and the center point positions of the plurality of calibration patterns; wherein the preset rule distribution refers to that the calibration patterns on the calibration board are linearly arranged in a first direction and a second direction, and are distributed at a preset interval in the first direction and the second direction, wherein the first direction is perpendicular to the second direction; and the supplement module is configured to traverse each calibration pattern of the calibration board in the calibration board image, and for each calibration pattern, if it is determined that the number of adjacent calibration patterns of the calibration pattern does not reach a preset number, the calibration pattern is supplemented according to the direction of the missing calibration pattern and the interval between the calibration patterns in the direction; wherein after each time a calibration pattern is supplemented, it is determined whether the distance of the supplemented calibration pattern beyond the preset boundary line reaches a preset distance, and in the case that the determination result is yes, the supplemented calibration pattern is deleted, and it is determined that the calibration pattern has no new supplemented calibration pattern, until it is determined that all calibration patterns have no new supplemented calibration pattern.

8. An electronic device comprising a processor and a memory, wherein, The memory stores computer program instructions, and the computer program instructions are run by the processor to execute the processing method in any one of claims 1 to 6.

9. A storage medium, on which program instructions are stored, and the program instructions are run to execute the processing method in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Robot tail end positioning deviation correction method and system

    CN105066884A

  • Fish-eye image splicing method based on long-strip scaling board

    CN106875339A