## 3 Structure of the Proposed Models  
Traditional time series forecasting methods have a limited ability to extract nonlinear features since the majority of the current electricity load data contain nonlinear characteris  
Figure 4: Spatial attention structure.  
Figure 3: Channel attention structure.  
tics. We examine the nonlinear properties of electricity load data using the 2D-CNN model, which performs in a variety of fields. Before inputting the model, we transform the time series data into image data using GAF with a statistical interpretation since the 2D-CNN model performs incredibly well using the data input as images and has a very strong ability to extract features. The covariance matrix at various time points in GAF is represented by the Gram matrix. The matrix includes both the time series data and the relationships between the data at various time periods. The proposed model receives the time series data as the input, and to further simplify the training procedure, we add a double attention mechanism to the model to enhance the extracted features.  
Based on the above discussion, a novel, deep convolutional attention mechanism model for electricity load forecasting is proposed. The deep features of the input data are extracted using a deep convolutional network, and the extracted features are then filtered using channel attention and spatial attention, providing more weight to the features that are valuable and less weight to the features that are worthless. Multi-step ahead forecasting can be expressed as a prediction of \(\{X_{t+k}\}\) based on a given time series \(\{X_{t}\}\); here, \(t=1,2,\ldots,T\), \(k=1,2,\ldots,K\), and \(k\) is the forecast horizon. \(T\) is the total sample of the time series. Therefore, the proposed method forecasts the \((\{X_{t+1},X_{t+2},X_{t+3}\}\) electricity load horizons. Figure 5 illustrates the fundamental flowchart of the proposed model. In the preprocessing stage, the set of the time series is first deflated to the interval \(\left[\frac{1}{2},1\right]\), and then the deflated time series is transformed into images via GAF and the resulting image dataset is used as the input of the deep convolutional attention network. We then continuously adjust the weight parameters to obtain the final prediction results via backpropagation. More intricate mathematical expressions can be found in the following equations:  
\[Y_{1}^{(t,t)}=GAF(X_{t}) \tag{11}\]  
\[Y_{2}^{(\frac{t}{2},\frac{t}{2})}=\sigma(Conv2d(Y_{1}^{(t,t)})) \tag{12}\]  
\[Y_{3}^{(\frac{t}{2},\frac{t}{2})}=(SA(CA(Conv.unit(Y_{2}^{(\frac{t}{2},\frac{t} {2})})+Residual)\times 4 \tag{13}\]  
\[Y_{pre}=Linear(Y_{3}) \tag{14}\]  
Figure 5: Flowchart of the proposed model.  
Here, \(X_{t}\) denotes the time series observations; \(GAF(\cdot)\) denotes the transformation of the input matrix \(X_{t}\) into a Gram matrix with the size of \(t\times t\); \(\sigma\) denotes the activation function; \(Conv.unit(\cdot)\) indicates the convolution operation on the matrix from Section 2.2. CA means the attention operation on the input features stated in Section 2.3, and similarly, SA is the spatial attention operation. Finally, Equation (13) repeats the same structure four times, corresponding to the four identical tandem structures in Figure 5.