A processing method for industrial camera acquisition
Through the intelligent automatic exposure control system and deep neural network model, combined with multi-frame information fusion and adaptive optical enhancement, the image acquisition problem of traditional industrial cameras in low-light environments is solved, and high-quality image output and detection accuracy are improved.
Patent Information
- Application Number
- CN202411356469.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-27
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2044-09-27
AI Technical Summary
Traditional industrial cameras have problems such as increasing noise, loss of details, low contrast, and improper exposure in low-light environments. They also lack the comprehensive utilization of multi-frame information and automatic adjustment of optical components, which affects image quality and detection accuracy.
The intelligent automatic exposure control system and deep neural network model are adopted, combined with multi-frame information fusion technology and adaptive optical enhancement system, the exposure parameters and optical component settings are dynamically adjusted to generate high-quality images, and the algorithms and models are continuously optimized through the feedback mechanism.
It significantly improves the clarity and detail performance of images, reduces noise, optimizes exposure effects, improves image processing efficiency and detection accuracy of production processes, and improves overall production efficiency and product quality.
Smart Images

Figure CN118972701B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of visual inspection technology, and in particular to a processing method for data collected by an industrial camera. Background Art
[0002] With the popularization of automated production lines in manufacturing enterprises and the improvement of production speed of automated production lines, the online detection technology of machine vision, as the top priority of automated production lines, is being improved and upgraded to adapt to the production speed of automated production lines.
[0003] At present, the online detection technology of machine vision commonly used in automated production lines is to use industrial cameras to detect the flowing products produced by automated production lines. By using an encoder to connect the drive shaft of the conveyor belt, the moving speed of the product can be considered to be the same speed as the conveyor belt driven by the drive shaft. The encoder can determine the rotation speed and position of the rotating shaft. Therefore, the running distance and speed of the driving shaft rotating circle conveyor belt can be determined by judging the circumference and rotation speed of the driving shaft belt. The encoder will rotate to generate an electrical pulse signal output to the industrial camera, thereby controlling the industrial acquisition and imaging.
[0004] However, traditional industrial cameras have problems with increased noise, loss of details and low contrast in low-light environment image collection. Traditional methods mostly use single-frame images for processing, lack the comprehensive use of multi-frame information, and cannot effectively use the information in the time series for image enhancement and noise reduction. In addition, the existing exposure control methods of industrial cameras are mostly static settings, which cannot respond to changes in ambient light in real time, resulting in problems with image exposure or overexposure, which in turn affects image quality and makes it impossible to accurately detect and identify target objects. At the same time, the optical component settings of traditional industrial cameras are usually fixed or manually adjusted, lacking an automatic adjustment mechanism, which affects the effect of image acquisition.
[0005] Therefore, those skilled in the art provide a processing method for industrial camera acquisition to solve the problems raised in the above background technology. Summary of the invention
[0006] In view of the deficiencies in the prior art, the present invention provides a processing method for industrial camera acquisition to solve the problems raised in the above background technology.
[0007] To achieve the above objectives, the present invention is implemented through the following technical solutions: a processing method for industrial camera acquisition, comprising the following steps:
[0008] Step 1: Start the industrial camera, initialize the basic parameters, enable the intelligent automatic exposure control system, and preliminarily set the exposure time and gain parameters;
[0009] Step 2: Use the developed exposure control algorithm based on image analysis to analyze the initial image data in low-light environment in real time, and dynamically adjust the camera's exposure parameters according to the image brightness and details;
[0010] Step 3, continuously collecting multiple frames of low-light images in a short time;
[0011] Step 4: Use an efficient image alignment algorithm to align multiple frames of images, and apply multi-frame information fusion technology to fuse the aligned multi-frame image data to generate a clear, high-quality image;
[0012] Step 5: Input the fused image into the trained deep neural network model, so that the deep neural network model processes the input image according to the learned low-light image features;
[0013] Step 6: Combining the image processing results and the ambient light information, the adaptive optical enhancement system is used to dynamically adjust the optical element settings of the camera. After the optical settings are adjusted, image acquisition can be performed again.
[0014] Step 7: Output the processed high-quality image and store or transmit it to a downstream application system;
[0015] Step 8: Establish a feedback mechanism to continuously optimize automatic exposure control, image fusion algorithm and deep learning model based on actual application effects and environmental changes.
[0016] Preferably, in step 1, the intelligent automatic exposure control system is based on image analysis and machine learning technology to optimize the exposure parameters of industrial cameras in low-light environments. The system analyzes the captured image data in real time and dynamically adjusts the exposure time and gain settings;
[0017] The intelligent automatic exposure control system includes an image acquisition module, an image analysis module, an exposure control module, and a feedback mechanism; the image acquisition module is responsible for capturing the initial image and providing real-time image data for analysis; the image analysis module uses an image processing algorithm to analyze the brightness, contrast, and detail features of the image in real time; the exposure control module adjusts the exposure time and gain parameters of the camera according to the image analysis results; the feedback mechanism continuously monitors the image quality and adjusts the exposure parameters to cope with changes in ambient light.
[0018] Preferably, in the intelligent automatic exposure control system, the average brightness value of the image is calculated by a weighted average method, and the weighted average method formula is:
[0019] ,
[0020] in, , , Represents the red, green, and blue components of the i-th pixel in the image, respectively, and N represents the total number of pixels in the image;
[0021] In the intelligent automatic exposure control system, the exposure error is calculated by an exposure error evaluation function, and its algorithm formula is:
[0022] ,
[0023] in, Image brightness, Target brightness;
[0024] In the intelligent automatic exposure control system, the exposure time t and gain are dynamically adjusted according to the exposure error. , its algorithm formula is:
[0025] ,
[0026] ,
[0027] in, and It is a control parameter that adjusts the system's response speed to exposure error.
[0028] Preferably, in step 4, after aligning the images by an exposure control algorithm, multiple frames of images are fused, and the image fusion includes weighted average fusion and noise suppression fusion;
[0029] The weighted average fusion is to perform weighted average on the pixel values of each frame image according to its weight, and its algorithm formula is:
[0030] ,
[0031] in, The pixel value of the fused image, is the pixel value of the i-th frame image, is the corresponding weight, N is the number of frames;
[0032] The noise suppression fusion suppresses noise by calculating the median of pixel values or using a filter. The algorithm formula is:
[0033] ,
[0034] ,
[0035] in, is the filter weight.
[0036] Preferably, in step 5, the specific implementation algorithm steps of the deep learning model are as follows:
[0037] Step 1: Image preprocessing Input image To standardize:
[0038] ,
[0039] Among them, μ and σ are the mean and standard deviation of the image;
[0040] The second step, the convolution layer is used to extract image features:
[0041] ,
[0042] in, is the feature map of layer l, and are the weights and biases of the lth layer, Represents the convolution operation;
[0043] The third step is to use the pooling layer to reduce the size of the feature map while retaining the features:
[0044] ,
[0045] in, Represents the maximum pooling operation;
[0046] Step 4: The image enhancement layer processes the features to generate an enhanced image:
[0047] ,
[0048] Where E is the enhanced image, and are the weights and biases of the enhancement layer, is the activation function of the output layer;
[0049] Step 5. During the training process, use the loss function to measure the difference between the model output and the target enhanced image:
[0050] ,
[0051] Where N is the total number of image pixels, is the i-th pixel value of the enhanced image, The i-th pixel value of the target enhanced image;
[0052] Step 6: Use the back propagation algorithm to update the network parameters W and b:
[0053] ,
[0054] in, is the learning rate.
[0055] Preferably, the algorithm in step 6 involves an adaptive optical enhancement system, which dynamically adjusts the optical element settings of the camera in combination with the image processing results and the ambient light information. The algorithm steps are as follows:
[0056] a. Obtain the image processed by the deep neural network model and analyze its details and brightness information;
[0057] b. Obtain the lighting conditions of the environment in real time;
[0058] c. Calculate the optical element parameters to be adjusted based on the image processing results and ambient light information;
[0059] d. Adjust the camera's optical settings;
[0060] e. After adjusting the optical settings, image acquisition can be performed again.
[0061] Preferably, the algorithm formula in the algorithm step in step 6 is as follows:
[0062] Get the image processed by the deep neural network model , calculate the average brightness of the image And the level of detail, its algorithm formula:
[0063] ,
[0064] in, is the i-th pixel value of the enhanced image, N is the total number of pixels in the image;
[0065] Based on the image processing results and ambient light information, the optical element parameters are calculated. The algorithm formula is:
[0066] ,
[0067] in, and To control the parameters, is the target brightness, is the target ambient light intensity;
[0068] ,
[0069] in, To control the parameters, is the target level of detail, It is the detail level, which can be calculated by image gradient. The algorithm formula of image gradient is:
[0070] ,
[0071] Adjust the aperture size of the optical element and focal length .
[0072] Preferably, the algorithm in step 8 involves establishing a feedback mechanism to continuously optimize automatic exposure control, image fusion algorithm and deep learning model according to actual application effects and environmental changes. The following are the algorithm steps of the feedback mechanism:
[0073] a. Image quality assessment: assess the quality of processed images;
[0074] b. Error calculation: calculate the error between image quality and target quality;
[0075] c. Parameter adjustment: adjust the parameters of each algorithm module according to the error;
[0076] d. Model update: Update the deep learning model through online learning or regular retraining;
[0077] e. System iteration: re-process the image based on parameters and models.
[0078] Preferably, the algorithm formula in the feedback mechanism algorithm step is as follows:
[0079] The peak signal-to-noise ratio and structural similarity index can be used to evaluate image quality. The algorithm formula is:
[0080] ,
[0081] Among them, is the maximum pixel value of the image , the mean square error is:
[0082] ,
[0083] Structural similarity index calculation formula:
[0084] ,
[0085] in, and is the average value of image x and y, and is the variance of images x and y, is the covariance of images x and y, and is the stability constant;
[0086] Calculating image quality Target image quality The error between:
[0087] ,
[0088] Adjust the exposure time t and gain g according to the image quality error:
[0089] ,
[0090] in, and is the control parameter.
[0091] Adjust the weight of multi-frame fusion according to the image quality error:
[0092] ,
[0093] in, is the control parameter.
[0094] The present invention provides a processing method for industrial camera acquisition, which has the following beneficial effects:
[0095] 1. The present invention develops a deep neural network model specifically for low-light environments, which can automatically learn and optimize the features of low-light image processing, effectively improve the clarity and detail of the image, and adopts multi-frame information fusion technology to combine multi-frame low-light image data for image reconstruction and enhancement, which can significantly reduce image noise, enhance image details, and generate clearer and higher-quality image output.
[0096] 2. The intelligent automatic exposure control system developed by the present invention can analyze image information in low-light environments in real time, dynamically adjust exposure time and gain settings, effectively optimize image quality, and avoid image distortion caused by underexposure or overexposure. The proposed adaptive optical enhancement system can dynamically adjust the optical element settings of the camera according to real-time image data and ambient light conditions, improve light collection efficiency, and further reduce image noise in low-light environments.
[0097] 3. By establishing a feedback mechanism, the present invention can continuously optimize the automatic exposure control, image fusion algorithm and deep learning model according to the actual application effects and environmental changes, ensuring that the system always maintains the best performance under different conditions. The efficient image alignment and fusion algorithm can complete the acquisition, alignment and fusion processing of multiple frames of images in a short time, thereby improving image processing efficiency.
[0098] 4. The present invention utilizes artificial intelligence and machine learning technologies to enable the industrial camera system to have self-learning, self-adaptation and self-optimization capabilities, thereby improving the intelligence and automation level of the system. The high-quality images can provide more reliable basic data for subsequent image analysis and processing, improve the detection, monitoring and control accuracy in the industrial production process, and improve the overall production efficiency and product quality. BRIEF DESCRIPTION OF THE DRAWINGS
[0099] Figure 1 It is a flow chart of the present invention. DETAILED DESCRIPTION
[0100] In order to make the technical personnel in the technical field understand the scheme of the present invention, the technical scheme in the embodiment of the present invention will be clearly and completely described below in combination with the drawings in the embodiment of the present invention. Obviously, the described embodiment is a partial embodiment of the present invention, not a complete embodiment. Based on the embodiment of the present invention, other embodiments obtained by ordinary technicians in the field without creative work should fall within the scope of protection of the present invention.
[0101] The present invention is described in detail below in conjunction with the accompanying drawings:
[0102] Example:
[0103] Please see attached Figure 1 The embodiment of the present invention provides a processing method for industrial camera acquisition, comprising the following steps:
[0104] Step 1: Start the industrial camera, initialize the basic parameters, enable the intelligent automatic exposure control system, and preliminarily set the exposure time and gain parameters;
[0105] Step 2: Use the developed exposure control algorithm based on image analysis to analyze the initial image data in low-light environment in real time, and dynamically adjust the camera's exposure parameters according to the image brightness and details;
[0106] Step 3, continuously collecting multiple frames of low-light images in a short time;
[0107] Step 4: Use an efficient image alignment algorithm to align multiple frames of images, and apply multi-frame information fusion technology to fuse the aligned multi-frame image data to generate a clear, high-quality image;
[0108] Step 5: Input the fused image into the trained deep neural network model, so that the deep neural network model processes the input image according to the learned low-light image features;
[0109] Step 6: Combining the image processing results and the ambient light information, the adaptive optical enhancement system is used to dynamically adjust the optical element settings of the camera. After the optical settings are adjusted, image acquisition can be performed again.
[0110] Step 7: Output the processed high-quality image and store or transmit it to a downstream application system;
[0111] Step 8: Establish a feedback mechanism to continuously optimize automatic exposure control, image fusion algorithm and deep learning model based on actual application effects and environmental changes.
[0112] The benefits of step 1 are to ensure that the industrial camera can start quickly, improve the response speed of the system, and provide reasonable exposure time and gain parameters through the initial setting of the intelligent automatic exposure control system to ensure high initial image quality; the benefits of step 2 are to avoid overexposure and underexposure, ensure the balance of image brightness and details, and improve the clarity and detail performance of the image; the benefits of step 3 are to reduce motion blur caused by camera shake or object movement through rapid and continuous acquisition, and improve the stability and clarity of the image; the benefits of step 4 are to use multi-frame information fusion technology to integrate effective information in multi-frame images, reduce noise, enhance details, and generate clear and high-quality images; the benefits of step 5 are to effectively identify and optimize low-light image features, further improve image quality, and significantly improve the visual effect and information content of the image; the benefits of step 6 are to dynamically adjust the optical component settings, optimize light collection efficiency, and reduce image noise in low-light environments; the benefits of step 7 are to improve data flow efficiency and support detection, monitoring and control tasks in industrial production processes; the benefits of step 8 are to continuously optimize according to actual application effects and environmental changes to ensure that the system performance is always in the best state, and to continuously adjust and improve according to feedback to improve the intelligence and automation level of the system.
[0113] In step 1, the intelligent automatic exposure control system is based on image analysis and machine learning technology to optimize the exposure parameters of industrial cameras in low-light environments. The system analyzes the captured image data in real time and dynamically adjusts the exposure time and gain settings;
[0114] The intelligent automatic exposure control system includes an image acquisition module, an image analysis module, an exposure control module, and a feedback mechanism; the image acquisition module is responsible for capturing the initial image and providing real-time image data for analysis; the image analysis module uses an image processing algorithm to analyze the brightness, contrast, and detail features of the image in real time; the exposure control module adjusts the camera's exposure time and gain parameters based on the image analysis results; the feedback mechanism continuously monitors image quality and adjusts exposure parameters to cope with changes in ambient light.
[0115] The image acquisition module provides high-quality and complete initial image data, providing a reliable foundation for subsequent image analysis and exposure control; the image analysis module can accurately analyze the brightness, contrast and detail features of the image, provide detailed image quality indicators, and realize fast and real-time image analysis, ensuring that the system can quickly adjust exposure parameters and improve image quality; the exposure control module reduces human intervention, realizes automatic adjustment, and improves the intelligence level and ease of use of the system; through the feedback mechanism, the system can self-learn and adapt to gradually improve its own performance and response speed.
[0116] In the intelligent automatic exposure control system, the average brightness value of the image is calculated by the weighted average method. The weighted average method formula is:
[0117] ,
[0118] in, , , Represents the red, green, and blue components of the i-th pixel in the image, respectively, and N represents the total number of pixels in the image;
[0119] In the intelligent automatic exposure control system, the exposure error is calculated by the exposure error evaluation function. The algorithm formula is:
[0120] ,
[0121] in, Image brightness, Target brightness;
[0122] In the intelligent automatic exposure control system, the exposure time t and gain are dynamically adjusted according to the exposure error. , its algorithm formula is:
[0123] ,
[0124] ,
[0125] in, and It is a control parameter that adjusts the system's response speed to exposure error.
[0126] The weighted average method is used to calculate the average brightness value of an image. The algorithm formula is used to calculate the average brightness value of an image. It is the basic data of an intelligent automatic exposure control system. Through weighted processing, the formula takes into account the differences in the sensitivity of the human eye to different colors. The exposure error evaluation function calculates the exposure error algorithm formula by comparing the image brightness with the target brightness to determine the exposure error of the image, providing a basis for exposure adjustment. The formula is fast in calculation and can evaluate the exposure error in real time. The advantage of the exposure time adjustment formula is that it can quickly adjust the exposure parameters according to the real-time exposure error, improve image quality, automatically optimize exposure parameters, reduce human intervention, and improve the automation and intelligence level of the system.
[0127] In step 4, after the images are aligned by the exposure control algorithm, multiple frames of images are fused. Image fusion includes weighted average fusion and noise suppression fusion.
[0128] Weighted average fusion is to average the pixel values of each frame according to its weight. The algorithm formula is:
[0129] ,
[0130] in, The pixel value of the fused image, is the pixel value of the i-th frame image, is the corresponding weight, N is the number of frames;
[0131] Noise suppression fusion suppresses noise by calculating the median of pixel values or using filters. The algorithm formula is:
[0132] ,
[0133] ,
[0134] in, is the filter weight.
[0135] The benefits of the weighted average fusion algorithm formula are that by taking the weighted average of multiple frames of images, the random noise in each frame can be effectively smoothed out, the signal-to-noise ratio of the image can be improved, and the stability and consistency of the image can be improved by fusing multiple frames of images, and the abnormal influence of a single frame of image can be reduced; the benefits of the noise suppression fusion median filter formula are that it can effectively remove salt and pepper noise and mutation noise, improve the overall quality of the image, and can well protect the edges and details of the image while denoising; weighted filtering can achieve a smooth transition of the image, avoid image distortion caused by a single pixel value mutation, and can flexibly control the smoothness of the image and the degree of detail retention.
[0136] In step 5, the specific implementation algorithm steps of the deep learning model are as follows:
[0137] Step 1: Image preprocessing Input image To standardize:
[0138] ,
[0139] Among them, μ and σ are the mean and standard deviation of the image;
[0140] The second step, the convolution layer is used to extract image features:
[0141] ,
[0142] in, is the feature map of layer l, and are the weights and biases of the lth layer, Represents the convolution operation;
[0143] The third step is to use the pooling layer to reduce the size of the feature map while retaining the features:
[0144] ,
[0145] in, Represents the maximum pooling operation;
[0146] Step 4: The image enhancement layer processes the features to generate an enhanced image:
[0147] ,
[0148] Where E is the enhanced image, and are the weights and biases of the enhancement layer, is the activation function of the output layer;
[0149] Step 5. During the training process, use the loss function to measure the difference between the model output and the target enhanced image:
[0150] ,
[0151] Where N is the total number of image pixels, is the i-th pixel value of the enhanced image, The i-th pixel value of the target enhanced image;
[0152] Step 6: Use the back propagation algorithm to update the network parameters W and b:
[0153] ,
[0154] in, is the learning rate.
[0155] The benefits of the image preprocessing algorithm formula are that through standardization, the scale difference of image data is reduced, making the data distribution more uniform, which helps to accelerate the training process of the neural network and improve the accuracy and robustness of the model; the convolution layer is used to extract image features. The benefits of the algorithm formula can effectively extract feature information such as edges and textures in the image, and provide rich feature representations for subsequent processing; the pooling layer is used to reduce the size of the feature map and retain the features. The benefits of the algorithm formula reduce the size of the feature map through dimensionality reduction, reduce the computational complexity, speed up the model's reasoning speed, reduce information loss, and improve the generalization ability of the model; the image enhancement layer processes the features and generates an enhanced image. The benefits of the algorithm formula fuse the extracted features to generate a high-quality enhanced image, improving the visual effect and information content of the image; the loss function is used to measure the difference between the model output and the target enhanced image. The benefits of the algorithm formula are used to measure the difference between the model output and the target enhanced image, provide a basis for model optimization, gradually reduce errors, and improve the accuracy of the model; the benefits of using the back propagation algorithm formula can automatically calculate the gradient of the loss function, update the model parameters, make the training process efficient and automated, gradually reduce losses, and improve the prediction accuracy and generalization ability of the model.
[0156] The algorithm in step 6 involves an adaptive optical enhancement system that combines image processing results and ambient light information to dynamically adjust the camera's optical component settings. The algorithm steps are as follows:
[0157] a. Obtain the image processed by the deep neural network model and analyze its details and brightness information;
[0158] b. Obtain the lighting conditions of the environment in real time;
[0159] c. Calculate the optical element parameters to be adjusted based on the image processing results and ambient light information;
[0160] d. Adjust the camera's optical settings;
[0161] e. After adjusting the optical settings, image acquisition can be performed again.
[0162] Image data processed by the deep neural network model can more accurately analyze image details and brightness information, provide high-precision input data, and help subsequent optical adjustments to better improve image quality;
[0163] Real-time acquisition of ambient lighting conditions enables the system to dynamically adapt to environmental changes, improves the stability and consistency of image acquisition, helps optimize exposure time and gain settings, and reduces the impact of lighting changes on image quality;
[0164] Based on the comprehensive analysis of image processing results and ambient light information, the optimal optical component parameters are calculated to ensure the accuracy of adjustment, which can achieve more comprehensive optimization, improve image quality, reduce human intervention, and improve the level of automation;
[0165] By adjusting optical components, such as aperture and focal length, the light collection efficiency can be optimized, noise can be reduced, image clarity and detail can be improved, manual operations can be reduced, and the automation and intelligence level of the system can be improved;
[0166] By acquiring images again, the effect of optical adjustment can be verified to ensure the validity of adjustment parameters. The system can further optimize adjustment parameters, perform multiple iterations, gradually improve image quality, and achieve closed-loop control.
[0167] The algorithm formula in the algorithm step in step 6 is as follows:
[0168] Get the image processed by the deep neural network model , calculate the average brightness of the image And the level of detail, its algorithm formula:
[0169] ,
[0170] in, is the i-th pixel value of the enhanced image, N is the total number of pixels in the image;
[0171] Based on the image processing results and ambient light information, the optical element parameters are calculated. The algorithm formula is:
[0172] ,
[0173] in, and To control the parameters, is the target brightness, is the target ambient light intensity;
[0174] ,
[0175] in, To control the parameters, is the target level of detail, It is the detail level, which can be calculated by image gradient. The algorithm formula of image gradient is:
[0176] ,
[0177] Adjust the aperture size of the optical element and focal length .
[0178] Calculate the average brightness and detail level of the image The algorithm formula is used to calculate the average brightness value of the enhanced image, which can evaluate the overall brightness level of the image and determine whether the optical elements need to be adjusted to optimize the exposure;
[0179] Detail level calculation formula The detail level calculation can be used to evaluate the clarity of the image and determine whether the focus and aperture settings need to be further optimized;
[0180] Calculating optical element parameters can effectively optimize exposure by adjusting the aperture size, ensuring that image brightness is within the target range and improving image quality;
[0181] Focus adjustment formula By adjusting the focal length, the system can adaptively optimize the clarity of the image to ensure that the details are expressed as expected;
[0182] Image gradient calculation Image gradient calculation can detect edges and details in the image, evaluate the clarity of the image, and provide a basis for focal length adjustment.
[0183] The algorithm in step 8 involves establishing a feedback mechanism to continuously optimize the automatic exposure control, image fusion algorithm, and deep learning model based on actual application effects and environmental changes. The following are the algorithm steps of the feedback mechanism:
[0184] a. Image quality assessment: assess the quality of processed images;
[0185] b. Error calculation: calculate the error between image quality and target quality;
[0186] c. Parameter adjustment: adjust the parameters of each algorithm module according to the error;
[0187] d. Model update: Update the deep learning model through online learning or regular retraining;
[0188] e. System iteration: re-process the image based on parameters and models.
[0189] Through real-time evaluation and error calculation, the system can quickly identify and correct problems in image processing to ensure continuous optimization of processing effects; in combination with environmental changes and actual application effects, the system can dynamically adjust parameters and models so that the system can flexibly adapt to various complex environments and maintain high-quality image output; through online learning and regular retraining, the system can continuously improve and upgrade itself to enhance its intelligence and automation level; closed-loop control and continuous iteration mechanisms ensure that the system can work stably in various environments and provide consistent high-quality images; automated feedback and optimization mechanisms reduce reliance on human intervention and improve the system's autonomous operation capabilities and ease of use.
[0190] The algorithm formula in the feedback mechanism algorithm step is as follows:
[0191] The peak signal-to-noise ratio and structural similarity index can be used to evaluate image quality. The algorithm formula is:
[0192] ,
[0193] Among them, is the maximum pixel value of the image , the mean square error is:
[0194] ,
[0195] Structural similarity index calculation formula:
[0196] ,
[0197] in, and is the average value of image x and y, and is the variance of images x and y, is the covariance of images x and y, and is the stability constant;
[0198] Calculating image quality Target image quality The error between:
[0199] ,
[0200] Adjust the exposure time t and gain g according to the image quality error:
[0201] ,
[0202] in, and is the control parameter.
[0203] Adjust the weight of multi-frame fusion according to the image quality error:
[0204] ,
[0205] in, is the control parameter.
[0206] Through PSNR and SSIM, the system can accurately evaluate image quality, quantify processing effects, provide data support for optimization, calculate image quality errors in real time, clarify system performance deviations, provide a basis for parameter adjustment and optimization, dynamically adjust exposure time, gain and fusion weight according to errors, automatically optimize image processing effects, and improve the response speed and intelligence level of the system. Through feedback mechanisms and closed-loop control, the system can continuously optimize various parameters and models to ensure high-quality image output in various environments.
[0207] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. A processing method for industrial camera acquisition, characterized in that: The steps include: Step 1: Start the industrial camera, initialize the basic parameters, enable the intelligent automatic exposure control system, and preliminarily set the exposure time and gain parameters; Step 2: Use the image analysis algorithm of the intelligent automatic exposure control system to perform exposure control and dynamically adjust the exposure parameters of the camera according to the initial lighting conditions of the environment; Step 3, continuously collecting multiple frames of low-light images in a short time; Step 4: Use an efficient image alignment algorithm to align multiple frames of images, and apply multi-frame information fusion technology to fuse the aligned multi-frame image data to generate a clear, high-quality image; Step 5: Input the fused image into the trained deep neural network model, so that the deep neural network model processes the input image according to the learned low-light image features; Step 6: Combining the image processing results and the ambient light information, the adaptive optical enhancement system is used to dynamically adjust the optical element settings of the camera. After the optical settings are adjusted, image acquisition can be performed again. Step 7: Output the processed high-quality image and store or transmit it to a downstream application system; Step 8: Establish a feedback mechanism to continuously optimize automatic exposure control, image fusion algorithm and deep learning model according to actual application effects and environmental changes; The intelligent automatic exposure control system is based on image analysis and machine learning technology to optimize the exposure parameters of industrial cameras in low-light environments. The system analyzes the captured image data in real time and dynamically adjusts the exposure time and gain settings; The intelligent automatic exposure control system comprises: The image acquisition module is responsible for capturing the initial image and providing real-time image data for analysis; The image analysis module uses image processing algorithms to analyze the brightness, contrast and detail features of the image in real time; The exposure control module adjusts the exposure time and gain parameters of the camera according to the image analysis results; The feedback mechanism continuously monitors image quality and adjusts exposure parameters to cope with changes in ambient light.
2. The processing method for industrial camera acquisition according to claim 1 is characterized in that: In the intelligent automatic exposure control system, the average brightness value of the image is calculated by the weighted average method, and the weighted average method formula is: , in, , , Represents the red, green, and blue components of the i-th pixel in the image, respectively, and N represents the total number of pixels in the image; In the intelligent automatic exposure control system, the exposure error is calculated by an exposure error evaluation function, and its algorithm formula is: , in, Image brightness, Target brightness; In the intelligent automatic exposure control system, the exposure time t and gain are dynamically adjusted according to the exposure error. , its algorithm formula is: , , in, and It is a control parameter that adjusts the system's response speed to exposure error.
3. The processing method for industrial camera acquisition according to claim 1, characterized in that: In step 4, after the images are aligned by the exposure control algorithm, multiple frames of images are fused, and the image fusion includes weighted average fusion and noise suppression fusion; The weighted average fusion is to perform weighted average on the pixel values of each frame image according to its weight, and its algorithm formula is: , in, The pixel value of the fused image, is the pixel value of the i-th frame image, is the corresponding weight, N is the number of frames; The noise suppression fusion suppresses noise by calculating the median of pixel values or using a filter. The algorithm formula is: , , in, is the filter weight.
4. The processing method for industrial camera acquisition according to claim 1, characterized in that: In step 5, the specific implementation algorithm steps of the deep learning model are as follows: Step 1: Image preprocessing Input image To standardize: , Among them, μ and σ are the mean and standard deviation of the image; The second step, the convolution layer is used to extract image features: , in, is the feature map of layer l, and are the weights and biases of the lth layer, Represents the convolution operation; The third step is to use the pooling layer to reduce the size of the feature map while retaining the features: , in, Represents the maximum pooling operation; Step 4: The image enhancement layer processes the features to generate an enhanced image: , Where E is the enhanced image, and are the weights and biases of the enhancement layer, is the activation function of the output layer; Step 5. During the training process, use the loss function to measure the difference between the model output and the target enhanced image: , Where N is the total number of image pixels, is the i-th pixel value of the enhanced image, The i-th pixel value of the target enhanced image; Step 6: Use the back propagation algorithm to update the network parameters W and b: , in, is the learning rate.
5. The processing method for industrial camera acquisition according to claim 1, characterized in that: The algorithm in step 6 involves an adaptive optical enhancement system, which dynamically adjusts the optical element settings of the camera in combination with the image processing results and the ambient light information. The algorithm steps are as follows: a. Obtain the image processed by the deep neural network model and analyze its details and brightness information; b. Obtain the lighting conditions of the environment in real time; c. Calculate the optical element parameters to be adjusted based on the image processing results and ambient light information; d. Adjust the camera's optical settings; e. After adjusting the optical settings, image acquisition can be performed again.
6. The processing method for industrial camera acquisition according to claim 5, characterized in that: The algorithm formula in the algorithm step in step 6 is as follows: Get the image processed by the deep neural network model , calculate the average brightness of the image And the level of detail, its algorithm formula: , in, is the i-th pixel value of the enhanced image, N is the total number of pixels in the image; Based on the image processing results and ambient light information, the optical element parameters are calculated. The algorithm formula is: , in, and To control the parameters, is the target brightness, is the target ambient light intensity; , in, To control the parameters, is the target level of detail, It is the detail level, which can be calculated by image gradient. The algorithm formula of image gradient is: , Adjust the aperture size of the optical element and focal length .
7. The processing method for industrial camera acquisition according to claim 1, characterized in that: The algorithm in step 8 involves establishing a feedback mechanism to continuously optimize the automatic exposure control, image fusion algorithm and deep learning model according to the actual application effect and environmental changes. The following are the algorithm steps of the feedback mechanism: a. Image quality assessment: assess the quality of processed images; b. Error calculation: calculate the error between image quality and target quality; c. Parameter adjustment: adjust the parameters of each algorithm module according to the error; d. Model update: Update the deep learning model through online learning or regular retraining; e. System iteration: re-process the image based on parameters and models.
8. The processing method for industrial camera acquisition according to claim 7, characterized in that: The algorithm formula in the feedback mechanism algorithm step is as follows: The peak signal-to-noise ratio and structural similarity index can be used to evaluate image quality. The algorithm formula is: , in, is the maximum pixel value of the image, The mean square error is: , Structural similarity index calculation formula: , in, and is the average value of image x and y, and is the variance of images x and y, is the covariance of images x and y, and is the stability constant; Calculating image quality Target image quality The error between: , Adjust the exposure time t and gain g according to the image quality error: , in, and is the control parameter, Adjust the weight of multi-frame fusion according to the image quality error: , in, is the control parameter.
Citation Information
Patent Citations
Photographic underexposure correction using a neural network
CN113170030A
Photographic Underexposure Correction Using A Neural Network
US20200092453A1
Automatic exposure method and apparatus, electronic device, and computer readable storage medium
WO2024183368A1