Image denoising method, device and electronic device, image super-resolution denoising method
By training the noise generation and discrimination network on the asymmetric training set, the simulated noise is generated for training the image denoising network, which solves the problem of poor performance of existing super-resolution algorithms on different data sets and achieves efficient image super-resolution. Rate conversion and artifact reduction.
Patent Information
- Application Number
- CN202010729938.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-27
- Publication Date
- 2024-08-23
- Estimated Expiration
- 2040-07-27
AI Technical Summary
Existing super-resolution algorithms perform poorly on low-resolution images that are different from the distribution of the training data set, are prone to artifacts, and are difficult to effectively improve image super-resolution.
By training the asymmetric training set, noise-free and real noise images are obtained, and the noise generation network and the discrimination network are alternately and iteratively trained to generate simulated noise, which is used to train the image denoising network, thereby converting low-resolution images into high-resolution images. rate image.
The image super-resolution effect is improved, the artifact problem is reduced, and the noisy original image is converted into a noise-free new image through the image denoising network, which improves the image clarity.
Smart Images

Figure CN111861930B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image processing technology, and in particular to an image denoising method, a device and an electronic device, and an image super-resolution denoising method. Background Art
[0002] Image super-resolution refers to restoring a high-resolution image from a low-resolution image or image sequence. High-resolution images have high pixel density and can provide more details, which often play a key role in practical applications. The most direct way to obtain high-resolution images is to use high-resolution image sensors, but due to the limitations of sensor and optical device manufacturing processes and costs, this method is difficult to implement in many occasions and large-scale deployments. Therefore, it is of great practical significance to use existing equipment to obtain high-resolution images through super-resolution algorithms.
[0003] At present, most super-resolution algorithms are based on training paired data sets to obtain models. When the model is applied to low-resolution images with a distribution different from that of the training data set, the image super-resolution effect is poor and various artifacts are prone to occur. Summary of the invention
[0004] The present invention aims to solve at least one of the technical problems in the related art to a certain extent. To this end, the first object of the present invention is to propose an image denoising method, which can obtain an image denoising network for converting a low-resolution image into a high-resolution image by training an asymmetric training set, so as to improve the image super-resolution effect.
[0005] A second object of the present invention is to provide a computer-readable storage medium.
[0006] A third objective of the present invention is to provide an electronic device.
[0007] A fourth objective of the present invention is to provide an image denoising device.
[0008] A fifth object of the present invention is to provide an image super-resolution denoising method.
[0009] To achieve the above-mentioned purpose, an embodiment of the first aspect of the present invention proposes an image denoising method, which includes the following steps: respectively obtaining a noise-free first image and a second image with real noise having different image contents; using the first image and the second image to perform alternating iterative training on an initial noise generation network and a discrimination network to obtain a newly created noise generation network; inputting the first image into the newly created noise generation network, and outputting a third image with simulated noise; using the first image and the third image as paired training samples to train the initial image denoising network, and obtain a trained newly created image denoising network; wherein the newly created image denoising network is configured to convert the noisy original image into a noise-free newly created image.
[0010] The image denoising method of the embodiment of the present invention obtains a noise-free first image and a second image with real noise respectively, and then uses the first image and the second image to perform alternating iterative training on the initial noise generation network and the identification network to obtain a new noise generation network, and inputs the first image into the new noise generation network to obtain a third image with simulated noise, thereby using the first image and the third image as paired training samples to train the initial image denoising network to obtain a trained new image denoising network, which can convert the noisy original image into a noise-free new image. Thus, by training an asymmetric training set, an image denoising network for converting a low-resolution image into a high-resolution image can be obtained, thereby improving the image super-resolution effect.
[0011] In addition, the image denoising method of the present invention may also have the following additional technical features:
[0012] According to one embodiment of the present invention, the method of respectively acquiring a noise-free first image and a second image with real noise having different image contents includes: respectively acquiring a noise-free fourth image and a fifth image with real noise having different image contents; cropping or scaling the fourth image to obtain the first image, and cropping or scaling the fifth image to obtain the second image, so as to use the first image and the second image as unpaired training samples.
[0013] According to one embodiment of the present invention, the use of the first image and the second image to perform alternating iterative training on the initial noise generation network and the identification network to obtain a newly created noise generation network includes: the initial noise generation network training stage and the identification network training stage are performed alternately; the initial noise generation network training stage includes: inputting the first image into the initial noise generation network to obtain a first generated image with simulated noise; inputting the first generated image into the identification network to obtain a first identification result; obtaining a first loss based on the first image, the first generated image and the first identification result; adjusting the parameters of the initial noise generation network according to the first loss; the identification network training stage includes: inputting the first image into the initial noise generation network after parameter adjustment, and outputting a second generated image with simulated noise; inputting the second generated image into the identification network to obtain a second identification result; inputting the second image into the identification network to obtain a third identification result; obtaining a second loss based on the second identification result and the third identification result; and adjusting the parameters of the identification network according to the second loss.
[0014] According to one embodiment of the present invention, inputting the first generated image into the discrimination network to obtain a first discrimination result comprises: inputting the first generated image into a Gaussian high-pass filter to obtain a first intermediate image; inputting the first intermediate image into the discrimination network to obtain the first discrimination result; inputting the second generated image into the discrimination network to obtain a second discrimination result comprises: inputting the second generated image into the Gaussian high-pass filter to obtain a second intermediate image; inputting the second intermediate image into the discrimination network to obtain a second discrimination result; inputting the second image into the discrimination network to obtain the third discrimination result comprises: inputting the second image into the Gaussian high-pass filter to obtain a third intermediate image; inputting the third intermediate image into the discrimination network to obtain the third discrimination result.
[0015] According to one embodiment of the present invention, the first loss includes color loss, perceptual loss and texture loss, and the method for obtaining the color loss includes: inputting the first image and the first generated image into a Gaussian low-pass filter respectively to obtain a first filtered image and a first generated filtered image; and obtaining the color loss according to the first filtered image and the first generated filtered image.
[0016] According to one embodiment of the present invention, the first loss is calculated by the following formula:
[0017] L G =L col +αL tex +βL per ,
[0018]
[0019]
[0020] Among them, L G is the first loss, L col is the color loss, L tex is the texture loss, L per is the perceptual loss, n represents the number of images input in one iteration during training, and F L represents the high-frequency features obtained by Gaussian low-pass filtering, x represents the first image, and F H represents the low-frequency features obtained by Gaussian high-pass filtering, D represents the identification network, and G represents the noise generation network.
[0021] According to one embodiment of the present invention, the second loss is calculated by the following formula:
[0022]
[0023] Among them, L D For the second loss, y represents the second image.
[0024] According to one embodiment of the present invention, the initial noise generation network includes 12 residual sub-networks, wherein the residual sub-network includes a first convolutional layer and a second convolutional layer, the input end of the first convolutional layer is the input end of the residual sub-network, the output end of the first convolutional layer is connected to the input end of the second convolutional layer after Relu (Rectified Linear Units) activation processing, the output end of the second convolutional layer serves as the output end of the residual sub-network, and the input end and output end of the residual sub-network are connected.
[0025] To achieve the above-mentioned purpose, a second aspect of the present invention provides a computer-readable storage medium on which an image denoising program is stored. When the image denoising program is executed by a processor, the above-mentioned image denoising method is implemented.
[0026] The computer-readable storage medium of an embodiment of the present invention, when the image denoising program stored thereon is executed by a processor, can obtain an image denoising network for converting a low-resolution image into a high-resolution image by training an asymmetric training set, thereby improving the image super-resolution effect.
[0027] To achieve the above-mentioned purpose, the third aspect of the present invention proposes an electronic device, including a memory, a processor, and an image denoising program stored in the memory and executable on the processor, wherein when the processor executes the image denoising program, the above-mentioned image denoising method is implemented.
[0028] The electronic device of an embodiment of the present invention, when a computer program corresponding to the above-mentioned image denoising method stored in its memory is executed by a processor, can obtain an image denoising network for converting a low-resolution image into a high-resolution image by training an asymmetric training set, thereby improving the image super-resolution effect.
[0029] To achieve the above-mentioned purpose, a fourth aspect of the present invention proposes an image denoising device, which includes: a first acquisition module, used to respectively acquire a noise-free first image and a second image with real noise having different image contents; a first training module, used to use the first image and the second image to perform alternating iterative training on an initial noise generation network and a discrimination network to obtain a newly created noise generation network; a second acquisition module, used to input the first image into the newly created noise generation network and output a third image with simulated noise; a second training module, used to use the first image and the third image as paired training samples to train the initial image denoising network to obtain a trained newly created image denoising network; wherein the newly created image denoising network is configured to convert an original noisy image into a noise-free newly created image.
[0030] The image denoising device of the embodiment of the present invention obtains a noise-free first image and a second image with real noise having different image contents through a first acquisition module, and uses the first image and the second image to perform alternating iterative training on the initial noise generation network and the identification network through a first training module to obtain a newly created noise generation network, thereby inputting the first image into the newly created noise generation network through a second acquisition module, and outputting a third image with simulated noise, and then using the first image and the third image as paired training samples to train the initial image denoising network through a second training module to obtain a trained newly created image denoising network, and using the letter image denoising network to convert the noisy original image into a noise-free newly created image. Thus, by training an asymmetric training set, an image denoising network for converting a low-resolution image into a high-resolution image can be obtained, thereby improving the image super-resolution effect.
[0031] To achieve the above-mentioned purpose, a fifth aspect of the present invention proposes an image super-resolution denoising method, which includes the following steps: respectively obtaining a noise-free first reference image and a second reference image with real noise having different image contents; cropping or scaling the first reference image to obtain a third reference image, and cropping or scaling the second reference image to obtain a fourth reference image; using the third reference image and the fourth reference image to perform alternating iterative training on an initial noise generation network and a discrimination network to obtain a newly created noise generation network; converting the first reference image into a first training sample image, inputting the first training sample image into the newly created noise generation network, and outputting a second training sample image, wherein the resolution of the first reference image is greater than the resolution of the first training sample image, and the resolution of the second training sample image is the same as the resolution of the first training sample image; using the first reference image and the second training sample image as paired training samples, training the initial image super-resolution denoising network to obtain a trained newly created image super-resolution denoising network; wherein the newly created image super-resolution denoising network is configured to convert a noisy original image with a first resolution into a noise-free newly created image with a second resolution, and the first resolution is smaller than the second resolution.
[0032] The image super-resolution denoising method of the embodiment of the present invention obtains a noise-free first image and a second image with real noise respectively, and uses the first image and the second image to perform alternating iterative training on the initial noise generation network and the identification network to obtain a new noise generation network, thereby converting the first image into a first training sample image, inputting the first training sample image into the new noise generation network, outputting the second training sample image, and then using the first image and the second training sample image as paired training samples to train the initial image super-resolution denoising network to obtain a trained new image super-resolution denoising network, and through the new image super-resolution denoising network, the noisy original image is converted into a noise-free new image. Thus, by training an asymmetric training set, an image denoising network for converting a low-resolution image into a high-resolution image can be obtained, thereby improving the image super-resolution effect.
[0033] Additional aspects and advantages of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0034] Figure 1 is a flow chart of an image denoising method according to an embodiment of the present invention;
[0035] Figure 2 is a flow chart of an image denoising method according to another embodiment of the present invention;
[0036] Figure 3 is a flow chart of an image denoising method according to another embodiment of the present invention;
[0037] Figure 4 is a schematic diagram of an image processing process according to an embodiment of the present invention;
[0038] Figure 5 is an unpaired training picture of an example of the present invention;
[0039] Figure 6 is a low-resolution image of an input trained image denoising network in an example of the present invention;
[0040] Figure 7 is a high-resolution image output by a trained image denoising network of an example of the present invention;
[0041] Figure 8 is a structural block diagram of an image denoising device according to an embodiment of the present invention;
[0042] Fig. 9 It is a flowchart of an image super-resolution denoising method according to an embodiment of the present invention. DETAILED DESCRIPTION
[0043] Embodiments of the present invention are described in detail below, examples of which 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 intended to be used to explain the present invention, and should not be construed as limiting the present invention.
[0044] Please refer to the following Figure 1-9 An image denoising method, an apparatus, an electronic device, and an image super-resolution denoising method according to an embodiment of the present invention are described.
[0045] Figure 1 The figure is a flow chart of an image denoising method according to an embodiment of the present invention.
[0046] like Figure 1 As shown, the image denoising method includes the following steps:
[0047] S11, respectively acquiring a first noise-free image and a second image with real noise having different image contents.
[0048] Specifically, Figure 4As shown, respectively acquiring a noise-free first image and a second image with real noise having different image contents may include: respectively acquiring a noise-free fourth image and a fifth image with real noise having different image contents, and cropping or scaling the fourth image to obtain the first image, and cropping or scaling the fifth image to obtain the second image, so as to use the first image and the second image as unpaired training samples. The acquisition process may be as follows Figure 5 shown.
[0049] Specifically, the noise-free fourth image is cropped into the noise-free first image, and the fifth image with real noise is cropped into the second image with real noise. For example, 10,000 large images of 1024*1024 can be cropped into 160,000 small images of 256*256, that is, each high-resolution large image can be cropped into 16 low-resolution small images of 256*256. The noise-free fourth image is scaled into the noise-free first image, and the fifth image with real noise is scaled into the second image with real noise. For example, 160,000 large images of 1024*1024 can be scaled into 160,000 small images of 256*256.
[0050] It should be understood that cropping is to take a fixed-size (such as 128, 256, 512) image block at a random position in the image, which not only ensures that the image content resolution remains unchanged, but also obtains more training samples than the method of scaling the image. Therefore, in order to obtain the same number of small images (i.e., the first image and the second image), compared with the reduction process, the above-mentioned cropping process requires fewer large images (i.e., the fourth image and the fifth image) to be processed, and the processing speed is faster and more efficient.
[0051] S12, using the first image and the second image to perform alternate iterative training on the initial noise generation network and the identification network to obtain a new noise generation network.
[0052] The identification network may be a VGG (Visual Geometry Group) network or a Resnet (Residual Network) network, or other networks. The purpose of training the initial noise generation network is to make the third image with simulated noise generated by the initial noise generation network deceive the identification network so that the identification network cannot judge whether the third image generated by the initial noise generation network is true or false, thereby making the generated simulated noise closer to the distribution of real noise; the purpose of training the identification network is to make the identification network discover that the third image with simulated noise and the second image with real noise are not the same image. The initial noise generation network training stage and the identification network training stage are performed alternately. For example, the initial noise generation network training stage may be performed first, and then the identification network training stage may be performed, and then the above process may be repeated continuously. It should be noted that the initial noise generation network trained for the Nth time is obtained by adjusting the parameters of the initial noise generation network trained for the N-1th time, and the identification network trained for the Nth time is obtained by adjusting the parameters of the identification network trained for the N-1th time, where N is an integer greater than or equal to 2.
[0053] As an example, Figure 2 As shown, the above initial noise generation network training phase includes the following steps:
[0054] S21, inputting the first image into an initial noise generation network to obtain a first generated image with simulated noise.
[0055] Optionally, the simulated noise added by the initial noise generation network to the first image may be Gaussian noise, or may be added by Gaussian blurring, up-sampling or down-sampling, etc.
[0056] S22, inputting the first generated image into the identification network to obtain a first identification result.
[0057] Specifically, Figure 5 As shown, the first generated image is input into a Gaussian high-pass filter to obtain a first intermediate image, and then the first intermediate image is input into a discrimination network to obtain a first discrimination result.
[0058] S23, obtaining a first loss according to the first image, the first generated image and the first identification result.
[0059] The first loss includes color loss, perceptual loss, and texture loss. Color loss is measured only at low frequencies, so that the third image with simulated noise is the same as the first image without noise; perceptual loss is measured at full frequencies, that is, the close connection between high and low frequencies of the image is measured; texture loss is measured at high frequencies to measure whether the generated simulated noise is consistent with the distribution of real noise.
[0060] Specifically, the first image and the first generated image are respectively input into a Gaussian low-pass filter to obtain a first filtered image and a first generated filtered image, and then the color loss is obtained according to the first filtered image and the first generated filtered image.
[0061] As an example, the formula Calculate color loss.
[0062] Among them, L col is the color loss, F L represents the high-frequency features obtained by Gaussian low-pass filtering, n represents the number of images input in one iteration during training, i ranges from [1, n], x (i) represents the i-th first image of the input, and G represents the noise generation network.
[0063] According to the formula Calculate texture loss.
[0064] Among them, L tex is the texture loss, n represents the number of images input in one iteration during training, and F H represents the low-frequency features obtained by Gaussian high-pass filtering, and D represents the identification network.
[0065] Optionally, the VGG loss can be used as a perceptual loss, that is, the input and output images are input into the VGG network respectively, and the feature maps of some layers of the VGG network are taken out for loss. For example, the formula can be used Calculate the perceptual loss, where j represents the jth layer of the VGG network and 1 / C j H j W j Represents the size of the feature map of the j-th layer network, y and Both represent the style images obtained after image conversion of the input image, and Ф represents the VGG network.
[0066] Furthermore, according to the formula L G =L col +αL tex +βL per Calculate the first loss.
[0067] Among them, L G is the first loss, L per For perceived loss.
[0068] S24, adjusting parameters of the initial noise generation network according to the first loss.
[0069] It should be noted that the above-mentioned initial noise generation network includes 12 residual sub-networks, wherein the residual sub-network includes a first convolutional layer and a second convolutional layer, the input end of the first convolutional layer is the input end of the residual sub-network, the output end of the first convolutional layer is connected to the input end of the second convolutional layer after Relu activation processing, the output end of the second convolutional layer is used as the output end of the residual sub-network, and the input end and output end of the residual sub-network are connected.
[0070] Further, the identification network training phase is performed. As an example, Figure 3 As shown, the above identification network training phase includes the following steps:
[0071] S31, inputting the first image into the initial noise generation network after parameter adjustment, and outputting a second generated image with simulated noise.
[0072] S32, inputting the second generated image into the identification network to obtain a second identification result.
[0073] Specifically, the second generated image is input into a Gaussian high-pass filter to obtain a second intermediate image, and then the second intermediate image is input into a discrimination network to obtain a second discrimination result.
[0074] S33, inputting the second image into the identification network to obtain a third identification result.
[0075] Specifically, the second image is input into a Gaussian high-pass filter to obtain a third intermediate image, and then the third intermediate image is input into a discrimination network to obtain a third discrimination result.
[0076] S34, obtaining a second loss according to the second identification result and the third identification result.
[0077] Specifically, according to the formula Calculate the second loss.
[0078] Among them, L D is the second loss, y (i) represents the i-th second image of the input.
[0079] S35, adjusting parameters of the identification network according to the second loss.
[0080] Further, the above-mentioned initial noise generation network training stage and identification network training stage are repeated until the second loss of the identification network meets the preset condition, at which time the third image with simulated noise can "fool" the identification network.
[0081] It should be noted that the above-mentioned Gaussian low-pass filter and Gaussian high-pass filter are used to separate the high-frequency and low-frequency information of the image and to perform targeted constraints. The internal structures of the above-mentioned noise generation network and identification network can be designed as needed, but the overall adversarial structure of the noise generation network + identification network needs to be maintained.
[0082] S13, inputting the first image into a newly created noise generation network, and outputting a third image with simulated noise.
[0083] S14, using the first image and the third image as paired training samples to train the initial image denoising network to obtain a trained new image denoising network.
[0084] Specifically, Figure 5 As shown, since the third image with simulated noise that has passed the identification is closer to the second image with real noise, the noise-free first image and the third image with simulated noise that has passed the identification are used as paired training samples and input into the image denoising network for training to obtain a trained image denoising network. The image denoising network can not only improve the clarity of the image with real noise, but also alleviate the problem of super-resolution artifacts.
[0085] Furthermore, the newly created image denoising network is used to convert the noisy original image into a noise-free newly created image.
[0086] As an example, input into the new image denoising network above Figure 6 The low-resolution image (i.e., the original image with noise) shown in FIG. 1 can output a high-resolution image (i.e., a new image without noise) by the image denoising network. Figure 7 As shown, it can be clearly seen that relative to Figure 6 , Figure 7 The image clarity and super-resolution artifacts have been greatly improved.
[0087] In summary, the image denoising method of the embodiment of the present invention obtains an image denoising network for converting a low-resolution image into a high-resolution image by training an asymmetric training set, and the image super-resolution effect is improved through the network.
[0088] Furthermore, the present invention provides a computer-readable storage medium.
[0089] The computer-readable storage medium of the embodiment of the present invention stores an image denoising program, and the image denoising program implements the above-mentioned image denoising method when executed by a processor.
[0090] The computer-readable storage medium of an embodiment of the present invention can, when the image denoising program stored thereon is executed by a processor, obtain an image denoising network for converting a low-resolution image into a high-resolution image by training an asymmetric training set, thereby improving the image super-resolution effect.
[0091] Furthermore, the present invention provides an electronic device.
[0092] The electronic device of the embodiment of the present invention includes a memory, a processor, and an image denoising program stored in the memory and executable on the processor. When the processor executes the image denoising program, the above-mentioned image denoising method is implemented.
[0093] The electronic device of the embodiment of the present invention, by implementing the above-mentioned image denoising method, can obtain an image denoising network for converting a low-resolution image into a high-resolution image by training an asymmetric training set, thereby improving the image super-resolution effect.
[0094] Figure 8 4 is a structural block diagram of an image denoising device according to an embodiment of the present invention.
[0095] like Figure 8 As shown, the image denoising device 100 includes a first acquisition module 101 , a first training module 102 , a second acquisition module 103 , and a second training module 104 .
[0096] Specifically, the first acquisition module 101 is used to respectively acquire a noise-free first image and a second image with real noise having different image contents; the first training module 102 is used to use the first image and the second image to perform alternating iterative training on the initial noise generation network and the identification network to obtain a newly created noise generation network; the second acquisition module 103 is used to input the first image into the newly created noise generation network and output a third image with simulated noise; the second training module 104 is used to use the first image and the third image as paired training samples to train the initial image denoising network to obtain a trained newly created image denoising network; wherein the newly created image denoising network is configured to convert the noisy original image into a noise-free newly created image.
[0097] The image denoising device obtains an image denoising network for converting a low-resolution image into a high-resolution image by training an asymmetric training set, thereby improving the image super-resolution effect.
[0098] In one embodiment of the present invention, the first acquisition module 101 is specifically used to: respectively acquire a noise-free fourth image and a fifth image with real noise having different image contents; crop or scale the fourth image to obtain a first image, and crop or scale the fifth image to obtain a second image, so as to use the first image and the second image as unpaired training samples.
[0099] In one embodiment of the present invention, the first training module 102 is specifically used to: input the first image into the initial noise generation network to obtain a first generated image with simulated noise; input the first generated image into the identification network to obtain a first identification result; obtain a first loss based on the first image, the first generated image and the first identification result; and adjust the parameters of the initial noise generation network based on the first loss.
[0100] The first training module 102 can also be used to: input the first image into the initial noise generation network after parameter adjustment, and output a second generated image with simulated noise; input the second generated image into the identification network to obtain a second identification result; input the second image into the identification network to obtain a third identification result; obtain a second loss based on the second identification result and the third identification result; and adjust the parameters of the identification network based on the second loss.
[0101] The above-mentioned initial noise generation network training stage and the above-mentioned identification network training stage are performed alternately.
[0102] In one embodiment of the present invention, the first training module 102 may also be used to: input the first generated image into a Gaussian high-pass filter to obtain a first intermediate image; and input the first intermediate image into a discrimination network to obtain a first discrimination result.
[0103] The first training module 102 may also be used to: input the second generated image into a Gaussian high-pass filter to obtain a second intermediate image; and input the second intermediate image into a discrimination network to obtain a second discrimination result.
[0104] The first training module 102 can also be used to: input the second image into a Gaussian high-pass filter to obtain a third intermediate image; input the third intermediate image into a discrimination network to obtain a third discrimination result.
[0105] In one embodiment of the present invention, the first training module 102 can also be used to: input the first image and the first generated image into a Gaussian low-pass filter respectively to obtain a first filtered image and a first generated filtered image; and obtain color loss according to the first filtered image and the first generated filtered image.
[0106] Furthermore, the first loss is calculated by the following formula:
[0107] L G =L col +αL tex +βL per ,
[0108]
[0109]
[0110] Among them, L G is the first loss, L col is the color loss, L tex is the texture loss, L per is the perceptual loss, n represents the number of images input in one iteration during training, and F L represents the high-frequency features obtained by Gaussian low-pass filtering, x represents the first image, and F H represents the low-frequency features obtained by Gaussian high-pass filtering, D represents the identification network, and G represents the noise generation network.
[0111] In one embodiment of the present invention, the first training module 102 may also be used to calculate the second loss by the following formula:
[0112]
[0113] Among them, L D is the second loss, and y represents the second image.
[0114] It should be noted that, for other specific implementations of the image denoising device of the embodiment of the present invention, reference may be made to the image denoising method of the above embodiment.
[0115] In summary, the image denoising device of the embodiment of the present invention, through the super-resolution algorithm on the asymmetric training set, applies the super-resolution algorithm to the low-resolution image of the unknown degradation model, improves the super-resolution effect in the real scene, and enhances the image quality clarity.
[0116] Fig. 9 It is a flowchart of an image super-resolution denoising method according to an embodiment of the present invention.
[0117] like Fig. 9 As shown, the image super-resolution denoising method includes the following steps:
[0118] S41, respectively acquiring a first reference image without noise and a second reference image with real noise having different image contents.
[0119] S42, cropping or scaling the first reference image to obtain a third reference image, and cropping or scaling the second reference image to obtain a fourth reference image.
[0120] S43, using the third reference image and the fourth reference image to perform alternate iterative training on the initial noise generation network and the identification network to obtain a new noise generation network.
[0121] The initial noise generation network training stage includes: inputting the third reference image into the initial noise generation network to obtain a first reference generated image with simulated noise; inputting the first reference generated image into the identification network to obtain a first reference identification result; obtaining a first loss according to the third reference image, the first reference generated image and the first reference identification result; and adjusting the parameters of the initial noise generation network according to the first loss. The identification network training stage includes: inputting the third reference image into the initial noise generation network after parameter adjustment to output a second reference generated image with simulated noise; inputting the second reference generated image into the identification network to obtain a second reference identification result; inputting the fourth reference image into the identification network to obtain a third reference identification result; obtaining a second loss according to the second reference identification result and the third reference identification result; and adjusting the parameters of the identification network according to the second reference loss.
[0122] It should be noted that the above-mentioned initial noise generation network includes 12 residual sub-networks, wherein the residual sub-network includes a first convolutional layer and a second convolutional layer, the input end of the first convolutional layer is the input end of the residual sub-network, the output end of the first convolutional layer is connected to the input end of the second convolutional layer after Relu activation processing, the output end of the second convolutional layer is used as the output end of the residual sub-network, and the input end and output end of the residual sub-network are connected. The above-mentioned initial noise generation network training stage and the above-mentioned identification network training stage are performed alternately. The above-mentioned inputting the first reference generated image into the identification network to obtain the first reference identification result includes: inputting the first reference generated image into a Gaussian high-pass filter to obtain a first reference intermediate image; inputting the first reference intermediate image into the identification network to obtain the first reference identification result; the above-mentioned inputting the second reference generated image into the identification network to obtain the second reference identification result includes: inputting the second reference generated image into the Gaussian high-pass filter to obtain a second reference intermediate image; inputting the second reference intermediate image into the identification network to obtain the second reference identification result; the above-mentioned inputting the fourth reference image into the identification network to obtain the third reference identification result includes: inputting the fourth reference image into a Gaussian high-pass filter to obtain a third reference intermediate image; inputting the third reference intermediate image into the identification network to obtain the third reference identification result.
[0123] The first loss is calculated by the following formula:
[0124] L G =L col +αL tex +βL per ,
[0125]
[0126]
[0127] Among them, LG is the first loss, L col is the color loss, L tex is the texture loss, L per is the perceptual loss, n represents the number of images input in one iteration during training, and F L represents the high-frequency features obtained by Gaussian low-pass filtering, x represents the third reference image, and F H represents the low-frequency features obtained by Gaussian high-pass filtering, D represents the identification network, and G represents the noise generation network.
[0128] The method for obtaining the above-mentioned color loss is specifically as follows: inputting the third reference image and the first reference generated image into a Gaussian low-pass filter respectively to obtain a first reference filtered image and a first reference generated filtered image; and obtaining the color loss according to the first reference filtered image and the first reference generated filtered image.
[0129] The above second loss is calculated by the following formula:
[0130]
[0131] Among them, L D For the second loss, y represents the fourth reference image.
[0132] S44, converting the first reference image into a first training sample image, inputting the first training sample image into a newly created noise generation network, and outputting a second training sample image, wherein a resolution of the first reference image is greater than a resolution of the first training sample image, and a resolution of the second training sample image is the same as a resolution of the first training sample image.
[0133] The method for converting the first reference image into the first training sample image may be downsampling processing. For example, the noise-free first reference image may be downsampled to obtain a fifth reference image, and the fifth reference image may be input into the first training sample image. Figure 5 The noise generation model G shown in FIG. 1 is used to obtain a third reference generated image with simulated noise. The third reference generated image with simulated noise and the first reference image without noise are paired training data and can be used to train a super-resolution denoising network.
[0134] S45, using the first reference image and the second training sample image as paired training samples to train the initial image super-resolution denoising network to obtain a trained new image super-resolution denoising network.
[0135] Furthermore, the newly created image super-resolution denoising network is configured to convert a noisy original image with a first resolution into a noise-free newly created image with a second resolution, wherein the first resolution is smaller than the second resolution.
[0136] In summary, the image super-resolution denoising method of the embodiment of the present invention obtains an image denoising network for converting a low-resolution image into a high-resolution image by training an asymmetric training set, thereby improving the image super-resolution effect.
[0137] It should be noted that the logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in combination with these instruction execution systems, devices or apparatuses. For the purposes of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in combination with these instruction execution systems, devices or apparatuses. More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection portion with one or more wirings (electronic device), a portable computer disk box (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium and then editing, interpreting or processing in other suitable ways if necessary, and then stored in a computer memory.
[0138] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0139] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0140] In the description of the present invention, it is to be understood that the terms “center”, “longitudinal”, “lateral”, “length”, “width”, “thickness”, “up”, “down”, “front”, “back”, “left”, “right”, “vertical”, “horizontal”, “top”, “bottom”, “inside”, “outside”, “clockwise”, “counterclockwise”, “axial”, “radial”, “circumferential”, etc., indicating orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the present invention.
[0141] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of the present invention, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0142] In the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements, unless otherwise clearly defined. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0143] In the present invention, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being "above", "above" or "above" a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" or "below" a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.
[0144] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.
Claims
1. An image denoising method, It is characterized in that The following steps are involved: Acquire a first noise-free image and a second image with real noise respectively, each having different image contents; Using the first image and the second image to perform alternate iterative training on an initial noise generation network and a discrimination network to obtain a new noise generation network; Inputting the first image into the newly created noise generation network, and outputting a third image with simulated noise; Using the first image and the third image as paired training samples to train an initial image denoising network to obtain a trained new image denoising network; Wherein, the newly created image denoising network is configured to convert the noisy original image into a noise-free newly created image; The method of using the first image and the second image to perform alternate iterative training on the initial noise generation network and the identification network to obtain a new noise generation network includes: The initial noise generation network training phase and the discrimination network training phase are performed alternately; The initial noise generation network training phase includes: Inputting the first image into the initial noise generation network to obtain a first generated image with simulated noise; Inputting the first generated image into the identification network to obtain a first identification result; Obtaining a first loss according to the first image, the first generated image, and the first identification result; Adjusting parameters of the initial noise generation network according to the first loss; The identification network training phase includes: Inputting the first image into an initial noise generation network after parameter adjustment, and outputting a second generated image with simulated noise; Inputting the second generated image into the identification network to obtain a second identification result; Inputting the second image into the identification network to obtain a third identification result; Obtaining a second loss according to the second identification result and the third identification result; Parameters of the identification network are adjusted according to the second loss.
2. The image denoising method according to claim 1, It is characterized in that The step of respectively acquiring a noise-free first image and a second image with real noise having different image contents comprises: respectively acquiring a fourth image without noise and a fifth image with real noise having different image contents; The first image is obtained by cropping or scaling the fourth image, and the second image is obtained by cropping or scaling the fifth image, so that the first image and the second image are used as unpaired training samples.
3. The image denoising method according to claim 1, It is characterized in that The step of inputting the first generated image into the identification network to obtain a first identification result includes: Inputting the first generated image into a Gaussian high-pass filter to obtain a first intermediate image; Inputting the first intermediate image into the identification network to obtain the first identification result; The step of inputting the second generated image into the identification network to obtain a second identification result includes: Inputting the second generated image into the Gaussian high-pass filter to obtain a second intermediate image; Inputting the second intermediate image into the identification network to obtain a second identification result; The step of inputting the second image into the identification network to obtain the third identification result includes: Inputting the second image into the Gaussian high-pass filter to obtain a third intermediate image; The third intermediate image is input into the identification network to obtain the third identification result.
4. The image denoising method according to claim 1, It is characterized in that The first loss includes color loss, perception loss and texture loss, and the method for obtaining the color loss includes: Inputting the first image and the first generated image into a Gaussian low-pass filter to obtain a first filtered image and a first generated filtered image respectively; The color loss is obtained according to the first filtered image and the first generated filtered image.
5. The image denoising method according to claim 4, It is characterized in that The first loss is calculated by the following formula: L G =L col +αL tex +βL per , Among them, L G is the first loss, L col is the color loss, L tex is the texture loss, L per is the perceptual loss, n represents the number of images input in one iteration during training, and F L represents the high-frequency features obtained by Gaussian low-pass filtering, x represents the first image, and F H represents the low-frequency features obtained by Gaussian high-pass filtering, D represents the identification network, and G represents the noise generation network.
6. The image denoising method according to claim 5, It is characterized in that The second loss is calculated by the following formula: Among them, L D For the second loss, y represents the second image.
7. The image denoising method according to claim 1, It is characterized in that The initial noise generation network includes 12 residual sub-networks, wherein the residual sub-network includes a first convolutional layer and a second convolutional layer, the input end of the first convolutional layer is the input end of the residual sub-network, the output end of the first convolutional layer is connected to the input end of the second convolutional layer after Relu activation processing, the output end of the second convolutional layer is used as the output end of the residual sub-network, and the input end and output end of the residual sub-network are connected.
8. A computer-readable storage medium, It is characterized in that An image denoising program is stored thereon, and when the image denoising program is executed by a processor, the image denoising method according to any one of claims 1 to 7 is implemented.
9. An electronic device, It is characterized in that The invention comprises a memory, a processor and an image denoising program stored in the memory and executable on the processor. When the processor executes the image denoising program, the image denoising method according to any one of claims 1 to 7 is implemented.
10. An image denoising device, It is characterized in that include: A first acquisition module is used to respectively acquire a noise-free first image and a second image with real noise, which have different image contents; A first training module, used for performing alternating iterative training on an initial noise generation network and a discrimination network using the first image and the second image to obtain a new noise generation network; A second acquisition module, used for inputting the first image into the newly-created noise generation network, and outputting a third image with simulated noise; A second training module, used to train an initial image denoising network using the first image and the third image as paired training samples to obtain a newly trained image denoising network; The newly created image denoising network is configured to convert a noisy original image into a noise-free newly created image; The method of using the first image and the second image to perform alternate iterative training on the initial noise generation network and the identification network to obtain a new noise generation network includes: The initial noise generation network training phase and the discrimination network training phase are performed alternately; The initial noise generation network training phase includes: Inputting the first image into the initial noise generation network to obtain a first generated image with simulated noise; Inputting the first generated image into the identification network to obtain a first identification result; Obtaining a first loss according to the first image, the first generated image, and the first identification result; Adjusting parameters of the initial noise generation network according to the first loss; The identification network training phase includes: Inputting the first image into an initial noise generation network after parameter adjustment, and outputting a second generated image with simulated noise; Inputting the second generated image into the identification network to obtain a second identification result; Inputting the second image into the identification network to obtain a third identification result; Obtaining a second loss according to the second identification result and the third identification result; Parameters of the identification network are adjusted according to the second loss.
11. A method for image super-resolution denoising, It is characterized in that The following steps are involved: Acquire a first reference image without noise and a second reference image with real noise respectively, each having different image contents; Cropping or scaling the first reference image to obtain a third reference image, and cropping or scaling the second reference image to obtain a fourth reference image; The initial noise generation network and the identification network are alternately and iteratively trained using the third reference image and the fourth reference image to obtain a newly created noise generation network, wherein the initial noise generation network training stage and the identification network training stage are performed alternately; the initial noise generation network training stage includes: inputting the first reference image into the initial noise generation network to obtain a first generated image with simulated noise; inputting the first generated image into the identification network to obtain a first identification result; obtaining a first loss according to the first reference image, the first generated image and the first identification result; adjusting the parameters of the initial noise generation network according to the first loss; the identification network training stage includes: inputting the first reference image into the initial noise generation network after parameter adjustment, and outputting a second generated image with simulated noise; inputting the second generated image into the identification network to obtain a second identification result; inputting the second reference image into the identification network to obtain a third identification result; obtaining a second loss according to the second identification result and the third identification result; adjusting the parameters of the identification network according to the second loss; Converting the first reference image into a first training sample image, inputting the first training sample image into a newly created noise generation network, and outputting a second training sample image, wherein the resolution of the first reference image is greater than the resolution of the first training sample image, and the resolution of the second training sample image is the same as the resolution of the first training sample image; Using the first reference image and the second training sample image as paired training samples, training an initial image super-resolution denoising network to obtain a trained new image super-resolution denoising network; The newly created image super-resolution denoising network is configured to convert a noisy original image with a first resolution into a noise-free newly created image with a second resolution, wherein the first resolution is smaller than the second resolution.
Citation Information
Patent Citations
Image noise removal system, method and device
CN109636746A
Image denoising method based on adversarial generative network
CN110223254A
Method and device for generating image denoising model
CN110288547A
Method for generating super-resolution image based on generative adversarial network
CN110490804A
Super resolution using a generative adversarial network
US20180075581A1
