# Real-Time Detection of Insulator Defects with Channel Pruning and Channel Distillation
## 4 Experiment and Results
### Experiment Results and Analysis  
As shown in Table 5, after channel distillation, the resulting distilled model (OD-YOLOv7-tiny), has a parameter size of 2.8 M, which represents a 53% reduction compared to the original YOLOv7-tiny model. In terms of model speed, the inference speed of the original YOLOv7-tiny model was 1.25 ms, whereas the final OD-YOLOv7-tiny model achieved an inference speed of 0.78 ms, marking an improvement of 37.6% and significantly enhancing the speed. Regarding accuracy, the OD-YOLOv7-tiny model shows improvements in precision (P), recall (R), [EMAIL_ADDRESS], and [EMAIL_ADDRESS]:0.95 by 3.9%, 5.3%, 2.2%, and 0.3%, respectively, compared to the original YOLOv7-tiny model. These enhancements in both model size and speed were achieved without compromising accuracy. Figure 19 illustrates the [EMAIL_ADDRESS] and [EMAIL_ADDRESS]:0.95 throughout the training process for various networks, where the improved model refers to the enhanced network, the pruned model to the network after channel pruning, and the distilled model to the network after channel distillation, which is the final network, OD-YOLOv7-tiny.  
As shown in Figure 19, the detection performance of the four models on the same type of image indicates that the model with network improvements performs the best. The accuracy of the model after channel pruning decreases; however, the detection capability of the model OD-YOLOv7-tiny, which underwent channel distillation, surpasses that of the original YOLOv7-tiny model. By reducing the model size and enhancing its speed, our proposed method can be effectively deployed on small edge devices. This allows for the  
Figure 19: The [EMAIL_ADDRESS] throughout the training process for various networks.  
\begin{table}
\begin{tabular}{c c c c c c c} \hline \hline
**Network** & **P** & **R** & **[EMAIL_ADDRESS]** & **[EMAIL_ADDRESS]** & **Parameter** & **GFLOPs** & **Inference Time** \\  & & & & & & **Size (M)** & **(Batch Size 32)** \\ \hline YOLOv7-tiny & 71.6\% & 56.0\% & 62.4\% & 28.1\% & 6.1 & 13.0 & 1.25 ms \\ Improved model & 78.4\% & 65.4\% & 71.2\% & 32.8\% & 5.5 & 10.7 & 1.31 ms \\ Pruned model & 73.3\% & 58.5\% & 64.6\% & 28.0\% & 2.8 & 5.3 & 0.78 ms \\ Distilled model & 75.5\% & 61.3\% & 66.3\% & 28.4\% & 2.8 & 5.3 & 0.78 ms \\ \hline \hline \end{tabular}
\end{table}
Table 5: The parameters and detection results of the progressively optimized model.  
real-time detection of insulator defects in power transmission lines, meeting the application requirements for rapid response handling. Figure 20a,b, respectively, display the heatmaps for our model's detection of damaged insulator damage and insulator flashover. Through these heatmaps, we can identify which areas in the feature maps exhibit higher activation values. This enables us to comprehend the model's focus on various features and offers a more intuitive understanding of its attention to different regions.  
In order to directly test the detection outcomes of the improved OD-YOLOv7-tiny, we randomly selected several images from the test set of our insulator defect dataset, which contained various defects for detection, and conducted a visual comparison with YOLOv7-tiny. Figure 21 illustrates the detection performance of both models in different scenarios. It is evident that the improved OD-YOLOv7-tiny exhibits superior detection capabilities compared to the original YOLOv7-tiny.  
Figure 21: The detection performance of both models in different scenarios.  
Figure 20: The heatmaps for our model’s detection of damaged insulator damage and insulator flashover.