Image enhancement method, image enhancement device, storage medium, and electronic device

By using HSV spatial decomposition and image enhancement denoising, the problem of noise amplification in low-light image enhancement is solved, achieving high-quality image enhancement results.

CN117237225BActive Publication Date: 2026-04-07CHINA ENERGY GRP NINGXIA COAL IND CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-09-26
Publication Date
2026-04-07

AI Technical Summary

Technical Problem

Existing technologies, when enhancing low-light images, amplify noise, which degrades the performance of downstream visual tasks, and struggle to effectively separate illumination and reflection components, resulting in poor enhancement effects.

Method used

The HSV spatial decomposition method is used to decompose the input image into initial hue, saturation and luminance images, and image enhancement and denoising are performed on them respectively. Then, the target saturation and luminance images are fused to generate an RGB image, and a semi-implicit difference ROF denoising model is used for further denoising.

Benefits of technology

It effectively avoids noise amplification, improves image quality and detail recognition, ensures color authenticity, and enhances image enhancement effects.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 1
    Figure 1
Patent Text Reader

Abstract

The application provides an image enhancement method, an image enhancement device, a storage medium and an electronic device. The image enhancement method comprises the following steps: acquiring and decomposing an HSV space image corresponding to an input image to obtain an initial hue image, an initial saturation image and an initial brightness image of the HSV space image; sequentially performing first image enhancement processing and first image denoising processing on the initial saturation image to determine a target saturation image; sequentially performing second image enhancement processing and second image denoising processing on the initial brightness image to determine a target brightness image; and determining a first enhanced image corresponding to the input image according to the initial hue image, the target saturation image and the target brightness image. Through the application, the problem of poor image enhancement effect is solved, and the noise of the final first enhanced image will not be amplified.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of image processing, in particular to an image enhancement method, an image enhancement device, a computer readable storage medium and an electronic device. BACKGROUND

[0002] When capturing images in the underground environment of a coal mine, the image sensor will inevitably work under low light conditions, that is, the sensory illuminance is between 0.002 lux and 0.3 lux (the illuminance under sunlight is 60000-100000 lux). The light source in the tunnel environment is complex and changeable, so the images taken under adverse lighting conditions usually have poor visibility. However, working under such conditions is necessary for the promotion of the intelligent system of the coal mine, such as tunnel environment monitoring, underground personnel identification, equipment fault detection, etc. The purpose of image enhancement is to improve the quality of the image under adverse lighting conditions, thereby improving the contrast and illuminance of the image, improving the detail recognition of the image, and ensuring the color authenticity of the enhanced image. However, a large amount of noise is embedded in the image, which makes it difficult to decompose the noise from the degraded image. For the above reasons, when the adverse image is enhanced, the complex noise is amplified. These amplified noises will reduce the performance of downstream visual tasks.

[0003] A method based on the Retinex theory is adopted in the prior art, which is widely used in low-light image enhancement. They decompose the input low-light image into illuminance and reflectance, and enhance the illuminance of the image, but it is still difficult to effectively separate the illumination and reflection components, thus resulting in poor enhancement effect of the low-light image.

[0004] Therefore, there is an urgent need for an image enhancement method that can avoid noise amplification while enhancing low-light images. SUMMARY

[0005] The main purpose of the present application is to provide an image enhancement method, an image enhancement device, a computer readable storage medium and an electronic device to at least solve the problem of amplification of complex noise when enhancing low-light images in the prior art.

[0006] In order to achieve the above-mentioned purpose, according to one aspect of the present application, an image enhancement method is provided, comprising: acquiring and decomposing an HSV space image corresponding to an input image to obtain an initial hue image, an initial saturation image and an initial brightness image of the HSV space image; sequentially performing first image enhancement processing and first image denoising processing on the initial saturation image to determine a target saturation image; sequentially performing second image enhancement processing and second image denoising processing on the initial brightness image to determine a target brightness image; and determining a first enhanced image corresponding to the input image according to the initial hue image, the target saturation image and the target brightness image.

[0007] Optionally, the image enhancement method further includes: using a semi-implicit differential ROF denoising model to denoise the first enhanced image to determine the second enhanced image.

[0008] Optionally, the initial saturation image is sequentially subjected to a first image enhancement process and a first image denoising process to determine the target saturation image, including: performing a morphological closing operation on the initial saturation image to form a first saturation image; and performing a Gaussian filtering process on the first saturation image to determine the target saturation image.

[0009] Optionally, performing a second image enhancement process and a second image denoising process sequentially on the initial brightness image to determine the target brightness image includes: performing a logarithmic transformation on the initial brightness image to form a first brightness image; and performing bilateral filtering on the first brightness image to determine the target brightness image.

[0010] Optionally, determining the first enhanced image corresponding to the input image based on the initial tone image, the target saturation image, and the target brightness image includes: obtaining a first likelihood probability and a first prior probability of the target saturation image, and determining a first posterior conditional probability of the target saturation image based on the first likelihood probability and the first prior probability; obtaining a second likelihood probability and a second prior probability of the target brightness image, and determining a second posterior conditional probability of the target brightness image based on the second likelihood probability and the second prior probability; and determining the first enhanced image based on the first posterior conditional probability, the second posterior conditional probability, and the initial tone image.

[0011] Optionally, obtaining the first likelihood probability of the target saturation image includes: obtaining the first saturation of each pixel in the target saturation image and generating a saturation histogram; normalizing the saturation histogram to obtain a first mean and a first variance; and calculating the first likelihood probability of the target saturation image based on the first saturation, the first mean, the first variance, and the probability density function.

[0012] Optionally, obtaining the second likelihood probability of the target brightness image includes: obtaining the first brightness of each pixel in the target brightness image and generating a brightness histogram; normalizing the brightness histogram to obtain a second mean and a second variance; and calculating the second likelihood probability of the target brightness image based on the first brightness, the second mean, the second variance, and the probability density function.

[0013] Optionally, obtaining a first prior probability of the target saturation image and a second prior probability of the target brightness image includes: obtaining the width and height of the input image; determining the first prior probability based on the first saturation, width, and height of each pixel, wherein the target saturation image includes multiple first saturations; and determining the second prior probability based on the first brightness, width, and height of each pixel, wherein the target brightness image includes multiple first brightnesses.

[0014] According to another aspect of this application, an image enhancement apparatus is provided, comprising: an acquisition unit, configured to acquire and decompose an HSV space image corresponding to an input image to obtain an initial hue image, an initial saturation image, and an initial brightness image of the HSV space image; a first processing unit, configured to sequentially perform a first image enhancement processing and a first image denoising processing on the initial saturation image to determine a target saturation image; a second processing unit, configured to sequentially perform a second image enhancement processing and a second image denoising processing on the initial brightness image to determine a target brightness image; and a third processing unit, configured to determine a first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image.

[0015] According to another aspect of this application, a computer-readable storage medium is provided, the computer-readable storage medium including a stored program, wherein, when the program is executed, it controls the device where the computer-readable storage medium is located to perform the above-described image enhancement method.

[0016] According to another aspect of this application, an electronic device is provided, comprising: one or more processors, a memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs include methods for performing the image enhancement method described above.

[0017] Applying the technical solution of this application, the obtained input image corresponding to the HSV space image is first decomposed to obtain images corresponding to the three components (H, S, V) of the HSV space image, namely, the initial hue image, the initial saturation image, and the initial brightness image. Then, image enhancement processing is performed on the initial saturation image and the initial brightness image respectively. The image enhancement processing on the initial saturation image is denoted as the first image enhancement processing, and the image enhancement processing on the initial brightness image is denoted as the second image enhancement processing. Then, image denoising processing is performed on the enhanced images of the initial saturation image and the initial brightness image respectively. The image denoising processing on the enhanced image of the initial saturation image is denoted as the first image denoising processing, and the image denoising processing on the enhanced image of the initial brightness image is denoted as the second image denoising processing. The process is referred to as the second image denoising process, thereby obtaining the target saturation image and the target brightness image after enhancement and denoising. This avoids the problem of poor image enhancement effect caused by the difficulty in effectively separating illumination and reflection components in the prior art. In addition, the initial tone image remains unchanged during the image enhancement process. When determining the first enhanced image corresponding to the input image based on the initial tone image, the target saturation image, and the target brightness image, since the target saturation image and the target brightness image have already undergone enhancement and denoising processes respectively, the RGB image after image enhancement, i.e., the first enhanced image, can be obtained by fusing the target saturation image and the target brightness image. The noise of the first enhanced image will not be amplified. Attached Figure Description

[0018] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings:

[0019] Figure 1 A hardware structure block diagram of a mobile terminal performing an image enhancement method according to an embodiment of this application is shown;

[0020] Figure 2 A schematic flowchart of an image enhancement method according to an embodiment of this application is shown;

[0021] Figure 3 A structural block diagram of an image enhancement apparatus provided according to an embodiment of this application is shown. Detailed Implementation

[0022] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.

[0023] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.

[0024] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate for the embodiments of this application described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0025] As described in the background section, the purpose of image enhancement is to improve image quality under unfavorable lighting conditions, thereby improving image contrast and illuminance, enhancing image detail recognition, and ensuring color fidelity. However, images often contain a large amount of embedded noise, making it difficult to decompose noise from degraded images. For these reasons, complex noise is amplified when unfavorable images are enhanced. This amplified noise degrades the performance of downstream visual tasks. Existing technologies employ methods based on Retinex theory, which is widely used in low-light image enhancement. These methods decompose the input low-light image into illuminance and reflectance, and enhance the image's illuminance. However, it is currently difficult to effectively separate the illumination and reflectance components, resulting in poor enhancement effects for low-light images. To address the problem of amplified complex noise when enhancing low-light images, embodiments of this application provide an image enhancement method.

[0026] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.

[0027] The methods and embodiments provided in this application can be executed on a mobile terminal, computer terminal, or similar computing device. Taking running on a mobile terminal as an example, Figure 1 This is a hardware structure block diagram of a mobile terminal for an image enhancement method according to an embodiment of the present invention. Figure 1 As shown, a mobile terminal may include one or more ( Figure 1Only one is shown in the diagram. A processor 102 (which may include, but is not limited to, a microprocessor MCU or a programmable logic device FPGA, etc.) and a memory 104 for storing data are also shown. The mobile terminal may further include a transmission device 106 for communication functions and an input / output device 108. Those skilled in the art will understand that... Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the mobile terminal described above. For example, the mobile terminal may also include components that are more... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown.

[0028] The memory 104 can be used to store computer programs, such as application software programs and modules, like the computer program corresponding to the image enhancement method in this embodiment of the invention. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, thereby implementing the above-described method. The memory 104 may include high-speed random access memory and non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the mobile terminal via a network. Examples of the aforementioned networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof. The transmission device 106 is used to receive or send data via a network. Specific examples of the aforementioned networks may include wireless networks provided by the mobile terminal's communication provider. In one example, the transmission device 106 includes a network interface controller (NIC), which can be connected to other network devices via a base station to communicate with the Internet. In one example, the transmission device 106 may be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0029] This embodiment provides an image enhancement method that runs on a mobile terminal, computer terminal, or similar computing device. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Also, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.

[0030] Figure 2 This is a flowchart of an image enhancement method according to an embodiment of this application. For example... Figure 2 As shown, the method includes the following steps:

[0031] Step S201: Obtain and decompose the HSV space image corresponding to the input image to obtain the initial tone image, initial saturation image and initial brightness image of the HSV space image;

[0032] Specifically, the input image is the low-light image to be enhanced and denoised. Optionally, the first image can be an RGB space image. To separate color information from the RGB space image and make color analysis and processing more convenient, the input image (RGB space image) is first converted into an HSV space image. Then, through decomposition, the H, S, and V components of the HSV space image can be directly extracted. The H component is the hue component, the S component is the saturation component, and the V component is the brightness component. These three components can be directly displayed. Specifically, the H component can be displayed using an initial hue image, the S component can be displayed using an initial saturation image, and the V component can be displayed using an initial brightness image.

[0033] Optionally, the H component can range from 0 to 360 degrees. For example, a hue value of 0 represents red, 60 represents yellow, 120 represents green, 180 represents cyan, 240 represents blue, and 300 represents purple. The S component can range from 0 to 1. For example, a saturation value of 0 represents a grayscale image, and a saturation value of 1 represents color saturation. The V component can range from 0 to 1. For example, a brightness value of 0 represents black, and a brightness value of 1 represents white.

[0034] Step S202: Perform first image enhancement processing and first image denoising processing sequentially on the initial saturation image to determine the target saturation image;

[0035] Specifically, the initial saturation image can first undergo a first image enhancement process, and then the initial saturation image after the enhancement process can be denoised using a first image denoising process, thereby suppressing the noise amplified after the initial saturation image undergoes image enhancement processing.

[0036] Step S203: Perform second image enhancement processing and second image denoising processing on the initial brightness image in sequence to determine the target brightness image;

[0037] Specifically, the initial brightness image can first undergo a second image enhancement process, and then the enhanced initial brightness image can be denoised using a second image denoising process, thereby suppressing the noise amplified after the initial brightness image undergoes image enhancement processing.

[0038] Step S204: Determine the first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image.

[0039] Specifically, since the initial hue image has not undergone image enhancement and image denoising processing, when fusing the three components of the HSV space image, the hue component is still displayed using the initial hue image, but the saturation component to be fused can be displayed using the target saturation image, and the luminance component to be fused can be displayed using the target luminance image. It can be understood that the image after fusing the initial hue image, the target saturation image, and the target luminance image is an RGB space image, and the fused RGB space image is the first enhanced image mentioned above.

[0040] In this embodiment, the obtained input image is first decomposed into its corresponding HSV spatial image to obtain images corresponding to the three components (H, S, V) of the HSV spatial image: the initial hue image, the initial saturation image, and the initial brightness image. Then, image enhancement processing is performed on the initial saturation image and the initial brightness image respectively. The image enhancement processing on the initial saturation image is denoted as the first image enhancement processing, and the image enhancement processing on the initial brightness image is denoted as the second image enhancement processing. Finally, image denoising processing is performed on the enhanced images of the initial saturation image and the initial brightness image respectively. The image denoising processing on the enhanced image of the initial saturation image is denoted as the first image denoising processing, and the image denoising processing on the enhanced image of the initial brightness image is denoted as the second image denoising processing. This is referred to as the second image denoising process, which yields the target saturation image and the target brightness image after enhancement and denoising. This avoids the problem of poor image enhancement caused by the difficulty in effectively separating illumination and reflection components in the prior art. In addition, the initial hue image remains unchanged during the image enhancement process. When determining the first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image, since the target saturation image and the target brightness image have already undergone enhancement and denoising processes respectively, the RGB image after image enhancement, i.e., the first enhanced image, can be obtained by fusing the target saturation image and the target brightness image. The noise of the first enhanced image will not be amplified.

[0041] In some optional implementations, the above image enhancement method may further include: denoising the first enhanced image using a semi-implicit differential ROF denoising model to determine the second enhanced image.

[0042] Specifically, the iterative formula for the above semi-implicit difference ROF denoising model is:

[0043]

[0044] Among them, the above and These represent the results at the current time step and the new time step, respectively. Δt > 0 represents the time step, and α > 0 represents the balancing parameter. This represents gradient descent flow.

[0045] In the above implementation, the RGB space image is converted from the HSV space image. Therefore, the initial values ​​in the iterative formula of the semi-implicit difference ROF denoising model can be used. The component image to be converted is set in HSV space, the maximum number of iterations is max, and the allowable error tolerance t > 0; then, in the nth iteration, the iteration result can be calculated according to the above iteration formula. Until n = max or Thus, the result obtained after processing by the semi-implicit differential ROF denoising model is the second enhanced image.

[0046] In the specific implementation process, the above-mentioned first image enhancement processing and first image denoising processing are performed sequentially on the initial saturation image to determine the target saturation image, including: performing morphological closing operation processing on the initial saturation image to form a first saturation image; and performing Gaussian filtering processing on the first saturation image to determine the target saturation image.

[0047] In the above embodiments, morphological closing operations can be used to perform dilation followed by erosion on the initial saturation image to remove noise and fill holes in the initial saturation image, making the image more complete and continuous, and improving the shape and structure of the image, thereby obtaining the first saturation image. Furthermore, in order to make the first saturation image less noisy and smoother, Gaussian filtering can be performed on the first saturation image to form the final target saturation image. The image quality of the target saturation image is better than that of the initial saturation image, and the noise is less.

[0048] In some optional implementations, performing a second image enhancement process and a second image denoising process sequentially on the initial brightness image to determine the target brightness image includes: performing a logarithmic transformation on the initial brightness image to form a first brightness image; and performing bilateral filtering on the first brightness image to determine the target brightness image.

[0049] Similarly, in the above embodiments, in order to improve the quality of the initial brightness image and reduce noise in the image, and improve the image clarity, a logarithmic transformation can be performed on the initial brightness image to form a first brightness image. Optionally, the logarithmic transformation is a nonlinear enhancement process. For example, the nonlinear enhancement process can be new_V = clog(1 + old_V), where new_V and old_V represent the V component value after transformation and the V component value before transformation, respectively, and c is a constant term. In addition, in order to further reduce the noise of the first brightness image and smooth the first brightness image, a bilateral filtering process can be applied to the first brightness image to obtain the final target brightness image. The image quality of the target brightness image is better than that of the initial brightness image, and the noise is smaller.

[0050] In some optional implementations, determining a first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image includes: obtaining a first likelihood probability and a first prior probability of the target saturation image, and determining a first posterior conditional probability of the target saturation image based on the first likelihood probability and the first prior probability; obtaining a second likelihood probability and a second prior probability of the target brightness image, and determining a second posterior conditional probability of the target brightness image based on the second likelihood probability and the second prior probability; and determining the first enhanced image based on the first posterior conditional probability, the second posterior conditional probability, and the initial hue image.

[0051] Specifically, I1 can be used to represent the saturation in the target saturation image, and I2 can be used to represent the brightness in the target brightness image, and event E can be defined. i Indicate I i (i = 1, 2) represents the proportion of the corresponding pixel in the fused HSV spatial image. The first likelihood probability of the target saturation image and the target brightness image can be expressed as P(I j |E i The first prior probabilities of the target saturation image and the target brightness image mentioned above can be expressed as P(E). i If the target saturation image and the target brightness image are such that the first posterior conditional probability can be expressed as P(E), then the first posterior conditional probability of the target saturation image and the target brightness image can be expressed as P(E). i |I j The calculation formula is as follows:

[0052]

[0053] It is understood that the first posterior conditional probability is the fusion weight of the target saturation image in the first enhanced image, and this fusion weight is denoted as W1. Similarly, the second posterior conditional probability is the fusion weight of the target brightness image in the first enhanced image, and this fusion weight is denoted as W2. Furthermore, to obtain the final first enhanced image, the initial tone image, the target saturation image, and the target brightness image are fused using the first posterior conditional probability, the second posterior conditional probability, and the initial tone image. Specifically, the first enhanced image can be calculated using the following formula:

[0054] c = f(H, W1⊙S, W2⊙V),

[0055] Where C represents the first enhanced image, and f(·) is the conversion function from HSV space to RGB format. i The symbol represents the weight of component i, and ⊙ represents the pixel-wise multiplication operator.

[0056] In some optional implementations, obtaining the first likelihood probability of the target saturation image includes: obtaining the first saturation of each pixel of the target saturation image and generating a saturation histogram; normalizing the saturation histogram to obtain a first mean and a first variance; and calculating the first likelihood probability of the target saturation image based on the first saturation, the first mean, the first variance, and the probability density function.

[0057] In the above embodiment, the target saturation image includes multiple pixels. To obtain the first likelihood probability of the target saturation image, the target saturation image is first traversed to obtain the saturation value of each pixel, which is the first saturation. Thus, the target saturation image has multiple first saturations. These multiple first saturations are grouped to generate a saturation histogram. Since this histogram roughly follows a normal distribution, it can be normalized. The horizontal axis of the normalized saturation histogram represents different intervals of the first saturation, with each interval representing the range of values ​​for the first saturation. Then… For each interval, multiply its center value by the frequency of the histogram corresponding to that interval, then sum the products of all intervals, and finally divide by the total frequency to obtain the first mean. Then, for each interval of first saturation, multiply the square of the difference between its center value and the first mean by the frequency of the saturation histogram corresponding to that interval, then sum the products of all intervals, and finally divide by the total frequency to obtain the first variance. Then, given the probability density function, substitute the first mean, the first variance, and the first saturation corresponding to each pixel into the probability density function to calculate the first likelihood probability of the target saturation image. Specifically, the probability density function for calculating the first likelihood probability is:

[0058]

[0059] Wherein, the above μ j σ j 2 and (x,y) represent the mean, variance, and pixel coordinates of the corresponding j component, respectively. For example, the above μ j and σ j 2 It can represent the first mean and first variance of the saturation component.

[0060] In some optional implementations, obtaining the second likelihood probability of the target brightness image includes: obtaining the first brightness of each pixel of the target brightness image and generating a brightness histogram; normalizing the brightness histogram to obtain a second mean and a second variance; and calculating the second likelihood probability of the target brightness image based on the first brightness, the second mean, the second variance, and the probability density function.

[0061] Similarly, in the above embodiment, the target brightness image includes multiple pixels. To obtain the first likelihood probability of the target brightness image, the target brightness image is first traversed to obtain the brightness value of each pixel, which is the first brightness. Thus, the target brightness image has multiple first brightness values. These multiple first brightness values ​​are grouped to generate a brightness histogram. Since the histogram roughly follows a normal distribution, it can be normalized. The horizontal axis of the normalized brightness histogram represents different intervals of the first brightness, with each interval representing the value range of the first brightness. Then, for each... For each interval of first brightness, multiply its center value by the frequency of the histogram corresponding to that interval, sum the products of all intervals, and finally divide by the total frequency to obtain the second mean. Then, for each interval of first brightness, multiply the square of the difference between its center value and the second mean by the frequency of the brightness histogram corresponding to that interval, sum the products of all intervals, and finally divide by the total frequency to obtain the second variance. Then, given the probability density function, substitute the second mean, the second variance, and the first brightness corresponding to each pixel into the probability density function to calculate the second likelihood probability of the target brightness image. Specifically, the probability density function for calculating the second likelihood probability is:

[0062]

[0063] Wherein, the above μ j σ j 2 and (x,y) represent the mean, variance, and pixel coordinates of the corresponding j component, respectively. For example, the above μ j and σ j 2It can represent the second mean and second variance of the luminance component.

[0064] In some optional implementations, obtaining a first prior probability of the target saturation image and a second prior probability of the target brightness image includes: obtaining the width and height of the input image; determining the first prior probability based on the first saturation, width, and height of each pixel, wherein the target saturation image includes a plurality of first saturations; and determining the second prior probability based on the first brightness, width, and height of each pixel, wherein the target brightness image includes a plurality of first brightnesses.

[0065] In the above implementation, since the pixel values ​​of the hue and saturation components are smaller than the pixel value of the enhanced luminance component, directly defining the first and second prior probabilities as 1 / 2 is inappropriate. Therefore, the width and height of the input image can be obtained first, and then the first prior probability of the target saturation image and the second prior probability of the target luminance image can be calculated respectively. Specifically, the first and second prior probabilities can be calculated using the following formula:

[0066]

[0067] Here, m and n represent the width and height of the input image, respectively.

[0068] This application also provides an image enhancement apparatus. It should be noted that the image enhancement apparatus of this application can be used to execute the image enhancement method provided in this application. This apparatus is used to implement the above embodiments and preferred embodiments; details already described will not be repeated. As used below, the term "module" can refer to a combination of software and / or hardware that implements a predetermined function. Although the apparatus described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.

[0069] The image enhancement apparatus provided in the embodiments of this application will be described below.

[0070] Figure 3 This is a schematic diagram of an image enhancement apparatus according to an embodiment of this application. Figure 3 As shown, the device includes:

[0071] The acquisition unit 10 is used to acquire and decompose the HSV space image corresponding to the input image to obtain the initial tone image, initial saturation image and initial brightness image of the HSV space image;

[0072] Specifically, the input image is the low-light image to be enhanced and denoised. Optionally, the first image can be an RGB space image. To separate color information from the RGB space image and make color analysis and processing more convenient, the input image (RGB space image) is first converted into an HSV space image. Then, through decomposition, the H, S, and V components of the HSV space image can be directly extracted. The H component is the hue component, the S component is the saturation component, and the V component is the brightness component. These three components can be directly displayed. Specifically, the H component can be displayed using an initial hue image, the S component can be displayed using an initial saturation image, and the V component can be displayed using an initial brightness image.

[0073] Optionally, the H component can range from 0 to 360 degrees. For example, a hue value of 0 represents red, 60 represents yellow, 120 represents green, 180 represents cyan, 240 represents blue, and 300 represents purple. The S component can range from 0 to 1. For example, a saturation value of 0 represents a grayscale image, and a saturation value of 1 represents color saturation. The V component can range from 0 to 1. For example, a brightness value of 0 represents black, and a brightness value of 1 represents white.

[0074] The first processing unit 20 is used to sequentially perform a first image enhancement process and a first image denoising process on the initial saturation image to determine the target saturation image;

[0075] Specifically, the initial saturation image can first undergo a first image enhancement process, and then the initial saturation image after the enhancement process can be denoised using a first image denoising process, thereby suppressing the noise amplified after the initial saturation image undergoes image enhancement processing.

[0076] The second processing unit 30 is used to sequentially perform second image enhancement processing and second image denoising processing on the initial brightness image to determine the target brightness image;

[0077] Specifically, the initial brightness image can first undergo a second image enhancement process, and then the enhanced initial brightness image can be denoised using a second image denoising process, thereby suppressing the noise amplified after the initial brightness image undergoes image enhancement processing.

[0078] The third processing unit 30 is used to determine the first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image.

[0079] Specifically, since the initial hue image has not undergone image enhancement and image denoising processing, when fusing the three components of the HSV space image, the hue component is still displayed using the initial hue image, but the saturation component to be fused can be displayed using the target saturation image, and the luminance component to be fused can be displayed using the target luminance image. It can be understood that the image after fusing the initial hue image, the target saturation image, and the target luminance image is an RGB space image, and the fused RGB space image is the first enhanced image mentioned above.

[0080] In this embodiment, the obtained input image is first decomposed into its corresponding HSV spatial image to obtain images corresponding to the three components (H, S, V) of the HSV spatial image: the initial hue image, the initial saturation image, and the initial brightness image. Then, image enhancement processing is performed on the initial saturation image and the initial brightness image respectively. The image enhancement processing on the initial saturation image is denoted as the first image enhancement processing, and the image enhancement processing on the initial brightness image is denoted as the second image enhancement processing. Finally, image denoising processing is performed on the enhanced images of the initial saturation image and the initial brightness image respectively. The image denoising processing on the enhanced image of the initial saturation image is denoted as the first image denoising processing, and the image denoising processing on the enhanced image of the initial brightness image is denoted as the second image denoising processing. This is referred to as the second image denoising process, which yields the target saturation image and the target brightness image after enhancement and denoising. This avoids the problem of poor image enhancement caused by the difficulty in effectively separating illumination and reflection components in the prior art. In addition, the initial hue image remains unchanged during the image enhancement process. When determining the first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image, since the target saturation image and the target brightness image have already undergone enhancement and denoising processes respectively, the RGB image after image enhancement, i.e., the first enhanced image, can be obtained by fusing the target saturation image and the target brightness image. The noise of the first enhanced image will not be amplified.

[0081] In some optional implementations, the above image enhancement method may further include: a fourth processing unit, used to perform denoising processing on the first enhanced image using a semi-implicit differential ROF denoising model to determine the second enhanced image.

[0082] Specifically, the iterative formula for the above semi-implicit difference ROF denoising model is:

[0083]

[0084] Among them, the above and These represent the results at the current time step and the new time step, respectively. Δt > 0 represents the time step, and α > 0 represents the balancing parameter. This represents gradient descent flow.

[0085] In the above implementation, the RGB space image is converted from the HSV space image. Therefore, the initial values ​​in the iterative formula of the semi-implicit difference ROF denoising model can be used. The component image to be converted is set in HSV space, the maximum number of iterations is max, and the allowable error tolerance t > 0; then, in the nth iteration, the iteration result can be calculated according to the above iteration formula. Until n = max or Thus, the result obtained after processing by the semi-implicit differential ROF denoising model is the second enhanced image.

[0086] In the specific implementation process, the first processing unit includes: a first processing module, used to perform morphological closing operation processing on the initial saturation image to form a first saturation image; and a second processing module, used to perform Gaussian filtering processing on the first saturation image to determine the target saturation image.

[0087] In the above embodiments, morphological closing operations can be used to perform dilation followed by erosion on the initial saturation image to remove noise and fill holes in the initial saturation image, making the image more complete and continuous, and improving the shape and structure of the image, thereby obtaining the first saturation image. Furthermore, in order to make the first saturation image less noisy and smoother, Gaussian filtering can be performed on the first saturation image to form the final target saturation image. The image quality of the target saturation image is better than that of the initial saturation image, and the noise is less.

[0088] In some optional embodiments, the second processing unit includes: a third processing module for performing a logarithmic transformation on the initial brightness image to form a first brightness image; and a fourth processing module for performing bilateral filtering on the first brightness image to determine a target brightness image.

[0089] Similarly, in the above embodiments, in order to improve the quality of the initial brightness image and reduce noise in the image, and improve the image clarity, a logarithmic transformation can be performed on the initial brightness image to form a first brightness image. Optionally, the logarithmic transformation is a nonlinear enhancement process. For example, the nonlinear enhancement process can be new_V = clog(1 + old_V), where new_V and old_V represent the V component value after transformation and the V component value before transformation, respectively, and c is a constant term. In addition, in order to further reduce the noise of the first brightness image and smooth the first brightness image, a bilateral filtering process can be applied to the first brightness image to obtain the final target brightness image. The image quality of the target brightness image is better than that of the initial brightness image, and the noise is smaller.

[0090] In some optional embodiments, the third processing unit includes: a fifth processing module, configured to acquire a first likelihood probability and a first prior probability of the target saturation image, and determine a first posterior conditional probability of the target saturation image based on the first likelihood probability and the first prior probability; a sixth processing module, configured to acquire a second likelihood probability and a second prior probability of the target brightness image, and determine a second posterior conditional probability of the target brightness image based on the second likelihood probability and the second prior probability; and a seventh processing module, configured to determine a first enhanced image based on the first posterior conditional probability, the second posterior conditional probability, and the initial tone image.

[0091] Specifically, I1 can be used to represent the saturation in the target saturation image, and I2 can be used to represent the brightness in the target brightness image, and event E can be defined. i Indicate I i (i = 1, 2) represents the proportion of the corresponding pixel in the fused HSV spatial image. The first likelihood probability of the target saturation image and the target brightness image can be expressed as P(I j |E i The first prior probabilities of the target saturation image and the target brightness image mentioned above can be expressed as P(E). i If the target saturation image and the target brightness image are such that the first posterior conditional probability can be expressed as P(E), then the first posterior conditional probability of the target saturation image and the target brightness image can be expressed as P(E). i |I j The calculation formula is as follows:

[0092]

[0093] It is understood that the first posterior conditional probability is the fusion weight of the target saturation image in the first enhanced image, and this fusion weight is denoted as W1. Similarly, the second posterior conditional probability is the fusion weight of the target brightness image in the first enhanced image, and this fusion weight is denoted as W2. Furthermore, to obtain the final first enhanced image, the initial tone image, the target saturation image, and the target brightness image are fused using the first posterior conditional probability, the second posterior conditional probability, and the initial tone image. Specifically, the first enhanced image can be calculated using the following formula:

[0094] c = f(H, W1⊙S, W2⊙V),

[0095] Where C represents the first enhanced image, and f(•) is the conversion function from HSV space to RGB format. i The symbol represents the weight of component i, and ⊙ represents the pixel-wise multiplication operator.

[0096] In some optional implementations, the fifth processing module includes: a first processing submodule, configured to acquire the first saturation of each pixel of the target saturation image and generate a saturation histogram; a second processing submodule, configured to normalize the saturation histogram to obtain a first mean and a first variance; and a third processing submodule, configured to calculate the first likelihood probability of the target saturation image based on the first saturation, the first mean, the first variance, and the probability density function.

[0097] In the above embodiment, the target saturation image includes multiple pixels. To obtain the first likelihood probability of the target saturation image, the target saturation image is first traversed to obtain the saturation value of each pixel, which is the first saturation. Thus, the target saturation image has multiple first saturations. These multiple first saturations are grouped to generate a saturation histogram. Since this histogram roughly follows a normal distribution, it can be normalized. The horizontal axis of the normalized saturation histogram represents different intervals of the first saturation, with each interval representing the range of values ​​for the first saturation. Then… For each interval, multiply its center value by the frequency of the histogram corresponding to that interval, then sum the products of all intervals, and finally divide by the total frequency to obtain the first mean. Then, for each interval of first saturation, multiply the square of the difference between its center value and the first mean by the frequency of the saturation histogram corresponding to that interval, then sum the products of all intervals, and finally divide by the total frequency to obtain the first variance. Then, given the probability density function, substitute the first mean, the first variance, and the first saturation corresponding to each pixel into the probability density function to calculate the first likelihood probability of the target saturation image. Specifically, the probability density function for calculating the first likelihood probability is:

[0098]

[0099] Wherein, the above μ j σ j 2 and (x,y) represent the mean, variance, and pixel coordinates of the corresponding j component, respectively. For example, the above μ j and σ j 2 It can represent the first mean and first variance of the saturation component.

[0100] In some optional implementations, the sixth processing module includes: a fourth processing submodule for acquiring the first brightness of each pixel of the target brightness image and generating a brightness histogram; a fifth processing submodule for normalizing the brightness histogram to obtain a second mean and a second variance; and a sixth processing submodule for calculating a second likelihood probability of the target brightness image based on the first brightness, the second mean, the second variance, and the probability density function.

[0101] Similarly, in the above embodiment, the target brightness image includes multiple pixels. To obtain the first likelihood probability of the target brightness image, the target brightness image is first traversed to obtain the brightness value of each pixel, which is the first brightness. Thus, the target brightness image has multiple first brightness values. These multiple first brightness values ​​are grouped to generate a brightness histogram. Since the histogram roughly follows a normal distribution, it can be normalized. The horizontal axis of the normalized brightness histogram represents different intervals of the first brightness, with each interval representing the value range of the first brightness. Then, for each... For each interval of first brightness, multiply its center value by the frequency of the histogram corresponding to that interval, sum the products of all intervals, and finally divide by the total frequency to obtain the second mean. Then, for each interval of first brightness, multiply the square of the difference between its center value and the second mean by the frequency of the brightness histogram corresponding to that interval, sum the products of all intervals, and finally divide by the total frequency to obtain the second variance. Then, given the probability density function, substitute the second mean, the second variance, and the first brightness corresponding to each pixel into the probability density function to calculate the second likelihood probability of the target brightness image. Specifically, the probability density function for calculating the second likelihood probability is:

[0102]

[0103] Wherein, the above μ j σ j 2 and (x,y) represent the mean, variance, and pixel coordinates of the corresponding j component, respectively. For example, the above μ j and σj 2 It can represent the second mean and second variance of the luminance component.

[0104] In some optional implementations, the fifth processing module includes: a seventh processing submodule for acquiring the width and height of the input image; an eighth processing submodule for determining a first prior probability based on the first saturation, width, and height of each pixel, wherein the target saturation image includes multiple first saturations; the sixth processing module includes: a ninth processing submodule for acquiring the width and height of the input image; and a tenth processing submodule for determining a second prior probability based on the first brightness, width, and height of each pixel, wherein the target brightness image includes multiple first brightnesses.

[0105] In the above implementation, since the pixel values ​​of the hue and saturation components are smaller than the pixel value of the enhanced luminance component, directly defining the first and second prior probabilities as 1 / 2 is inappropriate. Therefore, the width and height of the input image can be obtained first, and then the first prior probability of the target saturation image and the second prior probability of the target luminance image can be calculated respectively. Specifically, the first and second prior probabilities can be calculated using the following formula:

[0106]

[0107] Here, m and n represent the width and height of the input image, respectively.

[0108] The image enhancement device includes a processor and a memory. The aforementioned acquisition unit 10, first processing unit 20, second processing unit 30, and third processing unit 40 are all stored as program units in the memory. The processor executes the aforementioned program units stored in the memory to achieve the corresponding functions. All of the above modules are located in the same processor; or, the above modules are located in different processors in any combination.

[0109] The processor contains a kernel, which retrieves the corresponding program unit from memory. One or more kernels can be configured, and kernel parameters can be adjusted to enhance the low-light image (i.e., the first image) and suppress the amplification of noise.

[0110] The memory may include non-permanent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.

[0111] This invention provides a computer-readable storage medium including a stored program, wherein the program controls the device where the computer-readable storage medium is located to execute an image processing method when it is running.

[0112] Specifically, image processing methods include:

[0113] Step S201: Obtain and decompose the HSV space image corresponding to the input image to obtain the initial tone image, initial saturation image and initial brightness image of the HSV space image;

[0114] Specifically, the input image is the low-light image to be enhanced and denoised. Optionally, the first image can be an RGB space image. To separate color information from the RGB space image and make color analysis and processing more convenient, the input image (RGB space image) is first converted into an HSV space image. Then, through decomposition, the H, S, and V components of the HSV space image can be directly extracted. The H component is the hue component, the S component is the saturation component, and the V component is the brightness component. These three components can be directly displayed. Specifically, the H component can be displayed using an initial hue image, the S component can be displayed using an initial saturation image, and the V component can be displayed using an initial brightness image.

[0115] Optionally, the H component can range from 0 to 360 degrees. For example, a hue value of 0 represents red, 60 represents yellow, 120 represents green, 180 represents cyan, 240 represents blue, and 300 represents purple. The S component can range from 0 to 1. For example, a saturation value of 0 represents a grayscale image, and a saturation value of 1 represents color saturation. The V component can range from 0 to 1. For example, a brightness value of 0 represents black, and a brightness value of 1 represents white.

[0116] Step S202: Perform first image enhancement processing and first image denoising processing sequentially on the initial saturation image to determine the target saturation image;

[0117] Specifically, the initial saturation image can first undergo a first image enhancement process, and then the initial saturation image after the enhancement process can be denoised using a first image denoising process, thereby suppressing the noise amplified after the initial saturation image undergoes image enhancement processing.

[0118] Step S203: Perform second image enhancement processing and second image denoising processing on the initial brightness image in sequence to determine the target brightness image;

[0119] Specifically, the initial brightness image can first undergo a second image enhancement process, and then the enhanced initial brightness image can be denoised using a second image denoising process, thereby suppressing the noise amplified after the initial brightness image undergoes image enhancement processing.

[0120] Step S204: Determine the first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image.

[0121] Specifically, since the initial hue image has not undergone image enhancement and image denoising processing, when fusing the three components of the HSV space image, the hue component is still displayed using the initial hue image, but the saturation component to be fused can be displayed using the target saturation image, and the luminance component to be fused can be displayed using the target luminance image. It can be understood that the image after fusing the initial hue image, the target saturation image, and the target luminance image is an RGB space image, and the fused RGB space image is the first enhanced image mentioned above.

[0122] Optionally, the enhancement method further includes: denoising the first enhanced image using a semi-implicit differential ROF denoising model to determine the second enhanced image.

[0123] Optionally, the initial saturation image is sequentially subjected to a first image enhancement process and a first image denoising process to determine the target saturation image, including: performing a morphological closing operation on the initial saturation image to form a first saturation image; and performing a Gaussian filtering process on the first saturation image to determine the target saturation image.

[0124] Optionally, performing a second image enhancement process and a second image denoising process sequentially on the initial brightness image to determine the target brightness image includes: performing a logarithmic transformation on the initial brightness image to form a first brightness image; and performing bilateral filtering on the first brightness image to determine the target brightness image.

[0125] Optionally, determining the first enhanced image corresponding to the input image based on the initial tone image, the target saturation image, and the target brightness image includes: obtaining a first likelihood probability and a first prior probability of the target saturation image, and determining a first posterior conditional probability of the target saturation image based on the first likelihood probability and the first prior probability; obtaining a second likelihood probability and a second prior probability of the target brightness image, and determining a second posterior conditional probability of the target brightness image based on the second likelihood probability and the second prior probability; and determining the first enhanced image based on the first posterior conditional probability, the second posterior conditional probability, and the initial tone image.

[0126] Optionally, obtaining the first likelihood probability of the target saturation image includes: obtaining the first saturation of each pixel in the target saturation image and generating a saturation histogram; normalizing the saturation histogram to obtain a first mean and a first variance; and calculating the first likelihood probability of the target saturation image based on the first saturation, the first mean, the first variance, and the probability density function.

[0127] Optionally, obtaining the second likelihood probability of the target brightness image includes: obtaining the first brightness of each pixel in the target brightness image and generating a brightness histogram; normalizing the brightness histogram to obtain a second mean and a second variance; and calculating the second likelihood probability of the target brightness image based on the first brightness, the second mean, the second variance, and the probability density function.

[0128] Optionally, obtaining a first prior probability of the target saturation image and a second prior probability of the target brightness image includes: obtaining the width and height of the input image; determining the first prior probability based on the first saturation, width, and height of each pixel, wherein the target saturation image includes multiple first saturations; and determining the second prior probability based on the first brightness, width, and height of each pixel, wherein the target brightness image includes multiple first brightnesses.

[0129] This invention provides an electronic device, including a processor, a memory, and a program stored in the memory and executable on the processor. When the processor executes the program, it performs at least the following steps: acquiring and decomposing an HSV spatial image corresponding to an input image to obtain an initial hue image, an initial saturation image, and an initial brightness image of the HSV spatial image; sequentially performing a first image enhancement process and a first image denoising process on the initial saturation image to determine a target saturation image; sequentially performing a second image enhancement process and a second image denoising process on the initial brightness image to determine a target brightness image; and determining a first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image. The device described herein can be a server, PC, PAD, mobile phone, etc.

[0130] Optionally, the enhancement method further includes: denoising the first enhanced image using a semi-implicit differential ROF denoising model to determine the second enhanced image.

[0131] Optionally, the initial saturation image is sequentially subjected to a first image enhancement process and a first image denoising process to determine the target saturation image, including: performing a morphological closing operation on the initial saturation image to form a first saturation image; and performing a Gaussian filtering process on the first saturation image to determine the target saturation image.

[0132] Optionally, performing a second image enhancement process and a second image denoising process sequentially on the initial brightness image to determine the target brightness image includes: performing a logarithmic transformation on the initial brightness image to form a first brightness image; and performing bilateral filtering on the first brightness image to determine the target brightness image.

[0133] Optionally, determining the first enhanced image corresponding to the input image based on the initial tone image, the target saturation image, and the target brightness image includes: obtaining a first likelihood probability and a first prior probability of the target saturation image, and determining a first posterior conditional probability of the target saturation image based on the first likelihood probability and the first prior probability; obtaining a second likelihood probability and a second prior probability of the target brightness image, and determining a second posterior conditional probability of the target brightness image based on the second likelihood probability and the second prior probability; and determining the first enhanced image based on the first posterior conditional probability, the second posterior conditional probability, and the initial tone image.

[0134] Optionally, obtaining the first likelihood probability of the target saturation image includes: obtaining the first saturation of each pixel in the target saturation image and generating a saturation histogram; normalizing the saturation histogram to obtain a first mean and a first variance; and calculating the first likelihood probability of the target saturation image based on the first saturation, the first mean, the first variance, and the probability density function.

[0135] Optionally, obtaining the second likelihood probability of the target brightness image includes: obtaining the first brightness of each pixel in the target brightness image and generating a brightness histogram; normalizing the brightness histogram to obtain a second mean and a second variance; and calculating the second likelihood probability of the target brightness image based on the first brightness, the second mean, the second variance, and the probability density function.

[0136] Optionally, obtaining a first prior probability of the target saturation image and a second prior probability of the target brightness image includes: obtaining the width and height of the input image; determining the first prior probability based on the first saturation, width, and height of each pixel, wherein the target saturation image includes multiple first saturations; and determining the second prior probability based on the first brightness, width, and height of each pixel, wherein the target brightness image includes multiple first brightnesses.

[0137] This application also provides a computer program product, which, when executed on a data processing device, is suitable for executing an initialization program having at least the following method steps: acquiring and decomposing an HSV space image corresponding to an input image to obtain an initial hue image, an initial saturation image, and an initial brightness image of the HSV space image; sequentially performing a first image enhancement process and a first image denoising process on the initial saturation image to determine a target saturation image; sequentially performing a second image enhancement process and a second image denoising process on the initial brightness image to determine a target brightness image; and determining a first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image.

[0138] Optionally, the enhancement method further includes: denoising the first enhanced image using a semi-implicit differential ROF denoising model to determine the second enhanced image.

[0139] Optionally, the initial saturation image is sequentially subjected to a first image enhancement process and a first image denoising process to determine the target saturation image, including: performing a morphological closing operation on the initial saturation image to form a first saturation image; and performing a Gaussian filtering process on the first saturation image to determine the target saturation image.

[0140] Optionally, performing a second image enhancement process and a second image denoising process sequentially on the initial brightness image to determine the target brightness image includes: performing a logarithmic transformation on the initial brightness image to form a first brightness image; and performing bilateral filtering on the first brightness image to determine the target brightness image.

[0141] Optionally, determining the first enhanced image corresponding to the input image based on the initial tone image, the target saturation image, and the target brightness image includes: obtaining a first likelihood probability and a first prior probability of the target saturation image, and determining a first posterior conditional probability of the target saturation image based on the first likelihood probability and the first prior probability; obtaining a second likelihood probability and a second prior probability of the target brightness image, and determining a second posterior conditional probability of the target brightness image based on the second likelihood probability and the second prior probability; and determining the first enhanced image based on the first posterior conditional probability, the second posterior conditional probability, and the initial tone image.

[0142] Optionally, obtaining the first likelihood probability of the target saturation image includes: obtaining the first saturation of each pixel in the target saturation image and generating a saturation histogram; normalizing the saturation histogram to obtain a first mean and a first variance; and calculating the first likelihood probability of the target saturation image based on the first saturation, the first mean, the first variance, and the probability density function.

[0143] Optionally, obtaining the second likelihood probability of the target brightness image includes: obtaining the first brightness of each pixel in the target brightness image and generating a brightness histogram; normalizing the brightness histogram to obtain a second mean and a second variance; and calculating the second likelihood probability of the target brightness image based on the first brightness, the second mean, the second variance, and the probability density function.

[0144] Optionally, obtaining a first prior probability of the target saturation image and a second prior probability of the target brightness image includes: obtaining the width and height of the input image; determining the first prior probability based on the first saturation, width, and height of each pixel, wherein the target saturation image includes multiple first saturations; and determining the second prior probability based on the first brightness, width, and height of each pixel, wherein the target brightness image includes multiple first brightnesses.

[0145] It is obvious to those skilled in the art that the modules or steps of the present invention described above can be implemented using general-purpose computing devices. They can be centralized on a single computing device or distributed across a network of multiple computing devices. They can be implemented using computer-executable program code, and thus can be stored in a storage device for execution by a computing device. In some cases, the steps shown or described can be performed in a different order than those described herein, or they can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. Thus, the present invention is not limited to any particular combination of hardware and software.

[0146] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0147] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1A device that provides the functions specified in one or more boxes.

[0148] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0149] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0150] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0151] Memory may include non-persistent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0152] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0153] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.

[0154] As can be seen from the above description, the embodiments of this application achieve the following technical effects:

[0155] This application first decomposes the HSV spatial image corresponding to the obtained input image to obtain images corresponding to the three components (H, S, V) of the HSV spatial image, namely, the initial hue image, the initial saturation image, and the initial brightness image. Then, image enhancement processing is performed on the initial saturation image and the initial brightness image respectively. The image enhancement processing on the initial saturation image is denoted as the first image enhancement processing, and the image enhancement processing on the initial brightness image is denoted as the second image enhancement processing. Then, image denoising processing is performed on the enhanced images of the initial saturation image and the initial brightness image respectively. The image denoising processing on the enhanced image of the initial saturation image is denoted as the first image denoising processing, and the image denoising processing on the enhanced image of the initial brightness image is denoted as the second image denoising processing. The second image denoising process yields the target saturation image and the target brightness image after enhancement and denoising. This avoids the problem of poor image enhancement caused by the difficulty in effectively separating illumination and reflection components in the prior art. In addition, the initial hue image remains unchanged during the image enhancement process. When determining the first enhanced image corresponding to the input image based on the initial hue image, the target saturation image, and the target brightness image, since the target saturation image and the target brightness image have already undergone enhancement and denoising processes respectively, the RGB image after image enhancement, i.e., the first enhanced image, can be obtained by fusing the target saturation image and the target brightness image. The noise of the first enhanced image will not be amplified.

[0156] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the protection scope of this application.

Claims

1. An image enhancement method, characterized in that, include: Obtain and decompose the HSV space image corresponding to the input image to obtain the initial tone image, initial saturation image and initial brightness image of the HSV space image; The initial saturation image is sequentially subjected to a first image enhancement process and a first image denoising process to determine the target saturation image; The initial brightness image is sequentially subjected to a second image enhancement process and a second image denoising process to determine the target brightness image; Based on the initial tone image, the target saturation image, and the target brightness image, determine the first enhanced image corresponding to the input image. Determining a first enhanced image corresponding to the input image based on the initial tone image, the target saturation image, and the target brightness image includes: obtaining a first likelihood probability and a first prior probability of the target saturation image, and determining a first posterior conditional probability of the target saturation image based on the first likelihood probability and the first prior probability; obtaining a second likelihood probability and a second prior probability of the target brightness image, and determining a second posterior conditional probability of the target brightness image based on the second likelihood probability and the second prior probability; and determining the first enhanced image based on the first posterior conditional probability, the second posterior conditional probability, and the initial tone image, wherein the first enhanced image is determined using the formula... The calculation shows that c represents the first enhanced image, and f(·) is the conversion function from HSV space to RGB format. This represents the first posterior conditional probability. denoted as the second posterior conditional probability, ⊙ represents the pixel-wise multiplication operator, H represents the hue component in the HSV spatial image, S represents the saturation component in the HSV spatial image, and V represents the luminance component in the HSV spatial image.

2. The image enhancement method according to claim 1, characterized in that, The image enhancement method further includes: A semi-implicit differential ROF denoising model is used to denoise the first enhanced image in order to determine the second enhanced image.

3. The image enhancement method according to claim 1 or 2, characterized in that, The initial saturation image is sequentially subjected to a first image enhancement process and a first image denoising process to determine the target saturation image, including: The initial saturation image is subjected to morphological closing operation to form a first saturation image; The first saturation image is subjected to Gaussian filtering to determine the target saturation image.

4. The image enhancement method according to claim 1 or 2, characterized in that, The initial brightness image is sequentially subjected to a second image enhancement process and a second image denoising process to determine the target brightness image, including: The initial brightness image is logarithmically transformed to form a first brightness image; The first brightness image is subjected to bilateral filtering to determine the target brightness image.

5. The image enhancement method according to claim 1, characterized in that, Obtaining the first likelihood probability of the target saturation image includes: Obtain the first saturation of each pixel in the target saturation image and generate a saturation histogram; Normalize the saturation histogram to obtain the first mean and the first variance; The first likelihood probability of the target saturation image is calculated based on the first saturation, the first mean, the first variance, and the probability density function.

6. The image enhancement method according to claim 1, characterized in that, Obtaining the second likelihood probability of the target brightness image includes: Obtain the first brightness of each pixel in the target brightness image and generate a brightness histogram; Normalize the brightness histogram to obtain the second mean and the second variance; The second likelihood probability of the target brightness image is calculated based on the first brightness, the second mean, the second variance, and the probability density function.

7. The image enhancement method according to claim 1, characterized in that, Obtaining the first prior probability of the target saturation image and the second prior probability of the target brightness image includes: Obtain the width and height of the input image; The first prior probability is determined based on the first saturation of each pixel, the width, and the height, wherein the target saturation image includes a plurality of the first saturations; The second prior probability is determined based on the first brightness, width, and height of each pixel, wherein the target brightness image includes a plurality of the first brightness values.

8. An image enhancement device, characterized in that, include: The acquisition unit is used to acquire and decompose the HSV space image corresponding to the input image to obtain the initial tone image, initial saturation image and initial brightness image of the HSV space image; The first processing unit is used to sequentially perform a first image enhancement process and a first image denoising process on the initial saturation image to determine the target saturation image; The second processing unit is used to sequentially perform second image enhancement processing and second image denoising processing on the initial brightness image to determine the target brightness image; The third processing unit is configured to determine a first enhanced image of the input image based on the initial tone image, the target saturation image, and the target brightness image. The third processing unit includes: a fifth processing module, configured to acquire a first likelihood probability and a first prior probability of the target saturation image, and determine a first posterior conditional probability of the target saturation image based on the first likelihood probability and the first prior probability; a sixth processing module, configured to acquire a second likelihood probability and a second prior probability of the target brightness image, and determine a second posterior conditional probability of the target brightness image based on the second likelihood probability and the second prior probability; and a seventh processing module, configured to determine a first enhanced image based on the first posterior conditional probability, the second posterior conditional probability, and the initial tone image, wherein the first enhanced image is obtained using the formula... Calculations show that c represents the first enhanced image, and f( ) is a conversion function from HSV color space to RGB format. This represents the first posterior conditional probability. denoted as the second posterior conditional probability, ⊙ represents the pixel-wise multiplication operator, H represents the hue component in the HSV spatial image, S represents the saturation component in the HSV spatial image, and V represents the luminance component in the HSV spatial image.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein, when the program is executed, it controls the device on which the computer-readable storage medium is located to perform the image enhancement method according to any one of claims 1 to 7.

10. An electronic device, characterized in that, include: One or more processors, a memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs including methods for performing the image enhancement method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Image enhancement method

    CN111127350A