# Spectral Data-Driven Prediction of Soil Properties Using LSTM-CNN-Attention Model
## 4 Discussion  
A broader comparison with other models explored in recent studies on soil property prediction highlights further advantages of the proposed LSTM-CNN-Attention model. While traditional machine learning methods such as PLSR, SVR, and RF are effective in certain contexts, they struggle to capture the nonlinear and complex relationships present in soil spectral data. Recent deep learning models, including CNN-GRU and CNN-LSTM, have improved predictive performance by leveraging temporal dependencies and spatial features; however, the absence of attention mechanisms limits their ability to emphasize critical features. [PERSON] et al. [31] demonstrated that integrating attention mechanisms enhances feature discrimination by focusing on relevant bands in hyperspectral data. Similarly, [PERSON] et al. [48] employed a spatial attention mechanism to extract contextual information from multi-channel data for soil property prediction. In line with these findings, the attention mechanism in the proposed model optimizes feature extraction while minimizing the impact of redundant data. Moreover, by integrating LSTM, CNN, and attention modules, the model capitalizes on the unique strengths of each component. In comparison with PCA-LSTM, the proposed model avoids the information loss associated with dimensionality reduction and fully utilizes CNN to extract meaningful spatial patterns. The high R\({}^{2}\) and RPD values observed in the ablation studies further demonstrate that this integrated architecture significantly enhances prediction accuracy across multiple soil properties.  
To further assess the predictive performance of the proposed LSTM-CNN-Attention model for soil property prediction, we compared it with the S-AlexNet model from [PERSON] et al. [25]. As presented in Table 7, the proposed model outperforms S-AlexNet across all soil properties, achieving an R\({}^{2}\) of 0.949 for OC, surpassing the 0.94 reported by S-AlexNet. Similarly, the RPD for CaCO\({}_{3}\) reaches 5.377, compared with 3.89, demonstrating enhanced reliability. The superior performance of the proposed model arises from the integration of the attention mechanism, which highlights key features, and the LSTM component, which captures temporal dependencies in soil spectral data. This combined framework enables the model to effectively learn evolving patterns, delivering more precise and consistent predictions than S-AlexNet, which lacks these components.  
The LSTM-CNN-Attention model has demonstrated high efficacy in predicting soil properties; however, its intricate architecture significantly prolongs training times due to the intensive computational requirements of its LSTM, CNN, and Attention components. This trade-off between model performance and efficiency is a well-documented challenge when working with large datasets. To mitigate this issue, future research will explore more  
Figure 11: Line charts of (**a**) R\({}^{2}\) and (**b**) RPD for the proposed and other models.  
efficient alternatives, such as substituting LSTM with GRU, streamlining the Attention mechanism, or implementing parallel processing techniques to enhance training speed.