Abstract
Salvia miltiorrhiza Bunge (Danshen) is widely used in modern medicine, but the market faces challenges from counterfeit and mislabeled geographical indication products. To address this, we propose a novel framework combining Two-trace Two-dimensional (2T2D) correlation spectroscopy, hyperspectral imaging (HSI), transfer learning, and an enhanced deep learning model (DeiT-CBAM) to identify both authenticity and origin precisely. Hyperspectral data (873-1720 nm) were collected from six genuine and three adulterated regions and converted into synchronous 2T2D correlation spectroscopy images. We systematically evaluated five preprocessing strategies, three wavelength selection methods, three classical models, and four deep learning models. Models based on 2T2D correlation spectroscopy images consistently outperformed traditional one-dimensional spectral models. Notably, the DeiT-CBAM model, integrated with the successive projections algorithm (SPA), achieved optimal performance using only 79 wavelengths, with 100% accuracy on the training and validation sets and 99.62% on the test set, without the need for additional preprocessing. Model interpretability was further validated through layer-wise class activation mapping (layer-wise CAM). This study demonstrates that the integration of synchronous 2T2D correlation spectroscopy images with the DeiT-CBAM model offers robust discriminative performance, providing a reliable technical solution for geographical origin traceability of food, medicinal herbs, and other species.