# A Hybrid Deep Learning-Based Load Forecasting Model for Logical Range
## 2 Materials and Methods
### Proposed Load Forecasting Methodology
#### 2.2.1 Spatial Feature Extraction  
Spatial feature extraction involves transforming the dataset from time-series data into image data via GAF encoding. Subsequently, a CNN extracts features from the resulting images, with feature optimization through channel attention mechanisms such as SENet [20]. 1. Image conversion. Figure 3: Processing pipeline of the GCSG model. Figure 2: Sliding window-based processing of device load data in Logical Range. GAF encoding is a visualization and feature extraction technique for time-series analysis and signal processing. It converts one-dimensional time-series data into two-dimensional images while preserving their temporal characteristics. In this study, the GAF approach is used to transform the input data \(\mathbf{x}_{i}^{w}\) within each dataset \(s_{i}^{w}\) of Logical Range load data into two-dimensional images, expanding the data dimensionality. Figure 4 illustrates the conversion process. The main steps of the GAF conversion process for Logical Range load data are as follows:  
1. Extract the input data \(\mathbf{x}_{i}^{w}\) from the dataset \(s_{i}^{w}\), where \(w\) is the length of \(\mathbf{x}_{i}^{w}\) and \(\mathbf{x}_{i}^{w}=[x_{i-w},x_{i-w+1},\ldots,x_{i}]\);
2. Convert \(\mathbf{x}_{i}^{w}\) to polar coordinates using Equation (5): \[ \begin{cases}\theta_{i}=\arccos(x_{i})\\ r_{i}=\frac{t_{i}}{T}\end{cases} ,\] (5) where \(r_{i}\) is the polar radius, \(t_{i}\) is the timestamp of \(x_{i}\), \(T\) is the total timestamp length, and \(\theta_{i}\) is the polar angle. Here, \(r_{i}\) preserves the temporal characteristics of the time-series data, while \(\theta_{i}\) retains the numerical variations. 3. Construct the GAF matrix \(g_{i}\) using the cosine function (Equation (6)), with dimensions \(w\times w\): \[g_{i}=\left[ \begin{array}{cccc}\cos(\theta_{1}+\theta_{1})&\cdots&\cos( \theta_{1}+\theta_{w})\\ \vdots&\ddots&\vdots\\ \cos(\theta_{w}+\theta_{1})&\cdots&\cos(\theta_{w}+\theta_{w})\end{array}  \right].\] (6)  
Compared to \(\mathbf{x}_{i}^{w}\), \(g_{i}\) enhances the correlations between load data values across different timestamps in the Logical Range. 2. Feature extraction. The CNN is a deep learning architecture that is primarily used for tasks involving structured data, such as image recognition, classification, and object detection. A CNN operates by applying convolutional operations to extract features from images, followed by pooling operations to reduce the dimensionality of the extracted features. CNNs can automatically learn and capture local features within images and exhibit certain invariance to translations, scaling, and other transformations, making them highly effective for image data processing [21]. The channel attention mechanism enhances the interaction of information between channels in CNN feature maps, helping to learn the importance of different channels [22]. SENet, as one type of channel attention mechanism, adaptively adjusts the weights of individual channels to improve the network's focus on essential features, thereby enhancing the CNN's feature representation capability [23]. Figure 4: Gramian Angular Field (GAF) -based conversion of Logical Range load data. The GCSG model employs a CNN to extract features from \(g_{i}\) and integrates SENet to adjust feature weights, thus improving the CNN's perception of important features. The specific process is as follows:  
1. Conduct successive convolution, activation, and pooling operations on \(g_{i}\) to obtain feature maps \(\mathbf{p}_{i}=[\mathbf{p}_{i,1},\mathbf{p}_{i,2},\ldots,\mathbf{p}_{i,c}]\), where the size of \(\mathbf{p}_{i}\) is \(h\times l\times c\) and \(c\) is the number of channels, with each channel containing a two-dimensional feature. 2.