# Deep Learning Algorithm for Automatic Classification of Power Quality Disturbances
## 4 Results and Discussion
### Quantitative Evaluation
\begin{table}
\begin{tabular}{l c c c c c} \hline  & **No Noise** & **20 dB** & **30 dB** & **40 dB** & **50 dB** \\ \hline Flicker & 81.425 & 84.123 & 84.89 & 87.890 & 86.345 \\ Harmonics & 83.124 & 86.456 & 86.001 & 85.678 & 83.890 \\ Impulsive transient & 80.750 & 85.678 & 83.789 & 84.234 & 87.456 \\ Interruption & 84.250 & 83.901 & 87.654 & 86.012 & 85.234 \\ Normal & 81.741 & 87.234 & 85.012 & 82.345 & 84.89 \\ Notch & 82.499 & 84.567 & 84.321 & 88.789 & 86.789 \\ Oscillatory transient & 79.374 & 86.789 & 86.543 & 83.456 & 82.567 \\ Sag & 84.578 & 85.345 & 82.789 & 87.123 & 88.012 \\ Spike & 80.759 & 82.456 & 88.456 & 85.89 & 83.678 \\ Swell & 81.574 & 88.123 & 83.210 & 84.678 & 87.210 \\ \hline \end{tabular}
\end{table} 
Table 12: Detailed accuracy of the proposed method. Figure 4 presents a comprehensive bar chart illustrating the detailed accuracy of the proposed approach and the state-of-the-art methods. This visual representation allows for an easy comparison of the performance metrics across these approaches, highlighting the strengths and weaknesses of each model in terms of classification accuracy. By examining the bar chart, viewers can quickly discern how the proposed method stands out in achieving superior accuracy compared with its counterparts, thereby emphasizing its effectiveness in addressing classification challenges. Table 17 provides a comprehensive overview of the average accuracy achieved by the proposed CNN and other state-of-the-art methods. It presents a quantitative measure of how well each method performs in accurately classifying the test data. On the other hand, Figure 5 visually represents the testing accuracy levels of the proposed CNN and state-of-the-art methods. This graphical representation enables a more intuitive understanding of the performance comparison. By examining both the table and the figure, the proposed CNN performs well compared with the existing state-of-the-art methods in terms of testing accuracy. \begin{table}
\begin{tabular}{l c c c c c} \hline \hline  & **No Noise** & **20 dB** & **30 dB** & **40 dB** & **50 dB** \\ \hline Flicker & 83.054 & 85.805 & 86.588 & 89.648 & 88.072 \\ Harmonics & 84.786 & 88.185 & 87.721 & 87.392 & 85.568 \\ Impulsive transient & 82.365 & 87.392 & 85.465 & 85.919 & 89.205 \\ Interruption & 85.935 & 85.588 & 89.407 & 87.732 & 86.939 \\ Normal & 83.376 & 88.979 & 86.712 & 83.992 & 86.588 \\ Notch & 84.149 & 86.258 & 86.007 & 90.565 & 88.525 \\ Oscillatory transient & 80.961 & 88.525 & 88.274 & 85.125 & 84.218 \\ Sag & 86.270 & 87.052 & 84.445 & 88.865 & 89.772 \\ Spike & 82.374 & 84.105 & 90.225 & 87.608 & 85.352 \\ Swell & 83.205 & 89.885 & 84.874 & 86.372 & 88.954 \\ \hline \hline \end{tabular}
\end{table} 
Table 16: Detailed accuracy of the GRU method. Figure 4: Detailed accuracy of the proposed method compared with the state-of-the-art methods [7]. The proposed model achieved an accuracy of up to 99.49%, significantly outperforming traditional methods and even some existing models. This demonstrates the effectiveness of leveraging multi-scale CNNs combined with attention mechanisms to capture complex patterns in PQ signals. The integration of attention mechanisms allows the model to focus on the most relevant features of the input data, enhancing its ability to discern subtle variations in power quality disturbances. This can lead to more reliable classifications, especially in noisy environments. By improving the accuracy and efficiency of PQ analysis, the proposed approach has significant implications for real-world applications. Enhanced classification can lead to better monitoring and maintenance of power systems, ultimately contributing to increased reliability and stability of electrical grids. Moreover, future research could explore the model's scalability and its performance in real-time applications, where rapid and accurate classification of PQ disturbances is crucial.