YUV image enhancement method and device, electronic equipment and storage medium

By directly converting between YUV and HSV color spaces in image processing, the problems of color space conversion complexity and computing resource consumption in the prior art are solved, and efficient image enhancement and conversion are achieved.

CN119477706APending Publication Date: 2025-02-18HANGZHOU MICROFRAME INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310842561.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-07-11
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

In the image processing, the prior art, due to the complexity of color space conversion and high consumption of computing resources, the computing efficiency and quantization errors lead to low computational efficiency and quantization errors, which in turn affects the quality of the image.

Method used

A method for enhancing YUV image is proposed. By calculating the image of the original YUV image in the HSV color space, performing image enhancement processing, and converting the enhanced HSV image back to the YUV image, avoiding unnecessary RGB color space conversion.

Benefits of technology

The color space conversion process is simplified, computing resources are saved, computing time is shortened, computing efficiency is improved, and quantization errors and banding effects are reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119477706A_ABST
    Figure CN119477706A_ABST
Patent Text Reader

Abstract

The invention discloses a YUV image enhancement method and device, electronic equipment and a storage medium. The method comprises the following steps: calculating a V-channel image and / or an S-channel image of an original YUV image in an HSV color space; and carrying out image enhancement processing on the V-channel image and / or the S-channel image in the HSV color space. And finally, according to the original image and the V-channel image and / or S-channel image before and after image enhancement in the HSV color space, calculating to obtain a finally output image. According to the method provided by the invention, a traditional conversion method is greatly simplified, the process from YUV to RGB to HSV and then from HSV to RGB to YUV is not needed, and the process from HSV to RGB to YUV is also not needed to carry out full-amount conversion on each channel component, so that the calculation resources are saved, and the calculation efficiency is improved. Meanwhile, quantization errors in the conversion process are avoided, and the banding effect is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing, and in particular to a method, device, electronic equipment and storage medium for YUV image enhancement. Background Art

[0002] In image processing, the most common color space is the RGB color space. In the RGB color space, an image is represented by three channels, namely red, green, and blue. Different combinations of these three colors can form almost all other colors. The RGB color space uses a linear combination of three color components to represent colors. Any color is related to these three components, and these three components are highly correlated. However, the sensitivity of the human eye to these three color components is different. Among monochrome colors, the human eye is least sensitive to red and most sensitive to blue, so the RGB color space is a color space with poor uniformity. If the similarity of colors is directly measured using Euclidean distance, the result will have a large deviation from human vision. For a certain color, it is difficult for us to infer a more accurate three-component value to represent it. Therefore, the RGB color space is suitable for display systems, but not for image processing.

[0003] In order to be closer to the visual law of the human eye, the application of HSV color space is becoming more and more widespread in image processing. The color space model is also represented by three channels, namely hue, saturation, and value. Hue is also called hue, and its value range is [0°, 360°]. The change of hue corresponds to the change of color. Saturation is also called vividness, which refers to the intensity of color. Its value range is [0, 100%]. The higher the saturation, the brighter the visual effect. Conversely, the weaker the visual effect. Brightness is also called brightness, which refers to the degree of light and dark. Its value range is [0, 100%]. When the brightness is 0, it corresponds to black. HSV color space is closer to people's perception of color than RGB color space. It expresses the hue, vividness and brightness of color very intuitively, which is convenient for color comparison.

[0004] However, in the field of video image compression technology, in order to facilitate encoding and transmission and reduce bandwidth usage, the YUV color space is generally used. In the YUV color space, three channels are still used for representation: the Y channel represents brightness, and the U and V channels represent chrominance. The principle is to compress and sample the color information that the human eye is relatively insensitive to based on the characteristics of the human eye, and obtain a relatively small file for transmission.

[0005] Although there are many color space models in the field of video image coding and processing, the color space models can be converted to each other. Different image spaces are suitable for different application scenarios. YUV is easier to transmit and saves bit rate, but it has no advantage in image enhancement. At present, in the video encoding process, the video image format is often in YUV format. If you want to process the video image, you need to convert the YUV color space to the RGB color space suitable for image processing. In order to make the image closer to the visual law of the human eye and improve the subjective effect, the RGB color space can be further converted into the HSV color space. After the image is processed, the HSV color space is converted into the YUV color space for encoding, transmission and storage.

[0006] The traditional methods for converting between color spaces are as follows:

[0007] YUV to RGB: Among them, R, G, B are the three channel components of R, G, and B in the RGB color space; Y, U, and V are the three channel components of Y, U, and V in the YUV color space; A, B, C, and R are the three channel components of R, G, and B in the RGB color space; v , g u , g v 、b u is the coefficient; n is a positive integer.

[0008] In the YUV color space, different color spaces can be subdivided according to different chromaticity coordinate values. Correspondingly, different coefficient values ​​are taken during the conversion of different subdivided color spaces.

[0009] RGB to HSV:

[0010] Among them, R, G, B are the three channel components of R, G, B in the RGB color space; H, S, V are the three channel components of H, S, V in the HSV color space; M and C are intermediate variables; is the coefficient; the x%y function means x-[x / y]*y.

[0011] HSV to RGB:

[0012] Among them, R, G, B are the three channel components of R, G, B in the RGB color space; H, S, V are the three channel components of H, S, V in the HSV color space; X, M, C are intermediate variables; x%y function means x-[x / y]*y.

[0013] Although in the HSV color space, H represents hue, and changes in hue correspond to changes in color. In the process of image enhancement, hue generally does not change. However, as can be seen from the above formula, the traditional conversion between RGB and HSV requires the use of the value of the H channel component, and the H channel component has a very high correlation during the conversion process.

[0014] RGB to YUV: Among them, R, G, B are the three channel components of R, G, and B in the RGB color space; Y, U, and V are the three channel components of Y, U, and V in the YUV color space; k r , k g , k b , k0 is the coefficient.

[0015] In the YUV color space, different color spaces can be subdivided according to different chromaticity coordinate values. Correspondingly, different coefficient values ​​are taken during the conversion of different subdivided color spaces.

[0016] It can be seen that although different color spaces can be converted, the traditional transformation method requires a full transformation of each channel component during the conversion process. The transformation and inverse transformation involve a lot of calculations, which requires a lot of computing resources, has low computing efficiency, and is very time-consuming to run on the CPU. The value range of some channel components is a floating point number [0, 1], which increases the complexity of the calculation. In addition, multiple conversions are prone to cause quantization errors, which in turn lead to the appearance of banding effects in the image. Summary of the invention

[0017] Since the existing methods have the above problems, an embodiment of the present invention proposes a YUV image enhancement method.

[0018] Specifically, the embodiment of the present invention provides the following technical solutions: In a first aspect, an embodiment of the present invention provides a YUV image enhancement method, comprising: Calculate the first image of the original image in the HSV color space.

[0019] The original image is a YUV image.

[0020] Perform image enhancement processing on the first image in the HSV color space to obtain a second image in the HSV color space.

[0021] A third image after image enhancement is obtained by calculation according to the original image, the first image in the HSV color space, and the second image in the HSV color space.

[0022] The third image is a YUV image.

[0023] In a second aspect, an embodiment of the present invention provides a YUV image enhancement device, comprising: The first calculation module is used to calculate a first image of the original image in the HSV color space.

[0024] The original image is a YUV image.

[0025] The image enhancement module is used to perform image enhancement processing on the first image in the HSV color space to obtain a second image in the HSV color space.

[0026] The second calculation module is used to calculate the third image after image enhancement according to the original image, the first image in the HSV color space and the second image in the HSV color space.

[0027] The third image is a YUV image.

[0028] In a third aspect, an embodiment of the present invention further provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, a YUV image enhancement method as described in the first aspect is implemented.

[0029] In a fourth aspect, an embodiment of the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements a YUV image enhancement method as described in the first aspect.

[0030] It can be seen from the above technical solutions that the method provided by the present invention greatly simplifies the traditional conversion method. There is no need to convert from YUV to RGB to HSV, and then from HSV to RGB to YUV, and there is no need to convert each channel component in full, which saves computing resources, shortens computing time, and improves computing efficiency. In addition, it also avoids quantization errors in the conversion process and reduces the generation of banding effects. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0032] Figure 1 The figure is a flow chart of a YUV image enhancement method provided by an embodiment of the present invention.

[0033] Figure 2 It is a structural schematic diagram of a YUV image enhancement device provided by an embodiment of the present invention.

[0034] Figure 3 It is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0035] The specific implementation of the present invention is further described below in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and cannot be used to limit the protection scope of the present invention.

[0036] Figure 1 A flowchart of a YUV image enhancement method provided by an embodiment of the present invention is shown. Figure 1 As shown, the YUV image enhancement method provided by the embodiment of the present invention specifically includes the following contents:

[0037] Embodiment 1:

[0038] Calculate the first image of the original image in the HSV color space.

[0039] The original image is a YUV image.

[0040] The first image is a V channel image in the HSV color space, denoted as V1.

[0041] Among them, R, G, and B are the three channel components corresponding to the RGB color space; Y, U, and V are the three channel components corresponding to the original image; A, B, C, and R arev , g u , g v 、b u is the coefficient, and n is a positive integer.

[0042] The first image in the HSV color space is subjected to image enhancement processing to obtain a second image in the HSV color space, which is recorded as V2.

[0043] It should be understood that existing image enhancement processing methods are within the scope of the present disclosure, including but not limited to: sharpening, grayscale conversion, histogram enhancement, spatiotemporal filtering, image segmentation, etc. The present disclosure does not specifically limit the image enhancement method.

[0044] A third image after image enhancement is obtained by calculation according to the original image, the first image in the HSV color space, and the second image in the HSV color space.

[0045] The third image is a YUV image.

[0046]

[0047] Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components corresponding to the original image, respectively; y2, u2, and v2 represent the Y, U, and V three-channel components corresponding to the third image after image enhancement, respectively; V1 represents the first image in the HSV color space described in this embodiment; V2 represents the second image in the HSV color space described in this embodiment; n is a positive integer; c, K V is the coefficient.

[0048] Embodiment 2: Calculate the first image of the original image in the HSV color space.

[0049] The original image is a YUV image.

[0050] The first image is an S channel image in the HSV color space, denoted as S1.

[0051] Wherein, S1 represents the first image in the HSV color space described in this embodiment; V1 represents the V channel image in the HSV color space described in this embodiment; R, G, and B are the three channel components of R, G, and B corresponding to the RGB color space; Y, U, and V are the three channel components corresponding to the original image; M and C are intermediate variables; A, B, c, and r arev , g u , g v 、b u , is the coefficient; n is a positive integer.

[0052] The first image in the HSV color space is subjected to image enhancement processing to obtain a second image in the HSV color space, which is recorded as S2.

[0053] It should be understood that existing image enhancement processing methods are within the scope of the present disclosure, including but not limited to: sharpening, grayscale conversion, histogram enhancement, spatiotemporal filtering, image segmentation, etc. The present disclosure does not specifically limit the image enhancement method.

[0054] A third image after image enhancement is obtained by calculation according to the original image, the first image in the HSV color space, and the second image in the HSV color space.

[0055] The third image is a YUV image.

[0056]

[0057] Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components corresponding to the original image, respectively; y2, u2, and v2 represent the Y, U, and V three-channel components corresponding to the third image after image enhancement, respectively; S1 represents the first image in the HSV color space described in this embodiment; S2 represents the second image in the HSV color space described in this embodiment; A, c, and K S is the coefficient; n is a positive integer.

[0058] Embodiment three: Calculate the first image of the original image in the HSV color space.

[0059] The original image is a YUV image.

[0060] The first image includes a V channel image in an HSV color space and an S channel image in an HSV color space.

[0061] Among them, S1 represents the S channel image in the HSV color space described in this embodiment; V1 represents the V channel image in the HSV color space described in this embodiment; R, G, B are the three channel components of R, G, and B corresponding to the RGB color space; Y, U, and V are the three channel components corresponding to the original image; A, B, c, and r are v , g u , g v 、b u , is the coefficient, n is a positive integer; M and C are intermediate variables.

[0062] Perform image enhancement processing on the first image in the HSV color space to obtain a second image in the HSV color space.

[0063] The second image includes a V channel image in the HSV color space after image enhancement processing, which is recorded as V2, and an S channel image in the HSV color space after image enhancement processing, which is recorded as S2.

[0064] It should be understood that existing image enhancement processing methods are within the scope of the present disclosure, including but not limited to: sharpening, grayscale conversion, histogram enhancement, spatiotemporal filtering, image segmentation, etc. The present disclosure does not specifically limit the image enhancement method.

[0065] A third image after image enhancement is obtained by calculation according to the original image, the first image in the HSV color space, and the second image in the HSV color space.

[0066] The third image is a YUV image.

[0067]

[0068] Among them, y1, u1, and v1 respectively represent the Y, U, and V three-channel components corresponding to the original image; y2, u2, and v2 respectively represent the Y, U, and V three-channel components corresponding to the third image after the image enhancement; V1 and S1 respectively represent the V and S two-channel components corresponding to the first image in the HSV color space described in this embodiment; V2 and S2 respectively represent the V and S two-channel components corresponding to the second image in the HSV color space described in this embodiment; A, c, K S , K V is the coefficient; n is a positive integer.

[0069] Figure 2 FIG. 4 shows a schematic diagram of the structure of a YUV image enhancement device provided by an embodiment of the present invention. Figure 2 As shown:

[0070] Embodiment 4:

[0071] The first calculation module is used to calculate a first image of the original image in the HSV color space.

[0072] The original image is a YUV image.

[0073] The first image is a V channel image in the HSV color space, denoted as V1.

[0074] Among them, R, G, and B are the three channel components corresponding to the RGB color space; Y, U, and V are the three channel components corresponding to the original image; A, B, C, and R are v , g u , g v 、b u is the coefficient, and n is a positive integer.

[0075] The image enhancement module is used to perform image enhancement processing on the first image in the HSV color space to obtain a second image in the HSV color space, which is recorded as V2.

[0076] It should be understood that existing image enhancement processing methods are within the scope of the present disclosure, including but not limited to: sharpening, grayscale conversion, histogram enhancement, spatiotemporal filtering, image segmentation, etc. The present disclosure does not specifically limit the image enhancement method.

[0077] The second calculation module is used to calculate the third image after image enhancement according to the original image, the first image in the HSV color space and the second image in the HSV color space.

[0078] The third image is a YUV image.

[0079]

[0080] Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components corresponding to the original image, respectively; y2, u2, and v2 represent the Y, U, and V three-channel components corresponding to the third image after image enhancement, respectively; V1 represents the first image in the HSV color space described in this embodiment; V2 represents the second image in the HSV color space described in this embodiment; n is a positive integer; c, K V is the coefficient.

[0081] Embodiment five: The first calculation module is used to calculate a first image of the original image in the HSV color space.

[0082] The original image is a YUV image.

[0083] The first image is an S channel image in the HSV color space, denoted as S1.

[0084] Wherein, S1 represents the first image in the HSV color space described in this embodiment; V1 represents the V channel image in the HSV color space described in this embodiment; R, G, and B are the three channel components of R, G, and B corresponding to the RGB color space; Y, U, and V are the three channel components corresponding to the original image; M and C are intermediate variables; A, B, c, and r are v , g u , g v 、b u , is the coefficient; n is a positive integer.

[0085] The image enhancement module is used to perform image enhancement processing on the first image in the HSV color space to obtain a second image in the HSV color space, which is denoted as S2.

[0086] It should be understood that existing image enhancement processing methods are within the scope of the present disclosure, including but not limited to: sharpening, grayscale conversion, histogram enhancement, spatiotemporal filtering, image segmentation, etc. The present disclosure does not specifically limit the image enhancement method.

[0087] The second calculation module is used to calculate the third image after image enhancement according to the original image, the first image in the HSV color space and the second image in the HSV color space.

[0088] The third image is a YUV image.

[0089]

[0090] Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components corresponding to the original image, respectively; y2, u2, and v2 represent the Y, U, and V three-channel components corresponding to the third image after image enhancement, respectively; S1 represents the first image in the HSV color space described in this embodiment; S2 represents the second image in the HSV color space described in this embodiment; A, c, and K S is the coefficient; n is a positive integer.

[0091] Embodiment six: The first calculation module is used to calculate a first image of the original image in the HSV color space.

[0092] The original image is a YUV image.

[0093] The first image includes a V channel image in an HSV color space and an S channel image in an HSV color space.

[0094] Among them, S1 represents the S channel image in the HSV color space described in this embodiment; V1 represents the V channel image in the HSV color space described in this embodiment; R, G, B are the three channel components of R, G, and B corresponding to the RGB color space; Y, U, and V are the three channel components corresponding to the original image; A, B, c, and r are v , g u , g v 、b u , is the coefficient, n is a positive integer; M and C are intermediate variables.

[0095] The image enhancement module is used to perform image enhancement processing on the first image in the HSV color space to obtain a second image in the HSV color space.

[0096] The second image includes a V channel image in the HSV color space after image enhancement processing, which is recorded as V2, and an S channel image in the HSV color space after image enhancement processing, which is recorded as S2.

[0097] It should be understood that existing image enhancement processing methods are within the scope of the present disclosure, including but not limited to: sharpening, grayscale conversion, histogram enhancement, spatiotemporal filtering, image segmentation, etc. The present disclosure does not specifically limit the image enhancement method.

[0098] The second calculation module is used to calculate the third image after image enhancement according to the original image, the first image in the HSV color space and the second image in the HSV color space.

[0099] The third image is a YUV image.

[0100]

[0101] Among them, y1, u1, and v1 respectively represent the Y, U, and V three-channel components corresponding to the original image; y2, u2, and v2 respectively represent the Y, U, and V three-channel components corresponding to the third image after the image enhancement; V1 and S1 respectively represent the V and S two-channel components corresponding to the first image in the HSV color space described in this embodiment; V2 and S2 respectively represent the V and S two-channel components corresponding to the second image in the HSV color space described in this embodiment; A, c, K S , K V is the coefficient; n is a positive integer.

[0102] Based on the same inventive concept, another embodiment of the present invention provides an electronic device, such as Figure 3 As shown, the electronic device specifically includes the following contents: a processor 301 , a memory 302 , a communication interface 303 and a communication bus 304 .

[0103] The processor 301 , the memory 302 , and the communication interface 303 communicate with each other via the communication bus 304 ; the communication interface 303 is used to implement information transmission between various devices.

[0104] The processor 301 is used to call the computer program in the memory 302, and the processor implements all steps of the above-mentioned YUV image enhancement method when executing the computer program.

[0105] Based on the same inventive concept, another embodiment of the present invention provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, all steps of the above-mentioned YUV image enhancement method are implemented.

[0106] The logic instructions in the above-mentioned memory can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.

[0107] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the embodiments of the present invention. Those of ordinary skill in the art may understand and implement them without creative effort.

[0108] In addition, in the embodiments of the present invention, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Those skilled in the art may combine and combine the different embodiments and features of the different embodiments described in this specification without contradiction.

[0109] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for YUV image enhancement, characterized in that: include: Calculate the first image of the original image in the HSV color space; The original image is a YUV image; Performing image enhancement processing on the first image in the HSV color space to obtain a second image in the HSV color space; Obtaining an image-enhanced third image by calculation according to the original image, the first image in the HSV color space, and the second image in the HSV color space; The third image is a YUV image.

2. The method for YUV image enhancement according to claim 1, characterized in that: The first image in the HSV color space is a V channel image in the HSV color space and / or an S channel image in the HSV color space.

3. The method for YUV image enhancement according to claim 1, characterized in that: The second image in the HSV color space is a V channel image in the HSV color space and / or an S channel image in the HSV color space.

4. The method for YUV image enhancement according to claim 2, characterized in that: The calculation method of the V channel image in the HSV color space is: Among them, V1 is the V channel image in the HSV color space; R, G, B are the three channel components of R, G, and B in the RGB color space; Y, U, and V are the three channel components of Y, U, and V in the original image; A, B, c, and r are v , g u , g v 、b u is the coefficient, and n is a positive integer.

5. The method for YUV image enhancement according to claim 2, characterized in that: The calculation method of the S channel image in the HSV color space is: Among them, V1 is the V channel image in the HSV color space; S1 is the S channel image in the HSV color space; R, G, B are the three channel components of R, G, and B in the RGB color space; Y, U, and V are the three channel components of Y, U, and V in the original image; M and C are intermediate variables; A, B, c, and r are v , g u , g v 、b u , is the coefficient; n is a positive integer.

6. The method for YUV image enhancement according to claim 1, characterized in that: The image enhancement processing performed on the first image in the HSV color space includes: sharpening, grayscale transformation, histogram enhancement, spatiotemporal filtering, and image segmentation.

7. The method for YUV image enhancement according to claim 1, characterized in that: When the first image in the HSV color space and the second image in the HSV color space are both V channel images in the HSV color space, the third image after image enhancement is calculated according to the original image, the first image in the HSV color space, and the second image in the HSV color space, and the calculation method is: , Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components corresponding to the original image, respectively; y2, u2, and v2 represent the Y, U, and V three-channel components corresponding to the third image after image enhancement, respectively; V1 represents the first image in the HSV color space; V2 represents the second image in the HSV color space; n is a positive integer; c, K V is the coefficient.

8. The method for YUV image enhancement according to claim 1, characterized in that: When the first image in the HSV color space and the second image in the HSV color space are both S-channel images in the HSV color space, the third image after image enhancement is calculated according to the original image, the first image in the HSV color space, and the second image in the HSV color space, and the calculation method is: , Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components corresponding to the original image, respectively; y2, u2, and v2 represent the Y, U, and V three-channel components corresponding to the third image after image enhancement, respectively; S1 represents the first image in the HSV color space; S2 represents the second image in the HSV color space; n is a positive integer; A, c, and K S is the coefficient.

9. The method for YUV image enhancement according to claim 1, characterized in that: When the first image in the HSV color space is a V channel image in the HSV color space and an S channel image in the HSV color space, and the second image in the HSV color space is a V channel image in the HSV color space and an S channel image in the HSV color space, the third image after image enhancement is calculated according to the original image, the first image in the HSV color space, and the second image in the HSV color space, and the calculation method is: , Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components of the original image respectively; y2, u2, and v2 represent the Y, U, and V three-channel components of the third image after image enhancement respectively; V1 and S1 represent the V and S two-channel components of the first image in the HSV color space respectively; V2 and S2 represent the V and S two-channel components of the second image in the HSV color space respectively; c, A, and K S , K V is the coefficient; n is a positive integer.

10. A YUV image enhancement device, characterized in that: include: A first calculation module, used for calculating a first image of the original image in the HSV color space; The original image is a YUV image; An image enhancement module, used for performing image enhancement processing on the first image in the HSV color space to obtain a second image in the HSV color space; A second calculation module, used for calculating a third image after image enhancement according to the original image, the first image in the HSV color space, and the second image in the HSV color space; The third image is a YUV image.

11. The YUV image enhancement device according to claim 10, characterized in that: The first image in the HSV color space is a V channel image in the HSV color space and / or an S channel image in the HSV color space.

12. The YUV image enhancement device according to claim 10, characterized in that: The second image in the HSV color space is a V channel image in the HSV color space and / or an S channel image in the HSV color space.

13. The YUV image enhancement device according to claim 11, characterized in that: The calculation method of the V channel image in the HSV color space is: Among them, V1 is the V channel image in the HSV color space; R, G, B are the three channel components of R, G, and B in the RGB color space; Y, U, and V are the three channel components of Y, U, and V in the original image; A, B, c, and r are v , g u , g v 、b u is the coefficient, and n is a positive integer.

14. The YUV image enhancement device according to claim 11, characterized in that: The calculation method of the S channel image in the HSV color space is: Among them, V1 is the V channel image in the HSV color space; S1 is the S channel image in the HSV color space; R, G, B are the three channel components of R, G, and B in the RGB color space; Y, U, and V are the three channel components of Y, U, and V in the original image; M and C are intermediate variables; A, B, c, and r are v , g u , g v 、b u , is the coefficient; n is a positive integer.

15. The YUV image enhancement device according to claim 10, characterized in that: The image enhancement processing performed on the first image in the HSV color space includes: sharpening, grayscale transformation, histogram enhancement, spatiotemporal filtering, and image segmentation.

16. The YUV image enhancement device according to claim 10, characterized in that: When the first image in the HSV color space and the second image in the HSV color space are both V channel images in the HSV color space, the third image after image enhancement is calculated according to the original image, the first image in the HSV color space, and the second image in the HSV color space, and the calculation method is: , Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components corresponding to the original image, respectively; y2, u2, and v2 represent the Y, U, and V three-channel components corresponding to the third image after image enhancement, respectively; V1 represents the first image in the HSV color space; V2 represents the second image in the HSV color space; n is a positive integer; c, K V is the coefficient.

17. The YUV image enhancement device according to claim 10, characterized in that: When the first image in the HSV color space and the second image in the HSV color space are both S-channel images in the HSV color space, the third image after image enhancement is calculated according to the original image, the first image in the HSV color space, and the second image in the HSV color space, and the calculation method is: , Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components corresponding to the original image, respectively; y2, u2, and v2 represent the Y, U, and V three-channel components corresponding to the third image after image enhancement, respectively; S1 represents the first image in the HSV color space; S2 represents the second image in the HSV color space; n is a positive integer; A, c, and K S is the coefficient.

18. The YUV image enhancement device according to claim 10, characterized in that: When the first image in the HSV color space is a V channel image in the HSV color space and an S channel image in the HSV color space, and the second image in the HSV color space is a V channel image in the HSV color space and an S channel image in the HSV color space, the third image after image enhancement is calculated according to the original image, the first image in the HSV color space, and the second image in the HSV color space, and the calculation method is: , Wherein, y1, u1, and v1 represent the Y, U, and V three-channel components of the original image respectively; y2, u2, and v2 represent the Y, U, and V three-channel components of the third image after image enhancement respectively; V1 and S1 represent the V and S two-channel components of the first image in the HSV color space respectively; V2 and S2 represent the V and S two-channel components of the second image in the HSV color space respectively; c, A, and K S , K V is the coefficient; n is a positive integer.

19. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the YUV image enhancement method according to any one of claims 1 to 9 is implemented.

20. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the YUV image enhancement method according to any one of claims 1 to 9 is implemented.