CN116912324A - Internal reference calibration method of camera - Google Patents

Internal reference calibration method of camera Download PDF

Info

Publication number
CN116912324A
CN116912324A CN202310830821.7A CN202310830821A CN116912324A CN 116912324 A CN116912324 A CN 116912324A CN 202310830821 A CN202310830821 A CN 202310830821A CN 116912324 A CN116912324 A CN 116912324A
Authority
CN
China
Prior art keywords
calibration
robot
camera
point
calibration plate
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310830821.7A
Other languages
Chinese (zh)
Inventor
赖钦伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhuhai Amicro Semiconductor Co Ltd
Original Assignee
Zhuhai Amicro Semiconductor Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhuhai Amicro Semiconductor Co Ltd filed Critical Zhuhai Amicro Semiconductor Co Ltd
Priority to CN202310830821.7A priority Critical patent/CN116912324A/en
Publication of CN116912324A publication Critical patent/CN116912324A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/80Analysis of captured images to determine intrinsic or extrinsic camera parameters, i.e. camera calibration
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30244Camera pose

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Manipulator (AREA)

Abstract

The application discloses an internal reference calibration method of a camera, which comprises the following steps: s1: the robot acquires an image of a calibration plate of the calibration jig through a camera, and then identifies a calibration point from the image of the calibration plate; s2: the robot calibrates the internal reference of the camera according to the position of the calibration point on the calibration plate and the position of the calibration point in the image; s3: and detecting an internal reference calibration result of the camera by the robot, if the detection result is correct, taking the internal reference calibration result as the internal reference of the camera, and if the detection result is incorrect, calibrating the internal reference of the camera again by deleting the calibration plate and the calibration points of the image. The robot verifies the internal parameters of the camera to improve the accuracy of the internal parameter calibration result of the camera.

Description

Internal reference calibration method of camera
Technical Field
The application relates to the technical field of cameras, in particular to an internal parameter calibration method of a camera.
Background
The acquisition process of the geometric model parameters of the camera is called camera calibration, is an indispensable step for extracting three-dimensional space information from two-dimensional images in the fields of image processing and computer vision, and is widely applied to the fields of three-dimensional reconstruction, navigation, vision monitoring and the like. Therefore, how to calibrate the camera, the parameters of the geometric model of the camera and the importance of the parameters are obtained. The camera is calibrated under a certain camera model, and the geometric model parameters of the camera are obtained by processing the image and utilizing a series of data transformation and calculation methods. In the traditional calibration method, multiple images of the same marker at different positions are acquired, and then internal references of the camera are acquired based on the multiple images. The existing camera calibration method only calibrates the internal parameters of the camera, and does not detect the internal parameter calibration result of the camera, so that more errors occur in the internal parameter calibration result of the robot.
Disclosure of Invention
In order to solve the problems, the application provides an internal reference calibration method of a camera. The specific technical scheme of the application is as follows:
an internal reference calibration method of a camera comprises the following steps: s1: the robot acquires an image of a calibration plate of the calibration jig through a camera, and then identifies a calibration point from the image of the calibration plate; s2: the robot calibrates the internal reference of the camera according to the position of the calibration point on the calibration plate and the position of the calibration point in the image; s3: and detecting an internal reference calibration result of the camera by the robot, if the detection result is correct, taking the internal reference calibration result as the internal reference of the camera, and if the detection result is incorrect, calibrating the internal reference of the camera again by deleting the calibration plate and the calibration points of the image.
Further, in step S1, the robot acquires an image with a plurality of calibration plates through the camera, including the following steps: the robot moves to a calibration position of a calibration jig formed by a plurality of calibration plates; the robot makes the camera vertically upwards, then obtains the image that has all calibration boards of calibration tool through the camera.
Further, in step S1, the robot identifies a calibration point from the image of the calibration plate, including the steps of: the robot detects a quadrilateral black area in the image of the calibration plate; the robot connects the detected quadrilateral black areas in a clockwise direction; the robot acquires an inner quadrangle of a black area of the quadrangle; the robot uses four endpoints of the inner quadrangle as calibration points of the calibration plate through angular point detection; the calibration plate is a checkerboard calibration plate, and four sides of the inner quadrangle are respectively connected with the black areas of the quadrangle.
Further, in step S2, the robot calibrates the internal reference of the camera according to the position of the calibration point on the calibration plate and the position of the calibration point in the image on the image, including the following steps: the robot obtains physical coordinates of a calibration point on a physical coordinate system of the calibration plate and pixel coordinates of the calibration point in the image on the image; the robot projects the calibration points on the calibration plates into the images of the calibration plates according to the initial pose of each calibration plate relative to the center point of the robot and the initial internal reference of the camera to obtain projection coordinates of the calibration points of the calibration plates; the robot calculates the Euclidean distance between the projection coordinates of the calibration point of the calibration plate and the pixel coordinates of the calibration point in the image corresponding to the calibration point according to the Euclidean distance formula; and optimizing the internal parameters of the camera by the robot according to the acquired Euclidean distance through an iterative formula of a Gaussian Newton method to obtain the optimal internal parameters of the camera and the pose of the camera relative to each calibration plate.
Further, when the robot optimizes the internal parameters of the camera through the iterative formula of the Gauss Newton method and obtains the minimum Euclidean distance in the calculation process, the pose of each calibration plate corresponding to the minimum Euclidean distance and the central point of the robot and the internal parameters of the camera are used as the optimal internal parameters of the camera and the pose of the camera relative to each calibration plate.
Further, the robot obtains an initial pose of the calibration plate relative to a center point of the robot, comprising the following steps: the robot passes through the corner point of the upper left corner of the calibration plate and makes a vertical line perpendicular to the calibration plate; the robot takes an included angle between a vertical line vertical to the calibration plate and the advancing direction of the robot as an included angle between the calibration plate and the robot; the robot pre-stores the distance between the center point of the robot and the corner point of the upper left corner of the calibration plate when the robot calibrates the calibration position of the jig; and the robot combines according to the included angle between the calibration plate and the robot and the distance between the center point of the robot and the corner point of the upper left corner of the calibration plate to obtain the initial pose of the calibration plate relative to the center point of the robot.
Further, the robot obtains physical coordinates of the calibration point on the physical coordinate system of the calibration plate, including the following steps: the robot takes the corner point of the upper left corner of each calibration plate as an origin, and two sides of the calibration plate connected with the corner point of the upper left corner are respectively an X axis and a Y axis to construct a physical coordinate system; and the robot acquires the coordinates of the calibration point on the physical coordinate system according to the position of the calibration point on the calibration plate.
Further, in step S3, the robot detects the internal parameter calibration result of the camera, including the following steps: the robot classifies the calibration points in the image and determines the calibration plate to which the identified calibration points belong; the robot converts the pixel coordinates of the identified calibration points belonging to the same calibration plate into physical coordinates of a physical coordinate system of the calibration plate through the camera internal parameters and the pose of the camera relative to the calibration plate, and obtains the physical coordinates of the calibration points of the image; the robot acquires the Euclidean distance between the physical coordinates of the calibration points of the image and the physical coordinates of the calibration points of the calibration plate corresponding to the calibration points of the image, if the average value of the Euclidean distances of the set number is larger than a first set threshold value, the calibration of the calibration plate is judged to be wrong, otherwise, the calibration is correct; the robot is used for fitting the calibration points of the same calibration plate with correct calibration into a plurality of calibration point straight lines, then comparing the vertical distance between two adjacent and parallel calibration point straight lines, if the vertical distance between any two calibration point straight lines is larger than a second set threshold value, judging that the calibration plate is in error calibration, otherwise, the calibration is correct; the robot deletes the calibration plate with the wrong calibration and the identified calibration points belonging to the calibration plate, and then again calibrates the internal parameters of the camera.
Further, in step S2, the robot classifies the identified calibration points, and determines the calibration plate to which the identified calibration points belong, including the steps of: a1: the robot randomly selects the calibration points with the same number as the calibration plates as the centers of the clusters; a2: the robot obtains the cluster distance between the calibration point and the center of each cluster, and then assigns the calibration point to the cluster with the minimum cluster distance; a3: the robot obtains an average value of image coordinates of a calibration point of each cluster, and then takes the average value as the center of a new cluster; a4: the robot repeatedly performs the steps A2 and A3 until the average value of the image coordinates of the calibration point of each cluster is not changed, and then the robot determines the calibration plate to which the calibration point of each cluster belongs according to the center of each cluster.
Further, if the robot judges that all the calibration plates are in calibration error, the robot rotates for setting the angle, and then the camera is used for obtaining the image of the calibration plate of the calibration jig again to recalibrate the internal reference of the camera.
Compared with the prior art, the application has the beneficial effects that: according to the robot, after the internal parameters of the camera are calibrated through the image of the calibration plate, the accuracy of the internal parameter calibration result of the camera is improved through verifying the internal parameters of the camera, and then the accuracy of identifying objects during subsequent work of the robot is improved.
Drawings
Fig. 1 is a flow chart of an internal reference calibration method of a camera according to an embodiment of the application.
Detailed Description
Embodiments of the present application are described in detail below, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to like or similar elements or elements having like or similar functions throughout.
The technical scheme and the beneficial effects of the application are more clear and definite by further describing the specific embodiments of the application with reference to the drawings in the specification. The embodiments described below are exemplary by referring to the drawings for the purpose of illustrating the application and are not to be construed as limiting the application.
As shown in fig. 1, an internal parameter calibration method of a camera, the external parameter calibration method includes the following steps:
an internal reference calibration method of a camera comprises the following steps:
s1: the robot obtains an image of a calibration plate of the calibration jig through the camera, and then identifies a calibration point from the image of the calibration plate. The calibration jig is composed of a plurality of calibration plates, the number and the size of the calibration plates are adjusted according to the requirements of the robot, and the number and the size of the calibration plates are not limited. The calibration plate may be a checkerboard calibration plate, an ArUco calibration plate (ArUco is an open source library for estimating the pose of the camera according to a preset black-and-white markers), a churco calibration plate (churco calibration plate is obtained by combining a checkerboard calibration plate and an ArUco calibration plate), etc., and the calibration point may be a corner point, a dot, a ChArUco angle, etc. according to the type of the calibration plate. The robot can identify the calibration points from the image of the calibration plate through a corner detection algorithm. S2: the robot calibrates internal parameters of the cameras and obtains the pose of the cameras relative to each calibration plate according to the positions of the calibration points on the calibration plate and the positions of the calibration points in the images. The calibration points on the calibration plate are points on the calibration plate in the calibration jig in reality, the positions of the calibration points on the calibration plate are determined by the types and the sizes of the calibration plate, the positions of the calibration points on the calibration plate of different types and sizes are different, and a user can detect the positions of the calibration points on the calibration plate through auxiliary tools before calibrating the camera. The calibration points in the image are the calibration points identified in the calibration plate image, the positions of the calibration points in the image on the image are the pixel coordinates of the image, and the positions of the calibration points are obtained according to the pixel points occupied by the calibration points when the robot identifies the calibration points in the image. S3: and detecting an internal reference calibration result of the camera by the robot, if the detection result is correct, taking the internal reference calibration result as the internal reference of the camera, and if the detection result is incorrect, calibrating the internal reference of the camera again by deleting the calibration plate and the calibration points of the image. After the robot determines the internal parameters of the camera, the internal parameter calibration result can be detected to improve the accuracy of the internal parameter calibration result of the camera. The internal parameters of the camera calibrated by the robot are generally internal parameter matrixes, and the internal parameter matrixes comprise focal lengths and centers. In addition, for a wide angle camera, the internal parameters of the camera are projection functions instead of an internal matrix, and the projection functions include focal length, center and camera distortion parameters. The robot obtains the position appearance of the calibration board of demarcating the tool for the central point of demarcating the tool before the camera is demarcating, as long as with the central point coincidence of the central point of the robot of different external parameters and demarcating the tool, just can calculate the external parameters of robot through the position appearance of the calibration board of demarcating the tool for the central point of demarcating the tool, the flexibility is higher. According to the robot, after the internal parameters of the camera are calibrated through the image of the calibration plate, the accuracy of the internal parameter calibration result of the camera is improved through verifying the internal parameters of the camera, and then the accuracy of identifying objects during subsequent work of the robot is improved.
As one embodiment, in step S1, the robot obtains an image of a calibration plate of the calibration jig through a camera, and the method includes the following steps: the robot moves to the calibration position of the calibration jig formed by a plurality of calibration plates, and the calibration position can be set according to actual conditions, so that when the robots with the same shape are positioned at the calibration position, the center point of the robot and the corner point of the upper left corner of the calibration plates are the known values. The calibration plates of the calibration jig are generally arranged around the robot, the robot enables the camera to vertically upwards when the robot acquires images of the calibration plates, then the robot acquires the images with all the calibration plates of the calibration jig through the camera, in order to enable the camera to capture all the calibration plates, the robot can enable all the calibration plates of the calibration jig to fall into the visual angle range of the camera through autorotation, and if the calibration plates do not fall into the visual angle range of the camera, the calibration plates can be removed. The robot acquires the images of the calibration plates in a mode that the camera is vertically upwards, so that the robot is facilitated to acquire the images of all the calibration plates with the calibration jig, and the calibration efficiency is improved.
As one embodiment, in step S1, the robot identifies a calibration point from an image of the calibration plate, including the steps of: the robot detects a black area of a quadrangle in the image of the calibration plate. The robot connects the detected black areas of the quadrangle in the clockwise direction. The robot acquires an inner quadrangle of the black area of the quadrangle. The robot uses four endpoints of the inner quadrangle as calibration points of the calibration plate through corner detection. The calibration plate is a checkerboard calibration plate, four sides of the inner quadrangle are respectively connected with the black areas of the quadrangle, namely the black areas of the quadrangle are black quadrangles of the checkerboard, the inner quadrangle of the black areas of the quadrangle is white quadrangle of the checkerboard, and the four black quadrangles are surrounded by the four quadrangles. The robot firstly identifies the inner quadrangle from the checkerboard calibration plate, then takes four endpoints of the inner quadrangle as calibration points, effectively removes the calibration points connected with four edges of the checkerboard in the checkerboard, and improves the accuracy of the calibration result.
As one embodiment, in step S2, the robot calibrates internal parameters of the camera and obtains the pose of the camera relative to each calibration plate according to the position of the calibration point on the calibration plate and the position of the calibration point in the image on the image, and includes the following steps: the robot obtains physical coordinates of the calibration point on the physical coordinate system of the calibration plate and pixel coordinates of the calibration point in the image on the image. The robot obtains projection coordinates of the calibration points of the calibration plates by projecting the calibration points on each calibration plate into the image of the calibration plate according to the initial pose of the calibration plate and the center point of the robot (the initial pose is calculated by manually measuring the distance between the calibration plate and the center point of the robot) and the initial internal parameters of the camera (the initial camera internal parameters are estimated from the image (or obtained from a camera manufacturer)). The robot calculates the Euclidean distance between the projection coordinates of the calibration point of the calibration plate and the pixel coordinates of the calibration point in the image corresponding to the calibration point according to the Euclidean distance formula. And optimizing the internal parameters of the camera by the robot according to the acquired Euclidean distance through an iterative formula of a Gaussian Newton method to obtain the optimal internal parameters of the camera and the pose of the camera relative to each calibration plate. Assuming that the physical coordinates of the calibration point on the physical coordinate system of the calibration plate are (x 0, y 0), the projection coordinates (x 1, y 1) of the calibration point of the calibration plate are obtained by conversion from the projection coordinates, the pixel coordinates of the calibration point in the image on the image are (x 2, y 2), and the euclidean distance between the projection coordinates of the calibration point of the calibration plate and the pixel coordinates of the calibration point in the image corresponding to the calibration point is d=sqrt ((x 1-x 2) a2- (y 1-y 2) a2). Then the robot optimizes the internal parameters of the camera according to an iterative formula of Gauss Newton method, wherein θn+1=θn- (JTJ)' Λ < -1 >. JTd; wherein, thetan+1 is the updated internal reference or external reference, thetan is the pre-updated internal reference or external reference, d is the calculated Euclidean distance, and J is the Jacobian matrix. The robot can also optimize the pose of each calibration plate and the robot center point and internal parameters of the camera by a Levenberg-Marquardt algorithm (LM algorithm is the most widely used nonlinear least squares algorithm, chinese is the Levenberg-Marquardt method, which is an algorithm that uses gradients to find the maximum (small) value). After the initial pose of each calibration plate and the central point of the robot and the initial internal parameters of the camera are obtained by the robot, the pose of each calibration plate and the central point of the robot and the internal parameters of the camera are continuously and iteratively optimized through a Gauss Newton method, so that the pose of each calibration plate and the central point of the robot and the internal parameters of the camera obtained by the robot are the optimal values, and the accuracy of the calculation result is improved.
As one embodiment, when the robot optimizes the internal parameters of the camera through the iterative formula of the gauss newton method, and obtains the minimum euclidean distance in the calculation process, the pose of each calibration plate corresponding to the minimum euclidean distance and the central point of the robot and the internal parameters of the camera are used as the optimal internal parameters of the camera and the pose of the camera relative to each calibration plate. The Euclidean distance in the document is the re-projection error of the calibration point of the calibration plate and the calibration point in the image, and the pose of each calibration plate and the central point of the robot and the internal reference of the camera are obtained by obtaining the minimum value of the re-projection error, so that the practicability is higher.
As one of the embodiments, the robot obtains an initial pose of the calibration plate relative to a center point of the robot, including the steps of: the robot passes through the corner point of the upper left corner of the calibration plate and makes a vertical line perpendicular to the calibration plate; the robot takes an included angle between a vertical line vertical to the calibration plate and the advancing direction of the robot as an included angle between the calibration plate and the robot; the robot obtains the distance between the center point of the robot and the corner point of the upper left corner of the calibration plate; and the robot combines according to the included angle between the calibration plate and the robot and the distance between the center point of the robot and the corner point of the upper left corner of the calibration plate to obtain the initial pose of the calibration plate relative to the center point of the robot. The robot uses the midpoint of the robot as the origin of a robot coordinate system, the advancing direction of the robot is used as the X axis of the robot coordinate system, the wheel axis of the robot is used as the Y axis of the robot coordinate system, the robot constructs the robot coordinate system, and the initial pose of each calibration plate relative to the center point of the robot can be converted according to the included angle between the vertical line perpendicular to the calibration plate and the advancing direction of the robot, the distance between the corner points of the upper left corner of the calibration plate and the height of the upper left corner of the calibration plate. The robot calculates the pose of the calibration plate relative to the center point of the robot according to the included angle between the calibration plate and the robot and the distance between the center point of the robot and the corner point of the upper left corner of the calibration plate, so that the calculation speed is improved. As one of the embodiments, the robot acquires physical coordinates of the calibration point on the physical coordinate system of the calibration plate, including the steps of: the robot takes the corner point of the upper left corner of each calibration plate as an origin, and two sides of the calibration plate connected with the corner point of the upper left corner are respectively an X axis and a Y axis to construct a physical coordinate system; and the robot acquires the coordinates of the calibration point on the physical coordinate system according to the position of the calibration point on the calibration plate. The robot constructs a physical coordinate system according to the edges of the calibration plate respectively, so that the calculation accuracy is improved.
As one embodiment, in step S3, the robot detects the internal reference calibration result of the camera, and includes the following steps: the robot classifies the calibration points in the image and determines the calibration plate to which the identified calibration points in the image belong. And the robot converts the identified pixel coordinates of the calibration points belonging to the same calibration plate into physical coordinates of a physical coordinate system of the calibration plate through the optimal camera internal parameters and the pose of the camera relative to the calibration plate, so as to obtain the physical coordinates of the calibration points of the image. The robot acquires the Euclidean distance between the physical coordinates of the calibration points of the image and the physical coordinates of the calibration points of the calibration plate corresponding to the calibration points of the image, and if the average value of the Euclidean distances between the physical coordinates of the calibration points of the set number of images and the physical coordinates of the calibration points of the calibration plate corresponding to the calibration points of the image is larger than a first set threshold value, the calibration of the calibration plate is judged to be wrong, otherwise, the calibration is correct. The robot can also convert the physical coordinates of the calibration points of the calibration plate into the pixel coordinates of the image, and then calculate the euclidean distance with the pixel coordinates of the corresponding calibration points of the image. And the robot is used for fitting the calibration points of the same calibration plate with correct calibration into a plurality of calibration point straight lines, comparing the vertical distance between any two adjacent and parallel calibration point straight lines, and judging that the calibration plate is in error calibration if the vertical distance between any two adjacent and parallel calibration point straight lines is larger than a second set threshold value, otherwise, the calibration is correct. And the robot deletes the calibration plate with the calibration error and the identified calibration points belonging to the calibration plate, and then, the internal parameters of the camera are calibrated again through the step S2. If all the calibration plates are in error calibration, the robot rotates for a certain angle, and then the camera is used for acquiring images of the calibration plates of the calibration jig again to calibrate the internal parameters and the external parameters of the camera. The robot improves the accuracy of calculation by verifying the internal parameters of the camera.
As one embodiment, in step S2, the robot classifies the identified calibration points, determines the calibration plate to which the identified calibration points belong, and includes the following steps: a1: the robot randomly selects the calibration points with the same number as the calibration plates as the centers of clusters, wherein the clusters are point sets. A2: the robot acquires the cluster distance between the calibration point and the center of each cluster, and then assigns the calibration point to the cluster with the minimum cluster distance. A3: the robot obtains an average value of the image coordinates of the calibration points of each cluster, and then takes the average value as the center of the new cluster. A4: the robot repeatedly performs the steps A2 and A3 until the average value of the image coordinates of the calibration point of each cluster is not changed, and then the robot determines the calibration plate to which the calibration point of each cluster belongs according to the center of each cluster. The robot classifies the standard points through a clustering algorithm, so that the accuracy is high.
As one embodiment, if the robot judges that all the calibration plates are in calibration error, the robot rotates for setting the angle, and then the camera acquires the image of the calibration plate of the calibration jig again to recalibrate the internal reference of the camera. The robot re-calibrates the internal parameters of the camera by re-acquiring the image of the calibration plate, thereby improving the accuracy of the calibration result.
Compared with the prior art, the application has the beneficial effects that: according to the robot, after the internal parameters of the camera are calibrated through the image of the calibration plate, the accuracy of the internal parameter calibration result of the camera is improved through verifying the internal parameters of the camera, and then the accuracy of identifying objects during subsequent work of the robot is improved.
In the description of the present application, a description of the terms "one embodiment," "preferred," "example," "specific example," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the application, and a schematic representation of the terms described above in the present specification does not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. The connection modes in the description of the specification have obvious effects and practical effectiveness.
From the above description of the structure and principles, it should be understood by those skilled in the art that the present application is not limited to the above-described embodiments, but rather that modifications and substitutions using known techniques in the art on the basis of the present application fall within the scope of the present application, which is defined by the appended claims.

Claims (10)

1. The internal reference calibration method of the camera is characterized by comprising the following steps of:
s1: the robot acquires an image of a calibration plate of the calibration jig through a camera, and then identifies a calibration point from the image of the calibration plate;
s2: the robot calibrates the internal reference of the camera according to the position of the calibration point on the calibration plate and the position of the calibration point in the image;
s3: and detecting an internal reference calibration result of the camera by the robot, if the detection result is correct, taking the internal reference calibration result as the internal reference of the camera, and if the detection result is incorrect, calibrating the internal reference of the camera again by deleting the calibration plate and the calibration points of the image.
2. The method for calibrating internal parameters of a camera according to claim 1, wherein in step S1, the robot acquires an image with a plurality of calibration plates through the camera, comprising the steps of:
the robot moves to a calibration position of a calibration jig formed by a plurality of calibration plates;
the robot makes the camera vertically upwards, then obtains the image that has all calibration boards of calibration tool through the camera.
3. The method for calibrating internal parameters of a camera according to claim 2, wherein in step S1, the robot identifies a calibration point from an image of a calibration plate, comprising the steps of:
the robot detects a quadrilateral black area in the image of the calibration plate;
the robot connects the detected quadrilateral black areas in a clockwise direction;
the robot acquires an inner quadrangle of a black area of the quadrangle;
the robot uses four endpoints of the inner quadrangle as calibration points of the calibration plate through angular point detection;
the calibration plate is a checkerboard calibration plate, and four sides of the inner quadrangle are respectively connected with the black areas of the quadrangle.
4. The method for calibrating internal parameters of a camera according to claim 2, wherein in step S2, the robot calibrates the internal parameters of the camera according to the position of the calibration point on the calibration plate and the position of the calibration point in the image, comprising the steps of:
the robot obtains physical coordinates of a calibration point on a physical coordinate system of the calibration plate and pixel coordinates of the calibration point in the image on the image;
the robot projects the calibration points on the calibration plates into the images of the calibration plates according to the initial pose of each calibration plate relative to the center point of the robot and the initial internal reference of the camera to obtain projection coordinates of the calibration points of the calibration plates;
the robot calculates the Euclidean distance between the projection coordinates of the calibration point of the calibration plate and the pixel coordinates of the calibration point in the image corresponding to the calibration point according to the Euclidean distance formula;
and optimizing the internal parameters of the camera by the robot according to the acquired Euclidean distance through an iterative formula of a Gaussian Newton method to obtain the optimal internal parameters of the camera and the pose of the camera relative to each calibration plate.
5. The camera internal reference calibration method according to claim 4, wherein when the robot optimizes the camera internal reference by the iterative formula of the gauss newton method, and the minimum euclidean distance is obtained in the calculation process, the pose of each calibration plate corresponding to the minimum euclidean distance and the central point of the robot and the camera internal reference are used as the optimal camera internal reference and the pose of the camera relative to each calibration plate.
6. The method for calibrating internal parameters of a camera according to claim 4, wherein the robot obtains an initial pose of a calibration plate relative to a center point of the robot, comprising the steps of:
the robot passes through the corner point of the upper left corner of the calibration plate and makes a vertical line perpendicular to the calibration plate;
the robot takes an included angle between a vertical line vertical to the calibration plate and the advancing direction of the robot as an included angle between the calibration plate and the robot;
the robot pre-stores the distance between the center point of the robot and the corner point of the upper left corner of the calibration plate when the robot calibrates the calibration position of the jig;
and the robot combines according to the included angle between the calibration plate and the robot and the distance between the center point of the robot and the corner point of the upper left corner of the calibration plate to obtain the initial pose of the calibration plate relative to the center point of the robot.
7. The method for calibrating internal parameters of a camera according to claim 4, wherein the robot obtains physical coordinates of the calibration point on a physical coordinate system of the calibration plate, comprising the steps of:
the robot takes the corner point of the upper left corner of each calibration plate as an origin, and two sides of the calibration plate connected with the corner point of the upper left corner are respectively an X axis and a Y axis to construct a physical coordinate system;
and the robot acquires the coordinates of the calibration point on the physical coordinate system according to the position of the calibration point on the calibration plate.
8. The method for calibrating internal parameters of a camera according to claim 7, wherein in step S3, the robot detects the calibration result of the internal parameters of the camera, and the method comprises the following steps:
the robot classifies the calibration points in the image and determines the calibration plate to which the identified calibration points belong;
the robot converts the pixel coordinates of the identified calibration points belonging to the same calibration plate into physical coordinates of a physical coordinate system of the calibration plate through the camera internal parameters and the pose of the camera relative to the calibration plate, and obtains the physical coordinates of the calibration points of the image;
the robot acquires the Euclidean distance between the physical coordinates of the calibration points of the image and the physical coordinates of the calibration points of the calibration plate corresponding to the calibration points of the image, if the average value of the Euclidean distances of the set number is larger than a first set threshold value, the calibration of the calibration plate is judged to be wrong, otherwise, the calibration is correct;
the robot is used for fitting the calibration points of the same calibration plate with correct calibration into a plurality of calibration point straight lines, then comparing the vertical distance between two adjacent and parallel calibration point straight lines, if the vertical distance between any two calibration point straight lines is larger than a second set threshold value, judging that the calibration plate is in error calibration, otherwise, the calibration is correct;
the robot deletes the calibration plate with the wrong calibration and the identified calibration points belonging to the calibration plate, and then again calibrates the internal parameters of the camera.
9. The method for calibrating internal parameters of a camera according to claim 8, wherein in step S2, the robot classifies the identified calibration points and determines the calibration plate to which the identified calibration points belong, and the method comprises the following steps:
a1: the robot randomly selects the calibration points with the same number as the calibration plates as the centers of the clusters;
a2: the robot obtains the cluster distance between the calibration point and the center of each cluster, and then assigns the calibration point to the cluster with the minimum cluster distance;
a3: the robot obtains an average value of image coordinates of a calibration point of each cluster, and then takes the average value as the center of a new cluster;
a4: the robot repeatedly performs the steps A2 and A3 until the average value of the image coordinates of the calibration point of each cluster is not changed, and then the robot determines the calibration plate to which the calibration point of each cluster belongs according to the center of each cluster.
10. The method for calibrating the internal parameters of the camera according to claim 8, wherein if the robot judges that all the calibration plates are in calibration error, the robot rotates by a set angle, and then acquires the image of the calibration plate of the calibration jig through the camera again to calibrate the internal parameters of the camera.
CN202310830821.7A 2023-07-07 2023-07-07 Internal reference calibration method of camera Pending CN116912324A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310830821.7A CN116912324A (en) 2023-07-07 2023-07-07 Internal reference calibration method of camera

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310830821.7A CN116912324A (en) 2023-07-07 2023-07-07 Internal reference calibration method of camera

Publications (1)

Publication Number Publication Date
CN116912324A true CN116912324A (en) 2023-10-20

Family

ID=88361068

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310830821.7A Pending CN116912324A (en) 2023-07-07 2023-07-07 Internal reference calibration method of camera

Country Status (1)

Country Link
CN (1) CN116912324A (en)

Similar Documents

Publication Publication Date Title
CN108597009B (en) Method for detecting three-dimensional target based on direction angle information
CN109211198B (en) Intelligent target detection and measurement system and method based on trinocular vision
CN107977996B (en) Space target positioning method based on target calibration positioning model
CN110738273B (en) Image feature point matching method, device, equipment and storage medium
CN110827361B (en) Camera group calibration method and device based on global calibration frame
CN111815710B (en) Automatic calibration method for fish-eye camera
CN111123242B (en) Combined calibration method based on laser radar and camera and computer readable storage medium
CN112819903A (en) Camera and laser radar combined calibration method based on L-shaped calibration plate
CN112381847B (en) Pipeline end space pose measurement method and system
CN111522022B (en) Dynamic target detection method of robot based on laser radar
CN110597249B (en) Robot and recharging positioning method and device thereof
CN115774265B (en) Two-dimensional code and laser radar fusion positioning method and device for industrial robot
WO2024011764A1 (en) Calibration parameter determination method and apparatus, hybrid calibration board, device, and medium
CN112734844A (en) Monocular 6D pose estimation method based on octahedron
CN115201883A (en) Moving target video positioning and speed measuring system and method
CN111080640B (en) Hole detection method, device, equipment and medium
CN110838146A (en) Homonymy point matching method, system, device and medium for coplanar cross-ratio constraint
CN112050752B (en) Projector calibration method based on secondary projection
CN111524193B (en) Method and device for measuring two-dimensional size of object
CN116912324A (en) Internal reference calibration method of camera
CN116934867A (en) Camera calibration method
US7027637B2 (en) Adaptive threshold determination for ball grid array component modeling
CN112665528B (en) Correction method for laser scanning three-dimensional imaging
CN114963981A (en) Monocular vision-based cylindrical part butt joint non-contact measurement method
CN114998571A (en) Image processing and color detection method based on fixed-size marker

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination