A photovoltaic cluster power short-term prediction method based on a lightweight space-time network

CN122452634BActive Publication Date: 2026-10-16KUNMING UNIV OF SCI & TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202610924870.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-06-25
Publication Date
2026-10-16
Estimated Expiration
2046-06-25

AI Technical Summary

Technical Problem

随着光伏电站规模化并网,传统单电站预测模型难以满足集群级功率调度需求,因此基于时空联合建模的预测方法成为研究热点

Benefits of technology

(1)本发明通过深度可分离卷积实现时序建模轻量化,将传统标准卷积分解为逐通道卷积与逐点卷积,在保持时序特征提取能力的前提下,显著降低模型参数量与计算复杂度,有效提升模型推理速度,更适用于资源受限的边缘计算与实时调度场景。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122452634B_ABST
    Figure CN122452634B_ABST
Patent Text Reader

Abstract

The application discloses a photovoltaic cluster power short-term prediction method based on a light-weighted space-time network and belongs to the technical field of photovoltaic power prediction. First, historical power of a photovoltaic cluster and meteorological information data are preprocessed to construct a space-time feature sequence, then after time-dimension features are extracted through a light-weighted time sequence convolution module, dynamic space weights are generated based on a static space adjacency matrix by introducing a light-weighted MLP dynamic edge learning mechanism, and an adaptive space adjacency matrix is obtained through weighted fusion; then, through a gated space-time feature fusion module, space-time features are adaptively weighted and fused, and in combination with layer normalization, sparse self-attention and residual connection to enhance features, a photovoltaic cluster short-term power prediction result is output based on the fused features. While ensuring prediction accuracy, the application reduces model parameter quantity and calculation overhead, significantly improves reasoning efficiency, and solves the problem that existing photovoltaic cluster prediction models are difficult to deploy in a resource-limited environment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the fields of photovoltaic power prediction, deep learning and spatiotemporal data modeling technology, specifically a method for short-term prediction of photovoltaic cluster power based on lightweight spatiotemporal networks. Background Technology

[0002] Photovoltaic cluster power prediction is a core technical support for the dispatching of new energy power plants and the stable operation of the power grid. With the large-scale grid connection of photovoltaic power plants, traditional single-power plant prediction models are difficult to meet the needs of cluster-level power dispatching. Therefore, prediction methods based on spatiotemporal joint modeling have become a research hotspot.

[0003] Existing photovoltaic cluster power prediction models, such as the ST-MoFNet model which combines graph convolution, multi-scale temporal modeling, and attention mechanisms, can effectively capture the spatiotemporal dependencies between photovoltaic power plants and achieve good prediction accuracy. However, they suffer from significant drawbacks, including complex model structure, large parameter size, high computational cost, and prolonged inference time. Graph convolution operations and multi-scale temporal modeling involve a large number of matrix calculations, and the introduction of attention mechanisms further increases the number of model parameters and computational burden. This makes it difficult to deploy the model efficiently in resource-constrained environments such as real-time scheduling systems and edge computing, severely limiting its engineering applications.

[0004] Traditional lightweight solutions often employ simple methods such as compressing network depth and reducing feature dimensions. While this reduces computational overhead, it significantly sacrifices prediction accuracy, failing to optimize model complexity and inference efficiency while maintaining stable prediction performance. Therefore, there is an urgent need for a short-term photovoltaic cluster power prediction method that can balance prediction accuracy and computational efficiency, and is suitable for resource-constrained scenarios, addressing the technical pain points of existing models being complex and difficult to deploy in engineering. Summary of the Invention

[0005] To address the aforementioned issues, this invention provides a short-term power prediction method for photovoltaic clusters based on lightweight spatiotemporal networks. Through three core strategies—lightweight temporal modeling, adaptive spatial modeling, and gated spatiotemporal feature fusion—this invention significantly reduces the number of model parameters and computational complexity while maintaining prediction accuracy close to that of complex models, thereby significantly improving inference efficiency. It achieves a balance between prediction performance and engineering practicality, and is applicable to real-time scheduling and edge computing scenarios for photovoltaic power plants.

[0006] To achieve the above objectives, the present invention provides the following technical solution: a method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks, specifically including the following steps: S1. Obtain historical power data and meteorological information data of photovoltaic clusters to construct the original dataset; after performing missing value imputation and normalization on the original dataset, the preprocessed historical power data and meteorological information data are obtained, and a spatiotemporal feature sequence for model training and prediction is constructed. S2. A lightweight temporal convolutional network based on depthwise separable convolution is used to extract the temporal dimension features in the spatiotemporal feature sequence and output the temporal dimension features. The lightweight temporal convolutional network L-TCN includes residual paths and main paths; S3. Based on the historical power data preprocessed in S1, a static spatial adjacency matrix is ​​constructed by calculating the maximum information coefficient (MIC) between power stations. Based on the historical power data preprocessed in S1, the power value of each photovoltaic power station at the current moment is extracted as a node feature. A dynamic edge learning mechanism is introduced to perform nonlinear mapping on the node features, and a dynamic spatial weight matrix is ​​generated by inner product calculation. The static spatial adjacency matrix and the dynamic spatial weight matrix are weighted and fused to obtain an adaptive spatial adjacency matrix. The adaptive spatial adjacency matrix and the node features are then aggregated by graph convolution to obtain spatial dimension features. S4. Input the temporal dimension features output from S2 and the spatial dimension features output from S3 into the gated fusion unit. Calculate the fusion weights through the gated network and perform adaptive weighted fusion of the temporal and spatial dimension features to obtain the preliminary fused features. Subsequently, perform layer normalization, multi-head sparse self-attention feature enhancement, and gated weighting adjustment on the preliminary fused features in sequence to output the weighted enhanced fused features. Finally, perform residual connection between the enhanced fused features and the preliminary fused features to output the enhanced fused spatiotemporal features. S5. Input the enhanced fusion spatiotemporal features output from S4 into the fully connected layer, and output the short-term power prediction results of the photovoltaic cluster, thus completing the construction of the LSTGNet model and the short-term power prediction method of the photovoltaic cluster based on the lightweight spatiotemporal network. The short-term power prediction results include: power prediction values ​​for the photovoltaic cluster in 1 step, 3 steps and 5 steps; the 1-step, 3-step and 5-step power prediction values ​​correspond to different engineering application scenarios, the 1-step prediction is used for real-time scheduling of the photovoltaic cluster, and the 3-step and 5-step predictions are used for short-term scheduling planning of the photovoltaic cluster.

[0007] S6. Based on the short-term power prediction results and the actual values, calculate the evaluation index, complete the error evaluation of the model prediction performance, and visualize the prediction results. The evaluation metrics include: root mean square error (RMSE), mean absolute error (MAE), and coefficient of determination (R²).

[0008] Furthermore, the lightweight temporal convolutional network in S2 adopts a depthwise separable convolutional structure, decomposing the traditional standard one-dimensional convolution into channel-wise convolution and pointwise convolution, thus reducing the number of parameters. Reduced to When the number of output channels is large, it can significantly reduce computational overhead and improve inference efficiency.

[0009] Furthermore, step S2 specifically includes the following steps: S2.1 Input the spatiotemporal feature sequence into the residual path composed of 1×1 convolutions and perform point-by-point convolutions, outputting the residual path convolution result; S2.2. Simultaneously input the spatiotemporal feature sequence into the main path, extract the temporal features sequentially through two layers of depthwise separable convolution, and output the deep temporal features; perform residual fusion by adding the deep temporal features with the residual path convolution result element by element, and output the time dimension features. The main path is composed of two layers of depthwise separable convolution stacked in sequence. Each layer of depthwise separable convolution is followed by Weight Norm weight normalization, ReLU nonlinear activation and Dropout random deactivation. The depthwise separable convolution includes channel-wise convolution and point-wise convolution; On the main path, the spatiotemporal feature sequence first undergoes a first-layer depthwise separable convolution, where channel-wise convolution and pointwise convolution are performed sequentially to extract temporal features. Then, Weight Norm, ReLU nonlinear activation, and Dropout are performed sequentially. Next, the sequence enters a second-layer depthwise separable convolution, where channel-wise convolution, pointwise convolution, Weight Norm, ReLU, and Dropout operations are repeated to further extract deep temporal features. Finally, the deep temporal features extracted by the second-layer Dropout are joined with the residual path convolution result element-wise to form a residual concatenation, outputting the temporal dimension features.

[0010] Furthermore, step S3 specifically includes the following steps: S3.1 Based on the historical power data preprocessed in S1, a static spatial adjacency matrix is ​​constructed by calculating the maximum information coefficient (MIC) between power stations. S3.2 Introducing a dynamic edge learning mechanism: Inputting node features into a lightweight MLP for nonlinear mapping, obtaining new node representations, and then generating a dynamic spatial weight matrix through inner product calculation; The node features are input into a lightweight MLP for nonlinear mapping to obtain the mapped node representation, as shown in the following expression: ; In the formula, For input node features, The node representation is mapped by a lightweight multilayer perceptron (MLP). The dynamic adjacency matrix is ​​calculated using the inner product, as shown in the following expression: ; In the formula, The dynamic spatial weight matrix is ​​generated through inner product calculation. This is a transpose operation; S3.3. The static spatial adjacency matrix and the dynamic spatial weight matrix are weighted and fused to obtain the adaptive spatial adjacency matrix; the adaptive spatial adjacency matrix and the node features are then aggregated by graph convolution to obtain the spatial dimension features. The expression for the adaptive spatial adjacency matrix is ​​as follows: ; In the formula, This is a static spatial adjacency matrix constructed based on the power information of photovoltaic power plants. For the real number field, For the number of photovoltaic power plants, It is an adaptive spatial adjacency matrix. The preset balance coefficient; Furthermore, step S4 specifically includes the following steps: S4.1 Gated fusion: The temporal and spatial features are concatenated along the feature dimension to obtain concatenated features. The concatenated features are then input into the first gating network to calculate the first gating weights. The first gating weights are used to adaptively weight and fuse the temporal and spatial features to obtain preliminary fused features. The expression for calculating the first gating weight is as follows: In the formula, for Activation function and These are the weight parameters and bias terms of the first gating network, respectively. For splicing operations, Features in the time dimension Spatial dimensional features, As the first gating weight; The temporal and spatial features are adaptively weighted and fused using the first gating weight to obtain the preliminary fused features, as shown in the following expression: In the formula, For element-wise multiplication, Preliminary fusion characteristics; S4.2 Feature Enhancement: The initial fused features are sequentially subjected to layer normalization, multi-head sparse self-attention feature enhancement, and gated weighting adjustment to obtain enhanced fused features; The expression for gated weighted adjustment is as follows: ; In the formula, As the second gating weight, For the learnable weight parameters of the second gating network, For the learnable bias term of the second gating network, This represents the features after attention enhancement; Enhanced fusion features are obtained The expression is: In the formula, To enhance the integration features.

[0011] S4.3 Residual Connection: Perform residual connection between the enhanced fusion features and the preliminary fusion features to output the enhanced fusion spatiotemporal features.

[0012] Furthermore, the prediction output in S5 supports multi-step prediction, including single-step prediction (pred_len=1), 3-step prediction (pred_len=3), and 5-step prediction (pred_len=5), to meet the different engineering requirements of real-time scheduling and medium- and long-term scheduling of photovoltaic clusters.

[0013] Furthermore, in S6, the root mean square error (RMSE) is used to measure the overall deviation between the predicted value and the true value, the mean absolute error (MAE) is used to measure the average error of the predicted value, and the coefficient of determination (R²) is used to measure the goodness of fit of the model.

[0014] The S6 uses RMSE, MAE, and R² as core evaluation metrics, and records the number of model parameters, inference latency, throughput, and FLOPs to comprehensively evaluate prediction accuracy and lightweight performance.

[0015] The present invention adopts the above technical solution and has the following beneficial effects compared with the prior art: (1) This invention achieves lightweight temporal modeling through depth-separable convolution, decomposing the traditional standard convolution into channel-wise convolution and point-wise convolution. While maintaining the ability to extract temporal features, it significantly reduces the number of model parameters and computational complexity, effectively improves the model inference speed, and is more suitable for resource-constrained edge computing and real-time scheduling scenarios.

[0016] (2) This invention proposes a lightweight spatial modeling method that combines static spatial structure with dynamic edge learning, which can adaptively capture the time-varying spatial correlation between photovoltaic power plants as weather and operating status change. Without significantly increasing computational overhead, it greatly improves the model's ability to express complex spatial dependencies and its predictive robustness.

[0017] (3) The present invention adopts a gated spatiotemporal feature fusion mechanism, replacing the traditional high-computation cross-modal attention structure with a low-complexity gated network, to achieve adaptive weighted fusion of temporal features and spatial dimension features, taking into account feature expression ability and model lightweighting, and effectively balancing prediction accuracy and inference efficiency.

[0018] (4) While maintaining the prediction accuracy close to that of a high-precision complex model, this invention achieves comprehensive optimization of model volume, inference delay and computational overhead. It can support short-term power prediction at multiple scales such as single step, 3 steps and 5 steps, meet the real-time scheduling requirements of photovoltaic clusters, and has stronger engineering practicality and deployment value. Attached Figure Description

[0019] Figure 1 This is an overall flowchart of the photovoltaic cluster power short-term prediction method based on lightweight spatiotemporal network proposed in this invention; Figure 2 This is a schematic diagram of the lightweight temporal convolutional module (L-TCN) in this invention; Figure 3 This is a schematic diagram of the lightweight spatial modeling module (LLSM) in this invention; Figure 4 This is a schematic diagram of the structure of the gated spatiotemporal feature fusion module (GSTFM) in this invention; Figure 5 This is a comparison chart of the prediction results in step 1 of this invention; Figure 6 This is a comparison chart of the prediction results in the three steps of this invention; Figure 7 This is a comparison chart of the 5-step prediction results in this invention. Detailed Implementation

[0020] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0021] Please see Figures 1-7 A method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks includes the following steps: S1. Obtain historical power data and meteorological information data of photovoltaic clusters to construct the original dataset; after performing missing value imputation and normalization on the original dataset, the preprocessed historical power data and meteorological information data are obtained, and a spatiotemporal feature sequence for model training and prediction is constructed. First, data preprocessing is performed. Missing values ​​in the original dataset are filled using linear interpolation. Then, Min-Max normalization is used to map the power and meteorological data to the [0, 1] interval to eliminate the influence of unit dimensions. Finally, a sliding window mechanism is used to construct samples: the historical backtracking window length is T (in this embodiment, T=10, 20, and 30 correspond to 150 minutes, 300 minutes, and 450 minutes respectively), and the predicted future length is P (P=1, 3, and 5, corresponding to 15 minutes, 45 minutes, and 75 minutes respectively), forming a spatiotemporal feature sequence for model input.

[0022] S2. A lightweight temporal convolutional network based on depthwise separable convolution is used to extract the temporal dimension features in the spatiotemporal feature sequence and output the temporal dimension features. The lightweight temporal convolutional network L-TCN includes residual paths and main paths; The number of parameters of the depthwise separable convolution is ,in, Input the number of channels. Number of output channels The kernel size is used for depthwise separable convolution. When the number of output channels is large, depthwise separable convolution can significantly reduce the number of model parameters and computational complexity, while maintaining the ability to extract temporal features and improving the model's inference efficiency.

[0023] Traditional TCN modules use standard one-dimensional convolution, and their parameter calculation method is as follows: This structure in When the value is large, the computational cost is enormous. To solve this problem, such as... Figure 2 As shown, this embodiment uses depthwise separable convolution instead of standard convolution. The lightweight temporal convolutional network L-TCN specifically includes the following steps: S2.1 Input the spatiotemporal feature sequence into the residual path composed of 1×1 convolutions and perform point-by-point convolutions, outputting the residual path convolution result; S2.2. Simultaneously input the spatiotemporal feature sequence into the main path, extract the temporal features sequentially through two layers of depthwise separable convolution, and output the deep temporal features; perform residual fusion by adding the deep temporal features with the residual path convolution result element by element, and output the time dimension features. The main path consists of two layers of depthwise separable convolutions stacked sequentially. Each layer of depthwise separable convolution is followed by Weight Norm weight normalization, ReLU nonlinear activation, and Dropout random deactivation. Deep spatiotemporal feature sequences are extracted through depthwise separable convolutions. The depthwise separable convolution includes channel-wise convolution and point-wise convolution; On the main path, the spatiotemporal feature sequence first undergoes a first-layer depthwise separable convolution, where channel-wise convolution and pointwise convolution are performed sequentially to extract temporal features. Then, Weight Norm, ReLU nonlinear activation, and Dropout are performed sequentially. Next, the sequence enters a second-layer depthwise separable convolution, where channel-wise convolution, pointwise convolution, Weight Norm, ReLU, and Dropout operations are repeated to further extract deep temporal features. Finally, the deep temporal features extracted by the second-layer Dropout are joined with the residual path convolution result element-wise to form a residual concatenation, outputting the temporal dimension features. Channel-wise convolution: Applying a single convolution to each input channel independently The convolutional kernel is used to extract the temporal dimension features within each channel, with a parameter count of [value missing]. ; Pointwise convolution: using The convolutional kernel linearly combines features along the channel dimension to achieve information fusion and dimensionality transformation between channels, with a parameter count of [number missing]. Through this decomposition, the total number of parameters is reduced from... Down to This significantly reduces the computational burden while maintaining modeling capabilities over a longer timeframe.

[0024] S3. Construct a static spatial adjacency matrix based on the power information of photovoltaic power plants, introduce a lightweight multilayer perceptron (MLP) to perform nonlinear mapping on node features, and generate a dynamic spatial weight matrix through inner product calculation; weightedly fuse the static spatial adjacency matrix and the dynamic spatial weight matrix to obtain an adaptive spatial adjacency matrix, which captures the spatial correlation between photovoltaic power plants over time with low overhead; perform graph convolution aggregation on the adaptive spatial adjacency matrix and node features to obtain spatial dimension features. like Figure 3 As shown, the specific steps include: S3.1 Based on the historical power data preprocessed in S1, a static spatial adjacency matrix is ​​constructed by calculating the maximum information coefficient (MIC) between power stations. This matrix serves as the basic spatial topology, reflecting the inherent geographical or electrical connections between power stations. First, based on the MIC coefficients between power plants, a static spatial adjacency matrix is ​​constructed using historical power data. , serving as the basic spatial structure; among which, For the real number field, This refers to the number of photovoltaic power plants.

[0025] S3.2 Introducing a dynamic edge learning mechanism: Inputting node features into a lightweight MLP for nonlinear mapping, and obtaining a new node representation, a dynamic spatial weight matrix is ​​generated through inner product calculation to capture the real-time dynamic changes in the spatial correlation between power stations caused by changes in meteorological conditions. This invention introduces a dynamic edge learning mechanism, which incorporates the node features at the current time step. C represents the number of channels. Inputting a lightweight multilayer perceptron (MLP) maps the new node representations as follows: ; The dynamic adjacency matrix is ​​calculated using the inner product, as shown in the following expression: ; In the formula, This is a transpose operation.

[0026] S3.3. The static spatial adjacency matrix and the dynamic spatial weight matrix are weighted and fused to obtain the adaptive spatial adjacency matrix; the adaptive spatial adjacency matrix and the node features are then aggregated by graph convolution to obtain the spatial dimension features. The final adaptive spatial adjacency matrix is ​​obtained. The calculation expression is as follows: ; In the formula, As a balancing factor, it is set to 0.7 in this embodiment to retain relatively stable static spatial topology information while adaptively capturing dynamic changes in the correlation between power stations caused by changes in meteorological conditions. This design adds only a very low number of parameters to the MLP, avoiding the high computational cost of a fully dynamic graph model.

[0027] S4. Input the temporal dimension features output from S2 and the spatial dimension features output from S3 into the gated fusion unit. Calculate the fusion weights through the gated network and perform adaptive weighted fusion of the temporal and spatial dimension features to obtain the preliminary fused features. Subsequently, perform layer normalization, multi-head sparse self-attention feature enhancement, and gated weighting adjustment on the preliminary fused features in sequence to output the weighted enhanced fused features. Finally, perform residual connection between the enhanced fused features and the preliminary fused features to obtain the final enhanced fused spatiotemporal features, thereby improving the feature representation capability. Traditional models employ cross-attention mechanisms for feature fusion, which are computationally intensive. This embodiment proposes a method... Figure 4 The gated spatiotemporal fusion module GSTFM shown below has the following specific steps: S4.1 Gated fusion: The temporal and spatial features are concatenated along the feature dimension to obtain concatenated features. The concatenated features are then input into the first gating network to calculate the first gating weights. The first gating weights are used to adaptively weight and fuse the temporal and spatial features to obtain preliminary fused features. Time dimension features and spatial dimensional features The features are concatenated along the feature dimension and input into the first gating network. The expression for calculating the first gating weight is as follows: in, for Activation function For the learnable weight parameters of the first gating network, For the learnable bias term of the first gating network, For the concatenation operation, output the first gating weight. .

[0028] Subsequently, the two types of features are adaptively weighted and fused to obtain preliminary fused features. The expression is as follows: In the formula, ⊙ represents element-wise multiplication.

[0029] S4.2 Feature Enhancement: After performing layer normalization on the initial fused features, a multi-head sparse self-attention mechanism is introduced to extract global dependencies. The attention output features are then dynamically weighted and adjusted using a gating mechanism to obtain enhanced features. To enhance the global expressive power of fused features while controlling computational load, this embodiment introduces a lightweight enhancement mechanism: for Layer normalization is performed; a multi-head sparse self-attention mechanism is used to extract global dependencies, which reduces the complexity from O(L²) to O(L·log(L)) (L is the sequence length) compared to traditional self-attention.

[0030] Using gating mechanisms again for attention features The dynamic weighted adjustment is calculated using the following expression: ; In the formula, As the second gating weight, For the learnable weight parameters of the second gating network, For the learnable bias term of the second gating network; The weighted enhanced fusion features The expression is: ; S4.3 Residual Connection: Perform residual connection between the enhanced fusion features and the preliminary fusion features to output the enhanced fusion spatiotemporal features; Finally, the enhanced features With initial fusion characteristics Residual connections are performed to obtain the final output features, namely, the enhanced fused spatiotemporal features. Residual connections effectively alleviate the vanishing gradient problem and involve only element-wise addition, resulting in extremely low computational overhead.

[0031] S5, Power Prediction Output: Enhanced fused spatiotemporal features output from step S4. The input is fed into the output module, which consists of fully connected layers. These fully connected layers then map the features to the final prediction dimension, outputting the power predictions for the photovoltaic cluster in the next 1, 3, and 5 steps. .

[0032] S6. Error Assessment and Visualization: To objectively evaluate the effectiveness of this invention, it was compared with existing technologies on the same test set. The comparison objects included: the complex ST-MoFNet model, LiteSTGCN relying only on static graph structures, LiteGCN-LSTM, and the temporal-only LSTM model. Evaluation metrics included prediction accuracy (RMSE, MAE, R²) and computational efficiency (number of parameters, inference latency, throughput, number of floating-point operations (FLOPs)).

[0033] The root mean square error (RMSE) measures the overall deviation between the predicted and actual values, the mean absolute error (MAE) measures the average error of the predicted values, and the coefficient of determination (R²) measures the goodness of fit of the model. The closer R² is to 1, the better the model's predictive performance. The visualization uses curve comparison to plot the curves of the predicted and actual values, resulting in comparison charts for 1-step, 3-step, and 5-step predictions. This intuitively presents the model's prediction effect and provides a clear basis for model performance evaluation and optimization.

[0034] This embodiment uses mean squared error (MSE) as the loss function and the Adam optimizer for model training. The initial learning rate is set to 0.001, and the batch size is set to 64. The model training lasts for 100 epochs.

[0035] (1) Comparison of prediction accuracy The experimental results are shown in Tables 1 to 3. The experiments demonstrate that the LSTGNet model of this invention significantly outperforms lightweight baseline models such as LSTM and LiteSTGCN in accuracy across all prediction step sizes. In 1-step prediction, LSTGNet achieves an RMSE of 15.946, a MAE of 10.926, and an R² of 0.915; in 5-step prediction, the RMSE is 22.743, and the R² is 0.828. Compared to the highly complex ST-MoFNet model, the LSTGNet of this invention shows a difference of only 0.376 in RMSE during the 5-step prediction task, indicating that this invention successfully maintains near-optimal prediction performance while significantly reducing complexity.

[0036] Table 1: One-Step Prediction Indicators Table 2: 3-Step Prediction Indicators Table 3: 5-Step Prediction Indicators like Figures 5 to 7 As shown, the predicted curve of LSTGNet closely matches the actual curve, especially in the peak and valley regions where power fluctuates rapidly, and its tracking ability is significantly better than other lightweight models.

[0037] (2) Comparison of computational efficiency In terms of model lightweighting, this invention has significant advantages: Parameter count: LSTGNet has approximately 29,000 parameters, only one-quarter of ST-MoFNet (116,000). Computational complexity: LSTGNet's FLOPs are controlled between 42.15M and 67.69M, far lower than ST-MoFNet's 193.46M to 562.24M. Inference efficiency: LSTGNet's inference latency in single-step prediction is 0.864 ms / batch, and its throughput reaches 296,298 samples / s, both superior to ST-MoFNet (1.360 ms / batch, 188,209 samples / s), demonstrating excellent real-time processing capabilities.

[0038] (3) Ablation experiment verification To verify the effectiveness of each module, an ablation experiment was conducted in this embodiment (as shown in Table 4-6): Removing LLSM: The model's RMSE increased from 22.743 to 28.250 in the 5-step prediction task, validating the key role of the dynamic side learning mechanism in capturing time-varying spatial correlations.

[0039] Removing L-TCN: After adopting the standard TCN, the model FLOPs increased significantly (from 67.69M to 100.75M in the 5-step task), while the accuracy decreased slightly, demonstrating the advantage of lightweight temporal convolution in maintaining performance and reducing complexity.

[0040] Removing GSTFM: After using simple feature addition, the RMSE of the 5-step prediction increased sharply from 22.743 to 29.062, indicating that the gating fusion mechanism is crucial for the adaptive integration of spatiotemporal features.

[0041] In summary, this invention, through three core lightweight designs—L-TCN, LLSM, and GSTFM—successfully solves the problems of complex models and high resource consumption in existing technologies while ensuring prediction accuracy. Experimental data demonstrates that this method achieves an excellent balance between prediction performance and computational efficiency, possessing extremely high engineering practical value and promising prospects for widespread application.

[0042] Table 4: Experimental Indicators for Step 1 Ablation Experiment Table 5: Predictive Indicators for the Three-Step Ablation Experiment Table 6: Predictive Indicators of the 5-Step Ablation Experiment Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks, characterized in that, Includes the following steps: S1. Obtain historical power data and meteorological information data of photovoltaic clusters to construct the original dataset; after performing missing value imputation and normalization on the original dataset, the preprocessed historical power data and meteorological information data are obtained, and a spatiotemporal feature sequence for model training and prediction is constructed. S2. A lightweight temporal convolutional network based on depthwise separable convolution is used to extract the temporal dimension features in the spatiotemporal feature sequence and output the temporal dimension features. The lightweight temporal convolutional network L-TCN includes residual paths and main paths; S2.1 Input the spatiotemporal feature sequence into the residual path composed of 1×1 convolutions and perform point-by-point convolutions, outputting the residual path convolution result; S2.

2. Simultaneously input the spatiotemporal feature sequence into the main path, extract the temporal features sequentially through two layers of depthwise separable convolution, and output the deep temporal features; perform residual fusion by adding the deep temporal features with the residual path convolution result element by element, and output the time dimension features. The main path is composed of two layers of depthwise separable convolution stacked in sequence. Each layer of depthwise separable convolution is followed by Weight Norm weight normalization, ReLU nonlinear activation and Dropout random deactivation. S3. Based on the historical power data preprocessed in S1, a static spatial adjacency matrix is ​​constructed by calculating the maximum information coefficient (MIC) between power stations. Based on the historical power data preprocessed in S1, the power value of each photovoltaic power station at the current moment is extracted as a node feature. A dynamic edge learning mechanism is introduced to input the node features into a lightweight MLP for nonlinear mapping, and a dynamic spatial weight matrix is ​​generated by inner product calculation. The static spatial adjacency matrix and the dynamic spatial weight matrix are weighted and fused to obtain an adaptive spatial adjacency matrix. The adaptive spatial adjacency matrix and the node features are then aggregated by graph convolution to obtain spatial dimension features. S4. The temporal features output from S2 and the spatial features output from S3 are concatenated along the feature dimension. The first gating weight is calculated through the first gating network, and the temporal and spatial features are adaptively weighted and fused to obtain the preliminary fused features. Subsequently, the preliminary fused features are subjected to layer normalization, multi-head sparse self-attention feature enhancement, and second gating weight adjustment in sequence to output the weighted enhanced fused features. Finally, the enhanced fused features and the preliminary fused features are residually connected to output the enhanced fused spatiotemporal features. The expression for the second gated weighted adjustment is as follows: ; In the formula, As the second gating weight, For the learnable weight parameters of the second gating network, For the learnable bias term of the second gating network, This represents the features after attention enhancement; S5. Input the enhanced fusion spatiotemporal features output from S4 into the fully connected layer, and output the short-term power prediction results of the photovoltaic cluster, thus completing the construction of the LSTGNet model and the short-term power prediction method of the photovoltaic cluster based on the lightweight spatiotemporal network. S6. Based on the short-term power prediction results and the actual values, calculate the evaluation index, complete the error evaluation of the model prediction performance, and visualize the prediction results. The evaluation metrics include: root mean square error (RMSE), mean absolute error (MAE), and coefficient of determination (R²).

2. The method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks according to claim 1, characterized in that, In S2, the number of parameters of the depthwise separable convolution is ,in, Input the number of channels. Number of output channels is the kernel size.

3. The method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks according to claim 1, characterized in that, In S2, the depthwise separable convolution includes channel-wise convolution and pointwise convolution. On the main path, the spatiotemporal feature sequence first passes through the first layer of depthwise separable convolution, where channel-wise convolution and pointwise convolution extract temporal features sequentially. Then, weight normalization, ReLU nonlinear activation, and Dropout random deactivation are performed sequentially. Next, the sequence enters the second layer of depthwise separable convolution, where channel-wise convolution, pointwise convolution, weight normalization, ReLU, and Dropout operations are repeatedly performed to further extract deep temporal features. Finally, the deep temporal features extracted by the second layer Dropout are joined with the residual path convolution result element-wise by residual convolution to output the temporal dimension features.

4. The method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks according to claim 1, characterized in that, S3 specifically includes the following steps: S3.1 Based on the historical power data preprocessed in S1, a static spatial adjacency matrix is ​​constructed by calculating the maximum information coefficient (MIC) between power stations. S3.2 Introducing a dynamic edge learning mechanism: Inputting node features into a lightweight MLP for nonlinear mapping, obtaining new node representations, and then generating a dynamic spatial weight matrix through inner product calculation; The node features are input into a lightweight MLP for nonlinear mapping to obtain the mapped node representation, as shown in the following expression: ; In the formula, This is the node representation after mapping by a lightweight multilayer perceptron (MLP). For input node features; The dynamic adjacency matrix is ​​calculated using the inner product, as shown in the following expression: ; In the formula, The dynamic spatial weight matrix is ​​generated through inner product calculation. This is a transpose operation; S3.

3. The static spatial adjacency matrix and the dynamic spatial weight matrix are weighted and fused to obtain the adaptive spatial adjacency matrix; the adaptive spatial adjacency matrix and the node features are then aggregated by graph convolution to obtain the spatial dimension features. The expression for the adaptive spatial adjacency matrix is ​​as follows: ; In the formula, To preset the balance coefficient, This is a static spatial adjacency matrix constructed based on the power information of photovoltaic power plants. For the real number field, For the number of photovoltaic power plants, It is an adaptive spatial adjacency matrix.

5. The method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks according to claim 1, characterized in that, S4 specifically includes the following steps: S4.

1. The time dimension features and spatial dimension features are concatenated along the feature dimension to obtain the concatenated features. The concatenated features are then input into the first gating network to calculate the first gating weights. The first gating weights are used to adaptively weight and fuse the time dimension features and spatial dimension features to obtain the preliminary fused features. The expression for calculating the first gating weight is as follows: In the formula, for Activation function and These are the weight parameters and bias terms of the first gating network, respectively. For splicing operations, Features in the time dimension Spatial dimensional features, As the first gating weight; The temporal and spatial features are adaptively weighted and fused using the first gating weight to obtain the preliminary fused features, as shown in the following expression: In the formula, As a preliminary fusion feature, This is element-wise multiplication; S4.2 The initial fusion features are successively subjected to layer normalization, multi-head sparse self-attention feature enhancement, and second gating weighting adjustment to obtain enhanced fusion features; Enhanced fusion features are obtained The expression is: In the formula, To enhance fusion features; S4.

3. Perform residual connection between the enhanced fusion features and the preliminary fusion features to output the enhanced fusion spatiotemporal features.

6. The method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks according to claim 1, characterized in that, In step S5, the short-term power prediction results include: power prediction values ​​for the photovoltaic cluster in the next 1 step, 3 steps, and 5 steps; the 1-step, 3-step, and 5-step power prediction values ​​correspond to different engineering application scenarios, with the 1-step prediction used for real-time scheduling of the photovoltaic cluster, and the 3-step and 5-step predictions used for short-term scheduling planning of the photovoltaic cluster.

7. The method for short-term power prediction of photovoltaic clusters based on lightweight spatiotemporal networks according to claim 1, characterized in that, In S6, the root mean square error (RMSE) is used to measure the overall deviation between the predicted value and the true value, the mean absolute error (MAE) is used to measure the average error of the predicted value, and the coefficient of determination (R²) is used to measure the goodness of fit of the model.

Citation Information

Patent Citations

  • Wind power generation power prediction method and system based on deep learning

    CN121124025A

  • Distributed photovoltaic ultra-short-term solar irradiance prediction method based on multi-scale spatial-temporal feature fusion

    CN121615066A