An image color fidelity optimization method and system based on color perception feature mapping

By converting images to a uniform perception color space and extracting color perception features, and then adjusting them using a color feature mapping network, the problem of neglecting spatial correlation and texture adaptability in color optimization in existing technologies is solved, achieving a balance between color fidelity and visual effect in color optimization.

CN121883619BActive Publication Date: 2026-06-09GUANGDONG SANENSHI TECH CO LTD +1
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
GUANGDONG SANENSHI TECH CO LTD
Filing Date
2026-03-20
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

Existing color optimization methods ignore the spatial correlation between pixels and their surrounding neighborhoods, making it difficult to accurately simulate the color perception characteristics of the human eye. Furthermore, they are prone to introducing artifacts or destroying texture when processing complex texture images.

Method used

The image is converted from the RGB color space to the uniform perception color space, the luminance channel and the chromaticity channel are separated, the chromaticity value of the pixel and the local color space features are extracted, a color perception feature map is constructed, adjustment coefficients are generated through a color feature mapping network, filtering is performed, and a color fidelity loss function is introduced for verification.

Benefits of technology

It achieves color optimization without affecting image details and texture, preserves the clarity and sense of depth of the original image, ensures that the optimization results conform to the color perception characteristics of the human eye, and avoids local distortion through nonlinear mapping and fidelity constraints.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121883619B_ABST
    Figure CN121883619B_ABST
Patent Text Reader

Abstract

The present application relates to the field of image processing, and more particularly to an image color fidelity optimization method and system based on color perception feature mapping, which realizes decoupling processing of brightness information and color information by converting the image from RGB space to uniform perceptual color space and separating brightness and color channels. Color adjustment can be performed without affecting image detail texture, preserving the clarity and level of the original image. By extracting color perception features containing pixel chroma values and local spatial features, the limitations of traditional methods focusing only on single-point color values are addressed. The feature extraction method combines pixel properties with their spatial context, allowing the color optimization process to fully consider the color perception characteristics of the human eye. Nonlinear mapping is performed through a feature mapping network to generate adjustment coefficients, enabling intelligent and differentiated guidance of color adjustment and preventing local distortion caused by global uniform transformation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of image processing technology, and in particular to an image color fidelity optimization method and system based on color perception feature mapping. Background Technology

[0002] In the field of image processing, color fidelity optimization has always been one of the key technologies for improving the visual quality of images. By correcting and enhancing the colors of an image, its visual effect can be improved, making it more in line with the perceptual characteristics of the human eye or meeting specific application requirements. Currently, commonly used color optimization methods include techniques such as linear transformation based on color space, histogram-based contrast adjustment, and lookup table-based color mapping.

[0003] However, existing color optimization methods still have certain shortcomings in practical applications. On the one hand, traditional methods typically process individual pixels independently or adjust the entire image using globally uniform transformation parameters. This approach ignores the spatial correlation between pixels and their surrounding neighborhoods. Because the color distribution of natural images exhibits complex local correlations, pixels with the same color value may be perceived differently by the human eye in different spatial environments. Relying solely on single-point color information makes it difficult to accurately model this perceptual characteristic, leading to color distortion or unnatural transitions in certain areas of the optimized image. On the other hand, existing methods need improvement in adaptability to texture structures when processing images containing complex textures. Textured regions in images often have specific color distribution patterns, reflecting the visual characteristics of the texture itself, rather than color deviations that need correction. However, existing techniques struggle to effectively distinguish between color fluctuations caused by texture structures and differences caused by actual color variations when extracting image features. They easily misjudge texture details as color problems and process them accordingly, thus introducing unnecessary artifacts or destroying the realistic texture during the optimization process. Summary of the Invention

[0004] To address one or more problems in the prior art, the main objective of this application is to provide a method and system for optimizing image color fidelity based on color perception feature mapping.

[0005] To achieve the aforementioned objectives, this application proposes an image color fidelity optimization method based on color perception feature mapping, the method comprising:

[0006] The image to be processed is acquired in real time, and the image to be processed is converted from the RGB color space to the uniform perception color space. The brightness channel and the color channel are separated in the uniform perception color space.

[0007] Color perception features are extracted from the color channels. The color perception features include the chromaticity values ​​of pixels and local color space features. A color perception feature map is constructed based on the chromaticity values ​​of pixels and local color space features.

[0008] The color perception feature map is input into a preset color feature mapping network. The color feature mapping network performs a non-linear mapping between the color perception feature map and the reference color perception feature to generate an adjustment coefficient for each color channel.

[0009] Based on the adjustment coefficient, the original color channel is filtered to obtain the adjusted color channel;

[0010] The adjusted color channels are recombined with the original luminance channels, and the recombined color channels are converted to the RGB color space to obtain a preliminary optimized image;

[0011] The color fidelity loss function is called to verify the preliminary optimized image. When the color fidelity meets the preset fidelity threshold, the final optimized image is output.

[0012] This application also provides an image color fidelity optimization system based on color perception feature mapping, including:

[0013] The acquisition module is used to acquire the image to be processed in real time, convert the image to be processed from the RGB color space to the uniform perception color space, and separate the luminance channel and the color channel in the uniform perception color space.

[0014] An extraction module is used to extract color perception features from the color channels. The color perception features include the chromaticity values ​​of pixels and local color space features. A color perception feature map is constructed based on the chromaticity values ​​of pixels and local color space features.

[0015] The input module is used to input the color perception feature map into a preset color feature mapping network, and to perform a nonlinear mapping between the color perception feature map and the reference color perception feature through the color feature mapping network to generate the adjustment coefficient for each color channel.

[0016] The filtering module is used to filter the original color channel based on the adjustment coefficient to obtain the adjusted color channel;

[0017] The reconstruction and conversion module is used to reconstruct the adjusted color channels with the original luminance channels, and convert the reconstructed color channels to the RGB color space to obtain a preliminary optimized image;

[0018] The output module is used to call the color fidelity loss function to verify the preliminary optimized image. When the color fidelity meets the preset fidelity threshold, the final optimized image is output.

[0019] This application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of any of the methods described above.

[0020] This application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of any of the methods described above.

[0021] The image color fidelity optimization method and system based on color perception feature mapping in this application decouples brightness and color information by converting the image from RGB space to a uniform perception color space and separating brightness and color channels. This allows subsequent color adjustments to be performed without affecting image details and texture, preserving the clarity and depth of the original image. Secondly, this method extracts color perception features containing pixel chromaticity values ​​and local spatial features, overcoming the limitation of traditional methods that only focus on single-point color values. The feature extraction method, which combines pixel attributes with their spatial context, ensures that the color optimization process fully considers the human eye's color perception characteristics. Thirdly, by using a feature mapping network to generate adjustment coefficients through nonlinear mapping, intelligent and differentiated guidance for color adjustment is achieved. Different regions receive targeted processing based on their characteristics, preventing local distortion caused by globally uniform transformations. Finally, a color fidelity loss function is introduced for verification, setting fidelity constraints while pursuing color optimization to ensure that the color difference between the optimized result and the original image is controlled within an acceptable range for the human eye. Attached Figure Description

[0022] Figure 1 This is a flowchart illustrating an embodiment of an image color fidelity optimization method based on color perception feature mapping according to this application.

[0023] Figure 2 This is a flowchart illustrating another embodiment of the image color fidelity optimization method based on color perception feature mapping in this application.

[0024] Figure 3 This is a schematic block diagram of an image color fidelity optimization system based on color perception feature mapping according to an embodiment of this application;

[0025] Figure 4 This is a schematic block diagram of the structure of a computer device according to an embodiment of this application;

[0026] Figure 5 This is a comparative schematic diagram of an embodiment of the image color fidelity optimization method based on color perception feature mapping according to this application;

[0027] Figure 6 This is a comparative schematic diagram of another embodiment of the image color fidelity optimization method based on color perception feature mapping in this application.

[0028] The realization of the purpose, functional features and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0029] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0030] Reference Figure 1 This application provides an image color fidelity optimization method based on color perception feature mapping, the method comprising:

[0031] S1. Acquire the image to be processed in real time, convert the image to be processed from the RGB color space to the uniform perception color space, and separate the luminance channel and the color channel in the uniform perception color space.

[0032] S2. Extract color perception features from the color channel. The color perception features include the chromaticity value of the pixel and the local color space features. Construct a color perception feature map based on the chromaticity value of the pixel and the local color space features.

[0033] S3. Input the color perception feature map into a preset color feature mapping network, and perform nonlinear mapping between the color perception feature map and the reference color perception feature through the color feature mapping network to generate the adjustment coefficient for each color channel.

[0034] S4. Based on the adjustment coefficient, the original color channel is filtered to obtain the adjusted color channel;

[0035] S5. Recombine the adjusted color channels with the original luminance channels, and convert the recombined color channels to the RGB color space to obtain a preliminary optimized image;

[0036] S6. Call the color fidelity loss function to verify the preliminary optimized image. When the color fidelity meets the preset fidelity threshold, output the final optimized image.

[0037] As described in steps S1-S3 above, color perception, or Perceptual Color, is a commonly used concept in image processing, particularly in visual science. In the technical solution of this invention, color perception refers to a composite color feature that integrates the pixel's own chromaticity value and its spatial context information. By introducing local color space features, color perception features can simultaneously reflect the color attributes of a pixel and its color relationship with the surrounding environment, thereby more accurately simulating the human eye's color perception mechanism. Step 1: After acquiring the image to be processed in real time, the image first needs to be converted from the original RGB color space to a uniform perceptual color space, and the luminance channel and color channel are separated in this space. The reason for color space conversion is that although the RGB color space is widely used in image acquisition and display devices, the changes in color values ​​are not entirely consistent with human visual perception. In the RGB space, the same numerical difference may result in significant differences in the visual perception of the human eye in different color regions, which is not conducive to color optimization that conforms to the characteristics of human visual perception. Uniform perceptual color spaces, such as CIELAB or ICTCP spaces, are designed to make the changes in color values ​​as consistent as possible with the changes in human visual perception. In a uniform color space, luminance information is primarily concentrated in the luminance channel, while color information is concentrated in the color channel. Separating the luminance and color channels allows for independent processing of luminance and color. This is significant because the human eye has different sensitivities to luminance and color details, and in practical applications, it's often desirable to maintain luminance details while optimizing color. After separation, the luminance channel can remain unchanged, allowing processing only the color channel, thus enhancing color performance while maximizing the preservation of image texture details and depth. Step 2: After obtaining the color channels, it's necessary to extract color perception features. These features consist of two components: pixel chromaticity values ​​and local color space features. Pixel chromaticity values ​​are fundamental color attributes, reflecting the pixel's own color information, such as whether it leans towards red or blue, or whether its saturation is high or low. This is the basic data for color optimization. Local color space features reflect the color relationship between a pixel and its surrounding neighborhood. Specifically, for a given pixel, the color distribution of other pixels within a certain range needs to be considered. For example, is a pixel located at the center of a large, uniform color block, at the edge of a color-changing region, or in a region with rich texture? Different spatial relationships will cause the human eye to perceive the color of that pixel differently. Combining these two features constitutes the color perception feature. Based on the chromaticity value and local color space features of each pixel, a color perception feature map can be constructed. This feature map differs from ordinary images, reflecting the feature information of the pixel's own color attributes and its spatial context. The feature map will be used as input in subsequent steps to guide color optimization.Step 3 inputs the color-perceived feature map constructed in the previous step into a pre-trained color feature mapping network. This network is pre-trained and internally stores a baseline color-perceived feature library derived from a large number of high-fidelity images, representing an ideal color distribution pattern. In the feature mapping network, the input color-perceived feature map undergoes a non-linear mapping with the baseline color-perceived features. Non-linear mapping means that the network can learn a transformation rule based on the complex relationship between the input features and the baseline features, rather than simple linear addition or subtraction. Through this mapping, the network can determine the difference between the color features of the current image and the ideal baseline, and generate adjustment coefficients for each color channel accordingly. These adjustment coefficients are not globally uniform values, but correspond to the information in the color-perceived feature map. For example, for areas in the feature map showing low color saturation, the network may generate coefficients to increase saturation; for areas with color deviation, it generates coefficients to correct color cast. The adjustment coefficients can be understood as a guiding signal, telling subsequent steps which areas should be adjusted and to what extent.

[0038] As described in steps S4-S6 above, after obtaining the adjustment coefficients in step 4, the original color channels can be filtered. This filtering is not simple smoothing or sharpening, but adaptive filtering guided by the adjustment coefficients. Specifically, the filtering operation applies different degrees of influence to pixels at different positions in the color channel based on the magnitude and distribution of the adjustment coefficients. Areas with high adjustment coefficients indicate areas requiring significant color adjustment, resulting in a correspondingly stronger filter; areas with low adjustment coefficients indicate areas where the color is already relatively ideal, leading to a weaker filter to maintain the original state as much as possible. This method allows for fine-tuning of the color channels. The result of the filtering is an adjusted color channel, which, while retaining the basic structure of the original color, undergoes targeted optimization based on the color perception feature mapping. Step 5 requires recombining the adjusted color channel with the previously separated original luminance channel. Since the luminance channel remains constant throughout the processing, the recombined image retains all the luminance details and texture information of the original image, ensuring that image clarity is not affected. The recombined image is still located in a uniformly perceived color space and needs to be converted back to the RGB color space for display or storage. During the conversion process, the color gamut mapping issue also needs to be considered, as the color gamut range of a uniformly perceived color space is usually larger than that of the RGB color space. For colors outside the RGB color gamut, appropriate compression processing is required to bring them within the displayable range while maintaining visual continuity of the colors as much as possible. After this step, a preliminary optimized image is obtained. In step 6, the preliminary optimized image needs to be verified. The verification is based on a color fidelity loss function, which can quantify the degree of color difference between the optimized image and the original image. The loss function includes a function based on the CIEDE2000 color difference formula, which can well reflect the human eye's perception of color differences. The preliminary optimized image is input into the loss function, and the calculated loss value is compared with a preset fidelity threshold. If the loss value is less than or equal to the threshold, it means that the difference in color between the optimized image and the original image is within the range acceptable to the human eye, achieving both the optimization purpose and maintaining sufficient fidelity. If the loss value exceeds the threshold, it indicates over-optimization, which may have introduced unnatural color changes. In this case, the preliminary optimized image can be used as a new image to be processed, and the above steps can be repeated for iterative optimization until the fidelity requirement is met.

[0039] As mentioned above, by converting the image from RGB space to a uniformly perceived color space and separating the luminance and color channels, the luminance and color information are decoupled. This allows subsequent color adjustments to be performed without affecting image details and texture, preserving the clarity and depth of the original image. Secondly, this method overcomes the limitation of traditional methods that only focus on single-point color values ​​by extracting color perception features containing pixel chromaticity values ​​and local spatial features. The feature extraction method, which combines pixel attributes with their spatial context, allows the color optimization process to fully consider the human eye's perception of color, avoiding visual unnaturalness caused by isolated adjustments. Thirdly, by using a feature mapping network to generate adjustment coefficients through nonlinear mapping, intelligent and differentiated guidance for color adjustments is achieved. Different regions receive targeted processing based on their characteristics, preventing local distortion caused by globally uniform transformations. Finally, the method is validated by introducing a color fidelity loss function, setting fidelity constraints while pursuing color optimization, ensuring that the color difference between the optimized result and the original image is controlled within an acceptable range for the human eye.

[0040] Reference Figure 2 In one embodiment, the step of constructing a color perception feature map based on the chromaticity value and local color space features of the pixel includes:

[0041] S21. For each pixel in the color channel, extract neighborhood windows of different sizes centered on the pixel.

[0042] S22. Within each size of the neighborhood window, calculate the average chromaticity of all pixels within the neighborhood window, and use the average chromaticity as the local background chromaticity of this pixel at the current scale. Each scale corresponds to a neighborhood window of a certain size.

[0043] S23. Calculate the difference between the chromaticity value of the pixel and the local background chromaticity of the pixel at the current scale. Based on the calculation result, use the difference value as the local color contrast feature of the pixel at the current scale.

[0044] S24. Combine the chromaticity value of each pixel and the local color contrast features at each scale to generate an initial feature map corresponding to each scale.

[0045] S25. The initial feature maps at each scale are superimposed to form the color perception feature map.

[0046] As described above, step 1 involves extracting multiple neighborhood windows of different sizes centered on each pixel in the color channel. These different sizes refer to varying window dimensions; for example, a small 3×3 pixel window, a medium 5×5 pixel window, or a 7×7 pixel or larger window. Each window size corresponds to a scale. Multi-scale extraction is used because color features in an image exhibit different representations across different spatial ranges. Small-scale windows can capture subtle local color changes, such as texture details or color transitions near edges; large-scale windows can reflect color distribution over a larger area, such as the overall tonal tendency of an object or background color. Through multi-scale analysis, comprehensive color context information of pixels across different spatial ranges can be obtained. Step 2 involves calculating the average chromaticity of all pixels within each neighborhood window and using this average as the local background chromaticity of the current pixel at that scale. The local background chromaticity can be understood as the average color tendency of the surrounding environment within a certain range centered on the current pixel. For example, for a pixel located in a blue sky area, if most pixels within a large window centered on it are blue, the calculated local background chromaticity will be biased towards blue. Conversely, for a pixel located at the boundary between blue sky and white clouds, its window may contain both blue and white pixels, resulting in a calculated local background chromaticity that is a mixture of both. This local background chromaticity reflects the color environment of the pixel and serves as a benchmark for judging the relationship between the pixel's color and its environment. After obtaining the chromaticity value of the current pixel and its local background chromaticity at the current scale in step 3, the difference between the two needs to be calculated. This difference reflects the degree of contrast between the current pixel's color and its surrounding environment. If the difference between a pixel's chromaticity value and the local background chromaticity is small, it indicates that the pixel's color is similar to its surroundings and may be located within a uniform color region. If the difference is large, it indicates that the pixel's color is significantly different from its surroundings and may be located on a color boundary or isolated color block. Using this difference as the local color contrast feature of the current pixel at the current scale quantifies the color contrast relationship between the pixel and its environment within a specific spatial range. Step 4: Next, the chromaticity value of each pixel and the local color contrast features at each scale need to be combined to generate an initial feature map corresponding to each scale. Specifically, for each scale, an initial feature map corresponding to that scale is generated. Each pixel location in the map contains two pieces of information: the original chromaticity value of the pixel, and the local color contrast features calculated at that scale. The result is that for each scale, we have a feature image that simultaneously reflects the pixel's own color attributes and the color contrast relationship at that scale. The initial feature maps at different scales capture color relationships in different spatial ranges, providing multi-view information.Step 5 involves overlaying the initial feature maps at various scales to obtain the final color-perceived feature map. Overlaying is not simply adding pixels together; rather, it integrates feature information from different scales to form a comprehensive feature map containing multi-dimensional color features. In this color-perceived feature map, each pixel location corresponds to a feature vector. This vector contains the pixel's original chromaticity value and its color contrast relationship with the surrounding environment at different scales. This feature representation preserves the pixel's inherent color attributes while fully encoding the spatial context information of the pixel.

[0047] In one embodiment, the step of inputting the color perception feature map into a preset color feature mapping network, and non-linearly mapping the color perception feature map to a reference color perception feature through the color feature mapping network to generate adjustment coefficients for each color channel includes:

[0048] The color perception feature map is input into the color feature mapping network. The color perception feature map contains initial feature maps at multiple scales. Each initial feature map at a scale contains the chromaticity value of a pixel and the local color contrast features at that scale.

[0049] In the color feature mapping network, the initial feature map at each scale is convolved, and the scale feature map corresponding to each scale is extracted based on the processing result.

[0050] The scale feature maps corresponding to each scale are fused to obtain a fused feature map.

[0051] The fused feature map is compared with a preset benchmark color perception feature library, which includes multiple benchmark feature vectors and corresponding benchmark adjustment coefficients.

[0052] Calculate the similarity between the feature vector at each position in the fused feature map and each reference feature vector, and perform a weighted summation of the corresponding reference adjustment coefficients based on the similarity to obtain the adjustment coefficient for each position for each color channel;

[0053] Based on the adjustment coefficients at all locations, generate an adjustment coefficient map with the same dimensions as the original color channels.

[0054] As described above, step 1 inputs the previously constructed color-perceptual feature map into the color feature mapping network. At this point, the color-perceptual feature map is not a single image, but a collection of initial feature maps at multiple scales. Each scale of the initial feature map corresponds to a neighborhood window of a certain size. Each pixel location in the map contains two pieces of information: the original chromaticity value of the pixel, and the local color contrast features calculated at that scale. This multi-scale feature input design has a clear physical meaning. Small-scale initial feature maps capture the color contrast relationships near fine textures and edges, reflecting color changes at the local detail level; large-scale initial feature maps reflect the overall trend of color distribution over a larger area, embodying the color environment at the regional level. Inputting information from multiple scales simultaneously into the network allows subsequent processing to comprehensively utilize color features from different spatial ranges. Step 2 in the color feature mapping network requires convolution processing on each scale of the initial feature map. Convolution processing is a technique in deep learning; by sliding learnable convolution kernels across the feature map, it is possible to extract feature information with specific patterns. Since initial feature maps at different scales have different receptive fields and semantic levels, convolution processing can extract corresponding deep features tailored to the characteristics of each scale. For example, for small-scale feature maps, convolution operations are more likely to capture local structural information such as edges and corners; for large-scale feature maps, convolution operations are more likely to extract the overall color distribution pattern of the region. After convolution processing, the initial feature maps at each scale are transformed into corresponding scale feature maps. These scale feature maps, while retaining the original information, further refine the feature representations that are more valuable for color adjustment. After extracting the scale feature maps at each scale in step 3, these feature maps need to be fused to obtain a fused feature map. The fusion method can be channel-dimensional concatenation, weighted summation, or other combinations. The purpose of feature fusion is to integrate the information extracted at different scales to form a more comprehensive feature description of each pixel location. In the fused feature map, the feature vector at each pixel location integrates the detailed information at the small scale and the overall information at the large scale, knowing both the color contrast of the pixel in the local range and the color environment in a larger range. This overcomes the one-sidedness that may be caused by information from a single scale. After obtaining the fused feature map in step 4, it is compared with a pre-built baseline color perception feature library. The baseline color perception feature library is pre-constructed and contains a large number of baseline feature vectors extracted from high-fidelity images. Each baseline feature vector corresponds to a set of ideal baseline adjustment coefficients. These baseline feature vectors represent the color perception feature patterns presented when the image colors are at their optimal state in various typical scenarios. The essence of the comparison is to find the correspondence between the features of the current image and the ideal feature patterns.Each feature vector at each location in the fused feature map needs to be compared with the baseline feature vector in the library to determine which ideal mode the color feature at the current pixel location is closer to, thus determining how to adjust it. Step 5: For each location in the fused feature map, calculate the similarity between the feature vector at that location and each baseline feature vector in the baseline feature library. The similarity can be measured using cosine similarity, Euclidean distance, or other metrics, reflecting the degree of matching between the current feature and the baseline features. Based on the calculated similarity, the baseline adjustment coefficients corresponding to each baseline feature vector are weighted and summed. The higher the similarity of the baseline feature, the greater its contribution to the final adjustment coefficients; the lower the similarity of the baseline feature, the smaller its contribution. In this way, each pixel location will obtain a set of weighted fused adjustment coefficients. These coefficients are customized for the specific features of that pixel location, reflecting the adjustment strategy corresponding to the ideal color mode most similar to it. It should be noted that the adjustment coefficients are generated separately for each color channel. For a uniformly perceived color space containing two color channels, two sets of adjustment coefficients are generated; for a space containing three color channels, three sets of adjustment coefficients are generated. This ensures that different color channels can receive independent optimization processing. Step 6 generates an adjustment coefficient map with the exact same size as the original color channels, based on the adjustment coefficients calculated at all locations. In this adjustment coefficient map, each pixel location corresponds to a set of values, representing the adjustment intensity required for that pixel in each color channel. The generation of the adjustment coefficient map marks the complete transformation from feature extraction to adjustment instructions. The original image undergoes multi-scale feature extraction, followed by network mapping, ultimately transforming into an adjustment instruction map of the same size as the image itself, containing spatial distribution information. This map will be used to guide filtering processes, enabling refined and differentiated adjustments to the image's colors.

[0055] It is worth noting that a key reason why existing methods struggle to achieve precise color optimization is the lack of an effective feature-to-adjustment mapping mechanism. Traditional methods often employ fixed mathematical formulas or globally uniform transformation parameters, making it difficult to adaptively adjust processing strategies based on changes in image content. This invention, through a learnable network structure and a pre-defined benchmark feature library, achieves intelligent mapping that dynamically generates adjustment coefficients based on input features. First, through multi-scale convolution and feature fusion, the network can comprehensively utilize color information from different spatial ranges, generating adjustment coefficients that consider both local details and overall trends. Second, by comparing with the benchmark feature library and using similarity weighting, the generation of adjustment coefficients is based on comparison with a large number of ideal samples, making the adjustment direction more consistent with the objective laws of color optimization. Third, the final generated adjustment coefficient map has the same spatial resolution as the original image, achieving pixel-level differentiated adjustments, allowing color optimization to be refined to each pixel, rather than being limited to image patches or the entire image.

[0056] In one embodiment, the steps of recombining the adjusted color channels with the original luminance channels and converting the recombined color channels to the RGB color space to obtain a preliminary optimized image include:

[0057] The adjusted color channels and the original luminance channels are merged in the uniform perception color space to obtain a reconstructed uniform perception color space image.

[0058] Obtain the chromaticity value of each pixel in the adjusted color channel, and convert the chromaticity value into chromaticity coordinates corresponding to the RGB color space;

[0059] Based on the chromaticity coordinates, it is determined whether each pixel exceeds the color gamut range of the RGB color space. According to the determination result, for pixels that exceed the color gamut range, the chromaticity coordinates are compressed into the color gamut boundary.

[0060] Based on the compression results, the compressed chromaticity coordinates are combined with the luminance values ​​corresponding to the luminance channels to generate a preliminary optimized image in the RGB color space.

[0061] As described above, step 1 requires merging the adjusted color channels obtained through filtering with the original luminance channels that were previously separated and remained unchanged. The merging operation is performed in a uniformly perceived color space, combining the luminance channels with two or more color channels to form a complete uniformly perceived color space image. Although the luminance and color channels are separated during processing, they are originally components of the same image. The luminance channel carries the image's texture details and tonal gradations, while the color channels carry hue and saturation information. After the previous processing, the color channels have been optimized and adjusted according to the results of color perception feature mapping, while the luminance channel retains the original image's detail information. Merging the two again yields a complete image that retains the original details while improving color performance. Channel merging achieves a reunification of luminance and color information. Because the luminance channel has not been modified throughout, luminance-related visual elements such as texture details, edge sharpness, and contrast are fully preserved. This avoids the problem of detail blurring or sharpness reduction caused by color processing in common color enhancement methods. Step 2 obtains the chromaticity values ​​of each pixel in the adjusted color channels and converts these chromaticity values ​​into chromaticity coordinates corresponding to the RGB color space. This step is essentially a coordinate mapping from the uniform perception color space to the RGB color space. Coordinate transformation is necessary because different color spaces have different coordinate systems and representation ranges. Uniform perception color spaces, such as CIELAB, theoretically cover all colors visible to the human eye, with a wide range. The RGB color space, however, is the color space of a specific display device, and its coordinate range is limited by the device hardware, only covering a certain range of colors. Converting chromaticity values ​​to RGB chromaticity coordinates is necessary to determine whether these colors can be displayed correctly by the device in the RGB space. The coordinate transformation is based on a pre-determined color space transformation matrix or formula. Through mathematical transformation, the chromaticity value of each pixel in the uniform perception color space can be mapped to its corresponding position in the RGB space, resulting in a set of RGB chromaticity coordinates. These coordinates represent the theoretical position of the pixel's color in the RGB space. Step 3, after obtaining the RGB chromaticity coordinates of each pixel, needs to determine whether these coordinates exceed the color gamut range of the RGB color space. The RGB color space typically defines a cubic gamut, with each of its three coordinate components having a defined upper and lower limit. If all three components of a pixel's chromaticity coordinates are within the allowed range, the color can be displayed correctly on a display device. If any component exceeds the range, the color exceeds the device's display capabilities, and direct display will result in color truncation or distortion. Pixels outside the gamut need to be compressed, compressing their chromaticity coordinates towards the gamut boundaries.Compression is not simply about cropping out the excess color, as this leads to loss of color information and breaks in color transitions. A better approach is to employ a compression strategy that smoothly maps the excess color into the color gamut while preserving as much of the original color's hue and relative relationships as possible. For example, compression can be applied along the direction from the white point to the pixel, so that the compressed color retains its hue while appropriately reducing saturation and brightness until it falls within the color gamut. Alternatively, a non-linear compression function can be used, compressing colors farther from the color gamut boundary more significantly and colors closer to the boundary less, thus maintaining the continuity of color gradations. The effect of compression is to reproduce the original color perception as realistically as possible within the limited display color gamut. Although compression inevitably causes some loss of color information, a reasonable compression strategy can make this loss visually imperceptible, or at least maintain the relative relationships and visual continuity of colors. Step 4: Finally, based on the compression results, the compressed chromaticity coordinates are combined with the brightness values ​​corresponding to the original luminance channels to generate the final, preliminarily optimized image in the RGB color space. It's worth noting that while the luminance channel remains unchanged, the luminance value still needs to be included in the conversion calculation when transforming from a uniform perceived color space to RGB space. In fact, each pixel in an RGB image is composed of values ​​from three channels: red, green, and blue. These values ​​are calculated using both luminance and chromaticity coordinates. By performing an inverse color space transformation on the compressed chromaticity coordinates and the original luminance value, the red, green, and blue component values ​​of each pixel can be obtained, thus generating a complete RGB image. This step yields a preliminary optimized image that can be displayed correctly on standard display devices. This image retains the luminance details of the original image while undergoing targeted color optimization. Furthermore, all colors remain within the color gamut of the display device, preventing color clipping or distortion caused by exceeding the color gamut limit.

[0062] refer to Figure 5 In one embodiment, the step of constructing a color perception feature map based on the chromaticity value and local color space features of the pixel further includes:

[0063] After calculating the local color contrast features of each pixel at different scales, spatial frequency domain analysis is performed on the local color contrast features at each scale.

[0064] Based on the analysis results, determine whether there are periodic dense texture feature regions in the local color contrast features;

[0065] If there are feature regions with periodic dense textures, then the feature regions with periodic dense textures are divided into regions.

[0066] Based on the results of the region division, the periodic intensity of the characteristic region in spatial distribution is analyzed, and a periodic intensity distribution map of the characteristic region is generated according to the periodic intensity.

[0067] Determine the periodic intensity of the local color contrast features in spatial distribution at the current scale;

[0068] Based on the periodicity intensity, the local color contrast features within the feature region of the periodic dense texture are adjusted, wherein the higher the periodicity intensity, the greater the suppression of the local color contrast features.

[0069] The adjusted local color contrast features are combined with the chromaticity values ​​of the pixels to generate an initial feature map corresponding to each scale.

[0070] As mentioned above, after calculating the local color contrast features of each pixel at different scales in step 1, spatial frequency domain analysis needs to be performed on the local color contrast features at each scale. Spatial frequency domain analysis is a technique that transforms an image from the spatial domain to the frequency domain. Through this transformation, the distribution of image features at different frequencies can be observed. Spatial frequency domain analysis is performed because the local color contrast feature map itself can be considered an image, where the value of each pixel represents the color contrast intensity at that location. When there are periodic dense textures in the image, such as a striped shirt or woven fabric, these textures cause the local color contrast features to exhibit regular fluctuations in space. These regular fluctuations will manifest as energy peaks concentrated at specific frequencies in the frequency domain. Through spatial frequency domain analysis, the presence of such regular fluctuations can be detected, thereby determining whether the region belongs to a periodic dense texture. Step 2, based on the results of the spatial frequency domain analysis, needs to determine whether there are feature regions with periodic dense textures in the local color contrast features. The basis for this determination is whether obvious, concentrated frequency components are detected in the frequency domain. If frequency domain analysis shows significant periodic components, it indicates a regular fluctuation pattern in the local color contrast feature map at the current scale. This fluctuation is likely due to periodic texture structures in the image, rather than actual color deviation. Conversely, if frequency domain analysis shows a relatively dispersed energy distribution without obvious concentrated frequencies, it indicates that the local color contrast features in this area are mainly caused by random color changes or natural textures. For natural texture areas that need to be preserved, subsequent processing should maintain their original state as much as possible; while for artificial periodic texture areas that may cause misjudgments, further targeted processing is required. Step 3: If a feature area with periodic dense texture is identified, this area needs to be divided into regions. The purpose of region division is to group consecutive pixels with similar periodic features together to form one or more independent processing units. The basis for region division can be the spatial distribution of periodic features detected in the frequency domain analysis. For example, there may be multiple mutually separated periodic texture regions in the image, such as the striped shirt body and sleeves, which may both be striped but in different directions, and need to be divided into different regions for separate processing. It may also be a single large-area periodic texture region, such as a complete brick wall, which can be processed as a whole region. By dividing the region into areas, subsequent periodic intensity analysis and adjustments can be performed on a per-region basis, avoiding mutual interference between different regions due to differences in periodic characteristics. Step 4, based on the results of the region division, requires analyzing the periodic intensity of each characteristic region in spatial distribution and generating a periodic intensity distribution map for that characteristic region based on the analysis results. Periodic intensity reflects the significance of periodic fluctuations within that region. The analysis of periodic intensity can be further refined based on the frequency domain.For each region, the height and width of the main peak in its frequency domain, as well as its contrast with background noise, can be calculated. These information are then combined to obtain the overall periodic intensity of the region. Furthermore, time-frequency analysis methods such as short-time Fourier transform or wavelet analysis can be used to obtain the changes in periodic intensity at different locations within the region, thus generating a periodic intensity distribution map. In this distribution map, each pixel location corresponds to a periodic intensity value. The larger the value, the more significantly the local color contrast features at that pixel location are affected by periodic texture; the smaller the value, the weaker the influence of periodic texture. Step 5, based on the obtained periodic intensity distribution map, needs to determine the periodic intensity of the local color contrast features in spatial distribution at the current scale. This can be understood as aligning the periodic intensity information with the original local color contrast feature map, preparing for adjustment. Specifically, for each pixel location in the local color contrast feature map, the corresponding periodic intensity value can be obtained from the periodic intensity distribution map. In this way, each pixel's local color contrast feature value is accompanied by weight information, indicating the degree to which the feature value is affected by periodic texture. Step 6 adjusts the local color contrast features within the periodically dense texture feature region based on the periodic intensity value at each pixel location. The core principle of this adjustment is that the higher the periodic intensity, the greater the suppression of local color contrast features. Suppression is necessary because high values ​​of local color contrast features in periodically textured regions are often caused by texture structure rather than actual color deviations. Without suppression, these feature values ​​would be misinterpreted as significant color changes in the subsequent color feature mapping network, generating excessively high adjustment coefficients and leading to unexpected color enhancements or artifacts in the textured region. Suppression can be linear, such as multiplying the local color contrast feature value by a decay coefficient negatively correlated with the periodic intensity; or non-linear, such as truncating or compressing feature values ​​with periodic intensity exceeding a certain threshold. The goal is to weaken the feature components caused by texture structure while preserving as much of the possible true color changes as possible. Through this suppression process, the local color contrast features within the periodically textured region are adjusted to a more reasonable range, avoiding interference from texture structure in subsequent processing without completely erasing any possible true color information within the region. Step 7 concludes by combining the adjusted local color contrast features with the pixel chromaticity values ​​to generate initial feature maps for each scale. Through this processing, the local color contrast features within periodic texture regions are appropriately suppressed in the initial feature maps at each scale, while the features in non-periodic regions remain unchanged. These initial feature maps are then superimposed to form the final color perception feature map, which is used in the color feature mapping network.

[0071] refer to Figure 6For example, consider the color optimization of an image of a striped shirt. In this image, the shirt area displays a dense pattern of fine stripes with uniform spacing, representing a typical periodic dense texture. While the overall image tone is normal, the shirt area appears slightly dull due to lighting conditions, requiring appropriate color optimization to improve visual appeal. Traditional color optimization methods, when extracting local color contrast features, suffer from the periodic fluctuations of the stripes, causing regular variations in the chromaticity difference between each pixel and its surrounding background. These fluctuations caused by the texture structure are misinterpreted as significant local color changes, resulting in excessively high adjustment coefficients after input into the feature mapping network. After filtering, the shirt area exhibits unexpected color enhancement, with unnatural color ripples mixed into the originally uniform stripes, compromising the texture's realism. This invention performs color space transformation and channel separation on the image, extracting multi-scale local color contrast features from the color channels. For the shirt area, each scale of the local color contrast feature map shows regular fluctuations corresponding to the stripe period. Then, spatial frequency domain analysis is performed on these local color contrast feature maps. Frequency domain analysis revealed significant energy peaks in the shirt area at specific frequencies, indicating that this region belongs to a periodically dense texture feature area. Based on the frequency domain analysis results, the shirt area was divided into independent periodically dense texture feature regions, and the periodic intensity distribution within these regions was further analyzed. The analysis showed that the periodic intensity was higher in areas with dense stripes, while it was slightly lower at the stripe edges or where the stripes intersected with other clothing. Based on the periodic intensity distribution map, the local color contrast features within the shirt area were adaptively adjusted. At locations with high periodic intensity, such as the stripe center, the local color contrast features were significantly suppressed; at locations with moderate periodic intensity, such as the stripe edges, the suppression was correspondingly reduced. After adjustment, feature fluctuations caused by the texture structure were effectively weakened, while potential real color variations were preserved. The adjusted local color contrast features were combined with the pixel chromaticity values ​​to generate an adjusted initial feature map, which was then superimposed to form the final color perception feature map. When this feature map was input into the subsequent network, the generated adjustment coefficients primarily addressed the issue of realistic color dimness, rather than over-responding to the stripe structure.

[0072] In one embodiment, the step of adjusting the local color contrast features within the feature region of the periodic dense texture based on the periodic intensity includes:

[0073] Obtain the local color contrast feature value of each pixel within the feature region of the periodic dense texture at the current scale;

[0074] Extract the periodic intensity value corresponding to the pixel position from the periodic intensity distribution map;

[0075] Based on the periodic intensity value, a suppression coefficient corresponding to the periodic intensity value is determined, wherein the periodic intensity value and the suppression coefficient are positively correlated;

[0076] Multiply the local color contrast feature value by the suppression coefficient to obtain the adjusted local color contrast feature value;

[0077] Based on the adjusted local color contrast feature values ​​of all pixels, a local color contrast feature map adjusted at the current scale is generated.

[0078] As described above, Step 1 obtains the local color contrast feature value of each pixel within the periodic dense texture feature region at the current scale. These feature values ​​are calculated in the previous steps and are identified as belonging to the periodic dense texture region. The local color contrast feature value reflects the degree of difference between the chromaticity of each pixel and the chromaticity of its surrounding environment. In periodic texture regions, these feature values ​​often contain regular fluctuations caused by the texture structure. Obtaining these feature values ​​is for subsequent adjustments to weaken the texture-induced components while retaining any possible true color change information. The object of adjustment is clearly defined. It is not an adjustment of the original image pixels, nor an adjustment of the chromaticity values, but a specific adjustment of the intermediate feature of local color contrast feature values. This design ensures that the subsequent color optimization process is still based on complete color perception features, only preprocessing the components that may cause misjudgment. Step 2 extracts the periodic intensity value corresponding to each pixel position from the generated periodic intensity distribution map. The periodic intensity distribution map and the local color contrast feature map have the same spatial size, and each pixel position has a corresponding periodic intensity value. The periodic intensity value quantifies the degree to which the local color contrast features of a pixel are affected by periodic texture. In the texture center region, the periodic intensity value is high, indicating that the feature value at this location is mainly caused by the texture structure; at the texture edge or where it intersects with other regions, the periodic intensity value is moderate or low, indicating that the feature value at this location may be a mixture of texture influence and true color variation. Through this step, each pixel's local color contrast feature value obtains a corresponding weight information, indicating the extent to which the feature value needs adjustment. This pixel-level correspondence provides precise guidance for subsequent fine-tuning. Step 3 requires determining the corresponding suppression coefficient based on the periodic intensity value of each pixel. The suppression coefficient is positively correlated with the periodic intensity value; that is, the higher the periodic intensity, the larger the suppression coefficient; the lower the periodic intensity, the smaller the suppression coefficient. This positive correlation can be achieved in various ways. For example, a linear mapping relationship can be established, mapping the range of periodic intensity values ​​from zero to the maximum value to a suppression coefficient range of one to zero. When the periodic intensity is zero, the suppression coefficient is one, indicating no suppression at all; when the periodic intensity reaches its maximum value, the suppression coefficient is zero, indicating complete suppression. Alternatively, a non-linear mapping can be used, where the suppression coefficient decreases slowly when the periodic intensity is low and decreases rapidly after the periodic intensity exceeds a certain threshold, thus achieving segmented control of different intensity ranges. The suppression coefficient typically ranges from zero to one. When the suppression coefficient is one, it indicates no suppression of the feature value; when the suppression coefficient is zero, it indicates complete suppression of the feature value; when the suppression coefficient is between zero and one, it indicates a proportional attenuation of the feature value. Step 4 multiplies the local color contrast feature value by the corresponding suppression coefficient to obtain the adjusted local color contrast feature value.Through multiplication, the local color contrast feature values ​​in areas with high periodicity are significantly attenuated, effectively reducing high-frequency fluctuations caused by texture structure. In areas with low periodicity, the local color contrast feature values ​​remain essentially unchanged, preserving true color change information. In areas with moderate periodicity, the feature values ​​are appropriately attenuated, suppressing texture influence while also considering possible true color changes. The advantage of the multiplicative adjustment method lies in its continuity and smoothness. Since the periodicity value changes continuously in space, the suppression coefficient also changes continuously, resulting in a continuous spatial transition of the adjusted feature values, avoiding boundary effects or jumps caused by abrupt threshold cutting. Step 5 generates an adjusted local color contrast feature map at the current scale based on the adjusted local color contrast feature values ​​of all pixels. This feature map has the same size and resolution as the original feature map, the difference being that its values ​​have been adaptively suppressed according to the periodicity. The adjusted local color contrast feature map will be used to combine with the chromaticity values ​​of pixels to generate an initial feature map at the corresponding scale, which will then be superimposed to form the final color perception feature map. After this adjustment, the feature components of periodic texture regions in the color perception feature map have been reasonably suppressed, while the feature components of non-periodic regions remain unchanged, providing accurate input for the color feature mapping network.

[0079] In one embodiment, prior to the step of analyzing the periodic intensity of the feature region in spatial distribution based on the result of region segmentation, the method further includes:

[0080] Pattern decomposition is performed on the local color contrast feature map at each scale, and recurring local patterns are extracted as candidate primitives;

[0081] Calculate the similarity between each candidate primitive and detect the spatial arrangement pattern of the candidate primitives;

[0082] If there are candidate primitives with a similarity exceeding a first preset threshold, and the candidate primitives are arranged regularly in space, then the feature region is marked as an artificial periodic texture region.

[0083] Based on the artificial periodic texture region, the periodic intensity of the feature region in spatial distribution is analyzed.

[0084] As described above, step 1 performs pattern decomposition on the local color contrast feature maps at each scale, extracting recurring local patterns as candidate primitives. Pattern decomposition can be understood as breaking down the feature map into several small image blocks, each representing the color contrast feature distribution of a local region. These candidate primitives are similar to the basic units that constitute texture. For example, in a striped pattern of textiles, a stripe unit with alternating light and dark stripes may be a candidate primitive; in a brick wall image, the local features of a brick and the surrounding mortar joints may constitute a candidate primitive. Through pattern decomposition, recurring local structures can be extracted from the feature map. After extracting the candidate primitives in step 2, it is necessary to calculate the similarity between each candidate primitive and detect the spatial arrangement pattern of these candidate primitives. The similarity calculation is used to determine whether these local patterns are highly consistent, and the arrangement pattern detection is used to determine whether their spatial distribution is regular. For example, for man-made striped fabrics, the extracted candidate primitives often have a high similarity because they are all formed by the same repeated textile process. At the same time, these primitives usually exhibit a regular spatial arrangement, such as equal-spaced repetition or periodic cycles. For natural textures such as tree bark, although there may be local similarities, the similarity between primitives is usually low, and the spatial arrangement is random without obvious regularity. Step 3 marks the feature regions based on the detection results of similarity and arrangement regularity. If there are candidate primitives with similarity exceeding a first preset threshold, and these candidate primitives exhibit a regular spatial arrangement, then this feature region is marked as an artificial periodic texture region. The first preset threshold is used to determine whether the candidate primitives are sufficiently similar. The judgment of regular arrangement can be based on factors such as whether the spatial distance between primitives is consistent and whether the arrangement direction is uniform. Only when both conditions are met is the region identified as an artificial periodic texture region. For regions that do not meet the conditions, such as regions with low primitive similarity or random arrangement, they are classified as natural texture regions or ordinary texture regions, and no periodic intensity analysis and suppression processing are performed. Step 4 After completing the region marking, the periodic intensity analysis is only performed on the regions marked as artificial periodic textures. For these regions, the periodic intensity of their spatial distribution is analyzed, and a periodic intensity distribution map is generated. For areas with natural textures, the periodic intensity analysis and suppression steps are skipped, and their local color contrast features are directly used for feature combination. This ensures that the realistic texture of natural texture areas is not unduly suppressed.

[0085] In one feasible embodiment, the method further includes:

[0086] If the feature region is not marked as an artificial periodic texture region, then the feature region is marked as a natural texture region;

[0087] The local color contrast features within the natural texture area are not subjected to periodic intensity analysis and adjustment, but are directly combined with the chromaticity values ​​of the pixels to generate an initial feature map corresponding to each scale.

[0088] As described above, in step 1, feature regions not marked as artificial periodic texture regions in the preceding steps are marked as natural texture regions. After pattern decomposition and primitive analysis, regions that do not meet the criteria for artificial periodic texture are all classified as natural texture regions. Natural texture regions cover a wide range, including areas with naturally formed texture structures such as tree bark, sand, and water ripples, as well as uniform areas without obvious textures such as skin and the sky. The common characteristic of these regions is that the changes in their local color contrast features mainly originate from natural attributes, rather than artificial regular structures. In step 2, no periodic intensity analysis or corresponding feature adjustment is performed on the local areas marked as natural texture regions. The fluctuations in local color contrast features within natural texture regions are precisely an important component of their visual realism. For example, the rough texture of tree bark, the granular texture of sand, and the changes in water ripples are all perceived and recognized by the human eye through these feature fluctuations. If these fluctuations are suppressed, texture details will be lost, and the image will lose its realism. Therefore, skipping periodic intensity analysis means preserving the original feature expression of these natural texture regions. Local color contrast features are preserved intact, without attenuation or modification, ensuring that subsequent processing can accurately perceive the true color changes in these areas. Step 3 combines these unadjusted local color contrast features with the chromaticity values ​​of pixels to generate initial feature maps corresponding to each scale. For artificial periodic texture regions, the input is adjusted feature values ​​after periodic intensity suppression; for natural texture regions, the input is the original, unadjusted feature values. The feature maps from the two paths are finally merged to form a complete initial feature map for each scale.

[0089] It is worth noting that this invention faces challenges when processing a set of images with significant content differences. This set of images contains various types of textures, such as artificial textures like finely striped fabric or neatly arranged fences, natural textures like tree bark or sand, and textureless images like a clear sky or human skin. Periodicity intensity is needed to guide the suppression of feature regions. However, periodicity intensity is a continuous value, and in practical applications, a clear threshold needs to be set to determine which intensities of periodicity need to be suppressed and which do not. This presents a dilemma. If the periodicity intensity threshold is set too high, only very obvious artificial periodic textures, such as striped fabric, will be suppressed, while moderately intense periodic regions, such as some natural textures, will be preserved. Although the local color contrast features of these natural textures are not strongly periodic, they may still be misinterpreted by subsequent color feature mapping networks as color changes that need adjustment, resulting in unexpected artifacts in the processed image. If the periodicity intensity threshold is set too low, a large number of weakly periodic regions, such as the slight repetition of texture on tree bark, will be included in the suppression range. When the local color contrast features of these natural textures are weakened, subsequent networks struggle to accurately perceive the true color changes in these areas, resulting in the loss of texture details in the image. Tree bark loses its roughness, sand becomes blurry and flat, and the natural texture of the image is severely damaged.

[0090] This embodiment expands the judgment criterion from a single periodic intensity value to the identification of the essential attributes of the texture. In areas of artificial striped fabric, pattern decomposition extracts highly similar stripe primitives, and these primitives are arranged at equal intervals, satisfying the judgment criteria for artificial textures, thus classifying them as artificial periodic textures. In subsequent processes, regardless of the periodic intensity, they are processed according to predetermined suppression rules, avoiding missed judgments due to improper threshold settings. In natural texture areas such as tree bark, the primitives extracted by pattern decomposition have diverse shapes, low similarity, and no discernible spatial arrangement, thus being judged as natural textures. These areas skip the periodic intensity analysis and suppression steps, preserving the original features completely. In this way, even if these natural textures have a certain periodic intensity, they will not be misjudged and suppressed, preserving their delicate texture. For textureless areas such as the sky and skin, pattern decomposition may not extract obvious repeating patterns, but they are also classified as natural textures, with features fully preserved.

[0091] It should be added that the color feature mapping network used needs to be pre-trained to accurately map the input color perception feature map to the corresponding color adjustment coefficients. The training process includes: training data preparation: first, a training dataset needs to be constructed. The training data contains a large number of high-fidelity images, which should cover a wide range of scene types, including people, landscapes, buildings, artificial textures, and natural textures, to ensure the network's generalization ability. For each training image, its color perception feature map needs to be extracted according to the method described above, and used as the network input. At the same time, the expected output adjustment coefficients need to be labeled for each training image as training labels. The labeling of the expected adjustment coefficients can be done in two ways: one is for professional image processing personnel to manually adjust the image to the best visual effect and record the adjustment parameters as labels; the other is to use the original image as a reference, generate a target image through a color enhancement algorithm, and then derive the adjustment coefficients in reverse. Regardless of the method used, it is necessary to ensure that the label data can truly reflect the mapping relationship from the input features to the ideal adjustment. Network training process: the prepared training data is input into the color feature mapping network, and according to the forward propagation process described above, the network generates predicted adjustment coefficients based on the input color perception feature map. The difference between the predicted adjustment coefficient and the labeled true adjustment coefficient is calculated and used as the loss function. The loss function can take common forms such as mean squared error or mean absolute error, used to measure how close the predicted value is to the true value. Based on the error calculated by the loss function, the network's weight parameters are updated using the backpropagation algorithm. This process is iterated repeatedly on a large amount of training data, with each iteration making the network's predictions closer to the true labels. As the number of training rounds increases, the network gradually learns the mapping pattern from color perception features to adjustment coefficients. Construction of the benchmark feature library: The benchmark color perception feature library in the above method can include two construction methods. One is to train it jointly with the network, using benchmark feature vectors as learnable parameters and continuously optimizing them during training. The other is to select representative feature vectors from the training set as benchmarks after the network training is complete, or to cluster a large number of feature vectors using a clustering algorithm, using the cluster centers as benchmark feature vectors, and associating each benchmark vector with a corresponding adjustment coefficient. Regardless of the method used, the final benchmark feature library should be able to cover common color feature patterns and provide reasonable adjustment coefficient references for each pattern. Training Completion and Network Deployment: The network training is complete when the loss function converges below a preset threshold or after the preset number of iterations has been reached. At this point, the network's weight parameters are fixed, and the baseline feature library is constructed.

[0092] Reference Figure 3 This application also provides an image color fidelity optimization system based on color perception feature mapping, comprising:

[0093] Acquisition module 1 is used to acquire the image to be processed in real time, convert the image to be processed from the RGB color space to the uniform perception color space, and separate the luminance channel and the color channel in the uniform perception color space.

[0094] Extraction module 2 is used to extract color perception features from the color channel. The color perception features include the chromaticity value of the pixel and the local color space features. Based on the chromaticity value of the pixel and the local color space features, a color perception feature map is constructed.

[0095] Input module 3 is used to input the color perception feature map into a preset color feature mapping network, and to perform nonlinear mapping between the color perception feature map and the reference color perception feature through the color feature mapping network to generate adjustment coefficients for each color channel.

[0096] The filtering module 4 is used to filter the original color channel based on the adjustment coefficient to obtain the adjusted color channel.

[0097] The recombination and conversion module 5 is used to recombine the adjusted color channels with the original luminance channels, and convert the recombined color channels to the RGB color space to obtain a preliminary optimized image;

[0098] Output module 6 is used to call the color fidelity loss function to verify the preliminary optimized image. When the color fidelity meets the preset fidelity threshold, the final optimized image is output.

[0099] As described above, it is understood that each component of the image color fidelity optimization system based on color perception feature mapping proposed in this application can realize the function of any one of the image color fidelity optimization methods based on color perception feature mapping as described above, and the specific structure will not be described in detail.

[0100] Reference Figure 4 This application also provides a computer device, which may be a server, and its internal structure may be as follows: Figure 4 As shown, this computer device includes a processor, memory, network interface, and database connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and database. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The database stores monitoring data and other data. The network interface is used for communication with external terminals via a network connection. When executed by the processor, the computer program implements an image color fidelity optimization method based on color perception feature mapping.

[0101] The processor described above executes the image color fidelity optimization method based on color perception feature mapping, comprising: acquiring the image to be processed in real time; converting the image to be processed from the RGB color space to a uniform perception color space; separating the luminance channel and the color channel in the uniform perception color space; extracting color perception features from the color channels, the color perception features including the chromaticity value of the pixel and local color space features; constructing a color perception feature map based on the chromaticity value of the pixel and the local color space features; inputting the color perception feature map into a preset color feature mapping network; performing a nonlinear mapping between the color perception feature map and the reference color perception features through the color feature mapping network to generate adjustment coefficients for each color channel; filtering the original color channels based on the adjustment coefficients to obtain adjusted color channels; recombining the adjusted color channels with the original luminance channel; converting the recombined color channels to the RGB color space to obtain a preliminary optimized image; verifying the preliminary optimized image by calling a color fidelity loss function; and outputting the final optimized image when the color fidelity meets a preset fidelity threshold.

[0102] One embodiment of this application also provides a computer-readable storage medium storing a computer program thereon. When executed by a processor, the computer program implements an image color fidelity optimization method based on color perception feature mapping, comprising the following steps: acquiring an image to be processed in real time; converting the image to be processed from an RGB color space to a uniform perception color space; separating a luminance channel and a color channel in the uniform perception color space; extracting color perception features from the color channels, the color perception features including the chromaticity values ​​of pixels and local color space features; constructing a color perception feature map based on the chromaticity values ​​of pixels and local color space features; inputting the color perception feature map into a preset color feature mapping network; performing a nonlinear mapping between the color perception feature map and a reference color perception feature through the color feature mapping network to generate adjustment coefficients for each color channel; filtering the original color channels based on the adjustment coefficients to obtain adjusted color channels; recombining the adjusted color channels with the original luminance channel; converting the recombined color channels to an RGB color space to obtain a preliminary optimized image; verifying the preliminary optimized image by calling a color fidelity loss function; and outputting the final optimized image when the color fidelity meets a preset fidelity threshold.

[0103] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in this application and in the embodiments can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual-speed SDRAM (SSRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

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

[0105] The above description is only a preferred embodiment of this application and does not limit the patent scope of this application. Any equivalent structural or procedural changes made based on the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. A method for optimizing image color fidelity based on color perception feature mapping, characterized in that, The method includes: The image to be processed is acquired in real time, and the image to be processed is converted from the RGB color space to the uniform perception color space. The brightness channel and the color channel are separated in the uniform perception color space. Color perception features are extracted from the color channels. The color perception features include the chromaticity values ​​of pixels and local color space features. A color perception feature map is constructed based on the chromaticity values ​​of pixels and local color space features. The color perception feature map is input into a preset color feature mapping network. The color feature mapping network performs a non-linear mapping between the color perception feature map and the reference color perception feature to generate an adjustment coefficient for each color channel. Based on the adjustment coefficient, the original color channel is filtered to obtain the adjusted color channel; The adjusted color channels are recombined with the original luminance channels, and the recombined color channels are converted to the RGB color space to obtain a preliminary optimized image; The color fidelity loss function is called to verify the preliminary optimized image. When the color fidelity meets the preset fidelity threshold, the final optimized image is output. The step of constructing a color perception feature map based on the chromaticity values ​​and local color space features of the pixels includes: For each pixel in the color channel, a neighborhood window of different sizes is extracted with the pixel as the center. Within each neighborhood window of a given size, the average chromaticity of all pixels within the window is calculated, and this average chromaticity is used as the local background chromaticity of that pixel at the current scale. Each scale corresponds to a neighborhood window of a given size. Calculate the difference between the chromaticity value of a pixel and the local background chromaticity of the pixel at the current scale. Based on the calculation result, use the difference value as the local color contrast feature of the pixel at the current scale. The chromaticity value of each pixel and the local color contrast features at each scale are combined to generate the initial feature map corresponding to each scale. The initial feature maps at various scales are superimposed to form the color perception feature map.

2. The image color fidelity optimization method based on color perception feature mapping according to claim 1, characterized in that, The step of inputting the color perception feature map into a preset color feature mapping network, and then performing a non-linear mapping between the color perception feature map and the reference color perception feature through the color feature mapping network to generate adjustment coefficients for each color channel includes: The color perception feature map is input into the color feature mapping network. The color perception feature map contains initial feature maps at multiple scales. Each initial feature map at a scale contains the chromaticity value of a pixel and the local color contrast features at that scale. In the color feature mapping network, the initial feature map at each scale is convolved, and the scale feature map corresponding to each scale is extracted based on the processing result. The scale feature maps corresponding to each scale are fused to obtain a fused feature map. The fused feature map is compared with a preset benchmark color perception feature library, which includes multiple benchmark feature vectors and corresponding benchmark adjustment coefficients. Calculate the similarity between the feature vector at each position in the fused feature map and each reference feature vector, and perform a weighted summation of the corresponding reference adjustment coefficients based on the similarity to obtain the adjustment coefficient for each position for each color channel; Based on the adjustment coefficients at all locations, generate an adjustment coefficient map with the same dimensions as the original color channels.

3. The image color fidelity optimization method based on color perception feature mapping according to claim 2, characterized in that, The steps of recombining the adjusted color channels with the original luminance channels and converting the recombined color channels to the RGB color space to obtain a preliminary optimized image include: The adjusted color channels and the original luminance channels are merged in the uniform perception color space to obtain a reconstructed uniform perception color space image. Based on the reconstructed uniform perception color space image, the chromaticity values ​​of each pixel in the color channel of the reconstructed uniform perception color space image are obtained, and the chromaticity values ​​are converted into chromaticity coordinates corresponding to the RGB color space. Based on the chromaticity coordinates, it is determined whether each pixel exceeds the color gamut range of the RGB color space. According to the determination result, for pixels that exceed the color gamut range, the chromaticity coordinates are compressed into the color gamut boundary. Based on the compression results, the compressed chromaticity coordinates are combined with the luminance values ​​corresponding to the luminance channels to generate a preliminary optimized image in the RGB color space.

4. The image color fidelity optimization method based on color perception feature mapping according to claim 1, characterized in that, The step of constructing a color perception feature map based on the chromaticity values ​​and local color space features of the pixels further includes: After calculating the local color contrast features of each pixel at different scales, spatial frequency domain analysis is performed on the local color contrast features at each scale. Based on the analysis results, determine whether there are periodic dense texture feature regions in the local color contrast features; If there are feature regions with periodic dense textures, then the feature regions with periodic dense textures are divided into regions. Based on the results of the region division, the periodic intensity of the characteristic region in spatial distribution is analyzed, and a periodic intensity distribution map of the characteristic region is generated according to the periodic intensity. Determine the periodic intensity of the local color contrast features in spatial distribution at the current scale; Based on the periodicity intensity, the local color contrast features within the feature region of the periodic dense texture are adjusted, wherein the higher the periodicity intensity, the greater the suppression of the local color contrast features. The adjusted local color contrast features are combined with the chromaticity values ​​of the pixels to generate an initial feature map corresponding to each scale.

5. The image color fidelity optimization method based on color perception feature mapping according to claim 4, characterized in that, The step of adjusting the local color contrast features within the feature region of the periodic dense texture based on the periodic intensity includes: Obtain the local color contrast feature value of each pixel within the feature region of the periodic dense texture at the current scale; Extract the periodic intensity value corresponding to each pixel position from the periodic intensity distribution map; Based on the periodic intensity value, a suppression coefficient corresponding to the periodic intensity value is determined, wherein the periodic intensity value and the suppression coefficient are positively correlated; Multiply the local color contrast feature value by the suppression coefficient to obtain the adjusted local color contrast feature value; Based on the adjusted local color contrast feature values ​​of all pixels, a local color contrast feature map adjusted at the current scale is generated.

6. The image color fidelity optimization method based on color perception feature mapping according to claim 4, characterized in that, Before the step of analyzing the periodic intensity of the characteristic region in spatial distribution based on the region division results, the method further includes: Pattern decomposition is performed on the local color contrast feature map at each scale, and recurring local patterns are extracted as candidate primitives; Calculate the similarity between each candidate primitive and detect the spatial arrangement pattern of the candidate primitives; If there are candidate primitives with a similarity exceeding a first preset threshold, and the candidate primitives are arranged regularly in space, then the feature region is marked as an artificial periodic texture region. Based on the artificial periodic texture region, the periodic intensity of the feature region in spatial distribution is analyzed.

7. An image color fidelity optimization system based on color perception feature mapping, used in the method described in any one of claims 1-6, characterized in that, include: The acquisition module is used to acquire the image to be processed in real time, convert the image to be processed from the RGB color space to the uniform perception color space, and separate the luminance channel and the color channel in the uniform perception color space. An extraction module is used to extract color perception features from the color channels. The color perception features include the chromaticity values ​​of pixels and local color space features. A color perception feature map is constructed based on the chromaticity values ​​of pixels and local color space features. The input module is used to input the color perception feature map into a preset color feature mapping network, and to perform a nonlinear mapping between the color perception feature map and the reference color perception feature through the color feature mapping network to generate the adjustment coefficient for each color channel. The filtering module is used to filter the original color channel based on the adjustment coefficient to obtain the adjusted color channel; The reconstruction and conversion module is used to reconstruct the adjusted color channels with the original luminance channels, and convert the reconstructed color channels to the RGB color space to obtain a preliminary optimized image; The output module is used to call the color fidelity loss function to verify the preliminary optimized image. When the color fidelity meets the preset fidelity threshold, the final optimized image is output.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Digital image color correcting method and realizing device

    CN102769759A

  • Detection method and system of high-color gamut display screen for mobile phone

    CN118823141A

  • Low-light environment image adaptive enhancement method based on unmanned aerial vehicle inspection

    CN121053049A