基于微型光谱仪和Transformer模型的便携式土壤全氮含量检测仪研究
CSTR:
作者:
作者单位:

作者简介:

通讯作者:

中图分类号:

基金项目:

国家重点研发计划项目(2023YFD1701000)和中国农业大学2115人才工程项目


Portable Soil Total Nitrogen Content Detector Based on Miniature Spectrometer and Transformer Model
Author:
Affiliation:

Fund Project:

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

    便携式土壤全氮含量近红外光谱检测仪具有快速、非破坏性和高效性等优点,但已开发的仪器多采用滤光片式设计,光谱通道数量有限会导致部分关键信息丢失,且无法采用基于深度学习的预测模型。随着微型光谱仪的商业化,本文开发了基于连续光谱的高精度土壤全氮含量检测仪。检测仪主要由NIR-R210型微型光谱仪、树莓派、触控屏、移动电源构成,利用微型光谱仪获取土壤光谱反射率,利用树莓派中嵌入的深度学习模型进行土壤全氮含量预测,然后在显示屏中输出预测结果。在中国农业大学上庄实验站采集了600份土壤样本,分别对偏最小二乘法、门控循环单元和Transformer 3种模型的预测性能进行了对比分析。结果表明,基于全光谱数据的Transformer深度学习模型表现最好,模型决定系数R2为0.89,均方根误差(RMSE)为0.19g/kg,预测偏差(RPD)为2.96。进一步对检测仪进行田间实时原位测试,田间环境下预测结果R2可达0.83,精度较高,可为智慧农业中土壤养分实时检测与精准管理提供新的解决方案。

    Abstract:

    Portable near-infrared (NIR) spectroscopic detectors for soil total nitrogen content offer the advantages of rapid analysis, non-destructive measurement, and high efficiency. However, most existing instruments adopt filterbased designs with a limited number of spectral channels, which can lead to the loss of critical information and prevent the implementation of deep learning-based prediction models. With the commercialization of miniature spectrometers, a high-precision soil total nitrogen content detector was developed based on continuous spectral data. The detector primarily consisted of an NIR-R210 miniature spectrometer, a Raspberry Pi, a touchscreen display, and a portable power supply. The spectrometer was used to acquire soil spectral reflectance data, which were processed by a deep learning model embedded in the Raspberry Pi to predict soil total nitrogen content. The prediction results were then displayed in real time on the touchscreen. A total of 600 soil samples were collected from the Shangzhuang Experimental Station of China Agricultural University. The predictive performances of three models (partial least squares regression (PLSR), gated recurrent unit (GRU), and Transformer) were compared. Among them, the Transformer model based on full-spectrum data achieved the best performance, with a coefficient of determination (R2) of 0.89, a root mean square error (RMSE) of 0.19g/kg, and a residual predictive deviation (RPD) of 2.96. Further real-time in-situ field tests showed that the Transformer model maintained high accuracy under field conditions, with an R2 of up to 0.83. This portable device provided an effective solution for real-time soil nutrient detection and precision management in smart agriculture.

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

剧伟良,杨玮,宋亚美,刘楠,李民赞.基于微型光谱仪和Transformer模型的便携式土壤全氮含量检测仪研究[J].农业机械学报,2025,56(6):268-276. JU Weiliang, YANG Wei, SONG Yamei, LIU Nan, LI Minzan. Portable Soil Total Nitrogen Content Detector Based on Miniature Spectrometer and Transformer Model[J]. Transactions of the Chinese Society for Agricultural Machinery,2025,56(6):268-276.

复制
相关视频

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