{"title":"通过 YOLOv8n-CK 网络实现不同遮挡度下白菜(Brassica oleracea L.)头部的关键点检测和直径估算","authors":"","doi":"10.1016/j.compag.2024.109428","DOIUrl":null,"url":null,"abstract":"<div><p>Accurate and rapid estimation of cabbage head diameters is critical for precise decision-making in cabbage-harvesting equipment, thereby ensuring the quality of cabbage head harvesting. However, mature cabbage heads are enveloped by layers of outer leaves, resulting in varying degrees of occlusion, which poses significant challenges for direct detection and diameter measurement of cabbage heads. To address this problem, this study proposes a method based on the keypoint of cabbage head for estimating cabbage head diameters with different degrees of occlusion in the field. An improved deep learning model, YOLOv8n-Cabbage Keypoints (YOLOv8n-CK), is introduced to accurately and rapidly detect the keypoints of cabbage heads. Specifically, to enhance the attention of the network to occluded cabbage head features in complex images, the convolutional block attention module (CBAM) is introduced in the backbone, thereby improving the accuracy of the model in detecting the keypoints of occluded cabbage heads. Moreover, to balance the accuracy and speed of the keypoint detection network, all the Conv modules of the C2f-Bottleneck structure are replaced by Ghost modules, which effectively reduces the number of parameters in the model while maintaining its accuracy and reducing the computational complexity. Based on the results of keypoints detection, the physical diameter of cabbage heads is computed by integrating the depth information of the effective keypoints using a histogram filtering algorithm. The experimental results show that for varying degrees of occlusion, YOLOv8n-CK achieves an average precision (AP<sub>50–95</sub>) of 99.2 % in detecting cabbage head keypoints, with 12.68 % and 13.04 % reductions in the params and floating point operations per second, respectively, compared to the original model. The mean absolute percentage error of the cabbage head diameter estimation model is 4.28 ± 0.13 %, and it exhibits favorable performance even under heavy occlusion (occlusion rate >65 %). Validation on an edge computing device shows that the model achieves 142.6 frames per second, which satisfies the real-time diameter estimation requirements for cabbage heads. These findings confirm the effective in-situ measurement of cabbage head diameters in the field, offering innovative insights for the development of efficient and low-damage harvesting equipment for cabbage.</p></div>","PeriodicalId":50627,"journal":{"name":"Computers and Electronics in Agriculture","volume":null,"pages":null},"PeriodicalIF":7.7000,"publicationDate":"2024-09-12","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":"{\"title\":\"Keypoint detection and diameter estimation of cabbage (Brassica oleracea L.) heads under varying occlusion degrees via YOLOv8n-CK network\",\"authors\":\"\",\"doi\":\"10.1016/j.compag.2024.109428\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"<div><p>Accurate and rapid estimation of cabbage head diameters is critical for precise decision-making in cabbage-harvesting equipment, thereby ensuring the quality of cabbage head harvesting. However, mature cabbage heads are enveloped by layers of outer leaves, resulting in varying degrees of occlusion, which poses significant challenges for direct detection and diameter measurement of cabbage heads. To address this problem, this study proposes a method based on the keypoint of cabbage head for estimating cabbage head diameters with different degrees of occlusion in the field. An improved deep learning model, YOLOv8n-Cabbage Keypoints (YOLOv8n-CK), is introduced to accurately and rapidly detect the keypoints of cabbage heads. Specifically, to enhance the attention of the network to occluded cabbage head features in complex images, the convolutional block attention module (CBAM) is introduced in the backbone, thereby improving the accuracy of the model in detecting the keypoints of occluded cabbage heads. Moreover, to balance the accuracy and speed of the keypoint detection network, all the Conv modules of the C2f-Bottleneck structure are replaced by Ghost modules, which effectively reduces the number of parameters in the model while maintaining its accuracy and reducing the computational complexity. Based on the results of keypoints detection, the physical diameter of cabbage heads is computed by integrating the depth information of the effective keypoints using a histogram filtering algorithm. The experimental results show that for varying degrees of occlusion, YOLOv8n-CK achieves an average precision (AP<sub>50–95</sub>) of 99.2 % in detecting cabbage head keypoints, with 12.68 % and 13.04 % reductions in the params and floating point operations per second, respectively, compared to the original model. The mean absolute percentage error of the cabbage head diameter estimation model is 4.28 ± 0.13 %, and it exhibits favorable performance even under heavy occlusion (occlusion rate >65 %). Validation on an edge computing device shows that the model achieves 142.6 frames per second, which satisfies the real-time diameter estimation requirements for cabbage heads. These findings confirm the effective in-situ measurement of cabbage head diameters in the field, offering innovative insights for the development of efficient and low-damage harvesting equipment for cabbage.</p></div>\",\"PeriodicalId\":50627,\"journal\":{\"name\":\"Computers and Electronics in Agriculture\",\"volume\":null,\"pages\":null},\"PeriodicalIF\":7.7000,\"publicationDate\":\"2024-09-12\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"0\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Computers and Electronics in Agriculture\",\"FirstCategoryId\":\"97\",\"ListUrlMain\":\"https://www.sciencedirect.com/science/article/pii/S0168169924008196\",\"RegionNum\":1,\"RegionCategory\":\"农林科学\",\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"Q1\",\"JCRName\":\"AGRICULTURE, MULTIDISCIPLINARY\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Computers and Electronics in Agriculture","FirstCategoryId":"97","ListUrlMain":"https://www.sciencedirect.com/science/article/pii/S0168169924008196","RegionNum":1,"RegionCategory":"农林科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q1","JCRName":"AGRICULTURE, MULTIDISCIPLINARY","Score":null,"Total":0}
Keypoint detection and diameter estimation of cabbage (Brassica oleracea L.) heads under varying occlusion degrees via YOLOv8n-CK network
Accurate and rapid estimation of cabbage head diameters is critical for precise decision-making in cabbage-harvesting equipment, thereby ensuring the quality of cabbage head harvesting. However, mature cabbage heads are enveloped by layers of outer leaves, resulting in varying degrees of occlusion, which poses significant challenges for direct detection and diameter measurement of cabbage heads. To address this problem, this study proposes a method based on the keypoint of cabbage head for estimating cabbage head diameters with different degrees of occlusion in the field. An improved deep learning model, YOLOv8n-Cabbage Keypoints (YOLOv8n-CK), is introduced to accurately and rapidly detect the keypoints of cabbage heads. Specifically, to enhance the attention of the network to occluded cabbage head features in complex images, the convolutional block attention module (CBAM) is introduced in the backbone, thereby improving the accuracy of the model in detecting the keypoints of occluded cabbage heads. Moreover, to balance the accuracy and speed of the keypoint detection network, all the Conv modules of the C2f-Bottleneck structure are replaced by Ghost modules, which effectively reduces the number of parameters in the model while maintaining its accuracy and reducing the computational complexity. Based on the results of keypoints detection, the physical diameter of cabbage heads is computed by integrating the depth information of the effective keypoints using a histogram filtering algorithm. The experimental results show that for varying degrees of occlusion, YOLOv8n-CK achieves an average precision (AP50–95) of 99.2 % in detecting cabbage head keypoints, with 12.68 % and 13.04 % reductions in the params and floating point operations per second, respectively, compared to the original model. The mean absolute percentage error of the cabbage head diameter estimation model is 4.28 ± 0.13 %, and it exhibits favorable performance even under heavy occlusion (occlusion rate >65 %). Validation on an edge computing device shows that the model achieves 142.6 frames per second, which satisfies the real-time diameter estimation requirements for cabbage heads. These findings confirm the effective in-situ measurement of cabbage head diameters in the field, offering innovative insights for the development of efficient and low-damage harvesting equipment for cabbage.
期刊介绍:
Computers and Electronics in Agriculture provides international coverage of advancements in computer hardware, software, electronic instrumentation, and control systems applied to agricultural challenges. Encompassing agronomy, horticulture, forestry, aquaculture, and animal farming, the journal publishes original papers, reviews, and applications notes. It explores the use of computers and electronics in plant or animal agricultural production, covering topics like agricultural soils, water, pests, controlled environments, and waste. The scope extends to on-farm post-harvest operations and relevant technologies, including artificial intelligence, sensors, machine vision, robotics, networking, and simulation modeling. Its companion journal, Smart Agricultural Technology, continues the focus on smart applications in production agriculture.