Method and system for multi-station photovoltaic power prediction based on efficient fine-tuning of large language model

By using sequence segmentation and multidimensional structured coding techniques, multi-site time-series data is transformed into a structured representation that is easy for large language models to process. By adopting an efficient fine-tuning strategy, the problems of high computational cost and positional coding confusion in multi-site photovoltaic power prediction are solved, achieving accurate and efficient multi-site photovoltaic power prediction and expanding the application of large language models in the field of industrial time series.

CN121682459BActive Publication Date: 2026-06-09ZHEJIANG UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG UNIV
Filing Date
2026-02-12
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

Existing photovoltaic power prediction methods suffer from high computational costs, data adaptation difficulties, and location coding confusion when dealing with joint prediction of multiple photovoltaic power plants, resulting in insufficient ability of the model to accurately characterize the spatiotemporal characteristics of multiple power plants.

Method used

By employing sequence segmentation and multidimensional structured coding techniques, multi-site time-series data is transformed into a structured representation that is easy for large language models to process. Furthermore, through an efficient fine-tuning strategy, the original positional coding of the large language model is bypassed, and only a few specific layers are fine-tuned, enabling rapid adaptation to multi-site prediction tasks.

Benefits of technology

It significantly reduced training costs, enabled accurate and efficient prediction of photovoltaic power from multiple power plants, expanded the application scenarios of large language models in industrial time series fields, and provided reliable data support for the coordinated operation and economic scheduling of multi-power plant systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121682459B_ABST
    Figure CN121682459B_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on the efficient fine-tuning of large language model Multi-site photovoltaic power prediction method and system.Method includes: obtaining the historical photovoltaic power time series data of multiple sites in target period, and pre-processing, obtain sequence block tensor;Sequence block tensor is input into the multi-site photovoltaic power prediction model trained by efficient fine-tuning strategy, first, sequence block tensor is encoded into structured coding tensor containing power value, site identity and time by multidimensional structured coding layer, then the deep feature is extracted by the feature extraction network with the pre-training large language model as core, then the deep feature is mapped to the prediction dimension by linear output layer, and the multi-site photovoltaic power prediction result is obtained.The present application makes full use of the powerful sequence modeling capability of large language model, realizes the accurate prediction of multi-site photovoltaic power through the structure adjustment and efficient fine-tuning strategy for multi-site input.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of new energy power prediction in power systems, and relates to a method and system for predicting photovoltaic power at multiple power plants, and more particularly to a method and system for predicting photovoltaic power at multiple power plants based on efficient fine-tuning of a large language model. Background Technology

[0002] With the rapid increase in the penetration rate of photovoltaic (PV) power generation in the power system, its inherent volatility and intermittency pose a significant challenge to the safe and stable operation of the power grid. Accurate power forecasting is a key technology for addressing this challenge and improving PV absorption capacity. Especially in regional power grids, there are numerous distributed PV power plants, which exhibit both independent characteristics and spatiotemporal correlations due to macro-meteorological influences. Therefore, developing a multi-site PV power forecasting method capable of joint modeling has greater practical significance and application value compared to traditional single-site forecasting.

[0003] In the development of prediction technology, traditional time series models and early recurrent neural networks have limited ability to capture complex nonlinear dynamics and long-term dependencies. Although Transformer-based models have improved sequence modeling capabilities, they still struggle to explicitly distinguish between the "time step" and "variable (station)" dimensions when dealing with multivariate (multi-station) inputs, limiting their ability to finely characterize the spatiotemporal characteristics of multi-station systems.

[0004] The emergence of large language models has brought a breakthrough to sequence modeling, and its capabilities have become increasingly applicable to time series prediction. However, this transfer faces three major obstacles: First, large language models have a large number of parameters, making full fine-tuning computationally expensive; second, large language models are designed for discrete text, and transforming continuous multi-site time series data into an input representation that can be effectively processed by large language models is a challenge; third, the native positional encoding of large language models cannot distinguish between time sequence and site (variable) index, causing confusion in understanding "when" and "where". Therefore, a new technological solution is urgently needed to address these issues and enable the efficient and accurate application of large language models in multi-site prediction tasks. Summary of the Invention

[0005] To address the limitations of existing photovoltaic power prediction methods when handling joint prediction of multiple photovoltaic power plants, this invention aims to provide a method and system for multi-plant photovoltaic power prediction based on efficient fine-tuning of a large language model. This invention utilizes a pre-trained large language model, employing innovative sequence segmentation and multi-dimensional structured coding techniques to transform multi-plant time-series data into a sequence representation easily processed by the large language model. Furthermore, it employs an efficient fine-tuning strategy, bypassing the original positional encoding of the large language model and freezing its core parameters, fine-tuning only a few specific layers to achieve rapid adaptation to downstream multi-plant prediction tasks. This invention fully leverages the powerful sequence modeling capabilities of the large language model, while significantly reducing training costs through targeted input structures and fine-tuning strategies, achieving accurate and efficient prediction of photovoltaic power from multiple plants.

[0006] To achieve the above objectives, the present invention proposes the following technical solution:

[0007] A method for predicting photovoltaic power from multiple power plants based on efficient fine-tuning of a large language model includes the following steps:

[0008] Historical photovoltaic power time-series data from multiple power stations within the target time period are acquired, and then standardized and processed into sequence blocks to obtain sequence block tensors.

[0009] The sequence block tensor is input into a multi-site photovoltaic power prediction model trained with an efficient fine-tuning strategy to obtain the multi-site photovoltaic power prediction results;

[0010] The multi-site photovoltaic power prediction model includes a multi-dimensional structured coding layer, a feature extraction network, and a linear output layer connected in sequence.

[0011] The multidimensional structured coding layer is used to encode the sequence block tensor into a structured coding tensor containing power values, station identity information, and time information;

[0012] The feature extraction network uses a pre-trained large language model as its core to perform deep feature extraction on the structured coding tensor; wherein the structured coding tensor skips the native positional encoding module of the large language model when it is input.

[0013] The linear output layer is used to map the deep features to the prediction dimension and output the photovoltaic power prediction results for multiple sites.

[0014] Furthermore, the standardization and sequence segmentation processing specifically includes:

[0015] The historical photovoltaic power time series data of each power station is standardized. The standardized historical photovoltaic power time series data of each power station is then truncated along the time dimension by a sliding window with a preset block size and block step size to form a sequence block tensor. For data at the end of the time series that is not enough to form a complete block, a copying and padding method is used to complete it.

[0016] Furthermore, the multidimensional structured coding layer includes a trainable variable embedding matrix, a trainable linear value embedding layer, and a trainable temporal embedding matrix; the variable embedding matrix is ​​used to provide the identity code of each photovoltaic power station; the linear value embedding layer is used to project the block data fused with the identity code to the model's hidden space; and the temporal embedding matrix is ​​used to provide the absolute temporal location code of each block.

[0017] Furthermore, the step of generating the structured coding tensor in the multidimensional structured coding layer includes:

[0018] Based on the station identity information, the corresponding identity code is obtained from the variable embedding matrix and fused with the sequence block tensor;

[0019] The block tensor after identity encoding is projected through the linear value embedding layer to a hidden dimension that matches the input dimension of the feature extraction network to obtain the value embedding tensor.

[0020] Based on the time position of the block, the corresponding time code is obtained from the time embedding matrix and fused with the value embedding tensor to obtain a structured coding tensor;

[0021] The structured coding tensor is then reshaped into the input sequence format required by the feature extraction network.

[0022] Furthermore, the fusion of identity encoding with sequence block tensors and the fusion of time encoding with value embedding tensors are both achieved through a broadcast mechanism, using element-wise addition.

[0023] Furthermore, the pre-trained large language model includes a word embedding layer, a position encoding layer, multiple Transformer layers, and a final normalization layer connected in sequence; wherein, the feature extraction network bypasses the word embedding layer and position encoding layer of the large language model through a bypass mechanism, and directly inputs the structured encoding tensor into the multiple Transformer layers for deep feature extraction.

[0024] Furthermore, the process of training the multi-site photovoltaic power prediction model using an efficient fine-tuning strategy includes:

[0025] Prepare the training and validation datasets;

[0026] Freeze the parameters of the self-attention modules and feedforward neural network modules within all Transformer layers of the pre-trained large language model in the feature extraction network;

[0027] The parameters of the multidimensional structured coding layer, the linear output layer, and all layer normalization components in the large language model are set to be trainable; the layer normalization components include the layer normalization modules inside each Transformer layer and the final normalization layer.

[0028] Using the mean squared error as the loss function, the trainable parameters are iteratively optimized using the gradient descent method to finally obtain a well-trained multi-site photovoltaic power prediction model.

[0029] A multi-site photovoltaic power prediction system based on efficient fine-tuning of a large language model includes:

[0030] The data processing module is used to acquire historical photovoltaic power time-series data from multiple power stations within the target time period, and to perform standardization and sequence block processing to obtain sequence block tensors;

[0031] A multidimensional structured encoding module is used to encode the sequence block tensor into a structured encoded tensor containing power values, station identification information, and time information;

[0032] The feature extraction module, based on a pre-trained large language model, is used to perform deep feature extraction on the structured coding tensor; wherein the structured coding tensor skips the native positional coding module of the large language model when input;

[0033] The result output module is used to map the deep features to the prediction dimension and output the photovoltaic power prediction results for multiple sites.

[0034] A computer device, the computer device comprising:

[0035] One or more processors;

[0036] Memory, used to store one or more programs;

[0037] When the one or more programs are executed by the one or more processors, the one or more processors implement the above-described method for predicting photovoltaic power at multiple sites based on efficient fine-tuning of a large language model.

[0038] A computer-readable storage medium storing computer instructions that, when executed by one or more processors, cause the one or more processors to perform the steps in the method described above.

[0039] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0040] First, this invention employs sequence segmentation and multi-dimensional structured coding mechanisms to explicitly fuse multi-site time-series data with their respective time locations and site information, constructing a structured input representation suitable for large language models. This solves the adaptation problem between continuous time-series data and the discrete text modality of large language models, and clearly distinguishes between "when" and "where" information. Second, this invention uses a pre-trained large language model as the core feature extractor and designs a bypass mechanism to allow it to skip the original positional coding. This enables it to rely entirely on the constructed custom coding, which contains rich temporal and variable information, achieving deep modeling of multivariate time-series data by the large language model. Finally, by configuring an efficient fine-tuning strategy—freezing the main parameters of the large language model and training only the layer normalization and newly added coding layers—the computational overhead and time cost of model fine-tuning are greatly reduced, and overfitting on small-scale time-series data is effectively prevented. This achieves low-cost and high-efficiency transfer of pre-trained knowledge to multi-site prediction tasks. This invention expands the application scenarios of large language models in the industrial time series field. Through accurate and efficient joint prediction of multiple sites, it provides reliable data support for the coordinated operation and economic scheduling of multi-site systems with high proportion of distributed photovoltaic penetration. Attached Figure Description

[0041] Figure 1 This is a flowchart of a multi-site photovoltaic power prediction method based on efficient fine-tuning of a large language model, as described in an embodiment of the present invention.

[0042] Figure 2 This is a diagram showing the fine-tuning structure of a large language model used for multi-site photovoltaic power prediction in an embodiment of the present invention.

[0043] Figure 3 This is a data processing flow and structure diagram of the multi-site photovoltaic power prediction model in an embodiment of the present invention.

[0044] Figure 4 The photovoltaic power prediction curve of a certain power station under the joint prediction of multiple power stations is shown in the specific embodiment of the present invention. Detailed Implementation

[0045] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, 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, not all, of the embodiments of the present invention. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of the present invention.

[0046] A method for predicting photovoltaic power from multiple power plants based on efficient fine-tuning of a large language model includes the following steps:

[0047] Historical photovoltaic power time-series data from multiple power stations within the target time period are acquired, and then standardized and processed into sequence blocks to obtain sequence block tensors.

[0048] The sequence block tensor is input into a multi-site photovoltaic power prediction model trained with an efficient fine-tuning strategy to obtain the multi-site photovoltaic power prediction results;

[0049] The multi-site photovoltaic power prediction model includes a multi-dimensional structured coding layer, a feature extraction network, and a linear output layer connected in sequence.

[0050] The multidimensional structured coding layer is used to encode the sequence block tensor into a structured coding tensor containing power values, station identity information, and time information;

[0051] The feature extraction network uses a pre-trained large language model as its core to perform deep feature extraction on the structured coding tensor; wherein the structured coding tensor skips the native positional encoding module of the large language model when it is input.

[0052] The linear output layer is used to map the deep features to the prediction dimension and output the photovoltaic power prediction results for multiple sites.

[0053] In one specific embodiment of the present invention, the construction and training process of the multi-site photovoltaic power prediction model is as follows: Figure 1 , Figure 2 As shown, it specifically includes:

[0054] Step 1: First, acquire historical photovoltaic power time series data of multiple power stations within the target time period, and perform standardized sliding window sampling to construct a supervised learning sample set; then, divide the input sequence into blocks along the time dimension to obtain the sequence block tensor, which serves as the basic unit for encoding.

[0055] Assume the original multi-site time series data is ,in For a moment The photovoltaic output value, The total duration of the photovoltaic power output data. The number of photovoltaic power plants; time series data for multiple power plants. Standardization process:

[0056]

[0057] in, This represents the actual photovoltaic output of the m-th power station at time t. and The first The mean and standard deviation of the actual power output data of each power station. Let be the standardized photovoltaic output at time t of the m-th power station; let the length of the input photovoltaic output history sequence be . The predicted photovoltaic power output sequence length is Construct a sliding window sample set , where input samples , For the photovoltaic output of all power stations after time t is standardized, the target sample ,in This refers to the moment the data is slid to. During training, the sample set... Divide into small batches and ,in This refers to the batch size.

[0058] Next, the input time series data is divided into blocks for processing, specifically as follows:

[0059] Let the block size be The block size is First, for batch input Rearranged, becoming and along the time dimension Apply copy padding to make the sequence length Become This ensures that the data at the end of the sequence can be completely segmented; secondly, the padded sequence... Perform the unfolding operation, that is, along the time dimension. With step size The sliding size is The window; generates sequence block tensors ,in The number of blocks generated. , Indicates rounding down.

[0060] Step 2: Construct a multi-dimensional structured coding layer. Through a multi-dimensional structured coding mechanism, variable encoding, value embedding, and time encoding are performed on different stations to obtain a structured coding tensor including power values, station identity information, and time information, which serves as the input to the large language model.

[0061] The mechanism first fuses the identity code representing the station's identity with the original numerical values ​​of the sequence block tensor through a variable embedding layer; second, it projects the fused block tensor onto the core hidden dimension of the large language model through a linear value embedding layer; finally, it adds the obtained value embedding tensor to the time code representing the block's time position element by element, ultimately constructing a high-dimensional structured tensor representation that simultaneously contains numerical, variable, and temporal information.

[0062] This step is specifically represented as follows:

[0063] Variable encoding: Define a trainable variable embedding matrix For sequence block tensors The first in For each segment of a station, find its corresponding identification code. (Right now The (Line), this value is the station's identity information; the identity code Broadcast and add element-by-element to all its corresponding blocks, adding an identity fingerprint to all sites:

[0064]

[0065] in For sequence block tensors In rearrangement The subsequent single block, For the block tensor after fusing identity information;

[0066] Value embedding: Defines a trainable linear value embedding layer Its weight bias ,in The core hidden dimension of the large language model; the block tensor after fusing identity information Projection via value embedding layer:

[0067]

[0068] Generate value embedding tensor This tensor contains both the original numerical information and the station variable information.

[0069] Temporal encoding: Define a trainable temporal embedding matrix For the first For each time location block, find its corresponding time code. (Right now The (line), this value represents the absolute physical time of the station;

[0070] Time encoding Broadcast and add element by element All corresponding time positions On the block embedding tensor:

[0071]

[0072] Generate the final structured coding tensor It also carries three physical information: power value, station identity, and time stamp.

[0073] Reshaping: Then the structured encoding tensor station dimensions and block time dimension Merge and reshape the input format required for a large language model:

[0074]

[0075] in, This represents the feature vector input to the large language model; reshape represents the transformation of the structured encoding tensor. The station dimension and time dimension are merged.

[0076] Step 3: Construct a feature extraction network based on a pre-trained large language model and configure a dual optimization strategy to achieve efficient feature extraction.

[0077] First, a bypass mechanism is employed, allowing the structured encoding tensor representation to skip the native positional encoding module of the large language model, avoiding the confusion between temporal and variable information, and directly inputting it into the Transformer layer of the large language model. Second, an efficient fine-tuning strategy is implemented, freezing the parameters of the self-attention layer and feedforward network of the main body of the large language model during training, retaining only the parameters of the layer normalization module for training, thereby greatly reducing the fine-tuning cost while preserving the powerful sequence modeling capabilities of the large language model. Specifically:

[0078] Assume a pre-trained large language model From word embedding layer Location coding layer Transformer layer list and final layer normalization constitute.

[0079] Bypass mechanism: Input the feature vector of the large language model As the initial hidden state Skip the large language model Word embedding layer and position coding layer ;

[0080] Deep feature extraction: from the initial hidden state The list of Transformer layers is sent sequentially. Processing:

[0081]

[0082] in For the selected Transformer layer The number of layers. The last Transformer layer. Through final layer normalization :

[0083]

[0084] Obtain the extracted deep features .

[0085] Pre-trained large language models leverage their general sequence pattern recognition capabilities learned from massive amounts of data (such as sensitivity to periodicity and trends) to infer the fluctuation patterns of photovoltaic power and obtain deep features.

[0086] Then, an efficient fine-tuning strategy (Freeze) is used to divide the parameters of the large language model into a trainable subset and a frozen subset, specifically as follows:

[0087] Set up a large language model All parameters are ;Will Divided into trainable subsets and frozen subsets Trainable subset Includes large language models All layer normalization parameters; frozen subset Includes large language models The self-attention parameters and feedforward network parameters of all Transformer layers are updated during training. This strategy enables the generalization of photovoltaic prediction for multiple power plants to specific scenarios through fine-tuning of small parameters on a pre-trained large language model. At the hardware level, this means reducing parameter writing and gradient calculation operations by more than 99%, significantly reducing GPU memory usage and power consumption, making it possible to deploy large models on edge computing devices or industrial servers with limited computing power.

[0088] Step 4: Construct a linear output layer to map the extracted deep features to the required target prediction sequence length and number of power plants. Then, using the mean squared error (MSE) of multiple variables as the loss function, and based on the training dataset, solve for the trainable parameters of the model using gradient descent optimization and early stopping mechanisms to obtain the trained multi-power plant photovoltaic power prediction model. Specifically:

[0089] Linear output layer: This layer processes the deep features extracted by the feature extraction network. Flattened Define a trainable linear output layer. Its weight bias Calculate the predicted value Then will Remodeling ,in The obtained photovoltaic treatment prediction value.

[0090] Loss function: Mean squared error (MSE) is used as the loss function. Used to minimize the predicted value Compared with the true value Differences between them:

[0091]

[0092] in for, .

[0093] After obtaining the loss function value, the specific steps for optimizing the model parameters using gradient descent and early stopping mechanisms are as follows:

[0094] Step (1): Given the training dataset Validate dataset Initialize the model's trainable parameters Adam optimizer Learning rate Cosine annealing scheduler Maximum number of training rounds Stop early and be patient. ;

[0095] Step (2): Set the initial training rounds Early Stop Counter Optimal verification loss ;

[0096] Step (3): Iterate through all data batches Calculate the forward propagation; Calculate the loss Calculate the gradient Through the optimizer Update parameters ;

[0097] Step (4): Traverse the validation dataset All data batches Calculate the average verification loss ;

[0098] Step (5): If ,but Save the current model parameters Reset ;like ,but ;

[0099] Step (6): Training rounds Through the scheduler Update learning rate ;

[0100] Step (7): If (Triggering early stop) or If the maximum number of rounds is reached, training is terminated; otherwise, return to step (3).

[0101] Step (8): Training ends, return the optimal model parameters. This allows us to obtain a well-trained multi-site photovoltaic power prediction model.

[0102] The trained multi-site photovoltaic power prediction model is used to predict the photovoltaic power of multiple sites. The specific method is as follows: using new historical time-series data of multiple sites... As input, the photovoltaic power prediction results for multiple power stations can be obtained. .

[0103] The multi-site photovoltaic power prediction method of this invention introduces sequence segmentation and multi-dimensional encoding, transforming the multi-site time series problem into a sequence processing problem of a large language model; and adopts an efficient fine-tuning strategy to transfer the powerful capabilities of the pre-trained model to the prediction task at low cost, which greatly expands the application scenarios of the large language model in the field of industrial time series prediction, so as to efficiently support the coordinated operation and scheduling of multiple sites with deterministic prediction.

[0104] like Figure 3 As shown, in one specific embodiment of the present invention, the annual photovoltaic power generation of a certain regional power grid is selected for day-ahead interval prediction. The time series has a time resolution of 15 minutes, and the data includes the power generation of photovoltaic power plants in different geographical locations within the region. The ratio of the training set, validation set, and test set is 7:2:1. The prediction objective is an ultra-short-term prediction 15 minutes in advance.

[0105] Taking the joint prediction task for 5, 10, and 15 photovoltaic power plants as an example, the input historical sequence length is 8, and the predicted future sequence length is 1. The specific parameter settings and hierarchical connection relationships of the multi-plant photovoltaic power prediction model based on the large language model are as follows:

[0106] 1. Data Preprocessing and Sequence Segmentation Stage: First, the model segments the standardized multi-site time series data into blocks. The segmentation window size is set to 4, and the sliding step size is 2. For a time series of length 8, 3 blocks are generated after processing. At this point, the tensor dimension of the input data is transformed from (32, 5 / 10 / 15, 8) to the sequence segmentation tensor (32, 5 / 10 / 15, 3, 4).

[0107] 2. Multidimensional Structured Encoding Layer: This layer contains three parallel processing units designed to map chunked data to the hidden space dimension of a large language model. In this embodiment, it is set to 768.

[0108] 1) Variable embedding: A trainable lookup table with dimensions (5 / 10 / 15, 768) is used. The model extracts the corresponding identity feature vector based on the input site index and extends it to all time blocks of that site through a broadcast mechanism.

[0109] 2) Linear value embedding: A one-dimensional linear layer is used to project the original power values ​​of each block onto the hidden space dimension 768 of the language model.

[0110] 3) Temporal embedding: A trainable lookup table with dimensions (3, 768) is used to assign temporal position codes based on the absolute position of the block in the sequence.

[0111] The three embedding vectors are fused element-wise to produce a structured coding tensor of shape (32, 5 / 10 / 15×3, 768), which is then used as input to the subsequent network.

[0112] 3. Feature Extraction Network (LLM Backbone): The core of the feature extraction network adopts a pre-trained GPT-2 model architecture. Its configuration is as follows:

[0113] 1) Input interface: A bypass mechanism is provided to directly receive the above structured encoding tensor, skipping the word embedding and position encoding layers that come with the original model.

[0114] 2) Stacked Transformer layers of the language model: Contains 6 Transformer decoder modules within the language model. Each layer contains a multi-head self-attention mechanism and a feedforward neural network. The number of attention heads is set to 8.

[0115] 3) Efficient Fine-tuning Configuration: During training, the weight matrices of all self-attention modules and the weights of the feedforward network in the Transformer layer of the above language model are frozen. Only the layer normalization parameters within each layer and the normalization layer at the final output are set to a trainable state to adapt to the statistical distribution characteristics of photovoltaic data.

[0116] 4. Output Stage: The linear output layer model ends with a fully connected linear layer. This layer has an input dimension of 768 and an output dimension equal to the product of the block size and the prediction step size, which is 1. This layer directly maps the deep feature tensor output by the LLM back to the photovoltaic power prediction value, and finally reshapes the output tensor dimension to (32, 5 / 10 / 15, 1).

[0117] Table 1 presents the prediction performance indices obtained by the method of the present invention and the comparative method, wherein the comparative method uses the Transformer prediction model.

[0118] Table 1 Comparison of Prediction Model Performance

[0119]

[0120] As shown in Table 1, under different test conditions with 5, 10, and 15 monitoring stations, the method of this invention achieves superior results in both the mean absolute error (MAE) and mean squared error (MSE) compared to the comparative method. This indicates that the method of this invention has higher prediction accuracy, and it maintains a stable performance advantage even with an increase in the number of monitoring stations, verifying the superiority of the method of this invention in multi-station joint prediction problems.

[0121] Figure 4 This is a comparison chart of the predicted and actual curves for a specific photovoltaic power generation site under joint forecasting. The chart shows that the predicted curve provided by the method of this invention can closely track and fit the actual photovoltaic power value under different weather conditions. It should be noted that, in addition to multi-site photovoltaic power forecasting, the framework based on efficient fine-tuning of a large language model proposed in this invention is also applicable to other multivariate time series forecasting scenarios, such as multi-site wind power forecasting and multi-regional load forecasting, demonstrating broad applicability.

[0122] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0123] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0124] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0125] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0126] The above description is merely a preferred embodiment of the present invention. Although the present invention has been disclosed above with reference to preferred embodiments, it is not intended to limit the present invention. Any person skilled in the art can make many possible variations and modifications to the technical solutions of the present invention using the methods and techniques disclosed above, or modify them into equivalent embodiments with equivalent changes, without departing from the scope of the technical solutions of the present invention. Therefore, any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present invention without departing from the content of the technical solutions of the present invention shall still fall within the protection scope of the technical solutions of the present invention.

Claims

1. A method for predicting photovoltaic power from multiple power plants based on efficient fine-tuning of a large language model, characterized in that, Includes the following steps: Historical photovoltaic power time-series data from multiple power stations within the target time period are acquired, and then standardized and processed into sequence blocks to obtain sequence block tensors. The sequence block tensor is input into a multi-site photovoltaic power prediction model trained with an efficient fine-tuning strategy to obtain the multi-site photovoltaic power prediction results; The multi-site photovoltaic power prediction model includes a multi-dimensional structured coding layer, a feature extraction network, and a linear output layer connected in sequence. The multidimensional structured coding layer is used to encode the sequence block tensor into a structured coding tensor containing power values, station identity information, and time information; The feature extraction network uses a pre-trained large language model as its core to perform deep feature extraction on the structured coding tensor; wherein the structured coding tensor skips the native positional encoding module of the large language model when it is input. The linear output layer is used to map the deep features to the prediction dimension and output the photovoltaic power prediction results for multiple sites. The multidimensional structured coding layer includes a trainable variable embedding matrix, a trainable linear value embedding layer, and a trainable temporal embedding matrix; the variable embedding matrix is ​​used to provide the identity code of each photovoltaic power station; the linear value embedding layer is used to project the block data with the identity code into the model's hidden space; and the temporal embedding matrix is ​​used to provide the absolute temporal location code of each block. The steps for generating the structured coded tensor in the multidimensional structured coding layer include: Based on the station identity information, the corresponding identity code is obtained from the variable embedding matrix and fused with the sequence block tensor; The block tensor after identity encoding is projected through the linear value embedding layer to a hidden dimension that matches the input dimension of the feature extraction network to obtain the value embedding tensor. Based on the time position of the block, the corresponding time code is obtained from the time embedding matrix and fused with the value embedding tensor to obtain a structured coding tensor; The structured coding tensor is then reshaped into the input sequence format required by the feature extraction network.

2. The method for predicting photovoltaic power at multiple sites based on efficient fine-tuning of a large language model according to claim 1, characterized in that, The standardization and sequence segmentation process specifically includes: The historical photovoltaic power time series data of each power station is standardized. The standardized historical photovoltaic power time series data of each power station is then truncated along the time dimension by a sliding window with a preset block size and block step size to form a sequence block tensor. For data at the end of the time series that is not enough to form a complete block, a copying and padding method is used to complete it.

3. The method for predicting photovoltaic power from multiple power plants based on efficient fine-tuning of a large language model according to claim 1, characterized in that, The fusion of identity encoding with sequence block tensors and the fusion of time encoding with value embedding tensors are both achieved through a broadcast mechanism, using element-wise addition.

4. The method for predicting photovoltaic power from multiple power plants based on efficient fine-tuning of a large language model according to claim 1, characterized in that, The pre-trained large language model includes a word embedding layer, a position encoding layer, multiple Transformer layers, and a final normalization layer connected in sequence. The feature extraction network bypasses the word embedding layer and position encoding layer of the large language model through a bypass mechanism, and directly inputs the structured encoding tensor into the multiple Transformer layers for deep feature extraction.

5. The method for predicting photovoltaic power from multiple power plants based on efficient fine-tuning of a large language model according to claim 4, characterized in that, The process of training a multi-site photovoltaic power prediction model using an efficient fine-tuning strategy includes: Prepare the training and validation datasets; Freeze the parameters of the self-attention modules and feedforward neural network modules within all Transformer layers of the pre-trained large language model in the feature extraction network; The parameters of the multidimensional structured coding layer, the linear output layer, and all layer normalization components in the large language model are set to be trainable; the layer normalization components include the layer normalization modules inside each Transformer layer and the final normalization layer. Using mean squared error as the loss function, the trainable parameters are iteratively optimized using gradient descent to finally obtain a well-trained multi-site photovoltaic power prediction model.

6. A multi-site photovoltaic power prediction system based on efficient fine-tuning of a large language model, characterized in that, To implement the method of any one of claims 1-5, comprising: The data processing module is used to acquire historical photovoltaic power time series data from multiple power stations within the target time period, and to perform standardization and sequence block processing to obtain sequence block tensors; A multidimensional structured coding module is used to encode the sequence block tensor into a structured coding tensor containing power values, station identification information, and time information; The feature extraction module, based on a pre-trained large language model, is used to perform deep feature extraction on the structured coding tensor; wherein the structured coding tensor skips the native positional coding module of the large language model when input; The result output module is used to map the deep features to the prediction dimension and output the photovoltaic power prediction results for multiple sites.

7. A computer device, characterized in that, The computer device includes: One or more processors; Memory, used to store one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the multi-site photovoltaic power prediction method based on efficient fine-tuning of a large language model as described in any one of claims 1-5.

8. A computer-readable storage medium storing computer instructions, characterized in that, When the computer instructions are executed by one or more processors, the one or more processors cause the processors to perform the steps of the method according to any one of claims 1-5.

Citation Information

Patent Citations

  • Photovoltaic power prediction method based on pre-trained large language model

    CN120781168A