X-LIBS: Interpretable Soil Classification Using Explainable AI to Support Sustainable Crop Management
Author : Yingchao Huang
Abstract : Sustainable crop protection depends on a good understanding of soil conditions, as soil properties influence crop health, nutrient availability, and the resilience of farming systems. Rapid and reliable soil classification can therefore support better field management and more informed agricultural decision-making. Laser Induced Breakdown Spectroscopy (LIBS) has shown strong potential for fast soil analysis, but many machine learning methods used with LIBS are difficult to interpret, which limits their practical use in agriculture. This study presents an explainable artificial intelligence framework for soil classification using LIBS spectra and Partial Least Squares (PLS) modelling. To improve transparency, Local Interpretable Model-agnostic Explanations (LIME) was used to identify the spectral features and soil-related elemental signals that most strongly influenced classification decisions. To improve performance on unlabeled spectra, a co-training strategy was applied in which only low-uncertainty predictions were incorporated during label refinement. Prediction uncertainty was estimated by progressively removing the most important LIME-identified features and recording when the predicted class changed. To reduce bias caused by class imbalance, equal proportions of refined predictions from each class were included during co-training. The method was evaluated on the publicly available EMSLIBS dataset and achieved a test accuracy of 93%, comparable to the best-performing methods reported in the literature. Beyond prediction performance, the explainability results helped reveal the factors behind misclassifications and highlighted the dominant elemental features affecting soil classification. The proposed approach demonstrates how explainable LIBS-based machine learning can provide both accurate and interpretable soil information, with potential value for sustainable crop management and precision agriculture
Keywords : Sustainable Agriculture, Soil Classification, Laser-Induced Breakdown Spectroscopy (LIBS), Explainable Artificial Intelligence (XAI), Partial Least Squares (PLS), Local Interpretable Model-agnostic Explanations (LIME), Machine Learning, Precision Agriculture, Soil Analysis, Crop Management
Conference Name : International Conference on Integrated Pest Management and Sustainable Crop Protection (ICIPMSCP-26)
Conference Place : Virtual, Calgary, Canada
Conference Date : 26th Jun 2026