ROI, region of interest), camera calibration

ROI

Machine Vision ------- SciSmart Image Positioning - ROI Correction Algorithm
Region of interest (ROI, region of interest), in machine vision and image processing, on the processed image with a box, circle, ellipse, not The area to be processed is outlined by means of regular polygons, which is called a region of interest, or ROI for short. In the field of image processing, a region of interest is an image region selected from an image, and this region is the focus of image analysis. Delineate the area for further processing, or use ROI to delineate the target you want to process, which can reduce processing time and improve accuracy.

In a specific vision application, when the position of the incoming workpiece is fixed, the constant ROI can cover the incoming workpiece. However, when there is a large fluctuation in the position of the incoming material, it is impossible to realize the visual application through a fixed ROI. At this time, we can position the product through rough positioning, generate ROI according to the positioning position, length, width, angle and other data, and use the ROI tool to meet the requirements of visual applications; or use the ROI correction tool to correct the fixed ROI through rough positioning data Perform affine transformation to follow the product position to meet the requirements of visual applications.

camera calibration

Reference: https://www.zhihu.com/question/36241631

What is camera calibration? The process of estimating camera parameters is called camera calibration. Through camera calibration, all the information (parameters or coefficients) of the camera can be mastered, so that the precise relationship between the 3D points in the real world and the 2D projections (pixels) of the image captured by the camera can be determined. In general, camera calibration means recovering the following two types of parameters: Intrinsic parameters of the camera/lens system. Such as: lens focal length, optical center and radial distortion coefficient and other parameters. Extrinsic parameters: This refers to the orientation of the camera relative to some world coordinate system (rotation matrix R and translation vector t). A geometric calibration is used to estimate the parameters of the lens, thereby eliminating the distortion of the image.

The calibration of the camera is to calculate the internal parameters and external parameters of the camera, so as to realize the accurate measurement of the image and the application of object tracking. The internal parameters of the camera include parameters such as the principal point position, focal length, and pixel width, and the external parameters include parameters such as the rotation and translation of the camera, which can be used to restore the three-dimensional coordinate information of the real world, and then realize the conversion between pixels and physical quantities.

Calibration steps:

Image acquisition: First, it is necessary to acquire a calibration image, which is generally calibrated using templates such as black and white checkerboards, laser planes or other geometric figures, so as to accurately measure the image. These patterns need to meet certain characteristic requirements, such as the number of corner points, symmetry, etc.

Feature extraction: feature extraction of images, generally using features such as edges, corners, spots, textures, etc., in order to calculate the internal and external parameters of the image. Since a large number of feature points need to be extracted during the calibration process, automatic feature extraction algorithms such as SIFT and SURF are usually used.

Parameter calculation: For the feature points of the image, calibration can be achieved by solving the internal and external parameters of the camera. The internal parameters include focal length, principal point position and pixel size, etc. It is necessary to convert the pixel coordinates of the image to the actual physical quantity, and solve it by polynomial equation or least square method. External parameters are generally calculated using a PnP algorithm.

Accuracy evaluation: After the calibration is completed, the results need to be evaluated. Generally, indicators such as reprojection error or sub-pixel accuracy are used to evaluate the calibration accuracy. If the required accuracy is met, the calibration results can be used for applications such as measurement and tracking.

In general, camera calibration is a very important part of computer vision technology, and it is the premise and basis for realizing functions such as image measurement and tracking. Although the calibration process is somewhat complex, it is an essential step for applications that require high-precision measurement and tracking

Guess you like

Origin blog.csdn.net/qq_15821487/article/details/131002416