To address the issues of low defect detection accuracy and poor real-time performance in the internal inspection of metal bellows, an improved algorithm based on YOLOv8n, named YOLOv8n-FCW, was proposed. First, the backbone network of YOLOv8n was replaced with the faster and more lightweight faster neural networks (FasterNet), ensuring a balance between detection accuracy and computational efficiency. Second, a C2F_S module, incorporating the channel attention mechanism squeeze-and-excitation layer V2(SeLayerV2), partial convolution (PConv), and pointwise convolution (PWConv), was utilized to enhance the network capability for global feature learning, thereby improving the precision of feature representation and the integration of global information. Finally, a loss function named weighted IoU_Scale (WIoU_Scale), which combines weighting and scale adjustment, was adopted to accelerate the convergence speed and improve the accuracy of anchor box predictions. Experimental results demonstrate that, compared to the original YOLOv8n model, YOLOv8n-FCW achieves improvements of 4.7%, 3.8%, and 4.1% in mAP50, mAP50-95, and F1-Score, respectively. The model contains 7.3 million parameters and requires 11.2 GFLOPs of computation. Compared with other object detection algorithms, YOLOv8n-FCW exhibits higher accuracy and parameter efficiency, effectively meeting the requirements for internal defect detection in metal bellows.
为了验证WIoU_Scale的有效性,将YOLOv8n原本的CIoU(complete intersection over union)分别替换为DIoU(distance intersection over union)、GIoU(generalized intersection over union)和SIoU(soft intersection over union),并与WIoU_Scale进行对比,实验结果如表3所示。
JiangXiumin. Research on electromagnetic ultrasonic pipeline defect detection technology based on guided wave mode analysis[D]. Tianjin: Tianjin University of Science and Technology, 2023.
LiHui, LiDeyuan, YanXuewen, et al. Simulation of X-ray backscatter technology for defect detection in oil pipeline walls[J]. Technology Innovation and Application, 2020(24): 138-140.
ShenXiangkai, LiuJinhai. Research on defect and component detection method for oil pipelines based on heterogeneous diffusion model[J]. Control and Decision, 2025, 40(3): 937-945.
ZhouHui, YangJie, ZhaoXiangfei. Lightweight apple detection algorithm based on YOLOv8 in complex orchard environments[J]. Science Technology and Engineering, 2025, 25(6): 2274-2283.
ZhangDi, ZhouAnliang, WenMeng, et al. Detection of quality defects in seed crystal growth process based on improved YOLOv8n[J]. Science Technology and Engineering, 2025, 25(3): 969-976.
WangJunling, WangChenchen, XiongYuhua. Defect detection method for sewer pipelines based on YOLO V5L-IM and effect analysis[J]. Science Technology and Engineering, 2024, 24(18): 7833-7842.
[13]
ChenJ, KaoS H, HeH, et al. Run, don’t walk: chasing higher flops for faster neural networks[C]// 2023 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR). Vancouver: IEEE, 2023: 12021-12031.
[14]
JieH, LiS, SamuelA, et al. Squeeze-and-excitation networks[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2019, 42(8): 2011-2023.
[15]
NarayananM. SENetV2: aggregated dense layer for channelwise and global representations[J]. ArXiv, 2023: 2311.10807.
[16]
TongZ, ChenY, XuZ, et al. Wise-IoU: bounding box regression loss with dynamic focusing mechanism[J]. ArXiv: 2301.10051, 2023.
XiongWei, LuXin, QiuWeijin, et al. Defect detection method for transmission line insulators based on improved YOLOv8 and effect analysis[J]. Electronic Measurement Technology, 2025, 48(2): 178-188.
[19]
ZengJ C, ZhengY M, JinX P, et al. Research on improved YOLOV5 pipeline defect detection algorithm[J]. Journal of Pipeline Systems Engineering and Practice, 2025, 16(2): 1-10.
SunTieqiang, LiuJun, SongChao, et al. Defect detection method for aluminum profiles surface small targets based on improved YOLOv8n[J]. Modern Manufacturing Engineering, 2024(12): 120-129.
YeFamao, ZhangLi, YuanLiao, et al. DB-YOLO: a dual backbone YOLOv8 road defect detection model with feature enhancement fusion[J]. Computer Engineering and Applications, 2024, 60(24): 260-269.
[26]
SuC, HuS, ZhangH, et al. Automatic detection of water supply pipe defects based on underwater image enhancement and improved YOLOx[J]. Journal of Construction Engineering and Management, 2024, 150(10): 14919.
ZengFei, LiBin, ZhouJian, et al. Defect detection and geometric characterization of sewer pipelines based on improved YOLOv7 algorithm[J]. Modern Manufacturing Engineering, 2024(3): 110-118.
[29]
周元昊. 多相机金属管道内壁缺陷检测及其三维可视化研究[D]. 成都: 电子科技大学, 2024.
[30]
ZhouYuanhao. Research on defect detection and 3d visualization of inner walls of metal pipes using multiple cameras[D]. Chengdu: University of Electronic Science and Technology of China, 2024.
YouWeijun, LiCong, ZhangJiangxiong. Experimental study on identifying defects in concrete sewer pipeline joints using YOLOv5 machine learning model[J]. Water & Wastewater Engineering, 2023, 59(S1): 489-494.
[33]
ZhaoQ, WangG. Multi-architecture optimization of pipeline inner wall defect detection algorithm based on YOLOv8[J]. Measurement, 2025, 242: 116305.
[34]
YangD, MaC, YuG, et al. Automatic defect detection of pipelines based on improved OFG-YOLO algorithm[J]. Measurement, 2025, 242: 115847.
[35]
KunC, HongtaoL, ChunshuL, et al. An automatic defect detection system for petrochemical pipeline based on cycle-GAN and YOLOv5[J]. Sensors, 2022, 22(20): 7907.
SongJingjing, ZhangZhenli. Small object traffic sign detection algorithm based on YOLOv8n[J]. Science Technology and Engineering, 2024, 24(36): 15548-15557.
KongJianguo, ZhangXiangwei, ZhaoZhiwei, et al. Real-time bird detection method at airports based on improved YOLOv8[J]. Science Technology and Engineering, 2024, 24(32): 13944-13952.