A substation equipment infrared heat defect identification method based on YOLO_V5
By using an infrared heating defect identification method based on YOLO_V5, the problem of efficient identification of local heating defects in electrical equipment in substations was solved, enabling real-time monitoring and intelligent diagnosis of substation equipment and improving the safety and reliability of the power grid.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GUILIN UNIV OF ELECTRONIC TECH
- Filing Date
- 2026-04-29
- Publication Date
- 2026-07-17
Smart Images

Figure CN122415992A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of smart grid visual monitoring and safety management technology, specifically relating to a method for electrical equipment target detection based on computer vision and machine learning. This method can efficiently and accurately identify and monitor localized heating defects in indoor and outdoor electrical equipment in substations, enabling intelligent inspection and real-time management of the operating status of power grid equipment, effectively improving the safety, reliability, and stability of the power system. Background Technology
[0002] In the demanding power environment, to ensure the health and safety of every piece of equipment in a substation, power grid companies have established strict infrared inspection procedures, which clearly stipulate that infrared temperature measurements must be performed regularly on equipment such as disconnect switches and bushings. However, in the complex environment of a substation, due to the large number of devices and the inherent subjectivity of manual diagram interpretation, sometimes hot spots are missed or defects are misjudged. In such cases, a significant amount of manpower is often required for verification to ensure the absolute safety of the power grid. Considering the dual requirements of inspection efficiency and identification accuracy, we have innovatively developed an infrared heating intelligent detection system based on target recognition. This system can monitor and accurately identify the thermal field characteristics of substation equipment in real time. Once abnormal temperature rise or obvious hot spots are detected, the system will immediately calculate the temperature rise and issue a classification alert, thereby arranging timely maintenance and ensuring that power grid safety standards are strictly enforced. Summary of the Invention
[0003] To address the aforementioned issues, this invention proposes a method for identifying infrared heating defects in substation equipment based on YOLO_V5, enabling real-time monitoring and intelligent diagnosis of equipment status.
[0004] A method for identifying infrared heating defects in substation equipment based on YOLO_V5, characterized by comprising:
[0005] S1. Initialize system parameters to ensure the system is in optimal condition. Next, configure the infrared thermal imaging sensor parameters of the dual-light camera, including emissivity correction and ambient temperature compensation, to ensure the captured image quality meets the requirements of subsequent processing;
[0006] S2. After receiving the infrared image, the system performs a series of preprocessing operations. These operations include adjusting the image size to a standard 640x640 pixels and normalizing the image data to improve the efficiency and accuracy of subsequent processing;
[0007] S3. The preprocessed images are then fed into the pre-trained Power_Defect.pt model. This model has been trained on a large amount of power infrared data and is capable of accurately identifying the main body of substation equipment and infrared heating defect characteristics;
[0008] S4. In the Power_Defect.pt model, a pre-trained convolutional neural network is used to extract features from the input image. These features will be used for subsequent object classification and coordinate regression tasks;
[0009] S5. Based on feature extraction, the system scans the feature map using predefined prior boxes. For each prior box, the system performs target classification and coordinate regression to determine the presence of the main body of the device and heat-generating defects, as well as their location and size.
[0010] S6. To remove redundant predictions, the system uses a loss function and a non-maximum suppression algorithm to merge overlapping prediction boxes. This step ensures that the final output predictions are both accurate and concise.
[0011] S7. Based on the location of the main body of the equipment and the location of the heat-generating defect point obtained in step S5, the system extracts the highest temperature and reference point temperature of the corresponding area, calculates the relative temperature rise, and automatically determines the defect level according to the power specifications;
[0012] S8. Based on the image processed in step S2 and the position and size information obtained in step S5, the system draws rectangular boxes at corresponding positions in the image to mark the main body of the equipment and the hot spot, and displays and saves the relative temperature rise and defect level in the upper left corner of the image;
[0013] S9. The system outputs the detection results. These results include the predicted category, confidence level, and bounding box location. This information will be presented to the user in an appropriate manner or used for subsequent data analysis and processing. When the next frame is received, the system returns to step S2 for a new round of image processing. This process will continue to achieve continuous monitoring.
[0014] Furthermore, the camera in S1 is used for real-time monitoring and transmits real-time data to a computer.
[0015] Furthermore, the Power_Defect.pt model in step S3 needs to collect infrared defect datasets for the substation environment, including classifying and iteratively training the normal state, general overheating, severe overheating and critical state of various electrical equipment.
[0016] Furthermore, the preprocessing for training Power_Defect.pt in S3 employs Mosaic data augmentation. This method is particularly effective for small-sized objects. Mosaic data augmentation is achieved by randomly padding with four samples and then blending them with scaling and cropping.
[0017] Furthermore, the method for evaluating the loss function and suppressing nonmaximum values in S6 is specifically as follows:
[0018]
[0019]
[0020] in This represents the square of the Euclidean distance between the center points of the predicted bounding box and the ground truth bounding box. Let be the length of the diagonal of the minimum bounding rectangle region C. A parameter used to measure whether the aspect ratio is consistent. This is the weighting function.
[0021] Furthermore, the output of S9 is the detection result. The result includes the predicted category: indicating the type of device located or the level of thermal defect; the confidence level: indicating the reliability of the prediction result; and the bounding box position: indicating the location of the target category in the image.
[0022] This invention uses YOLOv5s.pt, a high-speed detection platform, to construct a detection network. This addresses the need for rapid detection of densely packed equipment during substation inspections. By real-time monitoring and accurate identification of the infrared thermal field characteristics of substation equipment, the system immediately calculates the temperature rise and issues an alert upon detecting equipment with overheating defects, enabling timely repairs and ensuring strict adherence to power grid protection standards. Attached Figure Description
[0023] Figure 1 This is a schematic diagram of the method and hardware configuration of the present invention;
[0024] Figure 2 This is a flowchart of the infrared heating defect identification program for substation equipment according to the present invention;
[0025] Figure 3 This is the training and validation implementation scheme for the core recognition model Power_Defect.pt of this invention; Detailed Implementation
[0026] To make the above features and application scenarios of the present invention clearer and easier to understand, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0027] Example 1.
[0028] like Figure 1 The diagram shown illustrates the method and hardware configuration of this invention. This embodiment provides a method for identifying infrared heating defects in substation equipment based on YOLO_V5, the hardware of which includes a computer and a dual-light infrared camera (or a camera pan-tilt unit mounted on an inspection robot).
[0029] The camera is used for:
[0030] The real-time infrared images and temperature flow data of the substation are transmitted to the computer.
[0031] The computer is used for:
[0032] The video stream obtained from the camera is analyzed and processed to obtain the predicted category, confidence level, temperature data, and box position.
[0033] Example 2.
[0034] like Figure 2 The diagram shows the flowchart of the infrared heating defect identification program for substation equipment according to the method of the present invention. This invention uses the YOLOv5 algorithm to collect and identify the infrared hotspot features of the equipment. PyQT5 is used as the software interface. It can identify the main body of the equipment and heating defect information in the video, and the final results are displayed on the program interface.
[0035] First, the system parameters are initialized to ensure the system is in optimal condition. Next, the parameters of the infrared thermal imaging sensor of the dual-light camera are configured, including emissivity correction and ambient temperature compensation, to ensure the captured image quality meets the requirements of subsequent processing.
[0036] After receiving the infrared image, the system performs a series of preprocessing operations. These operations include resizing the image to a standard 640x640 pixels and normalizing the image data to improve the efficiency and accuracy of subsequent processing.
[0037] The pre-processed images are then fed into the pre-trained Power_Defect.pt model. This model has been trained on a large amount of power infrared data and is capable of accurately identifying the main body of substation equipment and infrared heating defect features.
[0038] In the Power_Defect.pt model, a pre-trained convolutional neural network is used to extract features from the input image. These features will be used for subsequent object classification and coordinate regression tasks.
[0039] Based on feature extraction, the system scans the feature map using predefined prior bounding boxes. For each prior bounding box, the system performs target classification and coordinate regression to determine the presence of the main body of the device and heat-generating defects, as well as their location and size.
[0040] To remove redundant predictions, the system uses a loss function and a non-maximum suppression algorithm to merge overlapping prediction boxes. This step ensures that the final output predictions are both accurate and concise.
[0041] Based on the location of the main body of the equipment and the location of the heat-generating defect point obtained in step S5, the system extracts the highest temperature and reference point temperature of the corresponding area, calculates the relative temperature rise, and automatically determines the defect level according to the power specifications.
[0042] Based on the image processed in step S2 and the position and size information obtained in step S5, the system draws rectangular boxes in the corresponding positions in the image to mark the main body of the equipment and the hot spot, and displays and saves the relative temperature rise and defect level in the upper left corner of the image.
[0043] Finally, the system outputs the detection results. These results include the predicted category, confidence score, and bounding box location. When the next frame is received, the system returns to step S2 for a new round of image processing. This process continues to achieve continuous video stream processing.
[0044] Example 3.
[0045] like Figure 3 As shown, this embodiment aims to elaborate on the specific generation process of the power-specific identification model Power_Defect.pt described in claim 3 of the present invention. This process follows the standard deep learning model development paradigm and is optimized for the characteristics of substation infrared images, ultimately producing a specialized model that meets the accuracy requirements of industrial inspection. The specific steps are as follows:
[0046] Phase 1: Data Preparation Phase
[0047] 1. Collect raw infrared defect image dataset for substations: First, collect approximately 20,000 infrared thermal images from the power company's historical inspection database, condition-based maintenance records, and simulated fault experiments. These images cover different voltage levels, equipment types (such as disconnect switches, current transformers, main transformer bushings, etc.), weather conditions (sunny, cloudy, nighttime), and seasons. Using professional annotation software (such as LabelImg), accurately label the "equipment body" and "heat spots" in the images with rectangular bounding boxes, generating label files that correspond one-to-one with the images.
[0048] 2. Mosaic Data Augmentation: To achieve the technical solution described in claim 4, the system employs Mosaic data augmentation technology before feeding the data into the training network. This technology randomly selects four labeled training images and stitches them together into a new training image through random scaling, cropping, and arrangement. This processing method greatly enriches the background information of the dataset and enables the model to learn target features at multiple different scales simultaneously in a batch, significantly improving the model's robustness in detecting small targets (such as fine hotspots) and partially occluded targets.
[0049] Phase Two: Model Training Phase
[0050] 3. Loading Pre-trained Base Weights: To accelerate model convergence and improve final performance, this embodiment employs a transfer learning strategy. First, pre-trained YOLOv5s model weights (YOLOV5s-6.pt) on a large, general-purpose image dataset (such as COCO) are loaded. These pre-trained weights already possess powerful basic image feature extraction capabilities.
[0051] 4. Feature Extraction and Loss Calculation: Images after data augmentation are batch-input into the YOLOv5s network. The network extracts deep features through its backbone and neck networks. In the core stage of model training, the CIoU (Complete Intersection over Union) loss function described in claim 5 is used for optimized regression. Compared to traditional IoU loss, CIoU additionally considers the distance between the center points of the predicted and ground truth boxes, as well as the consistency of aspect ratio. This allows the model to converge faster and more stably during training, especially for slender equipment and irregularly shaped hot spots commonly found in substations, resulting in higher localization accuracy.
[0052] 5. Generate a Power-Specific Identification Model: After approximately 300 iterations of training, the model's weight parameters are continuously optimized based on the backpropagation gradient of the CIoU loss function until the loss value converges on the validation set. At this point, the final trained model weight file is saved and named Power_Defect.pt. This model has deeply learned and solidified the contour features and specific patterns of thermal defects of various equipment in substation infrared images.
[0053] Phase 3: Verification and Evaluation Phase
[0054] 6. Inference using the validation set: Unused validation set images from the training phase are input into the generated Power_Defect.pt model for inference. The model outputs a predicted bounding box with a confidence score for each potential target in the image. To eliminate multiple overlapping predictions of the same target, the system employs a non-maximum suppression (NMS) algorithm, selecting and retaining the optimal predicted bounding box based on its confidence score. This step corresponds to a partial implementation of claim 6.
[0055] 7. Output Performance Evaluation Curves: The prediction results filtered by NMS are compared with the true labels on the validation set, and a series of key performance evaluation metrics are calculated and output, including precision, recall, and F1 score. By plotting the PR curves, the overall performance of the model at different confidence thresholds can be intuitively evaluated.
[0056] 8. Final classification results: After comprehensive evaluation, the Power_Defect.pt model generated in this embodiment achieved an average precision (mAP@0.5) of 93.7% on the test set, and a recall rate of over 98% for hot spot defects of "severe" level and above. Its performance indicators fully meet the requirements for accuracy and reliability of automatic identification in industrial inspection, proving the effectiveness and practicality of the method of this invention.
[0057] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A method for identifying infrared heating defects in substation equipment based on YOLO_V5, characterized in that, Includes the following steps: S1. Initialize system parameters to ensure the system is in optimal condition. Next, configure the infrared thermal imaging sensor parameters of the dual-light camera, including emissivity correction and ambient temperature compensation, to ensure the captured image quality meets the requirements of subsequent processing; S2. After receiving the infrared image, the system performs a series of preprocessing operations. These operations include adjusting the image size to a standard 640x640 pixels and normalizing the image data to improve the efficiency and accuracy of subsequent processing; S3. The preprocessed image is then transmitted to the pre-trained Power_Defect.pt model. This model has been trained on a large amount of power infrared data and has the ability to accurately identify the main body of substation equipment and infrared heating defect characteristics; S4. In the Power_Defect.pt model, a pre-trained convolutional neural network is used to extract features from the input image. These features will be used for subsequent object classification and coordinate regression tasks; S5. Based on feature extraction, the system scans the feature map using predefined prior boxes. For each prior box, the system performs target classification and coordinate regression to determine the presence of the main body of the device and heat-generating defects, as well as their location and size. S6. To remove redundant prediction results, the system uses a loss function and a non-maximum suppression algorithm to merge overlapping prediction boxes. This step ensures that the final output prediction results are both accurate and concise. S7. Based on the location of the main body of the equipment and the heat-generating defect point obtained in step S5, the system extracts the highest temperature and reference point temperature of the corresponding area, calculates the relative temperature rise, and automatically determines the defect level according to the power specifications; S8. Based on the image processed in step S2 and the position and size information obtained in step S5, the system draws rectangular boxes at corresponding positions in the image to mark the main body of the equipment and the hot spot, and displays and saves the relative temperature rise and defect level in the upper left corner of the image; S9. The system outputs the detection results. These results include the predicted category, confidence level, and bounding box location. This information will be displayed to the user in an appropriate manner or used for subsequent data analysis and processing. When the next frame is received, the system returns to step S2 for a new round of image processing. This process will continue in order to achieve continuous monitoring.
2. The method according to claim 1, characterized in that, The camera in S1 is used for real-time monitoring and transmits real-time data to the computer.
3. The method according to claim 1, characterized in that, The Power_Defect.pt file for S3 requires dataset collection, class labeling, and model training.
4. The method according to claim 1, characterized in that, The preprocessing for training Power_Defect.pt in S3 employs Mosaic data augmentation. This method is particularly effective for small objects. Mosaic is filled with 4 samples randomly, and the Mosaic data augmentation is mixed with scaling and cropping.
5. The method according to claim 1, characterized in that, The loss function and nonmaximum suppression method of S6 are as follows: Given two predicted bounding boxes A and B of arbitrary properties, find a minimum closed shape C such that C contains both A and B. Then calculate the area of C that does not cover A or B, divide the area of C by the total area, and sum the results. The ratio of the subtraction. Therefore, This can be represented as the core formula: in This represents the square of the Euclidean distance between the center points of the predicted bounding box and the ground truth bounding box. Let be the length of the diagonal of the minimum bounding rectangle region C. A parameter used to measure whether the aspect ratio is consistent. This is the weighting function.
6. The method according to claim 1, characterized in that, The output of S9 is the detection result. The result includes the predicted category: indicating the type of device located or the level of thermal defect; the confidence level: indicating the reliability of the prediction result; and the bounding box position: indicating the location of the target category in the image.