A method for fusion of infrared and visible light images for joint high-level vision tasks
By constructing an image fusion network of teacher and student networks, combined with an adversarial generation network and a semantic segmentation model, the problem that the existing mid-infrared and visible light image fusion algorithms ignore advanced visual tasks is solved, and efficient image fusion and semantic information retention are achieved. Improved fusion performance and evaluation indicators.
Patent Information
- Application Number
- CN202411061385.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-05
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2044-08-05
AI Technical Summary
Existing infrared and visible light image fusion algorithms mainly focus on visual quality and evaluation indicators, ignoring the needs of high-level visual tasks, and the evaluation methods are one-sided and difficult to reflect the help of fusion results for high-level visual tasks.
Using the image fusion network of teacher network and student network, through adversarial generative network training and knowledge distillation, a real-time semantic segmentation model is introduced, the segmentation loss function of semantic information is calculated, and a joint loss function is generated to guide the training of the image fusion network to ensure that the fused image contains semantics information.
A semantic segmentation-driven image fusion framework is implemented, which improves the fusion performance of infrared and visible light images, meets the needs of advanced visual tasks, and shows competitive performance in visual effects and objective evaluation indicators.
Smart Images

Figure CN118570601B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image processing, and in particular to a method for fusing infrared and visible light images for a combined high-level visual task. Background Art
[0002] There are still some problems with deep learning-based fusion methods in the field of image fusion. First, most infrared and visible light image fusion algorithms tend to only carefully design the fusion network to pursue better visual quality and higher evaluation index results, while ignoring the need for the fused image to meet subsequent high-level visual tasks. In fact, existing studies have shown that only considering the visual quality and evaluation indicators of the underlying visual tasks is not helpful for subsequent high-level visual tasks. How to use high-level visual tasks to guide low-level visual methods to design and train networks is a problem worthy of in-depth study. Secondly, the existing evaluation methods are mainly visual intuitive evaluation and index evaluation. Visual evaluation mainly focuses on information such as contrast and edge texture of the fused image, while index evaluation uses different statistical indicators to evaluate the performance of the fusion method. However, only using visual intuitive evaluation and index evaluation of image fusion is one-sided, and it is difficult to reflect whether the fusion results are helpful for higher-level visual tasks. Summary of the invention
[0003] In view of the above-mentioned deficiencies in the prior art, the present invention provides a method for fusing infrared and visible light images for a combined high-level visual task.
[0004] In order to achieve the above-mentioned object of the invention, the technical solution adopted by the present invention is:
[0005] A method for combining infrared and visible light images for advanced visual tasks includes the following steps:
[0006] S1. Construct an image fusion network including a teacher network and a student network;
[0007] S2. Optimize and train the constructed image fusion network using the training method of the adversarial generative network;
[0008] S3, introducing the real-time semantic segmentation model into the optimized trained image fusion network, segmenting the output image of the image fusion network and assisting the image fusion network to learn and retain the semantic information of the fused image;
[0009] S4, calculating the segmentation loss function of the obtained semantic information, and using the segmentation loss function of the obtained semantic information to generate a joint loss function to guide the training and optimization of the image fusion network;
[0010] S5. Use the image fusion network trained and optimized in S4 to fuse infrared and visible light images to generate a fused image containing semantic information.
[0011] Furthermore, the S1 specifically includes the following steps:
[0012] S11. Construct a teacher network, including a residual module for extracting features of input infrared and visible light, a multi-scale channel attention module for enhancing the perception of features at different scales, and a fusion layer for fusing features of infrared and visible light images;
[0013] S12. Compress the constructed teacher network, transfer the knowledge of the teacher network to the compressed teacher network by minimizing the knowledge distillation loss function, and complete the student network construction.
[0014] Furthermore, the function for minimizing the knowledge distillation loss in S12 is expressed as:
[0015] ;
[0016] In the formula, To minimize the knowledge distillation loss function, is the b-th layer feature of the teacher network The projection function embedded into the spatial domain, The b-th layer features of the student network The projection function embedded into the same spatial domain as the teacher network, is the length of the feature vector, To sum the counts, Calculate the norm.
[0017] Further, the S2 specifically comprises the following steps;
[0018] S21, using an image fusion network to receive input of a real infrared image and a real visible light image, and generate a preliminary fused image;
[0019] S22, inputting the real infrared image, the real visible light image and the preliminary fusion image generated in S21 into two discriminators respectively to distinguish the authenticity of the input images;
[0020] S23, using the discriminator adversarial loss function to optimize the classification ability of the two discriminators;
[0021] S24. Based on the S23 discriminator adversarial loss function, the teacher network and the student network are trained.
[0022] Furthermore, the discriminator adversarial loss function in S23 is expressed as:
[0023] ;
[0024] ;
[0025] In the formula, is the first discriminator adversarial loss function, The output result of the first discriminator is input as the real infrared image, is the real infrared image input to the first discriminator, The output result of the first discriminator is input to the preliminary fusion image. is the preliminary fusion image input to the first discriminator; is the adversarial loss function for the second discriminator, is the output result of the second discriminator for real visible light input, is the real visible light image input to the second discriminator, The output result of the second discriminator is input to the preliminary fusion image. is the preliminary fusion image input to the second discriminator; is the feature vector length, N is the number of input images, and the constant 1 indicates that we want the discriminator to believe that the fused image is a real image.
[0026] Furthermore, the specific method of guiding the teacher network and the student network to train based on the discriminator adversarial loss function in S23 in S24 is:
[0027] ;
[0028] In the formula, is the fusion loss function; is the pixel intensity loss function; is the texture loss function, is the weight of texture loss function; is the image fusion adversarial loss function, is the weight of the image fusion adversarial loss function; where:
[0029] ;
[0030] Where m is the training batch size, max() is the maximization operation of elements at the same position, and I f ,I ir and I vis They are the fused image, the input infrared image, and the input visible light image. To sum the count;
[0031] ;
[0032] In the formula, is the Sobel gradient operator;
[0033] ;
[0034] In the formula, The output result of the first discriminator is input to the preliminary fusion image. The output result of the second discriminator is input to the preliminary fusion image. is a balancing parameter, N is the number of input images, and the constant 1 indicates that we want the discriminator to believe that the fused image is the real image.
[0035] Furthermore, the segmentation loss function in S4 is expressed as:
[0036] ;
[0037] In the formula, is the segmentation loss function; is the semantic loss, is the parameter corresponding to the semantic loss; is the weighted binary cross entropy loss, is the corresponding parameter of weighted binary cross entropy loss; is the cross entropy loss, is the parameter corresponding to the cross entropy loss; is the boundary-aware cross entropy loss, is the parameter corresponding to the boundary-aware cross entropy loss.
[0038] Furthermore, the joint loss function in S4 is expressed as:
[0039] ;
[0040] In the formula, is the joint loss function, is the fusion loss function, is the weight of the fusion loss function, is the segmentation loss function.
[0041] Furthermore, the specific method of generating the joint loss function in S4 to guide the training and optimization of the image fusion network is:
[0042] S41, inputting an infrared image and a visible light image pair, and initializing the number of main loop iterations P and the number of sub-loop iterations p, q, j;
[0043] S42, performing p iterations of training, using a pixel intensity loss function including texture loss to train the teacher network and the student network, updating the parameters of the teacher network and the student network through an Adam optimizer, and transferring the knowledge parameters of the teacher network to the student network according to minimizing the knowledge distillation loss function;
[0044] S43, performing q iterations of training, updating the parameters of the discriminator using the discriminator adversarial loss function, and updating the parameters of the student network using the fusion loss function;
[0045] S44, performing j iterations of training, selecting multiple images from the fused images judged as true by the discriminator, updating the parameters of the real-time semantic segmentation model using the SGD optimizer, and extracting semantic information from the fused images;
[0046] S45. Repeat steps S41-S44 until all P total iterations are completed.
[0047] The present invention has the following beneficial effects:
[0048] (1) A knowledge distillation-based image fusion framework driven by semantic segmentation is proposed to effectively achieve infrared and visible light image fusion and meet the requirements of advanced visual tasks. The framework mainly consists of a distributed fusion architecture, which serves as a teacher network and a student network, two discriminators, and a semantic segmentation network.
[0049] (2) We designed a discriminator adversarial loss and used dual discriminators to further optimize the fusion network, so that the fusion network has better fusion performance. At the same time, we designed a joint training strategy to train the entire network, which helps to improve the performance of the fusion network and meet the needs of subsequent advanced visual tasks.
[0050] (3) A large number of experiments were conducted on multiple public datasets and compared with existing mainstream fusion methods. The experimental results show that the proposed fusion framework exhibits highly competitive fusion performance in terms of visual effects and objective evaluation indicators compared with existing fusion methods. In addition, the effectiveness of the proposed joint high-level visual task training fusion network strategy is further verified through segmentation comparison experiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] Figure 1 The figure is a flow chart of the infrared and visible light image fusion method for combined advanced vision tasks of the present invention.
[0052] Figure 2 Schematic diagram of the general model of the intermediate layer feature distillation pointed out in the embodiments of the present invention.
[0053] Figure 3 A schematic diagram of a feature vector conversion process for generating knowledge transfer according to an embodiment of the present invention.
[0054] Figure 4 Schematic diagram of the SD-net process of dual discriminator optimization according to an embodiment of the present invention.
[0055] Figure 5 Schematic diagram of the DIS architecture for image classification according to an embodiment of the present invention.
[0056] Figure 6 This is a visual diagram of the segmentation results of various fusion methods in a scene of an embodiment of the present invention.
[0057] Figure 7 This is a visual graph of the segmentation results of various fusion methods for another scenario in an embodiment of the present invention. DETAILED DESCRIPTION
[0058] The specific implementation modes of the present invention are described below so that those skilled in the art can understand the present invention. However, it should be clear that the present invention is not limited to the scope of the specific implementation modes. For those of ordinary skill in the art, as long as various changes are within the spirit and scope of the present invention as defined and determined by the attached claims, these changes are obvious, and all inventions and creations utilizing the concept of the present invention are protected.
[0059] A method for fusion of infrared and visible light images for joint high-level vision tasks, such as Figure 1 As shown, the following steps are included:
[0060] S1. Construct an image fusion network including a teacher network and a student network;
[0061] In this embodiment, the following steps are specifically included:
[0062] S11. Construct a teacher network, including a residual module for extracting features of input infrared and visible light, a multi-scale channel attention module for enhancing the perception of features at different scales, and a fusion layer for fusing features of infrared and visible light images;
[0063] S12. Compress the constructed teacher network, transfer the knowledge of the teacher network to the compressed teacher network by minimizing the knowledge distillation loss function, and complete the student network construction.
[0064] The student network is obtained by compressing the teacher network. This compression process is called knowledge transfer. Through knowledge transfer, the knowledge of the teacher network is transferred to the student network, so that the smaller student network has the ability of the teacher network. Figure 2 As shown in Figure 1, various intermediate layer features can be extracted from different positions and optimized by arbitrary distance metric similarity. Knowledge is transferred from the teacher model to the student model by minimizing the knowledge distillation (KD) loss function, which aims to match the soft output of the teacher network and the true label.
[0065] The knowledge transfer compression fusion network is used to achieve real-time image fusion and ensure that the student network SD-net is as stable as the teacher network TD-net. SD-net learns the high-dimensional features generated by the intermediate layer of TD-net. During the knowledge transfer process, the infrared image and the visible light image pair are input into TD-net and SD-net respectively, and a preliminary fusion network is obtained through training. The fusion network has a four-layer residual module for extracting image features. For the four-layer residual module of the student network to be optimized, the goal is to reduce the difference between the intermediate layer output features of the teacher network and the student network. The process can be expressed as follows:
[0066] ;
[0067] in, Refers to the features output by the Nth layer residual module of the teacher fusion network, Refers to the features output by the Nth layer residual module of the student fusion network, The difference between the output features of the intermediate layers of the teacher network and the student network.
[0068] If the intermediate layer output features of the teacher fusion network and the student fusion network are directly used to optimize the residual module of the student fusion network, a huge amount of calculation is required. Therefore, the intermediate layer features are processed into feature vectors for the knowledge transfer process. The operation of converting the intermediate layer features into feature vectors is as follows: Figure 3 As shown in the figure, the input features are the intermediate layer features output by the residual module of the teacher fusion network or the student fusion network, n=C means the number of filters in the convolution layer is C, the concatenation layer represents the connection operation, the activation function is the ReLu function, and the flattening layer converts the reduced-dimensional features into a one-dimensional feature vector. It is easy to use this one-dimensional feature vector for knowledge transfer, so the optimization problem is converted to the following formula:
[0069] ;
[0070] in, and They represent the feature vectors of the teacher network and the student network respectively after the intermediate layer features are processed.
[0071] In the process of knowledge transfer, considering that the intermediate layer features of the teacher network TD-net and the student network SD-net are different in content and size, and have the characteristics of spatial dislocation, but the feature vectors after feature vectorization are in the same spatial domain, the processing process is as follows Figure 3 To implement the knowledge transfer process, the distillation loss L is used. KD To achieve knowledge transfer from TD-net to SD-net, specifically:
[0072] ;
[0073] In the formula, To minimize the knowledge distillation loss function, is the b-th layer feature of the teacher network The projection function embedded into the spatial domain, The b-th layer features of the student network The projection function embedded into the same spatial domain as the teacher network, is the length of the feature vector, To sum the counts, Calculate the norm.
[0074] S2. Optimize and train the constructed image fusion network using the training method of the adversarial generative network;
[0075] Since the infrared and visible light image fusion task cannot obtain accurate real labels, rough training cannot make the fusion network have higher performance. In order to further optimize the student fusion network SD-net, this embodiment uses a dual discriminator (Dv, Dr) to play against the student fusion network to further train the fusion network. The process of dual discriminator optimizing SD-net is as follows: Figure 4 As shown in the figure, V and I refer to the real visible light image and the real infrared image respectively, and F is the fused image output by the student fusion network SD-net. D() refers to the classifier network DIS composed of convolution modules, and its structure is as follows: Figure 5 As shown in the figure, the convolution kernel size from the first to the fourth layer is set to 3, the activation function uses the Leaky ReLu function, and the number of input and output channels are 1:32, 32:64, 64:128 and 128:256 respectively. DIS is used to classify the input image as true or false. D(F), D(V) and D(I) represent the classification results of the fused image, the real visible light image and the real infrared image respectively. The specific method is as follows:
[0076] S21, using an image fusion network to receive input of a real infrared image and a real visible light image, and generate a preliminary fused image;
[0077] The student fusion network SD-net receives the input of infrared image and visible light image and generates a fused image F. This fused image attempts to combine the features of infrared and visible light images to generate an image that looks as real as possible.
[0078] S22, inputting the real infrared image, the real visible light image and the preliminary fusion image generated in S21 into two discriminators respectively to distinguish the authenticity of the input images;
[0079] S23, using the discriminator adversarial loss function to optimize the classification ability of the two discriminators;
[0080] The discriminators Dr and Dv receive the fused image F and the corresponding real images I and V and try to distinguish whether these images are real or fake. The discriminators continuously optimize their classification ability to improve the accuracy of distinguishing real images from fused images.
[0081] The introduction of dual discriminators is extremely important for further optimization of the student fusion network. To this end, two discriminators are used to train the discriminator to distinguish between real image data and fake image data. In addition, the dual discriminator can output the probability scalar of real image data or fake image data from the input end respectively. Among them, the adversarial loss of the dual discriminator is defined as:
[0082] ;
[0083] ;
[0084] In the formula, is the first discriminator adversarial loss function, The output result of the first discriminator is input as the real infrared image, is the real infrared image input to the first discriminator, The output result of the first discriminator is input to the preliminary fusion image. is the preliminary fusion image input to the first discriminator; is the adversarial loss function for the second discriminator, is the output result of the second discriminator for real visible light input, is the real visible light image input to the second discriminator, The output result of the second discriminator is input to the preliminary fusion image. is the preliminary fusion image input to the second discriminator; is the feature vector length, N is the number of input images, and the constant 1 indicates that we want the discriminator to believe that the fused image is a real image.
[0085] S24. Based on the S23 discriminator adversarial loss function, the teacher network and the student network are trained.
[0086] In order to encourage the fusion model to fuse more meaningful image information and improve the visual quality and quantitative indicators of the fused image, a pixel intensity loss function L containing texture loss is introduced. F The teacher fusion network and the student fusion network are trained separately. The loss function L F It is expressed as:
[0087] ;
[0088] Among them, L pixel is a texture loss function, which is used to constrain the fused image to contain more target intensity information of the source image; Ltexture is the pixel intensity loss function, which is used to constrain the fused image to contain more texture information of the source image, and a is the weight coefficient of the pixel intensity loss function.
[0089] L pixel By reducing the difference between the fused image and the infrared image and the visible light image pair, the fused image is constrained to contain more target information from the source image. pixel It is expressed as:
[0090] ;
[0091] Among them, m represents the training batch size, max() represents the maximization operation of elements at the same position, and I f ,I ir and I vis Represent the fused image, the input infrared image and the visible light image respectively, Count for summation.
[0092] L texture The texture details of the source image can be extracted, and the fused image is constrained to have rich texture details. texture It is expressed as:
[0093] ;
[0094] In the formula, is the Sobel gradient operator.
[0095] Since the student fusion network SD-net has a small number of parameters, rough training is not enough to make it have good fusion performance, so a dual discriminator is used to further optimize the student fusion network. The adversarial loss function used is defined as:
[0096] ;
[0097] In the formula, The output result of the first discriminator is input to the preliminary fusion image. The output result of the second discriminator is input to the preliminary fusion image. is a balancing parameter, N is the number of input images, and the constant 1 indicates that we want the discriminator to believe that the fused image is the real image.
[0098] Finally, the loss function L defined by the dual discriminator guides the student to integrate the network training process G It is expressed as:
[0099] ;
[0100] In the formula, is the fusion loss function; is the pixel intensity loss function; is the texture loss function, is the weight of texture loss function; is the image fusion adversarial loss function, is the weight of the image fusion adversarial loss function, is the corresponding weight.
[0101] S3, introducing the real-time semantic segmentation model into the optimized and trained image fusion network, segmenting the output image of the image fusion network and assisting the image fusion network in learning to retain the semantic information of the fused image;
[0102] The fusion architecture proposed in this embodiment introduces a real-time semantic segmentation model PIDNet, which is used to segment the output image of the student fusion network to assist the fusion network learning to retain more semantic information of the fusion image. Since the adaptation scenario of PIDNet is a complex urban road scene, which is consistent with the application target scenario of this chapter, it is practical to use PIDNet to assist in training the fusion network.
[0103] S4, calculating the segmentation loss function of the obtained semantic information, and using the segmentation loss function of the obtained semantic information to generate a joint loss function to guide the training and optimization of the image fusion network;
[0104] The segmentation loss Lseg used in this embodiment includes semantic loss , weighted binary cross entropy loss , CE loss and boundary-aware CE loss . Therefore, the segmentation loss function Lseg is expressed as:
[0105] ;
[0106] in, is the parameter corresponding to the semantic loss, is the parameter corresponding to the weighted binary cross entropy loss, is the parameter corresponding to the cross entropy loss, is the parameter corresponding to the boundary-aware cross entropy loss.
[0107] Finally, the joint loss function Ltotal constructed by optimizing the fusion network using the segmentation model is expressed as:
[0108] ;
[0109] in, Denotes the fusion loss L G The weight factor is set to 1.2 in this embodiment after preliminary parameter adjustment experiments.
[0110] Most task-driven low-level visual tasks can be divided into two ways: using pre-trained high-level task models to guide the training of low-level task models, and jointly training low-level task and high-level task models at the same stage. However, in the field of image fusion, it is often difficult to obtain effective real fusion images to train high-level visual task models, and the strategy of jointly training low-level and high-level tasks at the same stage may lead to an imbalance between low-level visual task models and high-level visual task models. This embodiment adopts a joint alternating iterative training method to optimize the entire network structure by iteratively training the fusion network, discriminator, and segmentation network. Specifically, first, the aforementioned loss function guides the training of different modules to obtain basic feature processing capabilities, and then the joint training strategy is used to optimize the overall network so that it can balance the visual tasks at different stages. The specific method is:
[0111] S41, input an infrared image and a visible light image pair, and initialize the main loop iteration number P and the sub-loop iteration number p, q, j.
[0112] S42, perform p iterations of training to train the teacher network (TD-net) and the student network (SD-net), use the loss function LF, and update the parameters of the teacher network (TD-net) and the student network (SD-net) through the Adam optimizer. This process enables the network to better extract features in the image. Then use the knowledge distillation loss function LbKD to further update the parameters of the student network (SD-net) through the Adam optimizer. The knowledge distillation loss function helps transfer the knowledge of the teacher network to the student network, so that the student network has the capabilities of the teacher network while maintaining a smaller scale.
[0113] S43, perform q iterations of training, use the discriminator loss functions LDr and LDv, and update the parameters of the two discriminators (Dr and Dv) through the Adam optimizer. The function of these two discriminators is to distinguish the generated fusion image from the real infrared image and visible light image. Then use the generator loss function LG to update the parameters of the student network (SD-net) through the Adam optimizer. This process enables the student network to generate fusion images that are closer to the real image, thereby confusing the discriminator.
[0114] S44, perform j iterations of training, and select several images from the fused images that are judged as true by the discriminators Dr and Dv. Use these images to update the parameters of the semantic segmentation network PIDNet through the SGD optimizer. The semantic segmentation loss guides the training and optimization of the fusion network so that the generated fusion image contains more semantic information, thereby better meeting the needs of subsequent advanced visual tasks.
[0115] S45. Repeat the above three sub-loop steps until all P total iterations are completed.
[0116] S5. Use the image fusion network trained and optimized in S4 to fuse the infrared and visible light images, and generate a fused image containing semantic information.
[0117] In order to evaluate whether the semantic information contained in the fused image is beneficial to subsequent high-level visual tasks, PIDNet is retrained on the MFNet dataset to evaluate the segmentation performance. The configuration of the training set and the test set refers to the official report of the MFNet dataset. The fused images generated by different fusion methods are input into the retrained PIDNet network, and the pixel intersection over union (IoU) is used to measure the segmentation performance. Table 1 shows the fused image segmentation results of each fusion method. It can be found that the proposed fusion framework has achieved the highest IoU in most categories and ranks first in mIoU (meanIntersection over Union). The fusion network can fuse the complementary feature information of most infrared and visible light images. This complementary information helps the segmentation model to understand the imaging scene more comprehensively, so the fused image can improve the segmentation performance. With the guidance of PIDNet's integrated semantic information and segmentation loss, the fused image can contain richer semantic information, enabling the segmentation network to describe the imaging scene more accurately.
[0118] Table 1. Fusion image segmentation results (mIoU) of each fusion method on the dataset MFNet
[0119]
[0120] In addition to the retrained model, The PIDNet trained on the above is used to measure the contribution of the fusion results of different fusion methods to the segmentation task. The fusion results of each fusion method are input into the PIDNet model for segmentation. The visualization results are shown in Figure 2. Figure 6 and Figure 7 As shown. Figure 6 It can be found that the KDGFNet proposed in this section makes full use of the information of infrared images, provides more information about prominent targets such as pedestrians, and also provides relatively rich background descriptions, but its segmentation effect on buildings is inferior to NestFuse. Figure 7 In the segmentation results, it can be clearly observed that the road signs and pedestrian targets in the figure are well segmented, indicating that KDGFNet has better segmentation effects than other fusion methods in both foreground and background.
[0121] The infrared and visible light image fusion framework proposed in this embodiment introduces segmentation loss, which can improve the semantic information in the fused image. In order to verify the impact of segmentation loss on the fusion result, an ablation experiment was designed to directly remove the segmentation loss and optimize the fusion model only by the fusion loss to compare the impact of segmentation loss on the model capability. Table 2 shows the various fusion evaluation indicators of the fusion model trained only with fusion loss and the fusion model guided by the joint alternating iterative training strategy on the MFNet and RoadScene datasets. It can be noted that without the guidance of segmentation loss, the fusion network cannot purposefully retain the semantic information of the source image, resulting in a significant decrease in the evaluation indicators of the fused image.
[0122] Table 2 Comparison of fusion performance of different training strategies
[0123]
[0124] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0125] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0126] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0127] The present invention uses specific embodiments to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
[0128] Those skilled in the art will appreciate that the embodiments described herein are intended to help readers understand the principles of the present invention, and should be understood that the protection scope of the present invention is not limited to such specific statements and embodiments. Those skilled in the art can make various other specific variations and combinations that do not deviate from the essence of the present invention based on the technical revelations disclosed by the present invention, and these variations and combinations are still within the protection scope of the present invention.
Claims
1. A method for combining infrared and visible light image fusion for advanced visual tasks, characterized in that: The steps include: S1. Construct an image fusion network including a teacher network and a student network; S2. Optimize and train the constructed image fusion network using the training method of the adversarial generative network, including the following steps: S21, using an image fusion network to receive input of a real infrared image and a real visible light image, and generate a preliminary fused image; S22, inputting the real infrared image, the real visible light image and the preliminary fusion image generated in S21 into two discriminators respectively to distinguish the authenticity of the input images; S23. Use the discriminator adversarial loss function to optimize the classification ability of the two discriminators. The discriminator adversarial loss function is expressed as: ; ; In the formula, is the first discriminator adversarial loss function, The output result of the first discriminator is input as the real infrared image, is the real infrared image input to the first discriminator, The output result of the first discriminator is input to the preliminary fusion image. is the preliminary fusion image input to the first discriminator; is the adversarial loss function for the second discriminator, is the output result of the second discriminator for real visible light input, is the real visible light image input to the second discriminator, The output result of the second discriminator is input to the preliminary fusion image. is the preliminary fusion image input to the second discriminator; is the feature vector length, N is the number of input images, and the constant 1 indicates that the discriminator is expected to believe that the fused image is a real image; S24, based on the S23 discriminator adversarial loss function, guide the teacher network and the student network to train, the specific method is: ; In the formula, is the fusion loss function; is the pixel intensity loss function; is the texture loss function, is the weight of texture loss function; is the image fusion adversarial loss function, is the weight of the image fusion adversarial loss function; where: ; Where m is the training batch size, max() is the maximization operation of elements at the same position, and I f ,I ir and I vis They are the fused image, the input infrared image, and the input visible light image. To sum the count; ; In the formula, is the Sobel gradient operator; ; In the formula, The output result of the first discriminator is input to the preliminary fusion image. The output result of the second discriminator is input to the preliminary fusion image. is a balancing parameter, N is the number of input images, and the constant 1 indicates that the discriminator is expected to believe that the fused image is the real image; S3, introducing the real-time semantic segmentation model into the optimized trained image fusion network, segmenting the output image of the image fusion network and assisting the image fusion network to learn and retain the semantic information of the fused image; S4, calculating the segmentation loss function of the obtained semantic information, and using the segmentation loss function of the obtained semantic information to generate a joint loss function to guide the training and optimization of the image fusion network; S5. Use the image fusion network trained and optimized in S4 to fuse infrared and visible light images to generate a fused image containing semantic information.
2. The infrared and visible light image fusion method for joint advanced visual tasks according to claim 1 is characterized in that: The S1 specifically includes the following steps: S11. Construct a teacher network, including a residual module for extracting features of input infrared and visible light, a multi-scale channel attention module for enhancing the perception of features at different scales, and a fusion layer for fusing features of infrared and visible light images; S12. Compress the constructed teacher network, transfer the knowledge of the teacher network to the compressed teacher network by minimizing the knowledge distillation loss function, and complete the student network construction.
3. The infrared and visible light image fusion method for joint advanced visual tasks according to claim 2 is characterized in that: The loss function for minimizing the knowledge distillation in S12 is expressed as: ; In the formula, To minimize the knowledge distillation loss function, is the b-th layer feature of the teacher network The projection function embedded into the spatial domain, The b-th layer features of the student network The projection function embedded into the same spatial domain as the teacher network, is the length of the feature vector, To sum the counts, Calculate the norm.
4. The infrared and visible light image fusion method for joint advanced visual tasks according to claim 1 is characterized in that: The segmentation loss function in S4 is expressed as: ; In the formula, is the segmentation loss function; is the semantic loss, is the parameter corresponding to the semantic loss; is the weighted binary cross entropy loss, is the corresponding parameter of weighted binary cross entropy loss; is the cross entropy loss, is the parameter corresponding to the cross entropy loss; is the boundary-aware cross entropy loss, is the parameter corresponding to the boundary-aware cross entropy loss.
5. The infrared and visible light image fusion method for joint advanced visual tasks according to claim 1 is characterized in that: The joint loss function in S4 is expressed as: ; In the formula, is the joint loss function, is the fusion loss function, is the weight of the fusion loss function, is the segmentation loss function.
6. The infrared and visible light image fusion method for joint advanced visual tasks according to claim 1 is characterized in that: The specific method of generating the joint loss function in S4 to guide the training and optimization of the image fusion network is: S41, inputting an infrared image and a visible light image pair, and initializing the number of main loop iterations P and the number of sub-loop iterations p, q, j; S42, performing p iterations of training, using a pixel intensity loss function including texture loss to train the teacher network and the student network, updating the parameters of the teacher network and the student network through an Adam optimizer, and transferring the knowledge parameters of the teacher network to the student network according to minimizing the knowledge distillation loss function; S43, performing q iterations of training, updating the parameters of the discriminator using the discriminator adversarial loss function, and updating the parameters of the student network using the fusion loss function; S44, performing j iterations of training, selecting multiple images from the fused images judged as true by the discriminator, updating the parameters of the real-time semantic segmentation model using the SGD optimizer, and extracting semantic information from the fused images; S45. Repeat steps S41-S44 until all P total iterations are completed.
