Low-illumination image enhancement method and electronic equipment

By designing a lightweight image enhancement model CNTNet, the problem of high computing overhead of low-light image enhancement models in the prior art is solved, and efficient image quality improvement on terminal devices is achieved, and it is suitable for a variety of computer vision applications.

CN119107240APending Publication Date: 2024-12-10JIANGSU COLLEGE OF INFORMATION TECH
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202411041473.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-31
Publication Date
2024-12-10

AI Technical Summary

Technical Problem

Existing low-light image enhancement models have high computational overhead when deployed on terminal devices and are not suitable for mobile devices and embedded systems.

Method used

Using lightweight image enhancement model CNTNet, forward propagation and gradient backpropagation are performed through training data sets, model parameters are optimized, and customized nonlinear transformation layer and convolutional layer are combined to reduce the calculation amount and the number of parameters, and lightweight design is designed. Image enhancement method.

Benefits of technology

It significantly reduces computing complexity and memory requirements, improves computing efficiency, can run efficiently on terminal devices, maintain image quality, and is suitable for a variety of computer vision application scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119107240A_ABST
    Figure CN119107240A_ABST
Patent Text Reader

Abstract

The invention discloses a low-illumination image enhancement method and electronic equipment. The low-illumination image enhancement method comprises the following steps: acquiring a low-illumination image; the weight and parameters of the trained lightweight image enhancement model are loaded; enhancing the low-illumination image by using the trained lightweight image enhancement model; and outputting the enhanced low-illumination image. According to the low-illumination image enhancement method provided by the embodiment of the invention, the low-illumination image is enhanced by using the trained lightweight image enhancement model, the image intensity quality can be enhanced, the calculation overhead is reduced, and the calculation efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image processing technology, and more specifically to a low-illumination image enhancement method and an electronic device. Background Art

[0002] Low-light image enhancement is a fundamental task in many computer vision applications, and models based on convolutional neural networks have made significant progress in this field. However, the models in related technologies have a large number of parameters and high computational overhead, making them unsuitable for deployment on terminal devices, especially mobile devices and embedded systems. Summary of the invention

[0003] The present invention aims to solve one of the technical problems in the related art at least to a certain extent. To this end, the purpose of the present invention is to provide a low-illumination image enhancement method and electronic device to reduce the computational overhead and improve the computational efficiency.

[0004] To achieve the above-mentioned objectives, the first aspect of the embodiment of the present invention proposes a low-light image enhancement method, which includes: acquiring a low-light image; loading the weights and parameters of a trained lightweight image enhancement model; using the trained lightweight image enhancement model to enhance the low-light image; and outputting the enhanced low-light image.

[0005] In addition, the low-light image enhancement method of the embodiment of the present invention may also have the following additional technical features:

[0006] According to one embodiment of the present invention, the lightweight image enhancement model is a CNTNet model;

[0007] The CNTNet model includes: an input layer, a first nonlinear mapping layer, a first connection layer, a second nonlinear mapping layer, a first convolution layer, a second connection layer, a third nonlinear mapping layer, a third connection layer, a fourth nonlinear mapping layer, a second convolution layer, a fourth connection layer, a fifth nonlinear mapping layer, a fifth connection layer, a sixth nonlinear mapping layer, a third convolution layer, a sixth connection layer, a seventh connection layer, a fourth convolution layer and an output layer connected in sequence; wherein the input layer, the first connection layer, the second connection layer, the third connection layer, the fourth connection layer, the fifth connection layer and the sixth connection layer are connected in sequence, and the input layer is also connected to the seventh connection layer.

[0008] According to one embodiment of the present invention, the first nonlinear mapping layer, the second nonlinear mapping layer, the third nonlinear mapping layer, the fourth nonlinear mapping layer, the fifth nonlinear mapping layer and the sixth nonlinear mapping layer all include: a custom nonlinear transformation layer, a ReLU activation function and a Dropout layer.

[0009] According to one embodiment of the present invention, the function expression of the customized nonlinear transformation layer is:

[0010] layer=scale1*log(inputs*scale2+1)+shift1+shift2*inputs

[0011] Among them, scale1 represents the first scaling parameter, scale2 represents the second scaling parameter, shift1 represents the first translation parameter, shift2 represents the second translation parameter, and inputs represents the input image data.

[0012] According to one embodiment of the present invention, the first convolution layer is a 1x1 convolution layer, the second convolution layer and the fourth convolution layer are 3x3 convolution layers, and the third convolution layer is a 5x5 convolution layer.

[0013] According to one embodiment of the present invention, the training process of the CNTNet model includes: inputting a training data set into the CNTNet model, obtaining a predicted enhanced image corresponding to the training data through forward propagation calculation; calculating a total loss function based on the predicted enhanced image and the target image; back-propagating the gradient of the total loss function to the prediction result back to each layer of the CNTNet model; using an optimizer to update relevant parameters in the CNTNet model based on the gradient obtained by back propagation; when the iteration round reaches a preset number of iterations, the training is terminated to obtain a preliminarily trained CNTNet model; the preliminarily trained CNTNet model is evaluated through a validation set, and the parameters in the CNTNet model are adjusted to obtain a trained CNTNet model.

[0014] According to one embodiment of the present invention, the total loss function is composed of at least two of the following: a gradient loss function, a structural similarity index loss function, a perceptual loss function, and a Charbonnier loss function.

[0015] According to one embodiment of the present invention, the expression of the total loss function is: total loss function=gradient loss function+5×structural similarity index loss function+perceptual loss function+Charbonnier loss function.

[0016] According to one embodiment of the present invention,

[0017] Structural Similarity Index Loss = 1-SSIM(I pred ,I true )

[0018] Perceptual loss = Σ||φl(I pred )-φl(I true )|| 2

[0019] Charbonnier loss = Σsqrt((I pred -I true ) 2 +ε 2 )

[0020] in, represents the gradient of the predicted enhanced image at position (i, j), Represents the gradient of the target image at position (i, j), I pred represents the predicted enhanced image, I true represents the target image, φ represents the pre-trained neural network, φl represents the feature map of the first layer of the network, and ε represents a preset constant.

[0021] To achieve the above objectives, a second aspect of the present invention provides an electronic device, comprising a memory, a processor and a computer program stored in the memory, wherein when the computer program is executed by the processor, the low-illumination image enhancement method described above is implemented.

[0022] According to the low-light image enhancement method and electronic device provided in the embodiments of the present application, the low-light image enhancement method can enhance the image quality by using a trained lightweight image enhancement model to enhance the low-light image, while reducing the computational overhead and improving the computational efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0024] Figure 1 is a schematic flow chart of a low-illumination image enhancement method according to an embodiment of the present invention;

[0025] Figure 2 is a schematic diagram of the structure of a CNTNet model according to an embodiment of the present invention;

[0026] Figure 3 is a schematic structural diagram of a nonlinear mapping layer according to an embodiment of the present invention;

[0027] Figure 4 is a comparative schematic diagram of low illumination image enhancement according to an embodiment of the present invention;

[0028] Figure 5 It is a schematic structural diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0029] In order to make the purpose, technical scheme and advantages of the present invention more obvious, the exemplary embodiments according to the present invention will be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments of the present invention, and it should be understood that the present invention is not limited to the exemplary embodiments described herein. Based on the embodiments of the present invention described in the present invention, all other embodiments obtained by those skilled in the art without creative work should fall within the protection scope of the present invention.

[0030] In the following description, a large number of specific details are provided to provide a more thorough understanding of the present invention. However, it is apparent to those skilled in the art that the present invention can be implemented without one or more of these details. In other examples, in order to avoid confusion with the present invention, some technical features well known in the art are not described.

[0031] It should be understood that the present invention can be implemented in different forms and should not be interpreted as limited to the embodiments set forth herein. On the contrary, these embodiments are provided to make the disclosure thorough and complete and to fully convey the scope of the present invention to those skilled in the art.

[0032] In order to fully understand the present invention, a detailed structure will be proposed in the following description to illustrate the technical solution proposed by the present invention. The optional embodiments of the present invention are described in detail as follows, but in addition to these detailed descriptions, the present invention may also have other implementations.

[0033] Some embodiments of the present invention are described in detail below in conjunction with the accompanying drawings. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.

[0034] Please refer to the following Figure 1 -Attached Figure 5 A low-illumination image enhancement method and an electronic device according to an embodiment of the present invention are described.

[0035] Figure 1 It is a flowchart of a low-illumination image enhancement method according to an embodiment of the present invention.

[0036] like Figure 1 As shown, the low illumination image enhancement method includes:

[0037] S1, collect low-light images.

[0038] It should be noted that the low-light image may refer to an image with low brightness, poor contrast, and blurred details due to insufficient light in the shooting environment, insufficient camera exposure time, or improper camera sensitivity setting. The low-light image may be a 3-channel color image.

[0039] S2, loads the weights and parameters of the trained lightweight image enhancement model.

[0040] As an example, a pre-trained lightweight image enhancement model can be loaded using a deep learning framework (such as TensorFlow, PyTorch, etc.).

[0041] S3, uses the trained lightweight image enhancement model to enhance low-light images.

[0042] As an example, the captured low-light image is input into the loaded lightweight image enhancement model; the lightweight image enhancement model automatically performs a series of complex nonlinear transformations and feature extraction operations on the image; and finally outputs an enhanced image, which is significantly improved in brightness and contrast.

[0043] S4 outputs the enhanced low-light image.

[0044] The low-light image enhancement method of the embodiment of the present invention can enhance the image quality by using a trained lightweight image enhancement model to enhance the low-light image, while reducing the computational overhead and improving the computational efficiency.

[0045] In some embodiments of the present invention, Figure 2 As shown, the lightweight image enhancement model is a CNTNet (NonlinearTransform Net, nonlinear transformation network) model;

[0046] The CNTNet model includes: an input layer, a first nonlinear mapping layer, a first connection layer, a second nonlinear mapping layer, a first convolutional layer, a second connection layer, a third nonlinear mapping layer, a third connection layer, a fourth nonlinear mapping layer, a second convolutional layer, a fourth connection layer, a fifth nonlinear mapping layer, a fifth connection layer, a sixth nonlinear mapping layer, a third convolutional layer, a sixth connection layer, a seventh connection layer, a fourth convolutional layer and an output layer connected in sequence; wherein the input layer, the first connection layer, the second connection layer, the third connection layer, the fourth connection layer, the fifth connection layer and the sixth connection layer are connected in sequence, and the input layer is also connected to the seventh connection layer.

[0047] It should be noted that each nonlinear mapping layer can apply nonlinear activation functions (such as ReLU, PReLU, etc.) to process the input low-light image, which can increase the nonlinear ability of the CNTNet model. Each connection layer can connect or add the output of the input layer or the previous layer to the output of the current layer, which can alleviate the gradient vanishing problem in the deep network and promote the flow of information.

[0048] In this embodiment, the CNTNet model can enhance image quality while reducing computational overhead to achieve the lightweight goal.

[0049] In some embodiments of the present invention, Figure 3 As shown, the first nonlinear mapping layer, the second nonlinear mapping layer, the third nonlinear mapping layer, the fourth nonlinear mapping layer, the fifth nonlinear mapping layer and the sixth nonlinear mapping layer all include: a custom nonlinear transformation layer, a ReLU activation function and a Dropout layer.

[0050] It should be noted that the nonlinear mapping layer is a key component in the CNTNet model, which is responsible for performing multi-scale nonlinear transformation on the input image to enhance image quality and extract features.

[0051] Specifically, the function expression of the custom nonlinear transformation layer is:

[0052] layer=scale1*log(inputs*scale2+1)+shift1+shift2*inputs

[0053] Among them, scale1 represents the first scaling parameter, scale2 represents the second scaling parameter, shift1 represents the first translation parameter, shift2 represents the second translation parameter, and inputs represents the input image data.

[0054] It should be noted that the first scaling parameter and the second scaling parameter are initialized to 1 and are trainable; the first translation parameter and the second translation parameter are initialized to 0 and are trainable.

[0055] In some embodiments of the present invention, the first convolution layer is a 1x1 convolution layer, the second convolution layer and the fourth convolution layer are 3x3 convolution layers, and the third convolution layer is a 5x5 convolution layer.

[0056] It should be noted that in the CNTNet model, a 1x1 convolutional layer is first used to reduce the number of channels of the input image and perform feature fusion, and then 3x3 and 5x5 convolutional layers are used to extract image features of different scales. By inserting nonlinear mapping layers and connection layers between these convolutional layers, the CNTNet model is able to learn complex image enhancement mappings and output a final image with significantly improved brightness and contrast.

[0057] In this embodiment, each convolution layer uses a smaller convolution kernel, which can reduce the amount of calculation and the number of parameters while maintaining a good feature extraction capability.

[0058] As an example, the setup of the CNTNet model includes:

[0059] Input layer: accepts input of specified shape (None,None,3).

[0060] Custom layers and activation layers:

[0061] First layer: Apply a nonlinear transformation layer (num_ranges=6), then perform ReLU activation and 0.3 Dropout, and finally concatenate the output of the input layer and the Dropout layer.

[0062] Second layer: Apply a nonlinear transformation layer (num_ranges=2), then perform a ReLU activation and a Dropout of 0.3, then perform a 1x1 convolution, and finally concatenate the output of the previous connection layer with the current Dropout layer.

[0063] Third layer: Apply a nonlinear transformation layer (num_ranges=1), then perform ReLU activation and 0.3 Dropout, and finally connect the output of the previous connection layer with the current Dropout layer.

[0064] Fourth layer: Apply a nonlinear transformation layer (num_ranges=1), followed by ReLU activation and 0.3 Dropout, and then a 3x3 convolution.

[0065] Fifth layer: Apply a nonlinear transformation layer (num_ranges=1), followed by ReLU activation and 0.3 Dropout, and finally concatenate the output of the previous connection layer with the current Dropout layer.

[0066] Layer 6: Apply a nonlinear transformation layer (num_ranges=1), then perform ReLU activation and 0.3 Dropout, then perform a 5x5 convolution, and finally connect the output of the previous connection layer with the current Dropout layer.

[0067] Output layer: The input layer and the output of the sixth Dropout layer are concatenated and finally passed through a 3x3 convolutional layer (with Sigmoid activation) to get the output.

[0068] like Figure 4 As shown, the brightness, contrast and details of the image processed by the low-illumination image enhancement method of the present application are highly enhanced.

[0069] In summary, the CNTNet model of this application significantly reduces computational complexity and memory requirements through optimized architecture and streamlined parameter settings, enabling it to run efficiently on various terminal devices, including mobile devices and embedded systems. Excellent image quality enhancement capabilities: The CNTNet model uses a customized nonlinear transformation layer combined with a convolutional neural network to effectively improve the brightness, contrast, and details of images under low-light conditions, thereby significantly improving visual perception and analysis capabilities. Experimental results show that the CNTNet model significantly reduces the number of parameters while maintaining image quality evaluation indicators comparable to models in related technologies. This not only improves overall performance, but also reduces costs and energy consumption. It has the potential for application in multiple fields: The design and performance of the CNTNet model make it suitable for a variety of computer vision application scenarios, including security monitoring, autonomous driving, medical image analysis, etc., providing efficient and reliable image enhancement solutions for these fields.

[0070] In some embodiments of the present invention, the training process of the CNTNet model includes:

[0071] S21, input the training data set into the CNTNet model, and obtain the predicted enhanced image corresponding to the training data through forward propagation calculation.

[0072] S22, calculating a total loss function according to the predicted enhanced image and the target image.

[0073] S23, back-propagates the gradient of the total loss function to the prediction result back to each layer of the CNTNet model.

[0074] S24, based on the gradient obtained by back propagation, use the optimizer to update the relevant parameters in the CNTNet model.

[0075] As an example, the optimizer may be an Adam optimizer.

[0076] It should be noted that the learning rate and momentum parameters of the Adam optimizer are set to adjust the model parameters to minimize the loss function. Learning rate: Usually initially set to a small value, such as 0.001 or less. The choice of learning rate may need to be tuned to ensure that the model can converge effectively without skipping the optimal solution. β1 is usually set to the default value of 0.9, which is the exponential decay rate of the first-order moment estimate (i.e., the first-order moment of the gradient) calculated in the Adam optimizer. β2 is usually set to the default value of 0.999, which is the exponential decay rate of the second-order moment estimate (i.e., the second-order moment of the gradient) calculated in the Adam optimizer.

[0077] S25, when the iteration round reaches the preset number of iterations, the training is terminated to obtain the initially trained CNTNet model.

[0078] As an example, the preset number of iterations can be 200, and the batch size can be determined according to the performance of the running carrier of the CNTNet model.

[0079] S26, evaluate the initially trained CNTNet model through the validation set, adjust the parameters in the CNTNet model, and obtain the trained CNTNet model.

[0080] In some embodiments of the present invention, the total loss function is composed of at least two of the following:

[0081] Gradient loss function, Structural Similarity Index Measure (SSIM) loss function, perceptual loss function, Charbonnier loss function.

[0082] It is worth mentioning that the gradient loss is used to preserve the edge information of the image, which is defined as the difference between the gradient of the predicted image and the real image. The SSIM loss is used to measure the structural similarity between the predicted image and the real image. The perceptual loss is used to preserve the high-level features of the image.

[0083] In some embodiments of the present invention, the expression of the total loss function is:

[0084] Total loss function = gradient loss function + 5 × structural similarity index loss function + perceptual loss function + Charbonnier loss function.

[0085] Specifically,

[0086] Structural Similarity Index Loss = 1-SSIM(I pred ,I true )

[0087] Perceptual loss = Σ||φl(I pred )-φl(I true )|| 2

[0088] Charbonnier loss = Σsqrt((I pred -I true ) 2 +ε 2 )

[0089] in, represents the gradient of the predicted enhanced image at position (i, j), Represents the gradient of the target image at position (i, j), I pred represents the predicted enhanced image, I truerepresents the target image, φ represents the pre-trained neural network, φl represents the feature map of the first layer of the network, and ε represents a preset constant.

[0090] It should be noted that It can be obtained by finding the gradient of the image in the horizontal and vertical directions:

[0091]

[0092] For example, SSIM(x,y)=((2μ x μ y +C1)(2σ xy +C2)) / ((μ x 2 +μ y 2 +C1)(σ x 2 +σ y 2 +C2))

[0093] Among them, μ x and μ y Represents the average value of image x and y, σ x 2 and σ y 2 Represents the variance of images x and y, σ xy represents the covariance between images x and y, and C1 and C2 represent stability constants used to prevent the denominator from being zero.

[0094] It is worth mentioning that ε is a small constant used to improve numerical stability.

[0095] Corresponding to the above embodiment, the present invention further provides an electronic device.

[0096] Figure 5 It is a schematic structural diagram of an electronic device according to an embodiment of the present invention.

[0097] like Figure 5 As shown, the electronic device 500 includes: a processor 501 and a memory 503. The processor 501 and the memory 503 are connected, such as through a bus 502. Optionally, the electronic device 500 may also include a transceiver 504. It should be noted that in actual applications, the transceiver 504 is not limited to one, and the structure of the electronic device 500 does not constitute a limitation on the embodiments of the present invention.

[0098] Processor 501 may be a CPU (Central Processing Unit), a general purpose processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array) or other programmable logic devices, transistor logic devices, hardware components or any combination thereof. It may implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of the present invention. Processor 501 may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.

[0099] The bus 502 may include a path to transmit information between the above components. The bus 502 may be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus. The bus 502 may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 5 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0100] The memory 503 is used to store a computer program corresponding to the low-light image enhancement method of the above embodiment of the present invention, and the computer program is controlled and executed by the processor 501. The processor 501 is used to execute the computer program stored in the memory 503 to implement the content shown in the above embodiment of the low-light image enhancement method.

[0101] The electronic device 500 includes, but is not limited to, mobile terminals such as laptop computers, PADs (tablet computers), and fixed terminals such as desktop computers. Figure 5 The electronic device 500 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.

[0102] The electronic device 500 of the embodiment of the present invention can cultivate good driving habits of the driver in real time and dynamically during driving, improve driving safety and efficiency, and reduce the cost of guiding the driver to a certain place. It can also improve the efficiency of road use.

[0103] Although example embodiments have been described herein with reference to the accompanying drawings, it should be understood that the above example embodiments are merely exemplary and are not intended to limit the scope of the present application to this. Those of ordinary skill in the art may make various changes and modifications therein without departing from the scope and spirit of the present application. All these changes and modifications are intended to be included within the scope of the present application as required by the appended claims.

[0104] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0105] In the several embodiments provided in this 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 the units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed.

[0106] In the description provided herein, a large number of specific details are described. However, it is understood that the embodiments of the present application can be practiced without these specific details. In some instances, well-known methods, structures and techniques are not shown in detail so as not to obscure the understanding of this description.

[0107] Similarly, it should be understood that in order to streamline the present application and help understand one or more of the various inventive aspects, in the description of the exemplary embodiments of the present application, the various features of the present application are sometimes grouped together into a single embodiment, figure, or description thereof. However, the method of the present application should not be interpreted as reflecting the following intention: the claimed application requires more features than the features clearly stated in each claim. More specifically, as reflected in the corresponding claims, the inventive point is that the corresponding technical problem can be solved with features less than all the features of a single disclosed embodiment. Therefore, the claims following the specific embodiment are hereby explicitly incorporated into the specific embodiment, wherein each claim itself serves as a separate embodiment of the present application.

[0108] It will be understood by those skilled in the art that, except for mutually exclusive features, all features disclosed in this specification (including the accompanying claims, abstracts and drawings) and all processes or units of any method or device disclosed in this specification may be combined in any combination. Unless otherwise expressly stated, each feature disclosed in this specification (including the accompanying claims, abstracts and drawings) may be replaced by an alternative feature that provides the same, equivalent or similar purpose.

[0109] In addition, those skilled in the art will appreciate that, although some embodiments described herein include certain features included in other embodiments but not other features, the combination of features of different embodiments is meant to be within the scope of the present application and form different embodiments. For example, in the claims, any one of the claimed embodiments may be used in any combination.

[0110] The various component embodiments of the present application can be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. It should be understood by those skilled in the art that a microprocessor or digital signal processor (DSP) can be used in practice to implement some or all functions of some modules according to the embodiments of the present application. The application can also be implemented as a device program (e.g., computer program and computer program product) for executing a part or all of the methods described herein. Such a program implementing the present application can be stored on a computer-readable medium, or can have the form of one or more signals. Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.

[0111] It should be noted that the above embodiments illustrate the present application rather than limit the present application, and that those skilled in the art may design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference symbol between brackets should not be constructed as a limitation to the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "one" or "an" preceding an element does not exclude the presence of multiple such elements. The present application may be implemented by means of hardware including several different elements and by means of a suitably programmed computer. In a unit claim that lists several devices, several of these devices may be embodied by the same hardware item. The use of the words first, second, and third, etc. does not indicate any order. These words may be interpreted as names.

[0112] The above is only a specific implementation or description of a specific implementation of the present application, and the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. The protection scope of the present application shall be based on the protection scope of the claims.

Claims

1. A low illumination image enhancement method, It is characterized in that The method comprises: Capture low-light images; Load the weights and parameters of the trained lightweight image enhancement model; Enhance the low-light image using a trained lightweight image enhancement model; Outputs an enhanced low-light image.

2. The low-light image enhancement method according to claim 1, It is characterized in that The lightweight image enhancement model is a CNTNet model; The CNTNet model includes: an input layer, a first nonlinear mapping layer, a first connection layer, a second nonlinear mapping layer, a first convolutional layer, a second connection layer, a third nonlinear mapping layer, a third connection layer, a fourth nonlinear mapping layer, a second convolutional layer, a fourth connection layer, a fifth nonlinear mapping layer, a fifth connection layer, a sixth nonlinear mapping layer, a third convolutional layer, a sixth connection layer, a seventh connection layer, a fourth convolutional layer and an output layer connected in sequence; The input layer, the first connection layer, the second connection layer, the third connection layer, the fourth connection layer, the fifth connection layer and the sixth connection layer are connected in sequence, and the input layer is also connected to the seventh connection layer.

3. The low-light image enhancement method according to claim 2, It is characterized in that The first nonlinear mapping layer, the second nonlinear mapping layer, the third nonlinear mapping layer, the fourth nonlinear mapping layer, the fifth nonlinear mapping layer and the sixth nonlinear mapping layer all include: a custom nonlinear transformation layer, a ReLU activation function and a Dropout layer.

4. The low-light image enhancement method according to claim 3, It is characterized in that The function expression of the custom nonlinear transformation layer is: layer=scale1*log(inputs*scale2+1)+shift1+shift2*inputs Among them, scale1 represents the first scaling parameter, scale2 represents the second scaling parameter, shift1 represents the first translation parameter, shift2 represents the second translation parameter, and inputs represents the input image data.

5. The low-light image enhancement method according to claim 2, It is characterized in that The first convolution layer is a 1x1 convolution layer, the second convolution layer and the fourth convolution layer are 3x3 convolution layers, and the third convolution layer is a 5x5 convolution layer.

6. The low-light image enhancement method according to claim 2, It is characterized in that The training process of the CNTNet model includes: Input the training data set into the CNTNet model, and obtain the predicted enhanced image corresponding to the training data through forward propagation calculation; Calculating a total loss function based on the predicted enhanced image and the target image; Back-propagating the gradient of the total loss function to the prediction result back to each layer of the CNTNet model; According to the gradient obtained by back propagation, use the optimizer to update the relevant parameters in the CNTNet model; When the number of iterations reaches the preset number, the training ends and the initially trained CNTNet model is obtained; The initially trained CNTNet model is evaluated through a validation set, and parameters in the CNTNet model are adjusted to obtain a trained CNTNet model.

7. The low-light image enhancement method according to claim 6, It is characterized in that The total loss function consists of at least two of the following: Gradient loss function, structural similarity index loss function, perceptual loss function, Charbonnier loss function.

8. The low-light image enhancement method according to claim 7, It is characterized in that The expression of the total loss function is: Total loss function = gradient loss function + 5 × structural similarity index loss function + perceptual loss function + Charbonnier loss function.

9. The low-light image enhancement method according to claim 2, Features: Structural Similarity Index Loss = 1-SSIM(I pred ,I true ) Perceptual loss = Σ||φl(I pred )-φl(I true )|| 2 Charbonnier loss = Σsqrt((I pred -I true ) 2 +ε 2 ) in, represents the gradient of the predicted enhanced image at position (i, j), Represents the gradient of the target image at position (i, j), I pred represents the predicted enhanced image, I true represents the target image, φ represents the pre-trained neural network, φl represents the feature map of the first layer of the network, and ε represents a preset constant.

10. An electronic device, It is characterized in that The invention comprises a memory, a processor and a computer program stored in the memory, wherein when the computer program is executed by the processor, the low-illumination image enhancement method according to any one of claims 1 to 9 is implemented.

Citation Information

Patent Citations

  • Image processing method and medical imaging device

    CN107563983A

  • Low-illumination image enhancement method based on double-branch network combined with dense wavelets

    CN116029916A

  • Low-illumination image enhancement method and device, computer equipment and storage medium

    CN118154450A

  • Lightweight low-illumination image enhancement method based on convolutional neural network

    CN118351041A

  • Low-illumination image enhancement method and system based on customized expansion enhancer

    CN118365548A