Image super-resolution method based on spatial spectrum interaction Transform network

Through the image super-resolution method based on the spatial-spectral interactive Transformer network and combining spatial and spectral information, the problem of Transformer's poor performance in medical image super-resolution is solved, and efficient image super-resolution task performance is achieved.

CN118710499APending Publication Date: 2024-09-27ANHUI UNIV
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410911869.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-09
Publication Date
2024-09-27

AI Technical Summary

Technical Problem

It is difficult for Transformer to take into account both spatial and spectral information in medical image super-resolution, resulting in poor application results.

Method used

The image super-resolution method based on the spatial-spectral interactive Transformer network is used to perform feature extraction and reconstruction through the shallow feature extraction unit, deep feature extraction unit and high-resolution reconstruction unit, combined with the spatial Transformer and spectral Transformer, and fuse spatial and spectral information.

Benefits of technology

Improves the performance of image super-resolution tasks, generates features with short-range and long-range context, and achieves excellent image super-resolution results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118710499A
    Figure CN118710499A
Patent Text Reader

Abstract

The invention provides an image super-division method based on a spatial spectrum interaction Transform network. The method comprises the following steps: obtaining a first image to be super-divided; utilizing a shallow layer feature extraction unit of the trained spatial spectrum interaction Transform network to extract shallow layer features of the first image; utilizing a deep feature extraction unit of the trained spatial spectrum interaction Transform network to extract deep features of the shallow features; and processing the deep features by using a high-resolution reconstruction unit of the trained spatial spectrum interaction Transform network so as to obtain a second image after super-division. According to the method, shallow layer features are extracted through a shallow layer feature extraction unit, acquisition of local information is enhanced in spatial spectrum information interaction through a deep layer feature extraction unit, feature pairs with short-distance and remote contexts are generated, and the feature representation capability is further improved; and finally, feature fusion and reconstruction are carried out on the information of the two levels through a high-resolution reconstruction unit, so that excellent image super-division task performance is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing technology, and in particular to an image super-resolution method based on a space-spectrum interactive Transformer network. Background Art

[0002] Image super-resolution (SR) refers to the process of upgrading low-resolution images to high-resolution through algorithms and technologies. Image super-resolution can significantly improve the visual quality of images, making details clearer and more recognizable. In medical research, medical images such as CT and MRI are produced through rays or magnetic fields, so the resolution is limited. Super-resolution technology can help doctors or researchers more accurately analyze microscopic details such as cell structures and lesion areas, thereby improving the accuracy of diagnosis and the depth of scientific discovery.

[0003] Recently, Transformer has gained considerable popularity in fields including image super-resolution. These Transformer-based networks use self-attention along different dimensions, spaces, or channels and have achieved impressive performance. However, compared with ordinary images, medical images have more bands, and it is difficult for Transformer to take into account both spatial and spectral information at the same time, which greatly limits the application of Transformer in medical image super-resolution. Summary of the invention

[0004] In view of the above defects of the prior art, the present invention provides an image super-resolution method based on a spatial-spectral interactive Transformer network to solve the technical problem that the Transformer has a poor effect in image super-resolution.

[0005] To achieve the above-mentioned purpose and other related purposes, the present invention provides an image super-resolution method based on a spatial-spectral interaction Transformer network, comprising the following steps: obtaining a first image to be super-resolved; using a shallow feature extraction unit of a trained spatial-spectral interaction Transformer network to extract shallow features of the first image; using a deep feature extraction unit of the trained spatial-spectral interaction Transformer network to extract deep features of the shallow features; using a high-resolution reconstruction unit of the trained spatial-spectral interaction Transformer network to process the deep features to obtain a super-resolved second image.

[0006] In one embodiment of the present invention, the shallow feature extraction unit is expressed by the formula: s =Conv(Reshape(X LR )), where X LRis the first image, X s is the shallow feature, Reshape() is a function used to change the size of the feature map, and Conv() is a convolution operation.

[0007] In one embodiment of the present invention, the deep feature extraction unit is formed by cascading multiple spatial-spectral interactive Transformer modules, and the deep feature extraction unit is expressed by the formula: d =X s +M D (M D-1 (…M1(X s )+X s …)+X s ), where X d is the deep feature, M i () represents the i-th spatial-spectral interactive Transformer module.

[0008] In one embodiment of the present invention, the spatial-spectral interaction Transformer module includes a spatial Transformer, a spectral Transformer, a spatial interaction unit and a spectral interaction unit. The spatial-spectral interaction Transformer module processes the input features in the following steps: using the spatial Transformer and the spectral Transformer to process the input features respectively to obtain spatial self-attention features and spectral self-attention features; using the spatial interaction unit to process the spatial self-attention features, and guide the spectral self-attention features to obtain spectral dimension output; using the spectral interaction unit to process the spectral self-attention features, and guide the spatial self-attention features to obtain spatial dimension output; fusing the spatial dimension output and the spectral dimension output to obtain the output features of the spatial-spectral interaction Transformer module.

[0009] In one embodiment of the present invention, the spatial Transformer is expressed by the formula: In the formula, Q S , K S 、V S They are respectively the query matrix, keyword matrix and value matrix generated by linear projection on the input features. K S The transpose of k is the variance, softmax() is the normalization operation, Y Spa is the spatial self-attention feature.

[0010] In one embodiment of the present invention, the spatial interaction unit is expressed by the formula: OUTSpaIU =Sig(Conv(GELU(Conv(X in1 )))),where X in1 Represents the input features of the spatial interaction unit, Conv() is the convolution operation, GELU is the activation function, Sig() is the Sigmoid function, OUT SpaIU is output for the spatial dimension.

[0011] In one embodiment of the present invention, the spectral transformer is expressed by the formula: In the formula, Q C , K C 、V C The query matrix, keyword matrix and value matrix are generated by linear projection on the input features and reconstructed as A matrix of size, is the transpose of QC, α is a learnable parameter, softmax() is a normalization operation, and Y Spe is the spectral self-attention feature.

[0012] In one embodiment of the present invention, the spectrum interaction unit is expressed by the formula: OUT SpeIU =Sig(Conv(GELU(Conv(Gap(X in2 )))))), where X in2 represents the input features of the spectral interaction unit, Gap() is the global pooling operation, Conv() is the convolution operation, GELU is the activation function, Sig() is the Sigmoid function, OUT SpaIU is output for the spatial dimension.

[0013] In one embodiment of the present invention, the high-resolution reconstruction unit is expressed by the formula: HR =Reshape(Conv(Upsampling(X S +X d ))), where Upsampling() is the upsampling operation, and the scale factor during upsampling is the width and height magnification ratio of the super-resolution image.

[0014] In one embodiment of the present invention, the spatial-spectral interactive Transformer network has a loss function L during training. total Calculated using the following formula: λ1+λ2=1, where λ1 and λ2 are weight coefficients, and N is the total number of samples in each batch. is the real image corresponding to the training sample, is the super-resolution result of the network, ||||1 represents the L1 norm, and ||||2 represents the L2 norm.

[0015] Beneficial effects of the present invention: The present invention proposes an image super-resolution method based on a spatial-spectral interactive Transformer network. The method extracts shallow features through a shallow feature extraction unit. The deep feature extraction unit strengthens the acquisition of local information in the spatial-spectral information interaction and generates feature pairs with short-range and long-range contexts, further improving the feature representation capability. Finally, the two levels of information are feature-fused and reconstructed through a high-resolution reconstruction unit, thereby achieving excellent image super-resolution task performance. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0017] Figure 1 A structural diagram of a spatial-spectral interactive Transformer network provided in one embodiment of the present invention;

[0018] Figure 2 A structural diagram of a spatial-spectral interactive Transformer module provided in one embodiment of the present invention;

[0019] Figure 3 A structural diagram of a spatial Transformer provided in one embodiment of the present invention;

[0020] Figure 4 A structural diagram of a space interaction unit provided by an embodiment of the present invention;

[0021] Figure 5 A structural diagram of a spectral transformer provided in one embodiment of the present invention;

[0022] Figure 6 A structural diagram of a spectrum interaction unit provided in one embodiment of the present invention;

[0023] Figure 7 A flow chart of a training method provided in accordance with an embodiment of the present invention. DETAILED DESCRIPTION

[0024] The following describes the embodiments of the present invention through specific specific embodiments, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. It should be noted that the following embodiments and the features in the embodiments can be combined with each other without conflict. In addition to the specific methods, equipment, and materials used in the embodiments, according to the technical personnel in this technical field's grasp of the prior art and the records of the present invention, any methods, equipment, and materials of the prior art that are similar or equivalent to the methods, equipment, and materials described in the embodiments of the present invention can also be used to implement the present invention.

[0025] It should be understood that the terms used in the embodiments of the present invention are for describing specific embodiments rather than for limiting the scope of protection of the present invention. Unless otherwise defined, all technical and scientific terms used in the present invention have the same meaning as those generally understood by those skilled in the art.

[0026] In the following description, numerous details are discussed to provide a more thorough explanation of the embodiments of the present invention. However, it is obvious to those skilled in the art that the embodiments of the present invention can be implemented without these specific details. In some of the embodiments, well-known structures and devices are shown in the form of block diagrams rather than in detail to avoid making the embodiments of the present invention difficult to understand.

[0027] The flowchart and block diagram in the accompanying drawings illustrate the system architecture, functions and operations that may be implemented according to the methods and computer program products of various embodiments disclosed in the present invention. In this regard, each box in the flowchart or block diagram can represent a module, a program segment, or a part of a code, and the module, the program segment, or a part of the code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or the flowchart, and the combination of the boxes in the block diagram and / or the flowchart can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0028] See also Figure 1 , Figure 1A structural diagram of a spatial-spectral interactive Transformer network provided for one embodiment of the present invention. Based on the network, images can be super-resolved (i.e., super-resolution), and the specific super-resolution steps are as follows: obtaining a first image to be super-resolved; extracting shallow features of the first image using a shallow feature extraction unit of a trained spatial-spectral interactive Transformer network; extracting deep features of the shallow features using a deep feature extraction unit of a trained spatial-spectral interactive Transformer network; and processing the deep features using a high-resolution reconstruction unit of a trained spatial-spectral interactive Transformer network to obtain a super-resolved second image.

[0029] The first image to be super-resolved is X LR Indicates that the second image after super resolution is represented by X HR Indicates that the above process can be expressed by the formula:

[0030] X HR =H RC (H SF (X LR )+H DF (H SF (X LR ))),

[0031] In the formula, H SF (), H DF (), H RC () represent the functions of shallow feature extraction unit, deep feature extraction unit and high-resolution reconstruction unit respectively.

[0032] This method extracts shallow features through a shallow feature extraction unit, and the deep feature extraction unit strengthens the acquisition of local information in the interaction of spatial spectral information and generates feature pairs with short-range and long-range contexts to further improve the feature representation capability. Finally, the two levels of information are fused and reconstructed through a high-resolution reconstruction unit, thereby achieving excellent image super-resolution task performance.

[0033] In a specific embodiment of the present invention, the shallow feature extraction unit is expressed by the formula:

[0034] X s =Conv(Reshape(X LR )),

[0035] Where, X LR is the first image, X s It is a shallow feature, Reshape() is a function used to change the size of the feature map, and Conv() is a convolution operation. The shallow feature extraction unit here is composed of Reshape and a single 3×3 convolution to extract the local features of the image to be super-resolved.

[0036] In a specific embodiment of the present invention, the deep feature extraction unit is formed by cascading multiple spatial-spectral interactive Transformer modules (ie, SSITB), and the deep feature extraction unit is expressed by the formula:

[0037] X d =X s +M D (M D-1 (…M1(X s )+X s …)+X s ),

[0038] Where, X d is the deep feature, M i () represents the i-th spatial-spectral interactive Transformer module. The feature M output by the i-th spatial-spectral interactive Transformer module i () need to be added to the shallow feature Xs and then input into the i+1th spatial-spectral interactive Transformer module.

[0039] The number of spatial-spectral interaction Transformer modules is greater than or equal to 2. For different types of images to be super-resolved, the number may be different. The specific value can be selected based on the actual situation to select the best number. For example, multiple spatial-spectral interaction Transformer networks containing different numbers of spatial-spectral interaction Transformer modules can be trained, and then the one with the best effect can be selected.

[0040] See also Figure 2 In a specific embodiment of the present invention, the spatial-spectral interactive Transformer module includes a spatial Transformer (i.e. Figure 2 SpaTB in ), spectral Transformer (i.e. Figure 2 SpeTB in the spatial interaction unit (i.e. Figure 2 Spa-IU in the Figure 2The spatial-spectral interactive Transformer module processes the input features according to the following steps: the input features are processed by the spatial Transformer and the spectral Transformer respectively to obtain the spatial self-attention features and the spectral self-attention features; the spatial self-attention features are processed by the spatial interaction unit, and the spectral self-attention features are guided to obtain the spectral dimension output; the spectral self-attention features are processed by the spectral interaction unit, and the spatial self-attention features are guided to obtain the spatial dimension output; the spatial dimension output and the spectral dimension output are fused to obtain the output features of the spatial-spectral interactive Transformer module.

[0041] In this embodiment, the spatial-spectral interaction transformer module is composed of a spatial transformer and a spectral transformer in parallel. The spatial transformer and the spectral transformer are based on spatial self-attention and spectral self-attention respectively. By connecting the spatial transformer and the spectral transformer in parallel, the spatial-spectral interaction transformer module can realize the aggregation of elements between the spatial dimension and the spectral dimension. And when the spatial transformer and the spectral transformer generate outputs, the spatial interaction unit and the spectral interaction unit will input valuable spectral dimension and spatial dimension information respectively.

[0042] In a specific embodiment of the present invention, the spatial-spectral interactive Transformer module also includes operations such as a linear projection layer LN, a multi-layer perceptron MLP, and a convolutional layer. Its specific structure is as follows: Figure 2 As shown, I will not go into details here.

[0043] See also Figure 3 In a specific embodiment of the present invention, the spatial Transformer is expressed by the formula:

[0044]

[0045] In the formula, Q S , K S 、V S They are respectively the query matrix, keyword matrix and value matrix generated by linear projection on the input features. K S The transpose of k is the variance, softmax() is the normalization operation, Y Spa is the spatial self-attention feature. For a given input Q S , K S、V S The formulas are respectively expressed as: Q S =XW Q , K S =XW K , V S =XW V ,in, is the linear projection with the deviation omitted. Figure 3 In the convolution layer, Con v , linear projection layer Linear, normalization operation Norm and Reshape function.

[0046] See also Figure 4 In a specific embodiment of the present invention, the spatial interaction unit is expressed by the formula:

[0047] OUT SpaIU =Sig(Conv(GELU(Conv(X in1 )))),

[0048] Where, X in1 Represents the input features of the spatial interaction unit, Conv() is the convolution operation, GELU is the activation function, Sig() is the Sigmoid function, OUT SpaIU is the spatial dimension output. The spatial interaction unit is used to process the spatial self-attention features in order to guide the spectral attention to utilize valuable spatial information.

[0049] See also Figure 5 In a specific embodiment of the present invention, the spectral transformer is expressed by the formula:

[0050]

[0051] In the formula, Q C , K C 、V C The query matrix, keyword matrix and value matrix are generated by linear projection on the input features and reconstructed as A matrix of size, Q C is the transpose of , α is a learnable parameter, softmax() is a normalization operation, Y Spe is the spectral self-attention feature. The spectral Transformer is performed along the spectral dimension. For a given input X, the query matrix Q can be obtained. C , keyword matrix K C Sum value matrix V C .

[0052] See also Figure 6In a specific embodiment of the present invention, the spectrum interaction unit is expressed by the formula:

[0053] OUT SpeIU =Sig(Conv(GELU(Conv(Gap(X in2 ))))),

[0054] Where, X in2 Represents the input features of the spectral interaction unit, Gap() is the global pooling operation, Conv() is the convolution operation, GELU is the activation function, Sig() is the Sigmoid function, OUT SpaIU Output is the spatial dimension.

[0055] For the above four expressions, the spatial dimension output and spectral dimension output can be expressed as:

[0056] Y SSTIB-Spa =Y Spa *OUT SpeIU ,

[0057] Y SSTIB-Spe =Y Spe *OUT SpaIU ,

[0058] Finally, the spatial dimension output of SSTIB is combined with the spectral dimension output to obtain spatial-spectral aggregation information.

[0059] In a specific embodiment of the present invention, the high-resolution reconstruction unit is expressed by the formula:

[0060] X HR =Reshape(Conv(Upsampling(X S +X d ))),

[0061] In the formula, Upsampling() is the upsampling operation, the scale factor during upsampling is the ratio of the width and height of the super-resolution image, Conv() is the convolution operation, and Reshape() is the function used to change the size of the feature map. Finally, the size of the output super-resolution image becomes B×sH×sW.

[0062] See also Figure 7 Before using the spatial-spectral interactive Transformer network, you need to build the network first and then train it. The training samples can be constructed as follows: obtain high-resolution HR images, downsample the HR images to obtain low-resolution LR images, then use the LR-HR images as training samples, and use the training samples to train the network.

[0063] During the training process, the loss function is used to calculate the super-resolution result X SR With the real data X HR The error between them is calculated and the back propagation method is used to optimize the network parameters until the training is completed. When the network training is completed, it is very convenient to super-resolve the image later. You only need to input the image to be super-resolved into the trained network, and the network will automatically output the super-resolved image.

[0064] In a specific embodiment of the present invention, the loss function L of the spatial-spectral interactive Transformer network during training total Calculated using the following formula:

[0065] L total =λ1L1+λ2L spe ,

[0066]

[0067] λ1+λ2=1,

[0068] In the formula, λ1 and λ2 are weight coefficients, N is the total number of samples in each batch, is the real image corresponding to the training sample (i.e., the high-resolution image when constructing the training sample), is the super-resolution result of the network. The superscripts in the loss function formula are used to indicate the correspondence between the super-resolution result and the true super-resolution image. ||||1 represents the L1 norm, and ||||2 represents the L2 norm.

[0069] The L1 loss function is widely used in super-resolution tasks, but it ignores the special patterns in hyperspectral data, resulting in spectral distortion. Therefore, the spectral measurement loss L is also introduced in this embodiment. spe to constrain the spectral structure, and use the weighted sum of the two losses as the final loss function.

[0070] The effect of the present invention is further described below in conjunction with experiments.

[0071] 1. Experimental conditions:

[0072] The computer hardware environment of the experiment of the present invention is GTX3090GPU, the compilation environment is PyCharm, and the deep learning framework is PyTorch; all subsequent training and testing are based on this platform. The present invention uses the Cave dataset as a training set and a validation set. The Cave dataset includes daily objects in 32 scenes, with a spatial size of 512×512, including 31 spectral bands from 400nm to 700nm, and a step size of 10nm. In order to prepare training samples, we randomly selected 20 images from the database as training sets (10% of the samples were randomly selected from the training set for verification), and the rest were used as tests. For example, the bicubic interpolation method can be used to downsample a high-resolution image to obtain a corresponding low-resolution image. Specifically, when the upsampling factor d is 4, the extracted image size is 64×64 pixels (with 32 pixel overlaps); when the upsampling factor d is 8, the extracted image size is 128×128 pixels (with 64 pixel overlaps).

[0073] 2. Super-resolution evaluation indicators:

[0074] In order to evaluate the super-resolution performance of the super-resolution method of the present invention, the present invention uses three evaluation indicators, namely Peak Signal to Noise Ratio (PSNR), Structural Similarity (SSIM) and Spectral Angle Mapper (SAM), to evaluate the super-resolution results.

[0075] PSNR is an objective evaluation index for evaluating images, and its expression is as follows:

[0076]

[0077] Among them, MAX refers to the maximum value of the color of the image point, and MSE represents I SR The corresponding I HR However, the PSNR value is not consistent with the visual quality of the naked eye. To overcome this shortcoming, we also use SSIM to evaluate the super-resolution results. SSIM divides the distortion modeling into a combination of three different factors: brightness, contrast, and structure. Its expression is as follows:

[0078] SSIM(x,y)=[l(x,y)] α [c(x,y)] β [s(x,y)] γ ,

[0079]

[0080] Among them, l(x, y) represents the image brightness comparison, c(x, y) represents the image contrast comparison, s(x, y) represents the image structure comparison, μ represents the mean, σ represents the standard deviation, and σ xy Represents covariance, c1, c2 and c 3 is a constant used to maintain stability, calculated by the following formula: c1 = (k1L) 2 , c2=(k2L) 2 . Where L is the maximum pixel value in the image, k1 = 0.01, k2 = 0.03. In practical applications, we often use the simplified SSIM formula:

[0081]

[0082] The SAM algorithm treats the spectrum of each pixel in the image as a high-dimensional vector, and measures the similarity between spectra by calculating the angle between two vectors. The smaller the angle, the more similar the two spectra are, and the greater the possibility that they belong to the same type of objects. Therefore, the category of unknown data can be identified based on the size of the spectral angle. During classification, the spectral angle between the unknown data and the known data is calculated, and the category of the unknown data is classified into the category corresponding to the minimum spectral angle.

[0083]

[0084] Where Y is the given target vector and X is the vector to be measured.

[0085] 3. Experimental content and results analysis:

[0086] Comparison with state-of-the-art methods on the Cave dataset. We use bicubic interpolation (Bicubic) as the benchmark and compare the proposed model SSITB with eight other super-resolution models (VDSR, EDSR, GDRNN, 3DFCNN, SSPSR and RFSR) at ×4 and ×8 super-resolution sizes. The comparison results are shown in Table 1, where the best results are in bold and the second best are underlined.

[0087] Table 1: Comparison with state-of-the-art methods on the Cave dataset

[0088] method scale PSNR↑ SSIM↑ SAM↓ Bicubic ×4 36.1512 0.9498 3.4871 VDSR ×4 38.3049 0.9642 3.1355 EDSR ×4 39.0905 0.9674 3.1651 GDRNN ×4 38.4440 0.9638 2.9282 3DFCNN ×4 38.2389 0.9629 3.1747 SSPSR ×4 39.3413 0.9686 2.8397 RFSR ×4 40.0136 0.9735 2.6694 SSITN(ours) ×4 40.0715 0.9737 2.5208 Bicubic ×8 31.6647 0.8886 4.9947 VDSR ×8 32.7395 0.8986 4.8864 EDSR ×8 34.1514 0.9106 4.9694 GDRNN ×8 32.6542 0.8948 4.6812 3DFCNN ×8 32.4715 0.9038 4.9363 SSPSR ×8 34.4085 0.9145 4.3509 RFSR ×8 34.8724 0.9256 4.1465 SSITN(ours) ×8 34.9624 0.9344 4.0125

[0089] From the quantitative comparison results in Table 1, it can be seen that the method proposed in the present invention uses a more flexible method to process the spatial information and spectrum in the image, and achieves the best super-resolution results in all cases, which proves the advantage of our proposed model in the image super-resolution task.

[0090] The above embodiments are merely illustrative of the principles and effects of the present invention, and are not intended to limit the present invention. Anyone familiar with the art may modify or alter the above embodiments without departing from the spirit and scope of the present invention. Therefore, all equivalent modifications or alterations made by a person of ordinary skill in the art without departing from the spirit and technical concept disclosed by the present invention shall still be covered by the claims of the present invention.

Claims

1. An image super-resolution method based on a spatial-spectral interactive Transformer network, characterized in that: The steps include: Acquire a first image to be super-resolved; Extracting shallow features of the first image using a shallow feature extraction unit of a trained spatial-spectral interactive Transformer network; Utilizing the deep feature extraction unit of the trained spatial-spectral interactive Transformer network to extract deep features of the shallow features; The deep features are processed using a high-resolution reconstruction unit of the trained spatial-spectral interactive Transformer network to obtain a super-resolved second image.

2. The image super-resolution method based on the spatial-spectral interactive Transformer network according to claim 1 is characterized in that: The shallow feature extraction unit is expressed by the formula: X s =Conv(Reshape(X LR )), Where, X LR is the first image, X s is the shallow feature, Reshape() is a function used to change the size of the feature map, and Conv() is a convolution operation.

3. The image super-resolution method based on the spatial-spectral interactive Transformer network according to claim 2 is characterized in that: The deep feature extraction unit is formed by cascading multiple spatial-spectral interactive Transformer modules, and the deep feature extraction unit is expressed by the formula: X d =X s +M D (M D-1 (...M1(X s )+X s ...)+X s ), Where, X d is the deep feature, M i () represents the i-th spatial-spectral interactive Transformer module.

4. The image super-resolution method based on the spatial-spectral interactive Transformer network according to claim 3 is characterized in that: The spatial-spectral interaction Transformer module includes a spatial Transformer, a spectral Transformer, a spatial interaction unit, and a spectral interaction unit. The spatial-spectral interaction Transformer module processes the input features according to the following steps: The spatial Transformer and the spectral Transformer are used to process the input features respectively to obtain spatial self-attention features and spectral self-attention features; The spatial self-attention feature is processed by the spatial interaction unit, and the spectral self-attention feature is guided to obtain a spectral dimension output; The spectral self-attention feature is processed by the spectral interaction unit, and the spatial self-attention feature is guided to obtain a spatial dimension output; The spatial dimension output and the spectral dimension output are fused to obtain the output features of the spatial-spectral interactive Transformer module.

5. The image super-resolution method based on the spatial-spectral interactive Transformer network according to claim 4 is characterized in that: The spatial Transformer is expressed by the formula: In the formula, Q S , K S 、V S They are respectively the query matrix, keyword matrix and value matrix generated by linear projection on the input features. K S The transpose of k is the variance, softmax() is the normalization operation, Y Spa is the spatial self-attention feature.

6. The image super-resolution method based on the spatial-spectral interactive Transformer network according to claim 5, characterized in that: The spatial interaction unit is expressed by the formula: OUT SpaIU =Sig(Conv(GELU(Conv(X in1 )))), Where, X in1 Represents the input features of the spatial interaction unit, Conv() is the convolution operation, GELU is the activation function, Sig() is the Sigmoid function, OUT SpaIU is output for the spatial dimension.

7. The image super-resolution method based on the spatial-spectral interactive Transformer network according to claim 4, characterized in that: The spectral transformer is expressed by the formula: In the formula, Q C , K C 、V C The query matrix, keyword matrix and value matrix are generated by linear projection on the input features and reconstructed as A matrix of size, Q C is the transpose of , α is a learnable parameter, softmax() is a normalization operation, Y Spe is the spectral self-attention feature.

8. The image super-resolution method based on the spatial-spectral interactive Transformer network according to claim 7, characterized in that: The spectral interaction unit is expressed by the formula: OUT SpeIU =SIg(Conv(GELU(Conv(Gap(X in2 ))))), Where, X in2 represents the input features of the spectral interaction unit, Gap() is the global pooling operation, Conv() is the convolution operation, GELU is the activation function, Sig() is the Sigmoid function, OUT SpaIU is output for the spatial dimension.

9. The image super-resolution method based on spatial-spectral interactive Transformer network according to claim 3, characterized in that: The high-resolution reconstruction unit is expressed by the formula: X HR =Reshape(Conv(Upsampling(X S +X d ))), In the formula, Upsampling() is the upsampling operation, and the scale factor during upsampling is the width and height magnification ratio of the super-resolution image.

10. The image super-resolution method based on spatial-spectral interactive Transformer network according to claim 1, characterized in that: The spatial-spectral interaction Transformer network has a loss function L during training. total Calculated using the following formula: L total =λ1L1+λ2L spe , λ1+λ2=1, In the formula, λ1 and λ2 are weight coefficients, N is the total number of samples in each batch, is the real image corresponding to the training sample, is the super-resolution result of the network, ||||1 represents the L1 norm, and ||||2 represents the L2 norm.

Citation Information

Cited By

  • Transform image super-division method based on cross-dimension

    CN120163712A