Ultra‐short‐term irradiance forecasting model based on ground‐based cloud image and deep learning algorithm

IET Renewable Power GenerationEarly View ORIGINAL RESEARCH PAPEROpen Access Ultra-short-term irradiance forecasting model based on ground-based cloud image and deep learning algorithm Zhao Zhen, Corresponding Author Zhao Zhen georgiazhz@foxmail.com orcid.org/0000-0001-5406-6441 State Key Lab of Power System, Department of Electrical Engineering, Tsinghua University, Beijing, China Department of Electrical Engineering, North China Electric Power University, Baoding, China State Key Laboratory of Alternate Electrical Power System with Renewable Energy Sources (North China Electric Power University), Beijing, China Correspondence Zhao Zhen, State Key Lab of Power System, Department of Electrical Engineering, Tsinghua University, Beijing 100084, China. Email: georgiazhz@foxmail.comSearch for more papers by this authorXuemin Zhang, Xuemin Zhang orcid.org/0000-0001-9246-1397 State Key Lab of Power System, Department of Electrical Engineering, Tsinghua University, Beijing, ChinaSearch for more papers by this authorShengwei Mei, Shengwei Mei orcid.org/0000-0002-2757-5977 State Key Lab of Power System, Department of Electrical Engineering, Tsinghua University, Beijing, ChinaSearch for more papers by this authorXiqiang Chang, Xiqiang Chang State Grid Xinjiang Electric Power Co., Ltd, Urumqi, ChinaSearch for more papers by this authorHua Chai, Hua Chai Department of Electrical Engineering, North China Electric Power University, Baoding, ChinaSearch for more papers by this authorRui Yin, Rui Yin State Grid Hebei Electric Power Co., Ltd, Shijiazhuang, ChinaSearch for more papers by this authorFei Wang, Fei Wang Department of Electrical Engineering, North China Electric Power University, Baoding, China State Key Laboratory of Alternate Electrical Power System with Renewable Energy Sources (North China Electric Power University), Beijing, ChinaSearch for more papers by this author Zhao Zhen, Corresponding Author Zhao Zhen georgiazhz@foxmail.com orcid.org/0000-0001-5406-6441 State Key Lab of Power System, Department of Electrical Engineering, Tsinghua University, Beijing, China Department of Electrical Engineering, North China Electric Power University, Baoding, China State Key Laboratory of Alternate Electrical Power System with Renewable Energy Sources (North China Electric Power University), Beijing, China Correspondence Zhao Zhen, State Key Lab of Power System, Department of Electrical Engineering, Tsinghua University, Beijing 100084, China. Email: georgiazhz@foxmail.comSearch for more papers by this authorXuemin Zhang, Xuemin Zhang orcid.org/0000-0001-9246-1397 State Key Lab of Power System, Department of Electrical Engineering, Tsinghua University, Beijing, ChinaSearch for more papers by this authorShengwei Mei, Shengwei Mei orcid.org/0000-0002-2757-5977 State Key Lab of Power System, Department of Electrical Engineering, Tsinghua University, Beijing, ChinaSearch for more papers by this authorXiqiang Chang, Xiqiang Chang State Grid Xinjiang Electric Power Co., Ltd, Urumqi, ChinaSearch for more papers by this authorHua Chai, Hua Chai Department of Electrical Engineering, North China Electric Power University, Baoding, ChinaSearch for more papers by this authorRui Yin, Rui Yin State Grid Hebei Electric Power Co., Ltd, Shijiazhuang, ChinaSearch for more papers by this authorFei Wang, Fei Wang Department of Electrical Engineering, North China Electric Power University, Baoding, China State Key Laboratory of Alternate Electrical Power System with Renewable Energy Sources (North China Electric Power University), Beijing, ChinaSearch for more papers by this author First published: 06 September 2021 https://doi.org/10.1049/rpg2.12280AboutSectionsPDF ToolsRequest permissionExport citationAdd to favoritesTrack citation ShareShare Give accessShare full text accessShare full-text accessPlease review our Terms and Conditions of Use and check box below to share full-text version of article.I have read and accept the Wiley Online Library Terms and Conditions of UseShareable LinkUse the link below to share a full-text version of this article with your friends and colleagues. Learn more.Copy URL Share a linkShare onFacebookTwitterLinked InRedditWechat Abstract Solar irradiance is the main factor affecting the output of a photovoltaic (PV) power station, which is chiefly determined by the cloud distribution over the power station. For ultra-short-term, especially the intro-hour time scale irradiance forecasting, ground-based cloud image is considered as a very necessary data as Global Horizontal Irradiance (GHI). However, the information content in the image is much higher than that of GHI record, and there is even a difference in magnitude between them. Therefore, how to effectively extract the key features in the cloud images and fuse them with GHI record data is the decisive factor affecting the performance of the forecasting model. Here, a novel convolutional auto-encoder based cloud distribution feature (CDF) extraction method is first proposed. Then for feature fusion part, an LSTM-FUSION irradiance forecasting model is established based on long short-term memory (LSTM) neural network and feature fusion by time steps considering the one-to-one correlation between CDFs and GHI. Finally, a novel determination method of input time step length based on attention distribution analysis is also proposed. Simulation results show that the proposed LSTM-FUSION model is overall superior to the benchmark models. 1 INTRODUCTION With the development of modern society, the demand for electric energy is also increasing rapidly, while leading to very considerable fossil fuel consumption. This current situation has triggered many crises including environmental pollution, energy crisis, and global warming, which is clearly not conducive to the sustainable development of human society [1]. To deal with the above-mentioned crises, many countries and enterprises have been increasing their investment in the field of renewable energy and promoting the development of renewable energy generation, such as solar power generation and wind power generation. For solar power generation, its main form is photovoltaic (PV) power generation. The PV installed capacity increased rapidly and it increased from 40.29 GW in 2010 to 713.97 GW in 2020 according to data released by International Renewable Energy Agency (IRENA) [2]. Furthermore, it is worth mentioning that the penetration of PV power generation has been increasing due to its low cost or regulatory priority even when the covid-19 crisis resulted in the global downturn in electricity demand [3]. However, PV power generation basically determined by uncontrollable meteorological factors, which is significantly uncertain and intermittent. Thus, the rapidly increasing penetration scale is very detrimental to the security and economic operation of power grids. Mitigating the uncertainty of PV power generation is propitious to PV power consumption, and there are many related methods including dispatching hydropower [4], demand response [5-7], energy storage [8, 9] and PV power forecasting [10, 11]. For PV power forecasting, direct models predict PV power values directly, while the indirect models predict solar irradiance and other influence factors of PV power first and then predict the PV power using these factors [12]. Forecasting horizons of PV power forecasting models contain ultra-short term, short term, medium term, and long term [13]. Solar irradiance received by PV modules is instantaneously converted into electric energy according to PV effect, the output of PV power stations will fluctuate with the fluctuation of solar irradiance and solar irradiance is the most important meteorological factor affecting the output of PV power stations [14]. So accurate irradiance forecasting can significantly reduce the uncertainty of PV power forecasting [15]. Cloud distribution above PV power stations determines solar irradiance they received. Cloud movement is significantly uncontrollable, non-linear, and stochastic. When it is cloudy, solar irradiance is much fluctuated, which increases the difficulty of ultra-short-term forecasting. Thus, it is indispensable to introduce cloud information when predicting solar irradiance at the ultra-short scale. To meet the requirements of ultra-short-term forecasting modelling, sky cloud images are needed due to their high spatiotemporal resolution. Sky cloud images can generally be divided into satellite cloud images and ground-based cloud images (GBCIs). GBCIs are more commonly used due to the low spatiotemporal resolution [16, 17] or high cost [18] of satellite cloud images. In addition, because acquisition devices, acquisition locations and acquisition frequencies are different, the size and spatiotemporal resolution of GBCIs used in some studies are different [19-23]. At present, ultra-short-term irradiance forecasting works based on GBCIs can be divided into two categories. The research process of the first category of works can be summarized as two steps: one is cloud distribution prediction, the other is to constructing the mapping relationship between cloud distribution features (CDFs) from predicted cloud distributions and solar irradiance. Cloud distribution prediction contains cloud identification, cloud displacement estimation and cloud distribution prediction [24]. Because cloud distribution prediction is important, there are some literatures only focusing on it [25-28]. There are also some other literatures exploring the two steps, but the extracted CDFs (such as cloud index) and mapping relationships are generally simple [29-31]. Simple CDFs may be too simplified for representing cloud, and simple mapping expressions may not reflect the complex nonlinear relationship between CDFs and solar irradiance. To improve the non-linear mapping ability, a multilayer perceptron (MLP) has been developed to improve the accuracy of prediction [32]. The first type of works generally needs multiple image processing operations, which may cause relatively long research process and relatively difficult to complete. In addition, multiple operations may cause the error accumulation. The second type of works simplify the research process of the first type of works, especially CDFs are directly extracted from GBCIs without cloud distribution prediction. In some literature, CDFs are manually extracted according to the related knowledge, and then CDFs and other information including solar irradiance are directly connected in the input layer, namely simple feature fusion [33-35]. But manually extracted features may be not enough to make full use of the rich structural information in GBCIs. Therefore, some literature explores automatic CDF extraction by convolutional encoders. Convolutional encoder is a deep learning model which can automatically and effectively extract image features [36]. Some research uses convolutional encoders only to explore and verify the correlation between CDFs and PV output or irradiance, then to achieve mapping or forecasting [37, 38]. Some other studies use convolutional encoders to extract CDFs which were fused with irradiance sequences in a simple spliced manner, and then fit the complex relationship between fused features and irradiance sequences through MLP [19, 20, 22]. However, when MLP is used as the output layer, such feature fusion is not conducive to preserving the temporal relevance among information. According the above-mentioned literature, from the perspective of feature extraction, there is few works using a convolutional auto-encoder (CAE) to extract CDFs. Thus, a CDF extraction method based on CAE is proposed. Auto-encoder is kind of unsupervised deep learning model which can automatically extract low-dimension features [39], and CAE introducing convolutional operation is more favourable for image feature extraction [40]. From the perspective of feature fusion, temporal relevance among information is ignored due to simple connection in some previous works, which could make against improve the accuracy of forecasting. So, to solve this problem, an irradiance forecasting method based on LSTM and feature fusion by time steps is proposed, and the model to implement this method is constructed by a long short-term memory (LSTM) neural network and named LSTM-FUSION. LSTM is a deep learning model which can take account of the input time step relationship and deal with the problem of relatively long time series effectively [41]. The input of LSTM-FUSION is the sequence where CDF and global horizontal irradiance (GHI) are aligned in time steps and feature fusion by time steps is achieved in a hidden layer. In addition, three models are introduced as benchmarks, and they are named MLP-GHI, LSTM-GHI and LSTM-CDF respectively. MLP-GHI is constructed by MLP, while LSTM-CDF and LSTM-GHI are constructed by LSTM. MLP-GHI, LSTM-GHI and LSTM-CDF respectively take GHI sequences, GHI sequences and CDF sequences as input. MLP-GHI is the baseline model in this paper. On a real dataset, this paper uses the above four forecasting models to perform n-steps (n = 1, 2, …,6) predictions, that is, forecast the irradiance values in the next 10–60 min (the temporal resolution of the data is 10 min). The effectiveness and superiority of LSTM-FUSION is demonstrated through performance comparison. Moreover, considering the influence of input time step length on forecasting, a novel determination method of input time step length based on attention distribution analysis is proposed to determine the input time step length which is adopted by the above forecasting models in this paper. This method is implemented by a LSTM based on attention mechanism (AM), and this model is named LSTM-AM. AM can give more attention to useful information when training a model [42]. LSTM-AM can analyse the attention distribution of the influence of GHI in each time step on forecasting results. To sum up, the main contributions in this paper include: A feature extraction method based on CAE is proposed to extract CDFs from GBCIs without losing cloud information. A determination method of input time step length based on attention distribution analysis is proposed to determine the optimal input time step length. An irradiance forecasting method based on LSTM and feature fusion by time steps is proposed to maintain the temporal relationship between CDFs and GHI. The effectiveness and superiority of the proposed LSTM-FUSION model are verified compared with MLP-GHI, LSTM-GHI, and LSTM-CDF models. The rest of this paper is organized as follows. Section 2 describes the dataset and image preprocessing. Section 3 shows the research process, all mentioned methods and models, and assessment metrics. Section 4 presents the simulation and discussion. Finally, conclusions are drawn in Section 5. 2 DATA 2.1 Data description In a certain region, due to the similar geographical locale, PV outputs of two adjacent PV plants located at different places may exhibit similar time varying pattern, which defined as spatial similarity. In order to explore the correlations among several PV power output time series produced at different plants, temporal correlation which is seemed as the pairwise similarity on spatial dimension needs to be evaluated. In other words, for the sake of cloud motion, there will be a lagging or leading effect between two PV output time series corresponding to two adjacent plants, which is defined as temporal correlation. To facilitate understanding, PV power output data collected from plant A and plant B at the same period of time are selected and presented in Figure 1 with a distance of up to 19.6 kilometres. FIGURE 1Open in figure viewerPowerPoint GBCIs under different cloud conditions In this paper, the data for research and simulation are obtained from the National Renewable Energy Laboratory Solar Radiation Research Laboratory Baseline Measurement System [43], including GBCIs and GHI. While in practical engineering applications, the above data must be acquired by sky imager and radiometer equipment deployed in the PV station and may face the problem of inaccurate measurements. For GHI, if only a small amount of data is abnormal, it can be corrected by the interpolation method after elimination. If the data is missing for a long time, we can consider using the data of adjacent stations to fill in. However, no matter which method is used, inaccurate measurements will affect the forecasting accuracy for the proposed data-driven model. For GBCI, because it is the core key data to build the proposed forecasting model in this paper, inaccurate measurements may cause the model unavailable. The time resolution of GHI used in the paper is 1 min. For GBCIs, they are taken every 10 min by a device named TSI-880, in size of 352 × 288 pixels. According to the two acquisition frequencies, the sampling frequency is chosen as 10 min. Furthermore, the data is obtained from January 1 2013 to December 31 2014. At each sampling time point, a GHI value has a corresponding GBCI and the maximum GHI value is 1421.4 W/m2. Different cloud conditions are shown in Figure 1 The shadow band rotates as sun moves, which is aimed to prevent the sun area in the image from overexposure. In addition, the used dataset is divided into a training set, a validation set and a test set in chronological order, as shown as Table 1 The training set is used to train models, the validation set is used to choose models, and the test set is used to evaluate models. These three sets are similar in the GHI distributions, demonstrated as Figure 2 which can ensure that the evaluation results are reliable to some degree. TABLE 1. Time division of the dataset Dataset Time span Size Training set January 1 2013 to December 31 2013 26150 Validation set January 1 2014 to June 30 2014 13373 Testing set July 1 2014 to December 31 2014 12906 FIGURE 2Open in figure viewerPowerPoint GHI distributions in the training set, the validation set and the test set 2.2 Image preprocessing The aim of image preprocessing is to obtain the region of interest in an image, shown as Figure 3 where the sizes are indicated below each image. The process includes the following three steps: Preliminary noise filtering: choose a designated area (area within the white dotted line) that contains most sky information in a GBCI in Figure 3, then cut the area to get Figure 3. Precise noise filtering: point multiplication using the constructed binary matrix of Figure 3 and the pixel matrix of Figure 3, then the aimed image is obtained as shown Figure 3. Perform the above two-step operations on all original GBCIs. FIGURE 3Open in figure viewerPowerPoint The preprocessing of a GBCI The white region in Figure 3 represents the region of interest. The image like Figure 3 will be used as the input and output of the proposed CAE in what follows. 3 METHODOLOGY 3.1 Research process The research process in this paper contains three steps, as shown in Figure 4 Step 1 is the CDF extraction using the proposed CAE. Step 2 is determination of input time step length using LSTM-AM. Step 3 is to train, validate and evaluate LSTM-FUSION and the three benchmark methods including MLP-GHI, LSTM-GHI and LSTM-CDF. In step 3, n-step predictions can output n forecasting irradiance values. In addition, only the last value in a prediction sequence is evaluated when assessment. FIGURE 4Open in figure viewerPowerPoint Research flowchart of this paper 3.2 A cloud distribution feature extraction method based on convolutional auto-encoder The proposed CAE is shown as Figure 5 it is composed of a convolutional encoder and a convolutional decoder. At a time point for CDF extraction, a preprocessed GBCI is taken as the input and the output of the proposed CAE. The convolutional encoder consists of convolutional layers and pooling layers, and the convolutional decoder consists of transposed convolutional layers and convolutional layers. All layers in the proposed CAE are stacked sequentially. A convolutional layer can realize local connection and weight sharing, a pooling layer can realize down-sampling operation, and these three operations can help to extract image features efficiently while significantly reduce the parameters of model training [44]. A transposed convolutional layer can realize the up-sampling operation, and its calculation principle is the same as the convolution layer. The difference between a convolutional layer and a transposed convolutional layer is that the former can realize the down-sampling operation while the latter can realize the up-sampling operation [45]. In this CAE, the sampling operation achieved by pooling layers and transposed convolutional layers, while convolutional layers do not sample the input feature maps. When a GBCI is input to the CAE, the high-dimensional image information is first converted into low-dimensional CDFs by the convolutional encoder, and then the image information is reconstructed by the convolutional decoder using the CDFs. The extracted CDFs are used as input for LSTM-FUSION and LSTM-CDF. FIGURE 5Open in figure viewerPowerPoint The structure of the proposed CAE A convolutional layer and a transposed convolutional layer can be expressed as follows: y i , j , k l = ReLU w k l T x i , j l + b k l (1)where x i , j l is the input of location (i, j) in the l-th convolutional layer; w k l and b k l are the weight and the bias in the k-th convolutional kernel of the l-th convolutional layer, and w k l is shared across each region of the input. ReLU is the activation function for non-linear processing outputs of a convolutional layer, which can effectively improve the fitting ability of the model to a nonlinear relation [46]. A pooling layer can extract the effective information in the input feature map through down-sampling the output of a convolutional layer, it can be expressed as follows: P i , j , k l = maxpool y m , n , k l (2)where ( m , n ) ∈ R i , j , R i , j is the region around location (i, j); maxpoolmeans max pooling operation. When a feature map is fed into a pooling layer, its output has a quarter of the original size. Moreover, it should be noted that the CAE contains two non-computational layers including a flatten layer and a reshape layer, as shown in Figure 5 A flatten layer can flatten multi-dimension array into 1D array, and a reshape layer can reshape 1D array into multi-dimension array. 3.3 A determination method of input time step length based on attention distribution analysis The method in this subsection is implemented by LSTM-AM. The structure of a LSTM unit, the structure of a LSTM and AM and the structure of LSTM-AM are described below. LSTM is an improved variant of recurrent neural network (RNN), and it was proposed by Hochreiter and Schmidhuber in 1997 [47]. For RNN, gradient vanishing and gradient explosion are always suffered during fitting non-linear relationship among time series. LSTM successfully resolves the problem of gradient vanishing and effectively maintain useful time correlation features, because LSTM introduces gating mechanism which includes an input gate, a forget gate and an output gate, which makes it more suitable for longer time series prediction problems. The structure of a LSTM unit is shown as Figure 6 The working process of a LSTM unit is expressed as follows: f ( t ) = σ w f T · [ h ( t − 1 ) , x ( t ) ] + b f (3) i ( t ) = σ w i T · [ h ( t − 1 ) , x ( t ) ] + b i (4) g ( t ) = t a n h w g T · [ h ( t − 1 ) , x ( t ) ] + b g (5) c ( t ) = f ( t ) · c ( t − 1 ) + i t · g t (6) o ( t ) = σ w o T · [ h ( t − 1 ) , x ( t ) ] + b o (7) y ( t ) = h ( t ) = o ( t ) · tanh ( c ( t ) ) (8)where x ( t ) is the input data at time step t, y(t) is the output data at time step t, h(t) is the short-term state at time step t, c(t) is the long-term state at time step t, σ is sigmoid function, w and b are weight matrixes and biases of corresponding gates. The structure of LSTM is shown as Figure 7 where input sequences are sequentially entered into the LSTM network in chronological order. FIGURE 6Open in figure viewerPowerPoint The structure of a LSTM unit FIGURE 7Open in figure viewerPowerPoint The structure of a LSTM neural network AM is a way to select effective information, and it can give different attention distributions to all local information. AM can be described as follows: For N input vectors [ x 1 , x 2 , … , x N ] , the relevance between each input vector and the given query vector q is calculated using the given score function s( · ). Each score s(xi, q) (i = 1, 2, …, N) is fed into softmax function whose output is attention distribution α i . Attention output c is obtained by weighted mean calculation. AM in this paper is shown as Figure 8 and can be expressed as follows: s ( x i , q ) = v T · t a n h ( W · x i + U · q ) (9) α i = softmax ( s ( x i , q ) ) = exp ( s ( x i , q ) ) ∑ j = 1 N exp ( s ( x i , q ) ) (10) c = ∑ i = 1 N α i x i (11)where W, U and v are learnable matrices. FIGURE 8Open in figure viewerPowerPoint The structure of AM LSTM-AM sequentially contains two LSTM layers, an attention layer and a fully connected neuron, and it is shown as Figure 9 There are 13 units in each LSTM layer. The determination method of input time step length based on attention distribution analysis is achieved by LSTM-AM, and the procedures are described as follows: For LSTM-AM, the length of its input is m (m = 2, 3, …, 13) while its output is only one at the adjacent step, which means 12 models with different input lengths and the same output are trained using LSTM-AM. After training the 12 models, attention distribution sets are obtained and averaged by time steps. FIGURE 9Open in figure viewerPowerPoint The structure of LSTM-AM The attention distribution at each time step is shown as Figure 10 It can be seen from Figure 10 attention distributions basically show a decreasing trend over time steps, which is basically consistent with the intuitive feeling of the prediction problem. However, there is a small and unexpected rise at time step 9, so the input time step length of all forecasting models is determined as 8. FIGURE 10Open in figure viewerPowerPoint Attention distribution at each time step 3.4 An irradiance forecasting method based on LSTM and feature fusion by time steps The irradiance forecasting method based on LSTM and feature fusion by time steps is achieved by LSTM-FUSION which is described in this subsection. The number of units in the output layer of LSTM-FUSION n (n = 1, 2, …, 6) is equal to the forecasting step length. The difference among the structures of LSTM-FUSION performing n-step forecasting is only the number of units in an output layer, and so are three benchmark models. The structure of LSTM-FUSION performing 6-step forecasting is shown as Figure 11 and feature fusion by time steps contains following steps: Align CDFs and GHI by time steps in the input layer. In the first hidden layer, both input interfaces respectively receive CDFs and GHI in step 1, the shape of the corresponding features at each time step are respectively (1, 16) and (1, 8). In the concatenation layer without computational function, two kind of features at each time step are fused, whose shape is (1, 24). In the last hidden layer, the fused features are processed. The output generated by the last hidden layer is fed into the output layer, then 6-step forecasting is done. FIGURE 11Open in figure viewerPowerPoint The structure of LSTM-FUSION forecasting 6-step GHI 4 SIMULATION AND DISCUSSION 4.1 Simulation platform All simulations are built on the platform containing Intel(R) Core(TM) i9-9900X CPU@3.50 GHz, 64 GB RAM and a NVIDIA RTX 2080Ti GPU. All models are constructed by Keras and Python. For all the models in this paper, Adam is chosen as the optimizer [48], MSE is the loss function and epochs is 1000. For the proposed CAE, EarlyStopping and ReduceLROnPlateau are introduced to supervise the model's training, both of which can reduce the training time [50]. Thus, the number of the CAE's training epochs is 166 in fact, whose training process is shown as Figure 15 and training time is about 11.8 h. Moreover, 1.8 h is used to determine the input time step length and 2.5 h is used to train the remaining models. The setting of hyperparametres is determined by the basic Grid Search method according to the test results with actual data. For the structure of CAE, we have tested four model structures using the same dataset and found the best one for our method. The learning rate of the CAE is 0.001 and that of other models except CAE is 0.0002. For the dimension of CDF, the best forecasting accuracy can be achieved when the value is 16. 4.2 Benchmark models LSTM-CDF, LSTM-GHI and MLP-GHI are introduced as benchmark models and they respectively take CDF sequences, GHI sequences and GHI sequences as input. MLP-GHI is chosen as the baseline model. These three models forecasting 6-step GHI are shown as Figures 12, 13, and 14, respectively. Each hidden layer in LSTM-CDF, LSTM-GHI and MLP-GHI contains 16, 8 and 8 units, respectively. Moreover, for the five models except the proposed CAE, the activation function of each hidden layer is ReLU, and the output of each hidden layer passes through a batch normalization layer that can improve training speed and r