谢忠红,徐焕良,黄秋桂,王 培
基于高光谱图像和深度学习的菠菜新鲜度检测
谢忠红,徐焕良※,黄秋桂,王 培
(南京农业大学信息科学技术学院,南京 210095)
针对传统机器视觉在实现菠菜新鲜度检测精度偏低的问题,该文提出了一种基于高光谱和深度学习技术的圆叶菠菜新鲜度识别新方法。以10 ℃常温贮存的圆叶菠菜为研究对象,以天为单位,综合考虑影响菠菜新鲜度的6个因素:贮藏天数、外观、含水率、叶绿素a、叶绿素b和胡萝卜素,将菠菜划分为新鲜、次新鲜和腐败3个等级。拍摄菠菜叶片的高光谱图像,计算ROI(region of interest)反射率均值后,基于分组精英策略遗传算法, 结合2种分组策略,筛选出含6个波长的组合。定义训练集和测试集合,使用SVM分类器,基于波长对应的反射率,分别进行基于光谱特性界定菠菜的新鲜度分类试验。找出了识别率均值最高的3个波长,分别是389.55、742.325和1 025.662 nm。由于基于光谱特性进行菠菜新鲜度检测时识别率偏低。尝试基于菠菜的高光谱图像特征进一步进行菠菜新鲜度识别研究。从高光谱图像集中抽取这3个波长对应的菠菜图像,构成菠菜图像样本库(NormImg389、NormImg742、NormImg1 025和NormImg_merge),基于深度学习技术建立菠菜新鲜度识别模型,对图像样本库中4类图像进行识别试验,平均识别准确率79.69%、68.75%、69.27%和80.99%。而NormImg389测试集识别正确率接近80%,NormImg_merge测试集识别正确率最高达到了80.99%,说明融合3个波长对应的图像进行等级识别效果最好。该研究实现了圆叶菠菜新鲜度的无损检测,具有实践和理论意义。
高光谱; 波长; 算法;分组精英遗传算法;深度学习;新鲜度
蔬菜富含大量的水分、叶绿素、维生素C以及可溶性糖等化学物质是居民膳食中不可或缺的部分。然而采摘后蔬菜体内会发生一系列生理变化:1)由于叶子的蒸腾作用,叶片会萎缩、发黄;2)叶片内的含氮物质在酶的催化作用下生成硝酸盐和亚硝酸盐等物质;3)叶绿素含量大幅下降;4)水分的减少加速了蛋白质降解并且延迟了蛋白质的合成,使得不新鲜的蔬菜可溶性蛋白含量降低。随着生活水平的提高,人们对蔬菜品质提出了越来越高的要求[1-2]。
国内外众多学者使用高光谱和机器视觉技术检测蔬菜样本品质并取得了极大的成就。Zhang等以20和4 ℃贮藏环境下的圆叶菠菜为研究对象,叶绿素和胡萝卜素含量为评价指标,使用随机蛙跳法优选出了874~1 734 nm范围的4个特征波段,分别建立基于全波段和特征波段的PLS预测模型,后者性能更优[3]。Siripatrawan等事先将不同浓度的大肠杆菌接种到圆叶菠菜中,把菌落计数作为菠菜细菌感染程度指标,基于400~1 000 nm范围的高光谱波段,分别建立PCA和人工神经网络模型,预测大肠杆菌数量和分布[4]。Diezma等[5]把菠菜分别置于10和20 ℃环境中,共划分3个新鲜度等级(A、B、C),建立基于高光谱的SAM和PLS-DA判别模型。王巧男等以菠菜为研究对象,在4和20 ℃贮藏条件下,找出了最佳的光谱信息新鲜度判别模型SR-ELM,识别率达到了100%,同时分别研究了叶绿素a等化学成分的预测模型[6-7]。徐海霞基于菠菜图像的颜色特征,分别建立了贮藏天数的近邻预测模型和测定叶绿素含量的BP神经网络模型,取得了较好的效果[8]。
然而针对圆叶波菜的新鲜度检测,国际上尚未出现公认的行业标准。已有的叶菜新鲜度等级评判主要以外观和贮存天数为评价指标,无法全面揭示菠菜新鲜度;传统的机器视觉技术关注的可见光波段的图像,由于信息片面。而基于高光谱技术的蔬菜新鲜度检测,才刚刚开始起步,已有的研究的思路主要是建立光谱反射率和新鲜度之间的关系,而每一次检测都需要使用高光谱设备来获取反射率,这样成本过高。因此本文尝试寻找新鲜度和特征频谱对应图像之间的关系。
本文以室温10 ℃常温贮存圆叶菠菜为研究对象,使用高光谱仪获取了每片菠菜叶片在373~1 034 nm波长范围内的反射率,使用分组精英选择策略遗传优选算法和支持向量分类算法,筛选出了可用于菠菜新鲜度分类的3个波长389.55、742.325和1 025.662 nm。基于深度学习技术建立菠菜新鲜度识别模型,在图像样本库NormImg389、NormImg742、NormImg1 025和NormImg_merge中进行识别试验,3次试验的平均识别准确率79.69%、68.75%、69.27%和80.99%。
随着菠菜贮存天数的增加,出现水分胁迫现象,细胞中的叶绿素、胡萝卜素不断被氧化,叶片失水皱缩,呈现衰老状态。本次研究测定了与新鲜度相关的叶绿素、胡萝卜素、含水率、pH值、硝酸盐和亚硝酸盐等化学成分。
1.1.1 菠菜叶绿素和胡萝卜素测定
在南京农业大学生科楼实验室使用酶标仪完成叶绿素、胡萝卜素含量的测定。连续5 d每隔24 h测量150~250片菠菜叶子,样本总量为1 024片。分析图1可知,1~5 d随着菠菜保存天数增长,叶绿素和胡萝卜素含量总体呈减少趋势。1~3 d叶绿素b流失速度高于叶绿素a,但是3~5 d后,叶绿素a流失速度高于叶绿素b。而随着贮藏的时间增加,叶片表型特征变化也很明显,前面1~2 d叶子呈绿色,而到了第5天,菠菜叶片表面出现大量的黄色区域。
图1 菠菜叶绿素a、b和胡萝卜素浓度的平均值
1.1.2 含水率测定
根据GB 5009.3-2010标准中的直接干燥法,测定菠菜叶片中的水分。相对含水率(RMC,relative moisture content)计算公式(1)计算RMC值,测量结果如图2所示。前4 d,菠菜RMC平均值均高于80%;第5 天,菠菜含水量急剧下降,出现腐败现象。
试验结果发现在室温10 ℃环境下连续放置5 d的菠菜硝酸盐、亚硝酸盐质之浓度的波动范围为[0.051 4 mg/L,0.074 1 mg/L],变化不明显,而pH值均为7几乎没变。因此最终考虑了水分、叶绿素a,叶绿素b和胡萝卜素对菠菜新鲜度的影响。
本次研究将综合考虑影响菠菜新鲜度的6个因素:贮藏天数、外观、含水率、叶绿素a、叶绿素b和胡萝卜素。并基于标准差给每个因素赋予权值,计算出叶片的综合得分,并根据得分将菠菜划分新鲜、次新鲜和腐败3个等级。
1.2.1 外观评分方法
菠菜叶片的外观评分主观性大,为此研究中请20位生命科学专业的学生组成感官小组进行评价,挑选了3种与新鲜度密切相关的外观性质:色泽、形态、质地。评价标准如表1所示。将菠菜新鲜度由好到差依次为新鲜、次新鲜、腐败,等级量化为 3、 2、 1分[5]外观权重见表2,专家评定结果见表3。
表1 菠菜外观评定标准
表2 二元对比排序法确定的各外观指标的权重
表3 室温10 ℃条件下贮存1 d的菠菜叶片的专家评定结果
当以色泽判定表3所示的菠菜新鲜度时,有20位专家给出3分(新鲜),即色泽得3分的票数为20,其余类似。则该菠菜的模糊关系矩阵和外观综合评定结果为
将外观综合评定结果与分值向量相乘,最后可得出该样本的外观总得分,即最终评价得分¢值为:
1.2.2 综合得分
6个因素:贮藏天数、外观、含水率、叶绿素a、叶绿素b和胡萝卜素构成了一个得分矩阵。并基于每个因素的标准差给该因素赋予权值w,计算出叶片的综合得分,并根据得分将菠菜划分新鲜、次新鲜和腐败3个等级[9-11]
综合考虑叶片存储和得分情况(图3),将得分设置为3个区间:[0,0.36]为腐败,[0.36,0.52]为次新鲜,[0.52,1]为新鲜。
图3 10 ℃时1 024片叶子的综合得分
为了获得噪音小且清晰的图像,将五铃光学生产的高光谱仪(HSI-VNIR-00001)的像距和物距固定为17 mm、0.475 m,而光强设为200能够更加清晰地获取菠菜叶片表面的细节。为了配合相机的采集图像的速度,载物台移动速度2.5 mm/s。接着采用白板和黑暗环境对高光谱仪(图4a)进行校正。圆叶菠菜高光谱图像采集过程如下:1)每隔24 h选取30~50棵圆叶菠菜样本,从每棵圆叶菠菜上摘取5片真叶;2)将来自同1棵圆叶菠菜的5片真叶平摊于载物台上,启动步进电机,在移动过程中扫描圆叶菠菜样本(避光),拍摄结束后,载物台自载物台移动速度2.5 mm/s,最大程度地配合相机的采集速度动返回至起点;3)根据公式(7)计算出每幅高光谱图像的反射率。每片菠菜叶片选出感兴趣ROI区域(图4b),将ROI区域反射率的均值作为该菠菜叶片的反射率[12-18]。
式中R表示反射率,、分别表示样本、白板和黑暗环境反射强度。
使用高光谱设备的波长范围是[373 nm, 1 033 nm],以0.5 nm为间隔一共是1 232个波长。因此必须优选出能够进行菠菜新鲜度划分的波长组合。传统的遗传算法(genetic algorithm)具有的收敛速度慢、易早熟等缺陷。因此将搜索空间进行分组,在局部区间内寻找最优值后,合并每组的寻优结果,这种方法能够加速收敛[19-20]。
2.2.1 自适应分组
为了寻找能够区分菠菜新鲜度的波长,本次研究分析菠菜光谱反射率分布情况后,发现反射率随着波长的变化呈现先聚拢后发散或者先发散再聚拢的特征。因此本文尝试寻找反射率分布较为聚拢的拐角作为分界点进行划分。具体做法是计算每个波长对应的最大反射率和最小反射率的差找出了差值最小对应的波长,依次为389.55、401.629、742.325、949.939、1 025.662 nm,这些点也就是在这些波长处的反射率的极小值。从理论上讲差值越小,说明反射率紧凑,类内距离小,区分度弱。研究中结合精英策略以这些波长点为分界点进行分组,然后在每组中独立进行遗传操作,每代适应度值最高的波长为精英保留到下一代中,见图5[23-24]。
图5 自适应分组GGABE算法流程图
2.2.2 人工分组
人工指定分组法就是根据经验将整个解空间平均分为组,每组互不干扰地独立进行编码、选择、交叉和遗传操作。为了寻找较优且稳定的波长,采用多次进行人工分组,找出效果最好的波长组合。分组数∈[2,20]。
首先使用自适应分组策略进行波长筛选,10次试验后统计筛选出来的波长如图6a所示。将出现次数最少的745.056 nm波长删除,得到一个包含5个波长的集合,={389.55,401.629, 742.325, 949.939, 1 025.662 nm}。
人工分组进行波长筛选,将1 232个波长均匀划分为组,∈[2,20],统计每次分组后使用精英策略筛选出来的波长,结果如图6b所示,将出现频率最高的4个波长被定义为集合,={389.55,536.365, 742.325,1 025.662}。
图6 分组策略筛选出的波长出现的频数
计算∪,使用较成熟的分类工具箱libsvm对∪集合中的每个波长分别进行基于光谱特性界定菠菜的新鲜度识别试验。训练集和测试集各含240个菠菜样本。进行了10次试验,求取识别准确率的均值,结果如表4所示。分析表4可以发现389.55, 742.325, 1 025.662 nm对应的识别率最高,因此决定选择这3个波长进行进一步研究。
表4 菠菜新鲜度分类准确率
前面已有的研究是基于菠菜的光谱特性界定菠菜的新鲜度。研究结果是389.55、742.325、1 025.662 nm 3个波长对应的反射率在进行菠菜新鲜度识别时准确率最高,可达到62.08%,60%和60.42%。很显然还没有达到实用的要求,因此继续尝试寻找基于菠菜图像特征的等级判别方法。
从高光谱图像集中抽取了3个波长对应的灰度图像,构建img389、img742、img1025和img_merge(3个波长对应图像融合)图像数据库(图7)。对图像数据库中每幅图像进行背景分割后,将每片叶片图像归一化为64×64大小的图像(图8),形成于识别样本库:NormImg389、NormImg742、NormImg1025和NormImg_merge。研究中以NormImg_merge作为样本库,随机选择80%的图像样本作为学习样本集,另外20%的图像样本作为测试样本集。
深度学习通过模拟人的神经网络结构实现特征学习,在处理信号时经过多层变换描述数据特征,从而得到数据的解释[15]。CNN一般包括:输入层、卷积层、池化层、全连接层、Dropout层和输出层。研究中搭建的卷积神经网络的基本结构:1个输入层,4个卷积层和池化层组合,1个全连接层,2个Dropout层和1个输出层(如图9)[25-27]。
图8 归一化后的菠菜叶片的灰度图像
网络的关键参数weight有多钟初始化方式,研究中经过比较选择了normal_initializer()函数,其参数stddev=0.1。将第3个卷积层的参数stddev=0.01,第4个卷积层的参数stddev=0.001。
图9 深度学习网络结构
Fig 9 Deep learning network structure
1)LearnRate
LearnRate越小学得越仔细,但速度慢;LearnRate越大学得越粗糙,但速度快,易造成欠拟合。本次研究首先在[0.000 1, 0.1]区间中先选择了0.000 1、0.000 5、0.001、0.005、0.01、0.1 共6个学习率基于训练集进行训练,基于测试集进行识别。3次试验的平均训练时间和平均识别准确率结果如图10a所示。分析图10a可发现LearnRate=0.000 5时,识别准确率最高训练时间最短。为了进一步搜寻到最佳学习率,将搜索空间缩小为[0.000 3, 0.000 8],3次试验的平均训练时间和识别准确率如图10b所示。分析图10b可以发现LearnRate=0.000 6时,训练时间最短,识别准确率最高[28-30]。
从NormImg389、NormImg742、NormImg1025和NormImg_merg这4个图像数据库中随机选择80%的样本构成训练集1,2,3,4,剩下的20%构成测试集1,2,3,4。进行充分训练后在测试集中进行识别,如图11展示了某次在训练集中的训练情况和在测试集中的识别情况。
对比4个图像库的训练情况,可发现准确率虽波动但总体程提高和收敛趋势。最终训练准确率均可达到100%;4个图像库的测试集最终所能达到的准确率并不相同,其中NormImg389和NormImg_merg的测试集最终达到的准确率较高,接近80%,其他2个图像库的测试集稍低。
本次研究基于每个图像数据库进行了3次训练和测试,测试集的识别准确率如图12a和图12b所示。
分析图12可以发现NormImg_merge最高,为80.99%,而NormImg389仅次于NormImg_merge,达到了79.69%。NormImg742和NormImg1 025的测试准确率较低。
图10 搜寻最佳学习率的试验结果
图11 4个图像数据库某次的训练和测试情况
Fig11 Training and testing in 4 image databases
图12 基于深度学习技术的菠菜等级识别试验结果
Fig 13 Result of spinach grade recognition test based on deep learning technology
1)由于菠菜高光谱数据量巨大,为避免在识别时出现维度灾难,在计算出菠菜叶片ROI区域反射率的均值后,本次研究提出了基于分组和精英策略的遗传算法筛选出能较好地区分菠菜新鲜度的波长6个波长,使用SVM分类器,基于6个波长对应的菠菜反射率,分别进行基于光谱特性界定菠菜的新鲜度分类试验。找出10次试验识别率均值最高的3个波长(389.55、742.325、 1 025.662 nm)。
2)从高光谱图集中抽取了3个波长对应的菠菜图像构成了图像样本库,基于深度学习技术建立菠菜新鲜度识别模型,3次试验的平均识别准确率分别为79.69%、68.75%、69.27%和80.99%。说明将389.55、742.325和1 025.665 nm对应的图像进行融合后进行菠菜新鲜度识别效果最好。
3)叶绿素a、b、胡萝卜素和水分等指标对菠菜新鲜度均有一定的影响,前3者的敏感波段分别为663、645、470 nm,水分的敏感波段为[973,1 662],本次研究最终筛选的波段为389.55、742.325、1 025.662 nm,虽然没有与敏感波段重合,但与敏感波段是相关的。其中1 025.662nm在水的敏感区间[973, 1 662]中;742.325 nm则距离叶绿素a,叶绿素b的敏感波段比较近;389.55 nm则距离胡萝卜素的敏感波长较近。
[1] Jung Y J, Padmanabahn A, Hong J H, et al. Consumer freshness perception of spinach samples exposed to different storage conditions[J]. Postharvest Biology and Technology, 2012, 73: 115-121.
[2] 赵习姮,李哲. 采后蔬菜衰老与抗氧化酶活性的关系[J]. 生物技术,2010,20(6):85-87. Zhao Xiheng, Li Zhe. Relationship between senescence and antioxidative enzymes activities of postharvest vegetables[J]. Biotechnology, 2010, 20(6): 85-87. (in Chinese with English Abstract)
[3] Zhang C, Wang Q, Fei F, et al. Rapid and non-destructive measurement of spinach pigments content during storage using hyperspectral imaging with chemometrics[J]. Measurement, 2017, 97: 149-155.
[4] Siripatrawan U, Makino Y, Kawagoe Y, et al. Rapid detection ofcontamination in packaged fresh spinach using hyperspectral imaging[J]. Talanta, 2011, 85(1): 276-281.
[5] Diezma B, Lleo L, Roger J M, et al. Examination of the quality of spinach leaves using hyperspectral imaging[J]. Postharvest Biology and Technology, 2013, 85: 8-17.
[6] 王巧男. 基于高光谱成像技术的蔬菜新鲜度快速检测方法研究[D]. 杭州: 浙江大学2015.Wang Qiaonan.Rapid Detection Vegetable Freshness based on Hyperspectral Imaging Technology[D]. Hangzhou: Zhejiang University, 2015. (in Chinese with English Abstract)
[7] 朱军伟. 菠菜低温保鲜关键技术的研究[D]. 上海:上海海洋大学,2013. Zhu Junwei. Research on Key Technologies of Low Temperature Preservation of Spinach[D]. Shanghai: Shanghai Ocean University, 2013. (in Chinese with English Abstract)
[8] 徐海霞. 基于机器视觉和电子鼻技术的菠菜新鲜度无损检测研究[D]. 镇江:江苏大学,2016. Xu Haixia.Study on Nondestructive Detection of Freshness of Post-harvest Spinach Based on Machine Vision and Electronic Nose[D]. Zhenjiang: Jiangsu University, 2016. (in Chinese with English Abstract)
[9] 王浩云,李亦白,张煜卓,等. 基于光子传输模拟的苹果品质高光谱检测源探位置研究[J]. 农业工程学报, 2019, 35(4): 281-289 Wang Haoyun, Li Yibai, Zhang Yuzhuo, et al. Research on hyperspectral light and probe source location on apple for quality detection based on photon transmission simulation[J]. Transactions of the Chinese Society of Agricultural Engineering (Transactions of the CSAE), 2019, 35(4): 281-289
[10] Ye X J, Lino K, Zhang S. Monitoring of bacterial contamination on chicken meat surface using a novel narrowband spectral index derived from hyperspectral imagery data[J]. Meat Science, 2016, 122: 25-31.
[11] Kim C, Govindarajan K N. Optical scattering in beef steak to predict tenderness using hyperspectral imaging in the VIS-NIR region[J]. Sensing and Instrumentation for Food Quality and Safety, 2008, 2(3): 189-196
[12] 谭亮. 基于内容的中草药图像检索关键技术研究[D]. 杭州:浙江大学,2016 Tan Liang. Key Technology Research of Content-based Chinese Herbal Medicine Image Search[J]. Hangzhou: Zhejiang University, 2016. (in Chinese with English Abstract)
[13] 吴迪,宁纪锋,刘旭, 等. 基于高光谱成像技术和连续投影算法检测葡萄果皮花色苷含量[J]. 食品科学,2014(8):57-61 Wu Di, Ning Jifeng, Liu Xu, et al. Determination of anthocyanin content in grape skin using hyperspectral imaging technique and successive projections algorithm[J]. Food Science, 2014(8): 57-61. (in Chinese with English Abstract)
[14] 祝志慧,刘婷,马美湖. 基于高光谱信息融合和相关向量机的种蛋无损检测[J]. 农业工程学报,2015,31(15):285-292 Zhu Zhihui, Liu Ting, Ma Meihu. Hatching eggs nondestructive detection based on hyperspectral-imaging information and RVM[J]. Transactions of the Chinese Society of Agricultural Engineering (Transactions of the CSAE), 2015, 31(15): 285-292. (in Chinese with English Abstract)
[15] 潘磊庆,张伟,于敏莉, 等. 基于高光谱图像的鸡种蛋孵化早期胚胎性别鉴定[J]. 农业工程学报,2016,32(1):181-186. Pan Leiqing, Zhang Wei, Yu Minli, et al. Gender determination of early chicken hatching eggs embryos by hyperspectral imaging[J]. Transactions of the Chinese Society of Agricultural Engineering (Transactions of the CSAE), 2016 , 32 (1): 181-186. (in Chinese with English Abstract)
[16] 尚任,黑保琴,李盛阳, 等. 长时序高光谱图像清晰度影响因素分析[J]. 中国图象图形学报,2016,21(5):665-673. Shang Ren, Hei Baoqin, Li Shengyang, et al. Analysis of factors influencing clarity of hyper spectral images in long time series[J]. Journal of Image and Graphics, 2016, 21(5): 665-673.
[17] 方帅,瞿成佳,杨学志, 等. 组合因子最优的线性预测波段选择[J]. 中国图象图形学报,2016,21(2):255-262. Fang Shuai, Qu Chengjia, Yan Xuezhi, et al. Linear prediction band selection based on optimal combination factors[J]. Journal of Image and Graphics, 2016, 21(2): 255-262. (in Chinese with English Abstract)
[18] 石慧. 基于高光谱成像技术的对虾品质信息快速检测方法研究[D]. 杭州:浙江大学,2013. Shi Hui. Research on Rapid and Non-invasive Determination for Quality of Fenneropenaeus Chinensis Based on Hyperspectral Imaging Technology[D]. Hangzhou: Zhejiang University, 2013. (in Chinese with English Abstract)
[19] 王峰,曼媛,段俊洁. 一种改进的求解前N条最短路径问题的多种标号算法[J]. 小型微型计算机系统. 2016,37(7):1482-1487. Wang Feng, Man Yuan, Duan Junjie. Improved multiple labels algorithm for solving the N-shortest paths problem[J]. Journal of Chinese Computer Systems. 2016, 37(7): 1482-1487. (in Chinese with English Abstract)
[20] 岳钦,冯珊. 粗粒度并行遗传算法的计算性能分析[J]. 武汉理工大学学报,2008,30(7):107-110 Yue Qin, Feng Shan. The Statistical Analyses for Computational Performance of the Genetic Algorithms[J]. Chinese Journal of Computers 2008, 30(7): 107-110. (in Chinese with English Abstract)
[21] Tsai C, Huang H, Chan C. Parallel elite genetic algorithm and its application to global path planning for autonomous robot navigation[J]. IEEE Transactions on Industrial Electronics, 2011, 58(10): 4813-4821
[22] 罗熊,樊晓平,易晟,等. 具有大量不规则障碍物的环境下机器人路径规划的一种新型遗传算法[J]. 机器人,2004,26(1):11-16 Luo Xiong, Fan Xiaoping, Yi Sheng, et al. A novel genetic algorithm for robot path planning in environment containing large numbers of irregular obstacles[J]. Robot, 2004, 26(1): 11-16. (in Chinese with English Abstract)
[23] 庄嘉祥. 精英策略遗传算法改进及在作物模型参数优化的应用[D]. 南京:南京农业大学, 2013 Zhuang Jiaxiang. Improved Genetic Algorithm Based on Elitist Strategy and its Application in Parameter Optimization of Crop Models[D]. Nanjing: Nanjing Agricultural University, 2013. (in Chinese with English Abstract)
[24] 谢忠红,王培,顾宝兴,等. 基于分组和精英策略的遗传算法在机器人导航上的应用[J]. 华南农业大学学报,2017,38(5):110-116 Xie Zhonghong, Wang Pei, Gu Baoxing, et al. Application of genetic algorithm based on group and elite strategy for robot navigation[J]. Jounal of South China Agricultural University, 2017,38(5): 110-116. (in Chinese with English Abstract)
[25] 尹宝才,王文通,王立春. 深度学习研究综述[J]. 北京工业大学学报,2015,41(1):48-49. Yin Baocai, Wang Wentong, Wang Lichun. Review of deep learning[J]. Jounal of Beijing university of technology, 2015,419(1): 48-49. (in Chinese with English Abstract)
[26] Zeiler M D, Fergus R. Visualizing and understanding convolutional networks[C]// European Conference on Computer Vision. Springer, Cham, 2014: 818-833.
[27] 姜新猛. 基于Tensorflow的卷积神经网络的应用研究[D].武汉:华中师范大学,2017. Jiang Xinmeng. Application and Research of Convolution Neural Network Based on Tensorflow[D]. Wuhan: Central China Normal University, 2017. (in Chinese with English Abstract)
[28] 蒋文斌,彭晶,叶阁焰. 深度学习紫石英学习率算法研究[J]. 华中科技大学学报,2019,47(5):79-83. Jiang Wenbin, Peng Jing, Ye Geyan. Research on adaptive learning rate algorithm in deep learning[J]. Journal of Huazhong University of Science and Technology, 2019, 47(5): 79-83. (in Chinese with English Abstract)
[29] 王献锋,张传雷,张善文,等. 基于自适应判别深度置信网络的棉花病虫害预测[J]. 农业工程学报,2018,34(14):157-163. Wang Xianfeng, Zhang Chuanlei, Zhang Shanwen, et al .Forecasting of cotton diseases and pests based on adaptive discriminant deep belief network[J]. Transactions of the Chinese Society of Agricultural Engineering (Transactions of the CSAE), 2018, 34(14): 157-164. (in Chinese with English Abstract)
[30] 孙钰,周焱,袁明帅,等. 基于深度学习的森林虫害无人机实时监测方法[J]. 农业工程学报,2018,34(21):74-79. Sun Yu, Zhou Yan, Yuan Mingshuai, et al. UAV real-time monitoring for forest pest based on deep learning[J]. Transactions of the Chinese Society of Agricultural Engineering (Transactions of the CSAE), 2018, 34(21): 74-81. (in Chinese with English Abstract)
Spinach freshness detection based on hyperspectral image and deep learning method
Xie Zhonghong, Xu Huanliang※, Huang Qiugui, Wang Pei
(,210095,)
Aiming at the problem that the traditional machine vision has low discrimination accuracy when realizing the fresh level recognition of spinach, A new method for fresh grade recognition of spinach based on hyperspectral and deep learning was conducted in this study. Round leaf spinach stored in room temperature 10oC on a daily basis was regarded as research objects. The spinach was divided into three grades of fresh, relatively fresh and corruption according to the score calculated by considering 6 factors: fresh spinach days of storage, appearance, water content, chlorophyll a, chlorophyll b, and carotenoids. After 6 ROI areas was obtained from the hyperspectral image of spinach leaves shot with high spectrum imaging instrument, the mean reflectance of ROI region was calculated. Based on the grouping elite strategy genetic algorithm, an adaptive grouping strategy was used to screen out a set of wavelengths A, A={389.55 nm, 401.629 nm, 742.325 nm, 949.939 nm, 1 025.662 nm}. Then the artificial grouping strategy was also used for wavelength screening. The number of statistical groups was the wavelength selected by n = 1, 2, 3...n, and the four frequencies with the highest frequency were placed in the set B, B={389.55 nm, 536.365 nm, 742.325 nm, 1 025.662 nm }. The six wavelengths in the A∪B set were combined as the final selected wavelengths, and these wavelengths were better able to identify the fresh grade of spinach. Define training set R and test set T, R and T each containing 240 spinach samples. Using the SVM classifier, based on the spine reflectance corresponding to the six wavelengths, a fresh grade classification test based on the spectral characteristics to define spinach was separately performed. After 10 trials, the mean value of recognition accuracy was obtained, and the three wavelengths with the highest recognition rate were found, which were 389.55, 742.325 and 1 025.662 nm, respectively. The corresponding recognition rates were 62.08%, 60.00% and 60.42%, respectively. This indicated that the recognition rate of spinach fresh grade was low based on spectral characteristics. In addition to the spectral properties, spinach's hyperspectral image also contains rich image information corresponding to all wavelengths, so further spine fresh grade recognition based on image features can be performed. The spinach images corresponding to the three wavelengths extracted from the hyperspectral image set constituted an image sample library. Based on the deep learning technology, the spine fresh grade recognition model was established. The recognition experiments were carried out on four types of images (NormImg389、NormImg742、NormImg1 025和NormImg_merge) in the image sample library. The average recognition accuracy of the three experiments was 79.69%, 68.75%, 69.27% and 80.99%. The NormImg389 and NormImg_merge test sets had higher recognition rates, which were close to 80%. The image recognition rate of spinach in NormImg_merge was up to 80.99%, which indicated that when the spinach fresh level recognition was performed, the images corresponding to the three wavelengths were merged. Identifying can get the best classification results. This study achieved the non-destructive testing of the fresh grade of round leaf spinach, and the research results provided quality assurance for industrial processing and marketing, which has practical and theoretical significance.
hyperspectral; wavelength; algorithm; grouped elite genetic screening; deep learning; freshness
10.11975/j.issn.1002-6819.2019.13.033
TP242
A
1002-6819(2019)-13-0277-08
2019-03-01
2019-05-28
中央高校基本业务费(KYZ201670); 国家自然科学基金(31601545)
谢忠红,博士,副教授,研究方向为农业机器视觉,农业信息技术。Email:xiezh@njau.edu.cn
徐焕良,教授,博士生导师,研究方向为联网技术及应用、数据库与知识工程、软件工程、计算机辅助农业系统。Email:huanliangxu@njau.edu.cn
谢忠红,徐焕良,黄秋桂,王 培.基于高光谱图像和深度学习的菠菜新鲜度检测[J]. 农业工程学报,2019,35(13):277-284. doi:10.11975/j.issn.1002-6819.2019.13.033 http://www.tcsae.org
Xie Zhonghong, Xu Huanliang, Huang Qiugui, Wang Pei.Spinach freshness detection based on hyperspectral image and deep learning method[J]. Transactions of the Chinese Society of Agricultural Engineering (Transactions of the CSAE), 2019, 35(13): 277-284. (in Chinese with English abstract) doi:10.11975/j.issn.1002-6819.2019.13.033 http://www.tcsae.org