CN115841460A - High-precision hardware crack image detection and feature extraction method under complex background - Google Patents

High-precision hardware crack image detection and feature extraction method under complex background Download PDF

Info

Publication number
CN115841460A
CN115841460A CN202211454186.9A CN202211454186A CN115841460A CN 115841460 A CN115841460 A CN 115841460A CN 202211454186 A CN202211454186 A CN 202211454186A CN 115841460 A CN115841460 A CN 115841460A
Authority
CN
China
Prior art keywords
anchor box
input
complex background
hardware
crack image
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.)
Pending
Application number
CN202211454186.9A
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.)
Super High Voltage Co Of State Grid Hubei Electric Power Co ltd
Original Assignee
Super High Voltage Co Of State Grid Hubei Electric Power Co ltd
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 Super High Voltage Co Of State Grid Hubei Electric Power Co ltd filed Critical Super High Voltage Co Of State Grid Hubei Electric Power Co ltd
Priority to CN202211454186.9A priority Critical patent/CN115841460A/en
Publication of CN115841460A publication Critical patent/CN115841460A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Image Analysis (AREA)

Abstract

The invention provides a high-precision hardware fitting crack image detection and feature extraction method under a complex background, which is characterized in that parameters are updated directly through learning data by using a deep learning algorithm, so that a complex algorithm process of manual design is avoided, and the method has extremely high robustness and precision. Compared with the conventional method in which feature extraction mainly depends on an extractor designed manually, the conventional method also needs professional knowledge and a complex parameter adjusting process, and each method is specific to specific application, so that the generalization capability and robustness are poor, and the application limit of the conventional method is large particularly under a complex background. Deep learning mainly includes data-driven feature extraction, deep and data set-specific feature representation can be obtained according to learning of a large number of samples, the data set expression is more efficient and accurate, extracted abstract features are higher in robustness, better in generalization capability and adaptive to complex backgrounds, and the end-to-end method can be achieved.

Description

High-precision hardware crack image detection and feature extraction method under complex background
Technical Field
The invention relates to the technical field of computer image processing, high-precision hardware crack image detection, feature extraction and machine learning models, in particular to a high-precision hardware crack image detection and feature extraction method under a complex background.
Background
The construction of the power main artery is gradually realized in China, the scale of a power system is increased, the dependence of national economy and people on the power system is increased, and the requirements of the state on the safety and the stability of the power system are increased. The high-voltage transmission line not only has long transmission distance, but also has wide coverage area, and is vital to national construction. However, due to factors of construction materials and quality problems of the power transmission line, extreme weather, micro-topography and the like, accidents of the high-voltage power transmission line occur in different degrees. The bulb suspension loop is a key load-bearing part in the power transmission line, is generally matched with a bowl-head hardware fitting for use, is easy to generate fatigue fracture under the action of dynamic load of a connecting wire, and is used for solving the problems that the suspension loop, the root part and the rod part are connected to form a variable cross section, so that the normal operation of the power transmission line is seriously influenced.
The breakage of the ball head suspension loop mainly comprises breakage caused by original defects generated in the manufacturing process of the ball head suspension loop, clamping and unreasonable stress of hardware fittings caused by unreasonable installation process, overlarge dynamic load under severe and extreme weather, and cracking caused by corrosion and abrasion after long-term operation. These tests can now be identified and analyzed by means of high-precision cameras taking pictures back to the surface.
The traditional hardware crack image detection algorithm structure obtains an image convenient to detect through image preprocessing, and then extracts image features by means of a statistical machine learning method, so that the defect detection target is achieved. The image preprocessing generally comprises histogram equalization, filtering denoising, gray level binarization and secondary filtering to obtain simplified image information with separated foreground and background; and then completing marking and detecting the defects by using algorithms such as mathematical morphology, fourier transform, gabor transform and the like and a machine learning model. Although the traditional algorithm has achieved better effect in some specific applications, there are still many defects in the hardware detection field. For example: the image preprocessing steps are various, strong pertinence is achieved, and robustness is poor; many algorithms are computationally expensive and cannot accurately detect the size and shape of defects.
Disclosure of Invention
In view of the above practical needs, an object of the present invention is to provide a method for detecting and extracting features of a high-precision hardware crack image under a complex background, in which a deep learning algorithm is used to update parameters directly through learning data, so as to avoid a complex algorithm flow of manual design, and have extremely high robustness and precision. Compared with the traditional method in which feature extraction mainly depends on an extractor designed manually, the traditional method also needs professional knowledge and a complex parameter adjusting process, and each method is specific to specific application, has poor generalization capability and robustness, and particularly has great application limitation in the traditional method under a complex background. Deep learning mainly includes data-driven feature extraction, deep and data set-specific feature representation can be obtained according to learning of a large number of samples, expression of the data set is more efficient and accurate, extracted abstract features are higher in robustness, better in generalization capability and adaptive to complex backgrounds, and the method can be end-to-end.
In order to achieve the above objects and other related objects, the present invention adopts the following technical solutions:
a high-precision hardware crack image detection and feature extraction method under a complex background comprises the following steps:
s1) acquiring a high-precision hardware fitting picture data set A;
s2) taking 70% of pictures in A as a training set T and taking 30% of pictures in A as a test set O;
s3) making training data by using LabelImg, and storing the training data in a VOC2007 data format;
s4) the input picture size is 300 × 300, the number of input RGB channels is 3, the input image RGB average value m _ c = [123, 117, 104], the input anchor box factor S _ c = [0.1,0.2,0.37,0.54,0.71,0.88,1.05], the number of input classes is 1, and the input channel order r = [2,1,0]; inputting characteristic factors a _ r = [ [1.0,2.0,0.5], [1.0,2.0,0.5,3.0,1.0], [1.0,2.0,0.5,3.0,1.0], [1.0,2.0,0.5], [1.0,2.0,0.5] ], inputting adjacent anchor box center point step numbers s _ ds = [8, 16, 32, 64, 100, 300], inputting offset offsets = [0.5,0.5,0.5,0.5,0.5,0.5], inputting boundary code var _ code = [0.1,0.1,0.2,0.2], creating an SSD model M according to inputted parameters M _ c, s _ c, r, a _ r, s _ ds, offsets, var _ code;
s5) loading the training set T to the model M for training;
s6) loading the test set O to the model M for testing;
s7) recording L conf (x, c) is a loss function, L conf (x, c) the formula is:
Figure BDA0003952233850000031
wherein->
Figure BDA0003952233850000032
i denotes the ith anchor box, j denotes the jth input box, <' > H>
Figure BDA0003952233850000033
The ith anchor box is matched with the jth input box with the category p, if the ith anchor box is matched with the jth input box, 1 is taken, and if not, 0 is taken;
s8) inputting the detection factor mu, if L conf (x, c) > mu goes to step S4), and the parameters of the input anchor box factors a _ r and S _ c are adjusted;
and S9) inputting a newly acquired high-precision hardware fitting picture S set to the model M for prejudgment, and outputting a result set R.
Optionally, step S3) uses LabelImg to make training data with the size of the anchor box set to 300X 300, the anchor box being a picture of the presence of crack features.
Optionally, the GRB average parameter m-c in step S4) is used for calculating the average value of the reference color range.
Optionally, the anchor box factor parameter S-c in step S4) is used to configure the anchor box length-width ratio.
Optionally, the input channel sequence parameter r in step S4) is used to specify a color arrangement sequence of the pictures.
Optionally, the characteristic factor parameters a-r in step S4) are used to constrain the aspect ratio of the anchor box convolution layer.
Optionally, the step number parameter S _ ds of the center point of the adjacent anchor box in step S4) is used as a scaling factor for returning the anchor box to the original ray.
Optionally, the offset parameter offset in step S4) is used to determine the center point of the anchor box.
Optionally, the boundary coding parameter var _ code in step S4) is used for scaling the anchor box offset for each coordinate.
Optionally, step S8) detects a factor μ input ranging from 0.6 to 0.9.
The invention has the beneficial effects that: in the field of image recognition, the problems of complex background, large target scale change, low color contrast and the like are always the biggest challenges in various fields of application. The hardware fittings generally have limited size, no obvious characteristics of self color, various application scenes, extremely small crack size, low crack color contrast and the like, so that the detection difficulty is greatly increased. The method applies the SSD deep learning model, reforms the loss function, regards the background part as a simple sample, reduces the proportion of background loss in confidence loss, enables the model to be converged more quickly and the model to be trained more sufficiently, and improves the target detection precision under the complex background. The hardware detection and feature extraction are realized, the technical defects are effectively overcome, the detection application of hardware cracks under a complex background is met, and the positive effect is exerted particularly on the detection of the hardware cracks on the power transmission line in practice.
Drawings
Fig. 1 is a block diagram of a high-precision hardware crack image detection and feature extraction method under a complex background.
Fig. 2 is an implementation schematic diagram of a high-precision hardware crack image detection and feature extraction method under a complex background.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in further detail with reference to the accompanying drawings. It should be understood that the detailed description and specific examples, while indicating the invention, are intended for purposes of illustration only and are not intended to limit the scope of the invention.
In an embodiment, in a method for detecting and extracting high-precision hardware crack images under a complex background, the overall architecture structure is shown in fig. 1; the implementation flow is shown in fig. 2, and comprises the following steps:
s1) acquiring a high-precision hardware fitting picture data set A;
s2) taking 70% of the pictures in the A as a training set T and taking 30% of the pictures in the A as a test set O;
s3) making training data by using LabelImg, and storing the training data in a VOC2007 data format;
s4) the input picture size is 300 × 300, the number of input RGB channels is 3, the input image RGB average value m _ c = [123, 117, 104], the input anchor box factor S _ c = [0.1,0.2,0.37,0.54,0.71,0.88,1.05], the number of input classes is 1, and the input channel order r = [2,1,0]; inputting characteristic factors a _ r = [ [1.0,2.0,0.5], [1.0,2.0,0.5,3.0,1.0], [1.0,2.0,0.5,3.0,1.0], [1.0,2.0,0.5], [1.0,2.0,0.5] ], inputting adjacent anchor box center point step numbers s _ ds = [8, 16, 32, 64, 100, 300], inputting offset offsets = [0.5,0.5,0.5,0.5,0.5,0.5], inputting boundary code var _ code = [0.1,0.1,0.2,0.2], creating an SSD model M according to inputted parameters M _ c, s _ c, r, a _ r, s _ ds, offsets, var _ code;
s5) loading the training set T to the model M for training;
s6) loading the test set O to the model M for testing;
s7) recording L conf (x, c) is a loss function, L conf (x, c) the formula is:
Figure BDA0003952233850000051
wherein->
Figure BDA0003952233850000052
i denotes the ith anchor box, j denotes the jth input box, <' > H>
Figure BDA0003952233850000053
The ith anchor box is matched with the jth input box with the category p, if the ith anchor box is matched with the jth input box, 1 is taken, and if not, 0 is taken;
s8) inputting the detection factor mu, if L connf (x, c) > mu goes to step S4), and the parameters of the input anchor box factors a _ r and S _ c are adjusted;
and S9) inputting a newly acquired high-precision hardware fitting picture S set to the model M for prejudgment, and outputting a result set R.
In the embodiment, the size of the anchor box when training data is made by using LabelImg in the step S3) is set to 300H 300, and the anchor box is a picture with crack characteristics. The GRB average value parameter m _ c in step S4) is used for calculating a mean value of a reference color range, the anchor box factor parameter S _ c in step S4) is used for configuring an anchor box length-width ratio, the input channel sequence parameter r in step S4) is used for specifying a picture color arrangement sequence, the characteristic factor parameter a _ r in step S4) is used for constraining an anchor box convolution layer vertical-horizontal ratio, the adjacent anchor box center point step number parameter S _ ds in step S4) is used for a scaling factor of an anchor box return primitive, the offset parameter offset in step S4) is used for determining the center point of the anchor box, the boundary coding parameter var _ code in step S4) is used for a scaling ratio of an anchor box offset of each coordinate, and step S8) detects that a factor μ input range is 0.6 to 0.9.
The invention has the beneficial effects that: in the field of image recognition, the problems of complex background, large target scale change, low color contrast and the like are always the biggest challenges in various fields of application. The hardware fittings generally have limited size, no obvious characteristics of self color, various application scenes, extremely small crack size, low crack color contrast and the like, so that the detection difficulty is greatly increased. The method applies the SSD deep learning model, reforms the loss function, regards the background part as a simple sample, reduces the proportion of background loss in confidence loss, enables the model to be converged more quickly and the model to be trained more sufficiently, and improves the target detection precision under the complex background. The hardware detection and feature extraction are realized, the technical defects are effectively overcome, the detection application of the hardware cracks under the complex background is met, and the positive effect is exerted particularly on the detection of the hardware cracks on the power transmission line in practice.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that it is obvious to those skilled in the art that various modifications and improvements can be made without departing from the principle of the present invention, and these modifications and improvements should also be considered as the protection scope of the present invention.

Claims (10)

1. A high-precision hardware crack image detection and feature extraction method under a complex background is characterized by comprising the following steps:
s1) acquiring a high-precision hardware fitting picture data set A;
s2) taking 70% of pictures in A as a training set T and taking 30% of pictures in A as a test set O;
s3) making training data by using LabelImg, and storing the training data in a VOC2007 data format;
s4) the input picture size is 300 × 300, the number of input RGB channels is 3, the input image RGB average value m _ c = [123, 117, 104], the input anchor box factor S _ c = [0.1,0.2,0.37,0.54,0.71,0.88,1.05], the number of input classes is 1, and the input channel order r = [2,1,0]; inputting characteristic factors a _ r = [ [1.0,2.0,0.5], [1.0,2.0,0.5,3.0,1.0], [1.0,2.0,0.5,3.0,1.0], [1.0,2.0,0.5], [1.0,2.0,0.5] ], inputting adjacent anchor box center point step numbers s _ ds = [8, 16, 32, 64, 100, 300], inputting offset offsets = [0.5,0.5,0.5,0.5,0.5,0.5], inputting boundary code var _ code = [0.1,0.1,0.2,0.2], creating an SSD model M according to inputted parameters M _ c, s _ c, r, a _ r, s _ ds, offsets, var _ code;
s5) loading the training set T to the model M for training;
s6) loading the test set O to the model M for testing;
s7) recording L conf (x, c) is a loss function, L conf (x, c) the formula is:
Figure FDA0003952233840000011
wherein
Figure FDA0003952233840000012
i denotes the ith anchor box, j denotes the jth input box,
Figure FDA0003952233840000013
the ith anchor box is matched with the jth input box with the category p, if the ith anchor box is matched with the jth input box, 1 is taken, and if not, 0 is taken;
s8) inputting the detection factor mu, if L conf (x, c) > mu goes to step S4), and the parameters of the input anchor box factors a _ r and S _ c are adjusted;
and S9) inputting a newly acquired high-precision hardware fitting picture S set to the model M for prejudgment, and outputting a result set R.
2. The method for detecting and extracting the hardware crack image with high precision under the complex background according to claim 1, wherein the size of the anchor box is set to 300 x 300 when LabelImg is used for making training data in step S3), and the anchor box is a picture with crack features.
3. The method according to claim 1, wherein the GRB mean parameter m _ c in step S4) is used as a mean value of a reference color range during operation.
4. The method for detecting and extracting the features of the hardware fitting crack image with high precision under the complex background of claim 1, wherein the anchor box factor parameter S _ c in the step S4) is used for configuring the length-width ratio of the anchor box.
5. The method for detecting and extracting the hardware crack image with high precision under the complex background according to claim 1, wherein the input channel sequence parameter r in the step S4) is used for specifying a color arrangement sequence of the pictures.
6. The method for detecting and extracting the features of the hardware crack image with high precision under the complex background of claim 1, wherein the feature factor parameter a _ r in the step S4) is used for constraining the aspect ratio of the anchor box convolution layer.
7. The method for detecting and extracting the features of the hardware fitting crack image with high precision under the complex background of claim 1, wherein the step number parameter S _ ds of the center point of the adjacent anchor box in the step S4) is used as a scaling factor for returning the anchor box to the original shot.
8. The method for detecting and extracting the features of the hardware fitting crack image with high precision in the complex background according to claim 1, wherein the offset parameter offsets in step S4) is used for determining the center point of the anchor box.
9. The method for detecting and extracting the hardware crack image with high precision under the complex background according to claim 1, wherein the boundary coding parameter var _ code in step S4) is used for scaling the anchor box offset of each coordinate.
10. The method for detecting and extracting the hardware crack image with high precision under the complex background according to claim 1, wherein the input range of the detection factor μ in the step S8) is 0.6 to 0.9.
CN202211454186.9A 2022-11-21 2022-11-21 High-precision hardware crack image detection and feature extraction method under complex background Pending CN115841460A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211454186.9A CN115841460A (en) 2022-11-21 2022-11-21 High-precision hardware crack image detection and feature extraction method under complex background

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211454186.9A CN115841460A (en) 2022-11-21 2022-11-21 High-precision hardware crack image detection and feature extraction method under complex background

Publications (1)

Publication Number Publication Date
CN115841460A true CN115841460A (en) 2023-03-24

Family

ID=85575747

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211454186.9A Pending CN115841460A (en) 2022-11-21 2022-11-21 High-precision hardware crack image detection and feature extraction method under complex background

Country Status (1)

Country Link
CN (1) CN115841460A (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109344821A (en) * 2018-08-30 2019-02-15 西安电子科技大学 Small target detecting method based on Fusion Features and deep learning
CN109446925A (en) * 2018-10-08 2019-03-08 中山大学 A kind of electric device maintenance algorithm based on convolutional neural networks
CN110751642A (en) * 2019-10-18 2020-02-04 国网黑龙江省电力有限公司大庆供电公司 Insulator crack detection method and system
CN111735815A (en) * 2020-06-18 2020-10-02 江苏方天电力技术有限公司 Method and device for detecting defects of small hardware fittings of power transmission line and storage medium
CN112070715A (en) * 2020-07-30 2020-12-11 许继集团有限公司 Transmission line small-size hardware defect detection method based on improved SSD model
CN113096098A (en) * 2021-04-14 2021-07-09 大连理工大学 Casting appearance defect detection method based on deep learning
CN114742820A (en) * 2022-05-11 2022-07-12 西南交通大学 Bolt looseness detection method and system based on deep learning and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109344821A (en) * 2018-08-30 2019-02-15 西安电子科技大学 Small target detecting method based on Fusion Features and deep learning
CN109446925A (en) * 2018-10-08 2019-03-08 中山大学 A kind of electric device maintenance algorithm based on convolutional neural networks
CN110751642A (en) * 2019-10-18 2020-02-04 国网黑龙江省电力有限公司大庆供电公司 Insulator crack detection method and system
CN111735815A (en) * 2020-06-18 2020-10-02 江苏方天电力技术有限公司 Method and device for detecting defects of small hardware fittings of power transmission line and storage medium
CN112070715A (en) * 2020-07-30 2020-12-11 许继集团有限公司 Transmission line small-size hardware defect detection method based on improved SSD model
CN113096098A (en) * 2021-04-14 2021-07-09 大连理工大学 Casting appearance defect detection method based on deep learning
CN114742820A (en) * 2022-05-11 2022-07-12 西南交通大学 Bolt looseness detection method and system based on deep learning and storage medium

Similar Documents

Publication Publication Date Title
WO2019104767A1 (en) Fabric defect detection method based on deep convolutional neural network and visual saliency
CN107194937B (en) Traditional Chinese medicine tongue picture image segmentation method in open environment
CN112651968B (en) Wood board deformation and pit detection method based on depth information
CN109035273B (en) Image signal fast segmentation method of immunochromatography test paper card
CN113592861A (en) Bridge crack detection method based on dynamic threshold
CN111652213A (en) Ship water gauge reading identification method based on deep learning
CN111127360B (en) Gray image transfer learning method based on automatic encoder
CN110866915A (en) Circular inkstone quality detection method based on metric learning
CN116758077A (en) Online detection method and system for surface flatness of surfboard
CN117218029B (en) Night dim light image intelligent processing method based on neural network
CN107909085A (en) A kind of characteristics of image Angular Point Extracting Method based on Harris operators
CN115639248A (en) System and method for detecting quality of building outer wall
CN112215303B (en) Image understanding method and system based on self-learning attribute
CN117541574A (en) Tongue diagnosis detection method based on AI semantic segmentation and image recognition
CN116189194B (en) Drawing enhancement segmentation method for engineering modeling
CN115841460A (en) High-precision hardware crack image detection and feature extraction method under complex background
CN111462084A (en) Image vectorization printing bleeding point prediction system and method based on random forest
CN116051808A (en) YOLOv 5-based lightweight part identification and positioning method
CN115482207A (en) Bolt looseness detection method and system
CN114659453A (en) Method and system for detecting paint film thickness of enameled wire
CN113834447A (en) High-dynamic laser light bar self-adaptive imaging processing method under outdoor complex environment
CN111968136A (en) Coal rock microscopic image analysis method and analysis system
Chen A PCB Image Self-adaption Threshold Segmentation Method Fusing Color Information and OTSU Theory
CN116091818B (en) Pointer type instrument reading identification method based on multi-neural network cascading model
CN114863095B (en) Answer sheet image segmentation method based on color conversion

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
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20230324