Automatic focusing and distortion optimization method based on large-target-surface industrial lens
By setting a dynamic adjustment mechanism in large target industrial lenses and using convolutional neural networks to optimize lens parameters, the problem of limited imaging quality in traditional lenses in high-precision industrial applications is solved, and high-precision and low-distortion high-definition imaging effect is achieved.
Patent Information
- Application Number
- CN202411940091.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-26
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2044-12-26
AI Technical Summary
Traditional industrial lenses cannot meet the high-precision needs in complex industrial applications. Traditional focus technology lacks intelligence and adaptability, and cannot adjust the focal length, distortion and brightness distribution in real time, resulting in limited imaging quality.
By setting up a dynamic adjustment mechanism between the front focus group and the rear fixed lens group of the large target industrial lens, combining the convolutional neural network to build a spacing optimization prediction model, calculate the imaging quality index in real time and adjust the lens parameters dynamically, extract and analyze radial, tangential and comet distortion information, and automatically generate correction instructions to optimize lens spacing.
It realizes accurate adjustment of focus length, resolution and distortion, improves the imaging quality and accuracy of the lens, and is especially suitable for high-precision industrial applications of large target surfaces, which can significantly improve imaging clarity and stability.
Smart Images

Figure CN119620325A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of lens distortion optimization, and in particular to an automatic focusing and distortion optimization method based on a large-target-area industrial lens. Background Art
[0002] With the continuous development of industrial automation and high-precision detection technology, the demand for industrial lenses in various application scenarios is increasing, especially in the fields of machine vision, automated detection, object recognition, etc. Large-format industrial lenses, as an important high-precision optical component, have broad prospects for use in these applications.
[0003] Many traditional lenses rely on manual adjustment or crude autofocus technology, which cannot meet the high-precision requirements in complex industrial applications. Small changes in the spacing between optical components have a significant impact on focal length, resolution, and distortion, but traditional methods are often unable to adjust accurately, resulting in small changes in focal length and resolution not being corrected in time, thus affecting the final imaging effect. Most traditional optical lens adjustment technologies lack intelligence and adaptive capabilities, and cannot dynamically adjust lens parameters such as focal length, distortion, and brightness distribution based on real-time collected image data. Even if an autofocus mechanism is used, it is often impossible to automatically perform comprehensive quality optimization, resulting in limited imaging quality. Summary of the invention
[0004] In view of the deficiencies in the prior art, the present invention provides an automatic focusing and distortion optimization method based on a large-target-area industrial lens to solve the problems mentioned in the background technology.
[0005] To achieve the above objectives, the present invention is implemented through the following technical solutions: an automatic focusing and distortion optimization method based on a large-target industrial lens comprises the following steps:
[0006] S1. A dynamic adjustment mechanism is provided between the front focusing group A and the rear fixed lens group B of the lens. The front focusing group A is composed of a positive meniscus lens, a negative meniscus lens, a double cemented lens and a double convex positive lens in sequence. The rear fixed lens group B is composed of a negative meniscus lens. In the initial state, the distance between the front focusing group A and the rear fixed lens group B is set to a first initial distance L1.
[0007] S2, based on the first initial distance L1, collect the first imaging area image of the lens imaging area, and calculate and obtain the focal length F and effective resolution C after deep analysis by image analysis technology: effective , and establish optical performance data sets;
[0008] S3, based on the optical performance data set, using a convolutional neural network to build and train a spacing optimization prediction model, calculate the imaging quality index Q of the lens in real time, and preset a quality threshold Z, when the imaging quality index Q is lower than the quality threshold Z, generate a first correction instruction to correct the first initial spacing L1 to generate a second spacing L2;
[0009] S4, collecting the image of the second imaging area of the lens imaging area, and using image processing technology to extract the radial distortion information, tangential distortion information and comet distortion information of the second imaging area image, constructing an offset and identifying it, and after identifying the presence of radial distortion, tangential distortion or comet distortion, deeply calculating to obtain: comet distortion coefficient HJ, radial distortion coefficient The first tangential distortion coefficient on the x-axis and the second tangential distortion coefficient on the y-axis The overall distortion rate D is obtained by association, and a distortion risk threshold value X is preset. If the overall distortion rate D exceeds the distortion risk threshold value X, a second correction instruction is generated to correct the second distance L2 to generate a third distance L3;
[0010] S5. Collect the third imaging area image of the lens imaging area, and use image processing technology to extract the pixel features of the central area and the edge area, construct and evaluate the edge brightness attenuation coefficient E. If the edge brightness attenuation coefficient E is greater than 1, generate a third correction instruction to correct the third distance L3 to generate a fourth distance L4 to achieve a high-definition imaging effect with a large target surface and low distortion.
[0011] Preferably, S1 comprises:
[0012] S11, the front focusing group A is composed of the following lenses arranged in sequence along the direction of the incident light, including:
[0013] The first meniscus positive lens A1: used for preliminary collection and correction of light convergence performance;
[0014] A first meniscus negative lens A2 and a second meniscus negative lens A3 are used to optimize the divergence characteristics of light to control aberrations;
[0015] The second meniscus positive lens A4, the third meniscus positive lens A5 and the fourth meniscus positive lens A6 are respectively used to compensate for focus drift and improve imaging resolution;
[0016] The double concave negative lens A7 and the first double convex positive lens A8 are cemented together to form a double cemented lens, which is used to suppress complex chromatic aberration and reduce optical distortion;
[0017] A second biconvex positive lens A9 is used to further converge the light to ensure the imaging clarity of the image plane;
[0018] Among them, an aperture stop STOP is arranged between the second meniscus positive lens A4 and the third meniscus positive lens A5, and the aperture stop STOP plays a role in limiting the beam angle and optimizing light transmission in the optical design;
[0019] S12, the rear fixed lens group B includes a third meniscus negative lens A10, which is used to correct the focal length stability of the system and cooperate with the front focusing group A to reduce the image distortion;
[0020] S13, in the initial installation state of the lens, the initial distance between the front focusing group A and the rear fixed lens group B is determined to be the first initial distance L1 through a stepper motor or a piezoelectric driver in conjunction with a laser displacement sensor.
[0021] Preferably, S2 comprises:
[0022] The focal length F is obtained by using an optical focal length measuring instrument or a laser interferometer. The specific method is as follows:
[0023] S211. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam;
[0024] S212, collecting the position of the lens imaging point on the target surface, the measuring instrument automatically tracks the position of the focus point, and collects and obtains the following parameters, including:
[0025] Object distance O d : The distance from the object to the main surface of the lens, unit: mm;
[0026] Image distance I d : The distance from the imaging plane to the main surface of the lens, unit: mm;
[0027] Like high H i : The actual height of the imaged object, unit: mm;
[0028] Material height H o : The actual height of the object, unit: mm;
[0029] S213. In optics, the Gaussian imaging formula describes the relationship between an object and an image, especially when imaging with a lens. The expression is as follows:
[0030]
[0031] Where F is the focal length. The formula is based on the basic optical principle of the lens and explains the influence of the position of the object and the imaging plane on the focal length. The focal length F of the lens depends on the relative distance between the object and the imaging plane.
[0032] And take the reciprocal of both sides of the formula and calculate the focal length F using the following formula:
[0033]
[0034] Where, focal length F is the object distance O d and image distance I d The quotient of the product of and their sum;
[0035] S214, the imaging process is considered as the light of the object passing through the lens converges to the imaging plane, and the object distance is O d and image distance I d The ratio of determines the magnification M, and the object distance O is verified by the magnification M formula. d and image distance I d The relationship between:
[0036]
[0037] Preferably, S2 further includes:
[0038] Obtain effective resolution C by calculating with resolution test chart or image processing technology effective , the specific method is as follows:
[0039] S221. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam;
[0040] S222: Select a first test calibration object so that the first test calibration object is parallel to the lens imaging plane, and use a high-resolution image acquisition device to acquire an image of the first imaging area:
[0041] S223, using an image processing algorithm to extract the pixel size in the image of the first imaging area, and calculate the number of line pairs that can be resolved per millimeter P s , and in the case of magnification, the effective resolution C is calculated by the following formula effective :
[0042]
[0043] In the formula, C represents resolution, P s Indicates the number of line pairs that can be resolved per millimeter, W o is the actual object width, W s is the width of the sensor.
[0044] Preferably, S3 includes:
[0045] S31. Using a convolutional neural network, construct an initial model of the convolutional neural network, and train and test the initial model of the convolutional neural network with an optical performance data set, and use the trained initial model of the convolutional neural network as a spacing optimization prediction model, and use the intermediate layer output of the optical performance data set as a feature vector to identify feature information, and train and test the spacing optimization prediction model through the acquired feature information, and use the trained spacing optimization prediction model as data to run prediction;
[0046] S32. Extract focal length F and effective resolution C from the optical performance data set effective After dimensionless processing, the imaging quality index Q is calculated by the following correlation formula:
[0047] Q=F*α+C effective *β;
[0048] Where α and β represent the focal length F and effective resolution C respectively. effective The weight value of , 0<α<1, 0<β<1, and α+β=1;
[0049] S33, presetting a quality threshold Z, and comparing and evaluating the imaging quality index Q with the quality threshold Z to obtain a first evaluation result, including:
[0050] When the imaging quality index Q is less than the quality threshold Z, it indicates that the image quality is unqualified, and a first correction instruction is generated to adjust the first initial distance L1 between the front focusing group A and the rear fixed lens group B, and reduce the current first initial distance L1 by 3%-5% to form a second distance L2;
[0051] When the imaging quality index Q≥quality threshold Z, it indicates that the image quality is qualified, the first initial distance L1 is maintained and a first qualified label is generated on the industrial lens.
[0052] Preferably, S4 includes:
[0053] S41. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam;
[0054] S42, selecting a second test calibration object so that the second test calibration object is parallel to the lens imaging plane, and using a high-resolution image acquisition device to acquire an image of the second imaging area:
[0055] S43, using image processing technology to extract radial distortion information, tangential distortion information and comet distortion information of the second imaging area image, setting each pixel point (x ideal ,y ideal ) are the coordinates of the x-axis and y-axis in the ideal image, (x distorted ,y distorted) are the coordinates of the x-axis and y-axis in the actual image;
[0056] S44. By collecting the coordinate difference between the actual image and the ideal image, the offset and the comet distortion coefficient HJ are obtained by the following formula:
[0057] Δx distorted =x distorted -x ideal ;
[0058] Δy distorted =y distorted -y ideal ;
[0059]
[0060] In the formula, Δx distorted Indicates the offset in the x-axis direction, Δy distorted Indicates the offset in the y-axis direction; r indicates the distance from the center point of the edge aperture to the center of the image;
[0061] Preset a first radial distortion threshold value X1, a second tangential distortion threshold value X2 and a third comet distortion threshold value X3;
[0062] When Δx distorted or Δy distorted > the first radial distortion threshold X1, it indicates that radial distortion exists; when Δx distorted or Δy distorted ≤ the first radial distortion threshold X1, it means there is no radial distortion; when Δx distorted or Δy distorted > the second tangential distortion threshold X2, indicating that there is tangential distortion; when Δx distorted or Δy distorted When the comet distortion coefficient HJ is less than or equal to the second tangential distortion threshold X2, it indicates that there is no tangential distortion; when the comet distortion coefficient HJ is greater than or equal to the third comet distortion threshold X3, it indicates that there is comet distortion; when the comet distortion coefficient HJ is less than or equal to the third comet distortion threshold X3, it indicates that there is no comet distortion.
[0063] Preferably, S44 includes:
[0064] S441, when the radial distortion is identified, for the distance between each pixel and the center of the image, calculate the radial distance r in the actual image in the first imaging area image. distorted and the radial distance r in the ideal image ideal , the expression is:
[0065]
[0066] In the formula, r idealrepresents the radial distance of each pixel in the ideal image, r distorted Represents the radial distance of each pixel in the actual image;
[0067] S442. Calculate the radial distortion coefficient using the following radial distortion formula:
[0068]
[0069] Wherein, k1 represents the first-order radial distortion weight coefficient, which is used to make the maximum contribution to the total distortion; k2 represents the second-order radial distortion weight coefficient, which is used to correct the high-order influence; k3 represents the third-order radial distortion weight coefficient, which is used to make slight corrections to the extreme edge points; the values of k1, k2 and k3 are obtained through experimental fitting;
[0070] S443, when the tangential distortion is identified, the radial distance r in the actual image in the acquired area image is calculated. distorted and the radial distance r in the ideal image ideal , and the first tangential distortion coefficient on the x-axis is calculated by the following formula and the second tangential distortion coefficient on the y-axis
[0071]
[0072]
[0073] In the formula, p1 and p2 are weight coefficients, which are obtained by fitting experimental data or image calibration; is the square of the radial distance of each pixel from the image center;
[0074] S444. Extract the radial distortion coefficient calculated in S442-S443 The first tangential distortion coefficient on the x-axis and the second tangential distortion coefficient on the y-axis Combined with the comet distortion coefficient HJ obtained by S44 calculation, after dimensionless processing, the overall distortion rate D is calculated by the following formula:
[0075]
[0076] Wherein w1, w2 and w3 represent weights, 0<w1<1, 0<w2<1, 0<w3<1, and w1+w2+w3=1.
[0077] Preferably, S4 further includes:
[0078] S45, based on the overall distortion rate D calculated and obtained in S444, a distortion risk threshold X is preset, and the overall distortion rate D is compared with the distortion risk threshold X to obtain a second evaluation result, including:
[0079] When the overall distortion rate D>the distortion risk threshold X, it indicates that the distortion is abnormal, and a second correction instruction is generated, including: using a segmented fine-tuning method to increase the current second spacing L2 by 0.5% to 1%, and each adjustment does not exceed 0.5% to 1%, to form a third spacing L3, until the overall distortion rate D<the distortion risk threshold X;
[0080] When the overall distortion rate D ≤ the distortion risk threshold X, it means that the distortion is within the standard threshold range and no correction is required, and a second qualified label is generated on the industrial lens.
[0081] Preferably, S5 includes:
[0082] S51. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam;
[0083] S52: Select a third test calibration object so that the third test calibration object is parallel to the lens imaging plane, and use a high-resolution image acquisition device to acquire an image of the third imaging area:
[0084] S53: extract the pixel features of the central area and the pixel features of the edge area from the third imaging area image, and calculate the image center brightness L by the following formula center and image edge brightness L edge :
[0085]
[0086] Where N center Indicates the number of pixels in the central area, I center (x, y) is the brightness value of each pixel in the central area, N edge Indicates the number of pixels in the edge area; I edge (x,y) is the brightness value of each pixel in the edge region. (x,y)∈centerregion means that only the pixels in the "center region" are summed; (x,y)∈edgeregion means that only the pixels in the "edge region" are summed.
[0087] S54, based on the image center brightness L center and image edge brightness L edge , the edge brightness attenuation coefficient E is calculated by the following formula:
[0088]
[0089] S55, when the value of the edge brightness attenuation coefficient E is greater than 1, it indicates that the brightness of the edge of the image is lower than that of the center, and brightness attenuation occurs, and a third correction instruction is generated, including: using a segmented fine-tuning method to increase the current third spacing L3 by 0.05% to 0.1% to form a fourth spacing L4;
[0090] When the value of the edge brightness attenuation coefficient E is ≤1, it means that the image brightness distribution is uniform, no brightness attenuation occurs, no correction is required, and a third qualified label is generated on the industrial lens.
[0091] Preferably, when the industrial lens generates the first qualified label, the second qualified label and the third qualified label at the same time, it means that the lens has reached the predetermined qualified standards in multiple performance indicators. If any qualified label is missing, steps S1-S5 are repeated until the first qualified label, the second qualified label and the third qualified label are generated at the same time.
[0092] The present invention provides an automatic focusing and distortion optimization method based on a large-surface industrial lens. It has the following beneficial effects:
[0093] (1) The automatic focusing and distortion optimization method based on the large-target industrial lens. Traditional lenses cannot accurately adjust the focal length and resolution during the imaging process. The present invention can accurately adjust the distance between the front focusing group A and the rear fixed lens group B by setting a dynamic adjustment mechanism between the two groups of lenses, thereby optimizing the focal length, resolution and distortion. Through the gradual correction of each step S3-S5 (including focal length, distortion, brightness attenuation, etc.), the imaging quality of the lens is improved, especially in industrial applications with large target surfaces and high precision requirements, the imaging clarity and accuracy can be significantly improved.
[0094] (2) The present invention uses a convolutional neural network (CNN) model to construct and train a spacing optimization prediction model, which can calculate the imaging quality index Q of the lens in real time and dynamically adjust the focal length and spacing of the lens according to real-time data. Traditional methods usually lack this intelligent adaptive capability, and this feature of the present invention enables the lens to automatically adjust according to the real-time collected image data, and timely compensate for the impact of lens quality and manufacturing errors on lens performance, thereby ensuring that the best imaging effect can be achieved under various environmental conditions.
[0095] (3) The present invention extracts and analyzes radial distortion information, tangential distortion information and comet distortion information in the imaging area image, can accurately calculate the overall distortion rate D, and automatically generate correction instructions according to the preset distortion risk threshold X. Different from traditional image processing algorithms, the present invention can fundamentally reduce the generation of distortion by optimizing and adjusting the optical design, thereby achieving low-distortion high-definition imaging effects without relying on post-processing. This intelligent distortion optimization technology is particularly suitable for high-precision industrial applications, such as automated detection and object recognition.
[0096] (4) The calculation and correction of the edge brightness attenuation coefficient E in the present invention can effectively eliminate the edge brightness attenuation phenomenon. When it is detected that the edge brightness attenuation coefficient E is greater than 1, the system will automatically generate a correction instruction to further adjust the lens spacing to ensure a more uniform brightness distribution in the imaging area and improve the overall imaging effect of the lens. BRIEF DESCRIPTION OF THE DRAWINGS
[0097] Figure 1 This is a schematic diagram of the arrangement structure of the front focusing group A and the rear fixed lens group B of the large-target-area industrial lens of the present invention;
[0098] Figure 2 The figure is a schematic diagram of the steps of the automatic focusing and distortion optimization method based on a large-target-area industrial lens of the present invention. DETAILED DESCRIPTION
[0099] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0100] Example 1
[0101] See also Figure 1-2 The present invention provides an automatic focusing and distortion optimization method based on a large-target industrial lens, comprising the following steps:
[0102] S1. A dynamic adjustment mechanism is provided between the front focusing group A and the rear fixed lens group B of the lens. The front focusing group A is composed of a positive meniscus lens, a negative meniscus lens, a double cemented lens and a double convex positive lens in sequence. The rear fixed lens group B is composed of a negative meniscus lens. In the initial state, the distance between the front focusing group A and the rear fixed lens group B is set to a first initial distance L1.
[0103] S2, based on the first initial distance L1, collect the first imaging area image of the lens imaging area, and calculate and obtain the focal length F and effective resolution C after deep analysis by image analysis technology: effective, and establish optical performance data sets;
[0104] S3, based on the optical performance data set, using a convolutional neural network to build and train a spacing optimization prediction model, calculate the imaging quality index Q of the lens in real time, and preset a quality threshold Z, when the imaging quality index Q is lower than the quality threshold Z, generate a first correction instruction to correct the first initial spacing L1 to generate a second spacing L2;
[0105] S4, collecting the image of the second imaging area of the lens imaging area, and using image processing technology to extract the radial distortion information, tangential distortion information and comet distortion information of the second imaging area image, constructing an offset and identifying it, and after identifying the presence of radial distortion, tangential distortion or comet distortion, deeply calculating to obtain: comet distortion coefficient HJ, radial distortion coefficient The first tangential distortion coefficient on the x-axis and the second tangential distortion coefficient on the y-axis The overall distortion rate D is obtained by association, and a distortion risk threshold value X is preset. If the overall distortion rate D exceeds the distortion risk threshold value X, a second correction instruction is generated to correct the second distance L2 to generate a third distance L3;
[0106] S5. After the second correction instruction is executed, an image of the third imaging area of the lens imaging area is collected, and image processing technology is used to extract pixel features of the central area and pixel features of the edge area, and an edge brightness attenuation coefficient E is constructed and evaluated. If the edge brightness attenuation coefficient E is greater than 1, a third correction instruction is generated to correct the third distance L3 to generate a fourth distance L4 to achieve a high-definition imaging effect with a large target surface and low distortion.
[0107] In this embodiment, the traditional lens cannot accurately adjust the focal length and resolution during the imaging process, but the present invention can accurately adjust the distance between the two groups of lenses by setting a dynamic adjustment mechanism between the front focusing group A and the rear fixed lens group B, thereby optimizing the focal length, resolution and distortion. Through the gradual correction of each step S3-S5 (including focal length, distortion, brightness attenuation, etc.), the imaging quality of the lens is improved, especially in industrial applications with large target surface and high precision requirements, which can significantly improve the imaging clarity and accuracy.
[0108] The present invention uses a convolutional neural network (CNN) model to build and train a spacing optimization prediction model, which can calculate the imaging quality index Q of the lens in real time and dynamically adjust the focal length and spacing of the lens according to real-time data. Traditional methods usually lack this intelligent adaptive capability, and this feature of the present invention enables the lens to automatically adjust according to the real-time collected image data, and timely compensate for the impact of lens quality and manufacturing errors on lens performance, thereby ensuring that the best imaging effect can be achieved under various environmental conditions.
[0109] The present invention extracts and analyzes radial distortion information, tangential distortion information and comet distortion information in the imaging area image, can accurately calculate the overall distortion rate D, and automatically generate correction instructions according to the preset distortion risk threshold X. Different from traditional image processing algorithms, the present invention can fundamentally reduce the generation of distortion by optimizing and adjusting the optical design, thereby achieving low-distortion high-definition imaging effects without relying on post-processing. This intelligent distortion optimization technology is particularly suitable for high-precision industrial applications, such as automated detection and object recognition.
[0110] The calculation and correction of the edge brightness attenuation coefficient E in the present invention can effectively eliminate the edge brightness attenuation phenomenon. When it is detected that the edge brightness attenuation coefficient E is greater than 1, the system will automatically generate a correction instruction to further adjust the lens spacing to ensure that the brightness distribution in the imaging area is more uniform, thereby improving the overall imaging effect of the lens.
[0111] Example 2
[0112] This example is an explanation of Example 1. Figure 1 , specifically, S1 includes:
[0113] S11, the front focusing group A is composed of the following lenses arranged in sequence along the direction of the incident light, including:
[0114] The first meniscus positive lens A1: used for preliminary collection and correction of light convergence performance;
[0115] A first meniscus negative lens A2 and a second meniscus negative lens A3 are used to optimize the divergence characteristics of light to control aberrations;
[0116] The second meniscus positive lens A4, the third meniscus positive lens A5 and the fourth meniscus positive lens A6 are respectively used to compensate for focus drift and improve imaging resolution;
[0117] The double concave negative lens A7 and the first double convex positive lens A8 are cemented together to form a double cemented lens, which is used to suppress complex chromatic aberration and reduce optical distortion;
[0118] A second biconvex positive lens A9 is used to further converge the light to ensure the imaging clarity of the image plane;
[0119] Among them, an aperture stop STOP is arranged between the second meniscus positive lens A4 and the third meniscus positive lens A5, and the aperture stop STOP plays a role in limiting the beam angle and optimizing light transmission in the optical design;
[0120] S12, the rear fixed lens group B includes a third meniscus negative lens A10, which is used to correct the focal length stability of the system and cooperate with the front focusing group A to reduce the image distortion;
[0121] S13, in the initial installation state of the lens, the initial distance between the front focusing group A and the rear fixed lens group B is determined to be the first initial distance L1 through a stepper motor or a piezoelectric driver in conjunction with a laser displacement sensor.
[0122] In this embodiment, when the lens is initially installed, a stepper motor or a piezoelectric driver is used to adjust the distance between the front focusing group A and the rear fixed lens group B. This mechanism can be fine-tuned as needed to achieve more precise focal length adjustment. Combined with a laser displacement sensor, the distance can be measured and accurately adjusted in real time to keep the focal length and resolution of the lens at the optimal state. The precise coordination between the front focusing group A and the rear fixed lens group B ensures the stability of the focal length and avoids interference and instability factors within the system during the focusing process. The third meniscus negative lens (A10) in the rear fixed lens group B is used to correct the focal length stability of the system and cooperates with the adjustment action of the front focusing group A to ensure that the imaging quality of the system will not be affected during long-term use.
[0123] Example 3
[0124] This example is an explanation of Example 1. Figure 1 , specifically, S2 includes:
[0125] The focal length F is obtained by using an optical focal length measuring instrument or a laser interferometer. The specific method is as follows:
[0126] S211. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam, so as to minimize the error in the focal length measurement process. This step ensures the symmetry of the optical axis during the entire measurement process and avoids measurement errors caused by tilted or misaligned lenses.
[0127] S212, collecting the position of the lens imaging point on the target surface, the measuring instrument automatically tracks the position of the focus point, and collects and obtains the following parameters, including:
[0128] Object distance O d : The distance from the object to the main surface of the lens, unit: mm;
[0129] Image distance I d : The distance from the imaging plane to the main surface of the lens, unit: mm;
[0130] Like high H i : The actual height of the imaged object, unit: mm;
[0131] Material height H o: The actual height of the object, in millimeters (mm); by automatically tracking the position of the focus point, automatically collect parameters such as object distance, image distance, object height, and image height. These parameters can help accurately calculate the focal length and reduce errors in human operation, thereby improving measurement accuracy and efficiency.
[0132] S213. In optics, the Gaussian imaging formula describes the relationship between an object and an image, especially when imaging with a lens. The expression is as follows:
[0133]
[0134] Where F is the focal length. The formula is based on the basic optical principle of the lens and explains the influence of the position of the object and the imaging plane on the focal length. The focal length F of the lens depends on the relative distance between the object and the imaging plane.
[0135] And take the reciprocal of both sides of the formula and calculate the focal length F using the following formula:
[0136]
[0137] Where, focal length F is the object distance O d and image distance I d The quotient of the product of and their sum;
[0138] S214, the imaging process is considered as the light of the object passing through the lens converges to the imaging plane, and the object distance is O d and image distance I d The ratio of determines the magnification M, and the object distance O is verified by the magnification M formula. d and image distance I d The relationship between:
[0139]
[0140] Obtain effective resolution C by calculating with resolution test chart or image processing technology effective , the specific method is as follows: The magnification M is used to verify the relationship between the object distance and the image distance, which helps to understand the working characteristics of the lens under different imaging conditions. The actual imaging quality of the lens can be further verified through resolution testing.
[0141] S221. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam;
[0142] S222: Select a first test calibration object so that the first test calibration object is parallel to the lens imaging plane, and use a high-resolution image acquisition device to acquire an image of the first imaging area:
[0143] S223, using an image processing algorithm to extract the pixel size in the image of the first imaging area, and calculate the number of line pairs that can be resolved per millimeter P s , and in the case of magnification, the effective resolution C is calculated by the following formula effective :
[0144]
[0145] In the formula, C represents resolution, P s Indicates the number of line pairs that can be resolved per millimeter, W o is the actual object width, W s is the sensor width. The sensor width refers to the physical size of the camera image sensor (usually in millimeters). This is a key parameter because the resolution calculation is based on the actual physical size of the sensor. In this formula, the sensor width refers to the actual physical width of the sensor used for imaging. This parameter directly affects the number of line pairs that can be resolved per millimeter, which in turn affects the final effective resolution.
[0146] Example 4
[0147] This example is explained in Example 3. Figure 1 Specifically, S3 includes:
[0148] S31. Use a convolutional neural network to construct an initial model of the convolutional neural network, and use the optical performance data set to train and test the initial model of the convolutional neural network, and use the trained initial model of the convolutional neural network as a spacing optimization prediction model. At the same time, use the intermediate layer output of the optical performance data set as a feature vector to identify feature information, and use the acquired feature information to train and test the spacing optimization prediction model, and use the trained spacing optimization prediction model as data to run predictions. Through these feature vectors, the convolutional neural network can identify key image feature information, such as focal length changes, resolution fluctuations and other factors that affect imaging quality.
[0149] S32. Extract focal length F and effective resolution C from the optical performance data set effective After dimensionless processing, the imaging quality index Q is calculated by the following correlation formula:
[0150] Q=F*α+C effective *β;
[0151] Where α and β represent the focal length F and effective resolution C respectively. effective The weight value of , 0<α<1, 0<β<1, and α+β=1;
[0152] S33, presetting a quality threshold Z, and comparing and evaluating the imaging quality index Q with the quality threshold Z to obtain a first evaluation result, including:
[0153] When the imaging quality index Q is less than the quality threshold Z, it indicates that the image quality is unqualified, and a first correction instruction is generated to adjust the first initial distance L1 between the front focusing group A and the rear fixed lens group B, and reduce the current first initial distance L1 by 3%-5% to form a second distance L2;
[0154] When the imaging quality index Q≥quality threshold Z, it indicates that the image quality is qualified, the first initial distance L1 is maintained and a first qualified label is generated on the industrial lens.
[0155] In this embodiment, the process greatly simplifies the lens adjustment process by automatically evaluating the imaging quality index Q and generating the first correction instruction. Without manual intervention, the lens parameters can be automatically optimized according to the imaging quality, thereby improving the imaging accuracy and stability. Through continuous imaging quality evaluation and optimization instruction generation, the system can adjust the lens spacing in real time to ensure that the lens is always in the best working state.
[0156] Example 5
[0157] This example is an explanation of Example 1. Figure 1 , specifically, S4 includes:
[0158] S41. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam; by using a high-precision rotating table, more precise angle adjustment can be achieved, reducing distortion errors caused by inaccurate lens position.
[0159] S42, selecting a second test calibration object so that the second test calibration object is parallel to the lens imaging plane, and using a high-resolution image acquisition device to acquire an image of the second imaging area:
[0160] S43, using image processing technology to extract radial distortion information, tangential distortion information and comet distortion information of the second imaging area image, setting each pixel point (x ideal ,y ideal ) are the coordinates of the x-axis and y-axis in the ideal image, (x distorted ,y distorted ) are the coordinates of the x-axis and y-axis in the actual image;
[0161] S44. By collecting the coordinate difference between the actual image and the ideal image, the offset and the comet distortion coefficient HJ are obtained by the following formula:
[0162] Δx distorted =x distorted-x ideal ;
[0163] Δy distorted =y distorted -y ideal ;
[0164]
[0165] In the formula, Δx distorted Indicates the offset in the x-axis direction, Δy distorted Indicates the offset in the y-axis direction; r indicates the distance from the center point of the edge aperture to the center of the image;
[0166] Preset a first radial distortion threshold value X1, a second tangential distortion threshold value X2 and a third comet distortion threshold value X3;
[0167] When Δx distorted or Δy distorted > the first radial distortion threshold X1, it indicates that radial distortion exists; when Δx distorted or Δy distorted ≤ the first radial distortion threshold X1, it means there is no radial distortion; when Δx distorted or Δy distorted > the second tangential distortion threshold X2, indicating that there is tangential distortion; when Δx distorted or Δy distorted When HJ is less than or equal to the second tangential distortion threshold value X2, it indicates that there is no tangential distortion; when the comet distortion coefficient HJ is greater than or equal to the third comet distortion threshold value X3, it indicates that there is comet distortion; when the comet distortion coefficient HJ is less than or equal to the third comet distortion threshold value X3, it indicates that there is no comet distortion. In this stage, image processing technology is used to accurately identify different types of distortion (radial, tangential and comet distortion), making the analysis of distortion more comprehensive.
[0168] 44 include:
[0169] S441, when the radial distortion is identified, for the distance between each pixel and the center of the image, calculate the radial distance r in the actual image in the first imaging area image. distorted and the radial distance r in the ideal image ideal , the expression is:
[0170]
[0171] In the formula, r ideal represents the radial distance of each pixel in the ideal image, r distorted Represents the radial distance of each pixel in the actual image;
[0172] S442. Calculate the radial distortion coefficient using the following radial distortion formula:
[0173]
[0174] Wherein, k1 represents the first-order radial distortion weight coefficient, which is used to make the maximum contribution to the total distortion; k2 represents the second-order radial distortion weight coefficient, which is used to correct the high-order influence; k3 represents the third-order radial distortion weight coefficient, which is used to make slight corrections to the extreme edge points; the values of k1, k2 and k3 are obtained through experimental fitting;
[0175] S443, when the tangential distortion is identified, the radial distance r in the actual image in the acquired area image is calculated. distorted and the radial distance r in the ideal image ideal , and the first tangential distortion coefficient on the x-axis is calculated by the following formula and the second tangential distortion coefficient on the y-axis
[0176]
[0177]
[0178] In the formula, p1 and p2 are weight coefficients, which are obtained by fitting experimental data or image calibration; is the square of the radial distance of each pixel from the image center;
[0179] S444. Extract the radial distortion coefficient calculated in S442-S443 The first tangential distortion coefficient on the x-axis and the second tangential distortion coefficient on the y-axis Combined with the comet distortion coefficient HJ obtained by S44 calculation, after dimensionless processing, the overall distortion rate D is calculated by the following formula:
[0180]
[0181] Wherein w1, w2 and w3 represent weights, 0<w1<1, 0<w2<1, 0<w3<1, and w1+w2+w3=1.
[0182] S45, based on the overall distortion rate D calculated and obtained in S444, a distortion risk threshold X is preset, and the overall distortion rate D is compared with the distortion risk threshold X to obtain a second evaluation result, including:
[0183] When the overall distortion rate D>the distortion risk threshold X, it indicates that the distortion is abnormal, and a second correction instruction is generated, including: using a segmented fine-tuning method to increase the current second spacing L2 by 0.5% to 1%, and each adjustment does not exceed 0.5% to 1%, to form a third spacing L3, until the overall distortion rate D<the distortion risk threshold X;
[0184] When the overall distortion rate D ≤ the distortion risk threshold X, it means that the distortion is within the standard threshold range and no correction is required, and a second qualified label is generated on the industrial lens.
[0185] In this embodiment, the lens distortion is comprehensively analyzed from multiple dimensions (radial, tangential, comet distortion), which can accurately identify different types of distortion and provide accurate data for subsequent optimization and adjustment. The first tangential distortion coefficient on the x-axis and the second tangential distortion coefficient on the y-axis Combined with the calculation of the comet distortion coefficient HJ obtained by S44 calculation, various distortion conditions of the lens (radial, tangential, comet distortion) can be quantified, providing a scientific basis for correction.
[0186] The overall distortion rate D is calculated and compared with the preset distortion risk threshold X to obtain the second evaluation result. If the overall distortion rate D exceeds the distortion risk threshold X, the system will generate a correction instruction to adjust the lens spacing by segmented fine-tuning until the overall distortion rate drops below the threshold. The generated second correction instruction uses segmented fine-tuning to gradually optimize the lens parameters by 0.5% to 1% each time, making the adjustment process more precise and stable.
[0187] Example 6
[0188] This example is explained in Example 5. Figure 1 Specifically, S5 includes:
[0189] S51. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam;
[0190] S52: Select a third test calibration object so that the third test calibration object is parallel to the lens imaging plane, and use a high-resolution image acquisition device to acquire an image of the third imaging area:
[0191] S53: extract the pixel features of the central area and the pixel features of the edge area from the third imaging area image, and calculate the image center brightness L by the following formula center and image edge brightness L edge :
[0192]
[0193] Where N center Indicates the number of pixels in the central area, I center (x, y) is the brightness value of each pixel in the central area, N edge Indicates the number of pixels in the edge area; I edge (x,y) is the brightness value of each pixel in the edge region. (x,y)∈centerregion means that only the pixels in the "center region" are summed; (x,y)∈edgeregion means that only the pixels in the "edge region" are summed.
[0194] S54, based on the image center brightness L center and image edge brightness L edge , the edge brightness attenuation coefficient E is calculated by the following formula:
[0195]
[0196] S55, when the value of the edge brightness attenuation coefficient E is greater than 1, it indicates that the brightness of the edge of the image is lower than that of the center, and brightness attenuation occurs, and a third correction instruction is generated, including: using a segmented fine-tuning method to increase the current third spacing L3 by 0.05% to 0.1% to form a fourth spacing L4; until the value of the edge brightness attenuation coefficient E is less than 1 or equal to 1;
[0197] When the value of the edge brightness attenuation coefficient E is ≤1, it means that the image brightness distribution is uniform, no brightness attenuation occurs, no correction is required, and a third qualified label is generated on the industrial lens.
[0198] In this embodiment, by calculating the edge brightness attenuation coefficient E, the difference between the image edge brightness and the center brightness can be quantified, revealing the degree of image brightness attenuation. The edge brightness attenuation coefficient E provides a standard for subsequent correction, ensuring that the image brightness attenuation can be scientifically and reasonably identified. Through the segmented fine-tuning method, the lens parameters can be finely adjusted to improve the brightness uniformity of the image and ensure that the image quality meets the standard requirements. The segmented fine-tuning method is used to adjust the lens spacing to avoid over-correction and improve the stability and accuracy of the correction process.
[0199] Example 7
[0200] This example is an explanation of Example 1. Figure 1 Specifically, when the industrial lens generates the first qualified label, the second qualified label and the third qualified label at the same time, it means that the lens has reached the predetermined qualified standards in multiple performance indicators. If any qualified label is missing, steps S1-S5 are repeated until the first qualified label, the second qualified label and the third qualified label are generated at the same time.
[0201] Here is a labeled diagram of the calibration steps and results:
[0202]
[0203]
[0204] In this embodiment, this process ensures that all potential problems (such as focal length, distortion, brightness distribution, etc.) are detected and corrected one by one, thereby avoiding the impact that may be caused by a certain performance indicator being unqualified. The final lens performance is comprehensively optimized and suitable for a wider range of application scenarios. If any qualified label is missing, the system will automatically trigger steps S1-S5 for recalibration. This feedback mechanism can automatically identify and correct unqualified items, and ensure that each performance indicator is within the qualified range by gradually optimizing and adjusting the lens parameters, avoiding human intervention and reducing human errors. By repeating the correction steps, it is possible to fine-tune the focal length, resolution, distortion, brightness attenuation, etc., so that the various performance of the lens gradually reaches the optimal state. Each correction continuously approaches the ideal lens performance through scientific methods, and ultimately achieves precise optical effects.
[0205] The threshold is set to facilitate comparison. The size of the threshold depends on the amount of sample data and the number of bases set by technicians in this field for each group of sample data; as long as it does not affect the proportional relationship between the parameter and the quantized value.
[0206] The above formulas are obtained by collecting a large amount of data for software simulation and selecting a formula that is close to the actual value. The coefficients in the formula are set by technical personnel in this field according to actual conditions. The above is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited to this. Any technical personnel familiar with the technical field within the technical scope disclosed by the present invention, according to the technical solution and inventive concept of the present invention, make equivalent replacement or change, which should be covered within the protection scope of the present invention.
Claims
1. The automatic focusing and distortion optimization method based on large-surface industrial lens is characterized by: The following steps are involved: S1. A dynamic adjustment mechanism is provided between the front focusing group A and the rear fixed lens group B of the lens. The front focusing group A is composed of a positive meniscus lens, a negative meniscus lens, a double cemented lens and a double convex positive lens in sequence. The rear fixed lens group B is composed of a negative meniscus lens. In the initial state, the distance between the front focusing group A and the rear fixed lens group B is set to a first initial distance L1. S2, based on the first initial distance L1, collect the first imaging area image of the lens imaging area, and calculate and obtain the focal length F and effective resolution C after deep analysis by image analysis technology: effective , and establish optical performance data sets; S3, based on the optical performance data set, using a convolutional neural network to build and train a spacing optimization prediction model, calculate the imaging quality index Q of the lens in real time, and preset a quality threshold Z, when the imaging quality index Q is lower than the quality threshold Z, generate a first correction instruction to correct the first initial spacing L1 to generate a second spacing L2; S4, collecting the image of the second imaging area of the lens imaging area, and using image processing technology to extract the radial distortion information, tangential distortion information and comet distortion information of the second imaging area image, constructing an offset and identifying it, and after identifying the presence of radial distortion, tangential distortion or comet distortion, deeply calculating to obtain: comet distortion coefficient HJ, radial distortion coefficient The first tangential distortion coefficient on the x-axis and the second tangential distortion coefficient on the y-axis The overall distortion rate D is obtained by association, and a distortion risk threshold value X is preset. If the overall distortion rate D exceeds the distortion risk threshold value X, a second correction instruction is generated to correct the second distance L2 to generate a third distance L3; S5. Collect the third imaging area image of the lens imaging area, and use image processing technology to extract the pixel features of the central area and the edge area, construct and evaluate the edge brightness attenuation coefficient E. If the edge brightness attenuation coefficient E is greater than 1, generate a third correction instruction to correct the third distance L3 to generate a fourth distance L4 to achieve a high-definition imaging effect with a large target surface and low distortion.
2. The automatic focusing and distortion optimization method based on a large target surface industrial lens according to claim 1, characterized in that: S1 includes: S11, the front focusing group A is composed of the following lenses arranged in sequence along the direction of the incident light, including: The first meniscus positive lens A1: used for preliminary collection and correction of light convergence performance; A first meniscus negative lens A2 and a second meniscus negative lens A3 are used to optimize the divergence characteristics of light to control aberrations; The second meniscus positive lens A4, the third meniscus positive lens A5 and the fourth meniscus positive lens A6 are respectively used to compensate for focus drift and improve imaging resolution; The double concave negative lens A7 and the first double convex positive lens A8 are cemented together to form a double cemented lens, which is used to suppress complex chromatic aberration and reduce optical distortion; A second biconvex positive lens A9 is used to further converge the light to ensure the imaging clarity of the image plane; Among them, an aperture stop STOP is arranged between the second meniscus positive lens A4 and the third meniscus positive lens A5, and the aperture stop STOP plays a role in limiting the beam angle and optimizing light transmission in the optical design; S12, the rear fixed lens group B includes a third meniscus negative lens A10, which is used to correct the focal length stability of the system and cooperate with the front focusing group A to reduce the image distortion; S13, in the initial installation state of the lens, the initial distance between the front focusing group A and the rear fixed lens group B is determined to be the first initial distance L1 through a stepper motor or a piezoelectric driver in conjunction with a laser displacement sensor.
3. The automatic focusing and distortion optimization method based on a large-target industrial lens according to claim 1, characterized in that S2 include: The focal length F is obtained by using an optical focal length measuring instrument or a laser interferometer. The specific method is as follows: S211. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam; S212, collecting the position of the lens imaging point on the target surface, the measuring instrument automatically tracks the position of the focus point, and collects and obtains the following parameters, including: Object distance O d : The distance from the object to the main surface of the lens, unit: mm; Image distance I d : The distance from the imaging plane to the main surface of the lens, unit: mm; Like high H i : The actual height of the imaged object, unit: mm; Material height H o : The actual height of the object, unit: mm; S213. In optics, the Gaussian imaging formula describes the relationship between an object and an image, especially when imaging with a lens. The expression is as follows: Where F is the focal length. The formula is based on the basic optical principle of the lens and explains the influence of the position of the object and the imaging plane on the focal length. The focal length F of the lens depends on the relative distance between the object and the imaging plane. And take the reciprocal of both sides of the formula and calculate the focal length F using the following formula: Where, focal length F is the object distance O d and image distance I d The quotient of the product of and their sum; S214, the imaging process is considered as the light of the object passing through the lens converges to the imaging plane, and the object distance is O d and image distance I d The ratio of determines the magnification M, and the object distance O is verified by the magnification M formula. d and image distance I d The relationship between:
4. The automatic focusing and distortion optimization method based on a large target surface industrial lens according to claim 3 is characterized in that: S2 also includes: Obtain effective resolution C by calculating with resolution test chart or image processing technology effective , the specific method is as follows: S221. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam; S222: Select a first test calibration object so that the first test calibration object is parallel to the lens imaging plane, and use a high-resolution image acquisition device to acquire an image of the first imaging area: S223, using an image processing algorithm to extract the pixel size in the image of the first imaging area, and calculate the number of line pairs that can be resolved per millimeter P s , and in the case of magnification, the effective resolution C is calculated by the following formula effective : In the formula, C represents resolution, P s Indicates the number of line pairs that can be resolved per millimeter, W o is the actual object width, W s is the width of the sensor.
5. The automatic focusing and distortion optimization method based on a large-target-area industrial lens according to claim 4, characterized in that S3 include: S31. Using a convolutional neural network, construct an initial model of the convolutional neural network, and train and test the initial model of the convolutional neural network with an optical performance data set, and use the trained initial model of the convolutional neural network as a spacing optimization prediction model, and use the intermediate layer output of the optical performance data set as a feature vector to identify feature information, and train and test the spacing optimization prediction model through the acquired feature information, and use the trained spacing optimization prediction model as data to run prediction; S32. Extract focal length F and effective resolution C from the optical performance data set effective After dimensionless processing, the imaging quality index Q is calculated by the following correlation formula: Q=F*α+C effective *b; Where α and β represent the focal length F and resolution C respectively. effective The weight value of , 0<α<1, 0<β<1, and α+β=1; S33, presetting a quality threshold Z, and comparing and evaluating the imaging quality index Q with the quality threshold Z to obtain a first evaluation result, including: When the imaging quality index Q is less than the quality threshold Z, it indicates that the image quality is unqualified, and a first correction instruction is generated to adjust the first initial distance L1 between the front focusing group A and the rear fixed lens group B, and reduce the current first initial distance L1 by 3%-5% to form a second distance L2; When the imaging quality index Q≥quality threshold Z, it indicates that the image quality is qualified, the first initial distance L1 is maintained and a first qualified label is generated on the industrial lens.
6. The automatic focusing and distortion optimization method based on a large-target-area industrial lens according to claim 1, characterized in that S4 include: S41. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam; S42, selecting a second test calibration object so that the second test calibration object is parallel to the lens imaging plane, and using a high-resolution image acquisition device to acquire an image of the second imaging area: S43, using image processing technology to extract radial distortion information, tangential distortion information and comet distortion information of the second imaging area image, setting each pixel point (x ideal ,y ideal ) are the coordinates of the x-axis and y-axis in the ideal image, (x distorted ,y distorted ) are the coordinates of the x-axis and y-axis in the actual image; S44. By collecting the coordinate difference between the actual image and the ideal image, the offset and the comet distortion coefficient HJ are obtained by the following formula: Δx distorted =x distorted -x ideal ; Δy distorted =y distorted -y ideal ; In the formula, Δx distorted Indicates the offset in the x-axis direction, Δy distorted Indicates the offset in the y-axis direction; r indicates the distance from the center point of the edge aperture to the center of the image; Preset a first radial distortion threshold value X1, a second tangential distortion threshold value X2 and a third comet distortion threshold value X3; When Δx distorted or Δy distorted > the first radial distortion threshold X1, it indicates that radial distortion exists; when Δx distorted or Δy distorted ≤ the first radial distortion threshold X1, it means there is no radial distortion; when Δx distorted or Δy distorted > the second tangential distortion threshold X2, indicating that there is tangential distortion; when Δx distorted or Δy distorted When the comet distortion coefficient HJ is less than or equal to the second tangential distortion threshold X2, it indicates that there is no tangential distortion; when the comet distortion coefficient HJ is greater than or equal to the third comet distortion threshold X3, it indicates that there is comet distortion; when the comet distortion coefficient HJ is less than or equal to the third comet distortion threshold X3, it indicates that there is no comet distortion.
7. The automatic focusing and distortion optimization method based on a large-target-area industrial lens according to claim 6, characterized in that: S44 includes: S441, when the radial distortion is identified, for the distance between each pixel and the center of the image, calculate the radial distance r in the actual image in the first imaging area image. distorted and the radial distance r in the ideal image ideal , the expression is: In the formula, r ideal represents the radial distance of each pixel in the ideal image, r distorted Represents the radial distance of each pixel in the actual image; S442. Calculate the radial distortion coefficient using the following radial distortion formula: Wherein, k1 represents the first-order radial distortion weight coefficient, which is used to make the maximum contribution to the total distortion; k2 represents the second-order radial distortion weight coefficient, which is used to correct the high-order influence; k3 represents the third-order radial distortion weight coefficient, which is used to make slight corrections to the extreme edge points; the values of k1, k2 and k3 are obtained through experimental fitting; S443, when the tangential distortion is identified, the radial distance r in the actual image in the acquired area image is calculated. distorted and the radial distance r in the ideal image ideal , and the first tangential distortion coefficient on the x-axis is calculated by the following formula and the second tangential distortion coefficient on the y-axis In the formula, p1 and p2 are weight coefficients, which are obtained by fitting experimental data or image calibration; is the square of the radial distance of each pixel from the image center; S444. Extract the radial distortion coefficient calculated in S442-S443 The first tangential distortion coefficient on the x-axis and the second tangential distortion coefficient on the y-axis Combined with the comet distortion coefficient HJ obtained by S44 calculation, after dimensionless processing, the overall distortion rate D is calculated by the following formula: Wherein w1, w2 and w3 represent weights, 0<w1<1, 0<w2<1, 0<w3<1, and w1+w2+w3=1.
8. The automatic focusing and distortion optimization method based on a large-target-area industrial lens according to claim 7, characterized in that: S4 also includes: S45, based on the overall distortion rate D calculated and obtained in S444, a distortion risk threshold X is preset, and the overall distortion rate D is compared with the distortion risk threshold X to obtain a second evaluation result, including: When the overall distortion rate D>the distortion risk threshold X, it indicates that the distortion is abnormal, and a second correction instruction is generated, including: using a segmented fine-tuning method to increase the current second spacing L2 by 0.5% to 1%, and each adjustment does not exceed 0.5% to 1%, to form a third spacing L3, until the overall distortion rate D<the distortion risk threshold X; When the overall distortion rate D ≤ the distortion risk threshold X, it means that the distortion is within the standard threshold range and no correction is required, and a second qualified label is generated on the industrial lens.
9. The automatic focusing and distortion optimization method based on a large-target industrial lens according to claim 1, characterized in that S5 include: S51. Fix the industrial lens on a high-precision rotating table to ensure that the optical axis is aligned with the measuring instrument beam; S52: Select a third test calibration object so that the third test calibration object is parallel to the lens imaging plane, and use a high-resolution image acquisition device to acquire an image of the third imaging area: S53: extract the pixel features of the central area and the pixel features of the edge area from the third imaging area image, and calculate the image center brightness L by the following formula center and image edge brightness L edge : Where N center Indicates the number of pixels in the central area, I center (x, y) is the brightness value of each pixel in the central area, N edge Indicates the number of pixels in the edge area; I edge (x,y) is the brightness value of each pixel in the edge region. (x,y)∈centerregion means that only the pixels in the "center region" are summed; (x,y)∈edgeregion means that only the pixels in the "edge region" are summed. S54, based on the image center brightness L center and image edge brightness L edge , the edge brightness attenuation coefficient E is calculated by the following formula: S55, when the value of the edge brightness attenuation coefficient E is greater than 1, it indicates that the brightness of the edge of the image is lower than that of the center, and brightness attenuation occurs, and a third correction instruction is generated, including: using a segmented fine-tuning method to increase the current third spacing L3 by 0.05% to 0.1% to form a fourth spacing L4; When the value of the edge brightness attenuation coefficient E is ≤1, it means that the image brightness distribution is uniform, no brightness attenuation occurs, no correction is required, and a third qualified label is generated on the industrial lens.
10. The automatic focusing and distortion optimization method based on a large-target-area industrial lens according to claim 9, characterized in that: When the industrial lens generates the first qualified label, the second qualified label and the third qualified label at the same time, it means that the lens has reached the predetermined qualified standards in multiple performance indicators. If any qualified label is missing, steps S1-S5 are repeated until the first qualified label, the second qualified label and the third qualified label are generated at the same time.
Citation Information
Patent Citations
Image space telecentric lens for imaging spectrometer and imaging spectrometer
CN119087643A
Image capturing lens and image capturing device
JP2017003677A
Observation Optical System, Observation Imaging Device, Observation Imaging System, Image Forming Lens System, and Method of Adjusting Observation Optical System
US20190339501A1
Cited By
Foam lightweight concrete surface pore diameter and volume detection method
CN121230635A