An image enhancement algorithm based on adaptive filtering
Through the image enhancement algorithm based on adaptive filtering, the problems of insufficient details, color distortion, and uneven brightness in low-quality underwater images are solved, and efficient image enhancement is achieved, improving clarity and contrast.
Patent Information
- Application Number
- CN202510236893.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-28
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2045-02-28
AI Technical Summary
The prior art has problems such as insufficient details, color distortion, and uneven brightness in the enhancement of low-quality underwater images.
The image enhancement algorithm based on adaptive filtering is used to evaluate the attenuation degree of each channel of the image, calculate the channel adjustment coefficient, adjust the pixel distribution, and combine the backscattered light and atmospheric scattering models to improve the contrast and details of the image.
It effectively solves the color shift problem of underwater images, improves the clarity and authenticity of the image, enhances contrast and detailed information, and meets the needs of visual applications.
Smart Images

Figure CN119741245B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of image enhancement, in particular to an image enhancement algorithm based on adaptive filtering. Background Art
[0002] Image enhancement also plays a vital role in the field of visual enhancement, especially the enhancement of low-quality underwater images. The lighting conditions in the underwater environment are complex, and the suspended matter and pigments in the water will cause image color distortion and reduced contrast, thus affecting the recognizability of objects. Low-quality underwater images will significantly affect multiple fields, including marine scientific research, environmental monitoring, underwater archaeology, diving activities, fishery management, and underwater robot operations, resulting in inaccurate information recognition, distorted ecological assessments, and reduced mission efficiency, thus hindering the understanding and protection of marine ecology.
[0003] To this end, researchers have studied low-quality image enhancement methods, and image enhancement technology has become increasingly important in the field of computer vision.
[0004] In general, methods for enhancing underwater low-quality images can be divided into three types: model-based methods, model-free methods, and deep learning-based methods.
[0005] Model-based methods usually establish a physical model of imaging by considering the degradation process of degraded images, and use manual priors or assumptions to invert the physical model to generate a clear image. These commonly used priors or assumptions include dark channel priors, super Laplace reflectance priors, adaptive dark pixel priors, illumination channel sparse priors, etc. However, complex scenes have different lighting conditions and attenuation characteristics, which makes these model-based methods often unstable when used for image restoration.
[0006] Model-free methods enhance the details, colors, and contrast of degraded images by correcting pixel distribution, including histogram correction methods and image fusion-based methods. For example, the minimum color loss principle is used to make the pixel distribution of each channel similar, and then a fusion framework is proposed to improve the contrast and details based on the maximum attenuation map; a contrast-corrected image and a detail-sharpened image are obtained from the input image, and then they are fused by relying on a multi-scale fusion strategy to produce a good result with high contrast and natural colors. These methods improve the image quality to a certain extent, but are prone to excessive or insufficient enhancement. Deep learning-based methods use powerful learning capabilities to improve the overall contrast and color based on large-scale image data. For example, researchers constructed a conditional generative adversarial network to learn the mapping relationship between degraded images and clear images, and collected a large number of real underwater images to train the network; proposed a reinforcement learning network for image enhancement, which selects a series of image enhancement operations and organizes them into an optimal sequence, thereby using sequential enhancement actions to produce enhanced images, etc. These deep learning-based methods often require a large number of images for network training, which is difficult for certain specific underwater scenes.
[0007] The above underwater image enhancement methods have limitations in the process of low-quality underwater image enhancement, such as insufficient details, color distortion, uneven brightness, etc.
[0008] Therefore, how to provide an image enhancement algorithm that effectively solves the problems of insufficient details, color distortion, and uneven brightness has become a technical problem that technicians in this field urgently need to solve. Summary of the invention
[0009] In view of this, the present invention provides an image enhancement algorithm based on adaptive filtering to solve the problems of unclear detail highlighting, low contrast, uneven brightness, color distortion, etc. in existing image enhancement methods for low-quality images. In order to achieve the above purpose, the present invention provides the following technical solutions:
[0010] An image enhancement algorithm based on adaptive filtering includes the following steps:
[0011] 11) Evaluate the attenuation degree of each channel of low-quality images;
[0012] 12) Using the attenuation degree of each channel of the low-quality image, calculate the channel adjustment coefficient used to adjust the pixel distribution of the low-quality image;
[0013] 13) Adjust the pixel distribution of the low-quality image through the channel adjustment coefficient to obtain a color-corrected image;
[0014] 14) Estimate the backscattered light of the color-corrected image;
[0015] 15) The backscattered light of the color-corrected image and the transmittance of the color-corrected image derived based on the dark channel prior theory are used in combination with the atmospheric scattering model to enhance the contrast and details of the color-corrected image.
[0016] Furthermore, the specific steps for evaluating the attenuation degree of each channel of the low-quality image are as follows:
[0017] 21) Calculate low quality images , and The sum of the pixel values of the channel. The specific formula is:
[0018] ,
[0019] in, represents the pixel channels of the image, and Represent the length and width of the image respectively, Represents a low-quality image at coordinates The pixel value at is the coordinate of the pixel point, Indicates the corresponding channel of the low-quality image The sum of the pixel values;
[0020] 22) Evaluate the attenuation degree of each channel of the low-quality image. The specific formula is:
[0021] ,
[0022] in, Used to evaluate the attenuation of each channel of low-quality images. , and Represent low quality images , and The sum of the pixel values of the channel.
[0023] Furthermore, the specific steps of calculating the channel adjustment coefficient for adjusting the pixel distribution of the low-quality image by using the attenuation degree of each channel of the low-quality image are as follows:
[0024] 31) Calculate the maximum attenuation of each channel of the low-quality image ;
[0025] 32) Calculate the channel adjustment coefficient used to adjust the image pixel distribution. The specific formula is:
[0026] ,
[0027] in, Indicates the corresponding channel The channel adjustment factor.
[0028] Furthermore, the pixel distribution of the low-quality image is adjusted by the channel adjustment coefficient to obtain a color-corrected image. The specific steps are as follows:
[0029] 41) Select the channel corresponding to the maximum attenuation degree of each channel of the low-quality image as the reference channel ;
[0030] 42) Adjust the pixel distribution of the low-quality image to obtain a color-corrected image. The specific formula is:
[0031] ,
[0032] in Represents a color-corrected image In coordinates The pixel value at Indicates the reference channel In coordinates The pixel value at .
[0033] Furthermore, the specific steps of estimating the backscattered light of the color-corrected image are:
[0034] 51) Number the four equal regions of the color-corrected image and represent them as , The values of are 1, 2, 3, and 4, representing the upper left area, lower left area, upper right area, and lower right area of the color-corrected image, respectively;
[0035] 52) Calculate the brightness standard, contrast standard and attenuation difference standard of the four-divided areas of the color-corrected image respectively. The specific calculation formula is as follows:
[0036] ,
[0037] ,
[0038] ,
[0039] in, Indicates the color-corrected image in channel No. In the sub-area The pixel value at the coordinate, is the brightness standard, is the contrast standard, is the attenuation difference standard, represents the averaging function, and They represent the maximum value function and the minimum value function respectively;
[0040] 53) Using color correction to correct image brightness standards , contrast standard and attenuation difference standard Construct a scoring formula for backscattered light. The scoring formula is as follows:
[0041] ,
[0042] in represents the backscattered light score of the color-corrected image;
[0043] 54) Select backscatter score The corresponding four-divided area is the effective backscattering area, and the maximum pixel value in the effective backscattering area is selected as the estimated value of the backscattered light of the color-corrected image. .
[0044] Furthermore, the backscattered light of the color-corrected image and the transmittance of the color-corrected image derived based on the dark channel prior theory are used in combination with the atmospheric scattering model to improve the contrast and details of the color-corrected image. The specific steps are as follows:
[0045] 61) The transmittance is calculated using the dark channel priori theory. The specific formula is:
[0046] ,
[0047] in express Pixel blocks of size Represents the color-corrected image at coordinates The pixel value at represents the transmittance, An estimate of the backscattered light representing the color-corrected image;
[0048] 62) Calculate the atmospheric scattering model. The specific formula is:
[0049] ,
[0050] in, represents a color-corrected image with rich contrast and detail, represents the image transmittance, An estimate of the backscattered light representing the color-corrected image;
[0051] 63) Estimation of backscattered light combined with color-corrected images and transmittance Compute contrast- and detail-rich color-corrected images , the specific formula is:
[0052] .
[0053] Beneficial effects: The present invention proposes an image enhancement algorithm based on adaptive filtering, aiming to solve the problems of color deviation and contrast loss in underwater low-quality images.
[0054] Adaptive color correction uses the total attenuation value of each channel to determine , and The attenuation degree of each channel of the low-quality image is calculated, and the channel adjustment coefficient used to adjust the pixel distribution of the low-quality image is calculated by using the attenuation degree of each channel of the low-quality image. Finally, the pixel distribution of the low-quality image is adjusted by the channel adjustment coefficient to obtain a color-corrected image. The underwater low-quality image processed by this step effectively solves the problem of underwater image color deviation, improves the clarity and authenticity of the image, and helps observers better understand the underwater environment. Make the image more artistic and visually attractive, enhance the viewing experience; help protect the natural colors of underwater organisms, maintain the original beauty of the environment, and promote people's awareness of protecting the marine environment; make it easier for observers to identify objects and landscapes, which is beneficial to the exploration and research of marine resources.
[0055] The optimized backscattered light fully considers the brightness standard, contrast standard and attenuation difference standard of the background area, and constructs a scoring formula for backscattered light, making the calculation of backscattered light more accurate. The image processing part effectively improves the contrast of underwater images, enhances the visibility of images, improves the capture of detail information, improves image quality and enhances the vividness of image content, thereby better meeting the needs of visual applications such as underwater detection, underwater photography and scientific research. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] FIG1 is a schematic diagram of a flow chart of an image enhancement algorithm based on adaptive filtering according to an embodiment of the present invention;
[0057] Figure 2a is a low-quality original underwater image;
[0058] Fig. 2b is a color enhanced image obtained after color correction in Fig. 2a;
[0059] Figure 2c is the final image of Figure 2a after color correction and contrast enhancement using optimized backscattered light. DETAILED DESCRIPTION
[0060] In order to have a further understanding and recognition of the structural features and the effects achieved by the present invention, a preferred embodiment and accompanying drawings are used for detailed description as follows:
[0061] As shown in FIG1 , an image enhancement algorithm based on adaptive filtering according to the present invention comprises the following steps:
[0062] The first step is to evaluate the attenuation of each channel of the low-quality image. The steps are as follows:
[0063] (1) As shown in Figure 2a, low-quality underwater images often have color deviation and low contrast. , and The sum of the pixel values of the channel. The specific formula is:
[0064] ,
[0065] in, represents the pixel channels of the image, and Represent the length and width of the image respectively, Represents a low-quality image at coordinates The pixel value at is the coordinate of the pixel point, Indicates the corresponding channel of the low-quality image The sum of the pixel values;
[0066] (2) Evaluate the attenuation degree of each channel of the low-quality image. The specific formula is:
[0067] ,
[0068] in, Used to evaluate the attenuation of each channel of low-quality images. , and Represent low quality images , and The sum of the pixel values of the channel.
[0069] The second step is to use the attenuation degree of each channel of the low-quality image to calculate the channel adjustment coefficient used to adjust the pixel distribution of the low-quality image. The specific steps are:
[0070] (1) Calculate the maximum attenuation of each channel of the low-quality image ;
[0071] (2) Calculate the channel adjustment coefficient used to adjust the image pixel distribution. The specific formula is:
[0072] ,
[0073] in, Indicates the corresponding channel The channel adjustment factor.
[0074] The third step is to adjust the pixel distribution of the low-quality image through the channel adjustment coefficient to obtain a color-corrected image. The specific steps are:
[0075] (1) Select the channel corresponding to the maximum attenuation degree of each channel of the low-quality image as the reference channel ;
[0076] (2) Adjust the pixel distribution of the low-quality image to obtain a color-corrected image. The specific formula is:
[0077] ,
[0078] in Represents a color-corrected image In coordinates The pixel value at Indicates the reference channel In coordinates As shown in Figure 2b, the color-corrected image has a more natural appearance without additional artifacts and over-enhancement or under-enhancement.
[0079] The fourth step is to estimate the backscattered light of the color-corrected image. The specific steps are:
[0080] (1) Number the four equal regions of the color-corrected image and express them as , The values of are 1, 2, 3, and 4, representing the upper left area, lower left area, upper right area, and lower right area of the color-corrected image, respectively;
[0081] (2) Calculate the brightness standard, contrast standard, and attenuation difference standard of the four-divided areas of the color-corrected image respectively. The specific calculation formulas are as follows:
[0082] ,
[0083] ,
[0084] ,
[0085] in, Indicates the color-corrected image in channel No. In the sub-area The pixel value at the coordinate, is the brightness standard, is the contrast standard, is the attenuation difference standard, represents the averaging function, and They represent the maximum value function and the minimum value function respectively;
[0086] (3) Using color correction to correct image brightness standards , contrast standard and attenuation difference standard Construct a scoring formula for backscattered light. The scoring formula is as follows:
[0087] ,
[0088] in represents the backscattered light score of the color-corrected image;
[0089] (4) Select backscattered light score The corresponding four-divided area is the effective backscattering area, and the maximum pixel value in the effective backscattering area is selected as the estimated value of the backscattered light of the color-corrected image. .
[0090] The fifth step is to use the backscattered light of the color-corrected image and the transmittance of the color-corrected image derived based on the dark channel prior theory, combined with the atmospheric scattering model to improve the contrast and details of the color-corrected image. The specific steps are as follows:
[0091] (1) The transmittance is calculated using the dark channel prior theory. The specific formula is:
[0092] ,
[0093] in express Pixel blocks of size Represents the color-corrected image at coordinates The pixel value at represents the transmittance, An estimate of the backscattered light representing the color-corrected image;
[0094] (2) Calculate the atmospheric scattering model. The specific formula is:
[0095] ,
[0096] in, represents a color-corrected image with rich contrast and detail, represents the image transmittance, An estimate of the backscattered light representing the color-corrected image;
[0097] (3) Estimation of backscattered light combined with color-corrected image and transmittance Compute contrast- and detail-rich color-corrected images , the specific formula is:
[0098] .
[0099] As shown in Figure 2c, the color-corrected image has a clearer appearance after being enriched in contrast and details.
[0100] An image enhancement algorithm based on adaptive filtering proposed by this method significantly improves the visual quality of underwater images, including contrast, clarity and color reproduction, making underwater scenes more realistic and easy to observe.
[0101] Secondly, this method can effectively cope with complex environments such as low light and turbid water, providing more reliable image support for underwater detection, marine ecological research, archaeology and other fields. In addition, its efficient enhancement capability helps promote the real-time application of underwater robots and automation systems, and improve work efficiency and safety.
[0102] The above shows and describes the basic principles, main features and advantages of the present invention. The present invention is not limited by the above embodiments. The above embodiments and descriptions only describe the principles of the present invention. The present invention may be subject to various changes and improvements without departing from the spirit and scope of the present invention. These changes and improvements fall within the scope of the present invention to be protected. The scope of protection claimed by the present invention is defined by the attached claims and their equivalents.
Claims
1. An image enhancement algorithm based on adaptive filtering, characterized in that: The following steps are involved: 11) Evaluating low-quality images , and The attenuation level of the channel; 12) Based on the low quality image , and The attenuation degree of the channel, and the channel adjustment coefficient used to adjust the pixel distribution of the low-quality image are calculated; 13) adjusting the pixel distribution of the low-quality image based on the channel adjustment coefficient to obtain a color-corrected image; 14) Number the four equal regions of the color-corrected image and represent them as , The values of are 1, 2, 3, and 4, representing the upper left area, lower left area, upper right area, and lower right area of the color-corrected image, respectively; 15) Calculate the brightness standard, contrast standard and attenuation difference standard of the four divided areas respectively. The specific calculation formula is as follows: , , , in, Indicates the color-corrected image in channel No. In the sub-area The pixel value at the coordinate, is the brightness standard, is the contrast standard, is the attenuation difference standard, represents the averaging function, and They represent the maximum value function and the minimum value function respectively; 16) Based on the color-corrected image brightness standard, contrast standard and attenuation difference standard, a scoring formula for backscattered light is constructed. The specific scoring formula is: , in represents the backscattered light score of the color-corrected image; 17) Select the backscattered light score of the color-corrected image The corresponding four-divided area is the effective backscattering area, and the maximum pixel value in the effective backscattering area is selected as the estimated value of the backscattered light of the color-corrected image. ; 18) Based on the backscattered light of the color-corrected image and the transmittance of the color-corrected image derived based on the dark channel prior theory, the contrast and details of the color-corrected image are improved in combination with an atmospheric scattering model.
2. The image enhancement algorithm based on adaptive filtering according to claim 1, characterized in that: Evaluating low quality images , and The attenuation degree of the channel, the specific steps are: 21) Calculate low quality images , and The sum of the pixel values of the channel. The specific formula is: , in, represents the pixel channels of the image, and Represent the length and width of the image respectively, Represents a low-quality image at coordinates The pixel value at is the coordinate of the pixel point, Indicates the corresponding channel of the low-quality image The sum of the pixel values; 22) Evaluate the attenuation degree of each channel of the low-quality image. The specific formula is: , in, Used to evaluate the attenuation of each channel of low-quality images. , and Represent low quality images , and The sum of the pixel values of the channel.
3. The image enhancement algorithm based on adaptive filtering according to claim 2, characterized in that: Based on the attenuation degree of each channel of the low-quality image, a channel adjustment coefficient for adjusting the pixel distribution of the low-quality image is calculated, and the specific steps are: 31) Calculate the maximum attenuation of each channel of the low-quality image ; 32) Calculate the channel adjustment coefficient used to adjust the image pixel distribution. The specific formula is: , in, Indicates the corresponding channel The channel adjustment factor.
4. The image enhancement algorithm based on adaptive filtering according to claim 3, characterized in that: The pixel distribution of the low-quality image is adjusted based on the channel adjustment coefficient to obtain a color-corrected image. The specific steps are as follows: 41) Select the channel corresponding to the maximum attenuation degree of each channel of the low-quality image as the reference channel ; 42) Adjust the pixel distribution of the low-quality image to obtain a color-corrected image. The specific formula is: , in Represents a color-corrected image In coordinates The pixel value at Indicates the reference channel In coordinates The pixel value at .
5. The image enhancement algorithm based on adaptive filtering according to claim 1, characterized in that: The backscattered light of the color-corrected image and the transmittance of the color-corrected image derived based on the dark channel prior theory are used in combination with the atmospheric scattering model to improve the contrast and details of the color-corrected image. The specific steps are as follows: 51) The transmittance is calculated using the dark channel priori theory. The specific formula is: , in express Pixel blocks of size Represents the color-corrected image at coordinates The pixel value at represents the transmittance, An estimate of the backscattered light representing the color-corrected image; 52) Calculate the atmospheric scattering model. The specific formula is: , in, represents a color-corrected image with rich contrast and detail, represents the image transmittance, An estimate of the backscattered light representing the color-corrected image; 53) Estimation of backscattered light combined with color-corrected images and transmittance Compute contrast- and detail-rich color-corrected images , the specific formula is: 。
Citation Information
Patent Citations
Improved Retinex Image Enhancement Algorithm for Explicit Expression of Multi-scale and Histogram Truncation
AU2020104021A4
Underwater image restoration method based on improved dark channel
CN108765342A