A method for identifying a circular calibration board

By performing binary processing and calculation of the center of mass standard deviation of the circular calibration plate image, combined with iterative and perspective projection, the center coordinates are quickly identified, which solves the problems of slow identification speed and poor robustness in the prior art, and achieves efficient and accurate circular calibration plate recognition.

CN113963070BActive Publication Date: 2025-08-05NANJING TUODAO MEDICAL TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111331058.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-11
Publication Date
2025-08-05
Estimated Expiration
2041-11-11

AI Technical Summary

Technical Problem

The existing circular grid calibration methods are slow to identify and are not robust, easily affected by the background environment, making it difficult to accurately identify circular calibration plates.

Method used

By binarizing the circular calibration plate image, the standard deviation of the center of mass and boundary point distance of the connecting block is calculated, the candidate circle set is iteratively selected, and the center coordinates are identified by combining perspective projection and subpixel boundary point fitting.

Benefits of technology

It realizes fast and robust circular calibration plate recognition, which can effectively remove noise and image distortion, and improves recognition accuracy and stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113963070B_ABST
    Figure CN113963070B_ABST
Patent Text Reader

Abstract

The present invention discloses a circular calibration plate recognition method, comprising the following steps: (1) a camera captures an image of a circular calibration plate and performs binarization processing on the image; (2) a connected domain search is performed to obtain connected blocks on the image; (3) the centroid of each connected block and the distance between the boundary point of each connected block and its centroid are calculated, and the standard deviation of each connected block is calculated based on the calculated distance, and the blocks are sorted from small to large; the number of circular marking points on the calibration plate is T, and the first T0 connected blocks in the sorting are selected as candidate circle sets, where T0>T; (4) the average value of the centroids of all candidate circles is calculated, and the distance between the centroid of each candidate circle and the average value is calculated based on the calculated distance, and the blocks are sorted from small to large; L is used as the iteration step length, and the first T connected blocks in the sorting are selected. k (5) Repeat step (4) until T candidate circles are obtained, which are the final T circular marking points. The present invention has a fast recognition speed and high robustness by iteratively extracting circles on the circular calibration plate.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of visual technology, and in particular to a circular calibration plate recognition method. Background Art

[0002] In recent years, with the continuous development of artificial intelligence, computer vision has also gained widespread application. As an essential component of industrial vision, cameras are becoming increasingly important. Camera calibration aims to determine the camera's internal and external parameters. Traditional common camera calibration methods include checkerboard calibration and circular grid calibration. Due to its characteristics, the circular grid calibration method has slightly higher accuracy than the checkerboard grid. Other calibration methods exist, but they require custom calibration plates, which have higher requirements.

[0003] The general circular grid recognition algorithm is slow and often fails to recognize the object due to the influence of the background environment, so the algorithm is not very robust. Summary of the Invention

[0004] Purpose of the invention: In view of the above shortcomings, the present invention proposes a circular calibration plate recognition method with high speed and high algorithm robustness.

[0005] Technical solution:

[0006] A circular calibration plate recognition method comprises the following steps:

[0007] (1) The camera collects the image of the circular calibration plate and performs binarization processing on the image;

[0008] (2) Search for connected domains on the binary image to obtain connected blocks on the image;

[0009] (3) Calculate the centroid position of each connected block and the distance between the boundary point of each connected block and its centroid position, and calculate the standard deviation of each connected block based on this, and sort them from small to large; the number of circular marking points on the calibration plate is T, and select the first T0 connected blocks in the sorting as the candidate circle set, T0>T;

[0010] (4) Calculate the average value of the mass centers of all candidate circles in the candidate circle set, and calculate the distance from the mass center position of each candidate circle to the average value based on this, and sort them from small to large; use L as the iteration step size, and select T before sorting. k candidate circles and update the candidate circle set, T k <T0;

[0011] (5) Repeat step (4) until T candidate circles are obtained, which are the final T circle marking points.

[0012] The method further includes step (6), wherein the boundary points of the obtained circle are transformed into a circle through perspective projection, the sub-pixel boundary points are calculated, the center of the circle is obtained by fitting, and then the center coordinates of the circles on the final calibration plate are obtained by back-projection.

[0013] The step (2) specifically comprises: performing row traversal on the binary image to obtain connected regions of each row, and performing column clustering on each connected region to obtain each connected block on the binary image.

[0014] The row traversal is specifically as follows:

[0015] Traverse the image from left to right, where I(x,y) represents the pixel value at the point (x,y) on the image after binarization in step (1). When the pixel value I of the uth point on a certain row is obtained, u When (x, y) = 1, it is defined as the left boundary m of a connected area on the line until the pixel value I of v points is traversed based on the u-th point. u+v When (x,y)=0, then I u+v-1 (x, y) = 1 is the right boundary n of the connected region; and so on, the connected pixels in each row are classified to obtain the connected regions C1[m,n],…,C W [m,n], where W represents the number of connected regions traversed;

[0016] Finally, the connected area classification results of all rows are obtained:

[0017] R i ={C1,..C W}

[0018] Here, i represents the i-th row.

[0019] The connected blocks on the binary image obtained by clustering the connected regions are specifically:

[0020] Let the connected regions involved in adjacent rows be the w1th connected region in the i-th row and the w2th connected region in the i+1-th row, then their connectivity is expressed as:

[0021] Con=! (R i .C w1 .n <R i+1 .C w2 .m||R i+1 .C w2 .n <R i .C w1 .m)

[0022] Traverse all connected regions between adjacent rows in turn. If the connected regions are also connected in columns, merge the connected regions of adjacent rows to obtain connected blocks.

[0023] The center of mass (x o ,y o ) are as follows:

[0024]

[0025] Among them, N represents the number of points in the connected block, (x t ,y t ) represents a point in the connected block.

[0026] The step (3) is specifically as follows:

[0027] The distance from the jth boundary point of a connected block to its centroid is:

[0028] Then the standard deviation of the distance from all boundary points of the connected block to its centroid is in, It is the average distance between all boundary points of the connected block and its centroid.

[0029] In step (4), after each iteration, the selected T k Is the difference between T less than the set iteration step L? If so, the selected T k The difference between and T is used as the new iteration step size; if it is not less than , the iteration continues with the previous iteration step size L.

[0030] In the step (5), the iteration step length L is set to gradually decrease with iteration.

[0031] The reduction amplitude of the iteration step is set to 1.

[0032] Beneficial effects: The present invention achieves fast recognition speed and high robustness through iterative extraction of circles on a circular calibration plate. BRIEF DESCRIPTION OF THE DRAWINGS

[0033] Figure 1 Flowchart of the present invention.

[0034] Figure 2 The original image of the circular calibration plate captured by the camera.

[0035] Figure 3 Schematic diagram of a binarized image according to the present invention.

[0036] Figure 4This is a classification diagram of connected areas in the same row of the present invention.

[0037] Figure 5 These are two boundary cases of column connectivity in the present invention.

[0038] Figure 6 It is the column connected clustering graph of the present invention. DETAILED DESCRIPTION

[0039] The present invention will be further explained below with reference to the accompanying drawings and specific embodiments.

[0040] Figure 1 It is a flow chart of the present invention, as shown in FIG. Figure 1 As shown, the circular calibration plate recognition method of the present invention includes the following steps:

[0041] (1) Collect the original image of the circular calibration plate through the camera, such as Figure 2 As shown in the figure, the circular calibration plate is a white background calibration plate with several black circular marks on it, where the number of circular marks is known; the original image with the circular calibration plate is binarized using a local adaptive threshold, and the image is as follows Figure 3 The binary image shown; in the present invention, 0 represents black and 1 represents white in the binary image;

[0042] The circles on the image after the binarization process in step (1) have the following properties: the pixels in the circle on the same row are connected, and the pixels on the column are also connected;

[0043] (2) Traverse the binary image row by row to obtain the connected areas of each row;

[0044] The image after binarization in step (1) is traversed from left to right, where I(x,y) represents the pixel value at the point (x,y) on the image after binarization in step (1). When the pixel value I of the uth point on a row is obtained, u When (x, y) = 1, it is defined as the left boundary m of a connected area on the line until the pixel value I of v points is traversed based on the u-th point. u+v When (x,y)=0, then I u+v-1 (x, y) = 1 is the right boundary n of the connected region; and so on, each row of connected pixels can be classified to obtain each connected region C1[m,n],…,C W [m,n], where W represents the number of connected regions traversed; Figure 4 As shown, the connected area classification results of all rows are finally obtained:

[0045] R i ={C1,..C W}

[0046] Among them, i represents the i-th row;

[0047] (3) Perform column clustering on each connected region obtained in step (2) to obtain each connected block;

[0048] (31) If the connected regions between adjacent rows intersect at the boundary, the two connected regions are considered to be connected in the column;

[0049] Then, starting from the first connected region of R1, we traverse and search for the region in R2 that is connected to a connected region of R1 until all connected regions of R1 are traversed, and all connected regions between R2 and R1 on the column are obtained; if adjacent columns are connected, there are two possible boundary conditions as follows: Figure 5 As shown in , the connected areas between adjacent rows must have an intersection. Let the connected areas involved in adjacent rows be the w1th connected area in the i-th row and the w2th connected area in the i+1-th row. The formula is described as:

[0050] Con=! (R i .C w1 .n <R i+1 .C w2 .m||R i+1 .C w2 .n <R i .C w1 .m)

[0051] Among them, R i .C w1 .m represents the left boundary of the w1th connected region in the i-th row, R i .C w1 .n represents the right boundary of the w1th connected region in the i-th row, R i+1 .C w2 .m represents the left boundary of the w2th connected region in the i+1th row, R i+1 .C w2 .n represents the right boundary of the w2th connected region in the i+1th row, R i .C w1 .n <R i+1 .C w2 .m means that the right boundary of the w1th connected region in the i-th row and the left boundary of the w2th connected region in the i+1th row have no intersection, R i+1 .C w2 .n <R i .C w1 .m means that the right boundary of the w2th connected region in the i+1th row has no intersection with the left boundary of the w1th connected region in the ith row;

[0052] (32) According to the above formula, the connected regions between adjacent rows are traversed and searched. If there is a region in R2 that is connected to a connected region in R1, the two regions are merged.

[0053] (33) Search for areas in R3 that are connected to a certain connected area in R2, and so on, until all connected blocks are obtained after traversing the image, such as Figure 6 As shown; the connected block can be described as P q ={I1,..I J}, where P q represents the qth connected block, I1,..I J is the boundary point of the connected block, J represents the number of boundary points of the connected block;

[0054] (4) After the column clustering is completed, many connected blocks will be obtained on the image. However, our goal is to obtain the circle on the calibration plate, which still contains a lot of noise: the characteristic of a circle is that the distance from all points on the boundary to the center of the circle is equal. First, due to the problem of image shooting angle, the circle may be an ellipse; second, when collecting the original image of the calibration plate, other objects that are not the calibration plate will be collected together. After binarization, there will be a lot of noise that does not belong to the calibration plate. Therefore, here we remove the noise by calculating the standard deviation of the distance from all boundary points in each connected block to its center of mass;

[0055] Among them, the centroid of a connected block (x o ,y o ): Among them, N represents the number of points in the connected block, (x t ,y t ) represents a point in the connected block;

[0056] Then the distance from the jth boundary point of a connected block to its centroid is:

[0057] Then the standard deviation of the distance from all boundary points of the connected block to its centroid position can be obtained as in, is the average value of the distance from all boundary points of the connected block to its centroid;

[0058] Because the dev of a circle is close to 0, even the dev of an ellipse is smaller than that of connected blocks of other shapes. The dev of all connected blocks is sorted from small to large. Since the number of circles on the calibration plate is known to be T, the first T0 connected blocks are selected as the candidate circle set, where T0>T, and T0 is set according to actual needs. In this embodiment, T0=T+20;

[0059] (5) Although the distance intervals of the circles on the calibration plate are equal, due to the problem of shooting angle, projection mapping and distortion, the image will be deformed and there will be some deviation in the distance. However, the circles are relatively concentrated, so according to the centroid position of each connected block obtained in step (4), the average value Cen of the centroids of all candidate circles in the candidate circle set is calculated, and the distance from the centroid position of each candidate circle to the average value Cen is calculated and sorted from small to large; L is used as the iteration step, and the first T k as candidate circles and update the candidate circle set, T k <T0; where the iteration step L is set according to actual needs;

[0060] (6) Repeat step (5) until T circles are obtained, which are the final T circular marking points;

[0061] (7) Due to the shooting angle problem, the circle is imaged as an ellipse, so the boundary points of the circle are transformed into a circle through perspective projection, and its sub-pixel boundary points are calculated. Then, the center of the circle is fitted and back-projected back to obtain the coordinates of the center of each circle on the final calibration plate, which are used to calculate the calibration.

[0062] In the present invention, after each iteration, the selected T k Is the difference between T less than the set iteration step L? If so, the selected T k The difference between and T is used as the new iteration step size; if it is not less than , the iteration continues with the previous iteration step size L.

[0063] In the present invention, the iteration step size may also be gradually reduced with iterations, and the reduction range of the iteration step size is determined according to actual needs; further, the reduction range of the iteration step size may be set to 1.

[0064] In the present invention, connected blocks are obtained by sequentially performing row traversal and column traversal, but the present invention is not limited thereto. The present invention can also obtain connected blocks on the binarized image by searching for connected areas of black pixels.

[0065] The preferred embodiments of the present invention are described in detail above, but the present invention is not limited to the specific details in the above embodiments. Within the technical concept of the present invention, various equivalent transformations (such as quantity, shape, position, etc.) can be made to the technical solution of the present invention, and these equivalent transformations all fall within the scope of protection of the present invention.

Claims

1. A circular calibration plate recognition method, characterized by: Including steps: (1) The camera collects the image of the circular calibration plate and performs binarization processing on the image; (2) Search for connected domains on the binary image to obtain connected blocks on the image; (3) Calculate the centroid position of each connected block and the distance between the boundary point of each connected block and its centroid position, and calculate the standard deviation of each connected block based on this, and sort them from small to large; The number of circular marking points on the calibration plate is T, and the first T0 connected blocks in the sorting are selected as the candidate circle set, T0>T; (4) Calculate the average value of the mass centers of all candidate circles in the candidate circle set, and calculate the distance from the mass center position of each candidate circle to the average value based on this, and sort them from small to large; use L as the iteration step size, and select T before sorting. k candidate circles and update the candidate circle set, T k <T0; (5) Repeat step (4) until T candidate circles are obtained, which are the final T circle marking points.

2. The circular calibration plate recognition method according to claim 1, wherein: The method further includes step (6), wherein the boundary points of the obtained circle are transformed into a circle through perspective projection, the sub-pixel boundary points are calculated, the center of the circle is obtained by fitting, and then the center coordinates of the circles on the final calibration plate are obtained by back-projection.

3. The circular calibration plate recognition method according to claim 1, wherein: The step (2) specifically comprises: performing row traversal on the binary image to obtain connected regions of each row, and performing column clustering on each connected region to obtain each connected block on the binary image.

4. The circular calibration plate recognition method according to claim 3, wherein: The row traversal is specifically as follows: Traverse the image from left to right, where I(x,y) represents the pixel value at the point (x,y) on the image after binarization in step (1). When the pixel value I of the uth point on a row is obtained, u When (x, y) = 1, it is defined as the left boundary m of a connected area on the line until the pixel value I of v points is traversed based on the u-th point. u+v When (x,y)=0, then I u+v-1 (x, y) = 1 is the right boundary n of the connected region; and so on, the connected pixels in each row are classified to obtain the connected regions C1[m,n],…,C W [m,n], where W represents the number of connected regions traversed; Finally, the connected area classification results of all rows are obtained: R i ={C1,..C W } Here, i represents the i-th row.

5. The circular calibration plate recognition method according to claim 4, characterized in that: The connected blocks on the binary image obtained by clustering the connected regions are specifically: Let the connected regions involved in adjacent rows be the w1th connected region in the i-th row and the w2th connected region in the i+1-th row, then their connectivity is expressed as: Con=!(R i .C w1 .n<R i+1 .C w2 .m||R i+1 .C w2 .n<R i .C w1 .m) Traverse the connected regions between all adjacent rows in turn. If the connected regions are also connected in columns, merge the connected regions of adjacent rows to obtain connected blocks.

6. The circular calibration plate recognition method according to claim 1, wherein: The center of mass (x o ,y o ) are as follows: Among them, N represents the number of points in the connected block, (x t ,y t ) represents a point in the connected block.

7. The circular calibration plate recognition method according to claim 1, wherein: The step (3) is specifically as follows: The centroid of a connected block is (x o ,y o ), its jth boundary point (x j ,y j ) to its center of mass is: Then the standard deviation of the distance from all boundary points of the connected block to its centroid is in, It is the average distance between all boundary points of the connected block and its centroid.

8. The circular calibration plate recognition method according to claim 1, wherein: In step (4), after each iteration, the selected T k Is the difference between T less than the set iteration step L? If so, the selected T k The difference with T is used as the new iteration step; If it is not less than, continue to iterate with the previous iteration step size L.

9. The circular calibration plate recognition method according to claim 1, wherein: In the step (4), the iteration step length L is set to gradually decrease with iteration.

10. The circular calibration plate recognition method according to claim 9, characterized in that: The reduction amplitude of the iteration step is set to 1.