Next Article in Journal
Best Practice Forever? Dynamics behind the Perception of Farm-Fed Anaerobic Digestion Plants in Rural Peripheries
Next Article in Special Issue
Intelligent Controlled DSTATCOM for Power Quality Enhancement
Previous Article in Journal
Effects of the Operating Parameters of Supersonic Separators on the Supersonic Liquefaction Characteristics of Natural Gas
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Regulated Two-Dimensional Deep Convolutional Neural Network-Based Power Quality Classifier for Microgrid

1
Department of Electrical Engineering, National Central University, Taoyuan 320, Taiwan
2
Department of Information and Technology, Immanuel Christian University, Yogyakarta 55571, Indonesia
3
Department of Computer Science and Information Engineering, Asia University, Taichung 413, Taiwan
4
Metal Industries Research and Development Centre, Taichung 407, Taiwan
*
Author to whom correspondence should be addressed.
Energies 2022, 15(7), 2532; https://doi.org/10.3390/en15072532
Submission received: 12 March 2022 / Revised: 25 March 2022 / Accepted: 27 March 2022 / Published: 30 March 2022

Abstract

:
Due to the penetration of renewable energy and load variation in the microgrid, the diagnosis of power quality disturbances (PQD) is important to the operation stability and safety of the microgrid system. Once the power imbalance is present between the generation and the load demand, the fundamental frequency would deviate from the nominal value. As a result, the performance of the power quality classifier based on the neural network would be deteriorated since the deviation of fundamental frequency is not taken into account. In this paper, the regulated two-dimensional (2D) deep convolutional neural network (CNN)-based approach for PQD classification is proposed. In the data preprocessing stage, the IEC-based synchronizer is introduced to detect the deviation of fundamental frequency. In this way, the 2D grayscale image serving as the input of the deep CNN classifier can be accurately regulated. The obtained 2D image can effectively preserve information and waveform characteristics of the PQD signal. The experiment is implemented with datasets containing 14 different categories of PQD. According to this result, it is revealed that the regulated 2D deep CNN can improve the effectiveness of PQD classification in a real-time manner. Furthermore, the proposed method outperforms the methods in previous studies according to the field verification.

1. Introduction

With the high penetration of renewable energy and widespread usage of power-electronic loads, the operation stability of the microgrid would be deteriorated due to the power quality disturbances (PQD). For the grid-connected mode, the voltage-type PQD of the power grid would interfere with the operation of the microgrid [1]. The current-type PQD is significant to the microgrid in the islanded mode due to the nonlinear loads in the power system [2]. The emergence of PQD would lead to the malfunction or inefficiency of electricity equipment in the microgrid. Therefore, identification and detection of PQD are indispensable to the system reliability and security. In recent years, intelligent approaches based on deep learning have been applied for the classification of PQD. Among numerous intelligent approaches, the convolutional neural network (CNN) is one of the effective structures and is widely employed in the PQD classification work [3].
The one-dimensional (1D) CNN for PQD classification has been implemented in the literature [4,5,6,7,8]. These studies are focused on the improvement of the classification performance in the over-fitting problem [4], modification of the process in the feature extraction of PQD [5,6], and proposal of the hybrid classification model [7]. To deal with the issues related to computational burden and the complexity of the classification model, the advanced data compression technique in the data preprocessing is proposed in [8]. However, a lot of PQD information would disappear due to the compression process.
Due to the learning capability for the diversity and complexity of image features, the CNN method is applied for the classification of two-dimensional (2D) images [9]. If one would apply the CNN for the classification of PQD, which is a 1D signal, the data preprocessing process is required to convert the 1D power signal to the 2D image. Since more PQD information can be included in the 2D image than that in the 1D signal, many image conversion techniques have been carried out in recent years [10,11,12,13,14,15,16,17]. Fast discrete curvelet transform is employed in [10] to extract the feature image of PQD. In [11], the signal-waveform image is directly utilized for the training the PQD classifier. The space phasor diagram is applied in [12,13,14] for the transformation of the sag signal into the PQD image. In the studies of [15,16,17], an image transformation matrix is proposed, where the sampling points of the PQD signal are rearranged in the matrix and then converted into the grayscale image. However, some important features are completely lost in the transformation of [12,13,14]. Once the fundamental frequency is deviated from the nominal value, the rearrangement of the image transformation matrix in [15,16,17] would lead to classification inaccuracy. This is because the time positions of PQD would be deteriorated due to the variation of fundamental frequency.
In this paper, a regulated 2D deep CNN-based power quality classifier is proposed to enhance the identification performance. In Section 2.1, the mathematical models of classical PQD discussed in this paper are introduced. The IEC-based synchronizer is developed in the preprocessing stage to estimate the deviation of fundamental frequency of the microgrid in Section 2.2. Then, the 2D grayscale image for the training of the deep CNN classifier is regulated in Section 2.3 with the obtained fundamental frequency, where the PQD information can be accurately preserved. After the PQD training with the structure of deep CNN mentioned in Section 2.4, the power quality classifier is ready for the disturbance identification. To examine the performance of PQD classification, the results of training and evaluation phases and field experiments with the proposed and compared classifiers are presented in Section 3.

2. Proposed Regulated 2D Deep CNN-Based Power Quality Classifier

The proposed regulated 2D deep CNN-based power quality classifier can be divided into three stages: signal synchronization (SS), image regulation (IR), and disturbance classification (DC). In the SS stage, the deviated fundamental frequency can be obtained with the synchronizer based on IEC Std. 61000-4-7. Then, the obtained fundamental frequency would be used to split the PQD signal correctly and regulate the 2D grayscale image matrix in the IR stage. The regulated feature image would then be processed in the DC stage to perform the PQD identification. The solution procedure of proposed power quality classifier is depicted in Figure 1. In the following, first, the mathematical models for the generation of PQD training data are introduced. Furthermore, the proposed approach to implement the IEC-based synchronizer and image regulation is presented. Then, the structure of the applied deep CNN model is introduced.

2.1. Mathematical Model of PQD

To provide sufficient and diverse PQD data, the mathematical models with the parameter variations in IEEE Std. 1159 were employed to generate the synthetic PQD for the training of the power quality classifier in this section [18]. As listed in Table 1, 14 categories of PQD signals s(t) were applied.
The values of parameters such as intensity (α), distortion of the transient (β), distortion of the flicker ( λ ), and time (t1 and t2) were randomly generated to obtain the variety of each PQD category. The nominal value of fundamental frequency (f) was set to be 60 Hz, varying in the range of 59.5 and 60.5 Hz, whereas the sampling frequency (fs) was 7680 Hz, the number of sampling cycles (Nc) was 12, the total sampling points (Ns) was 1536, and the amplitude (A) was normalized to 1. T is the fundamental period. The synthetic signals generated for each PQD category were 10,000 samples and then the total number of samples was 140,000.

2.2. Signal Synchronization (SS)

Due to the variation of fundamental frequency, the traditional signal transformation for the training of the neural network in the literature would be deteriorated, where the splitting process of the PQD signal to form the image matrix is incorrect. To solve this problem, the signal synchronization of fundamental frequency followed by IEC 61000-4-7 is introduced in this paper to regulate the image matrix [19]. The synchronization process of fundamental frequency is represented in Figure 2, where the detection method for the fundamental frequency is not specified, which provides design flexibility for the instrument manufacturer, f0 is the nominal fundamental frequency, and f(k) and f(k − 1) are the present and previous estimated values of fundamental frequency, respectively. As a result, a simple detection method of fundamental frequency is introduced in this section.
Suppose the discrete-time PQD signal, si, through the low-pass filter sLP_i can be expressed as:
s L P _ i = A cos ( 2 π f i f s + θ ) ,   i = 1 ,   2 ,   3 ,   ,   I
where f is the fundamental frequency, A is the amplitude, fs is the sampling frequency, θ is the phase angle, and I is the number of samples. Equation (1) can also be represented in the complex form as:
s L P _ i = A c Ω i + A c Ω i ,   i = 1 ,   2 ,   3 ,   ,   I
where A c = A 2 e j φ , Ω = e j 2 π f f s , and * represents the complex conjugate. Followed by the autoregressive prediction model, the total squared error, E, for the signal approximation can be expressed with the linear combination of three successive samples in Equation (3), where η is the parameter for the signal approximation [20]:
E = i = 3 I ( η s L P _ i + s L P _ i 1 + η s L P _ i 2 ) 2
Besides, the transfer function of the second-order autoregressive prediction model can be given by:
η Ω 2 + Ω + η = 0
To minimize the approximation error, the relationship of Equation (5) shall be met:
  d E d η = 2 i = 3 I ( η s L P _ i + s L P _ i 1 + η s L P _ i 2 ) ( s L P _ i + s L P _ i 2 ) = 0
Then, η can be solved in Equation (6):
η = i = 3 I s L P _ i 1 ( s L P _ i + s L P _ i 2 ) i = 3 I ( s L P _ i + s L P _ i 2 ) 2
By substituting Equation (6) into Equation (4) and solving Ω, the fundamental frequency, f, can be calculated adaptively based on the sliding window of I samples, as listed in Equation (7):
f = f s × cos 1 ( i = 3 I ( s L P _ i + s L P _ i 2 ) 2 2 i = 3 I s L P _ i 1 ( s L P _ i + s L P _ i 2 ) )
In this way, the deviated fundamental frequency can be easily obtained with the above-mentioned IEC-based synchronizer to regulate the image matrix.

2.3. Image Regulation (IR)

In this section, the PQD signal is divided into multiple cycles, where the obtained fundamental frequency from the IEC-based synchronizer in Equation (7) was utilized to determine the regulated cycle duration according to the variation of fundamental frequency. The signals of divided cycles were transformed into the submatrices, and these submatrices were then merged to form a regulated matrix. Finally, the regulated matrix was converted to the 2D grayscale image. The advantages of this approach are that the image resolution can be reduced, and the image matrix can be correctly regulated when the frequency variation is present. The main steps of the proposed approach are as follows:
Step 1
Determine the submatrix dimension.
The square submatrix (number of the rows (Nrow) is equal to the number of the columns (Ncol)) is chosen. Ncol is determined by Equation (8),
N c o l = f s f
where f is the regulated fundamental frequency obtained in Equation (7).
Step 2
Divide the PQD signal into multiple cycles.
The PQD signal is divided into Nc cycles according to the value of f.
Step 3
Transform the divided cycles into submatrices.
(1)
Initialize all the elements of the lth submatrix Ml_x,y with Equation (9), where x and y are the row and column indices, respectively.
M l _ x , y = 0 , l = 1 ,   2 ,   3 ,   ,   N c
(2)
Determine the column index y of the lth submatrix Ml_x,y.
The discrete-time index of the divided cycle is assigned as the column index to the submatrix, as listed in Equation (10), where y is the remainder of division between i and Ncol:
y = i i N c o l × N c o l
(3)
Determine the row index x of the lth submatrix Ml_x,y.
The process of row determination for each sampling point is displayed in Figure 3. The sampling values of the PQD signal are arranged into different levels. The number of levels should be the same as the number of rows, and the width of the level interval should be the same as well. The width of the level interval (LInt) is calculated with Equation (11):
L I n t = H s L s N r o w
where Hs represents the highest sampling value and Ls represents the lowest sampling value from all the sampling values. In addition, the lower (BL) and upper (BU) boundaries are used to define the limits of levels, which can be obtained through the process in Figure 3. The order of levels is started from the highest sampling value as the first level, while the lowest sampling value is in the final level. According to the level arrangement in Figure 3, the row index, x, of each sampling point, si, can be obtained in Equation (12) by comparing the sampling value to all the levels:
x = m
(4)
Insert the sampling values of a divided cycle as the matrix elements with the obtained row and column indices.
(5)
Repeat the process to transform the rest of the cycles into the submatrices.
Step 4
Merge the submatrices to form a regulated matrix.
All the corresponding elements in each submatrix are summed, as shown in Equation (13), where M is the element of the combined matrix, Ml is the element of the submatrix, and x and y are the matrix indices. The combined matrix has the same dimensions as the submatrices.
M x , y = l = 1 N c M l _ x , y , x N r o w , y N c o l
Step 5
Convert the regulated matrix to the 2D grayscale image.
The elements of the matrix are converted to the grayscale color (0–255) to create the grayscale image. The resulted image resolution is Nrow × Ncol pixels.

2.4. Disturbance Classification (DC)

The 2D deep CNN methods were employed to perform the classification of PQD. As depicted in Figure 4, the applied deep CNN structure is composed of six convolution layers, three max pooling layers, a dropout layer, and two dense or fully connected layers. The details of these compositions are presented in Table 2.

2.5. Indices of Performance Evaluation

To evaluate the performance of the proposed PQD classifier, the confusion matrix was applied to measure the indices such as accuracy, recall, precision, and f1-score, as listed in Equations (14)–(17) [21,22,23]. The four kinds of outputs from the confusion matrix, such as true positive (TP), false positive (FP), true negative (TN), and false negative (FP), were calculated to obtain the values of the indices.
a c c u r a c y = T P + T N T P + T N + F P + F N
r e c a l l = T P T P + F N
p r e c i s i o n = T P T P + F P
f 1 s c o r e = ( 2 × p r e c i s i o n × r e c a l l ) ( p r e c i s i o n + r e c a l l )

3. Results

To provide sufficient and diverse PQD data for the training of the power quality classifier, the generation of 14 types of datasets is performed in this section. Then, the PQD datasets used in this work are transformed to the regulated 2D grayscale images according to the procedure proposed in this paper. Furthermore, the results of the training and testing are analyzed to evaluate the performance of the proposed model and the models in the literature. Finally, the field verification is implemented based on a microgrid in the campus of National Central University, Taiwan, to examine the PQD classification.

3.1. Generation of Datasets and Regulated 2D Grayscale Image

The 14 synthetic PQD types were generated with the mathematical models from Table 1. Then, the PQD signal was converted to the regulated 2D grayscale image based on the proposed procedure, as shown in Table 3. It was found that the information of the original PQD signal can be preserved in the image, even though the values of sampling points were converted into the grayscale color. To realize the performance of the proposed regulated 2D transformation, the existing conversion methods in [15,16,17] were also implemented to obtain two 2D image datasets for comparison. For the training and validation purposes, 9000 and 1000 samples of each PQD category were utilized in the training and evaluation phases, respectively.

3.2. Results of Training and Evaluation Phases

The model structure in Table 2 was utilized for the training phase, where the 2D grayscale images obtained with the proposed approach and the methods in [15,16,17] were fed as the inputs. In the deep CNN model, an Adam optimizer with a learning rate of 0.001 was adopted and a categorical cross-entropy was applied for the loss function. The hardware for model training is based on a Nvidia Tesla T4 Graphics Processing Unit (GPU) accelerator with 16 GB of memory and an Intel Xeon (R) Central Processing Unit (CPU) at 2.20 GHz. All the algorithms of power quality classifiers were implemented with Go language, which is an open-source software developed by Google.
The fitting graphs between the training and validation of models are displayed in Figure 5. It was found that the models were trained at 50 epochs since the accuracy and loss values of training and validation after the 50 epochs were unstable for the compared models. In addition, the values in the dropout layer were adjusted to achieve the fitting accuracy and loss values between training and validation for each method. In this way, the dropout values were selected as 0.36 for the proposed method, 0.46 for Karasu’s method in [15,16], and 0.55 for Zheng’s method in [17], respectively. The performance evaluation for the compared models is listed in Table 4. It was realized that the performance of the proposed approach in the conversion task was better than the previous approaches.
For the model evaluation phase, the testing results are represented in the confusion matrices of Table 5, Table 6 and Table 7. Then, the values of indices such as the recall, the precision, and the f1-score were obtained, as presented in Table 8 and Figure 6.
The experimental results revealed that Karasu’s method in [15,16] obtained 99.88% for accuracy, 99.19% for precision, 99.18% for recall, and 99.18% for f1-score. Zheng’s method in [17] reached 99.74% for accuracy, 98.80% for precision, 97.81% for recall, and 98.30% for f1-score. It can be seen that the proposed approach outperformed the other methods, with 99.97% for accuracy, 99.81% for precision, 99.80% for recall, and 99.80% for f1-score. From the results in the confusion matrix, the capability of the proposed regulated model to detect only the PQD of interest in the dataset was also higher than the previous methods. It was indicated that the synchronization process of fundamental frequency is important to the 2D image transformation, which can effectively and correctly split the PQD signal to regulate the 2D image matrix. However, the computational time of the proposed approach was higher compared with the other methods since the larger 2D image size was utilized in the training phase.

3.3. Field Verification

To examine the practical performance of the proposed regulated 2D deep CNN-based method in the field PQD classification, the microgrid system at National Central University, Taiwan, was tested. The system information and photo are displayed in Table 9 and Figure 7, respectively.
According to numerous experimental tests, the proposed method can deal with most PQD classification accurately, compared with the threshold method (TM) in [24], the traditional fuzzy analysis (FA) in [25], the traditional back-propagation neural network (BPNN) in [26], the wavelet energy fuzzy neural network-based technique (WEFNNBT) in [27], Karasu’s method in [16,17], and Zheng’s method in [18], as listed in Table 10.
From Table 10, it can easily be found that the TM and FA could not recognize some PQD accurately (accuracy lower than 90%) due to the short-time duration and waveform distortion of PQD. The incorrect classification would be obtained in BPNN since the noisy interference is present in the solution process of discrete wavelet transform. The classification of the proposed approach was superior to WEFNNBT in [27], Karasu’s method in [15,16], and Zheng’s method in [17]. It was realized that the proposed method can effectively provide PQD classification and a protection strategy for the microgrid system.

4. Conclusions

A regulated 2D deep CNN-based power quality classifier for the microgrid was presented in this paper. For the traditional 2D CNN power quality classifier (Karasu’s method and Zheng’s method), the signal-to-image transformation is based on the nominal fundamental frequency. Once the deviation is present in the fundamental frequency due to the power imbalance between the generation and the load demand, the image transformation would be deteriorated. To enhance the classification performance, the IEC-based synchronizer was proposed to detect the deviation of fundamental frequency and regulate the image matrix. In this way, the information and waveform characteristics of the signal can be preserved in the regulated 2D grayscale image. Through the testing results and field measurement, it was demonstrated that the proposed approach can improve the efficacy of the PQD classification with accuracy higher than 99.79%, and was superior to the previous existing approaches. In addition, the total computational burden of SS and IR stages was very low due to the simple calculation of Equation (7) and rearrangement of images, which takes approximately 0.53 ms. Even though the training phase of the proposed method takes longer than the compared methods, the validation phase only takes approximately 20 ms. As a result, the total computational time for the power quality classification is 20.53 ms, which is shorter than the data duration of 200 ms (12 cycles under a 60 Hz system). Therefore, it was found that the proposed solution procedure meets the real-time requirement for the power quality classification.

Author Contributions

Conceptualization, C.-I.C., S.S.B. and Y.-C.C.; methodology, C.-I.C. and S.S.B.; software, S.S.B. and H.-C.Y.; validation, H.-C.Y. and C.-H.C.; formal analysis, C.-I.C. and S.S.B.; investigation, C.-I.C., S.S.B. and Y.-C.C.; resources, C.-I.C. and C.-H.C.; data curation, C.-I.C.; writing—original draft preparation, C.-I.C. and S.S.B.; writing—review and editing, C.-I.C.; visualization, C.-I.C., S.S.B. and Y.-C.C.; supervision, C.-I.C.; project administration, C.-I.C.; funding acquisition, C.-I.C. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by Ministry of Science and Technologies, grant numbers MOST 110-2221-E-008-058 and MOST 110-3116-F-008-001, and the Research Center for Energy Technology, National Central University, Taiwan.

Institutional Review Board Statement

The study did not require ethical approval.

Informed Consent Statement

Not applicable.

Data Availability Statement

The study did not report any data.

Acknowledgments

The authors gratefully acknowledge the helpful comments and suggestions of the reviewers for improving the presentation.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Chen, C.I.; Chen, Y.C.; Chen, C.H.; Chang, Y.R. Voltage Regulation Using Recurrent Wavelet Fuzzy Neural Network-Based Dynamic Voltage Restorer. Energies 2020, 13, 6242. [Google Scholar] [CrossRef]
  2. Chen, C.I.; Lan, C.K.; Chen, Y.C.; Chen, C.H. Adaptive Frequency-Based Reference Compensation Current Control Strategy of Shunt Active Power Filter for Unbalanced Nonlinear Loads. Energies 2019, 12, 3080. [Google Scholar] [CrossRef] [Green Version]
  3. Sindi, H.; Nour, M.; Rawa, M.; Öztürk, Ş.; Polat, K. A Novel Hybrid Deep Learning Approach Including Combination of 1D Power Signals and 2D Signal Images for Power Quality Disturbance Classification. Expert Syst. Appl. 2021, 174, 114785. [Google Scholar] [CrossRef]
  4. Wang, S.; Chen, H. A Novel Deep Learning Method for the Classification of Power Quality Disturbances Using Deep Convolutional Neural Network. Appl. Energy 2019, 235, 1126–1140. [Google Scholar] [CrossRef]
  5. Shen, Y.; Abubakar, M.; Liu, H.; Hussain, F. Power Quality Disturbance Monitoring and Classification Based on Improved PCA and Convolution Neural Network for Wind-Grid Distribution Systems. Energies 2019, 12, 1280. [Google Scholar] [CrossRef] [Green Version]
  6. Aggarwal, A.; Das, N.; Arora, M.; Tripathi, M.M. A Novel Hybrid Architecture for Classification of Power Quality Disturbances. In Proceedings of the 2019 6th International Conference on Control, Decision and Information Technologies (CoDIT), Paris, France, 23–26 April 2019; pp. 1829–1834. [Google Scholar]
  7. Mohan, N.; Soman, K.P.; Vinayakumar, R. Deep Power: Deep Learning Architectures for Power Quality Disturbances Classification. In Proceedings of the 2017 International Conference on Technological Advancements in Power and Energy (TAP Energy), Kollam, India, 21–23 December 2017; pp. 1–6. [Google Scholar]
  8. Wang, J.; Xu, Z.; Che, Y. Power Quality Disturbance Classification Based on Compressed Sensing and Deep Convolutional Neural Networks. IEEE Access. 2019, 7, 78336–78346. [Google Scholar] [CrossRef]
  9. Öztürk, Ş.; Akdemir, B. Cell-Type Based Semantic Segmentation of Histopathological Images Using Deep Convolutional Neural Networks. Int. J. Imaging Syst. Technol. 2019, 29, 234–246. [Google Scholar] [CrossRef]
  10. Liu, H.; Hussain, F.; Shen, Y.; Arif, S.; Nazir, A.; Abubakar, M. Complex Power Quality Disturbances Classification via Curvelet Transform and Deep Learning. Electr. Power Syst. Res. 2018, 163, 1–9. [Google Scholar] [CrossRef]
  11. Zhu, R.; Gong, X.; Hu, S.; Wang, Y. Power Quality Disturbances Classification via Fully-Convolutional Siamese Network and k-Nearest Neighbor. Energies 2019, 12, 4732. [Google Scholar] [CrossRef] [Green Version]
  12. Bagheri, A.; Bollen, M.H.J.; Gu, I.Y.H. Improved Characterization of Multi-Stage Voltage Dips Based on the Space Phasor Model. Electr. Power Syst. Res. 2018, 154, 319–328. [Google Scholar] [CrossRef]
  13. Bagheri, A.; Gu, I.Y.H.; Bollen, M.H.J.; Balouji, E. A Robust Transform-Domain Deep Convolutional Network for Voltage Dip Classification. IEEE Trans. Power Deliv. 2018, 33, 2794–2802. [Google Scholar] [CrossRef] [Green Version]
  14. Xiao, F.; Lu, T.; Wu, M.; Ai, Q. Maximal Overlap Discrete Wavelet Transform and Deep Learning for Robust Denoising and Detection of Power Quality Disturbance. IET Gener. Transm. Distrib. 2020, 14, 140–147. [Google Scholar] [CrossRef]
  15. Karasu, S.; Saraç, Z. Investigation of Power Quality Disturbances by Using 2D Discrete Orthonormal S-Transform, Machine Learning and Multi-Objective Evolutionary Algorithms. Swarm Evol. Comput. 2019, 44, 1060–1072. [Google Scholar] [CrossRef]
  16. Karasu, S.; Saraç, Z. Classification of Power Quality Disturbances by 2D-Riesz Transform, Multi-Objective Grey Wolf Optimizer and Machine Learning Methods. Digit. Signal Process. 2020, 101, 102711. [Google Scholar] [CrossRef]
  17. Zheng, Z.; Qi, L.; Wang, H.; Pan, A.; Zhou, J. Recognition Method of Voltage Sag Causes Based on Two-Dimensional Transform and Deep Learning Hybrid Model. IET Power Electron. 2020, 13, 168–177. [Google Scholar] [CrossRef]
  18. IEEE Recommended Practice for Monitoring Electric Power Quality; IEEE Std.: New York, NY, USA, 2019; pp. 1159–2019.
  19. IEC 61000-4-7; Testing and Measurement Techniques—General Guide on Harmonics and Interharmonics Measurements and Instrumentation, for Power Supply Systems and Equipment Connected Thereto. IEC Std.: Geneva, Switzerland, 2009.
  20. Chang, G.W.; Chen, C.I.; Liang, Q.W. A Two-Stage ADALINE for Harmonics and Interharmonics Measurement. IEEE Trans. Ind. Electron. 2009, 56, 2220–2228. [Google Scholar] [CrossRef]
  21. Cai, K.; Cao, W.; Aarniovuori, L.; Pang, H.; Lin, Y.; Li, G. Classification of Power Quality Disturbances Using Wigner-Ville Distribution and Deep Convolutional Neural Networks. IEEE Access 2019, 7, 119099–119109. [Google Scholar] [CrossRef]
  22. Xu, J.; Zhang, Y.; Miao, D. Three-Way Confusion Matrix for Classification: A Measure Driven View. Inf. Sci. 2020, 507, 772–794. [Google Scholar] [CrossRef]
  23. Tharwat, A. Classification Assessment Methods. Appl. Comput. Inform. 2021, 17, 168–192. [Google Scholar] [CrossRef]
  24. Li, H.; Chen, M.; Yang, B.; Blaabjerg, F.; Xu, D. Fast Fault Protection Based on Direction of Fault Current for the High-Surety Power-Supply System. IEEE Trans. Power Electron. 2019, 34, 5787–5802. [Google Scholar] [CrossRef] [Green Version]
  25. Dash, P.K.; Mishra, S.; Salama, M.M.A.; Liew, A.C. Classification of Power System Disturbances Using a Fuzzy Expert System and a Fourier Linear Combiner. IEEE Trans. Power Deliv. 2010, 15, 472–477. [Google Scholar] [CrossRef] [Green Version]
  26. Kumar, R.; Singh, B.; Shahani, D.T.; Chandra, A.; Al-Haddad, K. Recognition of Power-Quality Disturbances Using S-Transform-Based ANN Classifier and Rule-Based Decision Tree. IEEE Trans. Ind. Appl. 2015, 51, 1249–1258. [Google Scholar] [CrossRef]
  27. Chen, C.I.; Lan, C.K.; Chen, Y.C.; Chen, C.H.; Chang, Y.R. Wavelet Energy Fuzzy Neural Network-Based Fault Protection System for Microgrid. Energies 2020, 13, 1007. [Google Scholar] [CrossRef] [Green Version]
Figure 1. Solution procedure of the proposed power quality classifier.
Figure 1. Solution procedure of the proposed power quality classifier.
Energies 15 02532 g001
Figure 2. Synchronization process of fundamental frequency based on IEC Std. 61000-4-7.
Figure 2. Synchronization process of fundamental frequency based on IEC Std. 61000-4-7.
Energies 15 02532 g002
Figure 3. Process of row determination for each sampling point.
Figure 3. Process of row determination for each sampling point.
Energies 15 02532 g003
Figure 4. Architecture of the applied deep CNN model.
Figure 4. Architecture of the applied deep CNN model.
Energies 15 02532 g004
Figure 5. Fitting graph between the training and validation of (a) the proposed method, (b) Karasu’s method in [15,16], and (c) Zheng’s method in [17].
Figure 5. Fitting graph between the training and validation of (a) the proposed method, (b) Karasu’s method in [15,16], and (c) Zheng’s method in [17].
Energies 15 02532 g005
Figure 6. Bar chart of the testing evaluation between the proposed approach and the existing methods.
Figure 6. Bar chart of the testing evaluation between the proposed approach and the existing methods.
Energies 15 02532 g006
Figure 7. Microgrid system at National Central University, Taiwan.
Figure 7. Microgrid system at National Central University, Taiwan.
Energies 15 02532 g007
Table 1. Mathematical models and parameter constraints of PQD.
Table 1. Mathematical models and parameter constraints of PQD.
PQDCategoryMathematical ModelParameter Constraints
NormalC01 s ( t ) = A [ 1 ± α ( u ( t t 1 ) u ( t t 2 ) ) ] s i n ( ω t ) α 0.1 ,   T t 2 t 1 10 T ,   ω = 2 π f
SagC02 s ( t ) = A [ 1 α ( u ( t t 1 ) u ( t t 2 ) ) ] s i n ( ω t ) 0.1 α 0.9 ,   T t 2 t 1 10 T
SwellC03 s ( t ) = A [ 1 + α ( u ( t t 1 ) u ( t t 2 ) ) ] s i n ( ω t ) 0.1 α 0.8 ,   T t 2 t 1 10 T
InterruptionC04 s ( t ) = A [ 1 α ( u ( t t 1 ) u ( t t 2 ) ) ] s i n ( ω t ) 0.9 α 1 ,   T t 2 t 1 10 T
HarmonicsC05 s ( t ) = A [ α 1 s i n ( ω t ) + α 3 s i n ( 3 ω t ) + α 5 s i n ( 5 ω t ) + α 7 s i n ( 7 ω t ) ] 0.05 α 3 , α 5 , α 7 0.15 ,     α i 2 = 1
FlickerC06 s ( t ) = A [ 1 + λ s i n ( ω f t ) ] s i n ( ω t ) 5 f f 25 ,   w f = 2 π f f   0.1 λ 2
Transient oscillationC07 s ( t ) = A [ s i n ( ω t ) + β e ( t t 1 ) / τ   s i n ( ω n ( t t 1 ) ) ( u ( t t 2 ) u ( t t 1 ) ) ] 300 f n 900 ,   ω n = 2 π f n , 0.5 T t 2 t 1 N c 4 T ,   8   ms τ 40   ms ,   0.1 β 0.8
Periodic notchC08 s ( t ) = s i n ( ω t ) s i g n ( s i n ( ω t ) ) × { n = 0 9 k [ u ( t ( t 1 s n ) u ( t ( t 2 s n ) ) ] } 0.01 T t 2 t 1 0.05 T t 2 s ,   t 1 0 ,   0.1 k 0.4 ,   c = { 1 , 2 , 4 , 6 } ,   s = T c
Sag with harmonicsC09 s ( t ) = A [ 1 α ( u ( t t 1 ) u ( t t 2 ) ) ] [ α 1 s i n ( ω t ) + α 3 s i n ( 3 ω t ) + α 5 s i n ( 5 ω t ) ] 0.1 α 0.9 ,   T t 2 t 1 10 T ,   0.05 α 3 , α 5 , α 7 0.15 ,     α i 2 = 1
Swell with harmonicsC10 s ( t ) = A [ 1 + α ( u ( t t 1 ) u ( t t 2 ) ) ] [ α 1 s i n ( ω t ) + α 3 s i n ( 3 ω t ) + α 5 s i n ( 5 ω t ) ] 0.1 α 0.8 ,   T t 2 t 1 10 T 0.05 α 3 , α 5 , α 7 0.15 ,     α i 2 = 1
Interruption with harmonicsC11 s ( t ) = A [ 1 α ( u ( t t 1 ) u ( t t 2 ) ) ] [ α 1 s i n ( ω t ) + α 3 s i n ( 3 ω t ) + α 5 s i n ( 5 ω t ) ] 0.9 α 1 ,   T t 2 t 1 10 T 0.05 α 3 , α 5 , α 7 0.15 ,     α i 2 = 1
Flicker with harmonicsC12 s ( t ) = A [ 1 + λ s i n ( ω f t ) ] [ α 1 s i n ( ω t ) + α 3 s i n ( 3 ω t ) + α 5 s i n ( 5 ω t )   ] 0.1 λ 2 ,   5 f f 25 0.05 α 3 , α 5 , α 7 0.15 ,     α i 2 = 1
Flicker with sagC13 s ( t ) = A [ 1 + λ s i n ( ω f t ) ( 1 α ( u ( t t 1 ) u ( t t 2 ) ) ] s i n ( ω t ) 0.1 α 0.9 ,   T t 2 t 1 10 T 0.1 λ 2 ,   5   f f 25  
Flicker with swellC14 s ( t ) = A [ 1 + λ s i n ( ω f t ) ( 1 + α ( u ( t t 1 ) u ( t t 2 ) ) ] s i n ( ω t ) 0.1 α 0.8 ,   T t 2 t 1 10 T 0.1 λ 2 ,   5   f f 25
Table 2. Details of model architecture.
Table 2. Details of model architecture.
LayerParameters
Convolution 1Number of kernal filters = 32, Kernal size = 5 × 5, Activation function: ReLU
Convolution 2Number of kernal filters = 32, Kernal size = 5 × 5, Activation function: ReLU
Pooling 1Max pooling, Size = 2 × 2, Step: 2
Convolution 3Number of kernal filters = 32, Kernal size = 5 × 5, Activation function: ReLU
Convolution 4Number of kernal filters = 32, Kernal size = 5 × 5, Activation function: ReLU
Pooling 2Max pooling, Size = 2 × 2, Step: 2
Convolution 5Number of kernal filters = 32, Kernal size = 5 × 5, Activation function: ReLU
Convolution 6Number of kernal filters = 32, Kernal size = 5 × 5, Activation function: ReLU
Pooling 3Max pooling, Size = 2 × 2, Step: 2
Dense 1Number of neurons: 128, Activation function: ReLU
Dense 2Number of neurons: 14, Activation function: softmax
Table 3. Representation of the PQD signal and the regulated 2D grayscale image.
Table 3. Representation of the PQD signal and the regulated 2D grayscale image.
PQD TypePQD Signal2D Grayscale ImagePQD TypePQD Signal2D Grayscale Image
Normal Energies 15 02532 i001 Energies 15 02532 i002Sag wit harmonics Energies 15 02532 i003 Energies 15 02532 i004
Flicker Energies 15 02532 i005 Energies 15 02532 i006Swell with harmonics Energies 15 02532 i007 Energies 15 02532 i008
Harmonics Energies 15 02532 i009 Energies 15 02532 i010Interruption with harmonics Energies 15 02532 i011 Energies 15 02532 i012
Interruption Energies 15 02532 i013 Energies 15 02532 i014Flicker with harmonics Energies 15 02532 i015 Energies 15 02532 i016
Notch Energies 15 02532 i017 Energies 15 02532 i018Flicker with sag Energies 15 02532 i019 Energies 15 02532 i020
Sag Energies 15 02532 i021 Energies 15 02532 i022Flicker with swell Energies 15 02532 i023 Energies 15 02532 i024
Swell Energies 15 02532 i025 Energies 15 02532 i026Transient Energies 15 02532 i027 Energies 15 02532 i028
Table 4. Performance comparison of models.
Table 4. Performance comparison of models.
ModelsTraining Accuracy (%)Validation Accuracy (%)
Proposed Method99.2599.46
Karasu’s Method in [15,16]98.6998.94
Zheng’s Method in [17]97.9898.43
Table 5. Confusion matrix of the proposed method.
Table 5. Confusion matrix of the proposed method.
CategoryC01C02C03C04C05C06C07C08C09C10C11C12C13C14
C019980020000000000
C0209880120000000000
C030099800020000000
C040209980000000000
C0500001000000000000
C0600000100000000000
C0700000010000000000
C0800000001000000000
C090000000099208000
C1000000000010000000
C1100000000001000000
C1200000000000100000
C1300000000000010000
C1400000000000001000
Table 6. Confusion matrix of Karasu’s method in [15,16].
Table 6. Confusion matrix of Karasu’s method in [15,16].
CategoryC01C02C03C04C05C06C07C08C09C10C11C12C13C14
C019940000060000000
C02289600120000000000
C030099800020000000
C0402009800000000000
C0500001000000000000
C0600000100000000000
C074440009862000000
C082000000998000000
C0900000000980020000
C1000000000010000000
C110000000080992000
C1200000000000100000
C1300000000000010000
C140000000000002998
Table 7. Confusion matrix of Zheng’s method in [17].
Table 7. Confusion matrix of Zheng’s method in [17].
CategoryC01C02C03C04C05C06C07C08C09C10C11C12C13C14
C019980000002000000
C02329260420000000000
C0300100000000000000
C0401009900000000000
C0500001000000000000
C0600000100000000000
C0716402009744000000
C084000000996000000
C0900000000958042000
C1000000000010000000
C110000000060994000
C120000000020099800
C1300000000000010000
C140000000000002998
Table 8. Summary of the models’ performance between the proposed and existing methods.
Table 8. Summary of the models’ performance between the proposed and existing methods.
IndexKarasu’s
Method [15,16]
Zheng’s
Method [17]
Proposed
Approach
Accuracy (%)99.8899.7499.97
Precision (%)99.1998.8099.81
Recall (%)99.1897.8199.80
F1-score (%)99.1898.3099.80
Training time per epoch (seconds)151628
Table 9. System information of the microgrid at National Central University, Taiwan.
Table 9. System information of the microgrid at National Central University, Taiwan.
Building Sizefour 20-foot containers
Load Demand10 kWh/day
Solar GenerationThe total power generation per day is 7.4 kW × 3.9 h = 28.86 kWh
3.9 h is the average sunshine hours at National Central University, Taiwan
Storage SystemLithium-ion Battery21.6 kWh
Fuel Cell5 kW
Power InverterThree-phase 15 kW, AC output voltage is 220 V
Table 10. Comparison of classification accuracy between the proposed and existing methods.
Table 10. Comparison of classification accuracy between the proposed and existing methods.
PQDTMFABPNNWEFNNBTKarasu’s
Method
Zheng’s
Method
Proposed
Approach
Normal97.51%98.15%67.81%99.26%99.92%99.75%99.98%
Sag97.12%16.18%97.85%98.83%99.45%98.97%99.79%
Swell96.84%17.57%97.61%98.66%99.69%99.48%99.93%
Harmonic13.72%96.42%97.15%99.17%99.91%99.81%99.97%
Transient86.34%95.83%96.92%98.22%99.88%99.76%99.97%
Flicker83.62%94.45%96.83%97.84%99.74%99.68%99.96%
Interruption12.86%15.29%97.72%98.93%99.51%99.13%99.86%
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Chen, C.-I.; Berutu, S.S.; Chen, Y.-C.; Yang, H.-C.; Chen, C.-H. Regulated Two-Dimensional Deep Convolutional Neural Network-Based Power Quality Classifier for Microgrid. Energies 2022, 15, 2532. https://doi.org/10.3390/en15072532

AMA Style

Chen C-I, Berutu SS, Chen Y-C, Yang H-C, Chen C-H. Regulated Two-Dimensional Deep Convolutional Neural Network-Based Power Quality Classifier for Microgrid. Energies. 2022; 15(7):2532. https://doi.org/10.3390/en15072532

Chicago/Turabian Style

Chen, Cheng-I, Sunneng Sandino Berutu, Yeong-Chin Chen, Hao-Cheng Yang, and Chung-Hsien Chen. 2022. "Regulated Two-Dimensional Deep Convolutional Neural Network-Based Power Quality Classifier for Microgrid" Energies 15, no. 7: 2532. https://doi.org/10.3390/en15072532

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop