Low-light image enhancement method and system based on learnable YUV space
By decoupling luminance and chrominance in the learnable YUV space, and combining illumination-aware position coding and multi-branch denoising techniques, the problem of luminance and chrominance consistency in low-light images is solved, achieving synergistic enhancement of luminance and color and improving the visual quality of the image.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-26
- Publication Date
- 2026-03-27
AI Technical Summary
Existing low-light image enhancement methods are insufficient in terms of brightness and chromaticity consistency, noise characteristics and structural semantics joint modeling, and are difficult to effectively handle the degradation problem of ancient book images under complex lighting conditions, especially in terms of brightness restoration and detail fidelity.
By mapping images to a learnable YUV space, decoupling luminance and chrominance components, and employing a light-aware positional coding mechanism for luminance enhancement, combined with multi-branch parallel denoising and pixel-level dynamic fusion, and finally combining global color histogram priors and a learnable color shift corrector for color correction, a synergistic enhancement of luminance and color is achieved.
It significantly improves the brightness, clarity, and color fidelity of low-light images, effectively suppresses noise and color cast, and achieves high-quality, detailed, and natural-colored visual restoration.
Smart Images

Figure CN121746264A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of image processing and computer vision, and more particularly to a low-light image enhancement method and system based on a learnable YUV space. BACKGROUND
[0002] Low-light image enhancement is an important research direction in the field of image processing and computer vision, and its core goal is to improve the visibility and structural readability of images under weak light or non-uniform illumination conditions. In scenarios such as document archiving, digital restoration of ancient books, night monitoring, and intelligent recognition systems, due to limited performance of the shooting device or insufficient environmental light source, the images collected often present phenomena such as low overall brightness, damaged details, and color shift. Such degradation not only interferes with human eye observation, but also seriously affects the accuracy of subsequent tasks such as character recognition (OCR), layout structure analysis, and target detection. Therefore, how to achieve high-fidelity image restoration under low-light conditions has always been a key challenge in the field of image enhancement.
[0003] Early low-light image enhancement methods are mainly based on image transformation and illumination prior. Histogram equalization and gamma correction adjust the pixel intensity distribution to improve brightness and contrast, although simple to implement, but often accompanied by excessive stretching of details or overexposure in local regions. Subsequent Retinex theory methods decompose the image into illumination and reflection components, attempting to achieve adaptive enhancement through illumination estimation. Although it improves image brightness to some extent, it is difficult to handle non-uniform illumination and complex texture backgrounds due to reliance on fixed parameters and static assumptions, often resulting in unnatural colors or structural breaks, especially in ancient book images, which can easily cause paper texture and ink to blend.
[0004] With the rise of deep learning, low-light enhancement methods have gradually shifted from rule-based algorithms to data-driven end-to-end models. Convolutional Neural Network (CNN)-based enhancement methods such as Retinex-Net and KinD model improve enhancement results by learning the mapping relationship between illumination and reflection, but due to the lack of explicit modeling of noise and color consistency, they still tend to amplify noise in dark areas or introduce artifacts. Further development of the Transformer structure, such as LLFormer and Restormer, enhances the ability to capture image context information with global attention mechanisms, improving brightness restoration and overall structural fidelity to some extent. However, such methods still struggle to balance structural edge clarity and color stability in extremely dark areas and detail areas, often resulting in high-frequency noise residue or color shift in high-light areas.
[0005] In recent years, generative models such as low-light enhancement methods based on diffusion models or generative adversarial networks (GAN) have been introduced into this field to further improve the detail recovery capability. However, such models usually have high computational complexity and long inference time, which is not suitable for mobile applications and batch processing of ancient book images. In addition, the high degree of freedom of generative models may lead to color shift or generation of pseudo-structures, lacking the ability to constrain the structure of real document images.
[0006] In existing research, the method closest to the present invention is mainly based on a low-light enhancement scheme combining Retinex decomposition and deep learning network. This type of method usually first models the brightness of the image or estimates the illumination, then repairs the reflection details through the network, and reconstructs the enhanced results. Although it takes into account brightness and structure to some extent, it does not decouple the modeling of brightness and chrominance, nor does it introduce an adaptive noise recognition mechanism, and it still cannot effectively handle the complex degradation problems such as paper texture interference and uneven ink contrast in ancient book images. With the development of low-light image enhancement technology from brightness enhancement to multi-dimensional collaborative enhancement, joint modeling of brightness-chrominance consistency, noise characteristics, and structural semantics has become a breakthrough direction. The present invention is proposed in this context to explore a more robust enhancement mechanism in the cross-field of color space modeling, structure strengthening, and noise perception. SUMMARY
[0007] The purpose of the present invention is to provide a low-light image enhancement method and system based on a learnable YUV space, which maps the image to a learnable YUV space and decouples the processing, and then combines multiple enhancement and correction mechanisms to achieve brightness enhancement, color correction, and quality improvement of low-light images.
[0008] To achieve the above purpose, the present invention provides the following technical solutions: A low-light image enhancement method based on a learnable YUV space, comprising: S1, obtaining an original RGB image collected under low-light environment and pre-processing to obtain a pre-processed RGB image; S2, mapping the pre-processed RGB image to a learnable YUV color space to decouple the brightness component and the chrominance component; S3, using the brightness component, using an illumination perception position encoding mechanism for enhancement and structure modeling to obtain an enhanced brightness feature; S4, performing multi-branch parallel denoising and pixel-level dynamic fusion on the chrominance component to obtain a purified chrominance component; S5, fusing the enhanced brightness component and the purified chrominance component, and combining global color histogram prior, brightness-guided color attention, and learnable color correction to perform color correction; S6. Convert the corrected YUV image to an enhanced RGB image.
[0009] Furthermore, the preprocessing process S1 specifically includes: Normalize the raw RGB images acquired under low light conditions; The expression for the preprocessed RGB image is as follows: .
[0010] Furthermore, the preprocessed RGB image is mapped to a learnable YUV color space, and the luminance and chrominance components are decoupled, specifically as follows: Luminance components are generated using convex combination. The calculation formula is: (1) Among them, satisfying The constraints, These are weighting coefficients; The chromaticity components are generated using an unconstrained linear mapping, and the calculation formula is as follows: (2) (3) in, and This represents the learnable linear mapping coefficients used to construct the chromaticity components U and V.
[0011] Furthermore, in step S3, an illumination-aware position encoding mechanism is used for enhancement and structural modeling to obtain enhanced brightness features, specifically: Build a learnable two-dimensional position coding basic template The base template adaptively learns the spatial structure pattern of the image during forward propagation; Using the original luminance component Y as the guiding signal, an illumination weight map is generated through a lightweight illumination gating network. Specifically, it is expressed as: (4) In formula (4), Conv represents a convolutional layer with learnable kernel weights and bias terms, used to extract illumination-related spatial features from the brightness component Y. The obtained illumination weight map With Learnable Position Encoding Basic Template Element-wise multiplication is performed to generate the final position code for illumination sensing. : (5); Enhanced brightness features , the expression is: (6) wherein, is the position encoding of the final illumination perception generated, is the luminance component.
[0012] Further, the S4, the chrominance component is multi-branch parallel denoising and pixel-level dynamic fusion, to obtain the purified chrominance component, specifically: The chrominance signal , using a convolutional encoder containing stepwise down-sampling to extract multi-scale noise dominant features N: (7) Based on the noise dominant feature N, through a weight generator composed of 1x1 convolution and up-sampling operation, K weight maps with the same resolution as the input are generated : (8) K structure same but parameter sharing parallel denoising sub-network is constructed; each sub-network processes the chrominance signal , and introduces CBAM spatial attention mechanism, so that each branch can adaptively focus on the high noise area in its feature map, while retaining the edge structure; The processing process of the kth branch is represented as: (9) (10) (11) The feature output of the kth denoising branch is represented, which reflects the independent estimation of the chrominance noise and the detail structure of the branch; The branch attention weight map generated by the CBAM spatial attention mechanism is used to highlight the high noise or structure sensitive area; σ represents the Sigmoid activation function, which is used to map the features to the interval to generate weights that can be used for pixel-level modulation; The denoising result of each branch is multiplied element by element with the corresponding weight map and summed to obtain the fused denoising feature; And the denoising feature is passed through a 3x3 convolution and a tanh activation function, added to the original chrominance input in residual form, to obtain the final purified chrominance component : (12).
[0013] Further, the S5, the luminance component after fusion enhancement and the chrominance component after purification are combined, and the global color histogram prior, the luminance guided color attention and the learnable color bias corrector are combined for color correction, specifically: First, the global color histogram prior of the input image is extracted : (13) wherein, represents the probability distribution of color channel c; in formula (13), Softmax is a normalization function, which is used to convert the input feature into a probability distribution on each color channel; represents a multi-layer perception network, which is used to perform nonlinear mapping on the pooled global color statistical features; Pool represents a global pooling operation, which is used to extract the overall statistics of the input image on each color channel; represents an operation of performing convolution feature extraction on the input YUV image, which is used to obtain local color and luminance structure information to assist the construction of the histogram prior; The luminance guided color attention mechanism is introduced, and the color attention mechanism interacts with the color feature and the luminance feature to generate a color attention weight map : (14) In formula (14), , represent feature mapping functions used to extract , respectively; Sigmoid(·) is used to normalize the fused luminance-color feature to the interval to generate a pixel-level color attention weight ; The color attention weight map is used to reweight the color feature in space: (15) Before the final color correction, an intermediate image is obtained; wherein, represents a three-channel fused image after luminance enhancement and chrominance denoising, which has not yet undergone the color correction step and will be used as the input of the color correction; then, a trainable 3x3 color correction matrix and a bias vector are used to perform global linear transformation on the image: (16) Wherein, the matrix M is used for modeling the coupling and correction between color channels, and the vector b is used for compensating residual color cast. After the above-mentioned three mechanisms are cooperatively processed, the enhanced YUV image has natural color and good consistency .
[0014] Further, the S6 converts the corrected YUV image into an enhanced RGB image, specifically: The YUV image after comprehensive correction by the ACCM module is mapped back to the standard RGB color space through inverse conversion, and finally an enhanced image is output : (17) The processed image is significantly improved in key visual indicators such as brightness, detail texture definition, noise suppression effect, and color fidelity.
[0015] The application also provides a system for executing a low-light image enhancement method based on a learnable YUV space, comprising: An image acquisition module is configured to acquire an original RGB image collected in a low-light environment and perform preprocessing to obtain a preprocessed RGB image; A learnable YUV space conversion module is configured to map the preprocessed RGB image to a learnable YUV color space to decouple a luminance component and a chrominance component; A light-aware position encoding module is configured to utilize the luminance component and introduce a light-aware position encoding mechanism to perform enhancement and structure modeling to obtain an enhanced luminance feature; An adaptive noise fusion denoising module is configured to perform multi-branch parallel denoising and pixel-level dynamic fusion on the chrominance component to obtain a purified chrominance component; An adaptive color consistency module is configured to fuse the enhanced luminance component and the purified chrominance component, and combine a global color histogram prior, luminance-guided color attention, and a learnable color cast corrector to perform color correction; An image reconstruction module is configured to convert the corrected YUV image into an enhanced RGB image.
[0016] The application also provides an electronic device, comprising: A memory storing a computer program; A processor configured to execute the computer program to implement a low-light image enhancement method based on a learnable YUV space.
[0017] According to the embodiments provided by the application, the application has the following technical effects compared with the prior art: The application realizes effective decoupling of luminance and chrominance information by mapping the original low-light RGB image to a learnable YUV color space, then performs structure enhancement of the luminance component in a targeted manner according to light perception, performs multi-branch parallel denoising and dynamic fusion on the chrominance component, finally performs fine color correction in combination with a global color prior, luminance guided attention and a learnable corrector, and finally outputs an enhanced image through inverse conversion, thereby significantly improving the luminance, definition and color fidelity of the low-light image, effectively suppressing noise and color deviation, and realizing high-quality, detailed and natural color visual recovery effect under complex lighting conditions. BRIEF DESCRIPTION OF DRAWINGS
[0018] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, the drawings in the following description are only embodiments of the present application, and for those skilled in the art, other drawings can also be obtained without creative labor on the basis of the provided drawings.
[0019] The present application provides a low-light image enhancement method and system based on a learnable YUV space, which will be further described below in combination with the drawings. Figure 1 is the overall flowchart of the low-light image enhancement method based on a learnable YUV space provided by the embodiment 1 of the present application; Figure 2 is the overall architecture diagram of the low-light image enhancement system based on a learnable YUV space in the embodiment 3 of the present application; Figure 3 is the comparison diagram of the original RGB image and the enhanced image in the embodiment 1 of the present application; wherein (a) is the original low-light image of the LOLv2-Real dataset, and (b) is the enhanced image of the LOLv2-Real; Figure 4 is the comparison diagram of the original image and the enhanced image of the ancient book in the embodiment 1 of the present application; wherein (a) is the original image of the ancient book in the LJKDataset dataset, and (b) is the enhanced image of the LJKDataset. DETAILED DESCRIPTION
[0020] The specific embodiments of the present application will be further described in detail below in combination with the drawings and embodiments. The following embodiments are used to illustrate the present application, but not to limit the scope of the present application.
[0021] In order to better understand the purpose, structure and function of the present application, the present application will be further described in detail below in combination with the drawings.
[0022] Embodiment 1 As Figure 1As shown, this invention provides a low-light image enhancement method based on a learnable YUV space, comprising: S1. Acquire the original RGB image captured in a low-light environment and preprocess it to obtain the preprocessed RGB image; Specifically, this embodiment involves acquiring the original RGB image captured in a low-light environment. This image typically suffers from low overall brightness, significant noise, or color distortion. It will serve as input for all subsequent processing steps. In practical applications, this image can originate from imaging devices such as digital cameras, scanners, or surveillance cameras. To facilitate subsequent processing, it can be pre-processed... Normalization is performed to adjust the pixel value range to the [0,1] interval.
[0023] S2. Map the preprocessed RGB image to the learnable YUV color space to decouple the luminance and chrominance components. This embodiment specifically involves converting the RGB color space to an optimal, task-relevant color space. Its core innovation lies in proposing a dynamic, learnable YUV color space conversion method (Learnable Color-space Projection, LCSP), which achieves efficient decoupling of brightness and chromaticity from the source, avoiding the limitations of traditional fixed conversion formulas.
[0024] (1) Input: Normalized RGB image .
[0025] (2) Learnable modeling of the luminance component (Y): The luminance component is generated using a learnable convex combination, and its calculation formula is as follows: (1) Among them, the weighting coefficient These are not fixed values, but trainable parameters generated by the Softmax function. This design forces the following conditions to be met. The convex combination constraint ensures that the luminance component Y is a physically meaningful grayscale image that conforms to human visual perception, effectively preventing abnormal contrast or distortion of details caused by unreasonable luminance definition during subsequent enhancement.
[0026] (3) Learnable modeling of chromaticity components (U, V): The chromaticity components are generated using an unconstrained linear mapping, and the calculation formula is as follows: (2) (3) Among them, among them, and denote the learnable linear mapping coefficients for constructing the chroma components U, V. The values of this parameter group are all real numbers and are automatically adjusted through gradient optimization during the network training process to adaptively fit the color mapping rules under different imaging conditions, thereby more accurately separating out features related to color information, laying the foundation for subsequent precise denoising and color correction.
[0027] (4) Output: decoupled luminance component and chrominance component , .
[0028] S3, utilize the luminance component, and introduce an illumination-aware positional encoding mechanism for enhancement and structure modeling to obtain an enhanced luminance feature; The embodiment is specifically: the luminance component is enhanced, and the core innovation lies in introducing an illumination-aware positional encoding (IAPE) mechanism. This mechanism solves the problem that traditional static positional encoding is easily disturbed by noise in low-light images due to the inability to adapt to uneven illumination, leading to structure misjudgment and artifacts. By using luminance information as a guide to dynamically modulate spatial position prior, illumination distribution and spatial features are co-modeled, thereby significantly enhancing and protecting dark structures.
[0029] (1) Input: luminance component output by step S2
[0030] (2) Construct an illumination-aware positional encoding (IAPE): first, construct a learnable two-dimensional positional encoding base template for the feature map , which adaptively learns the spatial structure pattern of the image during forward propagation. Subsequently, using the original luminance component Y as a guide signal, a light-sensitive weight map is generated through a lightweight illumination gating network. The network consists of two convolutional layers and a nonlinear ReLU activation function, and is specifically represented as: (4) Conv in equation (4) represents a convolutional layer with learnable convolution kernel weights and bias terms, which is used to extract illumination-related spatial features from the luminance component Y. The convolution operation uses a 3x3 convolution kernel and calculates with a step size of 1, effectively capturing local illumination changes while maintaining the resolution of the feature map; The weight map can dynamically evaluate the reliability of the position prior according to the brightness level of each region of the image, giving high weights to the structure in bright areas and suppressing unreliable position signals caused by noise in dark areas.
[0031] (3) Modulation and injection of position prior: the obtained illumination weight map is element-wise multiplied with the learnable position encoding base template to generate the final illumination-aware position encoding : (5) (4) The modulated position encoding is injected into the original luminance feature map Y in the form of residual to obtain the final enhanced luminance component : (6) After the IGPE mechanism is enhanced, the luminance feature, the model has significantly improved the ability to perceive and restore structural information such as edges and contours in extremely dark areas, effectively suppressing the generation of artifacts and false textures. This mechanism is particularly suitable for separating fine text strokes and complex paper backgrounds in ancient books, providing a more stable and accurate structural basis for subsequent denoising, color correction and other processing modules.
[0032] This embodiment also provides another alternative: the learnable YUV conversion (LCSP) can be replaced by a fixed coefficient YUV / YCbCr / Lab linear transformation, or directly modeled in the RGB / Lab space in an end-to-end manner. Such a solution is simple to implement and has low training threshold, but due to the lack of task-adaptive luminance-chroma decoupling capability, it is more prone to "highlight-related color deviation" or detail modification problems in extremely dark areas.
[0033] The luminance enhancement and structure modeling (IGPE) can be replaced by Retinex decomposition (including adaptive illumination constraint), guided / bilateral / weighted least squares filtering for structure preserving enhancement, or using CNN / Transformer attention mechanism without position encoding. It is effective in conventional scenes, but when fine strokes and paper texture coexist in ancient books, it lacks the ability to distinguish between structure and noise, which can cause outline distortion or stroke adhesion.
[0034] S4, multi-branch parallel denoising and pixel-level dynamic fusion are performed on the chrominance component to obtain a purified chrominance component; The embodiment is specifically: this step is aimed at the complex noise existing in the chroma components U and V. In low light environment, the noise of the chroma channel is usually more significant than that of the luminance channel, and has the characteristics of uneven spatial distribution and large cross-channel intensity difference (for example, the blue channel noise is usually the strongest), which is easy to appear color spots, color noise and texture details mixed with artifacts. The traditional uniform intensity filtering strategy is difficult to balance noise suppression and detail preservation. Therefore, the application designs an adaptive noise fusion denoising module (Adaptive Noise Fusion Denoising Block, ANFDB), which realizes the differential processing of different noise types and regions through the strategy of "multi-scale noise modeling-branch collaborative denoising-pixel-level dynamic fusion".
[0035] (1) Input: chroma component output by step S2 and , for the sake of simplicity, the following general chroma channel is represented.
[0036] (2) Multi-scale noise feature extraction: first, the input chroma signal is used to extract multi-scale noise dominant features N using a convolutional encoder containing stepwise downsampling: (7) This multi-scale coding can effectively capture the complete noise spectrum from high-frequency random noise to low-frequency structural noise (such as color block residual image, paper background), providing global context for subsequent adaptive denoising.
[0037] (3) Pixel-level adaptive weight generation: based on the noise feature N, a weight generator composed of 1x1 convolution and upsampling operation is used to generate K (for example, K=4) weight maps with the same resolution as the input: (8) The Sigmoid function σ is used for activation here, and its independence allows the same pixel point to have response values on multiple weight maps. This means that the model can "simultaneously" choose a mixture of multiple denoising strategies for each pixel point, thereby efficiently processing mixed noise regions and overcoming the limitation of the Softmax function requiring mutually exclusive weights.
[0038] (4) Multi-branch parallel denoising: K parallel denoising sub-networks with the same structure but not sharing parameters are constructed. Each sub-network processes the original input The processing is performed, and a CBAM (Convolutional Block Attention Module) spatial attention mechanism is introduced, so that each branch can adaptively focus on the high-noise area in its feature map while retaining the edge structure. The processing process of the kth branch can be represented as: (9) (10) (11) denotes the feature output of the kth denoising branch, reflecting the independent estimation of the branch on chrominance noise and detail structure; is the branch attention weight map generated through the CBAM spatial attention mechanism, used to highlight high-noise or structure-sensitive areas; σ denotes the Sigmoid activation function, used to normalize the features to the interval to generate weights that can be used for pixel-level modulation These sub-branches have different receptive fields and noise suppression strengths, and can respectively process strong noise, weak noise, and texture areas differently, thereby significantly reducing the "over-smoothing" phenomenon in detail areas.
[0039] (5) Adaptive fusion and residual output: the denoising results of each branch are element-wise multiplied and summed with the corresponding weight map generated in step S4.3 to obtain the fused denoised features. Subsequently, the features are passed through a 3x3 convolution and a tanh activation function, and are added to the original chrominance input in a residual form to obtain the final purified chrominance component : (12) This fusion mechanism realizes targeted denoising by dynamically adapting the noise characteristics of different areas; the residual learning strategy is introduced in the output stage, effectively suppressing the distortion of image color and texture information, and thus building a good balance between noise suppression and detail preservation, significantly improving the visual fidelity of the denoising results.
[0040] The present embodiment also provides another alternative: chrominance subspace adaptive denoising (ANFDB) can be implemented on the chrominance channel through traditional algorithms such as BM3D, WNNM, NLM, etc., and can also use blind spot networks or frequency domain filtering and other lightweight models. Such methods perform well when dealing with a single noise type, but their regional adaptive ability and detail preservation performance are relatively limited when dealing with mixed noise such as color noise and paper texture superposition.
[0041] S5, fuse the enhanced luminance component and the purified chrominance component, and perform color correction in combination with a global color histogram prior, a luminance-guided color attention, and a learnable color bias corrector; S6: convert the corrected YUV image into an enhanced RGB image.
[0042] The embodiment is specifically: this step is the key to ensure that the final output image color is natural and real. In low-light image enhancement, if only the luminance recovery is concerned and the color modeling is ignored, the enhanced result is prone to color distortion, color bias, and cross-scene inconsistency. Therefore, the application designs an adaptive color consistency module (ACCM), which realizes the joint optimization of luminance enhancement and color consistency by introducing a triple synergy mechanism of global gamut prior, structure-guided color modulation, and dynamic color bias compensation.
[0043] (1) input: enhanced luminance component and purified chrominance component .
[0044] (2) global color histogram modeling: to constrain the color distribution of the image as a whole and prevent the overall gamut from drifting during the enhancement process, the ACCM module first extracts the global color histogram prior of the input image : (13) wherein, represents the probability distribution of color channel c; in formula (13), Softmax is a normalization function for converting the input feature into a probability distribution on each color channel; represents a multi-layer perceptron network for non-linear mapping of the pooled global color statistical features; Pool represents a global pooling operation for extracting overall statistics of the input image on each color channel; represents an operation of convolutional feature extraction on the input YUV image, which is used to obtain local color and luminance structure information to assist the construction of the histogram prior; wherein, represents the probability distribution of color channel c. This global prior, as a "color anchor point", is embedded in the feature map during the subsequent reconstruction process, which can effectively suppress the overall hue distortion caused by local over-enhancement and ensure that the output image maintains a natural and coordinated gamut range.
[0045] (3) luminance-guided color attention mechanism: to solve the spatial misalignment problem of luminance and color information (i.e. "correct luminance but misaligned color" artifacts), this module introduces a luminance-guided color attention mechanism. This mechanism extracts color features with luminance features interactively modeling, generating a color attention weight map (14) In formula (14), represent the feature mapping functions for extracting respectively; Sigmoid(·) is used to normalize the fused luminance-color features to interval to generate pixel-level color attention weights ; The weight map is used to spatially re-weight the color features: (15) This operation ensures that the restored color information is accurately aligned with the enhanced luminance structure (such as object edges, text outlines) in space, effectively eliminating color leakage and edge artifacts.
[0046] (5) Learnable color cast corrector: To further correct systematic color casts caused by device white balance, light source color temperature, etc., the ACCM module designs a learnable color cast corrector at the output end. The corrector performs a global linear transformation on the image through a trainable 3x3 color correction matrix and a bias vector (16) where matrix M is used to model the coupling and correction between color channels, and vector b is used to compensate for residual color casts, achieving adaptive correction of systematic color casts during the enhancement process or in low-light environments, achieving final white balance correction and color normalization.
[0047] (6) Output: After the above three mechanisms are cooperatively processed, the enhanced YUV image with natural and consistent color .
[0048] In summary, the ACCM module solves the problems of color gamut drift, color misplacement, and systematic color cast in low-light enhancement through multi-level cooperation of global constraints, local modulation, and system correction, ensuring that the enhancement result has high-fidelity color performance and excellent cross-scene consistency while improving brightness.
[0049] Step S6: Enhanced image reconstruction The YUV image corrected by the ACCM module is mapped back to the standard RGB color space through inverse conversion, and the final enhanced image is output : (17) The processed image is significantly improved in key visual indicators such as brightness, texture clarity, noise suppression effect, and color fidelity.
[0050] The embodiment also provides another alternative: color consistency and color cast correction (ACCM) can be implemented by gray world / gray edge, color card-based calibration, histogram matching, or fixed 3x3 color correction matrix. Such methods are simple to deploy, but are prone to color gamut drift and local "dyeing" when crossing devices, light sources, and images.
[0051] In summary, the core of the embodiment is to construct an enhanced framework that "decouples, divides, and collaborates" brightness and chrominance in a learnable color space. The key innovations and corresponding points to be protected are as follows: (1) Learnable brightness-chrominance decoupling mapping mechanism A dynamic, parameter-learnable YUV color space conversion method (Learnable Color-space Projection, LCSP) is proposed to replace the traditional fixed coefficient conversion formula. The core is to model the brightness component Y with a convex combination with a Softmax constraint to ensure its physical meaning, and to model the chrominance components (U, V) with an unconstrained linear mapping to maximize their color adaptability. The learnable color space mapping method itself, including its network structure, convex combination, and unconstrained mapping implementation, and the technical solution for color separation through the mapping.
[0052] (2) Illumination-aware position encoding (IAPE) that fuses image content In the brightness enhancement path, a dynamically generated position encoding (IAPE) is creatively introduced. The encoding is generated by the input image's own brightness component through a gating network, serving as a dynamic spatial prior strongly related to the illumination distribution, to guide the enhancement network to preferentially focus on and enhance the structural details of dark areas. The generation method of the illumination-aware position encoding (including the structure of the gating network), and the technical solution of injecting the dynamic encoding into the feature map in the form of residual, etc., to realize structure-guided enhancement.
[0053] (3) Adaptive noise fusion and denoising module (ANFDB) in the chrominance subspace Aiming at the complex characteristics of chrominance noise, a noise suppression module containing "multi-scale noise feature extraction, multi-branch parallel noise reduction, pixel-level adaptive fusion" is designed. The core innovation is to use the Sigmoid function to generate non-exclusive pixel-level weights, realize the dynamic and flexible fusion of the results of multiple noise reduction branches, and thus differentially process different types and intensities of noise. The overall architecture and method of ANFDB; the mechanism of generating pixel-level adaptive weights using multi-scale features; and the non-exclusive weight fusion strategy based on Sigmoid.
[0054] (4) Multi-level collaborative color consistency correction (ACCM) A comprehensive color correction framework is proposed, which through the collaboration of the three sub-modules of global color histogram prior, brightness-guided color attention mechanism and learnable color cast corrector, respectively from the three levels of global color gamut constraint, local color-structure alignment and systematic color cast compensation, ensures the accuracy and naturalness of the enhanced color. The overall method of color consistency correction; the specific technical implementation of its three core sub-modules (global color histogram modeling, brightness-guided color attention, and learnable color cast corrector), and the workflow of the collaboration between each step.
[0055] (5) Complete method flow and system of "decoupling, divide and conquer, and collaboration" The uppermost innovation of the present invention is to propose and implement a complete low-light image enhancement flow, the core step sequence of which is: decoupling through LCSP, dividing and conquering the brightness and chrominance through IGPE and ANS respectively, and finally realizing collaboration through ACCM. This flow constitutes the basis of the methodology of the present invention.
[0056] The method in the present invention realizes brightness / chrominance separation through learnable YUV conversion (LCSP), introduces illumination-aware structure guidance (IGPE) in the brightness path, avoids "brightening leads to color cast / detail loss" from the source, and ensures that dark brightening and stroke / outline authenticity are established simultaneously; for the problem of noise and underprint confusion, multi-scale modeling and multi-branch non-exclusive weight fusion (ANFDB) are used in the chrominance subspace to realize differential noise reduction and significantly reduce the elimination of weak strokes and paper texture interference; for global color gamut drift and systematic color cast, the color consistency and color cast correction module (ACCM) introduces global color gamut prior, brightness-guided color attention, and learnable correction matrix to obtain stable, natural and consistent color tone across scenes; for the engineering bottlenecks of deployment difficulty and dependence on paired data of generative methods, the present invention follows the lightweight flow of "decoupling, divide and conquer, and collaboration", and can also be stably, quickly and batch-operated in low-to-medium computing power environments, adapting to the actual needs of ancient book digitization, OCR and subsequent visual analysis.
[0057] Example 2 The application further provides a verification process of the method in embodiment 1 of the application, specifically: To verify the effectiveness and superiority of the method of the application in low-light image enhancement, comparative experiments were conducted based on public data sets (LOLv1, LOLv2) and low-light data sets of ancient books (LJKDataset). The experimental results show that the application is significantly better than existing methods in brightness recovery, noise suppression and color consistency, proving its practical engineering application value.
[0058] On the LOLv2-Real data set, the method of the application was compared with typical low-light enhancement models in terms of objective indicators, and the results were as follows: Table 1 Comparison of objective indicators of the application and prior art on LOLv2-Real data set
[0059] On the self-built ancient book data set (LJKDataset), the application also achieved the highest performance: Table 2 Comparison of objective indicators of the application and prior art on LJKDataset data set
[0060] The above results show that the application has strong generalization performance in different types of low-light images, especially significantly improving the character edge definition and paper texture fidelity in ancient book images.
[0061] To further verify the visual enhancement effect of the application, typical test images and the enhancement results of the application were compared from the subjective visual quality angle.
[0062] (1) LOLv2-Real data set test examples As shown in (a) of FIG. 8, Figure 3 is a typical low-light image collected in the LOLv2-Real data set, the overall brightness of the image is low, and there is obvious noise and color distortion in the detail area; as shown in (b) of FIG. 8, Figure 3 is the enhancement result after processing by the method of the application. As can be seen, the method of the application effectively suppresses the dark noise while maintaining the natural brightness, restores clear structure edges and true colors, and the overall visual effect is brighter and more balanced.
[0063] (2) LJKDataset ancient book test examples As shown in (a) of FIG. 9, Figure 4 is the original image sampled in the self-built low-light data set of ancient books, and it can be observed that the paper texture interference is obvious and the brightness of the ink area is insufficient; as shown in (b) of FIG. 9, Figure 4The result shown in (b) is enhanced by the method of the application. In the enhanced image, the paper background color is natural, the ink blackness is fully restored, the character edge is clear, there is no artifact and over-smoothing phenomenon, the text readability is significantly improved, and the enhancement effect is more in line with the visual characteristics of the real document.
[0064] Example 3 The application also provides a system for executing the low-light image enhancement method based on a learnable YUV space in Example 1, comprising: An image acquisition module is configured to acquire an original RGB image collected in a low-light environment and perform preprocessing to obtain a preprocessed RGB image; a learnable YUV color space projection module is configured to map the preprocessed RGB image to a learnable YUV color space to decouple a luminance component and a chrominance component; an illumination-aware luminance enhancement and structure modeling module is configured to utilize the luminance component and introduce an illumination-aware positional encoding mechanism to perform enhancement and structure modeling to obtain an enhanced luminance feature; and an adaptive noise fusion denoising module is configured to perform multi-branch parallel denoising and pixel-level dynamic fusion on the chrominance component to obtain a purified chrominance component. An adaptive chromatic consistency module is configured to fuse the enhanced luminance component and the purified chrominance component, and perform color correction in combination with a global color histogram prior, luminance-guided color attention, and a learnable color cast corrector. An image reconstruction module is configured to convert the corrected YUV image into an enhanced RGB image.
[0065] This embodiment is specifically as follows: Figure 2 The overall architecture diagram of the low-light image enhancement model is provided. As shown in Figure 2 The model core is sequentially connected by a learnable YUV color space projection module (LCSP), an illumination-aware luminance enhancement and structure modeling module (IAPE), an adaptive noise fusion denoising module (ANFDB), and an adaptive chromatic consistency module (ACCM). After the input low-light RGB image is decoupled into a luminance component and a chrominance component by the LCSP module, the luminance component enters the IGPE module for enhancement and structure protection, the chrominance component enters the ANFDB module for noise suppression, and finally the ACCM module is used for color fusion and correction, and the final enhanced RGB image is reconstructed.
[0066] The application further provides an electronic device, comprising: a memory storing a computer program; a processor for executing the computer program to implement the low-light image enhancement method based on a learnable YUV space.
[0067] The above description of the disclosed embodiments enables a person skilled in the art to implement or use the application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the application. Therefore, the application will not be limited to the embodiments shown herein but will be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A low-light image enhancement method based on a learnable YUV space, characterized in that, include: S1. Acquire the original RGB image captured under low light conditions and preprocess it to obtain the preprocessed RGB image; S2. Map the preprocessed RGB image to the learnable YUV color space to decouple the luminance and chrominance components. S3. Using the brightness component, an illumination-aware position coding mechanism is employed for enhancement and structural modeling to obtain the enhanced brightness features; S4. Perform multi-branch parallel denoising and pixel-level dynamic fusion on the chrominance components to obtain the purified chrominance components. S5. The enhanced luminance component and the purified chrominance component are fused together, and color correction is performed by combining global color histogram prior, luminance-guided color attention and learnable color shift corrector. S6. Convert the corrected YUV image to an enhanced RGB image.
2. The low-light image enhancement method based on learnable YUV space according to claim 1, characterized in that, The preprocessing process described in S1 is as follows: Normalize the raw RGB images acquired under low light conditions; The expression for the preprocessed RGB image is as follows: 。 3. The low-light image enhancement method based on learnable YUV space according to claim 1, characterized in that, Step S2 maps the preprocessed RGB image to a learnable YUV color space, decoupling the luminance and chrominance components, specifically as follows: Luminance components are generated using convex combination. The calculation formula is: (1) Among them, satisfying Constraints, These are weighting coefficients; The chromaticity components are generated using an unconstrained linear mapping, and the calculation formula is as follows: (2) (3) in, and This represents the learnable linear mapping coefficients used to construct the chromaticity components U and V.
4. The low-light image enhancement method based on learnable YUV space according to claim 1, characterized in that, S3 employs a light-sensing position encoding mechanism for enhancement and structural modeling to obtain enhanced brightness features, specifically: Build a learnable two-dimensional position coding basic template The base template adaptively learns the spatial structure pattern of the image during forward propagation; Using the original luminance component Y as the guiding signal, an illumination weight map is generated through a lightweight illumination gating network. Specifically, it is expressed as: (4) In formula (4), Conv represents a convolutional layer with learnable kernel weights and bias terms, used to extract illumination-related spatial features from the brightness component Y. The obtained illumination weight map With Learnable Position Encoding Basic Template Element-wise multiplication is performed to generate the final position code for illumination sensing. : (5); Enhanced brightness features The expression is: (6) in, To generate the final positional encoding for illumination sensing, This represents the luminance component.
5. The low-light image enhancement method based on learnable YUV space according to claim 1, characterized in that, S4 involves performing multi-branch parallel denoising and pixel-level dynamic fusion on the chrominance components to obtain the purified chrominance components, specifically as follows: For chromaticity signal A convolutional encoder incorporating progressive downsampling is used to extract multi-scale noise-dominant features N: (7) Based on the noise-dominant feature N, a weight generator consisting of 1x1 convolutions and upsampling operations is used to generate K weight maps with the same resolution as the input. : (8) Construct K parallel denoising subnetworks with identical structures but no parameter sharing; each subnetwork processes the chrominance signal. The process is performed, and the CBAM spatial attention mechanism is introduced, enabling each branch to adaptively focus on the noisy regions in its feature map while preserving the edge structure. The processing procedure for the k-th branch is represented as follows: (9) (10) (11) This represents the feature output of the k-th denoising branch, reflecting the branch's independent estimation of chroma noise and detail structure; This is a branch attention weight map generated by the CBAM spatial attention mechanism, used to highlight high-noise or structurally sensitive regions; σ represents the Sigmoid activation function, used to normalize the feature map to... The interval is used to generate weights that can be used for pixel-level modulation; The denoising results of each branch The elements are multiplied element-wise with the corresponding weight map and summed to obtain the fused denoised features; The denoised features are then passed through a 3×3 convolution and a tanh activation function, and added to the original chroma input as residuals to obtain the final purified chroma components. : (12)。 6. The low-light image enhancement method based on learnable YUV space according to claim 1, characterized in that, The S5 step involves fusing the enhanced luminance component and the purified chrominance component, and then performing color correction by combining global color histogram priors, luminance-guided color attention, and a learnable color shift corrector. Specifically: First, extract the global color histogram prior from the input image. : (13) in, Let represent the probability distribution of color channel c; in formula (13), Softmax is a normalization function used to convert the input features into probability distributions in each color channel; represents a multilayer perceptron network used for nonlinear mapping of pooled global color statistical features; Pool represents the global pooling operation used to extract the overall statistics of the input image across each color channel. This indicates the operation of convolutional feature extraction on the input YUV image, used to obtain local color and brightness structure information to assist in the construction of histogram prior; Introducing a brightness-guided color attention mechanism, the color attention mechanism focuses on color features. With brightness characteristics Perform interactive modeling to generate a color attention weight map. : (14) In formula (14), , Indicates that they are used for extraction respectively , The feature mapping function; Sigmoid(·) is used to normalize the fused brightness-color features to Intervals are used to generate pixel-level color attention weights. ; Using this color attention weight map Spatial reweighting of color features: (15) An intermediate image is required before final color correction. ;in, This represents the three-channel fused image after brightness enhancement and chroma denoising. This image has not yet undergone color correction and will be used as input for color correction. Subsequently, it is processed through a trainable 3x3 color correction matrix. and a bias vector Perform a global linear transformation on the image: (16) Among them, matrix M is used to model the coupling and correction between color channels, and vector b is used to compensate for residual color cast; The enhanced YUV image, processed through the aforementioned three mechanisms, exhibits natural colors and good consistency. .
7. The low-light image enhancement method based on learnable YUV space according to claim 1, characterized in that, S6 involves inversely converting the corrected YUV image into an enhanced RGB image, specifically as follows: YUV image after full correction by ACCM module By inversely converting and mapping back to the standard RGB color space, the final output is an enhanced image. : (17) The processed image shows significant improvements in key visual indicators such as brightness, detail and texture clarity, noise suppression, and color fidelity.
8. A low-light image enhancement system based on a learnable YUV space, for performing the low-light image enhancement method based on a learnable YUV space as described in any one of claims 1-7, comprising: The image acquisition module is used to acquire the original RGB image captured in a low-light environment and perform preprocessing to obtain the preprocessed RGB image; The learnable YUV color space projection module is used to map the preprocessed RGB image to the learnable YUV color space, decoupling the luminance component and chrominance component. The illumination-sensing brightness enhancement and structural modeling module is used to enhance and model the structure using the brightness components and an illumination-sensing position encoding mechanism to obtain the enhanced brightness features. An adaptive noise fusion and denoising module is used to perform multi-branch parallel denoising and pixel-level dynamic fusion on the chrominance components to obtain purified chrominance components. The adaptive color consistency module is used to fuse the enhanced luminance component and the purified chrominance component, and to perform color correction by combining global color histogram prior, luminance-guided color attention and a learnable color shift corrector. The image reconstruction module is used to inversely convert the corrected YUV image into an enhanced RGB image.
9. An electronic device, characterized in that, include: Memory, which stores computer programs; The processor, when executing the computer program, implements the low-light image enhancement method based on the learnable YUV space as described in any one of claims 1-7.
Citation Information
Cited By
Image enhancement method, computer equipment and readable storage medium
CN122023221A