Anomaly Detection in Mineral Micro-X-Ray Fluorescence Spectroscopy Based on a Multi-Scale Feature Aggregation Network
Abstract
1. Introduction
- 1
- We design an unsupervised MSFA-Net based on an autoencoder architecture, enabling end-to-end anomaly detection and reconstruction while jointly modeling spatial features and reconstruction errors.
- 2
- We introduce a multi-scale orthogonal attention (MOA) module to effectively integrate and disentangle spatial–spectral features at different scales, enhancing the model’s ability to discriminate subtle mineral anomalies within mixed pixels.
- 3
- We incorporate a DBSCAN-based spatial clustering strategy to generate pseudo-labels, guiding the reconstruction loss to assign higher semantic weights to anomalous regions. This improves the anomaly response capability while reducing dependence on labels or spectral libraries.
2. Methodology
2.1. MSFA-Net Framework for Micro-XRF Anomaly Detection
2.1.1. Encoder
2.1.2. Multi-Scale Orthogonal Attention Module
2.1.3. Decoder
2.2. Feature Aggregation Module
2.3. Loss Function
2.4. Anomaly Detection
2.5. Evaluation Indices
3. Materials
3.1. Sample Description
3.2. Data Preparation
4. Results and Discussion
4.1. Detection Performance
4.1.1. Comparisons of Detection Maps
4.1.2. Comparisons of AUC and ROC
4.1.3. Comparisons of the Separability Map
4.2. Discussion
4.3. Ablation Study
5. Conclusions
- 1
- Improved detection of subtle anomalies: The proposed multi-scale orthogonal attention module effectively captures global and local spatial–spectral contexts, significantly enhancing the network’s ability to detect weak mineral anomalies in mixed pixels.
- 2
- Breaking through spatial resolution limitations: By deep modeling reconstruction errors, MSFA-Net can accurately localize fine-scale anomalies that are not visible in elemental distribution maps, enabling sub-resolution anomaly detection.
- 3
- Reduced reliance on manual labels: A weighted reconstruction loss is designed based on DBSCAN clustering and spectral angle divergence, allowing the model to assign greater attention to potential anomalous regions during training, thus improving detection performance with minimal dependence on manual labeling.
Supplementary Materials
Author Contributions
Funding
Data Availability Statement
Conflicts of Interest
Appendix A. Hyperparameter Settings of MSFA-Net
Hyperparameter | Value |
---|---|
Epochs | 150 |
Batch size | 36,000 |
Learning rate | 0.0015 |
N_clusters | 4 |
Latent_layer_dim | 64 |
Anomal_prop | 0.015 |
Bandwidth | 0.3 |
Eps | 0.1 |
Min_samples | 25 |
References
- Gao, Z.; Zhu, X.; Sun, J.; Luo, Z.; Bao, C.; Tang, C.; Ma, J. Spatial Evolution of Zn-Fe-Pb Isotopes of Sphalerite within a Single Ore Body: A Case Study from the Dongshengmiao Ore Deposit, Inner Mongolia, China. Min. Depos. 2018, 53, 55–65. [Google Scholar] [CrossRef]
- Gregory, D.D.; Large, R.R.; Halpin, J.A.; Steadman, J.A.; Hickman, A.H.; Ireland, T.R.; Holden, P. The Chemical Conditions of the Late Archean Hamersley Basin Inferred from Whole Rock and Pyrite Geochemistry with Δ33S and δ34S Isotope Analyses. Geochim. Cosmochim. Acta 2015, 149, 223–250. [Google Scholar] [CrossRef]
- Hurai, V.; Huraiová, M.; Konečný, P. REE Minerals as Geochemical Proxies of Late-Tertiary Alkalic Silicate ± Carbonatite Intrusions Beneath Carpathian Back-Arc Basin. Minerals 2021, 11, 369. [Google Scholar] [CrossRef]
- Wang, B.; Ding, Z.; Bao, Z.; Song, M.; Zhou, J.; Lv, J.; Wang, S.; Zhang, Q.; Liu, C. Mesozoic Magmatic and Geodynamic Evolution in the Jiaodong Peninsula, China: Implications for the Gold and Polymetallic Mineralization. Minerals 2022, 12, 1073. [Google Scholar] [CrossRef]
- Boltshauser, B.E.; Zaffarana, C.B.; Gallastegui, G.; Orts, D.L.; Molina, J.F.; Poma, S.M.N.; González, V.R. Petrogenetic Evolution and Thermobarometry of the Late Jurassic La Hoya Pluton, Early Stages of the North Patagonian Batholith, Southwestern Argentina. Int. J. Earth Sci. 2023, 112, 1687–1716. [Google Scholar] [CrossRef]
- Balaram, V. Advances in Analytical Techniques and Applications in Exploration, Mining, Extraction, and Metallurgical Studies of Rare Earth Elements. Minerals 2023, 13, 1031. [Google Scholar] [CrossRef]
- Yang, J.; Zhang, Z.; Cheng, Q. Resolution Enhancement in Micro-XRF Using Image Restoration Techniques. J. Anal. At. Spectrom. 2022, 37, 750–758. [Google Scholar] [CrossRef]
- Wu, L.; Bak, S.; Shin, Y.; Chu, Y.S.; Yoo, S.; Robinson, I.K.; Huang, X. Resolution-Enhanced X-Ray Fluorescence Microscopy via Deep Residual Networks. Npj Comput. Mater. 2023, 9, 43. [Google Scholar] [CrossRef]
- Nikonow, W.; Rammlmair, D. Automated Mineralogy Based on Micro-Energy-Dispersive X-Ray Fluorescence Microscopy (µ-EDXRF) Applied to Plutonic Rock Thin Sections in Comparison to a Mineral Liberation Analyzer. Geosci. Instrum. Method. Data Syst. 2017, 6, 429–437. [Google Scholar] [CrossRef]
- Liang, J.; Sun, Y.; Lebedev, M.; Gurevich, B.; Nzikou, M.; Vialle, S.; Glubokovskikh, S. Multi-Mineral Segmentation of Micro-Tomographic Images Using a Convolutional Neural Network. Comput. Geosci. 2022, 168, 105217. [Google Scholar] [CrossRef]
- Barker, R.D.; Barker, S.L.L.; Wilson, S.; Stock, E.D. Quantitative Mineral Mapping of Drill Core Surfaces I: A Method for µ XRF Mineral Calculation and Mapping of Hydrothermally Altered, Fine-Grained Sedimentary Rocks from a Carlin-Type Gold Deposit. Econ. Geol. 2021, 116, 803–819. [Google Scholar] [CrossRef]
- Tang, J.; Wang, W.; Yuan, C. A New Anisotropic Singularity Algorithm to Characterize Geo-Chemical Anomalies in the Duolong Mineral District, Tibet, China. Minerals 2023, 13, 988. [Google Scholar] [CrossRef]
- Wang, W.; Yuan, C.; Tang, J.; Ren, X.; Zhao, J. Enhancing Deep Orebody Prediction and Localization through the Revelation of Geochemical Primary Halo Patterns in Drill Holes. Appl. Geochem. 2024, 171, 106100. [Google Scholar] [CrossRef]
- Liu, C.; Wang, W.; Tang, J.; Wang, Q.; Zheng, K.; Sun, Y.; Zhang, J.; Gan, F.; Cao, B. A Deep-Learning-Based Mineral Prospectivity Modeling Framework and Workflow in Prediction of Porphyry–Epithermal Mineralization in the Duolong Ore District, Tibet. Ore Geol. Rev. 2023, 157, 105419. [Google Scholar] [CrossRef]
- Lou, W.; Zhang, D.; Bayless, R.C. Review of Mineral Recognition and Its Future. Appl. Geochem. 2020, 122, 104727. [Google Scholar] [CrossRef]
- Kim, J.J.; Ling, F.T.; Plattenberger, D.A.; Clarens, A.F.; Lanzirotti, A.; Newville, M.; Peters, C.A. SMART Mineral Mapping: Synchrotron-Based Machine Learning Approach for 2D Characterization with Coupled Micro XRF-XRD. Comput. Geosci. 2021, 156, 104898. [Google Scholar] [CrossRef]
- Xu, Y.; Zhang, L.; Du, B.; Zhang, L. Hyperspectral Anomaly Detection Based on Machine Learning: An Overview. IEEE J. Sel. Top. Appl. Earth Obs. Remote Sens. 2022, 15, 3351–3364. [Google Scholar] [CrossRef]
- Lv, S.; Zhao, S.; Li, D.; Pang, B.; Lian, X.; Liu, Y. Spatial–Spectral Joint Hyperspectral Anomaly Detection Based on a Two-Branch 3D Convolutional Autoencoder and Spatial Filtering. Remote Sens. 2023, 15, 2542. [Google Scholar] [CrossRef]
- Chen, J.; Xu, F.; Zeng, T.; Li, X.; Chen, S.; Yu, J. MSFA: Multi-stage Feature Aggregation Network for Multi-label Image Recognition. IET Image Process. 2024, 18, 1862–1877. [Google Scholar] [CrossRef]
- Sun, T.; Wang, W.; Ma, W. MSFA-Net: A Multi-Scale Feature Aggregation Network with Mixed Attention for Industrial Defect Detection. SSRN Preprint 2025. [Google Scholar] [CrossRef]
- Cheng, X.; Huo, Y.; Lin, S.; Dong, Y.; Zhao, S.; Zhang, M.; Wang, H. Deep Feature Aggregation Network for Hyperspectral Anoma ly Detection. IEEE Trans. Instrum. Meas. 2024, 73, 5033016. [Google Scholar] [CrossRef]
- Wang, Q.; Li, F.; Jiang, X.; Wu, S.; Xu, M. On-Stream Mineral Identification of Tailing Slurries of Tungsten via NIR and XRF Data Fusion Measurement Techniques. Anal. Methods 2020, 12, 3296–3307. [Google Scholar] [CrossRef] [PubMed]
- Wang, W.; Liu, Z.; Tang, J.; Yuan, C. An Enhanced Strategy for Geo-Exploratory Data Analysis to Facilitate the Discovery of New Mineral Deposits. J. Geochem. Explor. 2024, 258, 107411. [Google Scholar] [CrossRef]
- Wang, W.; Pei, Y.; Cheng, Q.; Wang, W. Local Singularity Spectrum: An Innovative Graphical Approach for Analyzing Detrital Zircon Geochronology Data in Provenance Analysis. Fractal Fract. 2024, 8, 64. [Google Scholar] [CrossRef]
- Ouyang, D.; He, S.; Zhang, G.; Luo, M.; Guo, H.; Zhan, J.; Huang, Z. Efficient Multi-Scale Attention Module with Cross-Spatial Learning. In Proceedings of the ICASSP 2023—2023 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), Rhodes Island, Greece, 4–10 June 2023; IEEE: Rhodes Island, Greece, 2023; pp. 1–5. [Google Scholar]
- Salman, H.; Parks, C.; Swan, M.; Gauch, J. OrthoNets: Orthogonal Channel Attention Networks 2023; IEEE: Los Angeles, CA, USA, 2023. [Google Scholar]
- Wang, Q.; Zhang, X.; Tang, B.; Ma, Y.; Xing, J.; Liu, L. Lithology Identification Technology Using BP Neural Network Based on XRF. Acta Geophys. 2021, 69, 2231–2240. [Google Scholar] [CrossRef]
- Long, T.; Zhou, Z.; Hancke, G.; Bai, Y.; Gao, Q. A Review of Artificial Intelligence Technologies in Mineral Identification: Classification and Visualization. J. Sens. Actuator Netw. 2022, 11, 50. [Google Scholar] [CrossRef]
- Wang, W.; Xue, C.; Zhao, J.; Yuan, C.; Tang, J. Machine Learning-Based Field Geological Mapping: A New Exploration of Geological Survey Data Acquisition Strategy. Ore Geol. Rev. 2024, 166, 105959. [Google Scholar] [CrossRef]
- Duan, L.; Xu, L.; Guo, F.; Lee, J.; Yan, B. A Local-Density Based Spatial Clustering Algorithm with Noise. Inf. Syst. 2007, 32, 978–986. [Google Scholar] [CrossRef]
- Salles, R.D.R.; De Souza Filho, C.R.; Cudahy, T.; Vicente, L.E.; Monteiro, L.V.S. Hyperspectral Remote Sensing Applied to Uranium Exploration: A Case Study at the Mary Kathleen Metamorphic-Hydrothermal U-REE Deposit, NW, Queensland, Australia. J. Geochem. Explor. 2017, 179, 36–50. [Google Scholar] [CrossRef]
- Kerekes, J. Receiver Operating Characteristic Curve Confidence Intervals and Regions. IEEE Geosci. Remote Sens. Lett. 2008, 5, 251–255. [Google Scholar] [CrossRef]
- Tan, K.; Hou, Z.; Wu, F.; Du, Q.; Chen, Y. Anomaly Detection for Hyperspectral Imagery Based on the Regularized Subspace Method and Collaborative Representation. Remote Sens. 2019, 11, 1318. [Google Scholar] [CrossRef]
- Chang, C.-I.; Chiang, S.-S. Anomaly Detection and Classification for Hyperspectral Imagery. IEEE Trans. Geosci. Remote Sens. 2002, 40, 1314–1325. [Google Scholar] [CrossRef]
- Tusa, L.; Andreani, L.; Khodadadzadeh, M.; Contreras, C.; Ivascanu, P.; Gloaguen, R.; Gutzmer, J. Mineral Mapping and Vein Detection in Hyperspectral Drill-Core Scans: Application to Porphyry-Type Mineralization. Minerals 2019, 9, 122. [Google Scholar] [CrossRef]
- Li, B.; Yang, Y.; Wang, J.; Song, Z. Mesozoic Metallogenic Characteristics and Ore-Controlling Factors in the Southeastern Inner Mongolia, China. Arab. J. Geosci. 2022, 15, 1368. [Google Scholar] [CrossRef]
- Reed, I.S.; Yu, X. Adaptive Multiple-Band CFAR Detection of an Optical Pattern with Unknown Spectral Distribution. IEEE Trans. Acoust. Speech Signal Process. 1990, 38, 1760–1770. [Google Scholar] [CrossRef]
- Wang, S.; Wang, X.; Zhang, L.; Zhong, Y. Auto-AD: Autonomous Hyperspectral Anomaly Detection Network Based on Fully Convolutional Autoencoder. IEEE Trans. Geosci. Remote Sens. 2022, 60, 5503314. [Google Scholar] [CrossRef]
Module | LQD_1 | LQD_2 | LQD_3 | LQD_4 | LQD_5 | LQD_6 |
---|---|---|---|---|---|---|
No_Attention | 0.8508 | 0.7851 | 0.6329 | 0.7520 | 0.7902 | 0.7645 |
No_Groups | 0.8495 | 0.7878 | 0.6310 | 0.7516 | 0.7902 | 0.7727 |
No_Orthogonal | 0.8498 | 0.8165 | 0.6184 | 0.7526 | 0.7896 | 0.7676 |
MSFA-Net | 0.8517 | 0.8214 | 0.6389 | 0.8116 | 0.7905 | 0.7735 |
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. |
© 2025 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Lu, Y.; Jiang, W.; Zhao, M.; Zhou, Y.; Yang, J.; Qiu, K.; Cheng, Q. Anomaly Detection in Mineral Micro-X-Ray Fluorescence Spectroscopy Based on a Multi-Scale Feature Aggregation Network. Minerals 2025, 15, 970. https://doi.org/10.3390/min15090970
Lu Y, Jiang W, Zhao M, Zhou Y, Yang J, Qiu K, Cheng Q. Anomaly Detection in Mineral Micro-X-Ray Fluorescence Spectroscopy Based on a Multi-Scale Feature Aggregation Network. Minerals. 2025; 15(9):970. https://doi.org/10.3390/min15090970
Chicago/Turabian StyleLu, Yangxin, Weiming Jiang, Molei Zhao, Yuanzhi Zhou, Jie Yang, Kunfeng Qiu, and Qiuming Cheng. 2025. "Anomaly Detection in Mineral Micro-X-Ray Fluorescence Spectroscopy Based on a Multi-Scale Feature Aggregation Network" Minerals 15, no. 9: 970. https://doi.org/10.3390/min15090970
APA StyleLu, Y., Jiang, W., Zhao, M., Zhou, Y., Yang, J., Qiu, K., & Cheng, Q. (2025). Anomaly Detection in Mineral Micro-X-Ray Fluorescence Spectroscopy Based on a Multi-Scale Feature Aggregation Network. Minerals, 15(9), 970. https://doi.org/10.3390/min15090970