High-altitude operation safety belt detection method based on improved YOLOv8 model
The improved YOLOv8 model addresses detection challenges by integrating FasterNet, PConv, and SDI modules, achieving faster and more accurate safety belt detection suitable for resource-constrained edge devices, ensuring real-time monitoring and improved safety in power plant operations.
Patent Information
- Application Number
- CN202410527719.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-29
- Publication Date
- 2024-12-03
AI Technical Summary
Existing deep learning-based methods for detecting aerial work safety belts in power plants face challenges due to low detection accuracy, inefficiency, and the need for real-time monitoring in complex and changeable environments, with traditional YOLO models being computationally intensive and unsuitable for resource-constrained edge devices.
The method involves replacing the YOLOv8 backbone with FasterNet, integrating partial convolution (PConv) and Semantic Detail Fusion (SDI) modules, and constructing a lightweight detection head to enhance detection speed and accuracy for high-altitude work safety belts, using a customized dataset for training and evaluation.
The improved YOLOv8 model achieves faster and more accurate detection of safety belts, reducing computational demands and enabling real-time monitoring on edge devices, thereby enhancing safety and efficiency in power plant operations.
Smart Images

Figure CN119068166A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of deep learning target detection and relates to a high-altitude work safety belt detection method based on an improved YOLOv8 model. Background Art
[0002] With the rapid development of the power industry, the safety of power production has received increasing attention. In my country, power production accidents occur frequently, posing a serious threat to urban production safety. In power production operations, high-altitude operations are a high-risk activity. When workers work at heights, if they do not take appropriate safety measures, such as wearing safety belts correctly, safety accidents are very likely to occur, resulting in casualties and property losses. Therefore, ensuring that power workers wear safety belts correctly when working at heights is crucial to improving the level of on-site safety operations.
[0003] Traditional seat belt detection methods mainly rely on manual screening, which is not only inefficient but also has low detection accuracy and cannot meet the needs of modern power production. With the development of deep learning technology, automatic detection methods based on computer vision have gradually become a research hotspot. These methods can automatically detect seat belts in images and determine their wearing conditions, greatly improving detection efficiency and accuracy.
[0004] However, existing deep learning-based target detection methods are mainly aimed at general object detection, and the detection of small targets such as aerial work safety belts is still challenging. The aerial work safety belts account for a small proportion of the image and have unclear features. In addition, the working environment is complex and changeable, such as different lighting conditions and various background interferences, which make it difficult to accurately detect the safety belts. In addition, the particularity of power operations requires that the detection model must have not only high accuracy, but also fast detection speed to meet the needs of real-time monitoring.
[0005] Object detection models represented by YOLO have good results in detection accuracy and speed. Its successful application in object detection in the production field provides a reference for high-altitude safety belt object detection. At the same time, the network structure can be modified to further reduce the number of model parameters, improve the object detection speed, and deploy it on edge devices with limited computing power. Summary of the invention
[0006] 1. Purpose of the invention:
[0007] The purpose of this invention is to propose a high-altitude work safety belt detection method based on the improved YOLOv8 model, taking the high-altitude work safety belts of power plants in various places as the research object, and making lightweight improvements to the high-altitude work safety belt target detection model in the production site, thereby reducing the amount of calculation, saving equipment resources, and meeting the safety belt wearing detection requirements during high-altitude work.
[0008] 2. Technical solution:
[0009] In view of this, in order to solve the above problems, the present invention provides a method for detecting high-altitude work safety belts based on an improved YOLOv8 model, and the technical solution is as follows:
[0010] Step 1: Construct a data set of high-altitude work safety belts at power plant production sites and divide it into a training set and a validation set in a ratio of 8:2;
[0011] Step 2: Replace the backbone network of YOLOv8n with the backbone network of FasterNet, introduce the Fasternet module and partial convolution (PConv), and attach PWConv after PConv;
[0012] Step 3: Improve the feature extraction module and replace all the Concat modules in the YOLOv8 header with the Semantic and Detail Fusion (SDI) modules;
[0013] Step 4: Build a lightweight detection head and use PConv convolution to replace part of the traditional 3×3 convolution in the Head part of YOLOv8;
[0014] Step 5: Use the constructed power plant aerial work safety belt dataset to train, verify, and evaluate the improved YOLOv8 model.
[0015] 2. According to a high-altitude work safety belt detection method based on an improved YOLOv8 model, it is characterized in that the construction method of the FasterNet module in step 2 is: each FasterNet module consists of a PConv layer and two PWConv layers; in addition, a normalization layer (BN) and a ReLU activation function are added to the two PWConv layers of each FasterNet module; finally, a global average pooling, a 1×1 convolution kernel and a fully connected layer are used to complete feature conversion and classification.
[0016] 3. According to a high-altitude work safety belt detection method based on an improved YOLOv8 model, it is characterized in that the construction method of the semantic and detail fusion (SDI) module in step 3 is: first, the channel attention and spatial attention mechanisms are used for the initial features of the layers to redistribute the weights of the features; secondly, the features of all levels are converted into the same dimension, the number of channels is reduced to c by using 1×1 convolution, and then all features are mapped to the same dimension through adaptive average pooling downsampling and bilinear interpolation upsampling; then, a 3×3 convolution is used for each layer of features to smooth the feature map to reduce the impact of up and down sampling; finally, the Hadamard product is calculated for all features corresponding to each layer of the decoder network to aggregate their respective semantic information and detail information.
[0017] 4. According to a high-altitude work safety belt detection method based on an improved YOLOv8 model, it is characterized in that the memory access amount and floating-point operation amount of the PConv convolution in step 4 are:
[0018] PConv memory access amount P arams The calculation formula for floating-point operations FLOPs is as follows:
[0019] P arams =h×w×2c p +k 2 ×c p 2 ≈h×w×2c p (5)
[0020] FLOPs = h × w × k 2 ×c p 2 (6)
[0021] Where h, w - width and height of the feature map
[0022] k — the size of the convolution kernel
[0023] c p ——The number of channels affected by PConv
[0024] The memory access of PConv is only 1 / 4 of that of regular convolution, and the rest of cc p The channels do not participate in the calculation and do not need to access memory, so the FLOPs of PConv is only 1 / 16 of that of conventional convolution, which can effectively reduce the number of parameters and floating-point operations of the model.
[0025] 3. Innovation points:
[0026] Compared with the original YOLOv8 model, the present invention adopts Fasternet to replace the traditional YOLOv8 network as the backbone network, introduces a semantic and detail fusion (SDI) module, and adopts PConv convolution to replace part of the traditional 3×3 convolution in the Head part of the model.
[0027] In general, the present invention introduces the following methods and ideas:
[0028] (1) To address the problem of low computing speed in the traditional YOLOv8 model network, Fasternet is introduced to replace the backbone network of the traditional YOLOv8 model, reducing latency and improving computing speed without affecting accuracy.
[0029] (2) In order to address the ambiguity of existing safety belt detection methods in locating "workers working at heights" and the inefficiency of traditional supervision methods, the feature extraction module is improved, and the SDI module is introduced to improve the skip connection of the encoder-decoder network, integrating the semantic information of high-level features and the detailed information of low-level features, which significantly enhances the model's detection ability for small targets and improves the detection accuracy of safety belts for high-altitude work.
[0030] (3) In view of the problem that the wearing detection of safety belts during high-altitude operations in the current power plant production environment needs to meet the requirements of low latency and high throughput, a lightweight detection head is constructed, and PConv convolution is introduced in the head part of the target detection model to replace part of the traditional 3×3 convolution, which further reduces the amount of calculation and significantly improves the detection speed, making the model more suitable for real-time monitoring applications.
[0031] 4. Beneficial effects:
[0032] The present invention provides a high-altitude work safety belt detection method based on an improved YOLOv8 model. By introducing the FasterNet backbone network and partial convolution (PConv) technology, the speed and accuracy of the high-altitude work safety belt detection in the power plant are significantly improved. By improving the feature extraction module, all Concat modules are replaced with semantic and detail fusion (SDI) modules, which effectively enhances the detection capability of small targets. By introducing a lightweight detection head, PConv convolution is introduced in the Head part of the target detection model to replace part of the traditional 3×3 convolution. The design reduces the demand for computing resources, so that it can run efficiently on resource-constrained edge devices. These improvements not only improve the efficiency of power maintenance and overhaul, but also provide a strong technical guarantee for ensuring the personal safety of power workers, and obtain significant social and economic benefits. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.
[0034] Figure 1 A structural diagram of an improved YOLOv8 model provided in an embodiment of the present invention;
[0035] Figure 2 A flowchart of an improved YOLOv8 model provided by an embodiment of the present invention;
[0036] Figure 3 FasterNet backbone network architecture diagram provided for an embodiment of the present invention;
[0037] Figure 4 A schematic diagram of a FasterNet module provided in an embodiment of the present invention;
[0038] Figure 5 An SDI structure diagram provided for an embodiment of the present invention;
[0039] Figure 6 The PConv principle diagram provided by the embodiment of the present invention. DETAILED DESCRIPTION
[0040] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0041] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.
[0042] See also Figure 1 , the present invention provides a method for detecting high-altitude work safety belts based on an improved YOLOv8 model. Figure 2 , the specific implementation is as follows:
[0043] Step 1: Construct a data set of safety belts for aerial work at power plant production sites. The specific operations are as follows:
[0044] The experimental data set uses the production site operation photos published on the official website of Alibaba Cloud Tianchi, including low hanging high use violation data and high hanging low use correct data pictures of different light intensities, different perspectives, and different scenes. Labelme is used for data annotation to produce a data set that is more in line with the production site specifications of Datang Group, and the labeled data set is divided into a training set and a validation set in a ratio of 8:2, with 2026 and 500 photos respectively. The data set includes three categories: ground personnel, off-ground personnel, and high-altitude work safety belts.
[0045] Step 2: Replace the backbone network of YOLOv8n with the backbone network of FasterNet, introduce the Fasternet module and partial convolution (PConv), and attach PWConv after PConv. The steps to build the FasterNet module are as follows:
[0046] See also Figure 3The overall architecture of the FasterNe backbone network can be divided into four stages. First, before each stage, an embedding layer with a stride of 4 and a 4×4 convolution kernel or a merging layer with a stride of 2 and a 2×2 convolution kernel is designed for spatial downsampling and channel number expansion; second, several FasterNet blocks are set in each stage, and each FasterNet module consists of a PConv layer and two PWConv layers; in addition, too many normalization layers and activation layers will limit feature diversity, thereby affecting detection performance. Therefore, a normalization layer (BN) and a ReLU activation function are added to the two PWConv layers of each FasterNet module, see Figure 4 Among them, BN improves both training speed and accuracy. Using ReLU as the activation function improves the model training speed while avoiding the problem of gradient vanishing. Placing the normalization layer and activation layer between the two PWConv layers of each FasterNet module can reduce latency and maintain feature diversity. Finally, a global average pooling, a 1×1 convolution kernel, and a fully connected layer are used to complete feature conversion and classification.
[0047] Step 3: Improve the feature extraction module and replace all the Concat modules in the YOLOv8 header with the Semantic and Detail Fusion (SDI) module. The construction steps of the SDI module are as follows:
[0048] First, the channel attention and spatial attention mechanisms are used for the initial features of the layers to redistribute the weights of the features, as shown in formula (1). Secondly, the features of all levels are converted to the same dimension, and the number of channels is reduced to c using 1×1 convolution. Then, all features are mapped to the same dimension through adaptive average pooling downsampling and bilinear interpolation upsampling, as shown in formula (2). Then, a 3×3 convolution is used for each layer of features to smooth the feature map and reduce the impact of up and down sampling, as shown in formula (3). Finally, the Hadamard product is calculated for all features corresponding to each layer of the decoder network to aggregate their respective semantic information and detail information, as shown in formula (4).
[0049]
[0050] Where f i 0 is the initial feature of the i-th layer, Mc is the channel attention coefficient, Ms is the spatial attention coefficient, MLP represents a two-layer neural network, σ is the sigmoid activation function, AvgPool is the average pooling, MaxPool is the maximum pooling, and f i 1 is the feature after using channel attention, f i 2 The features after using spatial attention.
[0051]
[0052] In the formula is the j-th layer feature with the same number of channels, H i With W i is the width and height of the i-th layer decoder, is the feature of the jth level in the i-th layer decoder network.
[0053]
[0054] Where θ ij is the coefficient of the smoothed convolution layer, is the feature after smoothing convolution.
[0055]
[0056] H is the Hadamard product, that is, the bitwise multiplication of the matrices. is the feature passed to the i-th layer decoder network.
[0057] See also Figure 5 ,By introducing SDI, the model can integrate the semantic information in high-level features and the ,detail information in low-level features, and pass them to various parts of the subsequent ,segmentation network.
[0058] Step 4: Build a lightweight detection head. Use PConv convolution to replace part of the traditional 3×3 convolution in the Head part of YOLOv8. Figure 6 , the design steps of the PConv module are as follows:
[0059] PConv memory access amount P arams The calculation formula for floating-point operations FLOPs is as follows:
[0060] P arams =h×w×2c p +k 2 ×c p 2 ≈h×w×2c p (5)
[0061] FLOPs = h × w × k 2 ×c p 2 (6)
[0062] Where h, w - width and height of the feature map
[0063] k — the size of the convolution kernel
[0064] c p ——The number of channels affected by PConv
[0065] The memory access of PConv is only 1 / 4 of that of regular convolution, and the rest of cc p The channels do not participate in the calculation and do not need to access memory, so the FLOPs of PConv is only 1 / 16 of that of conventional convolution, which can effectively reduce the number of parameters and floating-point operations of the model.
[0066] Step 5: Use the power plant aerial work safety belt dataset constructed in step 1 to train, verify, and evaluate the improved YOLOv8 model:
[0067] The training was conducted on the experimental equipment, which was configured as follows: the processor was Intel Core i9-14900HX CPU, the GPU was NVIDIA GeForce RTX 4060Laptop GPU, the video memory was 24GB, the operating system was Windows 11, 64-bit, Python version 3.8.16, Pytorch1.13.1 framework, and Cuda version 11.7. The training parameters were: imgsz was 640, epochs was 300, batch was 16, workers was 8, Initial learning rate was 0.01, and Optimizer was SGD. The YOLOv5 original model, YOLOv6 original model, YOLOv8n original model, and improved YOLOv8 model were trained and verified using the high-altitude work safety belt dataset at the power plant production site. The experimental results are shown in Table 1.
[0068] Table 1
[0069]
[0070] It should be noted that each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description.
[0071] It should also be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device that includes a series of elements is inherent to the elements, or also includes elements inherent to these processes, methods, articles or devices. In the absence of further restrictions, the elements defined by the sentence "including a..." do not exclude the presence of other identical elements in the process, method, article or device that includes the elements.
[0072] The above description of the disclosed embodiments enables one skilled in the art to implement or use the present invention. Various modifications to these embodiments will be apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for detecting high-altitude work safety belts based on an improved YOLOv8 model, characterized in that: The following steps are involved: Step 1: Construct a data set of high-altitude work safety belts at power plant production sites and divide it into a training set and a validation set in a ratio of 8:2; Step 2: Replace the backbone network of YOLOv8n with the backbone network of FasterNet, introduce the Fasternet module and partial convolution (PConv), and attach PWConv after PConv; Step 3: Improve the feature extraction module and replace all the Concat modules in the YOLOv8 header with the Semantic and Detail Fusion (SDI) modules; Step 4: Build a lightweight detection head and use PConv convolution to replace part of the traditional 3×3 convolution in the Head part of YOLOv8; Step 5: Use the power plant aerial work safety belt dataset constructed in step 1 to train, verify, and evaluate the improved YOLOv8 model.
2. According to a high-altitude work safety belt detection method based on an improved YOLOv8 model, it is characterized in that: The construction method of the FasterNet module in step 2 is as follows: each FasterNet module consists of a PConv layer and two PWConv layers; in addition, a normalization layer (BN) and a ReLU activation function are added to the two PWConv layers of each FasterNet module; finally, a global average pooling, a 1×1 convolution kernel, and a fully connected layer are used to complete feature conversion and classification.
3. According to a high-altitude work safety belt detection method based on an improved YOLOv8 model, it is characterized in that: The construction method of the semantic and detail fusion (SDI) module in step 3 is: first, the channel attention and spatial attention mechanisms are used on the initial features of the layers to redistribute the weights of the features; Secondly, the features of all levels are converted to the same dimension, and the number of channels is reduced to c using 1×1 convolution. Then, all features are mapped to the same dimension through adaptive average pooling downsampling and bilinear interpolation upsampling. Then, a 3×3 convolution is used to smooth the feature map of each layer to reduce the impact of up and down sampling. Finally, the Hadamard product of all features corresponding to each layer of the decoder network is calculated to aggregate their respective semantic information and detail information.
4. According to a high-altitude work safety belt detection method based on an improved YOLOv8 model, it is characterized in that: The memory access amount and floating point operation amount of PConv convolution described in step 4 are: PConv memory access amount P arams The calculation formula for floating-point operations FLOPs is as follows: P arams =h×w×2c p +k 2 ×c p 2 ≈h×w×2c p (1) FLOPs=h×w×k 2 ×c p 2 (2) Where h, w- width and height of the feature map k - size of the convolution kernel c p - Number of channels PConv acts on The memory access of PConv is only 1 / 4 of that of regular convolution, and the rest of cc p The channels do not participate in the calculation and do not need to access memory, so the FLOPs of PConv is only 1 / 16 of that of conventional convolution, which can effectively reduce the number of parameters and floating-point operations of the model.
Citation Information
Cited By
Laminated slab embedded structure detection method and system and readable medium
CN119379694A
