CN112907565A - Fan blade defect identification method based on improved YOLOv3 - Google Patents

Fan blade defect identification method based on improved YOLOv3 Download PDF

Info

Publication number
CN112907565A
CN112907565A CN202110290817.7A CN202110290817A CN112907565A CN 112907565 A CN112907565 A CN 112907565A CN 202110290817 A CN202110290817 A CN 202110290817A CN 112907565 A CN112907565 A CN 112907565A
Authority
CN
China
Prior art keywords
pruning
model
layer
parameter
training
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
CN202110290817.7A
Other languages
Chinese (zh)
Inventor
张亚平
于傲
王方政
汤鹏
邹祖冰
朱小毅
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Three Gorges Corp
Original Assignee
China Three Gorges Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Three Gorges Corp filed Critical China Three Gorges Corp
Priority to CN202110290817.7A priority Critical patent/CN112907565A/en
Publication of CN112907565A publication Critical patent/CN112907565A/en
Withdrawn legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0004Industrial image inspection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20084Artificial neural networks [ANN]

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • General Health & Medical Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • Artificial Intelligence (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Biomedical Technology (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Quality & Reliability (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Testing Of Devices, Machine Parts, Or Other Structures Thereof (AREA)

Abstract

Training a YOLOv3 model based on an improved YOLOv3 fan blade defect identification method to obtain an optimal weight; taking the parameter gamma of the BN layer as a pruning factor, and selecting a proper parameter a to obtain a sparse model; according to a preset cutting threshold value s, cutting off a channel corresponding to the smaller parameter gamma and a corresponding parameter to complete pruning operation; training and fine-tuning the pruned model; adjusting the number of channels of the model convolutional layer after pruning to obtain a regular network model; the same residual error structural units are reduced on the regular network model, so that dense links are reduced, and an improved lightweight network model is obtained; and training a fan blade defect data set by using the improved lightweight network model to obtain optimal weight, thereby realizing fan blade defect identification. The method is used for identifying the defects of the fan blade through an improved YOLOv3 model; the identification efficiency is greatly improved, the labor force is liberated, and the method has great significance to the operation and maintenance of the power station.

Description

Fan blade defect identification method based on improved YOLOv3
Technical Field
The invention relates to the technical field of fan blade detection, in particular to a fan blade defect identification method based on improved YOLOv 3.
Background
With the rapid development of new energy in China, the scale of wind power generation is larger and larger, the maintenance of fan blades becomes an important link for the operation of the whole wind power plant, at present, the defect identification and detection of the fan blades mainly depend on visible light collection, the type of defects is manually judged, the efficiency is lower, the consumed time is longer, the other method is to compare defective images and normal images through a computer to obtain an analysis result, the processing time is long, and the accuracy is lower.
At present, the target recognition Detection algorithm based on deep learning mainly extracts image features through a convolutional neural network, and is mainly divided into two main categories, one category is based on a two-stage mode, such as an R-CNN algorithm recorded in literature [1] Girshick R, Donahue J, Darrell T, et al. Rich Feature Hierarchies for Accurate Object Detection and magnetic selection [ C ] IEEE Conference on Computer Vision & Pattern recognition.2014; fast R-CNN algorithm described in literature [2] Girshick R.Fast R-CNN [ C ]// IEEE International Conference on Computer Vision and Pattern Recognition,2015: 1440-1448; faster R-CNN algorithm described in literature [3] Ren S, He K, Girshick R B, et al. Faster R-CNN: towards real-time object detection with region protocol networks [ J ]. IEEE Transactions on Pattern Analysis and Machine Analysis, 2017,39(6): 1137) 1149.
One is a one-stage approach, such as the YOLO algorithm described in [4] Redmon J, Divvala S, Girshick R, et al, you Only Look Online: Unifield, Real-Time Object Detection [ J ].2015 ]; SSD algorithms described in document [5] Liu W, Anguelov D, Erhan D, et al.SSD: Single Shot MultiBox Detector [ C ]// European Conference on Computer Vision. The deep network model can improve the identification accuracy of the image target and realize intelligent identification.
The regression-based YOLO algorithm is a popular target detection algorithm at present, integrates two stages of extraction of candidate areas and target identification, obtains the category and position information of a target through a complete network structure, and has both accuracy and speed.
The fan blade defect identification and detection in the prior art has the following defects:
1) at present, the defect detection of some fan blades is manually observed through photos, so that the data volume is large, the efficiency is low, and time and labor are wasted;
2) the acquired defect image and the existing normal image are processed and compared by the computer to obtain an analysis result, and the method is long in processing time and low in accuracy.
3) The Yolov3 improves the identification accuracy, but the model is complex and large in scale, millions of parameters are needed during convolution operation, the requirement on the memory of hardware equipment is high, and some equipment with limited resources cannot run the network model.
4) The complex model has large calculation amount, occupies excessive CUP and GPU resources, consumes a large amount of time and affects the real-time performance of detection.
Disclosure of Invention
In order to solve the technical problem, the invention provides a fan blade defect identification method based on improved YOLOv3, which is used for fan blade defect identification through an improved YOLOv3 model; the identification efficiency is greatly improved, the labor force is liberated, and the method has great significance to the operation and maintenance of the power station.
The technical scheme adopted by the invention is as follows:
the fan blade defect identification method based on the improved YOLOv3 comprises the following steps:
s1, training a YOLOv3 model, wherein the average error rate is gradually reduced in the training process, and the training is stopped when the loss value is gradually reduced to be stable, so that the optimal weight is obtained;
s2: taking a parameter gamma of a BN layer as a pruning factor, cutting a channel layer according to a gamma value, introducing a parameter a to control the parameter sparseness degree of the BN layer, analyzing the influence of the size of the parameter a on the pruning factor gamma in the training process, extracting all the pruning factor gamma of the BN layer to be arranged in sequence, analyzing the distribution condition of the pruning factor gamma under different parameters a, and selecting a proper parameter a to obtain a sparse model;
in the step S2, the first step,
in the training process, continuously reducing the value of the pruning factor gamma, pruning channels with smaller contribution degree, sparsely training the pruning factor gamma in the BN layer, introducing L1 regularization, and adopting a formula
Figure BDA0002982548130000021
Redefining the implementation mode of the BN layer, and introducing the parameter a to control the parameter sparsity degree of the BN layer to finish sparsity training.
S3: after the thinning training, the value of the pruning factor gamma is reduced, and according to a preset shearing threshold value s, a channel corresponding to a smaller parameter gamma and a corresponding parameter are sheared to complete the pruning operation;
in S3, channel pruning is performed, all the pruning factors γ of the BN layer are sorted, a pruning ratio p is set, and the maximum parameter to be pruned is calculated according to the size of the pruning ratio p, and the maximum parameter value is recorded as a pruning threshold S.
In S3, when the pruning factor gamma corresponding to the channel layer is smaller than the threshold value S for clipping, recording the number of channels to be reserved in the network layer after clipping, and marking the channels to obtain a pre-clipping model; and after pre-pruning, obtaining a channel layer index list and a reserved list which are required to be pruned in each layer of network, pruning the channel index list according to the requirement to finish the pruning operation, and obtaining a model after pruning.
S4, training and fine-tuning the pruned model;
s5, adjusting the number of channels of the model convolutional layer after pruning to the power n closest to 2 to obtain a regular network model;
in S5, the number of channels of the pruned model convolutional layer is adjusted to the nearest n-th power of 2 by using the following formula:
lga=nlg2
n=lga/lg2
x=2n
s6, reducing the same residual error structural units on the regular network model, thereby reducing dense links and obtaining an improved lightweight network model;
s7: and training a fan blade defect data set by using the improved lightweight network model to obtain optimal weight, thereby realizing fan blade defect identification.
The invention discloses a fan blade defect identification method based on improved YOLOv3, which has the following technical effects:
1) by pruning the YOLOv3 model, the scale of the deep neural network model is reduced, the number of channels is reduced, and the parameter quantity is greatly reduced, so that the calculation complexity is reduced, and the method can be operated on a hardware platform with weaker performance.
2) And the pruned neural network is compressed again to form a lightweight network model. The model is reduced in network depth, the scale of the neural network is reduced, the identification accuracy of the model is considered, a network model with improved compression is obtained through experiments, training and analysis are carried out on the same data set, and the overall performance of the model is worried.
3) The improved YOLOv3 model is used for identifying the defects of the fan blades, greatly improves the identification efficiency, liberates labor force and has great significance for operation and maintenance of power stations.
Drawings
FIG. 1 is a pruning flow chart of the present invention.
FIG. 2 is a model diagram of Darknet 53Yolov3 according to the present invention.
FIG. 3 is a schematic view of the channel layer structure of 63-74 before pruning.
FIG. 4 is a schematic view of the structure of the channel layers 63-74 after pruning according to the present invention.
FIG. 5 is a schematic diagram of a structured network model according to the present invention.
Fig. 6 is a schematic view of a lightweight network model according to the present invention.
FIG. 7 is a schematic diagram of an improved YOLOv3 fan blade defect identification system.
Detailed Description
The fan blade defect identification method based on the improved YOLOv3 applies the improved neural network model based on deep learning to the detection and defect identification of the fan blade. According to the method, YOLOv3 is used as an algorithm for identifying the defect target of the fan blade, a model is trained in a sparse mode, the contribution degree of partial neurons is weakened, a channel layer of the model is cut according to a set pruning factor gamma, and the redundancy of the model is removed; regularizing and adjusting the irregular model after pruning to enable the channel layer of the backbone network to present the power number of 2; and carrying out hierarchical cutting on the adjusted network, and compressing the backbone network to obtain the neural network model with a simplified scale.
Model pruning needs to cut off part of neurons in the network, and the contribution of the cut neurons to the whole model is small. When some parameter values in the model approach to or become 0, the effect of propagation in the neural network is very small, and the contribution of the neurons corresponding to the parameters in the network connection is obviously reduced. The detection performance of the entire model can be maintained by cutting out these unimportant neurons. In order to approach the partial weight parameter values to 0, a sparse training mode can be adopted.
The sparsification training is as follows:
the BN layer is used for normalizing the channel, the gamma factor of the BN layer can be used as a pruning factor of the channel, no additional parameter is required to be introduced, and the expenditure of a neural network is reduced. And finally, cutting according to the value of the pruning factor gamma. In the training process, the value of a pruning factor gamma needs to be continuously reduced, channels with smaller contribution degree are pruned, so that the parameter gamma in a BN layer needs to be sparsely trained, L1 regularization is introduced, and a formula is adopted
Figure BDA0002982548130000041
f (x, W) is the predicted output of the sample, y is the true output of the sample, a is the balance parameter of the two terms, x is the sample, W is the weight of the network training.
Redefining the implementation mode of the BN layer, and introducing the parameter a to control the parameter sparsity degree of the BN layer to finish sparsity training.
After the sparsification training, the value of the parameter gamma is reduced, and according to a preset threshold value, channels and corresponding parameters corresponding to the smaller gamma are cut off to complete the pruning operation. The pruning procedure is shown in FIG. 1.
The model obtained through pruning is a model obtained by extracting features according to a data set during pre-training, is usually only suitable for the data set during pre-training, although the performance on the data set is very good, the generalization capability of the neural network after pruning is weak, the identification accuracy rate can be unstable when the neural network is used for training other data sets, a backbone network can be further trimmed and compressed on the basis of the pruning neural network to obtain a lightweight network model, and the data set is trained by using the lightweight network model.
And taking the residual structure as a basic unit structure, and re-trimming the number of the filters. According to the characteristics of Darknet 53Yolov3 model structure, the number of channels of the model convolutional layer after pruning is adjusted to the nearest n power of 2 by adopting the following formula.
lga=nlg2
n=lga/lg2
x=2n
The backbone network is formed by connecting residual error structures, and the removal of some layers from the ResNet network does not have great influence on the network performance. According to the thought, the backbone network is compressed by adopting a mode of reducing a residual error structure, and a lightweight network model is obtained.
The residual structure directly transmits the original output of the previous layer to the later layer, and the original output is added with the data through convolution operation to be used as the input of the next layer of network, so that overfitting of the network can be reduced.
The fan blade defect identification method based on the improved YOLOv3 comprises the following steps:
s1: a deep learning platform is built, a Darknet frame is used for pre-training a neural network, parameters such as learning rate and round number are configured to train a Darknet 53YOLOv3 model, and the model is shown in figure 2. The average error rate will gradually decrease in the training process, and when the loss value gradually decreases to reach a stable value, the training can be stopped to obtain the optimal weight.
S2: performing sparse training, taking the parameter gamma of the BN layer as a pruning factor, and cutting the channel layer according to the value of gamma, so that the parameter gamma of the BN layer needs to be sparse trained, and in the training process, a is generally 10-3、10-4、10-5And (4) equivalence. Analysis of the size of aThe influence of the number γ. All gamma factors of the BN layer are extracted and arranged in sequence, the distribution conditions of the parameters gamma under different a are analyzed, and a proper a is selected to obtain a sparse model.
S3: and (3) carrying out channel pruning, sequencing all parameters gamma of the BN layer, setting a pruning ratio p, calculating the maximum parameter to be pruned according to the size of p, recording the value as a threshold value s of pruning, recording the number of channels to be reserved in the network layer after pruning when a pruning factor corresponding to the channel layer is less than s, and marking the channels to obtain the structure of the pre-pruning model. After pre-pruning, a channel layer index list and a reserved list which are required to be pruned in each layer of the network are obtained, pruning operation is completed according to the channel index list to be pruned, a pruned model is obtained, the channel layer of the pruned model is extremely irregular, and the structure pairs of layers 63-74 before pruning and after pruning are shown in fig. 3 and 4.
S4: the model after pruning needs to be trained for fine adjustment, and the fine adjustment is to train for a plurality of rounds again.
S5: and (3) backbone network trimming, namely adjusting the number of channels of the model convolutional layer after pruning to be nearest to the power of 2 n, so as to obtain a more regular network model. As shown in fig. 5.
S6: the same residual structural units are reduced on the regular network model, so that dense links are reduced, and a lightweight network model is obtained, as shown in fig. 6.
S7: and training a fan blade defect data set by using the improved lightweight network model to obtain optimal weight, so that the blade defects can be efficiently and intelligently detected.
The optimal weight is a weight parameter obtained by training.
The acquired data are analyzed and detected in real time through the improved YOLOv3 target detection model, the type of the defect is alarmed, and the analyzed log information is filed, and the whole fan blade defect identification system is shown in FIG. 7.
The recognition system comprises image data acquisition equipment, and a server is used for preprocessing image data, improving a YOLOv3 model for prediction and defect warning, and storing log information.
The experiments were performed on the street scenes Challenge data set using both the model YOLOv3 and the modified YOLOv3, and the results are shown in table 1.
TABLE 1 comparison of model results
Figure BDA0002982548130000061

Claims (5)

1. The fan blade defect identification method based on the improved YOLOv3 is characterized by comprising the following steps of:
s1, training a YOLOv3 model, wherein the average error rate is gradually reduced in the training process, and the training is stopped when the loss value is gradually reduced to be stable, so that the optimal weight is obtained;
s2: taking a parameter gamma of a BN layer as a pruning factor, cutting a channel layer according to a gamma value, introducing a parameter a to control the parameter sparseness degree of the BN layer, analyzing the influence of the size of the parameter a on the pruning factor gamma in the training process, extracting all the pruning factor gamma of the BN layer to be arranged in sequence, analyzing the distribution condition of the pruning factor gamma under different parameters a, and selecting a proper parameter a to obtain a sparse model;
s3: after the thinning training, the value of the pruning factor gamma is reduced, and according to a preset shearing threshold value s, a channel corresponding to a smaller parameter gamma and a corresponding parameter are sheared to complete the pruning operation;
s4, training and fine-tuning the pruned model;
s5, adjusting the number of channels of the model convolutional layer after pruning to the power n closest to 2 to obtain a regular network model;
s6, reducing the same residual error structural units on the regular network model, thereby reducing dense links and obtaining an improved lightweight network model;
s7: and training a fan blade defect data set by using the improved lightweight network model to obtain optimal weight, thereby realizing fan blade defect identification.
2. The fan blade defect identification method based on the improved YOLOv3 of claim 1,the method is characterized in that: in S2, in the training process, continuously reducing the value of the pruning factor gamma, pruning channels with smaller contribution degree, sparsely training the pruning factor gamma in the BN layer, introducing L1 regularization, and adopting a formula
Figure FDA0002982548120000011
Redefining the implementation mode of the BN layer, and introducing the parameter a to control the parameter sparsity degree of the BN layer to finish sparsity training.
3. The fan blade defect identification method based on the improved YOLOv3 as claimed in claim 1, wherein: in S3, channel pruning is performed, all the pruning factors γ of the BN layer are sorted, a pruning ratio p is set, and the maximum parameter to be pruned is calculated according to the size of the pruning ratio p, and the maximum parameter value is recorded as a pruning threshold S.
4. The fan blade defect identification method based on the improved YOLOv3 as claimed in claim 1, wherein: in S3, when the pruning factor gamma corresponding to the channel layer is smaller than the threshold value S for clipping, recording the number of channels to be reserved in the network layer after clipping, and marking the channels to obtain a pre-clipping model; and after pre-pruning, obtaining a channel layer index list and a reserved list which are required to be pruned in each layer of network, pruning the channel index list according to the requirement to finish the pruning operation, and obtaining a model after pruning.
5. The fan blade defect identification method based on the improved YOLOv3 as claimed in claim 1, wherein: in S5, the number of channels of the pruned model convolutional layer is adjusted to the nearest n-th power of 2 by using the following formula:
lga=nlg2
n=lga/lg2
x=2n
CN202110290817.7A 2021-03-18 2021-03-18 Fan blade defect identification method based on improved YOLOv3 Withdrawn CN112907565A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110290817.7A CN112907565A (en) 2021-03-18 2021-03-18 Fan blade defect identification method based on improved YOLOv3

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110290817.7A CN112907565A (en) 2021-03-18 2021-03-18 Fan blade defect identification method based on improved YOLOv3

Publications (1)

Publication Number Publication Date
CN112907565A true CN112907565A (en) 2021-06-04

Family

ID=76105378

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110290817.7A Withdrawn CN112907565A (en) 2021-03-18 2021-03-18 Fan blade defect identification method based on improved YOLOv3

Country Status (1)

Country Link
CN (1) CN112907565A (en)

Similar Documents

Publication Publication Date Title
CN109272500B (en) Fabric classification method based on adaptive convolutional neural network
CN113379699A (en) Transmission line insulator defect detection method based on deep learning
CN108229550B (en) Cloud picture classification method based on multi-granularity cascade forest network
CN108256482A (en) A kind of face age estimation method that Distributed learning is carried out based on convolutional neural networks
CN113034483B (en) Cigarette defect detection method based on deep migration learning
CN111199213A (en) Equipment defect detection method and device for transformer substation
CN112487938A (en) Method for realizing garbage classification by utilizing deep learning algorithm
CN116681962A (en) Power equipment thermal image detection method and system based on improved YOLOv5
CN115100549A (en) Transmission line hardware detection method based on improved YOLOv5
CN112528738A (en) Artificial intelligence image recognition model optimization method and system
CN115452376A (en) Bearing fault diagnosis method based on improved lightweight deep convolution neural network
CN111090747A (en) Power communication fault emergency disposal method based on neural network classification
CN112561054B (en) Neural network filter pruning method based on batch characteristic heat map
CN110555384A (en) Beef marbling automatic grading system and method based on image data
CN115830302B (en) Multi-scale feature extraction fusion power distribution network equipment positioning identification method
CN117496223A (en) Light insulator defect detection method and device based on deep learning
CN117197554A (en) Transformer oil leakage real-time detection method and system
CN112132088A (en) Inspection point location missing inspection identification method
CN112907565A (en) Fan blade defect identification method based on improved YOLOv3
CN116561692A (en) Dynamic update real-time measurement data detection method
CN110991743A (en) Wind power short-term combination prediction method based on cluster analysis and neural network optimization
CN113221668B (en) Frame extraction method in wind generating set blade video monitoring
CN116415714A (en) Wind power prediction method and device, electronic equipment and readable storage medium
CN115392710A (en) Wind turbine generator operation decision method and system based on data filtering
CN115100546A (en) Mobile-based small target defect identification method and system for power equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WW01 Invention patent application withdrawn after publication
WW01 Invention patent application withdrawn after publication

Application publication date: 20210604