Abstract:To improve the counting efficiency of steel bars in construction sites, an improved lightweight YOLOv4 algorithm is proposed based on the insufficient computing power of hardware equipment in construction units and the dense occlusion of steel bar image objects. GCA-MobilenetV2 lightweight network is proposed to replace CSPDarknet53 as the main feature network of YOLOv4 algorithm. Aiming at the situation of dense steel bar images and serious occlusion between objects, attention-CSP-PANet structure integrating channel attention mechanism is proposed. Aiming at the large number of SPP structure parameters in deep network, DepthLite-SPP structure is proposed to enhance the receptive field of deep network and improve the detection speed of the algorithm. In view of the imbalance between positive and negative samples of the one-stage regression algorithm, CIOU-Focal loss function is designed. The experimental results show that the detection accuracy of the steel bar data set is 98.78%, which is 3.36% higher than that of the original algorithm. The detection speed FPS is 7.6, and the number of parameters is only 1/3 of the original algorithm.