Font Size: a A A

Research On The Application Of Image Segmentation And Object Detection In Agricultural Scenes

Posted on:2022-12-30Degree:MasterType:Thesis
Country:ChinaCandidate:S S JinFull Text:PDF
GTID:2513306764499684Subject:Computer Software and Application of Computer
Abstract/Summary:PDF Full Text Request
Seeds are the chips of agricultural technology.Bud length is an important criterion for judging seed vigor.However,manual measurements are traditional detection methods of bud length and vegetable growth,which has the problems with time-consuming and the measuring results are easily affected by experimenters' subjective factors.Agricultural product growth monitoring is an important part of smart agriculture.The squaring stage is before anthesis,while the commodity of green vegetables will be lower if they are at anthesis.Thus,if the squaring state of green vegetables can be detected in time,it is conducive to timely picking and adjustment of water and fertilizer strategy.With the development of computer vision technology,image segmentation,and object detection have high application value in agricultural scenes.In this study,the image segmentation technology is used to improve the efficiency of seed bud length and root length detection,and the target detection method is used for vegetable squaring stage detection.The main research works of this study are as follows:(1)In this study,a method of automatically detecting the bud and root length was proposed.Firstly,we used color features of bud and root,as well as shape features of seed to divide the image into bud part and root part.Secondly,the morphology method was used to deal with the edge contour of the bud and root.Then,through the skeleton thinning method,the image skeleton was extracted,and we proposed an endpoint deleted pruning method for only keeping the bud and main root's skeleton.Finally,the bud length and root length were calculated by Euclidean distance between pixels.Bud length and root length of corn,wheat,and rice were measured in the study.The results showed that the average percentage error of the bud length of corn,wheat,and rice was 2.90%,2.05%,and2.40% respectively,while that of root length were 1.90%,2.11%,and 2.02% respectively.(2)To realize the detection of green vegetables' squaring stage detection,we collected 27 video clips that last 30 seconds to 2 minutes long.Then we extracted video frames every 25 s.The extracted image frames were divided into overlapping blocks according to the resolution of 256×256 with an overlap rate of 0.2 and 640×640 with an overlap rate of 0.3,respectively.After that,label Img annotation tool was used to label the bolting part in block images.We make 2300 image blocks containing the bolting part.Then,the images were rotated at 3° and 5° respectively by the method of offline data enhancement methods.In addition,some images were fused with other images to generate more data.Finally,the data set was expanded to 8710 image blocks.(3)Aiming at the problem that the YOLOv5 s object detection algorithm is not effective in detecting small objects,this study introduces the image slice inference library SAHI(Slicing Aided Hyper Inference)to realize the large image slice inference and then combined the inference results to solve the problem of detecting the small object in large images to a certain extent.In this study,the Mosaic online data enhancement method was utilized to further expand the data and the NAM(Normalization-based Attention Module)attention mechanism was added to the YOLOv5 s backbone.Moreover,the neck network of YOLOv5 s was modified according to the Bi FPN(Bidirectional Feature Pyramid Network)idea to improve the feature fusion ability of YOLOv5 s.After the test,the precision,recall,and m AP(0.5)of the improved model were 0.949,0.946,and 0.955 respectively,where the recall and m AP(0.5)were increased by 1.2% and 0.6% compared with the original YOLOv5 s.According to the methods proposed in this study,the bud length and root length detection system and squaring state detection system of the vegetable can be designed and built respectively,which is beneficial to promote the automation of the agricultural industry and reduce labor cost and time cost.In addition,this study also provides a reference case for other agricultural image research.
Keywords/Search Tags:Bud length detection, Root length detection, Squaring stage, Image segmentation, Object detection, Image slice inference
PDF Full Text Request
Related items