Power market price forecasting method, system and device based on regional individualized modeling

CN122736674APending Publication Date: 2026-09-11JIANGSU WOTAIRUI CHU NEW ENERGY CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202610995914.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-06
Publication Date
2026-09-11

AI Technical Summary

Technical Problem

此外,该方案采用单一LSTM网络进行区域预测,缺乏将供需紧张程度、可再生能源出力偏离程度及备用成本变化趋势作为显式先验注入网络结构的机制,模型仅在输入层接收原始特征,网络中段与输出端无法持续获得市场微观驱动因素的强化引导,在区域供需结构快速变化时预测稳定性不足,难以满足高比例可再生能源并网下多时间尺度电价精准预测的需求

Benefits of technology

本发明通过构造供需紧张指数、可再生能源渗透波动率及备用成本梯度三项衍生特征,将隐性的市场驱动因素转化为连续数值信号,使模型在数据层面直接捕获定价机制的微观驱动力,提升了多元输入序列对电价形成过程的物理表征能力。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122736674A_ABST
    Figure CN122736674A_ABST
Patent Text Reader

Abstract

This invention belongs to the field of electricity market price prediction technology, and provides a method, system, and device for electricity market price prediction based on regional personalized modeling. The method includes: independently dividing the time-series data of each electricity market region into original datasets; standardizing the datasets; using a sliding window to construct multi-feature data from multiple consecutive time points as input sequences; and constructing the electricity price at future time points as the target output; constructing a three-layer gated recurrent unit network for each region, and training it to obtain a personalized electricity price prediction model for each region; inputting the latest multi-feature sequence collected from the target region into the trained prediction model, and inverting the standardized output as the future electricity price prediction result. This invention improves the ability of multi-source input sequences to physically represent the electricity price formation process, and enhances the learning quality of time-series features during periods of scarce prices, realizing a closed-loop, end-to-end regional personalized prediction process from feature acquisition to decision output.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of electricity market price forecasting technology, specifically relating to a method, system, and equipment for electricity market price forecasting based on regional personalized modeling. Background Technology

[0002] Currently, in the field of electricity market price forecasting, significant differences exist among different electricity market regions in terms of supply and demand structure, renewable energy penetration rate, and reserve capacity pricing mechanisms. This makes it difficult for a single global model to accurately capture the formation patterns of individualized regional electricity prices. With the high proportion of renewable energy connected to the grid, the grid operation's reliance on reserve capacity across multiple time scales continues to deepen. Electricity price fluctuations are not only affected by aggregate demand and clearing supply, but also closely related to the interplay between solar availability, wind availability, and reserve capacity prices with different response times. The need for independent modeling for different regions and the integration of multi-level market characteristics is becoming increasingly urgent. Regional electricity price forecasting based on deep learning has become a core technological direction in electricity market analysis.

[0003] A search revealed Chinese patent application CN202510219887.1, which discloses a method, apparatus, system, and storage medium for regional electricity price prediction. This scheme constructs a regional electricity price prediction function, extracts regional electricity price data features, and simultaneously inputs the function and data features into an LSTM deep learning structure for regional electricity price prediction, aiming to improve the accuracy and real-time performance of electricity price prediction. The scheme uses LSTM as the core network for time-series modeling, relying on the general fitting ability of neural networks to automatically learn mapping relationships from historical electricity prices and related feature sequences. Its standardization process employs a global Z-score transformation, uniformly calculating the mean and standard deviation for all samples in the training set, thus eliminating dimensional differences while uniformly compressing the dynamic range of all values. The training process uses mean squared error as the loss function, applying an equal penalty to each prediction deviation.

[0004] However, when faced with price spikes caused by supply and demand tensions in distant historical moments, the contribution of these signals to the final hidden state is gradually diluted due to the gradual decay of gradients during long-term backpropagation. This results in the model lacking sufficient sensitivity to periods of scarce prices. Traditional Z-score normalization scales the original values ​​corresponding to extreme electricity prices along with normal fluctuations, suppressing spike signals into a narrow range that is difficult for neural networks to discern at the input level. Mean squared error loss gives equal weight to all prediction biases, failing to pay extra attention to prediction errors during periods of high-price scarcity. This drives the optimization process to prioritize fitting the normal electricity price range with a large sample size, sacrificing the prediction accuracy of tail spikes. Furthermore, this scheme uses a single LSTM network for regional prediction, lacking a mechanism to explicitly inject the degree of supply and demand tension, the degree of deviation in renewable energy output, and the trend of reserve cost changes as priors into the network structure. The model only receives raw features at the input layer, and the middle and output ends of the network cannot continuously obtain reinforcement guidance from micro-market driving factors. This results in insufficient prediction stability when the regional supply and demand structure changes rapidly, making it difficult to meet the needs of accurate electricity price prediction across multiple time scales under a high proportion of renewable energy grid connection. Summary of the Invention

[0005] The purpose of this invention is to overcome the shortcomings of existing methods and provide a method, system and equipment for predicting electricity market prices based on regional personalized modeling.

[0006] To solve the above-mentioned technical problems, the present invention provides the following technical solution: The first objective of this invention is to provide a method for predicting electricity market prices based on regional personalized modeling, comprising the following steps: (1) Obtain the supply and demand characteristics, renewable energy ratio and multi-time scale reserve capacity time series data of each power market region, and divide the datasets independently by region; construct derived features for each region including regional supply and demand tension index, renewable energy penetration volatility and multi-time scale reserve cost gradient, and merge them with the datasets to form the original datasets of each region with time alignment. (2) After standardizing the original datasets of each region, a sliding window is used to construct the multi-feature data of multiple consecutive historical time points as the input sequence, and the electricity price of the future time point immediately following the historical window is constructed as the target output. (3) Construct a three-layer gated recurrent unit network for each region. After the first two gated recurrent unit layers, retain the complete sequence output and apply random discarding. After the third gated recurrent unit layer, only retain the final hidden state output. The gated recurrent unit network introduces a fusion mechanism of attention hidden state enhancement, mask-guided adaptive discarding and external feature adjustment gate. (4) Use the input sequence and target output generated in step (2) to train the gated recurrent unit network corresponding to each region. By minimizing the asymmetric loss function weighted by supply and demand tension, save the network parameters and standardized processing parameters of each region after training, and obtain the independent personalized electricity price prediction model for each region. (5) In the real-time prediction stage, the latest multi-feature sequence collected in the target area is input into the personalized electricity price prediction model trained in the area. The online recursive prediction formula of the supply and demand tension index at the target time is used to estimate the supply and demand tension index at the target time, and the inverse standardized output is taken as the future electricity price prediction result.

[0007] Furthermore, in step (1), the formula for calculating the regional supply and demand tension index is:

[0008] in, Represents total demand. Represents the initial supply. Represents the clearing supply, Weighting of supply before liquidation; The formula for calculating the volatility of renewable energy penetration is as follows:

[0009] in, and These represent the availability of solar power and the availability of wind power, respectively. For dispatchable power generation, The value is The smoothing constant, and It is the mean and standard deviation of available renewable energy in the same area over the past 24 hours; The formula for calculating the multi-timescale reserve cost gradient is as follows:

[0010] in, Indicates the response time is Price of spare capacity per minute It is a weight that is inversely proportional to the response speed.

[0011] Furthermore, in step (2), when standardizing the original datasets for each region, a dynamic scaling mechanism driven by the supply-demand tension index is introduced to preserve the numerical characteristics of extreme electricity price signals. The transformation formula is as follows:

[0012] in, Indicates the area The Each feature at time The original value, and These respectively represent the feature in the region Mean and standard deviation on the training set This is a regional supply and demand tension index. It is the scaling control coefficient.

[0013] Furthermore, in step (2), when constructing the input sequence using a sliding window, a fusion-time decay and supply-demand intensity weighted attention mask is used to explicitly mark key historical moments. The elements of the attention mask are defined as follows:

[0014] in, For the set history window length, the index Increasing from 1 to Represents various time steps within the window, from near to far. The time point is The supply and demand tension index It is the attenuation constant.

[0015] Furthermore, in step (3), the attention latent state enhancement mechanism is represented as follows:

[0016] in, Indicates the area No. The layer-gated loop unit is in the sliding window. The hidden state output at each time step Attention masks for the same sample, It is the strength enhancement coefficient; The mask-guided adaptive discarding mechanism is represented as follows:

[0017] in, The neuron retention probability represents the probability that the i-th neuron in the r-th layer of the GRU, at the t-th time step within the window, will not be discarded during forward propagation and will be retained for computation. The model will randomly retain neurons based on this probability; the higher the probability, the less likely the features at that time step will be discarded by regularization. It is the baseline discard ratio; The external feature regulation gate mechanism is represented as follows:

[0018] in, Indicates the comprehensive time series characteristics, Indicates the final hidden state. Indicates the volatility of renewable energy penetration. This represents the reserve cost gradient across multiple time scales. and It is a weight matrix. It is a bias vector. This is the sigmoid activation function, and ⊙ represents element-wise multiplication.

[0019] Furthermore, in step (4), the calculation formula for the supply-demand tension-weighted asymmetric loss function is as follows:

[0020] in, For the region The total number of training samples, It is the supply and demand tension index at the target time. It is the magnification factor. Output the target.

[0021] Furthermore, an adaptive gradient constraint mechanism with momentum truncation is introduced to impose a multiplicative penalty on prediction bias during price peak periods and automatically adjust the upper limit of the gradient magnitude. Each parameter matrix... gradient Scaling during backpropagation is performed using the following formula:

[0022] Norm cutoff threshold in the formula It is correlated with the mean of the supply and demand tension index in the current training batch, defined as ,in Based on the threshold, This is the sensitivity coefficient. It is the average of the supply and demand tension index of all samples in this batch.

[0023] Furthermore, in step (5), the online recursive prediction formula for the supply-demand tension index at the target time is expressed as:

[0024] In the formula, The number of differential backtracking steps, As the attenuation factor, It is the regional supply and demand tension index for the current moment and a total of four consecutive moments prior; The denormalization and restoration operation follows the inverse process of the transformation during training, and the calculation formula is:

[0025] In the formula, and It is a region The mean and standard deviation of the target electricity price features on the training set, calculated using the classic Z-score. This is the scaling control coefficient.

[0026] Another objective of this invention is to provide a power market price forecasting system based on regional personalized modeling, comprising: The data acquisition and feature construction module is used to acquire the supply and demand characteristics, renewable energy ratio, and multi-timescale reserve capacity time series data of each power market region, and to independently divide the dataset by region; it constructs derived features for each region, including the regional supply and demand tension index, renewable energy penetration volatility, and multi-timescale reserve cost gradient, and merges them with the dataset to form the original dataset time-aligned for each region. The data standardization and sample construction module is used to standardize the original datasets of each region, and then use a sliding window to construct the multi-feature data of multiple consecutive historical time points into an input sequence, and construct the electricity price of future time points immediately following the historical window into a target output. The model construction and mechanism coupling module is used to construct a three-layer gated recurrent unit network for each region. After the first two gated recurrent unit layers, the complete sequence output is retained and random discarding is applied. After the third gated recurrent unit layer, only the final hidden state output is retained. The module introduces attention hidden state enhancement, mask-guided adaptive discarding and external feature adjustment gate fusion mechanism in the gated recurrent unit network. The model training and parameter saving module is used to train the gated recurrent unit network corresponding to each region using the input sequence and target output. By minimizing the asymmetric loss function weighted by supply and demand tension, the module saves the network parameters and standardized processing parameters after training in each region, and obtains an independent personalized electricity price prediction model for each region. The real-time prediction and output module is used to input the latest multi-feature sequence collected in the target area into the personalized electricity price prediction model trained in that area, estimate the supply and demand tension index at the target time using the online recursive prediction formula of the supply and demand tension index at the target time, and take the inverted and standardized output as the future electricity price prediction result.

[0027] Another object of the present invention is to provide an electronic device, including a processor and a memory storing a computer program, wherein the processor executes the computer program to implement the electricity market price forecasting method based on regional personalized modeling provided by the first object of the present invention.

[0028] In combination with the above technical solutions, the beneficial effects of the present invention compared with the prior art are as follows: This invention transforms implicit market drivers into continuous numerical signals by constructing three derived features: a supply and demand tension index, a renewable energy penetration volatility, and a reserve cost gradient. This enables the model to directly capture the micro-driving force of the pricing mechanism at the data level, thereby enhancing the ability of multi-input sequences to physically represent the electricity price formation process.

[0029] This invention designs a dynamic scaling standardization and attention masking mechanism driven by the supply and demand tension index. While eliminating dimensional differences, it retains the numerical characteristics of extreme electricity price signals and applies differentiated weights to key historical moments, effectively preventing peak signals from being compressed into the ordinary range by conventional standardization and losing predictive sensitivity.

[0030] This invention introduces attention mask-guided hidden state enhancement and adaptive discarding mechanism into a three-layer gated recurrent unit network, which strengthens network connections during periods of supply and demand tension and almost prevents random disconnection. This compensates for the shortcomings of conventional recurrent networks in attenuating sharp signals over long distances and significantly improves the learning quality of temporal features during periods of scarce prices.

[0031] This invention employs an asymmetric loss function weighted by supply and demand tension, combined with momentum truncation adaptive gradient constraints. It imposes a multiplied penalty on prediction deviations during price peak periods and automatically adjusts the upper limit of gradient magnitude. This drives the optimization process to remain stable in stable batches and converge rapidly in scarce batches, effectively enhancing the model's fitting accuracy for high-price and scarce scenarios.

[0032] This invention utilizes online recursion and dynamic destandardization of the supply and demand tension index at the target time during the real-time prediction stage to automatically adapt the predicted electricity price to potential peak scenarios in terms of numerical range. This avoids the dimensional reduction deviation caused by the lag of standardized parameters and realizes a closed loop of personalized regional prediction throughout the entire process from feature collection to decision output.

[0033] In summary, this invention employs a series of technical means to transform implicit market drivers into quantifiable values, thereby enhancing the representation of electricity price formation mechanisms. These means include: dividing the dataset into regions and constructing three types of market-derived features; dynamically standardizing the data by region and constructing time-series samples using attention masks; implementing a three-layer independent GRU network with three types of enhancement mechanisms; training the network by region based on a supply-demand weighted asymmetric loss function; and completing the dynamic de-standardization process by online recursion of the supply-demand tension index. This approach eliminates differences in feature dimensions while preserving extreme electricity price values ​​and strengthening the weight of key historical time series. It also strengthens network connections during periods of supply-demand tension to alleviate the gradient decay problem of long-sequence peak signals, improving the feature learning ability during periods of scarce prices; increasing the penalty for prediction errors during high-price periods; optimizing gradient update rules to improve the fitting accuracy of peak electricity prices; and dynamically restoring predicted electricity price values ​​to eliminate biases caused by the lag in standardized parameters, thus forming a complete regional personalized prediction closed loop. Attached Figure Description

[0034] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings: Figure 1 This is a flowchart of the electricity market price prediction method based on regional personalized modeling provided in an embodiment of the present invention; Figure 2 This is a schematic diagram illustrating the composition principle of the original dataset provided in this embodiment of the invention; Figure 3 This is a schematic diagram illustrating the principles of data standardization and sample construction provided in this embodiment of the invention; Figure 4 This is a schematic diagram illustrating the principle of model construction and mechanism coupling provided in the embodiments of the present invention; Figure 5 This is a schematic diagram illustrating the principle of model training and actual prediction provided in the embodiments of the present invention; Figure 6 This is a schematic diagram of the structure of the electricity market price prediction system based on regional personalized modeling provided in an embodiment of the present invention. Detailed Implementation

[0035] The preferred embodiments of the present invention will be described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are for illustration and explanation only and are not intended to limit the present invention.

[0036] Example 1:

[0037] like Figure 1 The image shows an embodiment of the electricity market price forecasting method based on regional personalized modeling provided by the present invention, which includes the following steps: S1: Obtain the supply and demand characteristics, renewable energy ratio, and multi-timescale reserve capacity time series data of each power market region, and divide the datasets independently by region; construct derived features for each region, including regional supply and demand tension index, renewable energy penetration volatility, and multi-timescale reserve cost gradient, and merge them with the datasets to form the original datasets of each region with time alignment. S2: After standardizing the original datasets of each region, a sliding window is used to construct the multi-feature data of multiple consecutive historical time points as the input sequence, and the electricity price of the future time point immediately following the historical window is constructed as the target output. S3: Construct a three-layer gated recurrent unit network for each region. After the first two gated recurrent unit layers, retain the complete sequence output and apply random discarding. After the third gated recurrent unit layer, only retain the final hidden state output. The gated recurrent unit network introduces an attention-based hidden state enhancement, mask-guided adaptive discarding, and external feature adjustment gate fusion mechanism. S4: Use the input sequence and target output generated in step S2 to train the gated recurrent unit network corresponding to each region. By minimizing the asymmetric loss function weighted by supply and demand tension, save the network parameters and standardized processing parameters after training in each region to obtain an independent personalized electricity price prediction model for each region. S5: In the real-time prediction stage, the latest multi-feature sequence collected in the target area is input into the personalized electricity price prediction model trained in that area. The online recursive prediction formula of the supply and demand tension index at the target time is used to estimate the supply and demand tension index at the target time, and the inverted and standardized output is taken as the future electricity price prediction result.

[0038] Specifically, this embodiment innovatively constructs a complete process for regional personalized electricity price forecasting. The core is to independently divide the dataset according to the electricity market region and train a dedicated forecasting model. By constructing three derived features—regional supply-demand tension index, renewable energy penetration volatility, and multi-timescale reserve cost gradient—it accurately captures the micro-market driving factors of electricity price formation. It employs dynamic scaling standardization driven by the supply-demand tension index and time-decaying supply-demand attention masks to retain extreme electricity price signals and strengthen the feature weights of key historical moments. An attention-based hidden state enhancement, mask-guided adaptive discarding, and external feature adjustment gate fusion mechanism are embedded in a three-layer GRU network to optimize the learning effect of time-series features. A supply-demand tension-weighted asymmetric loss function and momentum truncation adaptive gradient constraints are designed to significantly improve the forecasting accuracy during periods of high price scarcity. This is complemented by online recursion of the target-time supply-demand tension index and dynamic de-standardization restoration methods, achieving closed-loop regional personalized electricity price forecasting.

[0039] The following is a detailed explanation of each step.

[0040] Step 1: Obtain the supply and demand characteristics, renewable energy ratio, and time series data of reserve capacity at multiple time scales for each power market region, and divide the dataset independently by region.

[0041] The supply and demand characteristics include aggregate demand, initial supply, and clearing supply. The renewable energy share is determined by the ratio of the sum of solar and wind power availability to dispatchable generation. The multi-timescale reserve capacity includes reserve capacity prices with different response times. All of the above data are collected at the same time interval and aggregated according to their respective electricity market regions to form independent original datasets for each region. This ensures that the subsequent modeling process fully considers the differences in pricing mechanisms and supply and demand structures in different regions, providing a data foundation for training personalized regional models.

[0042] In Step 1, when acquiring time-series data for each electricity market region, this scheme independently constructs three derived features for each region to explicitly capture the micro-driving factors of the pricing mechanism. The first derived feature is the regional supply-demand tension index, calculated as follows:

[0043] In the formula Represents total demand. Represents the initial supply. Represents the clearing supply, The pre-liquidation supply weight is set to 0.3 to reflect the reference strength of the initial bid. The first part of the formula weights and harmonizes the two supply forms, while the second part amplifies the gap effect of demand exceeding liquidation supply through a logarithmic function. When supply is abundant, the exponent approaches 1; when a shortage occurs, the exponent increases non-linearly sharply, thus transforming the implicit supply-demand imbalance into a continuous numerical signal. The second derived feature is the renewable energy penetration volatility, calculated as follows:

[0044] In the formula and These represent the availability of solar power and the availability of wind power, respectively. For dispatchable power generation, The value is A smoothing constant to prevent division by zero. and This represents the mean and standard deviation of available renewable energy in the same region over the past 24 hours. This commonality measures the degree of deviation of current renewable energy output from recent fluctuations; a greater deviation results in higher grid regulation costs, directly impacting the reserve demand-side pressure on electricity prices. The third derived feature is the multi-timescale reserve cost gradient, calculated as follows:

[0045] In the formula Indicates the response time is Price of spare capacity per minute The weights are inversely proportional to the response speed, and are set to 0.5, 0.3, and 0.2 respectively. This formula weights and sums the standby price difference values ​​at three time scales: five minutes, fifteen minutes, and sixty minutes, capturing the direction of marginal cost changes in the standby market across short, medium, and long-term dimensions. When prices rise synchronously across all scales... A significantly positive value indicates a tightening of peak-shaving resources. For example... Figure 2 As shown, the three derived features mentioned above, together with the original aggregate demand, initial supply, liquidation supply, renewable energy share, and reserve capacity price at each time scale, constitute the original time-aligned datasets for each region. The data for each region is collected at the same time intervals and stored independently. This set of regional datasets constructed with explicit features fully preserves the time-series information of the three dimensions of supply and demand structure, renewable output, and reserve cost, providing a structurally clear and physically meaningful multivariate input sequence for the region-by-region standardization and sliding window construction in step 2.

[0046] Step 2: After standardizing the datasets for each region, a sliding window is used to construct the multi-feature data from multiple consecutive time points into an input sequence, and the electricity price at future time points is constructed as the target output.

[0047] The standardization process involves independently calculating the mean and standard deviation of the feature data for each region, using the Z-score method to eliminate the dimensional differences between different features, so that the multivariate features have the same numerical scale during model training. The sliding window sequentially extracts continuous feature matrices as input samples at a set number of historical time points, and uses the future electricity price immediately following the historical window as the corresponding prediction target, generating a training sample set with a clear temporal alignment relationship. Each region independently generates its own sample set.

[0048] like Figure 3 As shown, in step 2, when standardizing the datasets for each region, this scheme introduces a dynamic scaling mechanism driven by the supply-demand tension index to preserve the numerical characteristics of extreme electricity price signals. For the region... The Each feature at time raw value Its standardized transformation formula is:

[0049] In the formula and These respectively represent the feature in the region Mean and standard deviation on the training set The regional supply and demand tension index constructed in step 1, This is the scaling factor, uniformly set to 0.1. This formula adds a bias proportional to the degree of supply and demand tension to the denominator of the traditional Z-score. When prices rise sharply due to supply shortages, the denominator increases accordingly, thus suppressing excessive inflation of the standardized value and preventing extreme price signals from being compressed into a trivial range by conventional standardization, ensuring the model's sensitivity to peak electricity price patterns. Based on this, when constructing the input sequence using a sliding window, an attention mask that integrates time decay and supply-demand intensity weighting is designed to explicitly mark key historical moments. The elements of the mask matrix are defined as follows:

[0050] In the formula For the set history window length, the index Increasing from 1 to Represents various time steps within the window, from near to far. The time point in step 1 is The supply and demand tension index This is the decay constant, set to 0.2. The formula multiplies the exponential time decay factor by the supply-demand tension and normalizes it, giving higher attention weight to samples closer to the prediction time and with tighter supply-demand within the window. The mask... The weighted input sequence is obtained by multiplying the standardized feature vector step-by-step, which strengthens the model's temporal memory of periods of supply shortage. Subsequently, the target output is defined as the nth time step after the end of the window. Actual electricity price at a given time point All samples maintain a strict temporal alignment. Each region independently completes the above construction process, generating a multivariate temporal sample set with dynamic scaling characteristics and attention guidance. This sample set directly adapts to the structured input required by the three-layer gated recurrent unit network in step 3, and seamlessly injects the supply-demand tension prior into the sequence learning process.

[0051] Step 3: Construct a three-layer gated recurrent unit network with the same structure for each region. After the first two gated recurrent unit layers of the network, retain the complete sequence output and apply random dropout. After the third gated recurrent unit layer, only retain the final hidden state output.

[0052] In the three-layer gated recurrent unit network, each layer has the same number of hidden units. The first two gated recurrent unit layers pass the hidden states of all time steps to the next layer, enabling the next layer to continue learning the feature dependencies at different positions in the sequence. At the same time, after each layer, a random discarding mechanism is used to temporarily disconnect some neuron connections at a preset ratio to reduce the risk of the model overfitting to local features. The third gated recurrent unit layer discards the hidden states of the intermediate time steps and only outputs the hidden states of the last time step, compressing the temporal features of the entire input sequence into a fixed-length vector representation, providing comprehensive temporal features for subsequent electricity price prediction.

[0053] like Figure 4 As shown, in step 3, when constructing a three-layer gated recurrent unit network for each region, three mechanisms tightly coupled with steps 1 and 2 are introduced between the first two layers and the third layer to enhance the model's sensitivity to key driving factors in electricity price formation. First, after each layer of gated recurrent units calculates the original hidden state sequence, the attention mask generated in step 2 is used to enhance the importance of the hidden state at each time step. The calculation formula is as follows:

[0054] In the formula Indicates the area No. The layer-gated loop unit is in the sliding window. The hidden state output at each time step The attention mask for the same sample defined in step 2. This is the enhancement intensity coefficient, fixed at 0.15. This formula, by multiplying the hidden state by an amplification factor positively correlated with supply and demand tension and temporal proximity, significantly enhances the feature representation of key historical moments before they flow into the next layer, compensating for the inadequacy of attenuation of sharp signals at long distances in conventional recurrent networks. Secondly, the fixed-ratio random discarding in the original scheme is replaced with a mask-guided adaptive discarding mechanism. The retention probability of neurons at each time step is directly determined by the attention weights in step 2, calculated as follows:

[0055] In the formula This is the baseline discard ratio, uniformly set to 0.2. When When the probability of retention approaches 1, it ensures that network connections are almost never broken during periods of supply and demand stress, forcing the model to fully learn the mapping relationships during these periods. When the attention weight is low, the probability of rejection increases, playing a regularization role. This adaptive rejection is applied to the sequence outputs of the first two gated recurrent units, while the third layer does not perform rejection processing to maintain the integrity of the compressed features. Finally, the outputs of intermediate time steps are discarded in the third-layer gated recurrent unit, retaining only the final hidden state. Next, an external regulation gate is designed to control the volatility of renewable energy penetration constructed in step 1. With multi-timescale reserve cost gradient The final feature vector is directly injected, and its calculation formula is as follows:

[0056] In the formula and These correspond to the last time point of the input sequence. Regional derivative features, and It is a weight matrix. It is a bias vector. The sigmoid activation function is used, and ⊙ represents element-wise multiplication. This gating automatically adjusts the activation strength of each dimension of the implicit representation based on the current degree of renewable energy deviation and the direction of reserve cost changes, encoding the real-time grid regulation pressure into a fixed-length vector used for the final prediction. The resulting... It fully integrates time-series dependence, supply-demand tension weighted memory, and external market pressure to form a comprehensive time-series feature for regional electricity price forecasting, which is directly fed into the fully connected forecasting layer in step 4 for loss calculation and parameter optimization.

[0057] Step 4: Train the corresponding network using the input sequence and target output of each region. By minimizing the mean square error between the predicted electricity price and the actual electricity price, obtain an independent electricity price prediction model for each region.

[0058] For each region, the sample set generated in step 2 is input into the gated recurrent unit network constructed in step 3 for forward propagation to obtain the predicted value. The mean squared error loss between the predicted value and the true target value is calculated. An adaptive learning rate optimizer is used to iteratively update the weight matrix and bias vector of each layer in the network along the gradient descent direction. After a set number of training rounds, the error converges. The network parameters and standardized processing parameters of each region are saved to form a personalized electricity price prediction model corresponding to each region.

[0059] Step 4: When training the network for each region, the combined temporal features obtained from the weighted input sequence in Step 2 through forward propagation in Step 3 are used. The data is fed into a fully connected prediction layer to generate future electricity price forecasts. The fully connected prediction layer here is a single-layer linear mapping network placed after the external feature adjustment gate fusion module at the end of the three-layer gated recurrent unit network. This fully connected prediction layer receives the comprehensive time-series features output after adaptive discarding guided by attention hidden state enhancement mask and processing by the external feature adjustment gate. It maps the high-dimensional time-series feature vector of the fused regional supply and demand tension, new energy fluctuation, and reserve cost gradient information into a single-dimensional future electricity price prediction value. It only undertakes the functions of feature dimensionality reduction and electricity price value regression output, and does not contain a recurrent structure or activation adjustment gate mechanism. It is a dedicated regression calculation unit that completes the conversion of time-series features into electricity price prediction values.

[0060] To enhance the model's fitting accuracy during periods of high prices and scarcity, a supply-demand tension-weighted asymmetric loss function is designed to replace the traditional mean squared error. Its calculation formula is as follows:

[0061] In the formula For the region The total number of training samples, It is the supply and demand tension index at the target time constructed in step 1. This is the amplification factor, fixed at 0.5. The formula multiplies the squared error of each sample by a weighting factor linearly related to the supply-demand tension at the target time, thus penalizing prediction bias during price peaks and driving the network parameters to converge towards accurately capturing tight price signals, while maintaining the smooth optimization characteristics of the mean squared error during normal periods. To address the potential for a surge in gradient magnitude caused by extreme samples, an adaptive gradient constraint mechanism with momentum truncation is designed, where each parameter matrix... gradient Scaling during backpropagation is performed using the following formula:

[0062] Norm cutoff threshold in the formula It is not a global constant, but rather correlated with the mean of the supply-demand tension index in the current training batch, defined as... ,in The base threshold is set to 1.0. The sensitivity coefficient is set to 0.3. This is the average of the supply and demand tension index for all samples in that batch. This design automatically widens the threshold in batches with tight supply, allowing for larger gradient updates to quickly learn scarce signals, while tightening the threshold in stable batches to prevent invalid fluctuations from interfering with training. The optimizer used is Adam, whose learning rate is adaptively reduced according to the iteration epoch and the loss convergence status. An exponential moving average of the loss variance in each epoch during training is also introduced to assess convergence stability. When the moving average loss change is lower than [value missing] for three consecutive periods... Training is terminated early, and the network parameters, standardized processing parameters, and all intermediate statistics required for constructing the attention mask in step 2 are saved for that region, forming a personalized electricity price prediction model that corresponds one-to-one with the region. When these models are saved, they have fully inherited the supply and demand response patterns and renewable fluctuation memory of their respective regions, directly providing region-specific inference capabilities for real-time prediction in step 5.

[0063] Step 5: For the target area, input the latest collected multi-feature sequence into the model trained in that area, and take the inverted and standardized output as the future electricity price prediction result.

[0064] like Figure 5 As shown, when real-time electricity price forecasting is required for a certain electricity market region, the network parameters and standardized processing parameters saved in step 4 for that region are loaded. Multi-feature data of the continuous historical time points closest to the current time of that region are collected to form the input sequence to be predicted. The standardized processing parameters corresponding to the training are used to scale the sequence and then the sequence is fed into the regional model for forward calculation. The model outputs the electricity price prediction value under the standardized scale. Then, the standardized processing parameters saved during training are used to perform the destandardization operation to restore the prediction value to the original electricity price dimension. Finally, the future electricity price value that can be directly used for electricity market transaction decisions is output.

[0065] In the real-time prediction stage of step 5, after loading the trained network parameters and standardized processing parameters onto the target region, the supply and demand tension index needs to be calculated from the latest collected continuous historical multivariate feature sequences according to the formula defined in step 1. Renewable energy penetration volatility and backup cost gradient Then, the scaling transformation is performed according to the dynamic scaling and standardization formula in step 2, and an attention-weighted sequence is constructed. The standardized electricity price prediction value is obtained from the network forward computation. It must be destandardized to restore it to its original dimensions, but step 2 is the target variable. The standardization process incorporates the supply-demand tension index at the target time into the denominator. However, this index is unknown at the time of forecasting. Therefore, an online recursive forecasting formula for the supply and demand tension index at the target time is designed:

[0066] In the formula The number of differential backtracking steps is fixed at 3. The attenuation factor is set to 0.6. This is the regional supply and demand tension index constructed in step 1, covering the current time and four consecutive previous times. This formula uses an exponentially weighted summation of recent first-order differences to capture the short-term inertia of supply and demand tension changes, thus extrapolating the estimated value for the target time from the most recent known index at the prediction time. Based on this, the destandardization and reduction operation strictly follows the inverse process of the transformation during training, and its calculation formula is:

[0067] In the formula and It is a region The mean and standard deviation of the target electricity price features on the training set, calculated using the classic Z-score. The scaling factor is set to 0.1, maintaining strict consistency with step 2. This formula amplifies the network output value to the variance space modulated by the supply and demand tension during the forecast period and shifts it to the original mean level, allowing the restored electricity price to automatically adapt to potential peak scenarios in terms of numerical amplitude. The entire destandardization process relies entirely on the standardized statistics and online recursive exponents saved in step 4, maintaining consistency in the transformation. The resulting output... This means that the future electricity price can be directly used for regional electricity market pricing decisions, and the regional personalized modeling and real-time prediction closed loop consisting of steps 1 to 5 is fully realized.

[0068] The technical effects of the present invention will be further explained below with reference to simulation experiments.

[0069] 1. Experimental Environment and Dataset Three differentiated electricity market regions in China were selected: A) high penetration of new energy sources, B) large peak-valley load difference, and C) scarce reserve resources. Time series data on time-of-use electricity prices, supply and demand, wind and solar power output, and multi-scale reserve capacity were collected at 96 points throughout the year. The data were divided into a training set of 70%, a validation set of 15%, and a test set of 15%. The benchmark scheme was the global LSTM electricity price prediction method mentioned in the background technology.

[0070] 2. Evaluation metrics: Mean Absolute Error (MAE), Root Mean Square Error (RMSE), Peak Electricity Price Prediction Accuracy (a deviation of less than 5% between the predicted value and the actual electricity price during peak hours is considered accurate), and number of training convergence rounds.

[0071] Table 1. Optimization of performance indicators by this embodiment compared to the baseline embodiment.

[0072] Example 2:

[0073] like Figure 6 As shown, this embodiment provides a power market price forecasting system based on regional personalized modeling, including: The data acquisition and feature construction module is used to acquire the supply and demand characteristics, renewable energy ratio, and multi-timescale reserve capacity time series data of each power market region, and to independently divide the dataset by region; it constructs derived features for each region, including the regional supply and demand tension index, renewable energy penetration volatility, and multi-timescale reserve cost gradient, and merges them with the dataset to form the original dataset time-aligned for each region. The data standardization and sample construction module is used to standardize the original datasets of each region, and then use a sliding window to construct the multi-feature data of multiple consecutive historical time points into an input sequence, and construct the electricity price of future time points immediately following the historical window into a target output. The model construction and mechanism coupling module is used to construct a three-layer gated recurrent unit network for each region. After the first two gated recurrent unit layers, the complete sequence output is retained and random discarding is applied. After the third gated recurrent unit layer, only the final hidden state output is retained. The module introduces attention hidden state enhancement, mask-guided adaptive discarding and external feature adjustment gate fusion mechanism in the gated recurrent unit network. The model training and parameter saving module is used to train the gated recurrent unit network corresponding to each region using the input sequence and target output. By minimizing the asymmetric loss function weighted by supply and demand tension, the module saves the network parameters and standardized processing parameters after training in each region, and obtains an independent personalized electricity price prediction model for each region. The real-time prediction and output module is used to input the latest multi-feature sequence collected in the target area into the personalized electricity price prediction model trained in that area, estimate the supply and demand tension index at the target time using the online recursive prediction formula of the supply and demand tension index at the target time, and take the inverted and standardized output as the future electricity price prediction result.

[0074] Example 3:

[0075] Another object of the present invention is to provide an electronic device, including a processor and a memory storing a computer program, wherein the processor executes the computer program to implement the electricity market price forecasting method based on regional personalized modeling provided in Embodiment 1.

[0076] It should be understood that although the steps in the flowcharts of the various embodiments of the present invention are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated in the present invention, there is no strict order restriction on the execution of these steps, and these steps can be executed in other orders. Moreover, at least some steps in the various embodiments may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least a portion of the sub-steps or stages of other steps.

[0077] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided by this invention can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0078] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for predicting electricity market prices based on regional personalized modeling, characterized in that, The method includes the following steps: (1) Obtain the supply and demand characteristics, renewable energy ratio and multi-time scale reserve capacity time series data of each power market region, and divide the datasets independently by region; construct derived features for each region including regional supply and demand tension index, renewable energy penetration volatility and multi-time scale reserve cost gradient, and merge them with the datasets to form the original datasets of each region with time alignment. (2) After standardizing the original datasets of each region, a sliding window is used to construct the multi-feature data of multiple consecutive historical time points as the input sequence, and the electricity price of the future time point immediately following the historical window is constructed as the target output. (3) Construct a three-layer gated recurrent unit network for each region. After the first two gated recurrent unit layers, retain the complete sequence output and apply random discarding. After the third gated recurrent unit layer, only retain the final hidden state output. The gated recurrent unit network introduces a fusion mechanism of attention hidden state enhancement, mask-guided adaptive discarding and external feature adjustment gate. (4) Use the input sequence and target output generated in step (2) to train the gated recurrent unit network corresponding to each region. By minimizing the asymmetric loss function weighted by supply and demand tension, save the network parameters and standardized processing parameters of each region after training, and obtain the independent personalized electricity price prediction model for each region. (5) In the real-time prediction stage, the latest multi-feature sequence collected in the target area is input into the personalized electricity price prediction model trained in the area. The online recursive prediction formula of the supply and demand tension index at the target time is used to estimate the supply and demand tension index at the target time, and the inverse standardized output is taken as the future electricity price prediction result.

2. The electricity market price forecasting method based on regional personalized modeling according to claim 1, characterized in that, In step (1), the formula for calculating the regional supply and demand tension index is: in, Represents total demand. Represents the initial supply. Represents the clearing supply, Weighting of supply before liquidation; The formula for calculating the volatility of renewable energy penetration is as follows: in, and These represent the availability of solar power and the availability of wind power, respectively. For dispatchable power generation, The value is The smoothing constant, and It is the mean and standard deviation of available renewable energy in the same area over the past 24 hours; The formula for calculating the multi-timescale reserve cost gradient is as follows: in, Indicates the response time is Price of spare capacity per minute It is a weight that is inversely proportional to the response speed.

3. The electricity market price forecasting method based on regional personalized modeling according to claim 1, characterized in that, In step (2), when standardizing the original datasets for each region, a dynamic scaling mechanism driven by the supply-demand tension index is introduced to preserve the numerical characteristics of extreme electricity price signals. The transformation formula is as follows: in, Indicates the area The Each feature at time The original value, and These respectively represent the feature in the region Mean and standard deviation on the training set This is a regional supply and demand tension index. It is the scaling control coefficient.

4. The electricity market price forecasting method based on regional personalized modeling according to claim 1, characterized in that, In step (2), when constructing the input sequence using a sliding window, a fusion-time decay and supply-demand intensity weighted attention mask is used to explicitly mark key historical moments. The elements of the attention mask are defined as follows: in, For the set history window length, the index Increasing from 1 to Represents various time steps within the window, from near to far. The time point is The supply and demand tension index It is the attenuation constant.

5. The electricity market price forecasting method based on regional personalized modeling according to claim 1, characterized in that, In step (3), the attention latent state enhancement mechanism is represented as follows: in, Indicates the area No. The layer-gated loop unit is in the sliding window. The hidden state output at each time step Attention masks for the same sample, It is the strength enhancement coefficient; The mask-guided adaptive discarding mechanism is represented as follows: in, Preserve the probability for the neuron. It is the baseline discard ratio; The external feature regulation gate mechanism is represented as follows: in, Indicates the comprehensive time series characteristics, Indicates the final hidden state. Indicates the volatility of renewable energy penetration. This represents the reserve cost gradient across multiple time scales. and It is a weight matrix. It is a bias vector. This is the sigmoid activation function, and ⊙ represents element-wise multiplication.

6. The electricity market price forecasting method based on regional personalized modeling according to claim 1, characterized in that, In step (4), the calculation formula for the supply-demand tension-weighted asymmetric loss function is as follows: in, For the region The total number of training samples, It is the supply and demand tension index at the target time. It is the magnification factor. Output the target.

7. The electricity market price forecasting method based on regional personalized modeling according to claim 6, characterized in that, An adaptive gradient constraint mechanism with momentum truncation is introduced to impose a multiple penalty on prediction deviations during price peak periods and automatically adjust the upper limit of the gradient magnitude. Each parameter matrix... gradient Scaling during backpropagation is performed using the following formula: Norm cutoff threshold in the formula It is correlated with the mean of the supply and demand tension index in the current training batch, defined as... ,in Based on the threshold, This is the sensitivity coefficient. It is the average of the supply and demand tension index of all samples in this batch.

8. The electricity market price forecasting method based on regional personalized modeling according to claim 1, characterized in that, In step (5), the online recursive prediction formula for the supply-demand tension index at the target time is expressed as: In the formula, The number of differential backtracking steps, As the attenuation factor, It is the regional supply and demand tension index for the current moment and a total of four consecutive moments prior; The denormalization and restoration operation follows the inverse process of the transformation during training, and the calculation formula is: In the formula, and It is a region The mean and standard deviation of the target electricity price features on the training set, calculated using the classic Z-score. This is the scaling control coefficient.

9. A power market price forecasting system based on regional personalized modeling, characterized in that, The system includes: The data acquisition and feature construction module is used to acquire the supply and demand characteristics, renewable energy ratio, and multi-timescale reserve capacity time series data of each power market region, and to independently divide the dataset by region; it constructs derived features for each region, including the regional supply and demand tension index, renewable energy penetration volatility, and multi-timescale reserve cost gradient, and merges them with the dataset to form the original dataset time-aligned for each region. The data standardization and sample construction module is used to standardize the original datasets of each region, and then use a sliding window to construct the multi-feature data of multiple consecutive historical time points into an input sequence, and construct the electricity price of future time points immediately following the historical window into a target output. The model construction and mechanism coupling module is used to construct a three-layer gated recurrent unit network for each region. After the first two gated recurrent unit layers, the complete sequence output is retained and random discarding is applied. After the third gated recurrent unit layer, only the final hidden state output is retained. The module introduces attention hidden state enhancement, mask-guided adaptive discarding and external feature adjustment gate fusion mechanism in the gated recurrent unit network. The model training and parameter saving module is used to train the gated recurrent unit network corresponding to each region using the input sequence and target output. By minimizing the asymmetric loss function weighted by supply and demand tension, the module saves the network parameters and standardized processing parameters after training in each region, and obtains an independent personalized electricity price prediction model for each region. The real-time prediction and output module is used to input the latest multi-feature sequence collected in the target area into the personalized electricity price prediction model trained in that area, estimate the supply and demand tension index at the target time using the online recursive prediction formula of the supply and demand tension index at the target time, and take the inverted and standardized output as the future electricity price prediction result.

10. An electronic device comprising a processor and a memory storing a computer program, characterized in that, When the processor executes the computer program, it implements the electricity market price forecasting method based on regional personalized modeling as described in any one of claims 1 to 8.

Citation Information

Patent Citations

  • Regional electricity price prediction method, device and system, and storage medium

    CN120338840A