基于稀疏自注意力和可见-近红外光谱的土壤氮含量预测
CSTR:
作者:
作者单位:

作者简介:

通讯作者:

中图分类号:

基金项目:

山东省自然科学基金项目(ZR2021MD100)和国家重点研发计划项目(2022YFD2002202)


Prediction of Soil Nitrogen Content Based on Sparse Self-attention and Visible-Near-infrared Spectroscopy
Author:
Affiliation:

Fund Project:

  • 摘要
  • |
  • 图/表
  • |
  • 访问统计
  • |
  • 参考文献
  • |
  • 相似文献
  • |
  • 引证文献
  • |
  • 资源附件
  • |
  • 文章评论
    摘要:

    氮是影响作物生长的关键因素,精准获取土壤氮含量是实施各类农田水肥管理技术的基础。利用可见-近红外光谱技术可以快速检测土壤氮含量,预测模型精度和泛化能力是制约将光谱技术应用于土壤氮含量检测的瓶颈。为此,提出了一种基于稀疏自注意力和可见-近红外光谱的土壤氮含量预测模型(Visible-near-infrared reflection spectrum and sparse transformer,VNIRSformer)用于提升预测精度和泛化能力。模型由输入层、嵌入层、编码器、解码器、预测层和输出层组成。采用大型公开数据集(Land use/cover area frame statistical survey,LUCAS)训练模型以提升模型泛化能力。实验测试VNIRSformer模型在15种不同光谱波长间隔下的性能,发现:随着波长间隔增加,预测精度先升后降,模型规模不断变小。波长间隔为1 nm时模型预测精度最低,RMSE为0.47 g/kg,R2为0.78。波长间隔为5 nm时模型预测精度最高,RMSE为0.35 g/kg,R2为0.89。当波长间隔从0.5 nm增加至1 nm时,模型规模下降最快,下降比例约为72%。当增加至5 nm后,模型规模匀速下降,下降比例约为5%。综合考虑模型规模及性能,最佳波长间隔设为5 nm。与6种不同预测模型(2种卷积神经网络、传统自注意力模型、偏最小二乘回归、支持向量机回归和K近邻回归)进行对比实验,发现:VNIRSformer模型性能最佳,RMSE为0.35 g/kg,R2为0.89,RPD为2.95。测试VNIRSformer对不同等级的土壤氮含量预测能力,发现:VNIRSformer模型能够较好预测小于5 g/kg的土壤氮含量。将VNIRSformer模型直接应用于自采数据集,发现:R2下降约0.17,表明模型具有一定泛化能力。研究表明,选取波长间隔为5 nm的光谱数据作为VNIRSformer模型输入,预测性能最佳,规模适中;稀疏注意力机制有助于提升模型预测精度,降低模型训练时间;预测模型具有一定泛化能力。研究结果可为基于可见-近红外光谱的土壤氮含量预测技术田间实际应用提供理论支持。

    Abstract:

    Nitrogen is a key factor that affects crop growth. The basis for the implementation of various agricultural water and fertilizer management technologies is the accurate determination of soil nitrogen content. Soil nitrogen content could be detected quickly by the visible-near-infrared spectroscopy technology. The bottleneck that limits the application of spectral technology in soil nitrogen test is the accuracy and generalizability of predictive models. In order to improve the prediction accuracy and generalization ability, a soil nitrogen content prediction model was proposed based on sparse self-attention and visible-near-infrared spectroscopy, which was called VNIRSformer. The model consisted of input layer, embedding layer, encoder, decoder, prediction layer and output layer. The land use/cover area frame statistical survey dataset (LUCAS) was used to train model to improve its generalization ability. The performance of VNIRSformer was tested at 15 different spectral wavelength intervals, and the result showed that as the wavelength interval was increased, the model prediction accuracy was firstly increased and then decreased, and the model size was reduced. The model prediction accuracy was the lowest at the wavelength interval of 1 nm, where the RMSE was 0.47 g/kg and the R2 was 0.78. The highest predictive accuracy of the model was for the 5 nm wavelength interval, of which the RMSE was 0.35 g/kg and the R2 was 0.89. The greatest reduction in model size was observed when the wavelength interval was increased from 0.5 nm to 1 nm, which was decreased by 72%. The model size was decreased uniformly at a rate of 5% as the wavelength interval was increased from 1 nm to 5 nm. Considering the model size and performance, the optimal wavelength interval was set to be 5 nm. When compared with six different prediction models (two convolutional neural networks, traditional self-attention model,partial least squares regression, support vector machine regression, and K-nearest neighbor regression), the VNIRSformer model had the best performance, with RMSE of 0.35 g/kg, R2 of 0.89 and RPD was 2.95. To test the adaptability of VNIRSformer to predict the soil nitrogen content at different grades, it was found that VNIRSformer had high prediction accuracy for soil nitrogen content below 5 g/kg. VNIRSformer was directly applied to self-collected datasets to verify the model’s generalization ability. R2 was decreased by 0.17, indicating that VNIRSformer had a certain generalization ability. The research results indicated that spectral data with a wavelength interval of 5 nm was selected as input of VNIRSformer, which had the best prediction performance and moderate scale. Sparse attention mechanism was able to improve model prediction accuracy and reduce model training time. The VNIRSformer model had a certain generalization ability. The results could provide support for the practical application of field soil nitrogen content prediction based on visible-near-infrared spectroscopy technology.

    参考文献
    相似文献
    引证文献
引用本文

冀荣华,李常昊,郑立华,宋丽芬.基于稀疏自注意力和可见-近红外光谱的土壤氮含量预测[J].农业机械学报,2024,55(10):392-398,409. JI Ronghua, LI Changhao, ZHENG Lihua, SONG Lifen. Prediction of Soil Nitrogen Content Based on Sparse Self-attention and Visible-Near-infrared Spectroscopy[J]. Transactions of the Chinese Society for Agricultural Machinery,2024,55(10):392-398,409.

复制
分享
文章指标
  • 点击次数:
  • 下载次数:
  • HTML阅读次数:
  • 引用次数:
历史
  • 收稿日期:2023-12-17
  • 最后修改日期:
  • 录用日期:
  • 在线发布日期: 2024-10-10
  • 出版日期:
文章二维码