Multi-camera correction method and system and medium

By controlling the sampling conditions and adjusting the light source exposure parameters, and calculating the correction coefficient and noise correction coefficient, the problem of inconsistent responsivity and noise in multi-camera systems is solved, thereby improving image quality and system reliability.

CN121982115APending Publication Date: 2026-05-05HEFEI I TEK OPTOELECTRONICS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
HEFEI I TEK OPTOELECTRONICS CO LTD
Filing Date
2026-01-13
Publication Date
2026-05-05

AI Technical Summary

Technical Problem

Existing technologies struggle to achieve consistent responsivity and noise correction in multi-camera systems, resulting in poor comparability and consistency of image data. This affects image stitching, comparative analysis, and measurement judgment, and the additional correction process increases noise.

Method used

By controlling sampling conditions, analyzing the system gain of each camera, calculating correction coefficients and noise correction coefficients, and combining adjustments to light source and exposure parameters, consistent adjustment of the responsivity and noise of each camera can be achieved.

Benefits of technology

It achieves consistency in responsivity and noise in multi-camera systems, improves the comparability and consistency of image quality, reduces noise levels, and enhances the overall reliability of multi-camera systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121982115A_ABST
    Figure CN121982115A_ABST
Patent Text Reader

Abstract

The invention discloses a multi-camera correction method and system and a medium, and the method comprises the steps: controlling a sampling condition, and analyzing the system gain of each camera; based on the ratio of the standard gain to the system gain, the correction coefficient of each camera is determined to correct each camera, so that the responsivity of each camera after correction is consistent; the method comprises the following steps of: extracting multiple frames of images acquired by the same camera, calculating a time domain noise value of each camera, determining a noise correction coefficient of each camera by adopting a ratio of a standard time domain noise value to the time domain noise value of each camera, and performing noise filtering on a gray value of each pixel point in the images acquired by the cameras according to the noise correction coefficient of each camera, therefore, the noise consistency adjustment of each camera is realized. According to the method, the effect that the noise level is consistent on the premise that the responsivity of the cameras is consistent is achieved, and the universality of the cameras of the same model or different models is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of machine vision, and particularly relates to a multi-camera correction method, system and medium. Background Technology

[0002] When performing response consistency correction using camera system gain, it is necessary to collect the camera system gain. Current solutions typically involve performing additional system gain collection testing after the camera has completed factory testing. This step is separate from the camera's factory testing, requiring extra testing time and manual data processing.

[0003] The degree of universality varies among different camera models. On the one hand, different camera models have different names for the same feature during the gain correction process. On the other hand, different camera models have significant differences in their response to the same light source. These factors make it difficult to flexibly adapt a single fixed method or strategy to different camera models.

[0004] In practical applications, especially in multi-camera systems or mass-produced camera equipment, even if each camera undergoes flat-field calibration, the inherent manufacturing process differences between different sensors can lead to significant response deviations in the output grayscale values ​​of each camera under the same light source conditions. This affects the comparability and consistency of image data between multiple cameras, causing difficulties for customers in subsequent image stitching, comparative analysis, measurement and judgment, and reducing the overall reliability of the multi-camera system. Existing technologies, in the process of correcting the grayscale values ​​of camera responses, also increase noise. In order to achieve consistency in camera responses while adding time-domain noise filtering, and to achieve simultaneous consistency in camera response and noise levels, this invention provides a multi-camera calibration method, system and medium. Summary of the Invention

[0005] The purpose of this invention is to overcome the above-mentioned problems in the prior art and to provide a multi-camera correction method, system and medium.

[0006] To achieve the above-mentioned technical objectives and effects, the present invention is implemented through the following technical solution: A multi-camera correction method is used to perform noise correction on multiple cameras after responsivity correction, so as to achieve consistent adjustment of image quality acquired by each camera. The correction method includes: By controlling the sampling conditions and analyzing the system gain of each camera, the system gain of each camera can be detected during the process of adjusting the light source from dark field to bright field. Based on the ratio between the standard gain and the system gain, the correction coefficients of each camera are determined to correct each camera so that the response of each camera is consistent after correction. Extract multiple frames of images captured by the same camera, calculate the temporal noise value of each camera, determine the noise correction coefficient of each camera by using the ratio of the standard temporal noise value to the temporal noise value of each camera, and filter the gray value of each pixel in the image captured by the camera according to the noise correction coefficient of each camera to achieve noise consistency adjustment of each camera. The temporal noise value is the average of the standard deviations corresponding to the change in grayscale value of each pixel in the entire image across multiple frames captured by the same camera.

[0007] Furthermore, two frames of images under the same sampling conditions are extracted respectively, and the average gray value of the two frames of images under the same sampling conditions and the variance corresponding to the difference in gray values ​​between the two frames of images are calculated. The ratio between the variance and the average gray value under the sampling conditions corresponding to the maximum variance is selected to determine the system gain of the camera.

[0008] Furthermore, based on the average gray value of the image under the sampling condition with the largest variance, the gray values ​​of the images under each sampling condition that have a ratio between the average gray value of the image under each sampling condition and the average gray value of the image under the sampling condition with the largest variance are selected, and the gray values ​​of the images under each sampling condition that are less than a set ratio coefficient threshold are selected.

[0009] Furthermore, the method for determining the standard gain includes: filtering the maximum value among the system gains of each camera, and using the product of a preset coefficient and the maximum system gain as the standard gain, wherein the preset coefficient is greater than 1.

[0010] Furthermore, after calibration, each camera controls the light source to obtain a stable light source. The control method includes: Based on the initial exposure parameter range, determine whether the target gray value is within the gray value range corresponding to the upper and lower limits of the exposure parameters. The exposure parameter range consists of the lower and upper limits of the exposure parameters, and the lower limit of the exposure parameters is less than the upper limit of the exposure parameters. If the grayscale value is not within the range of the upper and lower limits of the exposure parameters, adjust the light source current so that the target grayscale value is within the range of the upper and lower limits of the exposure parameters, and determine the light source brightness under the current light source current. Based on the determined light source brightness under the current light source current, a linear relationship between exposure time and gray value is constructed using the gray values ​​corresponding to the upper and lower limits of the exposure parameters. Determine if the number of fitting iterations is greater than the set number of fitting iterations. If it is, adjust the exposure parameter range using a binary method and update the exposure parameter range to determine if the image's grayscale value has been adjusted to the target grayscale value.

[0011] Furthermore, if the grayscale value of the image is not adjusted to the target grayscale value after the exposure parameter range is adjusted by the binary method, the determined light source brightness is halved or the updated exposure parameter range is adjusted by the binary method to obtain the grayscale value of the light source image tending to the target grayscale value after the exposure parameters and light source brightness are adjusted.

[0012] Furthermore, the method for determining the standard time-domain noise value of the same model of camera includes: determining it by using the average value of the time-domain noise values ​​of each camera under the same model.

[0013] Furthermore, a sliding window is used to extract the gray values ​​of the same pixel position in several consecutive frames of images, calculate the average gray value of the pixel position, and combine the camera's noise correction coefficient to calculate the gray value of the pixel position after filtering in each frame of images. The formula for calculating the grayscale value yi after filtering is: yi = xi / K σ +u(1-K σ ), where xi represents the grayscale value of a pixel in the i-th frame of the image, and K σ It represents the noise correction coefficient corresponding to the camera that captured several frames of images, and u represents the average gray value of the pixel position in several frames of images.

[0014] Based on the same inventive concept, a multi-camera correction system includes: The system data analysis module is used to control sampling conditions and analyze the system gain of each camera to realize the system gain of each camera detected during the process of adjusting the light source from dark field to bright field; The response adjustment module determines the correction coefficient of each camera based on the ratio between the standard gain and the system gain, so as to correct each camera and make the response of each camera consistent after correction. The noise adjustment module extracts multiple frames of images captured by the same camera, calculates the temporal noise value of each camera, determines the noise correction coefficient of each camera by using the ratio of the standard temporal noise value to the temporal noise value of each camera, and performs noise filtering on the gray value of each pixel in the image captured by the camera according to the noise correction coefficient of each camera, so as to achieve noise consistency adjustment of each camera. The temporal noise value is the average of the standard deviations corresponding to the change in grayscale value of each pixel in the entire image across multiple frames captured by the same camera.

[0015] A computer-readable storage medium includes a computer program that, when executed by a processor, implements the multi-camera correction method described in any of the preceding claims.

[0016] The beneficial effects of this invention are: This invention corrects the grayscale values ​​of light source images acquired by cameras under the same signal or different models, so that the responsivity of each camera is consistent after correction. It also performs temporal noise analysis on each camera after responsivity adjustment to determine the noise correction coefficient of each camera. Finally, it filters the grayscale values ​​of each pixel in the image acquired by each camera to achieve the effect of consistent responsivity and noise of each camera, thereby improving the versatility of cameras of the same or different models.

[0017] This invention achieves coordinated adjustment between camera exposure parameter range and light source brightness, and updates the exposure parameter range by fitting the linear relationship between exposure time and gray value within the exposure parameter range. This results in a situation where the actual gray value at the exposure time corresponding to the target gray value in the linear relationship between exposure time and gray value is close to the target gray value. Under the premise of optimizing the gray value adjustment speed, stable adjustment of the light source is achieved, providing reliable camera exposure time and light source brightness for the consistent adjustment of the response of multiple cameras. Attached Figure Description

[0018] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this application, illustrate exemplary embodiments of the invention and, together with their description, serve to explain the invention and do not constitute an undue limitation thereof. In the drawings: Figure 1 This is a flowchart of the multi-camera correction method in this invention; Figure 2 This is a flowchart of the light source control in this invention; Figure 3 This is a schematic diagram of the corrective effect in this invention; Figure 4 This is a schematic diagram of the multi-camera correction system in this invention. Detailed Implementation

[0019] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0020] In the field of camera imaging, a series of corrections are typically performed on the imaging system to obtain high-quality, consistent images. Among these, planar correction is a commonly used method. Its main purpose is to eliminate systematic non-uniformity in the image caused by factors such as optical system vignetting, differences in sensor pixel response, or uneven illumination. After planar correction, the camera can output uniform images under uniform lighting conditions, thus ensuring the image quality of a single camera under specific conditions.

[0021] However, in practical applications, especially in multi-camera systems or mass-produced camera equipment, even if each camera undergoes flat-field calibration, the inherent manufacturing process differences between different sensors can lead to significant response deviations in the output grayscale values ​​of each camera under the same light source conditions. This affects the comparability and coordination of image data between multiple cameras, causing difficulties for customers in subsequent image stitching, comparative analysis, measurement and judgment, and reducing the overall reliability of the multi-camera system.

[0022] like Figure 1 As shown, the present invention also provides a multi-camera correction method for noise correction of multiple cameras after responsivity correction, so as to achieve consistent adjustment of image quality acquired by each camera. The correction method includes: By controlling the sampling conditions and analyzing the system gain of each camera, the system gain of each camera can be detected during the process of adjusting the light source from dark field to bright field. The same camera is used to sequentially acquire images twice, once in dark scenes and once in bright scenes, thus obtaining two images for each sampling condition. For images in bright scenes, the grayscale sampling interval is set at 10% grayscale upper limit. Images corresponding to the overexposed images are acquired from the images corresponding to the 10% grayscale upper limit. Here, the grayscale upper limit is 255, and the 10% grayscale upper limit is the product of 10% and the grayscale upper limit, with a grayscale value of 25.

[0023] The images under each sampling condition are: dark field image, image with a pixel gray value of 10% of the maximum gray value, image with a pixel gray value of 20% of the maximum gray value, image with a pixel gray value of 30% of the maximum gray value, ... image with a pixel gray value of 90% of the maximum gray value, and overexposed image. Each sampled image is numbered sequentially.

[0024] Two frames of images under the same sampling conditions are extracted separately. The average gray value of the two frames under the same sampling conditions and the variance corresponding to the difference in gray values ​​between the two frames are calculated. The ratio between the variance and the average gray value under the sampling conditions corresponding to the maximum variance is selected to determine the system gain of the camera.

[0025] For the same camera and under the same sampling conditions, the gray values ​​of two frames are averaged to obtain the average gray value under the current sampling conditions.

[0026] The gray values ​​of the same pixel in two frames are compared to obtain the difference in gray values ​​of each pixel in the image. Based on the average gray value under the current sampling conditions, the variance corresponding to the difference in gray values ​​of all pixels in the two frames is calculated. From several sampling conditions, the variance and average gray value of the sampling condition with the largest variance are selected. The ratio between the variance and the average gray value under the sampling condition with the largest variance is used as the system gain of the camera.

[0027] Among them, the variance σ corresponding to the difference in grayscale values ​​between two frames is... 2 : m represents the number of pixels in the image, and Δf ji Let u be the difference in grayscale value of the i-th pixel under the j-th sampling condition. j It represents the average grayscale value of the two frames under the j-th sampling condition.

[0028] In this implementation, in order to improve the accuracy of the system gain calculation results of each camera, based on the average gray value of the image under the sampling condition with the largest variance, the gray values ​​of the images under each sampling condition that have a ratio between the average gray value of the image under the sampling condition with the largest variance and the average gray value of the image under the sampling condition with the largest variance are selected and are less than the set ratio coefficient threshold. When the ratio between the average gray value of the image under each sampling condition and the average gray value of the image under the sampling condition with the largest variance is less than the set ratio coefficient threshold, the average gray value of each pixel in the two frames of images and the variance corresponding to the difference in gray values ​​between the two frames of images are linearly related.

[0029] In this embodiment, the set ratio coefficient threshold is selected as 70%, that is, the product between the average gray value of the image under the sampling condition with the largest variance and the set ratio coefficient threshold can obtain the maximum gray value of the image that satisfies the linear relationship.

[0030] Images under each sampling condition with a gray value less than the maximum allowed gray value are selected. The average gray value of two frames under the same sampling condition and the variance corresponding to the difference in gray values ​​between the two frames are calculated. A linear fit is performed on the average gray value of two frames and the variance corresponding to the difference in gray values ​​between the two frames under each sampling condition to obtain a linear expression between the variance corresponding to the difference in gray values ​​between the two frames and the average gray value. The system gain of the current camera can be determined based on the slope of the straight line corresponding to the linear expression.

[0031] When the ratio between the gray values ​​of an image and the gray values ​​of the image with the maximum variance is greater than the set ratio coefficient threshold (0.7), the ratio between the variance corresponding to the difference in gray values ​​between two frames and the average gray value is less than the slope of the straight line in the linear expression. If the system gain of the camera is calculated using images under sampling conditions greater than the set ratio coefficient threshold, the system gain of the camera will deviate from the actual system gain of the camera. In order to improve the accuracy of the system gain calculation of the camera, the set ratio coefficient threshold is used to filter the images under each sampling condition to obtain the current actual system gain of the camera.

[0032] Based on the ratio between the standard gain and the system gain, the correction coefficients of each camera are determined to correct each camera so that the response of each camera is consistent after correction. The method for determining the standard gain includes: filtering the maximum value of the system gain of each camera, and using the product of a preset coefficient and the maximum system gain as the standard gain, wherein the preset coefficient is greater than 1.

[0033] In this implementation, the system gain of multiple cameras of the same model is obtained, the maximum value of the system gain of multiple cameras of the same model is selected, and a preset coefficient is selected. The standard gain of the model can be obtained by multiplying the maximum system gain with the preset coefficient. By selecting the maximum system gain of multiple cameras of the same model and a preset coefficient with a value greater than 1, the correction coefficient of each camera of the same model is made greater than 1, so as to avoid the defect of underexposure caused by the correction coefficient being less than 1.

[0034] Since the preset coefficient is greater than 1, the standard gain value is greater than the system gain value of any camera of the same model. The correction coefficient of each camera is equal to the ratio between the standard gain of the camera of that model and the system gain of each camera of the same model. The correction coefficient of each camera of the same model corrects the gray value of each pixel in the image acquired by the camera to obtain the corrected gray value of each pixel, thereby making the response of the images acquired by each camera consistent.

[0035] In this embodiment, the preset coefficient is preferably set to 1.1, but the specific value of the preset coefficient is not limited and is determined according to actual use.

[0036] Extract multiple frames of images captured by the same camera, calculate the temporal noise value of each camera, determine the noise correction coefficient of each camera by using the ratio of the standard temporal noise value to the temporal noise value of each camera, and filter the gray value of each pixel in the image captured by the camera according to the noise correction coefficient of each camera to achieve noise consistency adjustment of each camera. Wherein, the temporal noise value is the average value corresponding to the standard deviation of the gray value change at each pixel position in the image, and the standard deviation of the gray value change at the pixel position is the standard deviation of the gray value change at the same pixel position in multiple frames of images captured by the same camera.

[0037] In the process of correcting the responsivity consistency of multiple cameras, the grayscale values ​​of the images acquired by each camera are corrected by using the correction coefficients corresponding to each camera to ensure that the final responsivity of each camera is consistent. In the process of correcting multiple cameras, the temporal noise level of the cameras will also increase. In order to ensure that the noise level remains consistent while the responsivity of the cameras is consistent, a noise filtering algorithm needs to be added.

[0038] In this embodiment, the method for determining the standard temporal noise value of the same model of camera includes: using the average value of the temporal noise values ​​of each camera of the same model.

[0039] Specifically, in this embodiment, during the test of temporal noise in the image, several images are continuously acquired at 70% of the grayscale value corresponding to the upper limit of grayscale value (e.g., the grayscale value corresponding to 255*0.7 for 8-bit adjustment). The change in grayscale value at the same pixel position in two adjacent images is calculated, and the average change in grayscale value is calculated. Based on the average change in grayscale value at each pixel position, the standard deviation of the change in grayscale value is calculated. Finally, the average of the standard deviations of the change in grayscale value at all pixel positions in the entire image is taken to obtain the temporal standard deviation σ of the current camera. c .

[0040] Extract the time-domain standard deviation of each camera of the same model and calculate the average to obtain the standard time-domain standard deviation σ of that camera model. m Based on the standard time-domain standard deviation of the same model camera and the standard time-domain standard deviation of the camera, the noise correction coefficient of each camera is calculated. Through the noise correction coefficient, noise can be filtered in the gray values ​​of the images acquired by each camera, so that the camera response is consistent and the noise level is consistent.

[0041] Among them, the noise correction coefficient K for each camera σ =σ m / σ c .

[0042] In this implementation, a sliding window is used to extract the gray values ​​of the same pixel position in several consecutive frames of images, calculate the average gray value of each pixel position, and combine the camera's noise correction coefficient to calculate the gray value of the pixel after filtering in each frame of images. The formula for calculating the grayscale value yi after filtering is: yi = xi / K σ +u(1-K σ ), where xi represents the grayscale value of a pixel in the i-th frame of the image, and Kσ The noise correction coefficient represents the camera that captured several frames of images, and u represents the average gray value of the pixels in the several frames of images.

[0043] Specifically, the grayscale value of a pixel is adjusted based on a noise correction coefficient. This adjustment method involves using a sliding window to record the grayscale value X=[x1,x2,…,xn] of the current pixel position across n consecutive frames of data during continuous image acquisition by the camera, and then calculating the average grayscale value of the current pixel position across those n frames. Based on the method of reducing the standard deviation while keeping the mean of Gaussian noise constant, the gray value of each pixel position after filtering is obtained.

[0044] The above embodiments target different cameras of the same model. By selecting the largest system gain among the cameras of the same model, the standard gain of the camera of that model is determined according to a preset coefficient. The correction coefficient of each camera of that model is determined by sequentially using the ratio between the standard gain of the camera of that model and the system gain of the cameras of that model. Similarly, the present invention can also adjust the consistency of response for different cameras of different models.

[0045] When there is more than one type of camera, the system gain of each camera under each model is statistically analyzed, the maximum system gain of all cameras under all models is selected, and the standard gain of each model of camera that needs to be adjusted for responsivity consistency is determined by multiplying the maximum system gain with a preset coefficient. The standard gain is compared with the system gain of each camera to obtain the correction coefficient of each camera. The gray value of each pixel in the image acquired by the camera is corrected by using the correction coefficient of each camera, so as to achieve responsivity consistency of different cameras under different models.

[0046] To achieve universality across different camera models, a mapping table is established to obtain the feature parameters matched by different names in different camera models, since the same feature parameter appears with different names in different camera models.

[0047] Similarly, achieving consistent response adjustment between different cameras of the same model and between different cameras of different models is key to improving the overall performance of a multi-camera system. During the response adjustment process, the stability of the light source is the main factor affecting the consistency of response. Due to the instability of the light source itself and the long time required to reach a stable state during the adjustment of the exposure time of different cameras and the brightness of the light source, multiple adjustments are made in coordination between the camera exposure time and the brightness of the light source in order to quickly achieve stable adjustment of the light source.

[0048] After each camera undergoes flat-field correction, in order to eliminate their differences, different cameras of the same model or different cameras of different models use the ratio between the standard gain and the system gain of each camera to determine the correction coefficient of each camera, thereby making the response of each camera consistent after correction.

[0049] This embodiment discloses an example for adjusting the stability of a light source. Each camera is selected to capture images of the light source, specifically, as follows: Figure 2 As shown, after calibration, each camera controls the light source to obtain a stable light source. The control method includes: Based on the initial exposure parameter range, determine whether the target gray value is within the gray value range corresponding to the upper and lower limits of the exposure parameters. The exposure parameter range consists of the lower and upper limits of the exposure parameters, and the lower limit of the exposure parameters is less than the upper limit of the exposure parameters. The initial exposure parameter range is [t1, t2], where t1 is the lower limit of the exposure parameter and t2 is the upper limit of the exposure parameter. The exposure parameter is the exposure time.

[0050] If the grayscale value is not within the range of the upper and lower limits of the exposure parameters, adjust the light source current so that the target grayscale value is within the range of the upper and lower limits of the exposure parameters, and determine the light source brightness under the current light source current. When the exposure parameter is at the lower limit, it is determined whether the gray value of each pixel in the acquired light source image is less than the target gray value. If it is less than the target gray value, it is determined whether the gray value of each pixel in the acquired light source image is greater than the target gray value when the exposure parameter is at the upper limit. If it is greater than the target gray value, it indicates that under the current light source brightness, the target gray value is within the gray value range corresponding to the upper and lower limits of the exposure parameter.

[0051] If the grayscale value of each pixel in the acquired light source image is greater than the target grayscale value when the exposure parameter is at the lower limit, the light source current is reduced according to the linear relationship between the light source current and the grayscale value, so that the grayscale value of each pixel in the acquired light source image is less than the target grayscale value when the exposure parameter is at the lower limit, and the light source brightness under the current light source current is recorded. If the grayscale value of each pixel in the acquired light source image is less than the target grayscale value when the exposure parameters are at their upper limit, the light source current is enhanced and adjusted according to the linear relationship between the light source current and the grayscale value, so that the grayscale value of each pixel in the acquired light source image is greater than the target grayscale value when the exposure parameters are at their upper limit, and the light source brightness under the light source current is updated.

[0052] By controlling the change in the current of the light source, the grayscale value of the light source under different light source currents is obtained. Linear fitting is then used to obtain the linear relationship between the light source current and the grayscale value of the light source.

[0053] In this embodiment, based on the updated light source current and the light source brightness, under the updated light source current, the difference between the grayscale value of the acquired light source image and the target grayscale value is greater than the tolerance grayscale value under the minimum exposure parameter, and the difference between the grayscale value of the acquired light source image and the target grayscale value is greater than the tolerance grayscale value under the maximum exposure parameter. Specifically, under the minimum exposure parameter, the grayscale value of the light source image is less than the target grayscale value; the target grayscale value is less than the grayscale value of the light source image under the maximum exposure parameter.

[0054] The tolerance gray value The tolerance coefficient δ is set to 0.05, and g t This represents the target grayscale value.

[0055] Based on the tolerance grayscale value and the target grayscale value, the upper limit of the grayscale value corresponding to the minimum exposure parameter and the lower limit of the grayscale value corresponding to the maximum exposure parameter can be determined. The upper limit of the grayscale value corresponding to the minimum exposure parameter is... The lower limit of the grayscale value corresponding to the maximum exposure parameter. .

[0056] For the light source brightness determined above, the target grayscale value must fall within the grayscale value range corresponding to the upper and lower limits of the exposure parameters. If the determined light source brightness only has a grayscale value corresponding to the lower limit of the exposure parameters that is greater than the target grayscale value or a grayscale value corresponding to the upper limit of the exposure parameters that is less than the target grayscale value, then the light source brightness under the current light source current cannot be determined.

[0057] Based on a determined light source brightness, the gray values ​​corresponding to the upper and lower limits of the exposure parameters are used to construct a linear relationship between exposure time and gray value, so as to obtain the adjusted exposure time and light source brightness. Under a given light source brightness, the upper limit of the exposure parameters and the corresponding gray values, as well as the lower limit of the exposure parameters and the corresponding gray values, are extracted. Using the gray values ​​corresponding to the two sets of exposure times, a linear expression between exposure time and gray value is fitted. Based on the linear expression between exposure time and gray value, the exposure time corresponding to the target gray value is calculated, and the camera's exposure time is adjusted to obtain the true gray value corresponding to the current exposure time. The relationship between the absolute value of the difference between the true gray value of the exposure time and the target gray value corresponding to the linear expression and the set gray value threshold is determined. If it is less than the set gray value threshold, the exposure time adjustment of the linear light source within the exposure parameter range is completed.

[0058] If the grayscale value is greater than the set grayscale threshold, the current exposure time and the corresponding true grayscale value are extracted. This is then combined with the upper and lower limits of the exposure parameters (the grayscale values ​​being the true grayscale values ​​corresponding to the exposure time) to obtain a linear expression between the exposure time and the grayscale value. Based on this new linear expression, the exposure time corresponding to the target grayscale value is calculated. The camera's exposure time is then readjusted based on the calculated exposure time to obtain the true grayscale value corresponding to the current exposure time in the linear expression. The absolute value of the difference between the adjusted true grayscale value and the target grayscale value is then determined. If this difference is less than the set grayscale threshold, the exposure time of the line light source is adjusted within the exposure parameter range.

[0059] The exposure parameter range includes an upper limit and a lower limit. The upper limit corresponds to a first exposure time, and the lower limit corresponds to a second exposure time. The first exposure time is greater than the second exposure time. During the exposure time adjustment process, only the exposure time changes.

[0060] If the grayscale value is not less than the set grayscale threshold, the exposure time corresponding to the target grayscale value calculated by the linear expression and the actual grayscale value corresponding to the exposure time are extracted. Combining the exposure time and the actual grayscale value, the least squares method is used to fit a linear expression between the exposure time and the grayscale value. The number of fitting iterations is counted. Within the set number of fitting iterations m, if the difference between the actual grayscale value obtained from the linear expression between the exposure time and the target grayscale value is less than the set grayscale threshold, the linear expression between the exposure time and the grayscale value corresponding to the difference between the actual grayscale value and the target grayscale value being less than the set grayscale threshold is extracted, thus adjusting the exposure time of the line light source. In this embodiment, the number of fitting iterations is set to 10 to reduce the amount of data repeatedly fitted; other number of fitting iterations can be set as needed.

[0061] Determine if the number of fitting iterations is greater than the set number of fitting iterations. If it is, adjust the exposure parameter range using a binary method and update the exposure parameter range to determine if the image's grayscale value has been adjusted to the target grayscale value.

[0062] When the degree of the linear expression between the fitted exposure time and gray value is greater than the set number of fitting iterations, the exposure parameter range is divided into two parts. It is determined whether the gray value of the light source image corresponding to the median value of the exposure parameters in the exposure parameter range is greater than the set target gray value. Based on whether the gray value of the light source image corresponding to the median value of the exposure parameters is greater than the set target gray value, the exposure parameter range is redefined. The median value of the exposure parameters is equal to the average of the sum of the lower limit and the upper limit of the exposure parameters.

[0063] If the grayscale value of the light source image corresponding to the median of the exposure parameters is greater than the set target grayscale value, the exposure parameter range is adjusted from the lower limit of the exposure parameters to the median of the exposure parameters. If the grayscale value of the light source image corresponding to the median of the exposure parameters is less than the set target grayscale value, the exposure parameter range is adjusted from the median of the exposure parameters to the upper limit of the exposure parameters. Based on the grayscale value corresponding to the newly determined exposure parameter range, the linear relationship between exposure time and grayscale value is refitted. Based on the fitted linear relationship between exposure time and grayscale value, the exposure time corresponding to the target grayscale value is calculated, and the camera's exposure time is adjusted to obtain the true grayscale value of the light source image acquired at the current exposure time. It is then determined whether the difference between the true grayscale value of the light source image acquired at the current exposure time and the target grayscale value is less than the set grayscale value threshold. If it is less than the set grayscale value threshold, the exposure time adjustment of the line light source is achieved within the exposure parameter range adjusted by the bisection method.

[0064] In this embodiment, if the grayscale value of the light source image does not reach the target grayscale value after the exposure parameter range is adjusted by the bisection method, the determined light source brightness is halved, and the updated exposure parameter range is adjusted by the bisection method to obtain the grayscale value of the light source image tending to the target grayscale value after the exposure parameters and light source brightness are adjusted.

[0065] Specifically, if the grayscale value exceeds the set grayscale threshold, the current light source brightness is halved, and a new bisection is performed on the new exposure parameter range. By comparing the grayscale value of the light source image corresponding to the exposure time after bisection with the target grayscale value, the exposure parameter range is updated. The grayscale value corresponding to the updated exposure parameter range is then fitted to obtain a linear relationship between the updated exposure time and grayscale value. The exposure time corresponding to the target grayscale value is calculated, and the camera's exposure time is repeatedly adjusted. It is then determined whether the difference between the actual grayscale value of the light source image acquired at the current exposure time and the target grayscale value is less than the set grayscale threshold. If it is less than the set grayscale threshold, the light source brightness adjustment is completed within the new exposure parameter range; if it exceeds the set grayscale threshold, the light source brightness cannot be adjusted within the exposure parameter range, and the adjustment ultimately fails.

[0066] In this implementation, when the difference between the actual gray value and the target gray value of the light source image acquired at the current exposure time is greater than the set gray value threshold, the current exposure time and the actual gray value corresponding to the exposure time are extracted as fitting data. By continuously increasing the fitting data, the accuracy of the linear relationship between the fitted exposure time and the gray value is improved.

[0067] By analyzing the relationship between the grayscale values ​​corresponding to the upper and lower limits of the exposure parameter range and the target grayscale value, the brightness of the light source corresponding to the exposure parameter range that meets the light source requirements is initially determined. Based on the grayscale values ​​corresponding to the exposure parameters, a linear relationship between exposure time and grayscale value is fitted. Based on whether the difference between the actual grayscale value at the exposure time corresponding to the target grayscale value in the linear relationship and the target grayscale value is less than the set grayscale value threshold, the camera's exposure time and light source brightness are adjusted to quickly adjust a stable light source.

[0068] Once the difference between the actual gray value and the target gray value at the specified exposure time is greater than a set gray value threshold, based on the linear relationship between exposure time and gray value within the exposure parameter range, the exposure parameter range and light source brightness are narrowed. This ensures that the difference between the actual gray value at the specified exposure time and the target gray value in the adjusted linear relationship between exposure time and gray value is less than the set gray value threshold. By gradually approximating the target gray value with the exposure parameter range and light source brightness, the actual gray value at the specified exposure time in the fitted linear expression is close to the target gray value. This achieves coordinated adjustment of camera exposure time and light source brightness, ensuring stable adjustment of the camera and light source while optimizing the gray value adjustment speed. This provides reliable exposure time and light source brightness for consistent adjustment of the response of multiple cameras.

[0069] In this implementation, the grayscale value corresponding to the current camera's system gain is extracted. The relationship between the grayscale value corresponding to the system gain and the grayscale value corresponding to the average system gain is determined. The absolute value of the ratio between the difference between the grayscale value corresponding to the current camera's system gain and the grayscale value corresponding to the average system gain is determined. If the absolute value of the ratio is not greater than 25%, the system gain is written to the database to realize a closed-loop feedback mechanism. If the absolute value of the ratio is greater than 25%, the system gain is not written to the database.

[0070] By correcting multiple cameras to ensure consistent responsivity, and by adding a noise filtering algorithm during this process, noise levels are kept consistent while maintaining consistent responsivity across multiple cameras. This avoids an increase in noise levels due to responsivity adjustment, achieving universality for cameras of the same or different models and eliminating differences between cameras.

[0071] like Figure 3As shown, taking the lowest analog gain of PA8KCL-80KM as an example, the consistency correction effect shows that before correction, the maximum difference between the gain of each camera and the mean system was 11.82%. After adding consistency correction, the maximum difference in camera system gain was 3.87%, the standard deviation of camera system gain decreased from 0.0016 to 0.0004, the fluctuation of camera system gain value was significantly reduced, and the gain of each camera system was close to the standard value with no obvious deviation data. By performing consistent correction on the camera's responsivity, with the same light source brightness and the same exposure parameters, the average gray value of each camera with consistent responsivity adjustment is used as the standard gray value. The maximum difference between the gray value of each camera and the standard gray value is 4.21%, which meets the expected requirements.

[0072] Based on the same inventive concept, such as Figure 4 As shown, the present invention also discloses a multi-camera correction system, comprising: The system data analysis module is used to control sampling conditions and analyze the system gain of each camera to realize the system gain of each camera detected during the process of adjusting the light source from dark field to bright field; The response adjustment module determines the correction coefficient of each camera based on the ratio between the standard gain and the system gain, so as to correct each camera and make the response of each camera consistent after correction. The noise adjustment module extracts multiple frames of images captured by the same camera, calculates the temporal noise value of each camera, determines the noise correction coefficient of each camera by using the ratio of the standard temporal noise value to the temporal noise value of each camera, and performs noise filtering on the gray value of each pixel in the image captured by the camera according to the noise correction coefficient of each camera, so as to achieve noise consistency adjustment of each camera. The temporal noise value is the average of the standard deviations corresponding to the change in grayscale value of each pixel in the entire image across multiple frames captured by the same camera.

[0073] The detailed operation methods and principles of each module in the above multi-camera correction system are as described in the above multi-camera correction method, and will not be repeated here.

[0074] The present invention also provides a computer-readable storage medium including a computer program that, when executed by a processor, implements the above-described multi-camera correction method.

[0075] In practical applications, a computer-readable storage medium can be any combination of one or more computer-readable media. A computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. A computer-readable storage medium can be, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this embodiment, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.

[0076] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, capable of sending, propagating, or transmitting programs for use by or in connection with an instruction execution system, apparatus, or device.

[0077] Program code contained on a computer-readable medium may be transmitted using any suitable medium, including but not limited to wireless, wire, optical fiber, RF, etc., or any suitable combination thereof.

[0078] Computer program code for performing the operations of this application can be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, and C++, and conventional procedural programming languages ​​such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0079] In the description of this specification, references to terms such as "an embodiment," "example," and "specific example" indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.

[0080] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely illustrative of the principles of the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the claimed invention.

Claims

1. A multi-camera correction method for performing noise correction on multiple cameras after responsivity correction, so as to achieve consistent adjustment of image quality acquired by each camera, characterized in that, The correction method includes: By controlling the sampling conditions and analyzing the system gain of each camera, the system gain of each camera can be detected during the process of adjusting the light source from dark field to bright field. Based on the ratio between the standard gain and the system gain, the correction coefficients of each camera are determined to correct each camera so that the response of each camera is consistent after correction. Extract multiple frames of images captured by the same camera, calculate the temporal noise value of each camera, determine the noise correction coefficient of each camera by using the ratio of the standard temporal noise value to the temporal noise value of each camera, and filter the gray value of each pixel in the image captured by the camera according to the noise correction coefficient of each camera to achieve noise consistency adjustment of each camera. The temporal noise value is the average of the standard deviations corresponding to the change in grayscale value of each pixel in the entire image across multiple frames captured by the same camera.

2. The multi-camera correction method according to claim 1, characterized in that, Two frames of images under the same sampling conditions are extracted separately. The average gray value of the two frames under the same sampling conditions and the variance corresponding to the difference in gray values ​​between the two frames are calculated. The ratio between the variance and the average gray value under the sampling conditions corresponding to the maximum variance is selected to determine the system gain of the camera.

3. The multi-camera correction method according to claim 2, characterized in that, Based on the average gray value of the image under the sampling condition with the largest variance, the gray values ​​of the images under each sampling condition that have a ratio less than the average gray value of the image under the sampling condition with the largest variance are selected.

4. The multi-camera correction method according to claim 1, characterized in that, The method for determining the standard gain includes: filtering the maximum value among the system gains of each camera, and using the product of a preset coefficient and the maximum system gain as the standard gain, wherein the preset coefficient is greater than 1.

5. The multi-camera correction method according to claim 4, characterized in that, After each camera is calibrated, the light source is controlled to obtain a stable light source. The control method includes: Based on the initial exposure parameter range, determine whether the target gray value is within the gray value range corresponding to the upper and lower limits of the exposure parameters. The exposure parameter range consists of the lower and upper limits of the exposure parameters, and the lower limit of the exposure parameters is less than the upper limit of the exposure parameters. If the grayscale value is not within the range of the upper and lower limits of the exposure parameters, adjust the light source current so that the target grayscale value is within the range of the upper and lower limits of the exposure parameters, and determine the light source brightness under the current light source current. Based on the determined light source brightness under the current light source current, a linear relationship between exposure time and gray value is constructed using the gray values ​​corresponding to the upper and lower limits of the exposure parameters. Determine if the number of fitting iterations is greater than the set number of fitting iterations. If it is, adjust the exposure parameter range using a binary method and update the exposure parameter range to determine if the image's grayscale value has been adjusted to the target grayscale value.

6. The multi-camera correction method according to claim 5, characterized in that, If the grayscale value of the image is not adjusted to the target grayscale value after the exposure parameter range is adjusted by the binary method, then the brightness of the determined light source is halved or the updated exposure parameter range is adjusted by the binary method to obtain the grayscale value of the light source image that tends to the target grayscale value after the exposure parameters and light source brightness are adjusted.

7. The multi-camera correction method according to claim 1, characterized in that, Methods for determining the standard time-domain noise value of the same model of camera include: determining it by using the average value of the time-domain noise values ​​of each camera of the same model.

8. The multi-camera correction method according to claim 7, characterized in that, Using a sliding window, the grayscale values ​​of the same pixel location are extracted consecutively in several frames of images. The average grayscale value of the pixel location is calculated. Combined with the camera's noise correction coefficient, the grayscale value of the pixel location after filtering is calculated in each frame of images. The formula for calculating the grayscale value yi after filtering is: yi = xi / K σ +u(1-K σ ), where xi represents the grayscale value of a pixel in the i-th frame of the image, and K σ It represents the noise correction coefficient corresponding to the camera that captured several frames of images, and u represents the average gray value of the pixel position in several frames of images.

9. A multi-camera correction system, applied to the multi-camera correction method according to any one of claims 1-8, characterized in that, include: The system data analysis module is used to control sampling conditions and analyze the system gain of each camera to realize the system gain of each camera detected during the process of adjusting the light source from dark field to bright field; The response adjustment module determines the correction coefficient of each camera based on the ratio between the standard gain and the system gain, so as to correct each camera and make the response of each camera consistent after correction. The noise adjustment module extracts multiple frames of images captured by the same camera, calculates the temporal noise value of each camera, determines the noise correction coefficient of each camera by using the ratio of the standard temporal noise value to the temporal noise value of each camera, and performs noise filtering on the gray value of each pixel in the image captured by the camera according to the noise correction coefficient of each camera, so as to achieve noise consistency adjustment of each camera. The temporal noise value is the average of the standard deviations corresponding to the change in grayscale value of each pixel in the entire image across multiple frames captured by the same camera.

10. A computer-readable storage medium comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the multi-camera correction method as described in any one of claims 1-8.