CN112365559B - Infrared image coloring method for generating countermeasure network based on structural similarity - Google Patents
Infrared image coloring method for generating countermeasure network based on structural similarity Download PDFInfo
- Publication number
- CN112365559B CN112365559B CN202011305117.2A CN202011305117A CN112365559B CN 112365559 B CN112365559 B CN 112365559B CN 202011305117 A CN202011305117 A CN 202011305117A CN 112365559 B CN112365559 B CN 112365559B
- Authority
- CN
- China
- Prior art keywords
- image
- generator
- infrared image
- representing
- structural similarity
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T11/00—2D [Two Dimensional] image generation
- G06T11/001—Texturing; Colouring; Generation of texture or colour
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T11/00—2D [Two Dimensional] image generation
- G06T11/40—Filling a planar surface by adding surface attributes, e.g. colour or texture
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10048—Infrared image
Abstract
The invention relates to an infrared image coloring method for generating a countermeasure network based on structural similarity, which constructs a countermeasure network based on structural similarity and comprises a generator and a discriminator; the discriminator can distinguish whether the image is from an infrared image domain or a color image domain, and a loss function based on a generation countermeasure network, a cycle consistency loss function and a reconstruction loss function based on a norm or a norm, and a loss function based on structural similarity are adopted for the generator, so that the generator can generate a color image with vivid colors and clear edges; the pre-collected infrared image and the color image are used for training the proposed generation countermeasure network based on the structural similarity to a convergence condition, and the obtained generator can realize coloring of the infrared image. The invention not only can retain the advantage of infrared imaging shooting at night, but also can be beneficial to human eyes to better and more quickly capture useful information in the image and give full play to the value of the image, thereby promoting the development of night vision imaging technology.
Description
Technical Field
The invention relates to the technical field of image processing, in particular to an infrared image coloring method for generating a countermeasure network based on structural similarity.
Background
The near-infrared imaging technology is a technology for imaging by reflecting near-infrared radiation by different objects, is widely applied to night vision imaging devices, and has great application in military affairs, field observation, security, navigation and other aspects.
However, since the infrared image obtained by the near-infrared imaging technology is a monochromatic image, compared with a color image, the infrared image lacks more color features, which is not beneficial to direct resolution and identification of human eyes, and restricts the acquisition of effective information in a scene.
Disclosure of Invention
The invention aims to overcome the defects of the prior art and provides an infrared image coloring method for generating a countermeasure network based on structural similarity, which can convert an infrared image into a color image, not only retains the advantage of shooting at night by infrared imaging, but also is beneficial to human eyes to better and more quickly capture useful information in the image.
The technical scheme of the invention is as follows:
an infrared image coloring method for generating a countermeasure network based on structural similarity comprises the following steps:
1) constructing a generating countermeasure network based on the structural similarity, wherein the generating countermeasure network based on the structural similarity comprises a generator G and a discriminator D; wherein the generator G comprises a color image generator G RGB Infrared image generator G NIR Color image generator G RGB For generating colour images, an infrared image generator G NIR For generating an infrared image, the discriminator D being arranged to determine whether the image is from an infrared image domain or a colour image domain;
2) for the discriminator D, a loss function for generating a countermeasure network is adopted; for a generator G, a loss function based on a generated countermeasure network, a cyclic consistent loss function based on a first norm or a second norm, a reconstruction loss function are adopted, a loss function based on structural similarity is introduced, and a new loss function for the generator G is constructed; in step 2), the loss function based on the structural similarity is:
wherein, the first and the second end of the pipe are connected with each other,
wherein the content of the first and second substances,
y cycle =G RGB [G NIR (y)];
y recon =G RGB (y);
x cycle =G NIR [G RGB (x)];
x recon =G NIR (x);
wherein NIR represents the infrared image domain and RGB represents the color image domain; x represents a real infrared image and y represents a color image;representing by an infrared image generator G NIR The generated infrared image is converted into a digital image,representation by a color image generator G RGB Converting the generated color image; g NIR Representing an infrared image generator, G RGB A representative color image generator; x is a radical of a fluorine atom cycle Indicating cyclically consistent infrared image, y cycle Representing a cyclically consistent color image; x is the number of recon Representing the reconstructed infrared image, y recon Representing the reconstructed color image;a desired operation representing a distribution of image samples;
representing a structural similarity-based image transformation loss from the infrared image domain to the color image domain;
representing a structural similarity-based image transformation loss from a color image domain to an infrared image domain;
representing a structural similarity-based cyclic consensus loss from the infrared image domain to the color image domain;
representing a structural similarity-based cyclic consensus loss from the color image domain to the infrared image domain;
representing a structural similarity-based reconstruction loss from the infrared image domain to the color image domain;
representing a structural similarity-based reconstruction loss from a color image domain to an infrared image domain;
the SSIM represents a structural similarity calculation method, which specifically comprises the following steps:
wherein m and n represent a pair of images; mu.s m And mu n A mean value representing the image; sigma m And σ n Representing the variance of the image; sigma mn Representing the covariance of the two images; c 1 And C 2 Is a constant;
3) training the generation countermeasure network constructed in the step 1) based on the structural similarity to a convergence condition by utilizing the pre-collected infrared image and color image to obtain an updated color image generator G RGB Using the updated colour image generator G RGB The infrared image is colored.
Preferably, in step 2), the loss function for the generator G is:
L G =λ 1 L gan +λ 2 L cycle +λ 3 L recon +λ 4 L ssim ;
wherein L is gan 、L cycle And L recon Respectively representing loss function and cyclic consistent loss function of generation countermeasure networkAnd reconstructing a loss function; lambda [ alpha ] 1 >0、λ 2 >0、λ 3 > 0 and lambda 4 > 0 denotes a weight parameter for controlling each loss function.
Preferably, in step 3), the convergence condition is:
wherein NIR represents the infrared image domain and RGB represents the color image domain; g NIR Representing an infrared image generator, G RGB A representative color image generator; d NIR Discriminator indicating that the decision image is from the infrared image domain, D RGB A discriminator for indicating whether the judgment image is from a color image domain; l is D Representing a loss function, L, for the discriminator D G Representing the loss function for generator G.
Preferably, in step 3), the training is countertraining using the generator G and the discriminator D, and the updated color image generator G is obtained RGB 。
The invention has the following beneficial effects:
the invention relates to an infrared image coloring method for generating a confrontation network based on structural similarity, which comprises the following steps of firstly, constructing a generating confrontation network based on the structural similarity, wherein the generating confrontation network comprises a generator and a discriminator; secondly, a generation countermeasure loss function is adopted for the discriminator, so that the discriminator can distinguish whether the image is from an infrared image domain or a color image domain, and the generator not only adopts a loss function based on a generation countermeasure network, a cycle consistent loss function based on a norm or a norm and a reconstruction loss function, but also introduces a loss function based on structural similarity, so that the generator can generate a color image with vivid color and clear edges; and finally, training the proposed generation countermeasure network based on the structural similarity to a convergence condition by utilizing the pre-collected infrared image and the color image, and coloring the infrared image by the obtained generator.
The invention realizes the conversion of the infrared image into a vivid color image, not only can retain the advantage of shooting at night by infrared imaging, but also is beneficial to the human eyes to better and more quickly capture useful information in the image and give full play to the value of the image, thereby promoting the development of the night vision imaging technology.
Drawings
FIG. 1 is a schematic diagram of an infrared image rendering model for generating a countermeasure network based on structural similarity;
fig. 2 is a schematic diagram of a color image generation process.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples.
The invention provides an infrared image coloring method for generating a countermeasure network based on structural similarity in order to convert an infrared image into a vivid color image, which comprises the following steps:
1) constructing a generating confrontation network based on the structural similarity, wherein the generating confrontation network based on the structural similarity comprises a generator G and a discriminator D; wherein the generator G comprises a color image generator G RGB Infrared image generator G NIR Color image generator G RGB For generating colour images, an infrared image generator G NIR For generating an infrared image, the discriminator D being arranged to determine whether the image is from an infrared image domain or a colour image domain;
2) for the discriminator D, a loss function for generating a countermeasure network is adopted; for a generator G, a loss function based on a generated countermeasure network, a cyclic consistent loss function based on a first norm or a second norm, a reconstruction loss function are adopted, a loss function based on structural similarity is introduced, and a new loss function for the generator G is constructed; in step 2), the loss function based on the structural similarity is:
wherein the content of the first and second substances,
wherein the content of the first and second substances,
y cycle =G RGB [G NIR (y)];
y recon =G RGB (y);
x cycle =G NIR [G RGB (x)];
x recon =G NIR (x);
wherein NIR represents the infrared image domain and RGB represents the color image domain; x represents a real infrared image and y represents a color image;representing by an infrared image generator G NIR The generated infrared image is converted into an infrared image,representation by a color image generator G RGB Converting the generated color image; g NIR Representing an infrared image generator, G RGB A representative color image generator; x is the number of cycle Indicating cyclically consistent infrared image, y cycle Representing a cyclically consistent color image; x is the number of recon Representing the reconstructed infrared image, y recon Representing the reconstructed color image;a desired operation representing a distribution of image samples;
representing a structural similarity-based image transformation loss from the infrared image domain to the color image domain;
representing a structural similarity-based image transformation loss from a color image domain to an infrared image domain;
representing a structural similarity-based cyclic consensus loss from the infrared image domain to the color image domain;
representing a structural similarity-based cyclic consensus loss from the color image domain to the infrared image domain;
representing a structural similarity-based reconstruction loss from the infrared image domain to the color image domain;
representing a structural similarity-based reconstruction loss from a color image domain to an infrared image domain;
the SSIM represents a structural similarity calculation method, which specifically comprises the following steps:
wherein m and n represent a pair of images; mu.s m And mu n A mean value representing the image; sigma m And σ n Representing the variance of the image; sigma mn Representing the covariance of the two images; c 1 And C 2 As constants, the present embodiment is set to 0.0001 and 0.0009, respectively;
3) training the generation countermeasure network constructed in the step 1) based on the structural similarity to a convergence condition by utilizing the pre-collected infrared image and color image to obtain an updated color image generator G RGB Using the updated colour image generator G RGB The infrared image is colored.
In this embodiment, the generation countermeasure network described in step 1) is a generation countermeasure network model (No-Independent-Component-for-Encoding GAN, NICE-GAN) without Independent components for an encoder, where two sets of generation countermeasure networks are included, each set of generation countermeasure network includes one discriminator D and one generator G, and in each set of generation countermeasure network, the generator G and the discriminator D share an encoder E in the discriminator D, that is, the encoder E in the discriminator D is used as an encoder of the generator G. As shown in fig. 1, the image conversion process of NICE-GAN is represented as:
x recon =G NIR [E NIR (x)];
y recon =G RGB [E RGB (y)];
wherein NIR represents the infrared image domain and RGB represents the color image domain; x represents a real infrared image and y represents a color image;representing by an infrared image generator G NIR The generated infrared image is converted into an infrared image,representation by a color image generator G RGB Converting the generated color image; g NIR Representing an infrared image generator, G RGB A representative color image generator; x is the number of cycle Representing circularly coherent infrared images, y cycle Representing a circularly consistent color image; x is the number of recon Representing the reconstructed infrared image, y recon Representing the reconstructed color image; g NIR And G RGB An infrared image generator and a color image generator respectively; e NIR As a discriminator D NIR An encoder common to the generators; e RGB As a discriminator D RGB Common to the encoder of the generator. In this embodiment, the generator G and the discriminator D (including the encoder E) are constituted by a convolutional neural network, wherein the generator G includes 6 residual block structures and a deconvolution network layer; discriminator D (including encoder E) is a 7-layer convolutional neural network.
In step 2), the loss function for the generator G is:
L G =λ 1 L gan +λ 2 L cycle +λ 3 L recon +λ 4 L ssim ;
wherein L is gan 、L cycle And L recon Respectively representing a loss function, a cycle consistent loss function and a reconstruction loss function of the generated countermeasure network; lambda [ alpha ] 1 >0、λ 2 >0、λ 3 > 0 and lambda 4 > 0 denotes a weight parameter for controlling the respective loss function, in this embodiment, lambda 1 、λ 2 、λ 3 And λ 4 Set to 1, 10 and 0.001, respectively.
In step 3), the convergence condition is as follows:
wherein NIR represents the infrared image domain and RGB represents the color image domain; g NIR Representing an infrared image generator, G RGB A representative color image generator; d NIR Discriminator indicating that the decision image is from the infrared image domain, D RGB Signature representing the judged image from a colour image fieldA discriminator; l is a radical of an alcohol D Representing a loss function, L, for the discriminator D G Representing the loss function for generator G.
In step 3), the training is to adopt the generator G and the discriminator D to carry out confrontation training so as to obtain the updated color image generator G RGB . Further, using the updated color image generator G RGB The infrared image is colored, so that the infrared image can be converted into a vivid color image; the generation of the color image is shown in fig. 2.
The above examples are provided only for illustrating the present invention and are not intended to limit the present invention. Changes, modifications, etc. to the above-described embodiments are intended to fall within the scope of the claims of the present invention as long as they are in accordance with the technical spirit of the present invention.
Claims (4)
1. An infrared image coloring method for generating a confrontation network based on structural similarity is characterized by comprising the following steps:
1) constructing a generating countermeasure network based on the structural similarity, wherein the generating countermeasure network based on the structural similarity comprises a generator G and a discriminator D; wherein the generator G comprises a color image generator G RGB Infrared image generator G NIR Color image generator G RGB For generating colour images, an infrared image generator G NIR For generating an infrared image, the discriminator D being arranged to determine whether the image is from an infrared image domain or a colour image domain;
2) for the discriminator D, a loss function for generating a countermeasure network is adopted; for a generator G, a loss function based on a generated countermeasure network, a cyclic consistent loss function based on a first norm or a second norm, a reconstruction loss function are adopted, a loss function based on structural similarity is introduced, and a new loss function for the generator G is constructed; in step 2), the loss function based on the structural similarity is:
wherein the content of the first and second substances,
wherein the content of the first and second substances,
y cycle =G RGB [G NIR (y)];
y recon =G RGB (y);
x cycle =G NIR [G RGB (x)];
x recon =G NIR (x);
wherein NIR represents the infrared image domain and RGB represents the color image domain; x represents a real infrared image and y represents a color image;representing by an infrared image generator G NIR The generated infrared image is converted into an infrared image,representation by a color image generator G RGB Converting the generated color image; g NIR Representing an infrared image generator, G RGB A representative color image generator; x is the number of cycle Indicating cyclically consistent infrared image, y cycle Representing a cyclically consistent color image; x is the number of recon Representing the reconstructed infrared image, y recon Representing the reconstructed color image;a desired operation representing a distribution of image samples;
representing a structural similarity-based image transformation loss from the infrared image domain to the color image domain;
structure-based representation of conversion from color image domain to infrared image domainImage conversion loss of similarity;
representing a structural similarity-based cyclic consensus loss from the infrared image domain to the color image domain;
representing a structural similarity-based cyclic consensus loss from the color image domain to the infrared image domain;
representing a structural similarity-based reconstruction loss from the infrared image domain to the color image domain;
representing a structural similarity-based reconstruction loss from a color image domain to an infrared image domain;
the SSIM represents a structural similarity calculation method, which specifically comprises the following steps:
wherein m and n represent a pair of images; mu.s m And mu n A mean value representing the image; sigma m And σ n Representing the variance of the image; sigma mn Representing the covariance of the two images; c 1 And C 2 Is a constant;
3) training the generation countermeasure network constructed in the step 1) based on the structural similarity to a convergence condition by utilizing the pre-collected infrared image and color image to obtain an updated color image generator G RGB Using the updated colour image generator G RGB The infrared image is colored.
2. The infrared image coloring method for generating a countermeasure network based on structural similarity as claimed in claim 1, wherein in step 2), the loss function for the generator G is:
L G =λ 1 L gan +λ 2 L cycle +λ 3 L recon +λ 4 L ssim ;
wherein L is gan 、L cycle And L recon Respectively representing a loss function, a cycle consistent loss function and a reconstruction loss function of the generated countermeasure network; lambda [ alpha ] 1 >0、λ 2 >0、λ 3 > 0 and lambda 4 > 0 denotes a weight parameter for controlling each loss function.
3. The infrared image coloring method for generating a countermeasure network based on structural similarity as claimed in claim 1, wherein in step 3), the convergence condition is:
wherein NIR represents the infrared image domain and RGB represents the color image domain; g NIR Representing an infrared image generator, G RGB A representative color image generator; d NIR Discriminator indicating that the decision image is from the infrared image domain, D RGB A discriminator for indicating whether the judgment image is from a color image domain; l is D Representing a loss function, L, for the discriminator D G Representing the loss function for generator G.
4. The infrared image coloring method for generating countermeasure network based on structural similarity as claimed in claim 1, which isCharacterized in that in the step 3), the training is countertraining by adopting a generator G and a discriminator D, and then the updated color image generator G is obtained RGB 。
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011305117.2A CN112365559B (en) | 2020-11-19 | 2020-11-19 | Infrared image coloring method for generating countermeasure network based on structural similarity |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011305117.2A CN112365559B (en) | 2020-11-19 | 2020-11-19 | Infrared image coloring method for generating countermeasure network based on structural similarity |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112365559A CN112365559A (en) | 2021-02-12 |
CN112365559B true CN112365559B (en) | 2022-08-26 |
Family
ID=74533353
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011305117.2A Active CN112365559B (en) | 2020-11-19 | 2020-11-19 | Infrared image coloring method for generating countermeasure network based on structural similarity |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112365559B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113609893B (en) * | 2021-06-18 | 2024-04-16 | 大连民族大学 | Low-illuminance indoor human body target visible light characteristic reconstruction method and network based on infrared camera |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108711138A (en) * | 2018-06-06 | 2018-10-26 | 北京印刷学院 | A kind of gray scale picture colorization method based on generation confrontation network |
CN110827375A (en) * | 2019-10-31 | 2020-02-21 | 湖北大学 | Infrared image true color coloring method and system based on low-light-level image |
CN111524205A (en) * | 2020-04-23 | 2020-08-11 | 北京信息科技大学 | Image coloring processing method and device based on loop generation countermeasure network |
CN111583113A (en) * | 2020-04-30 | 2020-08-25 | 电子科技大学 | Infrared image super-resolution reconstruction method based on generation countermeasure network |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10474929B2 (en) * | 2017-04-25 | 2019-11-12 | Nec Corporation | Cyclic generative adversarial network for unsupervised cross-domain image generation |
-
2020
- 2020-11-19 CN CN202011305117.2A patent/CN112365559B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108711138A (en) * | 2018-06-06 | 2018-10-26 | 北京印刷学院 | A kind of gray scale picture colorization method based on generation confrontation network |
CN110827375A (en) * | 2019-10-31 | 2020-02-21 | 湖北大学 | Infrared image true color coloring method and system based on low-light-level image |
CN111524205A (en) * | 2020-04-23 | 2020-08-11 | 北京信息科技大学 | Image coloring processing method and device based on loop generation countermeasure network |
CN111583113A (en) * | 2020-04-30 | 2020-08-25 | 电子科技大学 | Infrared image super-resolution reconstruction method based on generation countermeasure network |
Non-Patent Citations (2)
Title |
---|
Multi-label learning with multi-label smoothing regularization for vehicle re-identification;Huanqiang Zeng 等;《ScienceDirect》;20190205;全文 * |
基于生成对抗网络的图像彩色化算法;赵绍良;《中国优秀硕士学位论文全文数据库》;20200215;第I138-1937页 * |
Also Published As
Publication number | Publication date |
---|---|
CN112365559A (en) | 2021-02-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Shao et al. | Remote sensing image fusion with deep convolutional neural network | |
Li et al. | Coupled GAN with relativistic discriminators for infrared and visible images fusion | |
CN111709902A (en) | Infrared and visible light image fusion method based on self-attention mechanism | |
CN110599395B (en) | Target image generation method, device, server and storage medium | |
CN111080567A (en) | Remote sensing image fusion method and system based on multi-scale dynamic convolution neural network | |
CN111260584A (en) | Underwater degraded image enhancement method based on GAN network | |
CN109509160A (en) | A kind of remote sensing image fusion method by different level using layer-by-layer iteration super-resolution | |
CN107203985A (en) | A kind of many exposure image fusion methods under end-to-end deep learning framework | |
CN105550989B (en) | The image super-resolution method returned based on non local Gaussian process | |
CN107958465A (en) | A kind of single image to the fog method based on depth convolutional neural networks | |
CN107085835B (en) | Color image filtering method based on quaternary number Weighted Kernel Norm minimum | |
CN112967178A (en) | Image conversion method, device, equipment and storage medium | |
CN111986108A (en) | Complex sea-air scene image defogging method based on generation countermeasure network | |
CN112116601A (en) | Compressive sensing sampling reconstruction method and system based on linear sampling network and generation countermeasure residual error network | |
CN108921783A (en) | A kind of satellite image super resolution ratio reconstruction method based on losses by mixture function constraint | |
He et al. | Color transfer pulse-coupled neural networks for underwater robotic visual systems | |
CN112365559B (en) | Infrared image coloring method for generating countermeasure network based on structural similarity | |
CN110599585A (en) | Single-image human body three-dimensional reconstruction method and device based on deep learning | |
Feng et al. | A new technology of remote sensing image fusion | |
CN116029930A (en) | Multispectral image demosaicing method based on convolutional neural network | |
CN110148083B (en) | Image fusion method based on rapid BEMD and deep learning | |
Reddy et al. | Image Compression and reconstruction using a new approach by artificial neural network | |
CN106355625B (en) | Single-polarization SAR false color image generation method | |
CN108537104A (en) | Compressed sensing network based on full figure observation and perception loss reconstructing method | |
CN116863069A (en) | Three-dimensional light field face content generation method, electronic equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |