An image enhancement method that can simultaneously enhance the clarity of high-illumination and low-illumination areas

By obtaining the illumination and reflection component estimation maps of the original and inverted images, and combining the image decomposition model and pyramid decomposition technology, the overexposure and color distortion problems caused by low-brightness area enhancement in the existing technology are solved, and efficient image enhancement effects are achieved.

CN116228553BActive Publication Date: 2025-09-19XIDIAN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211619685.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-15
Publication Date
2025-09-19
Estimated Expiration
2042-12-15

AI Technical Summary

Technical Problem

While existing image enhancement technologies improve the clarity of low-brightness areas, they can easily lead to overexposure, decreased contrast and color saturation in reasonably exposed areas. Traditional methods also have poor adaptability, while machine learning methods rely on big data and have poor cross-device migration capabilities.

Method used

By obtaining the initial illumination component estimation map and image smoothing weight of the original image and the inverted image, the objective function is constructed. The actual illumination and reflection component estimation maps are obtained by combining the image decomposition model. Image fusion is performed, and the image structure information is retained using Laplacian pyramid and Gaussian pyramid decomposition. Finally, the color cast is corrected using the Gray World algorithm.

Benefits of technology

It significantly improves the overall brightness and light distribution quality of low-light images, overcomes the problems of overexposure and color distortion, maintains high interpretability and low complexity, and enhances the visual and data value of the image.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116228553B_ABST
    Figure CN116228553B_ABST
Patent Text Reader

Abstract

The present invention discloses an image enhancement method that can simultaneously enhance the clarity of high- and low-illuminance areas, comprising the following steps: obtaining an original image to be processed and an inverted image of the original image; obtaining initial illumination component estimation maps and image smoothing weights for the original image and the inverted image, respectively; constructing an objective function for obtaining a final illumination component estimation, and obtaining actual illumination component estimation maps for the original image and the inverted image, respectively; obtaining initial reflection component estimation maps for the original image and the inverted image, and obtaining noise-free reflection component estimation maps for the original image and the inverted image; obtaining enhanced images of the original image and the inverted image based on the noise-free reflection component estimation map and the actual illumination component estimation map; and fusing the original image, the enhanced images of the original image, and the inverted image to obtain a fused image. The image enhancement method of the present invention can significantly improve the overall brightness of low-light images and the overall illumination distribution quality of images with uneven illumination.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of image processing technology, and specifically relates to an image enhancement method that can simultaneously enhance the clarity of high-illuminance and low-illuminance areas, so as to solve the problems of low image contrast, underexposure, overexposure, noise, and color cast after image enhancement. Background Art

[0002] There are two main approaches to existing image enhancement technology. One is the traditional approach, which designs models based on physical facts and a priori assumptions. This approach typically uses methods such as histograms, filters, and dehazing models, as well as methods based on image decomposition theory. The other is the machine learning approach, which uses large amounts of data for model training.

[0003] In the traditional route, the histogram method mainly solves the problem of excessive concentration of image brightness distribution, which leads to too small contrast difference between pixels; the filtering method mainly regards the illumination information as a low-frequency component, and this method improves the low-frequency signal distribution of the image; the defogging model method is based on the similarity in brightness distribution between low-light images and foggy images, and uses the atmospheric scattering model to improve the brightness distribution of low-light images. The method based on image decomposition theory is to extract the illumination information and reflection information from the image, and then recombine the improved illumination components and reflection information to achieve the purpose of image enhancement. This method is similar to some steps of the present invention, but it is incomplete and has limitations. The present invention performs multiple decompositions and multi-source fusion on images with unreasonable illumination to achieve the effect of simultaneously enhancing the clarity of high-illumination and low-illumination areas.

[0004] Machine learning requires the creation of large amounts of training data in advance to optimize network parameters. Its effectiveness depends on the data features contained in the training data, and its implementation requires the computing power of a graphics processing unit (GPU).

[0005] Traditional approaches, such as histogram-based methods, often only consider the overall grayscale distribution without taking into account image structure and color characteristics. Consequently, their enhancement effects are limited, their adaptability is poor, and they are prone to introducing noise and color distortion. Filtering methods are more sensitive to parameter selection and can easily destroy image structural information. Dehazing models lack interpretability and are prone to over-enhancement. Methods based solely on Retinex theory are prone to amplifying noise and over-enhancement during processing. Machine learning methods can achieve good results, but the models are often large and rely on high-quality datasets. They also have poor cross-device transferability and interpretability.

[0006] In particular, the current common dark image enhancement method, while improving the clarity of low-brightness areas, over-enhances the reasonably exposed areas in the image, causing the reasonably exposed areas to appear overexposed after enhancement, with a decrease in contrast and color saturation.

[0007] Therefore, to address the problem of insufficient image clarity caused by low light and a wide brightness range, as well as the shortcomings of existing technologies for this problem, the present invention provides an image processing method, electronic device, and storage medium that can simultaneously enhance clarity in both high and low illumination areas. This method addresses issues such as low image contrast, underexposure, overexposure, noise, and color cast after image enhancement. Summary of the Invention

[0008] In order to solve the problem of insufficient image clarity caused by insufficient illumination intensity or an excessively wide illumination range, such as dark or overexposed images, the present invention provides an image enhancement method that can simultaneously enhance the clarity of both high and low illumination areas. The technical problem to be solved by the present invention is achieved through the following technical solutions:

[0009] The present invention provides an image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas, comprising:

[0010] S1: Acquire an original image to be processed and an inverted image of the original image;

[0011] S2: Obtain the initial illumination component estimation map and image smoothing weight of the original image and the inverted image respectively;

[0012] S3: construct an objective function for obtaining the final illumination component estimation, using the initial illumination component estimation maps of the original image and the inverted image as initial inputs, respectively, to obtain the actual illumination component estimation maps of the original image and the inverted image;

[0013] S4: obtaining initial reflection component estimation maps of the original image and the inverted image according to the image decomposition model and calculating noise-free reflection component estimation maps of the original image and the inverted image;

[0014] S5: Obtaining enhanced images of the original image and the inverted image respectively according to the noise-free reflection component estimation map and the actual illumination component estimation map;

[0015] S6: Fusing the original image, the enhanced image of the original image, and the enhanced image of the inverted image to obtain a fused image.

[0016] In one embodiment of the present invention, the S2 includes:

[0017] S2.1: Performing initial illumination estimation on the original image and the inverted image respectively to obtain initial illumination component estimation maps of the original image and the inverted image;

[0018] S2.2: Obtain the original image smoothing weight and the inverted image smoothing weight according to the initial illumination component estimation maps of the original image and the inverted image respectively.

[0019] In one embodiment of the present invention, the objective function is:

[0020]

[0021] Where T represents the actual illumination component estimation map of the original image or the inverted image, Represents the initial illumination component estimation map of the original image or inverted image, W T represents the smoothing weight of the original image or the inverted image, α represents the regularization parameter, which is used to adjust the smoothing strength. represents the gradient matrix of T.

[0022] In one embodiment of the present invention, the S4 includes:

[0023] S4.1: Decomposition Model Based on Images Variations Calculate the initial reflection component estimation map of the original image and the inverted image, where L represents the normalized original image or inverted image, Represents the estimated value of the reflection component of the original image or the inverted image, The symbol represents pixel-by-pixel multiplication;

[0024] S4.2: Calculate the denoising weight W of the original image’s reflection component based on the initial reflection component estimation map of the original image R ;

[0025] S4.3: Iteratively calculate the noise-free reflection component estimation image of the original image using the reflection component denoising weights combined with the reflection component denoising model, wherein the reflection component denoising model is:

[0026]

[0027] in, Indicates the calculation of F norm, |·|1 indicates the calculation of L1 norm;

[0028] S4.4: Use the initial reflection component estimation map of the inverted image as the noise-free reflection component estimation map of the inverted image.

[0029] In one embodiment of the present invention, the S5 includes:

[0030] S5.1: Perform gamma transformation T′ on the actual illumination component estimation map of the original image and the inverted image. γ, obtain the illumination component estimation map after transformation adjustment of the original image and the inverted image, where T′ represents the illumination component estimation map after transformation adjustment, and γ is the coefficient of gamma transformation;

[0031] S5.2: Decomposition Model Based on Images Multiply the noise-free reflection component estimation map and the adjusted illumination component estimation map pixel by pixel to obtain the enhanced images of the original image and the inverted image respectively

[0032] In one embodiment of the present invention, the S6 includes:

[0033] S6.1: Design a fusion weight map based on the contrast, saturation, and exposure of the image, using pixels as the unit:

[0034]

[0035] in, k (), S k (), E k () is the contrast weight value, saturation weight value and exposure weight value of the kth image to be fused at point x; w c , w S , w E denote the weight coefficients corresponding to contrast, saturation, and exposure respectively; x denotes a point in the current image space, and the image to be fused includes the original image, the enhanced image of the original image, and the enhanced image of the inverted image;

[0036] S6.2: Normalizing the fusion weight map to obtain a normalized fusion weight map;

[0037] S6.3: Convert each to-be-fused image into a Laplacian pyramid image group of the to-be-fused images using Laplacian pyramid decomposition, preserving edge texture information in the to-be-fused images. Simultaneously, convert the obtained normalized fusion weight images corresponding to each to-be-fused image into a Gaussian pyramid weight image group using Gaussian pyramid decomposition, preserving the main structural information of the to-be-fused images.

[0038] S6.4: Linearly combine the Laplacian pyramid images of the current layer corresponding to the image group to be fused using the Gaussian pyramid images corresponding to the normalized fusion weight images to obtain a weighted Laplacian pyramid.

[0039] S6.5: The weighted Laplacian pyramid image of the fused image is upsampled and filtered to perform image pyramid reconstruction to obtain a final fused image.

[0040] In one embodiment of the present invention, the S6.1 includes:

[0041] S6.11: Obtain contrast weight maps for the original image, the enhanced image of the original image, and the enhanced image of the inverted image, where the contrast weight is expressed as:

[0042]

[0043] Among them, L k () represents the value of point x in the image space of the kth image to be fused, represents the sobel operator in the horizontal direction, Represents the Sobel operator in the vertical direction;

[0044] S6.12: After constructing the contrast weight map, the image to be fused is subjected to bilateral filtering. After the bilateral filtering, the image is noise-free while retaining the structural edge information of the image to be fused.

[0045] S6.13: Construct a saturation weight map of the image to be fused using the variances of the three channels of the image to be fused after bilateral processing. The expression for the saturation weight is:

[0046]

[0047] Among them, R′ k (), G′ k (), B′ k () respectively represent the pixel values ​​at the midpoint x of the three color channels B, G, and B in the image space after the kth image to be fused is processed by bilateral filtering, and Var() represents the variance;

[0048] S6.14: Obtain an exposure weight map of the image to be fused, where the expression of the exposure weight is:

[0049]

[0050] Among them, σ 2 is the variance;

[0051] S6.15: Obtain the fusion weight map by the contrast, saturation, and exposure of the image to be fused:

[0052]

[0053] in, k (), S k (), E k () is the contrast weight value, saturation weight value and exposure weight value of the kth image to be fused at point x; w c , w S , w Erepresent weight coefficients corresponding to contrast, saturation and exposure respectively; x represents a point in the current image space, and the images to be fused include the original image, the enhanced image of the original image and the enhanced image of the inverted image.

[0054] In one embodiment of the present invention, the image enhancement method further includes:

[0055] S7: Use the Gray World algorithm or White Patch white balance technology to correct the color cast of the fused image.

[0056] Compared with the prior art, the present invention has the following beneficial effects:

[0057] The image enhancement method of the present invention can significantly improve the overall brightness of low-light images and the overall illumination distribution quality of images with uneven illumination. It has the effect of enhancing and clarifying different brightness areas in the image, effectively overcoming the problems of overexposure, contrast and color saturation reduction in the bright parts of the image after other technologies enhance the dark image. At the same time, for the case of color distortion, a series of low-complexity and effective color cast correction algorithms are used to eliminate color deviation. The overall implementation method of the present invention can achieve a more significant enhancement effect while maintaining high interpretability and low complexity, effectively improving the visual value and data value of low-light images and images with uneven illumination distribution. The present invention will be further described in detail below with reference to the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] Figure 1 This is a flow chart of an image enhancement method for simultaneously enhancing the clarity of high-illumination and low-illumination areas, provided by an embodiment of the present invention;

[0059] Figure 2 is an original image provided by an embodiment of the present invention;

[0060] Figure 3 yes Figure 2 The inverse image of the original image shown;

[0061] Figure 4 This is an enhanced image fused using the image enhancement method according to an embodiment of the present invention. DETAILED DESCRIPTION

[0062] In order to further illustrate the technical means and effects adopted by the present invention to achieve the predetermined purpose of the invention, the following is a detailed description of an image enhancement method proposed by the present invention that can simultaneously enhance the clarity of high-illuminance and low-illuminance areas in combination with the accompanying drawings and specific implementation methods.

[0063] The aforementioned and other technical contents, features, and effects of the present invention are clearly presented in the following detailed description of the specific embodiments in conjunction with the accompanying drawings. Through the description of the specific embodiments, a deeper and more specific understanding of the technical means and effects adopted by the present invention to achieve the intended purpose can be obtained. However, the accompanying drawings are provided for reference and illustration purposes only and are not intended to limit the technical solutions of the present invention.

[0064] It should be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations are intended to cover non-exclusive inclusion, such that an article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of additional identical elements in the article or device comprising the element.

[0065] Example 1

[0066] See Figure 1 , Figure 1 1 is a flow chart of an image enhancement method for simultaneously enhancing the clarity of high-illumination and low-illumination areas, provided by an embodiment of the present invention. The image enhancement method includes:

[0067] S1: Acquire an original image to be processed and an inverted image of the original image.

[0068] Specifically, an original image I to be processed is read, and the original image is normalized to obtain a normalized image I', and then an inverted image of the original image is obtained by 1-I'.

[0069] S2: Obtain the initial illumination component estimation map and image smoothing weight of the original image and the inverted image respectively.

[0070] In this embodiment, step S2 includes:

[0071] S2.1: Perform initial illumination estimation on the original image and the inverted image respectively to obtain initial illumination component estimation images of the original image and the inverted image.

[0072] Specifically, based on empirical assumptions, the illumination should not be less than the value of any of the three color channels in the original image. Therefore, the maximum value of the three channels in the original image and the inverted image is extracted as the initial illumination component:

[0073]

[0074] Where L represents the normalized original image or the inverted image. The initial illumination component estimation map of the original image and the initial illumination component estimation map of the inverted image can be obtained using the above formula (1).

[0075] S2.2: Obtain the original image smoothing weight and the inverted image smoothing weight according to the initial illumination component estimation maps of the original image and the inverted image respectively.

[0076] It should be noted that there are multiple strategies to choose from for image smoothing weights. Different strategies will bring different effects. Some more intuitive strategies include but are not limited to:

[0077] (1) Directly set the weight matrix to 1, which is the most basic TV-L2 optimization.

[0078] (2) Another more reasonable image smoothing weight scheme is to use the gradient of illumination as the weight. The specific expression is:

[0079]

[0080] Among them, d∈{h,v}, h,v represent the horizontal direction and vertical direction respectively, Represents the gradient operator. ∈ represents a minimum quantity that prevents the denominator from being 0. Represents the value at point x in the initial illumination component estimation image. The above formula (2) can be used to obtain the original image smoothing weight and the inverted image smoothing weight.

[0081] In practical applications, the smoothing weight strategy used in the embodiment of the present invention should be designed according to image enhancement requirements or selected from existing solutions.

[0082] S3: Construct an objective function for obtaining the final illumination component estimation, use the initial illumination component estimation maps of the original image and the inverted image as initial inputs, and obtain the final illumination component estimation maps of the original image and the inverted image.

[0083] Specifically, an optimization method such as the steepest descent method or the preconditioned conjugate gradient method is used to iteratively calculate the actual illumination component estimation map of the original image and the actual illumination component estimation map of the inverted image. The objective function should be in the following form:

[0084]

[0085] Where T represents the actual illumination component estimation map of the original image or the inverted image, Represents the initial illumination component estimation map of the original image or inverted image, W T represents the smoothing weight of the original image or the inverted image, α represents the regularization parameter, which is used to adjust the smoothing strength. represents the trapezoidal matrix of T, represents the calculation of the F norm, and |·|1 represents the calculation of the L1 norm.

[0086] S4: Obtain the reflection component estimation map of the original image and the inverted image according to the image decomposition model.

[0087] Specifically, step S4 of this embodiment includes:

[0088] S4.1: Decomposition Model Based on Images Variations Calculate the initial reflection component estimation map of the original image and the inverted image, where L represents the normalized original image or inverted image, and R represents the reflection component of the original image or inverted image. Represents the estimated value of the reflection component of the original image or the inverted image, The symbol represents pixel-by-pixel multiplication. In this context represents the image L divided pixel by pixel by the illumination component estimate T.

[0089] S4.2: Calculate the denoising weight W of the original image’s reflection component based on the initial reflection component estimation map of the original image R This weight should be smaller at the main edges of the image, i.e., in areas with larger gradients. It should also be larger in areas with potential noise. Like the image smoothing weight, the reflectance denoising weight should also be designed by the operator based on image enhancement requirements.

[0090] S4.3: Use the reflection component denoising weights in combination with the reflection component denoising model to iteratively calculate the noise-free reflection component estimate of the original image. The reflection component denoising model should take the following form:

[0091]

[0092] Since the noise of the inverted image is small and can be ignored, the initial reflection component estimation map of the inverted image is used as the noise-free reflection component estimation map of the inverted image.

[0093] S5: Obtain enhanced images of the original image and the inverted image respectively according to the noise-free reflection component estimation map and the actual illumination component estimation map.

[0094] S5 of this embodiment specifically includes:

[0095] S5.1: Perform gamma transformation T′ on the actual illumination component estimation map of the original image and the inverted image. γ , the adjusted illumination component estimation maps of the original image and the inverted image are obtained, where T′ represents the illumination component estimation map after transformation adjustment, and γ is the coefficient of gamma transformation, which is usually taken as 0.7-0.8 according to practical experience.

[0096] S5.2: Decomposition Model Based on Images Multiply the noise-free reflection component estimation map and the adjusted illumination component estimation map pixel by pixel to obtain the enhanced images of the original image and the inverted image respectively

[0097] S6: Fusing the original image, the enhanced image of the original image, and the enhanced image of the inverted image to obtain a fused image.

[0098] Specifically, the original image, the enhanced image of the original image, and the enhanced image of the inverted image are fused so that the fusion result preserves as much structural detail as possible while ensuring the enhanced image. Furthermore, this embodiment pre-processes the image to be fused using existing double-sideband filtering techniques before calculating image saturation and exposure to eliminate the effects of noise on the enhanced image. In this embodiment, image fusion utilizes a multi-scale fusion technique based on pyramid decomposition.

[0099] Specifically, step S6 of this embodiment includes:

[0100] S6.1: Based on the image enhancement requirements, design a fusion weight map using the contrast, saturation, and exposure characteristics of the images to be fused (the original image, the enhanced image of the original image, and the enhanced image of the inverted image) in pixel units. Specifically, the fusion weights should take the following form:

[0101]

[0102] Among them, C k (x), S k (x), E k (x) is the contrast weight value, saturation weight value and exposure weight value of the k-th image to be fused at point x; w c , w S , w E represent weight coefficients corresponding to contrast, saturation and exposure respectively; x represents a point in the current image space, and the images to be fused include the original image, the enhanced image of the original image and the enhanced image of the inverted image.

[0103] Furthermore, it is necessary to obtain contrast weight maps of the original image, the enhanced image of the original image, and the enhanced image of the inverted image.

[0104] When constructing the contrast weight map, we first extract the edge texture structure gradient information in the image to be fused using the Sobel filter method. Then, we construct the contrast weight map of the image to be fused based on this gradient information. Pixels with larger gradients are given larger fusion weights so that the fused image better preserves the edge structure information of the image to be fused. Specifically, the contrast weight should take the following form:

[0105]

[0106] Among them, L k () represents the value of point x in the image space of the kth image to be fused, represents the sobel operator in the horizontal direction, Represents the Sobel operator in the vertical direction.

[0107] According to the above formula (6), the contrast of each pixel in the original image, the enhanced image of the original image, and the enhanced image of the inverted image can be obtained, thereby obtaining the contrast weight maps of the original image, the enhanced image of the original image, and the enhanced image of the inverted image.

[0108] Next, after constructing the contrast weight map, to eliminate the effects of noise on the fused image, the image to be fused is first subjected to bilateral filtering. This filtering eliminates noise while preserving the structural edge information of the image to be fused. Using this filtered image in subsequent image fusion processes can minimize the effects of noise on the final fused image. The saturation and exposure weight maps of the image to be fused are then derived from the bilaterally filtered source images, resulting in more effective saturation and exposure weight maps.

[0109] In the process of constructing the saturation weight map, the variance of the three channels of the image to be fused after bilateral processing is used to construct the saturation weight map of the image. When the image is overexposed or underexposed, the image appears close to black or white. Therefore, pixels with high saturation are given a higher fusion weight. Specifically, the saturation weight should take the following form:

[0110]

[0111] Among them, R′ k (), G′ k (), B′ k () represent the pixel values ​​at the midpoint x of the three color channels R, G, and B in the image space after the kth image to be fused is processed by bilateral filtering, and Var() represents the variance.

[0112] When constructing the exposure weight map, in the normalized image, the closer the pixel value is to 0, the more underexposed the pixel is; the closer the pixel value is to 1, the more overexposed the pixel is. Therefore, a larger fusion weight is given to the pixel value closer to 0.5 in the image to be fused. In addition, after testing, the reference pixel value selected here is 0.6, which produces the best fused image. Specifically, the exposure weight should take the following form:

[0113]

[0114] Among them, σ 2 is the variance, after testing, σ 2 The optimal setting is 0.2.

[0115] S6.2: Normalize the fusion weight map to obtain a normalized fusion weight map, which is in the following form:

[0116]

[0117] Wherein, N represents the number of images to be fused. In this embodiment, the images to be fused include the original image, the enhanced image of the original image, and the enhanced image of the inverted image, so N=3.

[0118] It is worth noting that in actual applications, the number and selection of image quality parameters are not limited to the three mentioned here. The parameter scheme should be designed by the operator or selected appropriately according to needs.

[0119] S6.3: In order to avoid the gap phenomenon caused by direct fusion, this embodiment adopts the concept of multi-resolution, specifically using image pyramid technology to fuse the images to be fused and the weight images corresponding to the images to be fused. Specifically, each image to be fused is converted into a Laplacian pyramid image group of a group of images to be fused through Laplacian pyramid decomposition, retaining the high-frequency information (edge ​​texture information) in the images to be fused, such as contour edge details. At the same time, the normalized weight images corresponding to each image to be fused are converted into a Gaussian pyramid weight image group through Gaussian pyramid decomposition, retaining the low-frequency information (main structure information) of the images to be fused. The Gaussian pyramid and the Laplacian pyramid are decomposed into the same number of layers.

[0120] S6.4: For each layer, use the Gaussian pyramid image corresponding to the normalized weight to perform a linear combination with the Laplacian pyramid image of that layer corresponding to the source image group to be fused, to obtain a weighted Laplacian pyramid. Specifically, the linear combination process should take the following form:

[0121]

[0122] Where, represents the Gaussian pyramid graph group of the normalized weight map. represents the Laplacian pyramid graph group of the source images to be fused. N represents the number of images to be fused.

[0123] S6.5: The weighted Laplacian pyramid image of the fused image is upsampled and filtered to perform image pyramid reconstruction to obtain a final fused image.

[0124] In this embodiment, the image enhancement method further includes the following steps:

[0125] S7: Use white balance techniques such as the Gray World algorithm or White Patch to correct the color cast of the obtained fused image.

[0126] The image enhancement method of the present invention can significantly improve the overall brightness of low-light images and the overall illumination distribution quality of uneven-light images. Figure 4 As shown, it has the effect of enhancing and clarifying the different brightness areas in the image, effectively overcoming the problems of overexposure, contrast and color saturation reduction in the bright parts of the image after other technologies enhance the dark image. At the same time, for the case of color distortion, a series of low-complexity and effective color cast correction algorithms are used to eliminate color deviation. The overall implementation method of the present invention can achieve a more significant enhancement effect while maintaining high interpretability and low complexity, effectively improving the visual value and data value of low-light images and images with uneven lighting distribution.

[0127] Example 2

[0128] Based on the above embodiment, this embodiment is based on Figure 2 Taking the original image in as an example, the image enhancement method of the embodiment of the present invention is further described. The image enhancement method includes:

[0129] Step 1: Figure 2 The original image shown is read and normalized to obtain a normalized image of the original image;

[0130] Step 2: Invert the normalized image of the original image to obtain Figure 3 Inverted image shown.

[0131] Step 3: Calculate the illumination estimation weight matrix and initial illumination component estimation for the original image and the inverted image respectively.

[0132] Step 4: Construct an objective function for illumination component estimation and solve it to obtain the estimated maps of the illumination components of the original image and the inverted image.

[0133] Step 5: Calculate the initial reflection components of the original image and the inverted image based on the image decomposition model.

[0134] Step 6: Since the noise in the inverted image is small and can be ignored, the embodiment of the present invention constructs an objective function for denoising the reflection component and only solves to obtain the reflection component estimation image of the original image. Generally, the objective function for reflection component estimation conforms to the following form:

[0135]

[0136] Wherein, R represents the reflection component and W represents the weight matrix. Optionally, different weight design schemes can be used in the denoising process to obtain different denoising effects.

[0137] Step 7: Based on the image decomposition model, the updated illumination component and reflection component are combined to calculate the enhanced original image and inverted image.

[0138] Step 8: The three images obtained - the original image, the enhanced image of the original image and the enhanced image of the inverted image are fused to obtain the fused enhanced image, such as Figure 4 shown.

[0139] Optionally, a white balance algorithm can be used on final images with severe color casts to improve the naturalness of the image's colors.

[0140] The image enhancement method of the embodiment of the present invention does not rely on any random number generation, and it can be considered that the result is independent of the choice of device. In addition, the architecture used in this method has high interpretability and fast computing speed while also having a small model size. In particular, in the objective function solution part where the computing demand is the largest, computing resources can be reused because the same structure is used. Such characteristics also determine that the method of the embodiment of the present invention can be implemented more conveniently on other devices.

[0141] Therefore, the beneficial effects of the embodiments of the present invention are:

[0142] 1. A highly stable framework: The original image, the enhanced image of the original image, and the enhanced image of the inverted image are fused to obtain an enhanced image that solves problems such as low image contrast, under-enhancement, over-enhancement, noise, and color cast after image enhancement.

[0143] 2. The same framework is used to process the illumination and reflection components of an image, which can significantly reduce the waste of hardware resources during deployment.

[0144] 3. Design the target optimization function of the image reflection component to effectively extract the image structure information.

[0145] Another embodiment of the present invention provides a storage medium storing a computer program for executing the steps of the image enhancement method for simultaneously enhancing clarity in high- and low-illuminance areas described in the above embodiments. Another aspect of the present invention provides an electronic device comprising a memory and a processor, wherein the memory stores a computer program, and when the processor invokes the computer program in the memory, the processor executes the steps of the image enhancement method for simultaneously enhancing clarity in high- and low-illuminance areas described in the above embodiments. Specifically, the integrated module implemented in the form of a software functional module can be stored in a computer-readable storage medium. The software functional module is stored in a storage medium and includes instructions for causing an electronic device (such as a personal computer, server, or network device) or a processor to execute some of the steps of the method described in various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, a mobile hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0146] The above is a further detailed description of the present invention in conjunction with specific preferred embodiments, and the specific implementation of the present invention should not be considered to be limited to these descriptions. For those skilled in the art of the present invention, without departing from the concept of the present invention, several simple deductions or substitutions can be made, which should be considered to fall within the scope of protection of the present invention.

Claims

1. An image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas, characterized in that: include: S1: Acquire an original image to be processed and an inverted image of the original image; S2: Obtain the initial illumination component estimation map and image smoothing weight of the original image and the inverted image respectively; S3: construct an objective function for obtaining the final illumination component estimation, using the initial illumination component estimation maps of the original image and the inverted image as initial inputs, respectively, to obtain the actual illumination component estimation maps of the original image and the inverted image; S4: obtaining initial reflection component estimation maps of the original image and the inverted image according to the image decomposition model and calculating noise-free reflection component estimation maps of the original image and the inverted image; S5: Obtaining enhanced images of the original image and the inverted image respectively according to the noise-free reflection component estimation map and the actual illumination component estimation map; S6: Fusing the original image, the enhanced image of the original image, and the enhanced image of the inverted image to obtain a fused image.

2. The image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas according to claim 1, characterized in that: The S2 includes: S2.1: Performing initial illumination estimation on the original image and the inverted image respectively to obtain initial illumination component estimation maps of the original image and the inverted image; S2.2: Obtain the original image smoothing weight and the inverted image smoothing weight according to the initial illumination component estimation maps of the original image and the inverted image respectively.

3. The image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas according to claim 1, characterized in that: The objective function is: Where T represents the actual illumination component estimation map of the original image or the inverted image, Represents the initial illumination component estimation map of the original image or inverted image, W T represents the smoothing weight of the original image or the inverted image, α represents the regularization parameter, which is used to adjust the smoothing strength. represents the gradient matrix of T.

4. The image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas according to claim 1, characterized in that: The S4 includes: S4.1: Decomposition Model Based on Images Variations Calculate the initial reflection component estimation map of the original image and the inverted image, where L represents the normalized original image or inverted image, represents the initial reflectance component estimate of the original image or the inverted image, The symbol represents pixel-by-pixel multiplication; S4.2: Calculate the denoising weight W of the original image’s reflection component based on the initial reflection component estimation map of the original image R ; S4.3: Iteratively calculate the noise-free reflection component estimation image of the original image using the reflection component denoising weights combined with the reflection component denoising model, wherein the reflection component denoising model is: in, Indicates the calculation of F norm, |·|1 indicates the calculation of L1 norm; S4.4: Use the initial reflection component estimation map of the inverted image as the noise-free reflection component estimation map of the inverted image.

5. The image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas according to claim 1, characterized in that: The S5 includes: S5.1: Perform gamma transformation T′ on the actual illumination component estimation map of the original image and the inverted image. γ , obtain the illumination component estimation map after transformation adjustment of the original image and the inverted image, where T′ represents the illumination component estimation map after transformation adjustment, and γ is the coefficient of gamma transformation; S5.2: Decomposition Model Based on Images Multiply the noise-free reflection component estimation map and the adjusted illumination component estimation map pixel by pixel to obtain the enhanced images of the original image and the inverted image respectively 6. The image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas according to claim 1, characterized in that: The S6 includes: S6.1: Design a fusion weight map based on the contrast, saturation, and exposure of the image, using pixels as the unit: in, k (), S k (), E k () is the contrast weight value, saturation weight value and exposure weight value of the kth image to be fused at point x; w c , w S , w E denote the weight coefficients corresponding to contrast, saturation, and exposure respectively; x denotes a point in the current image space, and the image to be fused includes the original image, the enhanced image of the original image, and the enhanced image of the inverted image; S6.2: Normalizing the fusion weight map to obtain a normalized fusion weight map; S6.3: Convert each to-be-fused image into a Laplacian pyramid image group of the to-be-fused images using Laplacian pyramid decomposition, preserving edge texture information in the to-be-fused images. Simultaneously, convert the obtained normalized fusion weight images corresponding to each to-be-fused image into a Gaussian pyramid weight image group using Gaussian pyramid decomposition, preserving the main structural information of the to-be-fused images. S6.4: Linearly combine the Laplacian pyramid images of the current layer corresponding to the image group to be fused using the Gaussian pyramid images corresponding to the normalized fusion weight images to obtain a weighted Laplacian pyramid. S6.5: The weighted Laplacian pyramid image of the fused image is upsampled and filtered to perform image pyramid reconstruction to obtain a final fused image.

7. The image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas according to claim 6, characterized in that: The S6.1 includes: S6.11: Obtain contrast weight maps for the original image, the enhanced image of the original image, and the enhanced image of the inverted image, where the contrast weight is expressed as: Among them, L k () represents the value of point x in the image space of the kth image to be fused, represents the sobel operator in the horizontal direction, Represents the Sobel operator in the vertical direction; S6.12: After constructing the contrast weight map, the image to be fused is subjected to bilateral filtering. After the bilateral filtering, the image is noise-free while retaining the structural edge information of the image to be fused. S6.13: Construct a saturation weight map of the image to be fused using the variances of the three channels of the image to be fused after bilateral processing. The expression for the saturation weight is: Among them, R′ k (), G′ k (), B′ k () respectively represent the pixel values ​​at the midpoint x of the three color channels R, G, and B in the image space after the kth image to be fused is processed by bilateral filtering, and Var() represents the variance; S6.14: Obtain an exposure weight map of the image to be fused, where the expression of the exposure weight is: Among them, σ 2 is the variance; S6.15: Obtain the fusion weight map by the contrast, saturation, and exposure of the image to be fused: Where, (), S(x), E(x) are the contrast weight value, saturation weight value and exposure weight value of the k-th image to be fused at point x; w c , w S , w E Represent the weight coefficients corresponding to contrast, saturation and exposure respectively; x represents a point in the current image space.

8. The image enhancement method capable of simultaneously enhancing the clarity of high-illumination and low-illumination areas according to claim 6, characterized in that: Also includes: S7: Use the Gray World algorithm or White Patch white balance technology to correct the color cast of the fused image.

Citation Information

Patent Citations

  • Weak light enhancement method based on multi-image fusion Retinex

    CN111127377A

  • Low-light image enhancement method and system, terminal and storage medium

    CN115358943A