Search

CN-115374835-B - Composite insulator thermal defect classification method and system based on random forest algorithm

CN115374835BCN 115374835 BCN115374835 BCN 115374835BCN-115374835-B

Abstract

The invention discloses a composite insulator thermal defect classification method and a system based on a random forest algorithm, which are characterized in that the temperature curves are obtained by extracting the central axis temperatures of the surfaces of composite insulators with different thermal defect types, the temperature curves are analyzed and processed, the temperature characteristic quantities of the composite insulators with different thermal defect types are obtained by calculation, the random forest algorithm is constructed by using Python software to establish a composite insulator thermal defect classification model, and the composite insulator thermal defect types are classified by using the classification model.

Inventors

  • LI TE
  • WANG SHAOHUA
  • MEI BINGXIAO
  • ZHAO LUMIN
  • XU XING
  • JIANG KAIHUA
  • CAO JUNPING
  • WANG ZHENGUO
  • TAO RUIXIANG
  • HU QIN
  • JIANG XINGLIANG
  • LIU LI

Assignees

  • 国网浙江省电力有限公司电力科学研究院

Dates

Publication Date
20260512
Application Date
20220608

Claims (7)

  1. 1. A composite insulator thermal defect classification method based on a random forest algorithm is characterized by comprising the following steps: S1, extracting central axis temperature data of the surfaces of composite insulators with different thermal defect types to obtain a temperature curve, wherein the thermal defect types of the composite insulators comprise three types of core rod decay, surface dirt accumulation and sheath aging and moisture absorption; s2, carrying out mathematical analysis on the central axis temperature curves of the surfaces of the composite insulators with different thermal defect types, and calculating the temperature characteristic quantities of the composite insulators with different thermal defect types to form a temperature characteristic quantity sample set; s3, adopting an SMOTE algorithm to amplify temperature characteristic quantity samples of the core rod decayed composite insulator to the number of composite insulators with surface dirt accumulation and sheath aging and damp; s4, constructing a random forest algorithm by using RandomForestClassifier in sklearn libraries in Python software, and establishing a composite insulator thermal defect classification model; S5, adopting ten-fold cross verification composite insulator thermal defect classification models, calculating classification effect evaluation values of each thermal defect type in each model, and selecting an optimal composite insulator thermal defect classification model according to the effect evaluation values; S6, classifying the thermal defect types of the composite insulator to be classified by using the obtained optimal composite insulator thermal defect classification model.
  2. 2. The method for classifying thermal defects of composite insulators based on random forest algorithm according to claim 1, wherein the step S2 specifically comprises the following steps: Seven temperature characteristic quantities are extracted, wherein the seven temperature characteristic quantities are respectively temperature difference, temperature standard deviation, peak number, heating length ratio, peak standard deviation, temperature maximum value relative position and peak value position standard deviation.
  3. 3. The method for classifying thermal defects of composite insulators based on random forest algorithm according to claim 1, wherein the step S3 specifically comprises the following steps: s31 for each sample in the core rod decay composite insulator Calculating k nearest neighbors by taking Euclidean distance as a standard; S32, randomly selecting a sample from k neighbor And is in contact with Obtaining a new sample according to the following formula ; S33, determining sampling multiplying power according to the unbalance degree of the temperature characteristic quantity sample set; S34, adding the amplified data to a temperature characteristic quantity sample set, and performing labeling treatment on the data in the sample set.
  4. 4. The method for classifying thermal defects of composite insulators based on random forest algorithm according to claim 1, wherein the construction of the random forest algorithm in step S4 specifically comprises the following steps: s41, randomly selecting 80% temperature characteristic values from temperature characteristic value sample sets of composite insulators of different thermal defect types by using a Bootstrap method, and constructing m training sets; S42, randomly selecting 80% of temperature characteristic quantity in each training set, and modeling decision trees of each training set by using a CART algorithm to obtain m decision trees; s43, testing each decision tree by using a test set to obtain m thermal defect type classification results of the composite insulator; S44, voting to determine the thermal defect type of the composite insulator by adopting a few principles obeying majority for the m thermal defect classification results.
  5. 5. The method for classifying thermal defects of a composite insulator based on a random forest algorithm according to claim 1, wherein the step S5 is characterized by calculating an effect evaluation value of a thermal defect classification model of the composite insulator, and specifically comprises the following steps: the classification results are displayed by using a confusion matrix, the accuracy rate, recall rate and F1 measure of each classification model for the classification results of the composite insulators of different thermal defect types are calculated according to the results, and the classification model with the highest average value of the F1 measure is selected as the optimal composite insulator thermal defect classification model, wherein: the accuracy represents the ratio of the predicted positive and actually positive sample size to the predicted positive sample size: TP represents the sample size predicted to be positive and actually positive, FP represents the sample size predicted to be positive and actually negative, precision represents the accuracy rate; recall represents the ratio of the predicted and actually positive sample size to the total actually positive sample size: wherein FN represents the sample size predicted to be negative and actually positive; f1 measure is a weighted harmonic mean of accuracy and recall: 。
  6. 6. The method for classifying thermal defects of composite insulators based on random forest algorithm according to claim 1, wherein the step S6 specifically comprises: S61, extracting the temperature of the central axis of the surface of the composite insulator to be classified, and obtaining a temperature curve; S62, analyzing a temperature curve, and calculating the temperature characteristic quantity of the composite insulator to be classified; S63, inputting the temperature characteristic quantity of the composite insulator to be classified into an optimal composite insulator thermal defect classification model to obtain a plurality of classification results; S64, adopting a rule of minority compliance to a plurality of obtained classification results, and voting to determine the type of the thermal defect of the composite insulator to be classified.
  7. 7. A composite insulator thermal defect classification system based on a random forest algorithm is characterized by comprising a temperature acquisition unit, a temperature characteristic quantity acquisition unit, a random forest classification model unit and a result output unit, wherein the temperature acquisition unit, the temperature characteristic quantity acquisition unit, the random forest classification model unit and the result output unit are sequentially connected, and the system comprises the following components: The temperature acquisition unit is used for acquiring a temperature curve of the central axis of the surface of the composite insulator to be classified, and the output end of the temperature acquisition unit is connected with the input end of the temperature characteristic quantity acquisition unit; the temperature characteristic quantity acquisition unit is used for acquiring the temperature characteristic quantity of the composite insulator to be classified, and the output end of the temperature characteristic quantity acquisition unit is connected with the input end of the random forest classification model unit; the random forest classification model unit is used for testing the temperature characteristic quantity to obtain a plurality of test results, and the output end of the random forest classification model unit is connected with the input end of the result display unit; And the result output unit is used for processing a plurality of classification results obtained by the classification model, and determining the thermal defect type of the composite insulator to be classified by voting by adopting a rule of minority compliance and majority compliance.

Description

Composite insulator thermal defect classification method and system based on random forest algorithm Technical Field The invention relates to the field of defect detection of high-voltage composite insulators, in particular to a composite insulator thermal defect classification method and system based on a random forest algorithm. Background The composite insulator has excellent anti-pollution flashover performance and smaller weight, is beneficial to controlling the construction cost of the transmission line and is widely applied to the transmission lines at home and abroad. The composite insulator has broken string and internal breakdown fault during operation, which threatens the safe operation of the circuit. The sheath aging damp composite insulator hardly generates heat under the low-humidity condition, the heating amplitude is smaller under the high-humidity condition, and the temperature measurement is kept in a follow-up manner. The surface dirt-accumulating composite insulator can be cleaned or replaced according to the heating degree. The decayed core rod may cause a break accident in the composite insulator, once it is found that it must be replaced immediately. The indiscriminate replacement of the heating composite insulator can bring a great deal of waste of manpower and material resources, so that the searching of the temperature characteristics of the composite insulators with different heat defect types is particularly important. At present, the artificial qualitative analysis of the infrared thermal image is an important means for finding the early internal defects of the composite insulator, but is greatly influenced by artificial subjective factors, and has lower efficiency and accuracy. Disclosure of Invention In view of the above, the method and the system for classifying the thermal defects of the composite insulator based on the random forest algorithm can efficiently and accurately classify the composite insulators with different thermal defect types by utilizing the temperature characteristics. The invention provides a composite insulator thermal defect classification method based on a random forest algorithm, which comprises the following steps: S1, extracting central axis temperature data of the surfaces of composite insulators with different thermal defect types to obtain a temperature curve; s2, carrying out mathematical analysis on the central axis temperature curves of the surfaces of the composite insulators with different thermal defect types, and calculating the temperature characteristic quantities of the composite insulators with different thermal defect types to form a temperature characteristic quantity sample set; s3, adopting an SMOTE algorithm to amplify temperature characteristic quantity samples of the core rod decayed composite insulator to the number of composite insulators with surface dirt accumulation and sheath aging and damp; S4, constructing a random forest algorithm by using RandomForestClassifier in sklearn libraries in Python software, and establishing a composite insulator thermal defect classification model; S5, adopting ten-fold cross verification composite insulator thermal defect classification models, calculating classification effect evaluation values of each thermal defect type in each model, and selecting an optimal composite insulator thermal defect classification model according to the effect evaluation values; S6, classifying the thermal defect types of the composite insulator to be classified by using the obtained optimal composite insulator thermal defect classification model. Further, the step S1 specifically includes: The thermal defect types of the composite insulator comprise three types of core rod decay, surface dirt accumulation and sheath aging and humidifying; And extracting the temperature data of the central axis of the surface of the composite insulator, wherein the extraction direction is from a high-voltage end to a low-voltage end, and the derived temperature curve is a series of discrete points along the central axis of the surface of the composite insulator. Further, the step S2 specifically includes: Seven temperature characteristic quantities are extracted, wherein the seven temperature characteristic quantities are respectively temperature difference, temperature standard deviation, peak number, heating length ratio, peak standard deviation, temperature maximum value relative position and peak value position standard deviation. Further, the step S3 specifically includes: s31, calculating k nearest neighbors by taking Euclidean distance as a standard for each sample x in the core rod decayed composite insulator; S32, randomly selecting a sample x n from the k nearest neighbor, and obtaining a new sample x new with the original sample x according to the following formula; xnew=x+rand(0,1)·(xn-x) s33, determining sampling multiplying power according to the unbalance degree of the temperature characteristic quantity sample