节点文献

基于机器视觉的稻飞虱现场识别技术研究

Research on Field Identification Technology of Rice Planthopper Based on Machine Vision

【作者】 邹修国

【导师】 丁为民;

【作者基本信息】 南京农业大学 , 农业生物环境与能源工程, 2013, 博士

【摘要】 针对稻田合理喷药需要知道害虫密度的问题,研究了稻飞虱现场实时识别技术,包括稻田现场拍摄稻飞虱图像的方法,对拍摄的图像用不变矩提取形状特征值,用灰度共生矩阵提取纹理特征值,以及用仿生算法改进BP神经网络对稻飞虱进行识别并计数。具体研究是采用自行设计的拍摄装置采集稻飞虱图像,灰度化后用大津法二值化,再用数学形态学滤波;对二值图像采用Hu矩、改进Hu矩、Zernike矩和Krawtchouk矩四种不变矩分别提取特征值,再用BP神经网络进行训练和测试,以此检测四种矩的提取效果,具体操作是用Matlab2008运行算法,对白背飞虱、灰飞虱和褐飞虱共300个样本进行了训练和测试,结果表明Krawtchouk矩提取稻飞虱图像形状的6个特征值的识别率最高,其中对褐飞虱的识别率达到了100%,但是对白背飞虱和灰飞虱的误识别率较大。针对这一情况,进一步采用改进灰度共生矩阵提取背部纹理的4个特征值来识别三种稻飞虱,训练结果是白背飞虱和灰飞虱的识别率要高于Krawtchouk矩提取的特征值,而褐飞虱的识别率低于Krawtchouk矩提取的特征值,于是将这两种提取特征值的方法结合起来,这样最终确定了10个特征值。在此基础之上,采用遗传算法和参数选择改进粒子群算法优化神经网络分别训练和识别三种稻飞虱,通过对比和分析,遗传算法和粒子群算法各有优缺点,于是采用遗传算法改进粒子群算法优化BP神经网络,实验结果得到白背飞虱的正确识别率为90%,灰飞虱为95%,褐飞虱为100%,通过分析适应度曲线和训练误差曲线表明这一算法搜索效率高,求解速度快,训练时间比遗传算法的提高了52.7%,比粒子群算法的提高了24.1%,更加满足本文提出的实时性要求。按前面选择的算法编完软件后,现场实验的结果表明可以识别稻飞虱并计数,为适时适量的稻田喷药提供了依据。论文的主要研究内容及成果如下:(1)研究稻飞虱现场实时识别技术。使用移动小车,分别拍摄白背飞虱100个样本,灰飞虱100个样本,褐飞虱100个样本,拍摄其背部图像,无线传回远程PC机,由设计的软件实时识别。(2)设计现场稻飞虱活体图像采集装置。采集装置核心采用三星嵌入式处理器S3C2440,配备台湾显泰的USB接口工业相机,相机镜头变倍比15:1,采集图像大小定为640×480像素,通过嵌入式系统由USB无线网卡传回远程计算机。(3)预处理稻飞虱图像。对稻飞虱图像进行灰度化、二值化、数学形态学滤波、高斯滤波、平滑滤波等处理,得到质量比较好的去掉背景的二值图像;再通过二值图像的坐标计算得到去掉背景的灰度图像;最后采用改进的分水岭算法分割稻飞虱,将一幅图像中的多头稻飞虱分离到160×160像素的各子图像中,以便进一步处理。采用的算法计算简单,稳定有效,耗时最少,满足实时性的要求。(4)用四种不变矩提取稻飞虱形状特征值。用Hu矩、改进Hu矩、Zernike矩和Krawtchouk矩四种不变矩分别提取特征值,再用BP神经网络训练和测试,经过Matlab2008实验对比,Krawtchouk矩提取的6个特征值不仅反映出全局特征,而且展现了更好的局部性,对于稻飞虱的识别分类明显好于其它不变矩,其中对褐飞虱的识别率达到100%,但是对白背飞虱和灰飞虱误识别率较高。(5)采用改进灰度共生矩阵提取稻飞虱背部纹理特征值。找到稻飞虱的重心,以重心为中心,选取多重环形路线构建灰度共生矩阵,解决稻飞虱图像的方向性问题,再计算灰度共生矩阵的能量、熵、惯性矩和相关等4个特征,用神经网络训练和测试,白背飞虱的识别率达到80%,灰飞虱的识别率达到90%,这两种稻飞虱的识别率要高于Krawtchouk矩提取的特征值,而褐飞虱的识别率为95%,低于Krawtchouk矩提取的特征值,于是将这两种提取特征值的方法结合起来,最终确定了10个特征值。(6)优化神经网络识别稻飞虱。将上面确定的10个特征值结合起来作为BP神经网络的输入,再将遗传算法和粒子群算法相结合,把粒子群算法中的极值跟踪法改为遗传算法的交叉和变异操作,采用粒子分别与个体极值和群体极值进行交叉运算,粒子自己变异运算搜索最优解,以此保持个体之间信息交流和种群的多样性,提高搜索效率,加快求解速度,训练时间是0.4071秒,比遗传算法的0.86085秒提高了52.7%,比粒子群算法的0.53599秒提高了24.1%,更加满足本文提出的实时性要求。(7)设计稻飞虱识别软件。软件的流程是打开由无线采集小车实时传回的稻飞虱图像,经过一系列处理,提取不变矩特征值,最后通过GAIPSO神经网络识别稻飞虱并计数。(8)现场实验。在南京农业大学卫岗水稻试验站对系统进行现场测试,将采集幕布放置在田块之间的观测路上,小车放置在幕布前,远程控制其自由运行。将小车调整到最佳拍摄位置,通过工业相机拍摄稻飞虱图像,再通过无线网卡传回远程计算机进一步处理。现场实验表明系统可以正常工作,并能够实现实时识别并计数。

【Abstract】 Aimed at the problems of excessive spraying pesticide in paddy, we studied on the field identification technology of rice planthopper with machine vision. In order to obtain images of rice planthopper, we designed an equipment which was controlled by a remote computer. After image acquisition, the first operation was image preprocessing. The shape features of rice planthoppers were extracted by Hu moment, Improved Hu moment, Zernike moment and Krawtchouk moment. Then, BP Neural Network was used to train and test in order to know which the best one of the four moments was. The experiment was used Matlab2008to verify algorithm. It trained and tested on300samples of sogatella furcifera, laodelphax and nilaparvata lugens. The result showed that the correct rate of the recognition was the highest one which features were extracted by Krawtchouk moment, but the error recognition ratio of sogatella furcifera and laodelphax was high. Aimed at this problem, gray level co-occurrence matrix was used to extract the value of the back texture feature to discriminate of the three rice planthoppers. On this basis, the paper further used genetic algorithm to optimize BP neural network and particle swarm optimize BP neural network. By contrast, genetic algorithm and particle swarm optimization algorithm have their own advantages and disadvantages. Experimental results showed that the recognition result using genetic algorithm to optimize particle swarm algorithm has a faster solution. It can satisfy real time.The main contents and results of the research:(1) The determination of research projectThis paper studied real-time identification for rice planthopper in the field. Image acquisition used a mobile vehicle. It shot300samples of Sogatella furcifera, Nilaparvata lugens and Laodelphax. It shot the back shape of rice planthoppers. They were sent back to the remote PC by wireless way and identified by software.(2) Mobile equipment design In order to obtain images of rice planthopper, I designed an equipment which was controlled by a remote computer. The image size was set to640*480pixels because of the wireless transmission. The vehicle had simple structure and low cost. The camera was less than600yuan. These laid the foundation for low cost recognition system of rice planthopper.(3) Image preprocessingThe first operation was image preprocessing. Qality of image was not good in this condition of real-time system. It can not identify rice planthoppers by color. The best way was the shape. The commonly formula was used to get gray image, and OTSU algorithm was used to get binary image. In order to get better qualities of binary image, morphologic processing, Gauss filtering and median filtering were used.(4) Image feature extraction base on shapeThe shape features of rice planthoppers were extracted by Hu moment, Improved Hu moment, Zernike moment and Krawtchouk moment. After analysis and comparison, Krawtchouk moment not only reflected the global feature, but also exhibited better local feature. It was the highest correct recognition rate, but the error recognition ratio of sogatella furcifera and laodelphax was high.(5) Image feature extraction base on textureThe center of gravity was found and used as the center to construct gray level co-occurrence matrix. It used multiple annular routes. The texture features of Energy, entropy, moment of inertia and the related of gray level co-occurrence matrix was extract. Then used neural network to train and recognize. The identification rate of sogatella reached80%, and the rate of laodelphax reached90%, and the rate of nilaparvata lugens reached95%. It created the condition combining the features extractted by moment invariant.(6) Image classification and recognitionGenetic algorithm and particle swarm algorithm were used to optimize BP neural network. By contrast, genetic algorithm and particle swarm optimization algorithm have their own advantages and disadvantages. After analysis and comparison, GAIPSO Algorithm optimized BP Neural Network was better than genetic algorithm and IPSO Algorithm optimized BP Neural Network algorithm. It can realize satisfy real time.(7) Design the recognition system of rice planthopperThe software was designed through the above algorithms. The final goal was to achieve recognition and counting of rice planthoppers.(8) Field experimentThe system was tested in rice experiment stand of Nanjing Agricultural University. The curtain was placed on the observation road between the two fields, and the car was placed in front of the curtain. The car run to the best shooting position by remote control, and then used industrial camera to take pictures. The wireless network card transferred the images to the remote computer to further process. Field experiments showed that the system can work normally, and it can realize real-time recognition.

  • 【分类号】S435.112.3
  • 【被引频次】3
  • 【下载频次】219
  • 攻读期成果
节点文献中: 

本文链接的文献网络图示:

本文的引文网络