Hyperspectral image classification based on dual-feature transformation fusion transformer
摘要
Hyperspectral image (HSI) classification is a key task in remote sensing. The rich spatial and spectral information in HSI provides essential data for classification but also poses significant processing challenges. The integration of Convolutional Neural Networks (CNNs) and Transformer models demonstrates strong data comprehension capabilities in HSI classification. However, current CNN-Transformer methods have certain limitations. Their feature extraction is relatively coarse, and they employ a single linear approach to convert features into attention matrices within the Transformer, resulting in incomplete feature representation and a limited attention scope. To address these issues, we propose a Dual Feature Transformation Fusion Transformer (DFTFT) network, which can utilize features more comprehensively and increase the scope of feature attention. Specifically, a cascaded CNN combining 3D and 2D CNNs deeply extracts spatial-spectral information from HSI. Through the feature transformation module, the features are transformed into a new attention matrix using a Gaussian-initialized matrix. The resulting nonlinear attention matrix is capable of representing complex and hard-to-express features. Finally, in the Dual Feature Transformer Encoder (DFTE) module, the Dual Fusion Attention (DFA) block integrates the attention matrix obtained from the feature transformation module with the attention matrix generated by the Transformer, thereby enhancing feature utilization and broadening the feature spectrum. Extensive experiments were conducted on three datasets, demonstrating that the proposed method outperforms state-of-the-art approaches. Our code is available at: https://github.com/liumeitong300/DFTFT.