Low-illumination image enhancement method, system, equipment and medium
By using technical means of color space feature extraction, pooling, denoising and chromaticity enhancement in low-light image processing, the problem of low-light image enhancement in the prior art lacks adaptability and prone to noise or distortion, and the image quality improvement and detail retention are achieved.
Patent Information
- Application Number
- CN202411574117.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-06
- Publication Date
- 2025-04-01
AI Technical Summary
The existing low-light image enhancement methods lack adaptability and are difficult to cope with complex and changeable actual scenarios, and are prone to additional noise or image distortion.
By extracting the initial image according to the color space, a brightness feature map and multiple chromaticity feature maps are obtained. After pooling operations, the brightness channel importance matrix and luminance feature map are extracted from the brightness feature map, dot product calculation is performed to denoise, and the chromaticity enhancement feature map is calculated based on the chromaticity feature map, and then stitching it and upsampling is performed to generate a low-illuminance enhancement image.
This method can enrich the content of low-illumination images, improve image quality, enhance image brightness and contrast, reduce noise, retain image details, and is suitable for complex and changeable actual scenes.
Smart Images

Figure CN119741240A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image processing technology, and in particular to a low-illumination image enhancement method, system, device and medium. Background Art
[0002] In recent years, the development of deep learning technology has brought new breakthroughs in image processing. The use of intelligent technology has gradually increased the requirements for image recognition technology. The imaging quality of the image often has a great impact on the recognition results. For example, in the evening or at night, due to insufficient light or insufficient lighting intensity, the image will appear dim, with low contrast and serious loss of image details.
[0003] In the current image processing field, existing low-light image enhancement methods are to perform various linear or nonlinear operations on pixel values, such as grayscale stretching, histogram equalization, etc., while existing technologies are based on fixed rules for adjustment and lack adaptability, making it difficult to cope with complex and changeable actual scenes. Not only are they not suitable for all types of images, but they are also prone to technical problems such as additional noise or image distortion. Summary of the invention
[0004] The following is a summary of the subject matter described in detail herein. This summary is not intended to limit the scope of the claims.
[0005] The main purpose of the embodiments of the present disclosure is to provide a low-light image enhancement method, system, device and storage medium, which can enrich the low-light image content and improve the image quality.
[0006] A first aspect of an embodiment of the present application provides a low-illumination image enhancement method, the method comprising:
[0007] Extract features of the initial image according to the color space to obtain a brightness feature map and multiple chromaticity feature maps;
[0008] Performing pooling operations on the brightness feature map and the multiple chromaticity feature maps respectively to obtain processed brightness feature maps and multiple chromaticity feature maps;
[0009] Extracting a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map;
[0010] Performing a dot product operation on the brightness channel importance matrix and the first brightness feature map to obtain a brightness denoising feature map;
[0011] Calculate a plurality of chromaticity enhancement feature maps according to the processed plurality of chromaticity feature maps;
[0012] Splicing the brightness denoising feature map and the multiple chroma enhancement feature maps to obtain an intermediate feature map;
[0013] The intermediate feature map is upsampled to obtain a low-illumination enhanced image.
[0014] The embodiment of the present application provides a low-illumination image enhancement method, which extracts features of an initial image according to a color space to obtain a brightness feature map and multiple chromaticity feature maps; performs pooling operations on the brightness feature map and the multiple chromaticity feature maps respectively to obtain a processed brightness feature map and multiple chromaticity feature maps; extracts a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map; performs a dot product operation on the brightness channel importance matrix and the first brightness feature map to obtain a brightness denoising feature map; calculates multiple chromaticity enhancement feature maps based on the processed multiple chromaticity feature maps; splices the brightness denoising feature map and the multiple chromaticity enhancement feature maps to obtain an intermediate feature map; performs upsampling processing on the intermediate feature map to obtain a low-illumination enhanced image, which can enrich the image content and thus improve the low-illumination image quality.
[0015] In some embodiments of the present application, before extracting features from the initial image according to the color space to obtain a brightness feature map and a plurality of chromaticity feature maps, the method further includes:
[0016] Acquire a low-light image, and perform contrast enhancement on the low-light image to obtain a processed low-light image;
[0017] The pixel values in the processed low-illuminance image are normalized and mapped to obtain the initial image.
[0018] In some embodiments of the present application, the chromaticity feature map includes a U chromaticity feature map and a V chromaticity feature map, and the pooling operation on the brightness feature map includes:
[0019] Performing a global average pooling operation on the brightness feature map to obtain the processed brightness feature map;
[0020] Performing a pooling operation on any one of the plurality of chromaticity feature maps, comprising:
[0021] Performing a maximum pooling operation on the U chromaticity feature map of the chromaticity feature map to obtain a processed U chromaticity feature map;
[0022] Performing an average pooling operation on the V chromaticity feature map of the chromaticity feature map to obtain a processed V chromaticity feature map;
[0023] The processed U chromaticity characteristic graph and the processed V chromaticity characteristic graph are used as processed chromaticity characteristic graphs.
[0024] In some embodiments of the present application, extracting a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map includes:
[0025] Performing a convolution operation on the processed brightness feature map to obtain the first brightness feature map;
[0026] Linearly combining the processed brightness feature maps to generate a second brightness feature map;
[0027] Processing the second brightness feature map through a ReLU activation function to obtain a processed second brightness feature map;
[0028] The processed second brightness feature map is linearly combined to generate a third brightness feature map, and the third brightness feature map is processed by a Sigmoid activation function to obtain the brightness channel importance matrix.
[0029] In some embodiments of the present application, the step of calculating a plurality of chromaticity enhancement feature maps according to the processed plurality of chromaticity feature maps includes:
[0030] Adding the processed multiple chromaticity feature maps to obtain a correlation matrix;
[0031] The correlation matrix is pixel-multiplied by the multiple chromaticity feature maps respectively to obtain multiple chromaticity enhancement feature maps corresponding to the multiple chromaticity feature maps.
[0032] In some embodiments of the present application, after upsampling the intermediate feature map to obtain a low-light enhanced image, the method further includes:
[0033] Through non-maximum suppression and threshold screening, the low-light enhanced image is detected using a preset target detection model to obtain a corresponding detection result, wherein the detection result includes the category and position information of the object in the low-light image.
[0034] A second aspect of an embodiment of the present invention provides a low-illumination image enhancement system, the system comprising:
[0035] A feature extraction module is used to extract features of the initial image according to the color space to obtain a brightness feature map and multiple chromaticity feature maps;
[0036] An image pooling module, used to perform pooling operations on the brightness feature map and the multiple chromaticity feature maps respectively to obtain processed brightness feature maps and multiple chromaticity feature maps;
[0037] An image extraction module, used for extracting a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map;
[0038] An image calculation module, used for performing a dot product operation on the brightness channel importance matrix and the first brightness feature map to obtain a brightness denoising feature map;
[0039] An image enhancement module, used for calculating a plurality of chromaticity enhancement feature maps according to the processed plurality of chromaticity feature maps;
[0040] An image stitching module, used for stitching the brightness denoising feature map and the multiple chroma enhancement feature maps to obtain an intermediate feature map;
[0041] The image processing module is used to perform upsampling processing on the intermediate feature map to obtain a low-illumination enhanced image.
[0042] A third aspect of an embodiment of the present invention provides an electronic device, comprising: at least one control processor and a memory for communicating with the at least one control processor; the memory stores instructions that can be executed by the at least one control processor, and the instructions are executed by the at least one control processor so that the at least one control processor can execute the above-mentioned low-illuminance image enhancement method.
[0043] A fourth aspect of an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the above-mentioned low-illumination image enhancement method.
[0044] A fifth aspect of an embodiment of the present invention provides a computer program product. When instructions in the computer program product are executed by a processor of an electronic device, the electronic device executes the above-mentioned low-illumination image enhancement method.
[0045] It can be understood that the beneficial effects of the second to fifth aspects compared with the related art are the same as the beneficial effects of the first aspect compared with the related art. Please refer to the relevant description in the first aspect, and no further details will be given here. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the description of the embodiments in conjunction with the following drawings, in which:
[0047] Figure 1 It is a flowchart of a low-light image enhancement method provided in an embodiment of the present application;
[0048] Figure 2 This is a schematic diagram of image recognition in an implementation manner provided in an embodiment of the present application;
[0049] Figure 3is a structural schematic diagram of a low-light image enhancement system provided in an embodiment of the present application;
[0050] Figure 4 It is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0051] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be understood as limiting the present application.
[0052] In the description of this application, if there is a description of first, second, etc., it is only for the purpose of distinguishing technical features, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features or implicitly indicating the order of the indicated technical features.
[0053] In the description of the present application, it should be understood that the descriptions involving orientation, such as the orientation or positional relationship indicated as up, down, etc., are based on the orientation or positional relationship shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present application.
[0054] In the description of this application, it should be noted that, unless otherwise clearly defined, terms such as setting, installing, connecting, etc. should be understood in a broad sense, and technicians in the relevant technical field can reasonably determine the specific meaning of the above terms in this application based on the specific content of the technical solution.
[0055] In the current image processing field, existing low-light image enhancement methods are to perform various linear or nonlinear operations on pixel values, such as grayscale stretching, histogram equalization, etc., while existing technologies are based on fixed rules for adjustment and lack adaptability, making it difficult to cope with complex and changeable actual scenes. Not only are they not suitable for all types of images, but they are also prone to technical problems such as additional noise or image distortion.
[0056] For this purpose, refer to Figure 1 An embodiment of the present application provides a low-light image enhancement method. The method is applied to a controller. The controller can be a server, an electronic device, or a mobile terminal, etc., which is not specifically limited here. The method includes the following steps S110 to S170.
[0057] Step S110: extract features of the initial image according to the color space to obtain a brightness feature map and multiple chromaticity feature maps.
[0058] In this step, before executing the step of extracting features of the initial image according to the color space to obtain a brightness feature map and multiple chromaticity feature maps, it also includes acquiring a low-light image, contrast enhancing the low-light image, and obtaining a processed low-light image; normalizing the pixel values in the processed low-light image and mapping to obtain the initial image.
[0059] Specifically, low-light images are not limited to photos taken directly by image processing devices equipped with low-light image enhancement systems (such as visual intelligent monitors, smart terminal devices), but also include photos taken by other external devices (such as network cameras, portable cameras, etc.) and subsequently imported or synchronized to the image processing device. In addition, low-light images may also come from cloud storage platforms and directly reach the image processing device for processing via network transmission. Similarly, these images may also be taken by independent imaging devices, such as high-end digital SLR cameras or professional cameras in different environments, and then uploaded to the image processing device through wireless transmission (Wi-Fi, Bluetooth, etc.), data cable transmission, etc.
[0060] In this embodiment, the low-light image may be an image captured by an imaging system (e.g., a camera), wherein the imaging system may be configured by the image processing device itself or by other devices. For example, the low-light image is a monitoring object in a specific scene captured by an intelligent visual device equipped with an image acquisition device; or the low-light image is a specific monitoring target captured by a fixed network camera and sent to the image processing device, etc.
[0061] In this embodiment, a low-light image is first acquired through an image acquisition device, and contrast enhancement processing is performed on the low-light image, including but not limited to processing the acquired low-light image through an adaptive nonlinear upscaling technology to adaptively improve the image contrast, thereby significantly enhancing the detail information of the dark and bright parts of the image, and then the pixel values in the processed low-light image are normalized, and the initial image for subsequent image enhancement is obtained by mapping the pixel values of the low-light image to a standardized interval of [0,1].
[0062] Furthermore, the low-light image is converted from the RGB color space to the YUV color space so that the brightness information and the chromaticity information can be effectively separated, wherein the color space includes but is not limited to RGB, CMY, HSV, and HSI. The brightness information includes the Y component, and the chromaticity information includes the U component and the V component. By extracting features of the initial image according to the color space, a brightness feature map and multiple chromaticity feature maps are obtained, which accurately reflect the brightness and color differences in the low-light image, facilitating subsequent image enhancement.
[0063] In one implementation of this embodiment, feature extraction is performed on the initial image according to the color space, and a brightness feature map and multiple chromaticity feature maps are obtained by two consecutive convolution blocks and a maximum pooling layer, wherein each convolution block consists of a convolution layer and a ReLU activation function layer, the convolution kernel size of the convolution layer is 3×3, the step size is 1, and the output feature map is 32. Feature extraction is performed on the brightness (Y) and chromaticity (U and V) channels of the YUV image to obtain three feature maps with consistent scales;
[0064] Step S120: performing pooling operations on the brightness feature map and the multiple chromaticity feature maps respectively to obtain processed brightness feature maps and multiple chromaticity feature maps.
[0065] In this step, the chromaticity feature map includes a U chromaticity feature map and a V chromaticity feature map, and the brightness feature map and multiple chromaticity feature maps are respectively pooled, including performing a global average pooling operation on the brightness feature map, performing a maximum pooling operation on the U chromaticity feature map of the chromaticity feature map, and performing an average pooling operation on the V chromaticity feature map of the chromaticity feature map, thereby obtaining a processed brightness feature map, a processed U chromaticity feature map, and a processed V chromaticity feature map, and the processed U chromaticity feature map and the processed V chromaticity feature map are used as processed chromaticity feature maps, thereby obtaining multiple processed chromaticity feature maps.
[0066] In this embodiment, the brightness feature map is the brightness information extracted from the initial image, and the chromaticity feature map is the color information extracted from the initial image. Pooling types are selected according to different color spaces or different feature maps, including but not limited to maximum pooling and average pooling. Among them, maximum pooling is to select the maximum value in each window as the output, which helps to maintain the significant features in the image, and average pooling is to calculate the average value of the pixels in each window, which helps to smooth the image. The appropriate pooling operation is selected according to different feature maps. The pooling operation can not only reduce the amount of data in the feature map, but also enhance the invariance of feature expression, improve the performance of subsequent tasks (such as classification, detection, etc.), and reduce computational complexity.
[0067] In one implementation of the present embodiment, a maximum pooling operation is performed on the U chromaticity feature map of the chromaticity feature map. Preferably, a window of a fixed size is defined and the window is moved across the entire feature map according to a step size. During each movement, the maximum value of the window coverage area is recorded, and a new feature map is formed based on the maximum value to obtain the processed U chromaticity feature map. After pooling, the size of the U chromaticity feature map is reduced and important color information is retained.
[0068] In one implementation of this embodiment, a maximum pooling operation is performed on the V chromaticity feature map of the chromaticity feature map. Preferably, a window of a fixed size is defined and the window is moved across the entire feature map according to a step size. During each movement, the maximum value of the window coverage area is recorded, and a new feature map is formed based on the maximum value to obtain a processed V chromaticity feature map. After pooling, the size of the V chromaticity feature map is reduced and important color information is retained.
[0069] In one implementation of this embodiment, the pooling operation of the brightness feature map is implemented through two branch units, the purpose of which is to reduce the noise interference in the brightness information, thereby improving the clarity of the image, as follows:
[0070] The first branch unit is used to generate the importance matrix of the brightness feature map. The first branch unit includes the following steps: performing a global average pooling operation on the input brightness feature map to reduce the spatial dimension of the feature map to a size of 1×1; inputting the feature map after global average pooling into a fully connected layer, and obtaining an output size of the fully connected layer of 1×1×32 / r; processing the feature map through a ReLU activation function layer; then, the feature map is further input into another fully connected layer to obtain an output result, and its output size is 1×1×32; finally, through a Sigmoid activation function layer, the brightness channel importance matrix is obtained, where is a scaling factor, which defaults to 4.
[0071] The second branch unit is used to extract features from the input brightness channel feature map. The second branch unit is composed of two convolutional layers stacked in sequence. The convolution kernel size of each convolutional layer is 3×3, the step size is 1, and the output feature map is 32.
[0072] Furthermore, a dot product operation is performed on the brightness channel importance matrix output by the first branch unit and the output feature map of the second branch unit to obtain a brightness denoising feature map, thereby effectively suppressing the noise in the brightness information and improving the overall quality of the image.
[0073] In some embodiments, the brightness feature map is pooled in step S120, including the following steps:
[0074] A global average pooling operation is performed on the brightness feature map to obtain a processed brightness feature map.
[0075] In this step, a global average pooling operation is performed on the brightness feature map, specifically including calculating the average value of all pixels in the entire feature map of the brightness feature map, and generating a single value by averaging all pixel values of the entire feature map, which represents the average brightness level of the entire brightness feature map. After global average pooling, the brightness feature map is converted into a single value, which is the result of global average pooling, that is, the processed brightness feature map, thereby extracting the overall characteristics of the image, significantly reducing the dimension of the feature map, reducing the number of parameters and avoiding overfitting.
[0076] In this embodiment, global average pooling (GAP) is a pooling operation, specifically applying average pooling on the entire feature map, that is, calculating the average value of each channel on the entire feature map, including adding the pixel values at each position in the feature map and then dividing it by the total number of pixels to obtain a single value as the representative value of the channel, thereby generating a processed brightness feature map. The final result is a 1x1 feature map, which contains the information concentration of the original brightness feature map. Therefore, for the brightness feature map extracted from the initial image, no matter what its original size is, after global average pooling, the output will be a 1x1 feature map, in which each element corresponds to the average of all pixel values of the corresponding channel in the brightness feature map.
[0077] By performing a global average pooling operation on the brightness feature map, the spatial dimension of the brightness feature map is significantly reduced and compressed into a single value. This not only effectively reduces the data dimension but also maintains important feature information, so that the brightness feature map has fewer parameters and lower computational complexity, thereby speeding up image processing.
[0078] In some embodiments, in step S120, a pooling operation is performed on any one of the plurality of chromaticity feature maps, including the following steps:
[0079] Performing a maximum pooling operation on the U chromaticity feature map of the chromaticity feature map to obtain a processed U chromaticity feature map;
[0080] Performing an average pooling operation on the V chromaticity feature map of the chromaticity feature map to obtain a processed V chromaticity feature map;
[0081] The processed U chromaticity feature map and the processed V chromaticity feature map are used as processed chromaticity feature maps.
[0082] In this step, in order to enhance the spatial correlation of chromaticity information, a maximum pooling operation is first performed on the U chromaticity feature map of the chromaticity feature map, including selecting the maximum pixel value in each pooling window of the U chromaticity feature map as the output value of the window, thereby compressing the U chromaticity feature map, and then an average pooling operation is performed on the V chromaticity feature map of the chromaticity feature map, including calculating the average value of all pixel values in each pooling window of the V chromaticity feature map as the output value of the window, thereby compressing the V chromaticity feature map, and then obtaining two chromaticity feature maps with the same output size.
[0083] In this embodiment, a maximum pooling operation is first performed on the U chromaticity feature map of the chromaticity feature map, including selecting a window of a preset size (for example, 2x2 or 3x3), sliding on the U chromaticity feature map, and then selecting the maximum value at each sliding window position as the output, and finally forming a processed U chromaticity feature map after size reduction based on the output maximum value. For the U color feature map, the most significant features in the local area are retained through the maximum pooling operation, which helps to maintain important structural information such as edges and details.
[0084] Similarly, an average pooling operation is performed on the V chromaticity feature map of the chromaticity feature map, including sliding a window of a preset size on the V chromaticity feature map, and then calculating the average of the pixel values in the current window at each window position, and generating a processed V chromaticity feature map with a reduced size according to the average value of each window. In addition, the processed U chromaticity feature map and the processed V chromaticity feature map constitute the processed chromaticity feature map. For the V color feature map, the average pooling operation can smooth the color changes in the image, reduce the impact of noise, and make the color information of the V chromaticity channel more uniform, which is conducive to expressing the overall color trend.
[0085] In addition, through different pooling methods, not only can the spatial correlation of chromaticity information be enhanced, but also the spatial resolution of the feature map can be reduced, thereby reducing the data dimension, thereby reducing the computing resources required for subsequent processing and optimizing the image processing process.
[0086] Step S130: extracting a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map.
[0087] In this step, the processed brightness feature map is first subjected to a convolution operation to obtain a first brightness feature map. The first brightness feature map is obtained through the convolution operation, including: selecting a suitable convolution kernel size to perform a convolution operation on the processed brightness feature map, applying the convolution kernel to the brightness feature map, and calculating the convolution result at each position by means of a sliding window, thereby outputting the first brightness feature map.
[0088] At the same time, the processed brightness feature map is linearly combined to generate a second brightness feature map. The linear combination process can be implemented by simple matrix multiplication, or a bias term can be added.
[0089] Then, the second brightness feature map is processed by the ReLU (Rectified Linear Unit) activation function, specifically including applying ReLU to the second brightness feature map, setting all negative values to 0, and keeping the positive values unchanged, so as to obtain the processed second brightness feature map, and then linearly combining the processed second brightness feature map to output the third brightness feature map.
[0090] The third brightness feature map is then processed by the Sigmoid activation function to obtain a brightness channel importance matrix, in which each element represents the importance of the corresponding area.
[0091] In this embodiment, the processed brightness feature map is first subjected to a convolution operation to obtain a first brightness feature map, wherein the convolution operation is performed by applying a convolution layer to the processed brightness feature map, detecting local features in the image, and capturing local features of the image by learning different filters, thereby extracting a richer feature representation from the original brightness feature map.
[0092] In addition, generating a first brightness feature map through a convolution operation helps to highlight or extract specific patterns or structures in the brightness map. Then the processed brightness feature map is linearly combined to generate a second brightness feature map, where the linear combination generally refers to weighted summation of input data using a set of weights, which can change the importance of different regions in the feature map, or fuse multiple feature maps to generate new representations, which helps the model learn more robust features, thereby potentially improving the model's performance on unseen data.
[0093] Then, the second brightness feature map is processed by the ReLU activation function to obtain the processed second brightness feature map. The rectified linear unit ReLU (Rectified Linear Unit) is a nonlinear activation function. By setting all negative values to 0 and retaining positive values, the second brightness feature map is processed by the ReLU activation function to introduce nonlinear factors, so that the model can learn more complex patterns and help alleviate the problem of gradient disappearance. Then, the processed second brightness feature map is linearly combined to generate the third brightness feature map. Finally, the third brightness feature map is processed by the Sigmoid activation function to obtain the brightness channel importance matrix. The Sigmoid activation function can map real numbers to the (0,1) interval and is used as the activation function of the output layer. Then, according to the third brightness feature map, a matrix representing the importance of the brightness channel is obtained, in which the value of each element reflects the importance of the brightness information at the corresponding position.
[0094] In some embodiments, extracting a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map in step S130 includes the following steps:
[0095] Performing a convolution operation on the processed brightness feature map to obtain a first brightness feature map;
[0096] Linearly combining the processed brightness feature maps to generate a second brightness feature map;
[0097] Processing the second brightness feature map through a ReLU activation function to obtain a processed second brightness feature map;
[0098] The processed second brightness feature map is linearly combined to generate a third brightness feature map, and the third brightness feature map is processed by a Sigmoid activation function to obtain a brightness channel importance matrix.
[0099] In this step, a first brightness feature map is obtained by performing a convolution operation on the processed brightness feature map, specifically including applying one or more convolution kernels (filters) to the input brightness feature map, wherein each convolution kernel performs a convolution operation with the brightness feature map, and then obtains the convolution result to form a new feature map, namely the first brightness feature map.
[0100] In addition, a second brightness feature map is generated by linearly combining the processed brightness feature map, including: when the first brightness feature map contains multiple channels (for example, multiple different convolution kernels are used), linearly combining the multiple channels, including assigning a weight to each channel, and then weighted summing them to obtain the second brightness feature map.
[0101] Furthermore, the second brightness feature map is processed by a ReLU (Rectified Linear Unit) activation function to introduce nonlinear characteristics, ensuring that all negative values are set to zero and positive values remain unchanged, thereby obtaining a processed second brightness feature map.
[0102] The processed second brightness feature map is then linearly combined, including changing the dimension of the feature map or adjusting the relative importance of each channel, to obtain a third brightness feature map. Then, the linearly combined third brightness feature map is processed by a Sigmoid activation function, wherein the output range of the Sigmoid function is between 0 and 1, which is used to indicate the degree of importance.
[0103] Finally, after being processed by the Sigmoid function, the importance score of each position is output, thus forming the brightness channel importance matrix.
[0104] In this embodiment, one or more convolution kernels (also called filters) are applied to perform a convolution operation with the brightness feature map to obtain a first brightness feature map, and the processed brightness feature map is linearly combined, that is, each channel is multiplied by different weights and then added to generate a second brightness feature map, and then the second brightness feature map is processed by a ReLU activation function, and each element in the second brightness feature map is activated by the ReLU activation function and linearly combined to generate a third brightness feature map, and then the third brightness feature map is processed by a Sigmoid activation function to obtain a brightness channel importance matrix, wherein the output range of the Sigmoid function is between (0,1), which helps to indicate the importance of each position, and can provide a smooth gradient, which is helpful for the subsequent optimization process.
[0105] In this embodiment, on the one hand, the feature map after global average pooling is input into a fully connected layer, and the output size of the fully connected layer is 1×1×32 / r; then, the feature map is processed by the ReLU activation function layer; then, the feature map is further input into another fully connected layer, and the output size of the layer is 1×1×32; finally, through the Sigmoid activation function layer, the brightness channel importance matrix is obtained, where r is the scaling factor, which defaults to 4; on the other hand, the input brightness (Y) channel feature map is feature extracted through two sequentially stacked convolutional layers, the convolution kernel size of each convolutional layer is 3×3, the step size is 1, and the output feature map is 32.
[0106] In this embodiment, a convolution operation is performed on the processed brightness feature map to extract local spatial features, and then the nonlinear expression ability of the model is increased by the ReLU (Rectified Linear Unit) activation function, while avoiding the gradient vanishing problem, and the output value is mapped to between 0 and 1 using the Sigmoid function, thereby obtaining a brightness channel importance matrix processed by the Sigmoid activation function to represent the relative importance of each brightness channel, thereby helping to emphasize key areas in the image.
[0107] Step S140: performing a dot product operation on the brightness channel importance matrix and the first brightness feature map to obtain a brightness denoising feature map.
[0108] In this step, a brightness denoising feature map is obtained by performing a dot product operation on the brightness channel importance matrix and the first brightness feature map, that is, the brightness channel importance matrix generated by the first branch unit is multiplied point by point with the feature map output by the second branch unit (also called dot product or Hadamard product), and then different weights are assigned to each channel in the feature map according to the importance matrix, so as to highlight important features and weaken unimportant features, effectively suppress the noise in the brightness information, and improve the overall quality of the image.
[0109] In this embodiment, by multiplying the brightness channel importance matrix and the first brightness feature map element by element (i.e., dot product), and then weighting the brightness value according to the importance of each pixel position, the area with higher importance is enhanced, while the noise part is suppressed due to its lower importance. The denoising degree is adaptively adjusted according to the specific content of different images, so that the denoising effect is more natural, avoiding the problem of over-smoothing that may occur in traditional methods, and protecting and highlighting useful image information while removing noise, thereby significantly improving the image quality under low illumination or other poor conditions.
[0110] Step S150: Calculate a plurality of chromaticity enhancement feature maps based on the processed plurality of chromaticity feature maps.
[0111] In this step, the processed chromaticity feature maps are added at the pixel level according to the corresponding positions, and the result of the addition is a new matrix, namely the correlation matrix. The obtained correlation matrix reflects the sum of information of all chromaticity feature maps at each position, and then the chromaticity feature map is enhanced by using the correlation matrix, including for each chromaticity feature map, the correlation matrix is multiplied point by point at the pixel level (Hadamard product), specifically, each chromaticity feature map is weighted according to the value in the correlation matrix. Since the area with a higher value in the correlation matrix means that the area is more important in multiple chromaticity feature maps, it will be strengthened in the enhancement process; otherwise, it will be weakened. Therefore, after the pixel multiplication operation, each chromaticity feature map will generate a new chromaticity enhancement feature map. These chromaticity enhancement feature maps retain the original color information, and by combining with the correlation matrix, the more important areas in the image are highlighted, and the expressiveness of certain specific areas is enhanced, thereby improving the image quality and enhancing the visual effect.
[0112] In this embodiment, the processed multiple chromaticity feature maps are added to form a comprehensive correlation matrix, which reflects the mutual relationship and intensity distribution between each color feature, and can capture the commonality of color information across feature maps, so as to identify which color characteristics are related and important in the whole image. Then, the correlation matrix is used to multiply each individual chromaticity feature map pixel by pixel (pixel multiplication), so that the pixel values in each chromaticity feature map are adjusted according to their relative importance and relevance in the whole image. Finally, through the pixel multiplication operation, a corresponding chromaticity enhancement feature map is generated for each input chromaticity feature map, which enhances the color features with high relevance and importance, while suppressing the less important parts, effectively highlighting the key color characteristics in the image, making the color more vivid and expressive, and helping to improve the visual effect or subsequent color feature-based analysis tasks. In the end, it can not only effectively improve the color quality and visual appeal of the image, but also well balance the relationship between color enhancement and detail retention.
[0113] In some embodiments, in step S130, multiple chromaticity enhancement feature maps are calculated based on the processed multiple chromaticity feature maps, including the following steps:
[0114] Add the processed multiple chromaticity feature maps to obtain a correlation matrix;
[0115] The correlation matrix is pixel-multiplied by the multiple chromaticity feature maps respectively to obtain multiple chromaticity enhancement feature maps corresponding to the multiple chromaticity feature maps.
[0116] In this step, the processed chromaticity feature map is added at the pixel level according to the corresponding position to obtain a correlation matrix, and then the obtained correlation matrix is used to reflect the sum of the information of all chromaticity feature maps at each position, and then the correlation matrix is multiplied point by point at the pixel level to enhance the chromaticity feature map, wherein the pixel multiplication operation is preferably a Multiply layer, specifically an operation layer in a deep learning framework, which receives two input tensors and outputs a new tensor, each element of which is the product of the elements at the same position in the corresponding input tensor.
[0117] In this embodiment, the elements at corresponding positions of the processed multiple chromaticity feature maps are added to obtain an output correlation matrix with a size of H×W×1; the spatial correlation matrix is respectively multiplied by the input chromaticity (U and V) feature maps through the Multiply layer to perform pixel multiplication operations to obtain a chromaticity enhancement feature map.
[0118] In this embodiment, the processed multiple chromaticity feature maps are summed at corresponding positions to generate a matrix representing the color correlation between different regions, which helps to capture the relationship between different colors in the image, so as to better understand the image content, and then the generated correlation matrix is multiplied pixel by pixel with the original multiple chromaticity feature maps (i.e., element-wise multiplication), so as to adjust the chromaticity value of each pixel point according to the color correlation strength at the pixel point, so that important color information is strengthened, while weaker noise or irrelevant information is suppressed. Therefore, by constructing and applying the color correlation matrix to guide the enhancement of the chromaticity feature map, not only the visual quality of the image is improved, but also a more valuable information basis is provided for further analysis and processing.
[0119] Step S160: splicing the brightness denoising feature map and multiple chroma enhancement feature maps to obtain an intermediate feature map.
[0120] In this step, the brightness denoising feature map and multiple chroma enhancement feature maps are merged according to the channel dimension, which means that when the brightness denoising feature map is a single-channel image (such as a grayscale image) and each chroma enhancement feature map is also a single-channel image, their respective information integrity will be maintained and combined into a new multidimensional data structure to obtain an intermediate feature map.
[0121] In this embodiment, by splicing the brightness denoising feature map with the chroma enhancement feature map, the brightness and color information of the image are comprehensively utilized, and the quality of the image is effectively improved by comprehensively utilizing the brightness and color information, retaining the complete visual characteristics of the image, while removing unnecessary noise interference, which helps to further improve the performance of various computer vision tasks, such as object recognition, scene understanding, etc., thereby achieving a clear and colorful effect.
[0122] Step S170: upsample the intermediate feature map to obtain a low-illumination enhanced image.
[0123] In this step, the intermediate feature map obtained by splicing the brightness denoising feature map and multiple chrominance enhancement feature maps is upsampled to obtain the final processed image, i.e., the low-light enhancement image, wherein the upsampling method includes nearest neighbor interpolation, bilinear interpolation, and transposed convolution (also called deconvolution), and the low-resolution feature map can be restored to a higher resolution through upsampling, so as to finally generate an output image that matches or is close to the input size. Therefore, the intermediate feature map is processed through the convolution layer and upsampling to generate the final low-light enhancement image, wherein the convolution layer is used to further process the upsampled feature map to ensure that the generated image has good visual quality and detail retention.
[0124] In this embodiment, by appropriately upsampling the intermediate feature map and performing subsequent convolution processing, an enhanced version that can improve the image quality under low-light conditions is obtained, and a higher resolution can be restored from a lower-resolution intermediate feature map, while maintaining image details and expanding the image size, making it more in line with actual application requirements. Moreover, by using the convolution layer for fine-tuning, key detail information in the image, such as texture, edges, etc., can be retained and highlighted, which is crucial to maintaining the realism of the image and significantly improving the quality of images taken in low-light environments, making them brighter, clearer and more detailed.
[0125] In one implementation of this embodiment, in order to improve the enhancement effect of the method, in the model training stage, the peak signal-to-noise ratio (PSNR) and the structural similarity index (SSIM) between the images before and after the enhancement, that is, the peak signal-to-noise ratio and the structural similarity index between the initial image and the low-light enhanced image, can be calculated, and the low-light enhanced image that meets the requirements can be screened out according to a predetermined quality threshold standard, thereby improving the low-light enhancement effect, wherein the peak signal-to-noise ratio (PSNR) is an indicator for measuring the quality of signal reconstruction, which is used in the fields of image processing and video coding, and the peak signal-to-noise ratio is defined based on the mean square error (MSE), reflecting the difference between the original data and the compressed or otherwise processed data; the structural similarity index (SSIM) is an indicator for measuring the similarity of two images, which aims to simulate the perception of image quality by the human visual system, and evaluates the quality of the image by comprehensively considering the three key factors of brightness, contrast and structure, which can better reflect the structural information of the image.
[0126] In one embodiment, when the calculated peak signal-to-noise ratio and structural similarity index of the enhanced image are lower than the peak signal-to-noise ratio and structural similarity index of the image before enhancement, it indicates that the current model enhancement effect still needs iterative improvement, so the system is re-trained, that is, the image enhancement is re-performed, and low-light enhanced images that meet the requirements are screened out according to a predetermined quality threshold standard, which not only improves the effect of model enhancement of low-light images, but also improves the model processing efficiency.
[0127] like Figure 2 As shown, in one implementation of the present embodiment, the original image is a low-light image, which contains images under various lighting conditions and targets to be detected (i.e., detection targets). The low-light image is contrast enhanced to obtain a processed low-light image, and then the pixel values in the processed low-light image are normalized to map the initial image.
[0128] Furthermore, feature extraction is performed on the initial image according to the color space to obtain a brightness feature map and multiple chromaticity feature maps. Pooling operations are performed on the brightness feature map and the multiple chromaticity feature maps respectively to obtain processed brightness feature maps and multiple chromaticity feature maps. Then, the brightness channel importance matrix and the first brightness feature map are extracted from the processed brightness feature map, and then the brightness channel importance matrix and the first brightness feature map are dot-producted to obtain a brightness denoising feature map, and multiple chromaticity enhancement feature maps are calculated based on the processed multiple chromaticity feature maps, thereby splicing the brightness denoising feature map and the multiple chromaticity enhancement feature maps to obtain an intermediate feature map, and then upsampling the intermediate feature map to obtain a low-light enhanced image, and finally the low-light enhanced image is detected by a preset target detection model to obtain a corresponding detection result, including the category and position information of the object in the low-light image.
[0129] In this embodiment, the low-light enhanced image is detected using a preset target detection model through non-maximum suppression and threshold screening to obtain a corresponding detection result, wherein the detection result includes the category and position information of the object in the low-light image. The preset target detection model is preferably the seventh version of the target detection model YOLO (You Only Look Once), which can quickly and accurately identify objects of multiple categories in the image and locate the position of the object.
[0130] In addition, non-maximum suppression (NMS) refers to the elimination of redundant bounding boxes for the same object that generates multiple overlapping bounding boxes in the output of the target detection model YOLO V7, and retaining the one that is most likely to be correct, that is, the low-light enhanced image is input into the target detection model YOLO V7 to obtain the model detection result, and the model detection result is processed by non-maximum suppression, thereby improving the accuracy of the detection result and avoiding multiple detections of the same object. This is achieved by comparing the confidence score of each candidate box and removing other boxes that are highly overlapped with the highest scoring box and have lower scores. In addition, threshold screening is an image processing technology that specifically filters out prediction results with confidence levels below a certain level by setting one or more thresholds to ensure that only sufficiently reliable detections are retained in the final output. Threshold screening can effectively reduce the false alarm rate and make the results more reliable.
[0131] This embodiment extracts features from an initial image according to a color space to obtain a brightness feature map and multiple chromaticity feature maps; performs pooling operations on the brightness feature map and the multiple chromaticity feature maps respectively to obtain processed brightness feature maps and multiple chromaticity feature maps; extracts a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map; performs a dot product operation on the brightness channel importance matrix and the first brightness feature map to obtain a brightness denoising feature map; calculates multiple chromaticity enhancement feature maps based on the processed multiple chromaticity feature maps; splices the brightness denoising feature map and the multiple chromaticity enhancement feature maps to obtain an intermediate feature map; and performs upsampling on the intermediate feature map to obtain a low-lighting enhanced image, which can enrich the image content and thus improve the low-lighting image quality.
[0132] like Figure 3 As shown, some embodiments of the present application provide a low-light image enhancement system, the system includes a feature extraction module 301, an image pooling module 302, an image extraction module 303, an image calculation module 304, a feature enhancement module 305, an image stitching module 306, and an image processing module 307. Specifically:
[0133] A feature extraction module 301 is used to extract features of the initial image according to the color space to obtain a brightness feature map and multiple chromaticity feature maps;
[0134] An image pooling module 302 is used to perform pooling operations on the brightness feature map and the multiple chromaticity feature maps respectively to obtain processed brightness feature maps and multiple chromaticity feature maps;
[0135] An image extraction module 303 is used to extract a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map;
[0136] An image calculation module 304 is used to perform a dot product operation on the brightness channel importance matrix and the first brightness feature map to obtain a brightness denoising feature map;
[0137] A feature enhancement module 305 is used to calculate a plurality of chromaticity enhancement feature maps according to the processed plurality of chromaticity feature maps;
[0138] An image stitching module 306, configured to stitch the brightness denoising feature map and the plurality of chroma enhancement feature maps to obtain an intermediate feature map;
[0139] The image processing module 307 is used to perform upsampling processing on the intermediate feature map to obtain a low-illumination enhanced image.
[0140] In one implementation, the feature extraction module 301 is further used to: acquire a low-light image, perform contrast enhancement on the low-light image, and obtain a processed low-light image.
[0141] In one implementation, the image pooling module 302 is further used to normalize the pixel values in the processed low-illumination image to map and obtain an initial image.
[0142] In one embodiment, the image pooling module 302 is further used to: obtain a processed brightness feature map by performing a global average pooling operation on the brightness feature map;
[0143] In one embodiment, the image pooling module 302 is further used to: perform a pooling operation on any one of the multiple chromaticity feature maps, including:
[0144] In one embodiment, the image pooling module 302 is further used to: obtain a processed U chromaticity feature map by performing a maximum pooling operation on the U chromaticity feature map of the chromaticity feature map;
[0145] In one embodiment, the image pooling module 302 is further used to: obtain a processed V chromaticity feature map by performing an average pooling operation on the V chromaticity feature map of the chromaticity feature map;
[0146] In one embodiment, the image pooling module 302 is further used to: use the processed U chromaticity feature map and the processed V chromaticity feature map as the processed chromaticity feature map.
[0147] In one embodiment, the image extraction module 303 is further used to: perform a convolution operation on the processed brightness feature map to obtain a first brightness feature map;
[0148] In one embodiment, the image extraction module 303 is further used to: linearly combine the processed brightness feature map to generate a second brightness feature map;
[0149] In one embodiment, the image extraction module 303 is further used to: process the second brightness feature map through a ReLU activation function to obtain a processed second brightness feature map;
[0150] In one embodiment, the image extraction module 303 is further used to: linearly combine the processed second brightness feature map to generate a third brightness feature map, and process the third brightness feature map through a Sigmoid activation function to obtain a brightness channel importance matrix.
[0151] In one embodiment, the feature enhancement module 305 is further used to: add the processed multiple chromaticity feature maps to obtain a correlation matrix;
[0152] In one embodiment, the feature enhancement module 305 is further used to: perform pixel multiplication of the correlation matrix with the multiple chromaticity feature maps respectively to obtain multiple chromaticity enhancement feature maps corresponding to the multiple chromaticity feature maps.
[0153] In one embodiment, the image processing module 307 is also used to: detect the low-light enhanced image by using a preset target detection model through non-maximum suppression and threshold screening, and obtain corresponding detection results, wherein the detection results include the category and location information of the object in the low-light image.
[0154] It should be noted that the low-light image enhancement system provided in this embodiment and the above-mentioned low-light image enhancement method are based on the same inventive concept, so the relevant content of the above-mentioned low-light image enhancement method is also applicable to the content of the low-light image enhancement system, and therefore, it will not be repeated here.
[0155] like Figure 4 The embodiment of the present application further provides an electronic device, the electronic device comprising:
[0156] At least one hydrogen fuel cell;
[0157] at least one memory;
[0158] at least one processor;
[0159] at least one program;
[0160] The program is stored in the memory, and the processor executes at least one program to implement the low-illumination image enhancement method described above in the present disclosure.
[0161] The electronic device may be any intelligent terminal including a mobile phone, a tablet computer, a personal digital assistant (PDA), a vehicle-mounted computer, etc.
[0162] The electronic device according to the embodiment of the present application is described in detail below.
[0163] The processor 1600 may be implemented by a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present disclosure;
[0164] The memory 1700 may be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 1700 may store an operating system and other application programs. When the technical solution provided in the embodiment of this specification is implemented by software or firmware, the relevant program code is stored in the memory 1700, and the processor 1600 calls and executes a low-light image enhancement method of the embodiment of the present disclosure.
[0165] Input / output interface 1800, used to implement information input and output;
[0166] The communication interface 1900 is used to realize the communication interaction between the device and other devices. The communication can be realized through a wired manner (such as USB, network cable, etc.) or a wireless manner (such as mobile network, WIFI, Bluetooth, etc.);
[0167] Bus 2000 , which transmits information between various components of the device (e.g., processor 1600 , memory 1700 , input / output interface 1800 , and communication interface 1900 );
[0168] The processor 1600 , the memory 1700 , the input / output interface 1800 , and the communication interface 1900 are connected to each other in communication within the device via the bus 2000 .
[0169] The embodiment of the present disclosure further provides a storage medium, which is a computer-readable storage medium. The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the above-mentioned low-illumination image enhancement method.
[0170] The memory, as a non-transient computer-readable storage medium, can be used to store non-transient software programs and non-transient computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0171] The embodiments of the present disclosure also provide a computer program product. When instructions in the computer program product are executed by a processor of an electronic device, the electronic device is used to execute the above-mentioned low-illumination image enhancement method.
[0172] The embodiments described in the embodiments of the present disclosure are intended to more clearly illustrate the technical solutions of the embodiments of the present disclosure and do not constitute a limitation on the technical solutions provided by the embodiments of the present disclosure. Those skilled in the art will appreciate that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of the present disclosure are also applicable to similar technical problems.
[0173] Those skilled in the art will appreciate that the technical solutions shown in the figures do not limit the embodiments of the present disclosure and may include more or fewer steps than shown in the figures, or a combination of certain steps, or different steps.
[0174] The device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0175] Those skilled in the art will appreciate that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices may be implemented as software, firmware, hardware, or a suitable combination thereof.
[0176] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0177] It should be understood that in the present application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.
[0178] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0179] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0180] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0181] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including multiple instructions to enable an electronic device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of each embodiment method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), disk or optical disk and other media that can store programs.
[0182] The above is a specific description of the preferred implementation of the embodiments of the present application, but the embodiments of the present application are not limited to the above-mentioned implementation methods. Technical personnel familiar with the field can also make various equivalent modifications or substitutions without violating the spirit of the embodiments of the present application. These equivalent modifications or substitutions are all included in the scope defined by the claims of the embodiments of the present application.
[0183] The embodiments of the present application are described in detail above in conjunction with the accompanying drawings, but the present application is not limited to the above embodiments. Various changes can be made within the knowledge scope of ordinary technicians in the relevant technical field without departing from the purpose of the present application.
Claims
1. A low-light image enhancement method, characterized in that: The method comprises: Extract features of the initial image according to the color space to obtain a brightness feature map and multiple chromaticity feature maps; Performing pooling operations on the brightness feature map and the multiple chromaticity feature maps respectively to obtain processed brightness feature maps and multiple chromaticity feature maps; Extracting a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map; Performing a dot product operation on the brightness channel importance matrix and the first brightness feature map to obtain a brightness denoising feature map; Calculate a plurality of chromaticity enhancement feature maps according to the processed plurality of chromaticity feature maps; Splicing the brightness denoising feature map and the multiple chroma enhancement feature maps to obtain an intermediate feature map; The intermediate feature map is upsampled to obtain a low-illumination enhanced image.
2. The low-light image enhancement method according to claim 1, characterized in that: Before extracting features from the initial image according to the color space to obtain a brightness feature map and a plurality of chromaticity feature maps, the method further includes: Acquire a low-light image, and perform contrast enhancement on the low-light image to obtain a processed low-light image; The pixel values in the processed low-illuminance image are normalized and mapped to obtain the initial image.
3. The low-light image enhancement method according to claim 2, characterized in that: The chromaticity feature map includes a U chromaticity feature map and a V chromaticity feature map, and the pooling operation on the brightness feature map includes: Performing a global average pooling operation on the brightness feature map to obtain the processed brightness feature map; Performing a pooling operation on any one of the plurality of chromaticity feature maps, comprising: Performing a maximum pooling operation on the U chromaticity feature map of the chromaticity feature map to obtain a processed U chromaticity feature map; Performing an average pooling operation on the V chromaticity feature map of the chromaticity feature map to obtain a processed V chromaticity feature map; The processed U chromaticity characteristic graph and the processed V chromaticity characteristic graph are used as processed chromaticity characteristic graphs.
4. The low-light image enhancement method according to claim 2, characterized in that: The step of extracting a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map comprises: Performing a convolution operation on the processed brightness feature map to obtain the first brightness feature map; Linearly combining the processed brightness feature maps to generate a second brightness feature map; Processing the second brightness feature map through a ReLU activation function to obtain a processed second brightness feature map; The processed second brightness feature map is linearly combined to generate a third brightness feature map, and the third brightness feature map is processed by a Sigmoid activation function to obtain the brightness channel importance matrix.
5. The low-light image enhancement method according to claim 2, characterized in that: The step of calculating a plurality of chromaticity enhancement feature maps according to the processed plurality of chromaticity feature maps comprises: Adding the processed multiple chromaticity feature maps to obtain a correlation matrix; The correlation matrix is pixel-multiplied by the multiple chromaticity feature maps respectively to obtain multiple chromaticity enhancement feature maps corresponding to the multiple chromaticity feature maps.
6. The low-light image enhancement method according to claim 5, characterized in that: After upsampling the intermediate feature map to obtain a low-light enhanced image, the method further includes: Through non-maximum suppression and threshold screening, the low-light enhanced image is detected using a preset target detection model to obtain a corresponding detection result, wherein the detection result includes the category and position information of the object in the low-light image.
7. A low-light image enhancement system, characterized in that: The system comprises: A feature extraction module is used to extract features of the initial image according to the color space to obtain a brightness feature map and multiple chromaticity feature maps; An image pooling module, used to perform pooling operations on the brightness feature map and the multiple chromaticity feature maps respectively to obtain processed brightness feature maps and multiple chromaticity feature maps; An image extraction module, used for extracting a brightness channel importance matrix and a first brightness feature map from the processed brightness feature map; An image calculation module, used for performing a dot product operation on the brightness channel importance matrix and the first brightness feature map to obtain a brightness denoising feature map; A feature enhancement module, used for calculating a plurality of chromaticity enhancement feature maps according to the processed plurality of chromaticity feature maps; An image stitching module, used for stitching the brightness denoising feature map and the multiple chroma enhancement feature maps to obtain an intermediate feature map; The image processing module is used to perform upsampling processing on the intermediate feature map to obtain a low-illumination enhanced image.
8. An electronic device, characterized in that: It includes at least one control processor and a memory for communicating with the at least one control processor; the memory stores instructions that can be executed by the at least one control processor, and the instructions are executed by the at least one control processor so that the at least one control processor can execute a low-illuminance image enhancement method as described in any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the low-illumination image enhancement method according to any one of claims 1 to 6.
10. A computer program product, characterized in that When the instructions in the computer program product are executed by a processor of an electronic device, the electronic device executes a low-illumination image enhancement method as described in any one of claims 1 to 6.