[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Next Article in Journal
Robust Wideband Interference Suppression Method for GNSS Array Antenna Receiver via Hybrid Beamforming Technique
Next Article in Special Issue
Two-Stage Adaptive Network for Semi-Supervised Cross-Domain Crater Detection under Varying Scenario Distributions
Previous Article in Journal
Estimation of Biochemical Compounds in Tradescantia Leaves Using VIS-NIR-SWIR Hyperspectral and Chlorophyll a Fluorescence Sensors
Previous Article in Special Issue
Identification of Rare Wildlife in the Field Environment Based on the Improved YOLOv5 Model
You seem to have javascript disabled. Please note that many of the page functionalities won't work as expected without javascript enabled.
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Adaptive Learnable Spectral–Spatial Fusion Transformer for Hyperspectral Image Classification

1
College of Information and Communication Engineering, Harbin Engineering University, Harbin 150001, China
2
Key Laboratory of Advanced Ship Communication and Information Technology, Harbin Engineering University, Harbin 150001, China
3
Agile and Intelligent Computing Key Laboratory of Sichuan Province, Chengdu 610000, China
*
Author to whom correspondence should be addressed.
Remote Sens. 2024, 16(11), 1912; https://doi.org/10.3390/rs16111912
Submission received: 15 March 2024 / Revised: 19 May 2024 / Accepted: 24 May 2024 / Published: 26 May 2024
(This article belongs to the Special Issue Recent Advances in Remote Sensing Image Processing Technology)
Figure 1
<p>Structure for proposed ALSST model. (The ASSF is proposed to exclude the fully connected layers and capture local continuity while considering complexity. The multiplication is used to fusion the spectral–spatial features. The LD-Former is designed to increase the data dynamics and prevent performance degradation as the transformer deepens. In this figure, <math display="inline"><semantics> <mrow> <mi>H</mi> <mo>×</mo> <mi>W</mi> <mo>×</mo> <mi>B</mi> </mrow> </semantics></math> is the size of the original HSI, <math display="inline"><semantics> <mrow> <mi>H</mi> <mo>×</mo> <mi>W</mi> <mo>×</mo> <mi>L</mi> </mrow> </semantics></math> is the size of HSI after PCA, and <math display="inline"><semantics> <mrow> <mi>P</mi> <mo>×</mo> <mi>P</mi> <mo>×</mo> <mi>L</mi> </mrow> </semantics></math> is the patches size).</p> ">
Figure 2
<p>Structure for proposed ASSF. PDWA is used to extract the spectral features of HSI, and ADWA is used to extract the spatial features of HSI.</p> ">
Figure 3
<p>Structure for proposed LD-Former. In this paper, MHDSA is the DropKey multi-head self-attention, ADD is the residual connection, MLP is the multi-layer perceptron, and NORM is the layer norm. N is the times of the encoder loops.</p> ">
Figure 4
<p>Structure for proposed MHDSA. <span class="html-italic"><b>Q</b></span>, <b><span class="html-italic">K</span></b>, and <b><span class="html-italic">V</span></b> are query, key, and value matrices.</p> ">
Figure 5
<p>TR dataset. (<b>a</b>) Pseudo-color image; (<b>b</b>) Ground-truth image.</p> ">
Figure 6
<p>MU dataset. (<b>a</b>) Pseudo-color image; (<b>b</b>) Ground-truth image.</p> ">
Figure 7
<p>AU dataset. (<b>a</b>) Pseudo-color image; (<b>b</b>) Ground-truth image.</p> ">
Figure 8
<p>UP dataset. (<b>a</b>) Pseudo-color image; (<b>b</b>) Ground-truth image.</p> ">
Figure 9
<p>Combined effect of the heads for attention, and the depth for encoders on four datasets. (<b>a</b>) TR dataset (8 + 1); (<b>b</b>) MU dataset (8 + 1); (<b>c</b>) AU dataset (4 + 1); (<b>d</b>) UP dataset (8 + 1). The horizontal axis represents the attention heads, while the vertical axis denotes the OA (%). The green represents one encoder depth and fusion block depth, and the orange represents two encoder depths and fusion block depths.</p> ">
Figure 10
<p>Classification images of different methods on TR dataset. (<b>a</b>) Ground-truth Image; (<b>b</b>) LiEtAl (98.10%); (<b>c</b>) SSRN (98.91%); (<b>d</b>) HyBridSN (98.57%); (<b>e</b>) DMCN (99.35%); (<b>f</b>) SpectralFormer (97.99%); (<b>g</b>) SSFTT (98.18%); (<b>h</b>) morpFormer (99.02%); (<b>i</b>) 3D-ConvSST (99.58%); (<b>j</b>) ALSST (99.70%).</p> ">
Figure 11
<p>T-SNE visualization on the TR dataset with different methods. (<b>a</b>) LiEtAl (98.10%); (<b>b</b>) SSRN (98.91%); (<b>c</b>) HyBridSN (98.57%); (<b>d</b>) DMCN (99.35%); (<b>e</b>) SpectralFormer (97.99%); (<b>f</b>) SSFTT (98.18%); (<b>g</b>) morpFormer (99.02%); (<b>h</b>) 3D-ConvSST (99.58%); (<b>i</b>) ALSST (99.70%).</p> ">
Figure 12
<p>Classification images of different methods on MU dataset. (<b>a</b>) Ground-truth Image; (<b>b</b>) LiEtAl (82.88%); (<b>c</b>) SSRN (86.94%); (<b>d</b>) HyBridSN (85.22%); (<b>e</b>) DMCN (87.39%); (<b>f</b>) SpectralFormer (87.08%); (<b>g</b>) SSFTT (87.06%); (<b>h</b>) morpFormer (84.96%); (<b>i</b>) 3D-ConvSST (86.21%); (<b>j</b>) ALSST (89.72%).</p> ">
Figure 13
<p>T-SNE visualization on the MU dataset with different methods. (<b>a</b>) LiEtAl (82.88%); (<b>b</b>) SSRN (86.94%); (<b>c</b>) HyBridSN (85.22%); (<b>d</b>) DMCN (87.39%); (<b>e</b>) SpectralFormer (87.08%); (<b>f</b>) SSFTT (87.06%); (<b>g</b>) morpFormer (84.96%); (<b>h</b>) 3D-ConvSST (86.21%); (<b>i</b>) ALSST (89.72%).</p> ">
Figure 14
<p>Classification images of different methods on AU dataset. (<b>a</b>) Ground-truth Image; (<b>b</b>) LiEtAl (94.84%); (<b>c</b>) SSRN (97.41%); (<b>d</b>) HyBridSN (96.50%); (<b>e</b>) DMCN (96.24%); (<b>f</b>) SpectralFormer (93.89%); (<b>g</b>) SSFTT (97.08%); (<b>h</b>) morpFormer (96.85%); (<b>i</b>) 3D-ConvSST (97.14%); (<b>j</b>) ALSST (97.84%).</p> ">
Figure 15
<p>T-SNE visualization on the AU dataset with different methods. (<b>a</b>) LiEtAl (94.84%); (<b>b</b>) SSRN (97.41%); (<b>c</b>) HyBridSN (96.50%); (<b>d</b>) DMCN (96.24%); (<b>e</b>) SpectralFormer (93.89%); (<b>f</b>) SSFTT (97.08%); (<b>g</b>) morpFormer (96.85%); (<b>h</b>) 3D-ConvSST (97.14%); (<b>i</b>) ALSST (97.84%).</p> ">
Figure 16
<p>Classification images of different methods on UP dataset. (<b>a</b>) Ground-truth Image; (<b>b</b>) LiEtAl (97.86%); (<b>c</b>) SSRN (99.56%); (<b>d</b>) HyBridSN (98.49%); (<b>e</b>) DMCN (99.20%); (<b>f</b>) SpectralFormer (98.01%); (<b>g</b>) SSFTT (99.46%); (<b>h</b>) morpFormer (99.26%); (<b>i</b>) 3D-ConvSST (99.52%); (<b>j</b>) ALSST (99.78%).</p> ">
Figure 17
<p>T-SNE visualization on the UP dataset. (<b>a</b>) LiEtAl (97.86%); (<b>b</b>) SSRN (99.56%); (<b>c</b>) HyBridSN (98.49%); (<b>d</b>) DMCN (99.20%); (<b>e</b>) SpectralFormer (98.01%); (<b>f</b>) SSFTT (99.46%); (<b>g</b>) morpFormer (99.26%); (<b>h</b>) 3D-ConvSST (99.52%); (<b>i</b>) ALSST (99.78%).</p> ">
Figure 18
<p>OA (%), AA (%), and K×100 on different ratio of DropKey. (<b>a</b>) TR dataset; (<b>b</b>) MU dataset; (<b>c</b>) AU dataset; (<b>d</b>) UP dataset. In the blue dashed box is the ratio corresponding to the best accuracy.</p> ">
Figure 19
<p>OA (%) of different training percentage on all methods. (<b>a</b>) TR dataset; (<b>b</b>) MU dataset; (<b>c</b>) AU dataset; (<b>d</b>) UP dataset. The accuracies of all evaluated methods demonstrated significant improvement as the number of training samples increased. Notably, the ALSST model consistently outperformed the other methods in every scenario, showcasing its superior effectiveness.</p> ">
Versions Notes

Abstract

:
In hyperspectral image classification (HSIC), every pixel of the HSI is assigned to a land cover category. While convolutional neural network (CNN)-based methods for HSIC have significantly enhanced performance, they encounter challenges in learning the relevance of deep semantic features and grappling with escalating computational costs as network depth increases. In contrast, the transformer framework is adept at capturing the relevance of high-level semantic features, presenting an effective solution to address the limitations encountered by CNN-based approaches. This article introduces a novel adaptive learnable spectral–spatial fusion transformer (ALSST) to enhance HSI classification. The model incorporates a dual-branch adaptive spectral–spatial fusion gating mechanism (ASSF), which captures spectral–spatial fusion features effectively from images. The ASSF comprises two key components: the point depthwise attention module (PDWA) for spectral feature extraction and the asymmetric depthwise attention module (ADWA) for spatial feature extraction. The model efficiently obtains spectral–spatial fusion features by multiplying the outputs of these two branches. Furthermore, we integrate the layer scale and DropKey into the traditional transformer encoder and multi-head self-attention (MHSA) to form a new transformer with a layer scale and DropKey (LD-Former). This innovation enhances data dynamics and mitigates performance degradation in deeper encoder layers. The experiments detailed in this article are executed on four renowned datasets: Trento (TR), MUUFL (MU), Augsburg (AU), and the University of Pavia (UP). The findings demonstrate that the ALSST model secures optimal performance, surpassing some existing models. The overall accuracy (OA) is 99.70%, 89.72%, 97.84%, and 99.78% on four famous datasets: Trento (TR), MUUFL (MU), Augsburg (AU), and University of Pavia (UP), respectively.

1. Introduction

The advent of advanced imaging technologies has garnered increased attention for various remote sensing modalities, with hyperspectral remote sensing technology emerging as a vital domain. Distinguished from grayscale and RGB imagery, hyperspectral images (HSIs) are the three-dimensional (3D) data encapsulated across hundreds of contiguous spectral bands, offering an abundance of spectral information alongside intricate spatial texture information [1]. HSIs have found extensive applications across diverse sectors, including plant disease diagnosis [2], military reconnaissance [3], ecosystem assessment [4], urban planning [5], and target detection [6], among others [7,8,9]. Therefore, substantial research efforts have been channeled into HSI-related works, spanning classification [10], band selection [11], and anomaly detection tasks [12]. Notably, hyperspectral image classification (HSIC) has a critical status within this spectrum of applications, which aims to distinguish land covers precisely at the pixel level [13].
Primitively, the assessment of the similarity in spectral information was evaluated by statistical algorithms, which then served as a basis for distinguishing hyperspectral pixels [14,15]. Nonetheless, this approach encounters limitations due to the potential variability of spectral characteristics within identical land objects and the occurrence of similar spectral features across different land types. In the past, HSIC predominantly leveraged traditional machine learning models. Given that the spectral bands in HSIs typically exceed 100, whereas the actual categories of land objects are usually fewer than 30, this causes a notable redundancy in spectral information. To address this, machine learning algorithms often employ techniques, such as principal component analysis (PCA) [16], independent component analysis (ICA) [17], and linear discriminant analysis (LDA) [18], to mitigate spectral redundancy. Subsequently, classifiers like decision trees [19], support vector machines (SVMs) [20], and K-nearest neighbors (KNNs) [21] were applied to the refined features for classification. Although machine learning methods have marked a substantial advancement over earlier statistical approaches to performance, they largely depend on manually crafted feature extraction, which may not effectively extract the more intricate information embedded within hyperspectral data. This limitation underscores the need for more advanced methodologies capable of autonomously adapting the complex patterns inherent in HSIs [22].
The rapid evolution of deep learning [23,24,25,26] has rendered it a more potent tool than traditional machine learning for extracting abstract information through multi-layer neural networks, significantly improving classification performance [27]. Deep learning techniques are the forefront methods of HSIC. Chen et al. [28] first introduced deep learning to HSIC, utilizing stacked autoencoders to extract spatial–spectral features and achieve notable classification outcomes. Since then, a plethora of deep learning architectures have been applied to HSIC, including deep belief networks (DBNs) [29], convolutional neural networks (CNNs) [30], graph convolutional networks (GCNs) [31], vision transformers [32], and other models [33,34]. Notably, CNNs and vision transformers have emerged as a leading approach in HSIC, attributed to the exceptional ability of CNNs to capture intricate spatial and spectral patterns and of vision transformers to capture long-range information, thereby setting a benchmark in the methodological advancement.
Roy et al. [35] combined the strengths of three-dimensional and two-dimensional convolutional neural networks (3DCNNs and 2DCNNs, respectively) to create a hybrid spectral CNN that excels in spatial–spectral feature representation, enhancing spatial feature delineation. Sun et al. [36] introduced a novel classification model featuring heterogeneous spectral–spatial attention convolutional blocks, which supports plug-and-play functionality and adeptly extracts 3D features of HSIs. CNNs demonstrate formidable performance due to their intrinsic network architecture, but their effectiveness is somewhat constrained when processing the lengthy spectral feature sequences inherent to HSIs. Acknowledging the transformative potential of vision transformers, Hong et al. [37] developed a spectral transformer tailored for extracting discriminative spectral features from block frequency bands. Sun et al. [38] introduced a spectral–spatial feature tokenization transformer that adeptly captures sequential relationships and high-level semantic features. Although vision transformers have shown proficiency in handling spectral sequence features, their exploitation of local spatial information remains suboptimal. To address this gap, Wang et al. [39] proposed a novel spectral–spatial kernel that integrates with an enhanced visual transformation method, facilitating comprehensive extraction of spatial–spectral features. Huang et al. [40] introduced the 3D Swin Transformer (3DSwinT) model, specifically designed to embrace the 3D nature of HSI and to exploit the rich spatial–spectral information they contain. Fang et al. [41] developed the MAR-LWFormer, which joins the attention mechanism with a lightweight transformer to facilitate multi-channel feature representation. The MAR-LWFormer capitalizes on the multispectral and multiscale spatial–spectral information intrinsic to HSI data, showing remarkable effectiveness even at exceedingly low sampling rates. Despite the above application of deep learning methods widespread in HSI classification, several challenges persist in the field. In these methods, the CNN layers employ a fixed approach to feature extraction without the dynamic fusion of spectral–spatial information. Moreover, during the deep information extraction phase by the transformer, dynamic feature updates are not conducted, limiting the adaptability and potential effectiveness of the model in capturing intricate data patterns.
To fully extract the spectral–spatial fusion features in HSIs and increase classification performance, a novel adaptive learnable spectral–spatial fusion transformer (ALSST) is designed. The dual-branch adaptive spectral–spatial fusion gating mechanism (ASSF) is engineered to concurrently extract spectral–spatial fusion features from HSIs. Additionally, the learnable transition matrix layer scale is incorporated into the original vision transformer encoder to enhance training dynamics. Furthermore, the DropKey technique is implemented in the multi-head self-attention (MHSA) to mitigate the risk of overfitting. This approach enhances the model’s generalization capabilities, ensuring more robust and reliable performance across diverse hyperspectral datasets. The key contributions of the ALSST are as follows:
  • In this study, a dual-branch fusion model named ALSST is designed to extract the spectral–spatial fusion features of HSIs. This model synergistically combines the prowess of CNNs in extracting local features with the capacity of a vision transformer to discern long-range dependencies. Through this integrated approach, the ALSST aims to provide a comprehensive learning mechanism for the spectral–spatial fusion features of HSIs, optimizing the ability of the model to interpret and classify complex hyperspectral data effectively.
  • A dual-branch fusion feature extraction module known as ASSF is developed in the study. The module contains the point depthwise attention module (PDWA) and the asymmetric depthwise attention module (ADWA). The PDWA primarily focuses on extracting spectral features from HSIs, whereas the ADWA is tailored to capture spatial information. The innovative design of ASSF enables the exclusion of linear layers, thereby accentuating local continuity while maintaining the richness of feature complexity.
  • The new transformer with a layer scale and DropKey (LD-Former) is proposed to increase the data dynamics and prevent performance degradation as the transformer deepens. The layer scale was added to the output of each residual block, and different output channels were multiplied by different values to make the features more refined. At the same time, the DropKey is adopted into self-attention (SA) to obtain DropKey self-attention (DSA). The combination of these two techniques overcomes the risk of overfitting and can train deeper transformers.
The remainder of this article is structured as follows: Section 2 delves into the underlying theory behind the proposed ALSST method. Section 3 introduces the four prominent HSI datasets, the experimental settings, and experiments conducted on datasets. Section 4 discusses the ablation analysis, the ratio of DropKey, and the impact of varying training samples. Section 5 provides a conclusion, summarizing the main findings and contributions of the article.

2. Methodology

2.1. Overall Architecture

The ALSST proposed in this article is shown in Figure 1. The ASSF with the PDWA and the ADWA is designed to enhance the spectral–spatial fusion feature extraction. The novel LD-Former is proposed to increase the data dynamics and prevent performance degradation as the transformer deepens.
From Figure 1, the original input data of the ALSST could be represented as X o r i H R H × W × B , where height is H , width is W , and spectra are B . HSIs feature extensive spectral bands that offer valuable information but concurrently elevate computational costs. The PCA is applied to reduce the spectral dimensions of the HSI, optimizing the balance between information retention and computational efficiency. The data after PCA would be reshaped to X P C A H R H × W × L , of which L is the amounts of bands after PCA.
X P C A H is sent to dual-branch ASSF to extract spectral–spatial fusion features X s p e c t r a l o u t and X s p a t i a l o u t . X P C A H is firstly sent to the convolution kernel 1 × 1 × 3 in the spectral branch to extract the spectral features X s p e c t r a l 3 D , and then X s p e c t r a l 3 D is reshaped to the X s p e c t r a l 2 D to make the feature dimension match the subsequent PDWA. We put X s p e c t r a l 2 D into the PDWA to focus on extracting spectral features. The outputs of the PDWA are sent to the convolution kernel 1 × 1 for reducing the feature channels. Then, the new outputs are reshaped to the one-dimensional (1D) vectors. X P C A H is synchronously sent to the convolution kernel 3 × 1 × 1 and 1 × 3 × 1 in the spatial branch to extract the spatial features X s p a t i a l 3 D , and then X s p a t i a l 3 D is reshaped to the X s p a t i a l 2 D to make the feature dimension match the subsequent ADWA. We put X s p a t i a l 2 D into the ADWA to focus on extracting spatial features. The outputs of the PDWA are also sent to the convolution kernel 1 × 1 for reducing the feature channels. Then, the new outputs are also reshaped to the1D vectors. The X s p e c t r a l 1 D and X s p a t i a l 1 D are multiplied to obtain the spectral–spatial fusion features for the subsequent LD-Former to extract the in-depth dynamic features information. The LD-Former may loop N times. Then, the outputs Y s p e c t r a l c l s and Y s p a t i a l c l s are put into the multi-layer perceptron (MLP) [42] separately for the final classification. The cross-entropy loss (CE) function is used to measure the degree of inconsistency between the predicted labels Y P and the true labels Y L .

2.2. Feature Extraction via ASSF

While transformer networks adeptly model global interactions between token embeddings via SA, they exhibit limitations in extracting fine-grained local feature patterns [42]. Given the proven effectiveness of CNNs in modeling spatial context features, particularly in HSI classification tasks, we integrate a CNN for feature extraction from input data. We draw inspiration from the GSAU [43] to devise the ASSF module for further refined feature representation. Central to ASSF are the PDWA and the ADWA, which bypass the linear layer and capture local continuity while managing complexity effectively.
The PDWA, deployed for extracting spectral features from HSIs, is depicted on the left of Figure 2. It comprises several key components: pointwise convolution (PWC), point depthwise convolution (PDWC), the multiplication operation, and the residual connection. These elements collaboratively function to enhance the feature extraction process. The input X s p e c t r a l i n of the module is divided into X s p e c t r a l P 1 and X s p e c t r a l P 2 . X s p e c t r a l P 1 is sent to the PWC layer to obtain X s p e c t r a l P P 1 . We feed X s p e c t r a l P P 1 into PDWC with 1 × 1 convolution kernel to yield the output X s p e c t r a l P D . Groups in the PDWC layer are equal to the channels of X s p e c t r a l P P 1 . Given that the convolution kernel size is 1 × 1 and the number of groups equals the input channels, this configuration effectively concentrates on the channel information, enabling a focused analysis and processing of the spectral or feature channels in the data. This approach ensures that the convolution operation emphasizes inter-channel relationships, enhancing the ability to capture and exploit channel-specific features of the model. X s p e c t r a l P 2 also obtains X s p e c t r a l P P 2 by a PWC. To keep a portion of the original information intact, no transformations or operations are applied to X s p e c t r a l P P 2 . This ensures the preservation of essential raw data characteristics within the analytical framework. The data obtained by multiplying X s p e c t r a l P D and X s p e c t r a l P P 2 are sent to a new PWC and obtain the output X s p e c t r a l o u t . We set a random parameter matrix G of size (1, 1, channels) and set it to be backpropagated and updated with training. The result of multiplying G and X s p e c t r a l o u t is connected with X s p e c t r a l i n by residual connection to obtain the output X s p e c t r a l o u t . By the matrix G, the adaptive update of the output of this module is achieved. The PWC employs a 1 × 1 convolution kernel designed to modify the data dimensions, which is crucial for aligning the dimensions across different layers. The main process of the PDWA is as follows:
PDWA ( X s p e c t r a l P 1 , X s p e c t r a l P 2 ) = Φ PDW ( X s p e c t r a l P 1 ) X s p e c t r a l P 2 ,
here, X s p e c t r a l P 1 and X s p e c t r a l P 2 represent the characteristic data of the two branches in the PDWA, respectively. Φ PDW ( ) and represent PDWC and multiplication.
The ADWA is primarily utilized to extract spatial features from HSIs, with its structure illustrated on the right of Figure 2. The ADWA framework encompasses several key components: the PWC, two layers of asymmetric depthwise convolution (ADWC), the multiplication operation, and the residual connection. These elements collectively enhance the capacity to capture and integrate spatial features of the model effectively, thereby enriching the overall feature representation. In this module, the PDWC within the PDWA is replaced by two ADWC layers with 3 × 1 and 1 × 3 convolution kernels, respectively, while all other operations remain consistent. This modification allows for a more nuanced extraction of spatial features by capturing variations along different dimensions, thereby enhancing the ability to discern spatial features within the data. The main processes of the ADWA are as follows:
ADWA ( X s p a t i a l A 1 , X s p a t i a l A 2 ) = Φ ADW 2 ( Φ ADW 1 ( X s p a t i a l A 1 ) ) X s p a t i a l A 2 ,
where X s p a t i a l A 1  and X s p a t i a l A 2 represent the features of the two branches in the ADWA. Φ ADW 1 and Φ ADW 2 represent two ADWCs.

2.3. LD-Former Encoder

Figure 3 delineates the structure of the proposed LD-Former. The LD-Former encoders are adept at modeling deep semantic interrelations among feature tokens, transforming the input of LD-Former into a sequence of vectors. A class token is integrated at the beginning of this vector sequence to encapsulate the overall sequence information. Subsequently, n positional encodings are embedded into the sequence to generate multiple tokens, with encoding similarity reflecting proximity in information. These tokens are then processed through the transformer encoder. The output from the multi-head DropKey self-attention (MHDSA) undergoes classification via an MLP, comprising one layer norm (LN) and two fully connected layers (FC), with a Gaussian error linear unit (GELU) [44] activation function employed for classification. The operations are iteratively applied N times. In deeper models, attention maps of subsequent blocks tend to be more similar, suggesting limited benefits from excessively increasing depth.
To address potential limitations of deep transformers, a learnable matrix (layer scale), inspired by CaiT models [45], is integrated into the transformer encoder. This layer scale introduces a learnable diagonal matrix to each residual block’s output, initialized near zero, enabling differentiated scaling across SA or MLP output channels, thereby refining feature representation and supporting the training of deeper models. The formulas are as follows:
x s = x s + diag λ s , 1 , , λ s , d × MHDSA LN x s ,
x m + 1 = x m + diag λ m , 1 , , λ m , d × MLP LN x m ,
here, LN is the layer norm and MLP is the feed-forward network in the LD-Former. λ s , 1 , , λ s , d and λ m , 1 , , λ m , d are learnable weights for the outputs of MHDSA and MLP. The diagonal values are all initialized to the fixed small value σ . When the depth is within 18, σ = 0.1 , when the depth is within 24, σ = 5 × 10 3 , and σ = 5 × 10 6 is adopted to the deeper networks.
Figure 4 delineates the structure of the proposed MHDSA. To elucidate the interrelations among feature tokens, the learnable weights denoted W Q , W K , and W V are established for the SA mechanism. These weights are utilized to multiply with the feature tokens, subsequently linearly aggregating them into three distinct matrices representing queries (Q), keys (K), and values (V). The Softmax is then applied to the resultant scores, transforming them into weight probabilities, thereby facilitating the SA computation, as delineated below.
SA Q , K , V = Softmax Q K T d K V ,
where d K represents the dimension of K .
At the same time, DropKey [46] is an innovative regularization technique designed for MHSA. It is an effective tool to combat overfitting, particularly in scenarios characterized by a scarcity of samples. DropKey prevents the model from relying too heavily on specific feature interactions by selectively dropping keys in the attention mechanism. It promotes a more generalized learning process that enhances the performance of the model on unseen data. The DSA computation is delineated below.
DSA Q , K , V = i = 1 n exp r i + Q K T d K i = 1 n exp r i + Q K T d K V ,
here, n is the number of feature tokens. r i is the ratio of DropKey. A structure analogous to MHSA named MHDSA is implemented in the approach, utilizing multiple sets of weights. MHDSA comprises several DSA units, where the scores from each DSA are aggregated. This method allows for a diversified and comprehensive analysis of the input features, capturing various aspects of the data through different attention perspectives. The formulation of this process is detailed in the following expression.
MHDSA Q , K , V = Concat DSA 1 ,   DSA 2 , ,   DSA h W ,
here, h is the attention heads number and W is the parameter matrix.

2.4. Final Classifier

The overarching algorithm of the ALSST for HSIC is detailed in Algorithm 1. The features Y s p e c t r a l c l s and Y s p a t i a l c l s extracted from the LD-Former encoders are fed into MLP layers for the terminal classification stage. Each MLP has two linear layers and a GELU operation. The size of the output layer in MLP is customized to match the total class count, enabling the Softmax  normalization of the activations of output units to sum to one.
This normalization makes the output embody a probability distribution of the class labels. Aggregating the final two output probability vectors yields the ultimate probability vector, with the maximum probability value designating the label of a pixel. Subsequently, the CE function is employed to calculate the loss value to enhance the precision of the classification results.
Algorithm 1 Adaptive Learnable Spectral–spatial Fusion Transformer for Hyperspectral Image Classification.
Input: HSI: X o r i H R H × W × B , Labels: Y L R H × W , Patches = 11 × 11, PCA = 30.
Output: Prediction: Y P
1Initialize: batch size = 64, epochs = 100, the initial learning rate of the optimizer Adam depends on datasets.
2PCA:  X P C A H R H × W × L .
3Patches: Accomplish the slicing process for HSI to acquire the small patches X i n H R P × P × L .
4Split X i n H  and into training sets D t r and test sets D t e ( D t r  has the class labels, and D t e has not the class labels).
5Training ALSST (begin)
6for epoch in range(epochs):
7       for i, ( D t r , Y L ) in enumerate ( D t r ):
8            Generate the spectral–spatial fusion features using the ASSF.
9           Perform the LD-Former encoder:
10           The learnable class tokens are added to the first locations of the 1D spectral–spatial fusion feature vectors derived from ASSF, while the positional embedding is carried out to the total feature vectors, to form the semantic tokens. The semantic tokens learned by Equations (3)–(7).
11           Input the spectral–spatial class tokens from LD-Former into the MLP.
12          X out = MLP X s p e c t r a l C D MLP X s p a t i a l C D
13          CE   Loss Y o u t , Y L
14Training ALSST (end) and test ALSST
15 Y P = ALSST t r a i n e d D t e

3. Experimental Results

3.1. Data Description

The performance of the proposed ALSST method in this article is evaluated on four public multi-modal datasets: Trento (TR), MUUFL (MU) [47,48], Augsburg (AU), and University of Pavia (UP). Details of all datasets are described as follows.
  • TR dataset
The TR dataset covers a rural area surrounding the city of Trento, Italy. It includes 600 × 166 pixels and six categories. The HSI has 63 bands in the wavelength range from 420.89 to 989.09 nm. The spectral resolution is 9.2 nm, and the spatial resolution is 1 m. The pseudo-color image of HSIs and the ground-truth image are in Figure 5. The color, class name, training samples, and test samples for the TR dataset are in Table 1.
2.
MU dataset
The MU dataset covers the University of Southern Mississippi Gulf Park Campus, Long Beach, Mississippi, USA. The dataset was acquired in November 2010 with a spatial resolution of 1 m per pixel. The original dataset is 325 × 337 pixels with 72 bands, and the imaging spectral range is between 380 nm and 1050 nm. Due to the influence of imaging noise, the first 4 and the last 4 bands were removed, and finally, 64 bands were used. The invalid area on the right of the original image is removed, and the 325 × 220 pixels is retained. Objects in the imaging scene were placed into eleven categories. The pseudo-color image of the HSI and the ground-truth image are in Figure 6. The details of MU dataset are in Table 2.
3.
AU dataset
The AU dataset was captured over the city of Augsburg, Germany. The spatial resolutions were down sampled to a resolution of 30 m. The HSI has 180 bands from 0.4 to 2.5 μm. The pixels size of AU is 332 × 485, and it depicts seven different land cover classes. The pseudo-color image of the HSI and the ground-truth image are in Figure 7. Details on the AU dataset are provided in Table 3.
4.
UP dataset
The UP hyperspectral dataset, captured in 2003, focuses on the urban area around the University of Pavia in Northern Italy. The dataset comprises 610 × 340 pixels, encompassing nine distinct categories of ground objects. It includes 115 consecutive spectral bands ranging from 0.43 to 0.86 μm, offering a spatial resolution of 1.3 m. Due to noise, 12 bands were discarded, leaving 103 bands for analysis. The pseudo-color image of the HSI, and the ground-truth image are in the Figure 8. Table 4 displays the image cube, ground-truth image, class names, training samples, and test samples for the UP dataset.

3.2. Experimental Setting

The experiments presented in this article are executed on Windows 11 and an RTX 3090Ti. The programming is conducted in Python 3.8, utilizing PyTorch 1.12.0. The input image size is 11 × 11, with a batch size of 64 and 100 epochs. The PCA method is employed to reduce the dimensionality of HSIs to 30. To enhance the robustness of the experimental outcomes, training and test samples for the TR, MU, AU, and UP are selected randomly. Table 2, Table 3, Table 4 and Table 5 detail the number of training and testing samples for these four datasets, and the selection of training samples for each class depends on its distribution and total number. The experiments are repeated five times to ensure consistency, with the final classification results representing the average of these iterations. The evaluation metrics of overall accuracy (OA), average accuracy (AA), and the statistical Kappa coefficient (K) are the primary indicators of performance in these classification experiments.
It is imperative to compare experimental outcomes across different parameter settings to achieve optimal accuracy. In this article, variables such as the initial learning rate of the Adam optimizer, the number of attention heads, the depth of encoders, and the depth of the LD-Former are rigorously tested across all datasets. A controlled variable method is employed in these experiments, ensuring consistency in input size, number of epochs, experiment iterations, and the quantity of training and testing samples.

3.2.1. Initial Learning Rate

Table 5 illustrates the impact of various initial learning rates for the Adam optimizer on the experimental outcomes. The initial learning rates of 0.001, 0.0005, and 0.0001 are evaluated in the experiments. The findings indicate that the optimal accuracy is achieved when the initial learning rates for the TR, MU, and UP datasets are 0.001 and for the AU dataset is 0.0005.
Table 5. OA (%) of different initial learning rate on all datasets (Bold represents the best accuracy).
Table 5. OA (%) of different initial learning rate on all datasets (Bold represents the best accuracy).
DatasetsInitial Learning Rate
0.0010.00050.0001
TR99.70 ± 0.0399.68 ± 0.0499.59 ± 0.01
MU89.72 ± 0.3688.67 ± 0.4787.76 ± 0.69
AU97.82 ± 0.1197.84 ± 0.0997.39 ± 0.04
UP99.78 ± 0.0399.56 ± 0.0599.54 ± 0.06

3.2.2. Depth and Heads

Figure 9 presents the combined influence of the number of attention heads, encoder depths, and the depth of the LD-Former on the performance of the ALSST. In this work, we evaluate the LD-Former with four distinct configurations (i.e., 4 + 2, 4 + 1, 8 + 2, and 8 + 1) for the number of attention heads and the depth of the encoder. The findings indicate that the optimal configuration for the TR, MU, and UP datasets involves setting the attention heads and LD-Former depth to 8 and 1, respectively, while a different optimal setting is 4 and 1 for the AU dataset.

3.3. Performance Comparison

In this section, we evaluate the performance of the proposed ALSST against various methods, including LiEtAl [49], SSRN [50], HyBridSN [35], DMCN [10], SpectralFormer [37], SSFTT [38], morpFormer [51], and 3D-ConvSST [52], to validate its classification effectiveness. The initial learning rates for all methods are aligned with those used for the ALSST to ensure a fair comparison, facilitating optimal performance evaluation. The classification outcomes and maps for each method across all datasets are detailed in Section 3.3.1. Subsequently, Section 3.3.2 provides a comparative analysis of resource consumption and computational complexity for all the methods.

3.3.1. Experimental Results

The classification outcomes for the proposed ALSST model and all compared methods are detailed in Table 6, Table 7, Table 8 and Table 9. The ALSST model consistently outperforms others across various evaluation metrics, with an OA of 99.70%, 89.72%, 97.84%, and 99.78%; AA of 99.53%, 92.39%, 90.30%, and 99.57%; and K × 100 of 99.60%, 86.59%, 96.91%, and 99.71% on the TR, MU, AU, and UP datasets. To provide a visual comparison of classification performance, Figure 10, Figures 12, 14 and 16 display the classification maps generated by all the considered methods, and Figures 11, 13, 15 and 17 display the T-SNE visualization by all the considered methods, further illustrating the superior performance of the ALSST model.
  • TR dataset
Table 6 indicates that SpectralFormer yields the most favorable classification outcomes among the compared methods. This inferior performance is attributed to its approach of directly flattening image blocks into vectors, a process that disrupts the intrinsic structural information of the image. Following SpectralFormer, LiEtAl ranks as the second-least-effective, primarily due to its simplistic structure, which limits its feature extraction capabilities. The proposed ALSST improves OA by 1.60%, 0.79%, 1.13%, 0.35%, 1.71%, 0.52%, 0.68%, and 0.12% compared to LiEtAl, SSRN, HyBridSN, DMCN, SpectralFormer, SSFTT, morpFormer, and 3D-ConvSST. At the same time, the proposed ALSST improves K × 100 by 2.80%, 1.17%, 1.57%, 0.66%, 2.99%, 0.83%, 1.04%, and 0.14% on AA, and improves 2.14%, 1.06%, 1.51%, 0.47%, 2.29%, 0.70%, 0.91%, and 0.16%, respectively. In addition, it could be found that the accuracy of category 3, 4 and 5 of the proposed ALSST reached 100%. The simplicity of the sample distribution facilitates the effective learning of feature information.
Table 6. OA, AA, K and per-class accuracy for TR dataset (Bold represents the best accuracy).
Table 6. OA, AA, K and per-class accuracy for TR dataset (Bold represents the best accuracy).
ClassLiEtAlSSRNHyBridSNDMCNSpectralFormerSSFTTMorp-
Former
3D-ConvSSTALSST
199.39 ± 0.4299.68 ± 0.2399.23 ± 0.62 99.65 ± 0.3599.10 ± 0.7298.84 ± 0.6197.89 ± 0.7598.94± 0.39 99.56 ± 0.05
292.61 ± 1.4794.31 ± 6.2095.18 ± 2.0899.74 ± 0.4994.49 ± 0.3998.01 ± 0.5096.49 ± 2.5799.06 ± 0.6499.48 ± 0.25
397.75 ± 0.3799.68 ± 0.6499.89 ± 0.2199.44 ± 0.5697.54 ± 0.58100 ± 0.00100 ± 0.00100 ± 0.00100 ± 0.00
499.88 ± 0.1299.99 ± 0.01100 ± 0.0099.99 ± 0.0199.92 ± 0.08100 ± 0.00100 ± 0.00100 ± 0.00100 ± 0.00
599.62 ± 0.4099.42 ± 1.0799.24 ± 0.4899.97 ± 0.0399.65 ± 0.2399.99 ± 0.0199.97 ± 0.0299.95 ± 0.05100 ± 0.00
691.16 ± 2.9997.06 ± 1.6694.18 ± 1.5896.42 ± 1.1288.51 ± 5.5595.38 ± 2.2396.58 ± 2.8498.39 ± 0.5198.17 ± 0.23
OA (%)98.10 ± 0.2498.91 ± 0.5598.57 ± 0.2299.35 ± 0.1797.99 ± 0.6499.18 ± 0.1299.02 ± 0.2899.58 ± 0.0899.70 ± 0.03
AA (%)96.73 ± 0.4198.36 ± 0.8297.96 ± 0.2698.87 ± 0.3596.54 ± 0.5198.70 ± 0.2298.49 ± 0.4299.39 ± 0.1199.53 ± 0.05
K × 10097.46 ± 0.2698.54 ± 0.7498.09 ± 0.2999.13 ± 0.5897.31 ± 0.4998.90 ± 0.1798.69 ± 0.3899.44 ± 0.1199.60 ± 0.04
As depicted in Figure 10, the ALSST model exhibits the least amount of salt-and-pepper noise in its classification maps compared to other methods, demonstrating its superior ability to produce cleaner and more accurate classification results. The category in the red box is represented by green, and only the proposed method can achieve all green, while other comparison methods are mixed with blue. It can also be seen from Figure 11 that the clustering effect of the model with higher precision is better, and the clustering effect of the ALSST is the best. Taking categories 2 and 8 as examples, the ALSST can separate them to a greater extent.
2.
MU dataset
Table 7 shows that LiEtAl has the worst classification results, and MFT_PT has the second worst because it only carries out ordinary convolutional feature extraction on HSIs. The OA of the proposed ALSST rises by 6.84%, 2.78%, 4.50%, 2.33%,2.64%, 2.66%, 4.76%, and 3.51% compared to LiEtAl, SSRN, HyBridSN, DMCN, SpectralFormer, SSFTT, morpFormer, and 3D-ConvSST. Meanwhile, the AA rises by 7.26%, 2.05%, 3.10%, 2.30%, 3.09%, 3.21%, 4.82%, and 4.22%, and the K × 100 rises by 8.73%, 3.54%, 5.62%, 2.99%, 3.45%, 3.40%, 5.98%, and 4.47%. The uneven and intricate sample distribution of the MU dataset causes considerable challenges in improving classification accuracy. The ALSST model leverages dynamic spectral–spatial fusion feature information to obtain a superior classification performance relative to other algorithms.
Table 7. OA, AA, K and per-class accuracy for MU dataset (Bold represents the best accuracy).
Table 7. OA, AA, K and per-class accuracy for MU dataset (Bold represents the best accuracy).
ClassLiEtAlSSRNHyBridSNDMCNSpectralFormerSSFTTMorp-
Former
3D-ConvSSTALSST
185.06 ± 2.0187.51 ± 1.3784.03 ± 3.5387.76 ± 2.3788.62 ± 0.3688.16 ± 0.5785.14 ± 2.2687.46 ± 0.8989.65 ± 1.03
277.97 ± 3.5683.77 ± 4.7983.28 ± 2.4584.85 ± 6.8178.01 ± 9.7584.27 ± 9.8279.49 ± 6.4081.75 ± 2.3888.06 ± 1.17
374.57 ± 5.7681.63 ± 3.2479.96 ± 2.4678.90 ± 3.3581.75 ± 8.5879.53 ± 3.8681.83 ± 2.2277.71 ± 4.4386.21 ± 1.12
489.03 ± 4.6095.27 ± 0.7097.15 ± 1.1696.42 ± 1.5494.88 ± 2.4993.89 ± 7.7396.30 ± 0.6594.62 ± 1.2394.18 ± 1.85
581.11 ± 3.5284.43 ± 1.0482.14 ± 1.6988.05 ± 3.9188.62 ± 0.3684.34 ± 3.1779.83 ± 5.1785.35 ± 2.3187.77 ± 2.57
699.49 ± 0.51100 ± 0.0099.81 ± 0.2599.84 ± 0.1699.43 ± 0.5799.68 ± 0.3299.56 ± 0.3899.24 ± 1.01100 ± 0.00
787.48 ± 1.8194.07 ± 0.9590.06 ± 2.0892.44 ± 3.0491.38 ± 2.0494.30 ± 2.5790.16 ± 2.7287.83 ± 2.0795.59 ± 0.88
888.90 ± 4.9691.64 ± 2.1295.86 ± 1.2794.56 ± 2.3292.28 ± 0.8593.03 ± 1.4792.82 ± 2.0093.76 ± 1.2194.38 ± 0.55
964.96 ± 1.8977.67 ± 2.3476.99 ± 1.7175.45 ± 3.5776.79 ± 0.9378.93 ± 1.3976.16 ± 6.1272.74 ± 1.4083.45 ± 2.50
1092.75 ± 4.2199.39 ± 1.2193.94 ± 3.3194.24 ± 5.7693.94 ± 6.0686.68 ± 10.9283.03 ± 10.4390.30 ± 3.5398.18 ± 1.48
1197.14 ± 1.3498.32 ± 0.9298.99 ± 0.3499.24 ± 0.7699.50 ± 0.5298.32 ± 1.68 98.99 ± 0.3499.16 ± 0.0398.82 ± 0.67
OA (%)82.88 ± 2.3086.94 ± 0.8785.22 ± 1.4787.39 ± 1.1287.08 ± 1.2487.06 ± 0.8584.96 ± 1.1086.21 ± 0.7089.72 ± 0.36
AA (%)85.13 ± 1.2090.34 ± 0.4989.29 ± 0.6290.09 ± 0.9989.30 ± 1.1289.18 ± 1.6487.57 ± 0.8088.17 ± 0.5392.39 ± 0.51
K × 10077.86 ± 0.9383.05 ± 1.0880.97 ± 1.7583.60 ± 0.2183.14 ± 1.6483.19 ± 0.4380.61 ± 1.3182.12 ± 0.8786.59 ± 0.46
As can be seen from the area inside the blue box in Figure 12, the classification image produced by the ALSST aligns most closely with the ground-truth image. As can be seen from the area inside the red circle of the T-SNE visualization in Figure 13, the ALSST has the best clustering effect.
3.
AU dataset
As Table 8 shows, SpectralFormer has the worst classification results, and LiEtAl has the second worst. The OA of the ALSST increased by 3.00%, 0.43%, 1.34%, 1.60%, 3.95%, 0.76%, 0.99%, and 0.70% compared to LiEtAl, SSRN, HyBridSN, DMCN, SpectralFormer, SSFTT, morpFormer, and 3D-ConvSST. Simultaneously, the AA of the proposed method increased by 18.64%, 2.56%, 5.86%, 9.27%, 18.64%, 4.18%, 2.27%, and 3.55%, and the K×100 increased by 4.33%, 0.62%, 1.93%, 2.31%, 5.69%, 1.10%, 1.43%, and 1.01%.
The red boxed area in Figure 14 indicates that the ALSST model generates classification maps with minimal salt-and-pepper noise compared to alternative methods, showcasing its capability to yield more precise classification outcomes. Furthermore, Figure 15 reveals that the higher the accuracy, the better the clustering effects, and the ALSST can distinguish categories 3 and 6 to the greatest extent.
Table 8. OA, AA, K and per-class accuracy for AU dataset (Bold represents the best accuracy).
Table 8. OA, AA, K and per-class accuracy for AU dataset (Bold represents the best accuracy).
ClassLiEtAlSSRNHyBridSNDMCNSpectralFormerSSFTTMorp-
Former
3D-ConvSSTALSST
198.25 ± 0.4398.94 ± 0.2299.12 ± 0.2698.59 ± 0.5686.10 ± 0.4498.82 ± 0.0897.71 ± 0.2199.09 ± 0.3298.67 ± 0.25
277.97 ± 3.5699.23 ± 0.2599.16 ± 0.3698.52 ± 0.4496.10 ± 1.4499.02 ± 0.3398.54 ± 0.2598.58 ± 0.2599.06 ± 0.09
397.54 ± 0.4889.29 ± 1.1895.61 ± 1.0087.64 ± 1.5175.99 ± 8.9290.13 ± 1.3989.69 ± 1.4693.33 ± 1.5395.96 ± 0.39
498.54 ± 0.2299.12 ± 0.2298.95 ± 0.2199.02 ± 0.5898.66 ± 0.3498.77 ± 0.3498.53 ± 0.1198.86 ± 0.1899.13 ± 0.14
564.97 ± 5.0485.01 ± 5.2384.64 ± 9.8771.08 ± 3.9948.88 ± 7.6179.09 ± 5.6084.88 ± 3.0681.02 ± 2.9887.39 ± 4.08
646.60 ± 2.0169.67 ± 4.1972.04 ± 3.5947.82 ± 5.1527.56 ± 9.5470.12 ± 3.3775.45 ± 3.5864.48 ± 2.9078.80 ± 1.73
758.39 ± 3.5872.93 ± 2.7472.67 ± 1.9564.51 ± 1.8655.50 ± 4.9566.88 ± 1.2071.36 ± 3.5871.90 ± 2.2973.08 ± 0.60
OA (%)94.84 ± 0.3997.41 ± 0.2496.50 ± 0.0896.24 ± 1.3693.89 ± 0.2797.08 ± 0.1896.85 ± 0.0797.14 ± 0.1897.84 ± 0.09
AA (%)71.66 ± 0.8587.74 ± 1.5984.44 ± 0.5881.03 ± 2.3071.66 ± 2.5886.12 ± 1.9388.03 ± 1.2186.75 ± 1.0290.30 ± 0.71
K × 10092.58 ± 0.7996.29 ± 0.3494.98 ± 0.1194.60 ± 0.4291.22 ± 0.4395.81 ± 0.2595.48 ± 0.1095.90 ± 0.2696.91 ± 0.13
4.
UP dataset
According to Table 9, LiEtAl exhibits the lowest classification performance, with SpectralFormer exhibiting the second lowest. The ALSST model demonstrates significant improvements in the OA of 1.92%, 0.22%, 1.29%, 0.58%, 1.77%, 0.32%, 0.52%, and 0.26% when compared to LiEtAl, SSRN, HyBridSN, DMCN, SpectralFormer, SSFTT, morpFormer, and 3D-ConvSST, respectively. Similarly, the AA values enhance by 3.30%, 0.37%, 1.81%, 0.98%, 2.97%, 0.50%, 0.96%, and 0.57%, while the K × 100 increases by 2.55%, 0.29%, 1.72%, 0.77%, 2.35%, 0.42%, 0.69%, and 0.35%.
Table 9. OA, AA, K and per-class accuracy for UP dataset (Bold represents the best accuracy).
Table 9. OA, AA, K and per-class accuracy for UP dataset (Bold represents the best accuracy).
ClassLiEtAlSSRNHyBridSNDMCNSpectralFormerSSFTTMorp-
Former
3D-ConvSSTALSST
199.06 ± 0.499.8 ± 0.0898.22 ± 0.3199.70 ± 0.1497.54 ± 0.1899.73 ± 0.2999.65 ± 0.1099.81 ± 0.1799.99 ± 0.01
299.76 ± 0.1099.99 ± 0.0399.95 ± 0.0499.95 ± 0.0599.89 ± 0.0999.97± 0.0299.97 ± 0.0399.97 ± 0.0299.99 ± 0.01
386.53 ± 1.5297.07 ± 1.9393.24 ± 1.3094.78 ± 2.5585.79 ± 2.0597.39 ± 0.8798.06 ± 1.3897.55 ± 1.0499.91 ± 0.11
495.49 ± 0.5499.31 ± 0.4198.43 ± 0.3897.20 ± 1.2097.45 ± 0.7497.95 ± 0.6498.34 ± 0.3997.98 ± 0.4798.17 ± 0.35
5100 ± 0.0099.95 ± 0.09100 ± 0.00100 ± 0.0099.98 ± 0.0399.94 ± 0.0999.55 ± 0.27100 ± 0.0099.97 ± 0.04
697.56 ± 0.65100 ± 0.0097.70 ± 0.2999.89 ± 0.1599.31 ± 0.4799.75 ± 0.2999.99 ± 0.02100 ± 0.0099.98 ± 0.04
798.86 ± 1.1898.53 ± 0.5599.41 ± 0.499.49 ± 0.3899.43 ± 0.2499.90 ± 0.1999.79 ± 0.1499.95 ± 0.06100 ± 0.00
894.60 ± 1.0398.07 ± 0.4394.90 ± 1.0097.40 ± 1.0094.36 ± 1.2898.30 ± 0.7295.91 ± 0.9198.75 ± 0.3199.50 ± 0.23
994.58 ± 3.34100 ± 0.0097.98 ± 0.7398.89 ± 1.2295.62 ± 2.0198.71 ± 0.5196.24 ± 0.6096.98 ± 0.5798.62 ± 0.45
OA (%)97.86 ± 0.3999.56 ± 0.0998.49 ± 0.1699.20 ± 0.1398.01 ± 0.1199.46 ± 0.1599.26 ± 0.0599.52 ± 0.0699.78 ± 0.03
AA (%)96.27 ± 0.7499.20 ± 0.1997.76 ± 0.3298.59 ± 0.2496.60 ± 0.2499.07 ± 0.2598.61 ± 0.1599.00 ± 0.1399.57 ± 0.08
K × 10097.16 ± 0.5299.42 ± 0.1297.99 ± 0.2198.94 ± 0.1797.36 ± 0.1599.29 ± 0.2099.02 ± 0.0799.36 ± 0.0899.71 ± 0.04
The blue box area in Figure 16 underscores that higher accuracy correlates with reduced salt-and-pepper noise, affirming the precision of the ALSST model. Additionally, the red circle area of the T-SNE visualization in Figure 17 illustrates that the ALSST achieves the most effective clustering among the compared methods. These observations collectively indicate that the ALSST substantially enhances classification performance.

3.3.2. Consumption and Computational Complexity

In this section, we conduct a thorough comparative analysis of the proposed ALSST against benchmark methods to evaluate classification performance. Main metrics, such as total parameters (TPs), training time (Tr), testing time (Te), and floating-point operations (Flops), are evaluated for each method. The detailed results are presented in Table 10. It is important to note that the padding in the convolution layers of the ALSST increases the number of parameters and the complexity of the model. However, the padding also introduces additional learnable features, which can contribute to enhancing classification accuracy.
The experimental configurations are consistent with those previously described. The 3D-ConvSST has the most Flops. The ALSST model demonstrates a reduction in total parameters compared to HyBridSN and DMCN and a decrease in Flops compared to DMCN. When analyzing the MU, AU, and UP datasets, the ALSST exhibits fewer Flops than SSRN, although it shows an increase in Flops for the TR dataset. The ALSST has a shorter testing duration, more total parameters, more Flops, and longer training time than the morpFormer on the TR dataset. Conversely, for the MU, AU, and UP datasets, the ALSST has shorter training times than morpFormer. The ALSST tends to have more total parameters and Flops compared to other methods across these datasets. Despite these aspects, the ALSST stands out by delivering superior classification performance, highlighting its effectiveness in handling diverse datasets.

4. Discussion

4.1. Ablation Analysis

This section takes the UP dataset as an example to assess the impact of various components on performance. The first and second columns in Table 11 are the convolutional fusion feature extraction module, ASSF, shown in Figure 1. The third column of Table 11 is the multiplication for the fusion of spectral–spatial features in the ASSF. The fourth column of Table 11 is the ordinary vision transformer encoder. According to the results, the ALSST model proposed in this study achieves the highest classification accuracy, indicating that each component positively enhances the classification performance.
Table 12 illustrates the impact of employing the asymmetric convolution kernel within the ALSST. A 3D convolution kernel can be decomposed into multiple 2D convolution kernels. When a 2D kernel possesses a rank of 1, it effectively functions as a sequence of 1D convolutions and reinforces the core structure of CNNs. Therefore, the classification accuracy of the proposed model is improved.

4.2. Ratio of DropKey

DropKey is an innovative regularizer applied within MHSA to effectively address the issue of overfitting, particularly in scenarios where samples are limited. In this section, we investigate the influence of varying DropKey ratios, ranging from 0.1 to 0.9, on the classification accuracy across four distinct datasets. The experimental results, including OA, AA, and K × 100, are showcased in Figure 18, indicating dataset-specific optimal DropKey ratios. Specifically, optimal performance for the TR and UP datasets is achieved with a DropKey ratio of 0.3, while the MU dataset peaks at 0.7 and the AU dataset at 0.8. Accordingly, the DropKey ratios are set to 0.3, 0.7, 0.8, and 0.3 for the TR, MU, AU, and UP datasets to optimize classification outcomes.

4.3. Training Percentage

In this section, we conducted experiments to evaluate the performance of the proposed ALSST model across various training set sizes. The experimental configurations were consistent with the previously described settings.
The outcomes of these experiments are presented in Figure 19, illustrating the performance of the models under different training percentages. For TR, AU, and UP datasets, we designated 2%, 4%, 6%, and 8% of the total samples as the training samples. However, due to the notably uneven sample distribution of the MU dataset, 5%, 10%, 15%, and 20% of the total samples are selected for training. Our experiments demonstrated a significant improvement in the accuracies of all methods as the size of the training set increased. The ALSST model displayed superior performance across all scenarios, especially showing a marked increase in accuracy on the MU dataset. This enhancement is attributed to the capacity to leverage rich learnable features of the ALSST, which allows for more effective adaptation to uneven distributions and thus improves accuracy. Furthermore, the effectiveness of the ALSST across all datasets underscores its broad applicability in tasks that involve spectral–spatial feature fusion and classification.

5. Conclusions

In this article, an adaptive learning spectral–spatial fusion model named ALSST is proposed. Firstly, a dual-branch ASSF is to extract spectral–spatial fusion features, which mainly includes the PDWA and the ADWA. The PDWA could extract the spectral information of HSIs. The ADWA could extract the spatial information of HSIs. Moreover, a transformer model that amalgamates MHSA and MLP is utilized to thoroughly leverage the correlations and heterogeneities among spectral–spatial features. Then, by adding a layer scale and DropKey to the primary transformer encoder and SA, the data dynamics are improved, and the influence of transformer depth on model classification performance is alleviated. Numerous experiments were executed across four HSI datasets to evaluate the performance of the ALSST in comparison with existing classification methods, aiming to validate its effectiveness and componential contributions. The outcomes of these experiments affirm the method’s effectiveness and its superior performance, underscoring the advantages of the ALSST in HSIC tasks. The inclusion of data padding in ASSF results an increase in model complexity and parameters. Consequently, a future direction for research is to focus on the development of a model that is both precise and lightweight, balancing the need for detailed feature extraction with the imperative for computational efficiency.

Author Contributions

Conceptualization, M.W., Y.S. and J.X.; methodology, software, validation, writing–original draft, M.W., Y.S. and R.S.; writing—review and editing, M.W., Y.S. and Y.Z.; supervision, J.X. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the Fundamental Research Funds for the Central Universities, grant number 3072022CF0801, the National Key R&D Program of China, grant number 2018YFE0206500, and the National Key Laboratory of Communication Anti Jamming Technology, grant number 614210202030217.

Data Availability Statement

The University of Pavia dataset used in this study is available at https://www.ehu.eus/ccwintco/index.php?title=Hyperspectral_Remote_Sensing_Scenes, the MUUFL dataset is available at https://github.com/GatorSense/MUUFLGulfport/, and the Trento and Augsburg datasets are available at https://github.com/AnkurDeria/MFT?tab=readme-ov-file. All the websites can be accessed on 15 March 2024.

Acknowledgments

The authors gratefully thank the peer researchers for their source codes and all the public HSI datasets.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Czaja, W.; Kavalerov, I.; Li, W. Exploring the High Dimensional Geometry of HSI Features. In Proceedings of the 2021 11th Workshop on Hyperspectral Imaging and Signal Processing: Evolution in Remote Sensing (WHISPERS), Amsterdam, The Netherlands, 24–26 March 2021; pp. 1–5. [Google Scholar]
  2. Mahlein, A.; Oerke, E.; Steiner, U.; Dehne, H. Recent Advances in Sensing Plant Diseases for Precision Crop Protection. Eur. J. Plant Pathol. 2012, 133, 197–209. [Google Scholar] [CrossRef]
  3. Shimoni, M.; Haelterman, R.; Perneel, C. Hyperspectral imaging for military and security applications: Combining myriad processing and sensing techniques. IEEE Geosci. Remote Sens. Mag. 2019, 7, 101–117. [Google Scholar] [CrossRef]
  4. Hestir, E.; Brando, V.; Bresciani, M.; Giardino, C.; Matta, E.; Villa, P.; Dekker, A. Measuring Freshwater Aquatic Ecosystems: The Need for a Hyperspectral Global Mapping Satellite Mission. Remote Sens. Environ. 2015, 167, 181–195. [Google Scholar] [CrossRef]
  5. Xu, Y.; Du, B.; Zhang, F.; Zhang, L. Hyperspectral Image Classification Via a Random Patches Network. ISPRS J. Photogramm. Remote Sens. 2018, 142, 344–357. [Google Scholar] [CrossRef]
  6. Wu, X.; Hong, D.; Chanussot, J. UIU-Net: U-Net in U-Net for infrared small object detection. IEEE Trans. Image Process. 2023, 32, 364–376. [Google Scholar] [CrossRef] [PubMed]
  7. Vaishnavi, B.B.S.; Pamidighantam, A.; Hema, A.; Syam, V.R. Hyperspectral Image Classification for Agricultural Applications. In Proceedings of the IEEE 2022 International Conference on Electronics and Renewable Systems (ICEARS), Tuticorin, India, 16–18 March 2022; pp. 1–7. [Google Scholar]
  8. Schimleck, L.; Ma, T.; Inagaki, T.; Tsuchikawa, S. Review of Near Infrared Hyperspectral Imaging Applications Related to Wood and Wood Products. Appl. Spectrosc. Rev. 2022, 57, 2098759. [Google Scholar] [CrossRef]
  9. Liao, X.; Liao, G.; Xiao, L. Rapeseed Storage Quality Detection Using Hyperspectral Image Technology–An Application for Future Smart Cities. J. Test. Eval. 2022, 51, JTE20220073. [Google Scholar] [CrossRef]
  10. Xiang, J.H.; Wei, C.; Wang, M.H.; Teng, L. End-to-End Multilevel Hybrid Attention Framework for Hyperspectral Image Classification. IEEE Geosci. Remote Sens. Let. 2022, 19, 5511305. [Google Scholar] [CrossRef]
  11. Feng, J.; Bai, G.; Li, D.; Zhang, X.G.; Shang, R.H.; Jiao, L.C. MR-Selection: A Meta-Reinforcement Learning Approach for Zero-Shot Hyperspectral Band Selection. IEEE Trans. Geosci. Remote Sens. 2022, 61, 5500320. [Google Scholar] [CrossRef]
  12. Ma, X.; Zhang, X.; Tang, X.; Zhou, H.; Jiao, L. Hyperspectral Anomaly Detection Based on Low-Rank Representation with DataDriven Projection and Dictionary Construction. IEEE J. Sel. Top. Appl. Earth Obs. Remote Sens. 2020, 13, 2226–2239. [Google Scholar] [CrossRef]
  13. Hong, D.; Wu, X.; Ghamisi, P.; Chanussot, J.; Yokoya, N.; Zhu, X.X. Invariant attribute profiles: A Spatial-Frequency Joint Feature Extractor for Hyperspectral Image Classification. IEEE Trans. Geosci. Remote Sens. 2020, 58, 3791–3808. [Google Scholar] [CrossRef]
  14. Bruzzone, L.; Roli, F.; Serpico, S.B. An Extension of the Ieffreys–Matusita Distance to Multiclasscases for Feature Selection. IEEE Tran. Geosci. Remote Sens. 1995, 33, 1318–1321. [Google Scholar] [CrossRef]
  15. Keshava, N. Distance Metrics and Band Selection in Hyperspectral Processing with Applications to Material Identification and Spectral Libraries. IEEE Trans. Geosci. Remote Sens. 2004, 42, 1552–1565. [Google Scholar] [CrossRef]
  16. Prasad, S.; Bruce, L.M. Limitations of Principal Components Analysis for Hyperspectral Target Recognition. IEEE Geosci. Remote Sens. Let. 2008, 5, 625–629. [Google Scholar] [CrossRef]
  17. Villa, A.; Benediktsson, J.A.; Chanussot, J. Hyperspectral Image Classification with Independent Component Discriminant Analysis. IEEE Geosci. Remote Sens. 2011, 49, 4865–4876. [Google Scholar] [CrossRef]
  18. Bandos, T.V.; Bruzzone, L.; Camps–Valls, G. Classification of Hyperspectral Images with Regularized Linear Discriminant Analysis. IEEE Geosci. Remote Sens. 2009, 47, 862–873. [Google Scholar] [CrossRef]
  19. Friedl, M.A.; Brodley, C.E. Decision Tree Classification of Land Cover from Remotely Sensed Data. Remote Sens. Environ. 1997, 61, 399–409. [Google Scholar] [CrossRef]
  20. Melgani, F.; Bruzzone, L. Classification of Hyperspectral Remote Sensing Images with Support Vector Machines. IEEE Geosci. Remote Sens. 2004, 42, 1778–1790. [Google Scholar] [CrossRef]
  21. Blanzieri, E.; Melgani, F. Nearest Neighbor Classification of Remote Sensing Images with the Maximal Margin Principle. IEEE Geosci. Remote Sens. 2008, 46, 1804–1811. [Google Scholar] [CrossRef]
  22. Lu, Y.; Wang, L.; Shi, Y. Classification of Hyperspectral Image with Small-Sized Samples Based on Spatial–Spectral Feature Enhancement. J. Harbin Eng. Univ. 2022, 43, 436–443. [Google Scholar]
  23. Zhang, R.; Xu, L.; Yu, Z.; Shi, Y.; Mu, C.; Xu, M. Deep-IRTarget: An automatic target detector in infrared imagery using dual-domain feature extraction and allocation. IEEE Trans. Multimed. 2022, 24, 1735–1749. [Google Scholar] [CrossRef]
  24. Zhang, R.; Cao, Z.; Yang, S.; Si, L.; Sun, H.; Xu, L.; Sun, F. Cognition-Driven Structural Prior for Instance-Dependent Label Transition Matrix Estimation. IEEE Trans. Neural Netw. Learn. Syst. 2024, 35, 38190682. [Google Scholar] [CrossRef] [PubMed]
  25. Zhang, R.; Tan, J.; Cao, Z.; Xu, L.; Liu, Y.; Si, L.; Sun, F. Part-Aware Correlation Networks for Few-shot Learning. IEEE Trans. Multimedia. 2024, 1–13. [Google Scholar] [CrossRef]
  26. Zhang, R.; Yang, S.; Zhang, Q.; Xu, L.; He, Y.; Zhang, F. Graph-based few-shot learning with transformed feature propagation and optimal class allocation. Neuro Comput. 2022, 470, 247–256. [Google Scholar] [CrossRef]
  27. Hong, Q.Q.; Zhong, X.Y.; Chen, W.T.; Zhang, Z.G.; Li, B. SATNet: A Spatial Attention Based Network for Hyperspectral Image Classification. Remote Sens. 2022, 14, 5902. [Google Scholar] [CrossRef]
  28. Chen, Y.; Lin, Z.; Zhao, X.; Wang, G.; Gu, Y. Deep Learning-Based Classification of Hyperspectral Data. IEEE J. Sel. Top. Appl. Earth Obs. Remote Sens. 2014, 7, 2094–2107. [Google Scholar] [CrossRef]
  29. Chen, Y.; Zhao, X.; Jia, X. Spectral–Spatial Classification of Hyperspectral Data Based on Deep Belief Network. IEEE J. Sel. Top. Appl. Earth Obs. Remote Sens. 2015, 8, 2381–2392. [Google Scholar] [CrossRef]
  30. Chen, Y.; Jiang, H.; Li, C.; Jia, X.; Ghamisi, P. Deep Feature Extraction and Classification of Hyperspectral Images Based on Convolutional Neural Networks. IEEE Trans. Geosci. Remote Sens. 2016, 54, 6232–6251. [Google Scholar] [CrossRef]
  31. Hong, D.; Gao, L.; Yao, J.; Zhang, B.; Plaza, A.; Chanussot, J. Graph Convolutional Networks for Hyperspectral Image Classification. IEEE Trans. Geosci. Remote Sens. 2020, 59, 5966–5978. [Google Scholar] [CrossRef]
  32. He, X.; Chen, Y.; Li, Q. Two-Branch Pure Transformer for Hyperspectral Image Classification. IEEE Geosci. Remote Sens. Lett. 2022, 19, 6015005. [Google Scholar] [CrossRef]
  33. Zhu, K.; Chen, Y.; Ghamisi, P.; Jia, X.; Benediktsson, J.A. Deep Convolutional Capsule Network for Hyperspectral Image Spectral and Spectral-Spatial Classification. Remote Sens. 2019, 11, 223. [Google Scholar] [CrossRef]
  34. Feng, J.; Yu, H.; Wang, L.; Cao, X.; Zhang, X.; Jiao, L. Classification of Hyperspectral Images Based on Multiclass Spatial–Spectral Generative Adversarial Networks. IEEE Trans. Geosci. Remote Sens. 2019, 57, 5329–5343. [Google Scholar] [CrossRef]
  35. Roy, S.K.; Krishna, G.; Dubey, S.R.; Chaudhuri, B.B. HybridSN: Exploring 3-D–2-D CNN feature hierarchy for hyperspectral image classification. IEEE Geosci. Remote Sens. Lett. 2020, 17, 277–281. [Google Scholar] [CrossRef]
  36. Sun, Y.; Wang, M.; Wei, C.; Zhong, Y.; Xiang, J. Heterogeneous spectral-spatial network with 3D attention and MLP for hyperspectral image classification using limited training samples. IEEE J. Sel. Top. Appl. Earth Obs. Remote Sens. 2023, 16, 8702–8720. [Google Scholar] [CrossRef]
  37. Hong, D.; Han, Z.; Yao, J. SpectralFormer: Rethinking hyperspectral image classification with transformers. IEEE Trans. Geosci. Remote Sens. 2022, 60, 5518615. [Google Scholar] [CrossRef]
  38. Sun, L.; Zhao, G.; Zheng, Y.; Wu, Z. Spectral–spatial feature tokenization transformer for hyperspectral image classification. IEEE Trans. Geosci. Remote Sens. 2022, 60, 1–14. [Google Scholar] [CrossRef]
  39. Wang, A.; Xing, S.; Zhao, Y.; Wu, H.; Iwahori, Y. A hyperspectral image classification method based on adaptive spectral spatial kernel combined with improved vision transformer. Remote Sens. 2022, 14, 3705. [Google Scholar] [CrossRef]
  40. Huang, X.; Dong, M.; Li, J.; Guo, X. A 3-d-swin transformer-based hierarchical contrastive learning method for hyperspectral image classification. IEEE Trans. Geosci. Remote Sens. 2022, 60, 5411415. [Google Scholar] [CrossRef]
  41. Fang, Y.; Ye, Q.; Sun, L.; Zheng, Y.; Wu, Z. Multi-attention joint convolution feature representation with lightweight transformer for hyperspectral image classification. IEEE Trans. Geosci. Remote Sens. 2023, 61, 5513814. [Google Scholar] [CrossRef]
  42. Gulati, A.; Qin, J.; Chiu, C.C. Conformer: Convolution-augmented transformer for speech recognition. arXiv 2020, arXiv:2005.08100. [Google Scholar]
  43. Wang, Y.; Li, Y.; Wang, G.; Liu, X. Multi-scale attention network for single image super-resolution. arXiv 2022, arXiv:2209.14145. [Google Scholar]
  44. Hendrycks, D.; Gimpel, K. Gaussian Error Linear Units (gelus). arXiv 2016, arXiv:1606.08415. [Google Scholar]
  45. Touvron, H.; Cord, M.; Sablayrolles, A. Going deeper with image transformers. arXiv 2021, arXiv:2103.17239v2. [Google Scholar]
  46. Li, B.; Hu, Y.; Nie, X.; Han, C.; Jiang, X.; Guo, T.; Liu, L. DropKey. arXiv 2023, arXiv:2208.02646v4. [Google Scholar]
  47. Gader, P.; Zare, A.; Close, R.; Aitken, J.; Tuell, G. Muufl Gulfport Hyperspectral and LiDAR Airborne Data Set; Technical Report REP-2013–570; University of Florida: Gainesville, FL, USA, 2013. [Google Scholar]
  48. Du, X.; Zare, A. Scene Label Ground T ruth Map for Muufl Gulfport Data Set; Technical Report 20170417; University of Florida: Gainesville, FL, USA, 2017. [Google Scholar]
  49. Li, Y.; Zhang, H.K.; Shen, Q. Spectral–Spatial Classification of Hyperspectral Imagery with 3D Convolutional Neural Network. Remote Sens. 2017, 9, 67. [Google Scholar] [CrossRef]
  50. Zhong, Z.; Li, J.; Luo, Z.; Chapman, M. Spectral–Spatial Residual Network for Hyperspectral Image Classification: A 3-D Deep Learning Framework. IEEE Trans. Geosci. Remote Sens. 2018, 56, 847–858. [Google Scholar] [CrossRef]
  51. Swalpa, K.R.; Ankur, D.; Shah, C. Spectral–spatial morphological attention transformer for hyperspectral image classification. IEEE Trans. Geosci. Remote Sens. 2022, 61, 5503615. [Google Scholar]
  52. Shyam, V.; Aryaman, S.; Shiv, R.D.; Satish, K.S. 3D-Convolution Guided Spectral-Spatial Transformer for Hyperspectral Image Classification. arXiv 2024, arXiv:2404.13252. [Google Scholar]
Figure 1. Structure for proposed ALSST model. (The ASSF is proposed to exclude the fully connected layers and capture local continuity while considering complexity. The multiplication is used to fusion the spectral–spatial features. The LD-Former is designed to increase the data dynamics and prevent performance degradation as the transformer deepens. In this figure, H × W × B is the size of the original HSI, H × W × L is the size of HSI after PCA, and P × P × L is the patches size).
Figure 1. Structure for proposed ALSST model. (The ASSF is proposed to exclude the fully connected layers and capture local continuity while considering complexity. The multiplication is used to fusion the spectral–spatial features. The LD-Former is designed to increase the data dynamics and prevent performance degradation as the transformer deepens. In this figure, H × W × B is the size of the original HSI, H × W × L is the size of HSI after PCA, and P × P × L is the patches size).
Remotesensing 16 01912 g001
Figure 2. Structure for proposed ASSF. PDWA is used to extract the spectral features of HSI, and ADWA is used to extract the spatial features of HSI.
Figure 2. Structure for proposed ASSF. PDWA is used to extract the spectral features of HSI, and ADWA is used to extract the spatial features of HSI.
Remotesensing 16 01912 g002
Figure 3. Structure for proposed LD-Former. In this paper, MHDSA is the DropKey multi-head self-attention, ADD is the residual connection, MLP is the multi-layer perceptron, and NORM is the layer norm. N is the times of the encoder loops.
Figure 3. Structure for proposed LD-Former. In this paper, MHDSA is the DropKey multi-head self-attention, ADD is the residual connection, MLP is the multi-layer perceptron, and NORM is the layer norm. N is the times of the encoder loops.
Remotesensing 16 01912 g003
Figure 4. Structure for proposed MHDSA. Q, K, and V are query, key, and value matrices.
Figure 4. Structure for proposed MHDSA. Q, K, and V are query, key, and value matrices.
Remotesensing 16 01912 g004
Figure 5. TR dataset. (a) Pseudo-color image; (b) Ground-truth image.
Figure 5. TR dataset. (a) Pseudo-color image; (b) Ground-truth image.
Remotesensing 16 01912 g005
Figure 6. MU dataset. (a) Pseudo-color image; (b) Ground-truth image.
Figure 6. MU dataset. (a) Pseudo-color image; (b) Ground-truth image.
Remotesensing 16 01912 g006
Figure 7. AU dataset. (a) Pseudo-color image; (b) Ground-truth image.
Figure 7. AU dataset. (a) Pseudo-color image; (b) Ground-truth image.
Remotesensing 16 01912 g007
Figure 8. UP dataset. (a) Pseudo-color image; (b) Ground-truth image.
Figure 8. UP dataset. (a) Pseudo-color image; (b) Ground-truth image.
Remotesensing 16 01912 g008
Figure 9. Combined effect of the heads for attention, and the depth for encoders on four datasets. (a) TR dataset (8 + 1); (b) MU dataset (8 + 1); (c) AU dataset (4 + 1); (d) UP dataset (8 + 1). The horizontal axis represents the attention heads, while the vertical axis denotes the OA (%). The green represents one encoder depth and fusion block depth, and the orange represents two encoder depths and fusion block depths.
Figure 9. Combined effect of the heads for attention, and the depth for encoders on four datasets. (a) TR dataset (8 + 1); (b) MU dataset (8 + 1); (c) AU dataset (4 + 1); (d) UP dataset (8 + 1). The horizontal axis represents the attention heads, while the vertical axis denotes the OA (%). The green represents one encoder depth and fusion block depth, and the orange represents two encoder depths and fusion block depths.
Remotesensing 16 01912 g009
Figure 10. Classification images of different methods on TR dataset. (a) Ground-truth Image; (b) LiEtAl (98.10%); (c) SSRN (98.91%); (d) HyBridSN (98.57%); (e) DMCN (99.35%); (f) SpectralFormer (97.99%); (g) SSFTT (98.18%); (h) morpFormer (99.02%); (i) 3D-ConvSST (99.58%); (j) ALSST (99.70%).
Figure 10. Classification images of different methods on TR dataset. (a) Ground-truth Image; (b) LiEtAl (98.10%); (c) SSRN (98.91%); (d) HyBridSN (98.57%); (e) DMCN (99.35%); (f) SpectralFormer (97.99%); (g) SSFTT (98.18%); (h) morpFormer (99.02%); (i) 3D-ConvSST (99.58%); (j) ALSST (99.70%).
Remotesensing 16 01912 g010
Figure 11. T-SNE visualization on the TR dataset with different methods. (a) LiEtAl (98.10%); (b) SSRN (98.91%); (c) HyBridSN (98.57%); (d) DMCN (99.35%); (e) SpectralFormer (97.99%); (f) SSFTT (98.18%); (g) morpFormer (99.02%); (h) 3D-ConvSST (99.58%); (i) ALSST (99.70%).
Figure 11. T-SNE visualization on the TR dataset with different methods. (a) LiEtAl (98.10%); (b) SSRN (98.91%); (c) HyBridSN (98.57%); (d) DMCN (99.35%); (e) SpectralFormer (97.99%); (f) SSFTT (98.18%); (g) morpFormer (99.02%); (h) 3D-ConvSST (99.58%); (i) ALSST (99.70%).
Remotesensing 16 01912 g011
Figure 12. Classification images of different methods on MU dataset. (a) Ground-truth Image; (b) LiEtAl (82.88%); (c) SSRN (86.94%); (d) HyBridSN (85.22%); (e) DMCN (87.39%); (f) SpectralFormer (87.08%); (g) SSFTT (87.06%); (h) morpFormer (84.96%); (i) 3D-ConvSST (86.21%); (j) ALSST (89.72%).
Figure 12. Classification images of different methods on MU dataset. (a) Ground-truth Image; (b) LiEtAl (82.88%); (c) SSRN (86.94%); (d) HyBridSN (85.22%); (e) DMCN (87.39%); (f) SpectralFormer (87.08%); (g) SSFTT (87.06%); (h) morpFormer (84.96%); (i) 3D-ConvSST (86.21%); (j) ALSST (89.72%).
Remotesensing 16 01912 g012
Figure 13. T-SNE visualization on the MU dataset with different methods. (a) LiEtAl (82.88%); (b) SSRN (86.94%); (c) HyBridSN (85.22%); (d) DMCN (87.39%); (e) SpectralFormer (87.08%); (f) SSFTT (87.06%); (g) morpFormer (84.96%); (h) 3D-ConvSST (86.21%); (i) ALSST (89.72%).
Figure 13. T-SNE visualization on the MU dataset with different methods. (a) LiEtAl (82.88%); (b) SSRN (86.94%); (c) HyBridSN (85.22%); (d) DMCN (87.39%); (e) SpectralFormer (87.08%); (f) SSFTT (87.06%); (g) morpFormer (84.96%); (h) 3D-ConvSST (86.21%); (i) ALSST (89.72%).
Remotesensing 16 01912 g013
Figure 14. Classification images of different methods on AU dataset. (a) Ground-truth Image; (b) LiEtAl (94.84%); (c) SSRN (97.41%); (d) HyBridSN (96.50%); (e) DMCN (96.24%); (f) SpectralFormer (93.89%); (g) SSFTT (97.08%); (h) morpFormer (96.85%); (i) 3D-ConvSST (97.14%); (j) ALSST (97.84%).
Figure 14. Classification images of different methods on AU dataset. (a) Ground-truth Image; (b) LiEtAl (94.84%); (c) SSRN (97.41%); (d) HyBridSN (96.50%); (e) DMCN (96.24%); (f) SpectralFormer (93.89%); (g) SSFTT (97.08%); (h) morpFormer (96.85%); (i) 3D-ConvSST (97.14%); (j) ALSST (97.84%).
Remotesensing 16 01912 g014
Figure 15. T-SNE visualization on the AU dataset with different methods. (a) LiEtAl (94.84%); (b) SSRN (97.41%); (c) HyBridSN (96.50%); (d) DMCN (96.24%); (e) SpectralFormer (93.89%); (f) SSFTT (97.08%); (g) morpFormer (96.85%); (h) 3D-ConvSST (97.14%); (i) ALSST (97.84%).
Figure 15. T-SNE visualization on the AU dataset with different methods. (a) LiEtAl (94.84%); (b) SSRN (97.41%); (c) HyBridSN (96.50%); (d) DMCN (96.24%); (e) SpectralFormer (93.89%); (f) SSFTT (97.08%); (g) morpFormer (96.85%); (h) 3D-ConvSST (97.14%); (i) ALSST (97.84%).
Remotesensing 16 01912 g015
Figure 16. Classification images of different methods on UP dataset. (a) Ground-truth Image; (b) LiEtAl (97.86%); (c) SSRN (99.56%); (d) HyBridSN (98.49%); (e) DMCN (99.20%); (f) SpectralFormer (98.01%); (g) SSFTT (99.46%); (h) morpFormer (99.26%); (i) 3D-ConvSST (99.52%); (j) ALSST (99.78%).
Figure 16. Classification images of different methods on UP dataset. (a) Ground-truth Image; (b) LiEtAl (97.86%); (c) SSRN (99.56%); (d) HyBridSN (98.49%); (e) DMCN (99.20%); (f) SpectralFormer (98.01%); (g) SSFTT (99.46%); (h) morpFormer (99.26%); (i) 3D-ConvSST (99.52%); (j) ALSST (99.78%).
Remotesensing 16 01912 g016
Figure 17. T-SNE visualization on the UP dataset. (a) LiEtAl (97.86%); (b) SSRN (99.56%); (c) HyBridSN (98.49%); (d) DMCN (99.20%); (e) SpectralFormer (98.01%); (f) SSFTT (99.46%); (g) morpFormer (99.26%); (h) 3D-ConvSST (99.52%); (i) ALSST (99.78%).
Figure 17. T-SNE visualization on the UP dataset. (a) LiEtAl (97.86%); (b) SSRN (99.56%); (c) HyBridSN (98.49%); (d) DMCN (99.20%); (e) SpectralFormer (98.01%); (f) SSFTT (99.46%); (g) morpFormer (99.26%); (h) 3D-ConvSST (99.52%); (i) ALSST (99.78%).
Remotesensing 16 01912 g017
Figure 18. OA (%), AA (%), and K×100 on different ratio of DropKey. (a) TR dataset; (b) MU dataset; (c) AU dataset; (d) UP dataset. In the blue dashed box is the ratio corresponding to the best accuracy.
Figure 18. OA (%), AA (%), and K×100 on different ratio of DropKey. (a) TR dataset; (b) MU dataset; (c) AU dataset; (d) UP dataset. In the blue dashed box is the ratio corresponding to the best accuracy.
Remotesensing 16 01912 g018
Figure 19. OA (%) of different training percentage on all methods. (a) TR dataset; (b) MU dataset; (c) AU dataset; (d) UP dataset. The accuracies of all evaluated methods demonstrated significant improvement as the number of training samples increased. Notably, the ALSST model consistently outperformed the other methods in every scenario, showcasing its superior effectiveness.
Figure 19. OA (%) of different training percentage on all methods. (a) TR dataset; (b) MU dataset; (c) AU dataset; (d) UP dataset. The accuracies of all evaluated methods demonstrated significant improvement as the number of training samples increased. Notably, the ALSST model consistently outperformed the other methods in every scenario, showcasing its superior effectiveness.
Remotesensing 16 01912 g019
Table 1. Details on TR dataset.
Table 1. Details on TR dataset.
No.ColorClass NameTraining SamplesTest Samples
1Remotesensing 16 01912 i001Apple Trees1293905
2Buildings1252778
3Ground105374
4Woods1549896
5Vineyard18410,317
6Roads1223052
Total81929,395
Table 2. Details on MU dataset.
Table 2. Details on MU dataset.
No.ColorClass NameTraining SamplesTest Samples
1Remotesensing 16 01912 i002Trees15023,096
2Mostly Grass1504120
3Mixed Ground Surface1506732
4Dirt and Sand1501676
5Road1506537
6Water150316
7Buildings Shadow1502083
8Buildings1506090
9Sidewalk1501235
10Yellow Curb15033
11Cloth Panels150119
Total165052,037
Table 3. Details on AU dataset.
Table 3. Details on AU dataset.
No.ColorClass NameTraining SamplesTest Samples
1Remotesensing 16 01912 i003Forest67512,832
2Residential Area151628,813
3Industrial Area1923659
4Low Plants134225,515
5Allotment28547
6Commercial Area821563
7Water161454
Total391174,383
Table 4. Details on UP dataset.
Table 4. Details on UP dataset.
No.ColorClass NameTraining SamplesTest Samples
1Remotesensing 16 01912 i004Asphalt3326299
2Meadows93217,717
3Gravel1051994
4Trees1532911
5Metal sheets671278
6Bare soil2514778
7Bitumen671263
8Bricks1843498
9Shadow47900
Total213840,638
Table 10. Total parameters, training time, testing time, and Flops of all methods on different datasets (Bold represents the best accuracy).
Table 10. Total parameters, training time, testing time, and Flops of all methods on different datasets (Bold represents the best accuracy).
MethodsTPsTr (s)Te (s)FlopsOA (%)TPsTr (s)Te (s)FlopsOA (%)
TRMU
LiEtAl36.64 K4.560.3540.21 M98.10 ± 0.2466.89 K6.850.5642.14 M82.88 ± 2.30
SSRN 102.80 K11.760.892.102 G98.91 ± 0.55102.92 K22.721.622.10 G86.94 ± 0.87
HyBridSN1.52 M5.230.55416.79 M98.57 ± 0.22 1.15 M9.410.92416.83 M85.22 ± 1.47
DMCN2.77 M20.221.693.21 G99.35 ± 0.172.77 M34.403.043.21 G87.39 ± 1.12
SpectralFormer97.33 K46.803.55192.68 M97.99 ± 0.6497.65 K93.226.22192.70 M87.08 ± 1.24
SSFTT147.84 K22.081.51447.18 M99.18 ± 0.12148.16 K38.062.78447.20 M87.06 ± 0.85
morpFormer62.56 K38.364.38334.43 M99.02 ± 0.2862.56 K77.677.11334.43 M84.96 ± 1.10
3D-ConvSST499.04 K33.473.037.95 G99.58 ± 0.08499.37 K66.445.367.95 G86.21 ± 0.70
ALSST157.06 K40.903.781.53 G99.70 ± 0.03157.39 K38.703.141.53 G89.72 ± 0.36
MethodsAUUP
LiEtAl42.69 K12.950.8440.59 M94.84 ± 0.3954.79 K7.210.5241.37 M97.86 ± 0.39
SSRN 102.82 K54.832.482.10 G97.41 ± 0.24102.87 K33.101.482.10 G99.56 ± 0.09
HyBridSN1.15 M17.941.05416.80 M96.50 ± 0.081.15 M10.020.57416.81 M98.49 ± 0.16
DMCN2.77 M76.963.823.21 G96.24 ± 1.362.77 M42.022.193.21 G99.20 ± 0.13
SpectralFormer97.39 K202.328.03192.68 M93.89 ± 0.2797.52 K41.342.17192.69 M98.01 ± 0.11
SSFTT147.90 K93.013.97447.18 M97.08 ± 0.18148.03 K19.841.15447.19 M99.46 ± 0.15
morpFormer62.56 K185.3810.22334.43 M96.85 ± 0.0762.56 K 102.126.46334.43 M99.26 ± 0.05
3D-ConvSST499.11 K155.337.937.95 G97.14 ± 0.18499.24 K85.224.287.95 G99.52 ± 0.06
ALSST157.13 K66.453.181.53 G97.84 ± 0.09157.26 K45.502.171.53 G99.78 ± 0.03
Table 11. Effect of different combinations on ALSST (Rows represent different combinations, √ indicates that the component exists, ⊗ represents the multiplication of spectral–spatial features, and the bold represents the best accuracy).
Table 11. Effect of different combinations on ALSST (Rows represent different combinations, √ indicates that the component exists, ⊗ represents the multiplication of spectral–spatial features, and the bold represents the best accuracy).
PDWAADWA TELD-FormerOA (%)AA (%)K × 100
Layer ScaleDropKey
78.06 ± 1.0563.62 ± 1.0570.43 ± 1.31
99.53 ± 0.0599.06 ± 0.0999.38 ± 0.07
99.57 ± 0.0499.11 ± 0.1199.44 ± 0.06
99.73 ± 0.0299.47 ± 0.0599.64 ± 0.03
99.52 ± 0.0498.99 ± 0.0799.37 ± 0.05
99.51 ± 0.0599.10 ± 0.0699.35 ± 0.06
99.56 ± 0.2199.12 ± 0.2999.42 ± 0.27
99.65 ± 0.2799.44 ± 0.3399.53 ± 0.36
99.78 ± 0.0399.57 ± 0.0899.71 ± 0.04
Table 12. The effect of asymmetric convolution for ALSST (Bold represents the best accuracy).
Table 12. The effect of asymmetric convolution for ALSST (Bold represents the best accuracy).
Kernel SizeOA (%)AA (%)K × 100
3 × 3 99.57 ± 0.0599.12 ± 0.0999.43 ± 0.06
1 × 3 and 3 × 1 99.78 ± 0.0399.57 ± 0.0899.71 ± 0.04
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Wang, M.; Sun, Y.; Xiang, J.; Sun, R.; Zhong, Y. Adaptive Learnable Spectral–Spatial Fusion Transformer for Hyperspectral Image Classification. Remote Sens. 2024, 16, 1912. https://doi.org/10.3390/rs16111912

AMA Style

Wang M, Sun Y, Xiang J, Sun R, Zhong Y. Adaptive Learnable Spectral–Spatial Fusion Transformer for Hyperspectral Image Classification. Remote Sensing. 2024; 16(11):1912. https://doi.org/10.3390/rs16111912

Chicago/Turabian Style

Wang, Minhui, Yaxiu Sun, Jianhong Xiang, Rui Sun, and Yu Zhong. 2024. "Adaptive Learnable Spectral–Spatial Fusion Transformer for Hyperspectral Image Classification" Remote Sensing 16, no. 11: 1912. https://doi.org/10.3390/rs16111912

APA Style

Wang, M., Sun, Y., Xiang, J., Sun, R., & Zhong, Y. (2024). Adaptive Learnable Spectral–Spatial Fusion Transformer for Hyperspectral Image Classification. Remote Sensing, 16(11), 1912. https://doi.org/10.3390/rs16111912

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop