Convolutional neural network image denoising algorithm

By using a convolutional neural network image denoising algorithm based on the CBAM attention mechanism and multi-scale features, the problem of detail loss caused by image denoising in existing technologies is solved, and high-quality image acquisition is achieved.

CN119027336APending Publication Date: 2024-11-26CHANGCHUN INST OF OPTICS FINE MECHANICS & PHYSICS CHINESE ACAD OF SCI
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202310583501.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-05-23
Publication Date
2024-11-26

AI Technical Summary

Technical Problem

Existing image denoising algorithms can lead to the loss of image detail information and affect image quality during the removal of Gaussian noise.

Method used

A convolutional neural network image denoising algorithm based on CBAM attention mechanism and multi-scale feature extraction is adopted. A deep convolutional neural network model combining multi-scale and attention mechanism is constructed and trained using MSE mean square loss function and Adam optimizer. Data augmentation techniques are combined to generate training dataset.

Benefits of technology

It effectively removes Gaussian noise while preserving image details and improving image quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119027336A_ABST
    Figure CN119027336A_ABST
Patent Text Reader

Abstract

The invention relates to a convolutional neural network image denoising algorithm, which is a convolutional neural network image denoising algorithm based on a CBAM attention mechanism and multi-scale feature extraction, and comprises the following steps: step 1, establishing a data set; 2, building a multi-scale and attention mechanism combined convolutional neural network model; 3, constructing a proper loss function, an optimizer and a learning rate, and carrying out training; and 4, inputting a noise image in a test set into the trained model, and carrying out denoising. According to the convolutional neural network image denoising algorithm based on the CBAM attention mechanism and the multi-scale feature extraction, the attention mechanism is utilized, the algorithm pays more attention to the noise of the image, the multi-scale module can extract more detailed image information, the noise is effectively removed, and the detail information of the image is reserved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of image denoising, and in particular to a convolutional neural network image denoising algorithm based on a CBAM attention mechanism and multi-scale feature extraction. Background Art

[0002] Gaussian noise is a noise whose probability density function follows Gaussian distribution. Gaussian noise is mainly caused by changes in current and voltage in the device circuit or system or poor lighting during image acquisition. Due to the presence of Gaussian noise, the image is blurred and unclear, affecting the image quality. The presence of noise not only affects the quality of the image, but also affects the effect of the image in practical applications. Therefore, removing Gaussian noise from the image and improving the image quality play an important role in practical applications. However, although the existing denoising algorithm can remove noise, it will also lose the detailed information of the image to a certain extent, affecting the quality of the image. Therefore, in order to obtain high-quality images, a convolutional neural network image denoising algorithm based on the CBAM attention mechanism and multi-scale feature extraction is invented. Summary of the invention

[0003] The present invention aims to solve the technical problems in the prior art, obtain high-quality images, effectively remove Gaussian noise and maintain the integrity of the image, and provide a convolutional neural network image denoising algorithm based on CBAM attention mechanism and multi-scale extraction features.

[0004] In order to solve the above technical problems, the technical solutions of the present invention are as follows:

[0005] A convolutional neural network image denoising algorithm is a convolutional neural network image denoising algorithm based on CBAM attention mechanism and multi-scale feature extraction, comprising the following steps:

[0006] Step 1: Create a data set;

[0007] Step 2: Build a convolutional neural network model that combines multi-scale and attention mechanisms;

[0008] Step 3: Construct a suitable loss function, optimizer, and learning rate for training;

[0009] Step 4: Input the noisy images in the test set into the trained model for denoising.

[0010] In the above technical solution, step one is specifically: expanding the data set by using data enhancement methods, and adding different levels of Gaussian noise to the data set to establish the training data set required by the algorithm.

[0011] In the above technical solution, step two is specifically: building a deep convolutional neural network image denoising model, which includes: multi-layer convolutional layers, batch normalization layers, Relu activation functions, multi-scale feature extraction modules and attention mechanisms.

[0012] In the above technical solution, step three is specifically as follows: training the constructed deep convolutional neural network image denoising model, selecting the MSE mean square loss function and the Adam optimizer, and setting the automatically adjusted learning rate, and putting the noisy image obtained in step one into the network model for training.

[0013] In the above technical solution, in step three, the initial rate of the automatically adjusted learning rate is set to 0.001.

[0014] In the above technical solution, step four is specifically: select a part of clean images as a test set, add different levels of noise to the test set, and then put it into the trained model to obtain clean images.

[0015] The present invention has the following beneficial effects:

[0016] The convolutional neural network image denoising algorithm based on the CBAM attention mechanism and multi-scale extraction features of the present invention utilizes the attention mechanism to focus the algorithm more on the noise of the image, and the multi-scale module can also extract more detailed image information, effectively remove noise and retain the detailed information of the image.

[0017] The convolutional neural network image denoising algorithm based on the CBAM attention mechanism and multi-scale extraction features of the present invention combines a multi-scale module (Res2net). Compared with the fixed-scale extraction method, the present model can extract more detailed noise information and complete information of the image from noisy pictures. The CBAM attention mechanism includes a channel attention module (Channel Attention Module) and a spatial attention (Spartial Attention Module). These two modules allow the CBAM attention mechanism to focus the model on the extraction of noise from the two dimensions of channel and space, thereby ensuring that the algorithm can effectively remove noise without losing the detailed information of the picture. The present invention is of great significance for removing noise and obtaining high-quality pictures. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] The present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments.

[0019] Figure 1 It is a step flow chart of the convolutional neural network image denoising algorithm based on the CBAM attention mechanism and multi-scale feature extraction of the present invention.

[0020] Figure 2 It is a schematic diagram of the network structure of the convolutional neural network image denoising algorithm based on the CBAM attention mechanism and multi-scale feature extraction of the present invention.

[0021] Figure 3 It is a schematic diagram of the multi-scale feature extraction module.

[0022] Figure 4 It is a schematic diagram of the CBAM attention mechanism.

[0023] Figure 5 is an image with Gaussian noise.

[0024] Figure 6 It is a clean image obtained after an image containing Gaussian noise is processed by the algorithm of the present invention. DETAILED DESCRIPTION

[0025] The present invention is described in detail below with reference to the accompanying drawings.

[0026] The Chinese meanings, functions or significances of the English abbreviations involved in the present invention are as follows:

[0027] Adam: is an algorithm that calculates an adaptive learning rate for each parameter or weight, which iteratively updates the neural network weights based on the training data.

[0028] MSE: It is a loss function commonly used in the field of deep learning. It is the square of the difference between the true value and the predicted value and then sums and averages them.

[0029] CBAM: is an attention mechanism module that combines channel attention and spatial attention.

[0030] Relu: Linear rectification function, a commonly used activation function in deep learning.

[0031] Conv: Convolutional layer, the core module of building convolutional neural network, used to extract the features of input data.

[0032] BN: Batch Normalization layer, which normalizes the output signal through standardization operations to ensure the stability of the network and accelerate the convergence of the network.

[0033] Train400: is a dataset commonly used for training networks in the field of image denoising, which contains 400 images of various types.

[0034] BSD68: A commonly used test set in the field of image denoising, containing 68 images.

[0035] Set12: A commonly used test set in the field of image denoising, containing 12 images.

[0036] AdaGrad: is a gradient descent optimization method with adaptive learning rate. It records the direction and distance of each iteration, so that there is a set of methods to adaptively adjust the learning rate for different problems.

[0037] RMSProp: is a gradient descent optimization method with adaptive learning rate, which improves the AdaGrad algorithm.

[0038] Epoch: A unit. An epoch means that all data is sent into the network and a forward calculation + back propagation process is completed.

[0039] gamma: The adjustment multiple of the learning rate, which means multiplying the original learning rate by gamma each time.

[0040] The convolutional neural network image denoising algorithm of the present invention is a convolutional neural network image denoising algorithm based on the CBAM attention mechanism and multi-scale feature extraction, such as Figure 1 As shown, it includes four steps:

[0041] Step 1: Create a data set;

[0042] Step 2: Build a convolutional neural network model that combines multi-scale and attention mechanisms;

[0043] Step 3: Construct a suitable loss function, optimizer, and learning rate, and train the data set in step 1;

[0044] Step 4: Input the noisy image in the test set into the trained model to denoise and obtain a clean image.

[0045] The specific process of the present invention is as follows:

[0046] Step 1: Expand the dataset through data enhancement methods and add different levels of Gaussian noise to the dataset to establish a training dataset of pairs of noisy images and clean images required by the algorithm.

[0047] The dataset used in this step is Train400, which contains 400 clear grayscale images with rich content, including various types of animals, landscapes, faces, etc. By cropping, scaling, and flipping the dataset, the 400 180×180 grayscale images are expanded to 238,400 40×40 grayscale images. Due to the lack of real noise images and the fact that additive Gaussian white noise is the closest to real noise, additive Gaussian white noise is added to the dataset. Additive Gaussian white noise means that the probability density function of noise follows Gaussian distribution. The probability density function of Gaussian noise can be expressed as:

[0048]

[0049] Where x represents the grayscale value of the image, μ is the mean or expected value of x, σ is the standard deviation of x, and σ 2 is the variance of x.

[0050] Step 2: Build a deep convolutional neural network image denoising model that combines multi-scale and attention mechanism. The model includes multiple convolutional layers, batch normalization layers (BN), Relu activation functions, multi-scale feature extraction modules and attention mechanisms.

[0051] The overall structure of the model is as follows Figure 2 As shown in the figure, the entire network structure consists of 16 convolutional layers, a multi-scale feature extraction module and a CBAM attention mechanism. The multi-scale feature extraction module consists of an improved Res2net multi-scale module. The first layer of this model consists of Conv+BN (convolutional layer + batch normalization layer), and the second layer is Conv+BN+Relu (convolutional layer + batch normalization layer + activation function). Relu is used as an activation function to effectively play the role of the network and avoid gradient explosion. The following is a multi-scale feature extraction module, which consists of four Res2net modules (such as Figure 3 ), followed by 11 layers of Conv+BN+Relu (convolution layer+batch normalization layer+activation function), and then connected to the CBAM attention mechanism to help the algorithm extract image noise from two dimensions, channel and space. The last layer is Conv (convolution layer). In the present invention, the multi-scale feature extraction module is composed of improved Res2net modules connected in series, and the first and last layers of the Res2net module are changed to 3×3 convolution layers. Figure 4 It is a schematic diagram of the attention mechanism of CBAM, which includes the channel attention module (Channel Attention Module) and the spatial attention (Spartial Attention Module).

[0052] Step 3: Train the constructed deep convolutional neural network denoising model, select the MSE mean square loss function and Adam optimizer, set the automatically adjusted learning rate, and set the initial rate to 0.001. Put the noisy image obtained in step 1 into the network model for training;

[0053] The MSE loss function is used to describe the gap between the true value and the predicted value. The smaller the loss function, the better the performance of the algorithm. The expression of the MSE loss function is as follows:

[0054]

[0055] Where N is the number of images in the training set, x iis the image obtained by training the neural network with the noise image, y i is the clean image corresponding to the noisy image. The Adam optimizer combines the advantages of the two optimization algorithms, AdaGrad and RMSProp. The first-order moment estimation and the second-order moment estimation of the gradient are comprehensively considered to calculate the update step size. The Adam optimizer is simple to implement and occupies little memory. It is very suitable for models with large-scale data and parameters. The initial learning rate of this algorithm is set to 0.001, gamma is set to 0.2, and it is iterated every 30 epochs.

[0056] Step 4: Select a part of clean images as the test set. First, add different levels of noise to the test set, and then put it into the trained model to obtain clean images.

[0057] BSD68 and Set12 are selected as test sets. First, corresponding additive Gaussian white noise is added to the pictures in the test sets, and then they are sequentially put into the trained model of the present invention to obtain clean images. Figure 5 It is a noisy image, mainly obvious Gaussian noise. Figure 6 It is a clean image after the image containing Gaussian noise is processed by the algorithm of the present invention. After the Gaussian noise is processed by the trained model of the present invention, there is almost no noise, and the image details are very clear. Figure 5 and Figure 6 It can be seen from the comparison that the algorithm is very effective in removing additive Gaussian white noise and can retain the complete information of the image.

[0058] The present invention utilizes a multi-scale model to extract finer detail features. The algorithm can retain image details while removing Gaussian noise. Combined with the characteristics of the CBAM attention mechanism, the algorithm can remove noise more effectively. The present invention can effectively remove noise without losing image details, which plays an important role in improving image quality and the image in subsequent applications.

[0059] Obviously, the above embodiments are merely examples for the purpose of clear explanation, and are not intended to limit the implementation methods. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the implementation methods here. The obvious changes or modifications derived therefrom are still within the scope of protection of the invention.

Claims

1. A convolutional neural network image denoising algorithm, characterized in that: It is a convolutional neural network image denoising algorithm based on the CBAM attention mechanism and multi-scale feature extraction, which includes the following steps: Step 1: Create a data set; Step 2: Build a convolutional neural network model that combines multi-scale and attention mechanisms; Step 3: Construct a suitable loss function, optimizer, and learning rate for training; Step 4: Input the noisy images in the test set into the trained model for denoising.

2. The convolutional neural network image denoising algorithm according to claim 1, characterized in that: Step one is as follows: expand the data set through data enhancement methods, add different levels of Gaussian noise to the data set, and establish the training data set required by the algorithm.

3. The convolutional neural network image denoising algorithm according to claim 1, characterized in that: Step 2 is specifically: building a deep convolutional neural network image denoising model, which includes: multi-layer convolutional layers, batch normalization layers, Relu activation functions, multi-scale feature extraction modules and attention mechanisms.

4. The convolutional neural network image denoising algorithm according to claim 3, characterized in that: Step three is as follows: train the constructed deep convolutional neural network image denoising model, select the MSE mean square loss function and Adam optimizer, set the automatically adjusted learning rate, and put the noisy image obtained in step one into the network model for training.

5. The convolutional neural network image denoising algorithm according to claim 4, characterized in that: In step 3, the initial rate of the automatically adjusted learning rate is set to 0.

001.

6. The convolutional neural network image denoising algorithm according to claim 1, characterized in that: Step 4 is as follows: select a part of clean images as the test set, add different levels of noise to the test set, and then put it into the trained model to obtain clean images.

Citation Information

Patent Citations

  • Deep learning image denoising method integrating multiple scales and attention mechanism

    CN111292259A

  • Image denoising method based on attention and dense connection residual block convolution kernel neural network

    CN113610719A

  • Synthetic radar image denoising method based on deep learning

    CN115689958A