Electricity market price prediction method and device, medium and equipment

By using a composite neural network model in the power market price prediction, combined with the crown porcupine optimization algorithm, two-way long and short-term memory network and attention mechanism model, historical multi-source data is trained, and the problem of insufficient accuracy of electricity price prediction in the existing technology is solved, and the electricity price prediction effect with higher accuracy and robustness is achieved.

CN120198149APending Publication Date: 2025-06-24GUANGDONG ELECTRIC POWER TRADING CENT CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510211888.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-25
Publication Date
2025-06-24

AI Technical Summary

Technical Problem

The existing technology cannot accurately predict the future price of the power market, mainly because the model of a single network structure has insufficient features, information loss and long-distance dependence.

Method used

A composite neural network model is adopted to optimize the hyperparameters of the initial neural network through the crown porcupine optimization algorithm, and combine the preset bidirectional long and short-term memory network and attention mechanism model to train historical multi-source data to improve the accuracy and robustness of electricity price prediction.

Benefits of technology

It achieves higher accuracy prediction of electricity market prices, is more robust and interpretable, can effectively improve the accuracy and efficiency of electricity price prediction, and provides reliable decision-making support for electricity market participants.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120198149A_ABST
    Figure CN120198149A_ABST
Patent Text Reader

Abstract

The invention discloses an electricity market price prediction method and device, a medium and equipment. According to the method and the device, comprehensive and multi-dimensional input information is provided for electricity price prediction by acquiring the electric power multi-source data including the meteorological data at the current moment, the energy cost and the market supply and demand indexes. The data cover key factors influencing the electricity price, and a rich feature basis is provided for the model. On the basis, historical data are trained and hyper-parameters are optimized by combining a composite neural network model based on a crown porcupine optimization algorithm, BiLSTM and an attention mechanism. The model finally realizes accurate prediction of future electricity price of a target area through feature extraction, bidirectional time-dependent modeling and dynamic weight distribution.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of electricity market price forecasting, and particularly to a method, device, medium and equipment for electricity market price forecasting. Background Art

[0002] With the advancement of the electricity market reform, the operating mechanism of the electricity spot market has become increasingly complex, and electricity price forecasting has become a key link for electricity market participants to formulate strategies and optimize resource allocation. In recent years, the Guangdong electricity spot market was officially launched on December 28, 2023, marking a new stage in the electricity market reform. However, affected by factors such as the "dual carbon" goal and the construction of market diversification, the electricity price series shows non-stationary and highly volatile characteristics, making it a very challenging task to accurately forecast electricity prices.

[0003] Existing electricity price forecasting methods mainly include production cost methods, statistical methods, and methods based on heuristics or data mining. The production cost method relies on detailed modeling of the behavior and costs of electricity market agents, but its calculation process is complex and requires a large amount of confidential information, making it difficult to be widely applied in actual scenarios. Statistical methods (such as time series analysis) can capture the time dependence of electricity prices, but their linear assumptions limit the ability to simulate non-linear relationships, and the forecasting accuracy is limited. In recent years, methods based on heuristics or data mining (such as deep learning models like LSTM and CNN) have gradually emerged. These methods can effectively handle non-linear relationships and perform well in time series forecasting. However, models with a single network structure still have deficiencies in feature extraction ability, information loss, and long-distance dependence problems, making it difficult to meet the needs of complex electricity price forecasting, resulting in the inability of existing technologies to accurately predict the future prices of the electricity market. Summary of the Invention

[0004] The present invention provides a method, device, medium and equipment for electricity market price forecasting to solve the problem that the future prices of the electricity market cannot be accurately predicted in the existing technology.

[0005] In a first aspect, the present application provides a method for electricity market price forecasting, including:

[0006] Obtain multi-source electricity data; wherein, the multi-source electricity data includes meteorological data, energy costs, and market supply and demand indicators at the current moment;

[0007] According to the multi-source electricity data and a preset composite neural network model, obtain the electricity price forecasting result for the future moment in the target area;

[0008] Among them, the preset composite neural network model is obtained by training historical multi-source data on the initial neural network according to the crown porcupine optimization algorithm, the preset bidirectional long short-term memory network, and the preset attention mechanism model.

[0009] This application provides comprehensive and multi-dimensional input information for electricity price prediction by obtaining power multi-source data including meteorological data, energy costs, and market supply and demand indicators at the current moment. These data cover the key factors affecting electricity prices, thus providing a rich feature basis for the model. On this basis, the crown porcupine optimization algorithm (CPO) is used to optimize the hyperparameters of the initial neural network, ensuring that the model can efficiently find a parameter combination close to the optimal in the high-dimensional non-convex search space, thereby improving the performance and training efficiency of the model. Further, by combining the preset bidirectional long short-term memory network (BiLSTM) and the attention mechanism model, the long-term and short-term dependencies of the electricity price sequence can be effectively captured, key features can be highlighted, and the model's ability to focus on important information can be enhanced. Through the training of historical multi-source data by this composite neural network model, the electricity price prediction results for the target area at future moments not only have higher accuracy but also stronger robustness and interpretability. This application effectively solves the problem that the prior art cannot accurately predict the future price of the electricity market.

[0010] As a preferred embodiment of the first aspect, the preset composite neural network model is obtained by training historical multi-source data on the initial neural network according to the crown porcupine optimization algorithm, the preset bidirectional long short-term memory network, and the preset attention mechanism model, specifically as follows:

[0011] Obtain historical multi-source data;

[0012] Input the historical multi-source data into the initial neural network model, so that the initial neural network model performs local feature extraction and dimensionality reduction processing on the input data through the convolutional neural network layer to generate the first multi-source data;

[0013] Establish bidirectional time dependencies for the first multi-source data according to the preset bidirectional long short-term memory network, perform dynamic weight allocation during the training of the first multi-source data according to the attention mechanism model, and perform global search and local optimization on each hyperparameter of the bidirectional long short-term memory network according to the crown porcupine optimization algorithm;

[0014] Among them, the respective hyperparameters include the learning rate, the random dropout ratio, and the number of units of each bidirectional long short-term memory network;

[0015] When the prediction error coefficient of the initial neural network model meets the preset error threshold, terminate the training to obtain the preset composite neural network model.

[0016] In this preferred embodiment, the present application realizes the efficient processing of multi-source power data and accurate electricity price prediction through an optimized composite neural network model. Specifically, first, historical multi-source data containing various influencing factors is obtained and input into the initial neural network model. The convolutional neural network (CNN) layer is used to extract local features and reduce the dimensionality of the input data, generating the first multi-source data. This process effectively reduces the data complexity and extracts key features. Subsequently, a bidirectional time-dependent relationship of the data is established through a preset bidirectional long short-term memory network (BiLSTM), and at the same time, the attention mechanism model is combined to dynamically allocate weights to the data during the training process, strengthening the model's ability to focus on important information. On this basis, the crown porcupine optimization algorithm is introduced to globally search and locally optimize the hyperparameters of the BiLSTM (such as the number of units, learning rate, and dropout ratio), ensuring that the model achieves optimal performance in a complex and changing data environment. When the prediction error coefficient of the model meets the preset threshold, the training terminates. The obtained composite neural network model has high accuracy, strong robustness, and good interpretability, and can effectively improve the accuracy and efficiency of electricity price prediction, providing reliable decision-making support for electricity market participants.

[0017] As a preferred embodiment of the first aspect, the historical multi-source data includes historical meteorological data, historical energy costs, and historical market supply and demand indicators;

[0018] The historical meteorological data includes historical wind speed, historical temperature, and historical typhoon conditions;

[0019] The historical energy costs include historical liquefied natural gas prices and coal machine costs;

[0020] The historical market supply and demand indicators include historical load and historical market prices.

[0021] In this preferred embodiment, the present application achieves high-precision modeling and optimization of electricity price forecasting by comprehensively analyzing historical multi-source data. Specifically, the historical multi-source data covers multiple key areas such as meteorology, energy costs, and market supply and demand. Among them, historical meteorological data (such as wind speed, temperature, and typhoon conditions) can reflect the impact of natural conditions on electricity prices; historical energy costs (such as liquefied natural gas prices and coal mill costs) reveal the dynamic changes in power generation costs; and historical market supply and demand indicators (such as load and market price) are directly related to the supply-demand balance and price fluctuations in the power market. By integrating these multi-dimensional data into the model, the model can more comprehensively capture the internal laws of electricity price changes. This integration of multi-source data not only enriches the input features of the model but also provides a richer information basis for the model, enabling it to more accurately reflect the complex relationships between electricity prices and various factors. On this basis, the model further improves the prediction accuracy and robustness through the synergistic effect of optimization algorithms and neural network structures. Finally, this electricity price forecasting method based on multi-source data can provide more reliable and accurate decision-making support for power market participants, significantly improving the operational efficiency of the power market and the rationality of resource allocation.

[0022] As a preferred embodiment of the first aspect, when the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model. Specifically:

[0023] The prediction error of the initial neural network model includes R 2 coefficient of determination, root mean square error, and mean absolute percentage error;

[0024] When the R 2 coefficient of determination reaches the preset first threshold, the root mean square error reaches the preset second threshold, and the mean absolute percentage error reaches the preset third threshold, the training is stopped to obtain the preset composite neural network model.

[0025] In this preferred embodiment, the present application ensures the high precision and reliability of the composite neural network model through a strict error evaluation system. Specifically, in the training process of the initial neural network model, the coefficient of determination, root mean square error (RMSE), and mean absolute percentage error (MAPE) are used as comprehensive evaluation indicators for prediction errors. The coefficient of determination measures the explanatory ability of the model for data variation, RMSE reflects the average error between the predicted value and the true value, while MAPE provides a relative percentage evaluation of the error. When the coefficient of determination reaches a preset first threshold, it indicates that the model has a high degree of fitting to the data; at the same time, when RMSE and MAPE respectively reach the preset second and third thresholds, it shows that the prediction accuracy and stability of the model both meet the requirements. At this time, the training is terminated, and the obtained composite neural network model not only performs well on the training data but also has good generalization ability, capable of providing high-precision and reliable electricity price prediction results for electricity market participants, significantly improving the decision-making efficiency and market operation benefits.

[0026] As a preferred embodiment of the first aspect, obtaining the electricity price prediction result of the target area at a future moment according to the multi-source power data and the preset composite neural network model specifically includes:

[0027] Input the multi-source power data into the composite neural network model, so that the convolutional neural network layer of the composite neural network model performs local feature extraction and dimensionality reduction processing on the multi-source power data to generate first feature data;

[0028] Input the first feature data into the bidirectional long short-term memory network of the composite neural network model, so that the bidirectional long short-term memory network models the bidirectional time dependence relationship through forward and backward chain processing to generate second feature data;

[0029] Input the first feature data into the attention mechanism model of the composite neural network model, so that the attention mechanism model performs dynamic weight allocation on the second feature data, calculates the contribution degree of each time step feature to the prediction result, and generates weighted feature data;

[0030] According to the weighted feature data, calculate and output the electricity price prediction value of the target area at a future moment through the output layer.

[0031] In this preferred embodiment, the present application realizes the efficient processing of multi-source power data and accurate electricity price prediction through the collaborative action of the multi-layer structure of the composite neural network model. Specifically, first, the multi-source power data is input into the model, and the convolutional neural network (CNN) layer is used to extract local features and reduce the dimensionality of the data, generating the first feature data. This process effectively extracts the key local information in the data and reduces the computational complexity. Subsequently, the first feature data is input into the bidirectional long short-term memory network (BiLSTM), which models the bidirectional time-dependent relationship using its forward and backward chain processing, generating the second feature data, thereby capturing the long-term dynamic characteristics of the electricity price sequence. Further, the second feature data is input into the attention mechanism model, which dynamically assigns weights and calculates the contribution degree of the features at each time step to the prediction result, generating the weighted feature data. This process significantly enhances the model's ability to focus on important information, improving the accuracy and interpretability of the prediction. Finally, based on the weighted feature data, the output layer calculates and outputs the electricity price prediction value for the future moment in the target area. Through this mechanism of hierarchical processing and feature optimization, the model can not only accurately predict electricity prices but also adapt to the complex dynamic changes in the power market, providing reliable decision-making support for market participants and significantly improving the operation efficiency of the power market and the rationality of resource allocation.

[0032] In a second aspect, the present application provides an electricity market price prediction device. The electricity market price prediction device includes an acquisition module and a prediction module;

[0033] The acquisition module is used to acquire multi-source power data; wherein, the multi-source power data includes meteorological data, energy costs, and market supply and demand indicators at the current moment;

[0034] The prediction module is used to obtain the electricity price prediction result for the future moment in the target area according to the multi-source power data and a preset composite neural network model;

[0035] Wherein, the preset composite neural network model is obtained by training historical multi-source data on an initial neural network according to the crown porcupine optimization algorithm, a preset bidirectional long short-term memory network, and a preset attention mechanism model.

[0036] This device uses two modules to divide labor and work in coordination, which can more accurately predict electricity prices. This application provides comprehensive and multi-dimensional input information for electricity price prediction by obtaining multi-source power data including meteorological data, energy costs, and market supply and demand indicators at the current moment. These data cover the key factors affecting electricity prices, thus providing a rich feature basis for the model. On this basis, the Crown Porcupine Optimization Algorithm (CPO) is used to optimize the hyperparameters of the initial neural network, ensuring that the model can efficiently find a near-optimal parameter combination in a high-dimensional non-convex search space, thereby improving the performance and training efficiency of the model. Further, by combining the preset Bidirectional Long Short-Term Memory Network (BiLSTM) and the attention mechanism model, the long-term and short-term dependencies of the electricity price sequence can be effectively captured, key features can be highlighted, and the model's ability to focus on important information can be enhanced. Through the training of the historical multi-source data by this composite neural network model, the electricity price prediction results for the future moment in the target area not only have higher accuracy but also stronger robustness and interpretability. This application effectively solves the problem that the prior art cannot accurately predict the future price of the electricity market.

[0037] As a preferred embodiment of the second aspect, the preset composite neural network model is obtained by training historical multi-source data on the initial neural network according to the Crown Porcupine Optimization Algorithm, the preset Bidirectional Long Short-Term Memory Network, and the preset attention mechanism model. Specifically:

[0038] Obtain historical multi-source data;

[0039] Input the historical multi-source data into the initial neural network model, so that the initial neural network model performs local feature extraction and dimensionality reduction processing on the input data through the convolutional neural network layer to generate the first multi-source data;

[0040] Establish bidirectional time dependencies for the first multi-source data according to the preset Bidirectional Long Short-Term Memory Network, perform dynamic weight allocation during the training of the first multi-source data according to the attention mechanism model, and perform global search and local optimization on each hyperparameter of the Bidirectional Long Short-Term Memory Network according to the Crown Porcupine Optimization Algorithm;

[0041] Among them, each hyperparameter includes the learning rate, the random dropout ratio, and the number of units in each Bidirectional Long Short-Term Memory Network;

[0042] When the prediction error coefficient of the initial neural network model meets the preset error threshold, terminate the training to obtain the preset composite neural network model.

[0043] In this preferred embodiment, the present application realizes the efficient processing of multi-source power data and accurate electricity price prediction through an optimized composite neural network model. Specifically, first, historical multi-source data containing various influencing factors is obtained and input into the initial neural network model. The convolutional neural network (CNN) layer is used to extract local features and reduce the dimension of the input data, generating the first multi-source data. This process effectively reduces the data complexity and extracts key features. Subsequently, a bidirectional time-dependent relationship of the data is established through the preset bidirectional long short-term memory network (BiLSTM), and at the same time, the attention mechanism model is combined to dynamically allocate weights to the data during the training process, strengthening the model's ability to focus on important information. On this basis, the crown porcupine optimization algorithm is introduced to globally search and locally optimize the hyperparameters of the BiLSTM (such as the number of units, learning rate, and dropout ratio), ensuring that the model achieves optimal performance in a complex and changing data environment. When the prediction error coefficient of the model meets the preset threshold, the training terminates. The obtained composite neural network model has high accuracy, strong robustness, and good interpretability, and can effectively improve the accuracy and efficiency of electricity price prediction, providing reliable decision-making support for power market participants.

[0044] As a preferred embodiment of the second aspect, when the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model, specifically:

[0045] The prediction error of the initial neural network model includes R 2 coefficient of determination, root mean square error, and mean absolute percentage error;

[0046] When the R 2 coefficient of determination reaches the preset first threshold, the root mean square error reaches the preset second threshold, and the mean absolute percentage error reaches the preset third threshold, the training is stopped to obtain the preset composite neural network model.

[0047] In this preferred embodiment, the present application ensures the high precision and reliability of the composite neural network model through a strict error evaluation system. Specifically, in the training process of the initial neural network model, the coefficient of determination, root mean square error (RMSE), and mean absolute percentage error (MAPE) are used as comprehensive evaluation indicators for prediction errors. The coefficient of determination measures the explanatory ability of the model for data variation, RMSE reflects the average error between the predicted value and the true value, and MAPE provides a relative percentage evaluation of the error. When the coefficient of determination reaches a preset first threshold, it indicates that the model has a high degree of fitting to the data; at the same time, when RMSE and MAPE respectively reach the preset second and third thresholds, it shows that both the prediction accuracy and stability of the model meet the requirements. At this time, the training is terminated, and the obtained composite neural network model not only performs well on the training data but also has good generalization ability, and can provide high-precision and reliable electricity price prediction results for electricity market participants, significantly improving the decision-making efficiency and market operation benefits.

[0048] In a third aspect, the present application provides a computer-readable storage medium, which includes a stored computer program. When the computer program runs, it controls the device where the computer-readable storage medium is located to execute a method for predicting electricity market prices as described above. Its beneficial effects are the same as those of the method for predicting electricity market prices provided in the first aspect of the present application.

[0049] In a fourth aspect, the present application provides a terminal device, which includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements any one of the methods for predicting electricity market prices as described in the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 : A flowchart of an embodiment of the method for predicting electricity market prices provided by the present application;

[0051] Figure 2 : A schematic structural diagram of an embodiment of the composite neural network model provided by the present application;

[0052] Figure 3 : A schematic structural diagram of an embodiment of the device for predicting electricity market prices provided by the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0053] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.

[0054] Embodiment 1

[0055] Please refer to Figure 1 , which is a method for predicting electricity market prices provided by an embodiment of the present invention.

[0056] With the deepening of the electricity market reform, short-term electricity price prediction is crucial for the decision-making efficiency and resource allocation benefits of market participants. However, traditional electricity price prediction methods face significant challenges: the production cost method relies on confidential data and complex optimization, with limited practicality; statistical methods are difficult to capture the non-linear fluctuation characteristics of electricity prices due to linear assumptions; while deep learning methods based on LSTM, etc. have the potential for non-linear modeling, but still have bottlenecks such as insufficient local feature extraction, loss of long-sequence information, and weak model interpretability. Especially under the drive of the "dual carbon" goal, the increasing proportion of new energy and the complexity of the market environment have further exacerbated the difficulty of electricity price prediction. There is an urgent need for a prediction method that integrates multi-source data and balances accuracy and interpretability.

[0057] This application proposes a method for predicting electricity market prices based on a four-layer composite neural network of CPO-CNN-BiLSTM-Attention. Its innovation is reflected in the following aspects:

[0058] Multi-level feature fusion architecture:

[0059] CNN layer: Extract the local correlation of input features such as energy cost and meteorological data through convolution operations, and capture short-term fluctuation patterns (such as the impact of offshore wind power after a 20% increase in wind speed);

[0060] BiLSTM layer: Bidirectionally model the long-term dependence relationship of time series, combining historical and future states (such as the sudden change in supply and demand before and after a typhoon passes by);

[0061] Attention layer: Dynamically allocate weights, focus on the features of key time steps (such as the impact of electricity price when the cost of coal-fired units suddenly increases), and enhance the interpretability of the model.

[0062] Global optimization of hyperparameters:

[0063] Introduce the Crown Porcupine Optimization Algorithm (CPO), and through simulating exploration, development, defense, and group cooperation behaviors, globally search and locally optimize hyperparameters such as the number of BiLSTM units and learning rate, significantly improving the model convergence efficiency and generalization ability.

[0064] Data-driven adaptive design:

[0065] The input data covers multi-dimensional market indicators (such as adjusted temperature thresholds, average power transmission load from west to east in Guangdong), adapting to the complex scenarios of the Guangdong power spot market;

[0066] The training termination conditions adopt multi-error collaborative thresholds (R 2 > 70%, RMSE < 0.1, MAPE < 15%), ensuring the accuracy and stability of the model.

[0067] S01: Obtain multi-source power data; wherein, the multi-source power data includes meteorological data, energy costs, and market supply and demand indicators at the current moment.

[0068] S02: Obtain the electricity price prediction result for the future moment in the target area according to the multi-source power data and a preset composite neural network model;

[0069] Among them, the preset composite neural network model is obtained by training historical multi-source data on the initial neural network according to the crown porcupine optimization algorithm, a preset bidirectional long short-term memory network, and a preset attention mechanism model.

[0070] As a preferred embodiment of Embodiment 1, the preset composite neural network model is obtained by training historical multi-source data on the initial neural network according to the crown porcupine optimization algorithm, a preset bidirectional long short-term memory network, and a preset attention mechanism model, specifically:

[0071] Obtain historical multi-source data;

[0072] The historical multi-source data is shown in the following table:

[0073]

[0074]

[0075] Input the historical multi-source data into the initial neural network model, so that the initial neural network model performs local feature extraction and dimensionality reduction processing on the input data through a convolutional neural network layer, generating first multi-source data;

[0076] Among them, convolution is a mathematical operation. In a CNN, it slides a window over the input image or feature map and calculates the weighted sum of the elements within the window and the corresponding elements of the convolution kernel to generate an output feature map. Convolution is a special linear operation used to extract local features in an image. Pooling is a downsampling operation in a convolutional neural network. It defines a spatial neighborhood and statistically processes the features within that neighborhood to generate a new feature map. The pooling operation reduces the size of the feature map, thereby reducing the computational load and the number of parameters in the subsequent convolutional layer, and thus improving the computational efficiency. Through the pooling operation, the CNN can further extract the features of the input data, enabling the model to learn more abstract and high-level feature representations. The pooling operation reduces the dimensionality and the number of parameters of the feature map, reducing the complexity of the model, and thus preventing the occurrence of overfitting to a certain extent. The pooling operation reduces the size of the feature map, thereby reducing the computational load and the number of parameters in the subsequent convolutional layer, and thus improving the computational efficiency.

[0077] Based on the preset bidirectional long short-term memory network, establish a bidirectional time dependence relationship for the first multi-source data, perform dynamic weight allocation during the training of the first multi-source data according to the attention mechanism model, and perform global search and local optimization on each hyperparameter of the bidirectional long short-term memory network according to the crown porcupine optimization algorithm;

[0078] More specifically, the bidirectional long short-term memory network consists of two independent LSTM layers. One processes the input sequence from front to back (forward), and the other processes the sequence from back to front (backward). The outputs of these two LSTMs are concatenated together at each time step and then passed to the next layer or the output layer to capture the global context at the current time step. Compared with traditional LSTM, BiLSTM can utilize both past and future information simultaneously, so it is more suitable for tasks that require capturing bidirectional dependencies, such as understanding mood or trend changes that fully consider historical and future states. BiLSTM can capture longer dependencies, which is beneficial for some sequence data containing long-term dependencies.

[0079] More specifically, the attention mechanism model is a technology that enables the model to focus on important information and fully learn and absorb it. By calculating the importance scores of each element in the input sequence related to the current task, and then performing a weighted sum of the input elements according to these scores to obtain a weighted average representation for subsequent processing or prediction. When processing sequence data, the attention mechanism allows the model to dynamically assign different weights to each element in the input sequence, enabling the model to focus on the information that is most useful for the current task.

[0080] Among them, each hyperparameter includes the learning rate, the random dropout ratio, and the number of units in the bidirectional long short-term memory network;

[0081] In the optimization, the CPO hyperparameter optimization mechanism is used to avoid local optimal traps in the solution space. Crested porcupines will share information through group collaboration to improve the efficiency of foraging. In the algorithm, this is similar to information sharing or the propagation of global solutions, which is used to accelerate convergence. CPO hyperparameter optimization can find the optimal parameter permutation and combination in the CNN-BiLSTM-ATTENTION model. In this model, the parameters involved include the number of units in the LSTM layer, the number of data samples input into the model each time, the number of times the model is trained on the training set, the learning rate of the optimizer, and the proportion of randomly discarded neurons.

[0082] CPO designs the optimization process by simulating the following characteristics and behaviors of crested porcupines: (1) exploration behavior (2) exploitation behavior (3) defense behavior (4) group collaboration. Crested porcupines will explore the surrounding environment when foraging. This process is used in the algorithm to search the solution space to discover potential global optimal solutions. Once a high-quality food source (i.e., an optimal solution in the solution space) is found, the crested porcupine will further optimize around this area, which corresponds to local search in the algorithm. Crested porcupines protect themselves by adjusting their distance from other organisms (such as the length and direction of their quills). In the optimization, this mechanism is used to avoid local optimal traps in the solution space. Crested porcupines will share information through group collaboration to improve the efficiency of foraging. In the algorithm, this is similar to information sharing or the propagation of global solutions, which is used to accelerate convergence.

[0083] When the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model.

[0084] As Figure 2 shown, Figure 2 This is the prediction model structure based on CPO-CNN-BiLSTM-Attention of this application. This model consists of CPO hyperparameter optimization, an input layer, a CNN layer (convolution layer + pooling layer), a BiLSTM layer (forward LSTM layer and backward LSTM layer), an Attention layer, and an output layer.

[0085] In this preferred embodiment, the present application realizes the efficient processing of multi-source power data and accurate electricity price prediction through an optimized composite neural network model. Specifically, first, historical multi-source data containing various influencing factors is obtained and input into the initial neural network model. The convolutional neural network (CNN) layer is used to extract local features and reduce the dimension of the input data, generating the first multi-source data. This process effectively reduces the data complexity and extracts key features. Subsequently, a bidirectional time-dependent relationship of the data is established through the preset bidirectional long short-term memory network (BiLSTM), and at the same time, the attention mechanism model is combined to dynamically allocate weights to the data during the training process, strengthening the model's ability to focus on important information. On this basis, the crown porcupine optimization algorithm is introduced to globally search and locally optimize the hyperparameters of BiLSTM (such as the number of units, learning rate, and dropout ratio), ensuring that the model achieves optimal performance in a complex and changing data environment. When the prediction error coefficient of the model meets the preset threshold, the training terminates. The obtained composite neural network model has high precision, strong robustness, and good interpretability, and can effectively improve the accuracy and efficiency of electricity price prediction, providing reliable decision-making support for power market participants.

[0086] As a preferred embodiment of Embodiment 1, when the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model, specifically:

[0087] The prediction error of the initial neural network model includes the coefficient of determination, root mean square error, and mean absolute percentage error;

[0088] When the coefficient of determination reaches the preset first threshold, the root mean square error reaches the preset second threshold, and the mean absolute percentage error reaches the preset third threshold, the training is stopped to obtain the preset composite neural network model.

[0089] More specifically, R 2 The coefficient of determination measures the model's ability to explain the variation of the data; RMSE measures the average error between the model's predicted values and the true values; MAPE measures the percentage of the average error between the model's predicted values and the true values. During the model training process, when the above three indicators simultaneously meet the following conditions, it can be considered that the model training is completed: R 2 Coefficient of determination > 70%, RMSE < 0.1, MAPE < 15%.

[0090] In practical applications, when users obtain independent variable data or have corresponding expectations, these independent variable indicators can be brought into the trained model to predict the day-ahead average price of the Guangdong power spot market on day t + 1. In this way, users can utilize the prediction ability of the model to plan and make decisions in advance, thereby improving operational efficiency and economic benefits.

[0091] In this preferred embodiment, the present application ensures the high precision and reliability of the composite neural network model through a strict error evaluation system. Specifically, in the training process of the initial neural network model, the coefficient of determination, root mean square error (RMSE), and mean absolute percentage error (MAPE) are used as comprehensive evaluation indicators for prediction errors. The coefficient of determination measures the ability of the model to explain the variation of the data. RMSE reflects the average error between the predicted value and the true value, while MAPE provides a relative percentage evaluation of the error. When the coefficient of determination reaches a preset first threshold, it indicates that the model has a high degree of fitting to the data. At the same time, when RMSE and MAPE reach the preset second and third thresholds respectively, it shows that the prediction accuracy and stability of the model both meet the requirements. At this time, the training is terminated. The obtained composite neural network model not only performs well on the training data but also has good generalization ability, can provide high-precision and reliable electricity price prediction results for electricity market participants, and significantly improve the decision-making efficiency and market operation benefits.

[0092] As a preferred embodiment of Embodiment 1, obtaining the electricity price prediction result of the target area at a future moment according to the multi-source power data and the preset composite neural network model specifically includes:

[0093] Input the multi-source power data into the composite neural network model, so that the convolutional neural network layer of the composite neural network model performs local feature extraction and dimensionality reduction processing on the multi-source power data to generate first feature data;

[0094] Input the first feature data into the bidirectional long short-term memory network of the composite neural network model, so that the bidirectional long short-term memory network models the bidirectional time dependence relationship through forward and backward chain processing to generate second feature data;

[0095] Input the first feature data into the attention mechanism model of the composite neural network model, so that the attention mechanism model performs dynamic weight allocation on the second feature data, calculates the contribution degree of each time step feature to the prediction result, and generates weighted feature data;

[0096] According to the weighted feature data, calculate and output the electricity price prediction value of the target area at a future moment through the output layer.

[0097] In this preferred embodiment, the present application realizes the efficient processing of multi-source power data and accurate electricity price prediction through the collaborative action of the multi-layer structure of the composite neural network model. Specifically, first, the multi-source power data is input into the model, and the convolutional neural network (CNN) layer is used to extract local features and reduce the dimension of the data, generating the first feature data. This process effectively extracts the key local information in the data and reduces the computational complexity. Subsequently, the first feature data is input into the bidirectional long short-term memory network (BiLSTM), which uses its forward and backward chain processing to model the bidirectional time-dependent relationship, generating the second feature data, thereby capturing the long-term dynamic characteristics of the electricity price sequence. Further, the second feature data is input into the attention mechanism model, which dynamically assigns weights and calculates the contribution degree of each time-step feature to the prediction result, generating the weighted feature data. This process significantly enhances the model's ability to focus on important information and improves the accuracy and interpretability of the prediction. Finally, based on the weighted feature data, the output layer calculates and outputs the electricity price prediction value for the future moment in the target area. Through this hierarchical processing and feature optimization mechanism, the model can not only accurately predict the electricity price but also adapt to the complex dynamic changes in the power market, providing reliable decision-making support for market participants and significantly improving the operation efficiency of the power market and the rationality of resource allocation.

[0098] The present application provides comprehensive and multi-dimensional input information for electricity price prediction by obtaining multi-source power data including meteorological data, energy costs, and market supply and demand indicators at the current moment. These data cover the key factors affecting electricity prices, thus providing a rich feature basis for the model. On this basis, the crown porcupine optimization algorithm (CPO) is used to optimize the hyperparameters of the initial neural network, ensuring that the model can efficiently find a near-optimal parameter combination in the high-dimensional non-convex search space, thereby improving the performance and training efficiency of the model. Further, by combining the preset bidirectional long short-term memory network (BiLSTM) and the attention mechanism model, the long-term and short-term dependencies of the electricity price sequence can be effectively captured, key features can be highlighted, and the model's ability to focus on important information can be enhanced. Through the training of the historical multi-source data by this composite neural network model, the electricity price prediction result for the future moment in the target area obtained finally not only has higher accuracy but also has stronger robustness and interpretability. The present application effectively solves the problem that the prior art cannot accurately predict the future price of the power market.

[0099] Embodiment 2

[0100] Please refer to Figure 3 , which is a power market price prediction device provided by an embodiment of the present application.

[0101] In this embodiment, the power market price prediction device includes an acquisition module 10 and a prediction module 20.

[0102] With the deepening of the electricity market reform, short-term electricity price forecasting is crucial for the decision-making efficiency and resource allocation benefits of market participants. However, traditional electricity price forecasting methods face significant challenges: the production cost method relies on confidential data and complex optimization, with limited practicality; statistical methods are difficult to capture the non-linear volatility characteristics of electricity prices due to linear assumptions; while deep learning methods based on LSTM, etc., although having the potential for non-linear modeling, still have bottlenecks such as insufficient local feature extraction, loss of long-sequence information, and weak model interpretability. Especially under the drive of the "dual carbon" goal, the increasing proportion of new energy and the complexity of the market environment have further exacerbated the difficulty of electricity price forecasting, and there is an urgent need for a forecasting method that integrates multi-source data and balances accuracy and interpretability.

[0103] This application proposes a power market price forecasting method based on a four-layer composite neural network of CPO-CNN-BiLSTM-Attention, and its innovation is reflected in the following aspects:

[0104] Multi-level feature fusion architecture:

[0105] CNN layer: Extract the local correlation of input features such as energy cost and meteorological data through convolution operations to capture short-term fluctuation patterns (such as the impact of offshore wind power after a 20% increase in wind speed);

[0106] BiLSTM layer: Bidirectionally model the long-term dependence relationship of time series, combining historical and future states (such as the sudden change in supply and demand before and after a typhoon passes by);

[0107] Attention layer: Dynamically allocate weights, focus on the features of key time steps (such as the impact of electricity price during the period of sudden increase in coal mill cost), and enhance the model interpretability.

[0108] Hyperparameter global optimization:

[0109] Introduce the Crown Porcupine Optimization Algorithm (CPO), and through simulating exploration, development, defense, and group cooperation behaviors, globally search and locally optimize hyperparameters such as the number of BiLSTM units and learning rate, significantly improving the model convergence efficiency and generalization ability.

[0110] Data-driven adaptive design:

[0111] The input data covers multi-dimensional market indicators (such as the adjusted temperature threshold, the average load of power transmission from the west to the east), adapting to the complex scenarios of the Guangdong electricity spot market;

[0112] The training termination condition adopts a multi-error collaborative threshold (R 2 > 70%, RMSE < 0.1, MAPE < 15%), ensuring the model accuracy and stability.

[0113] The acquisition module 10 is used to acquire multi-source power data; wherein, the multi-source power data includes meteorological data, energy cost, and market supply and demand indicators at the current moment.

[0114] The prediction module 20 is used to obtain the electricity price prediction result at a future moment in the target area according to the multi-source power data and a preset composite neural network model;

[0115] Wherein, the preset composite neural network model is obtained by training historical multi-source data on an initial neural network according to the crown porcupine optimization algorithm, a preset bidirectional long short-term memory network, and a preset attention mechanism model.

[0116] As a preferred embodiment of the second embodiment, the preset composite neural network model is obtained by training historical multi-source data on an initial neural network according to the crown porcupine optimization algorithm, a preset bidirectional long short-term memory network, and a preset attention mechanism model, specifically:

[0117] Obtain historical multi-source data;

[0118] The historical multi-source data is shown in the following table:

[0119]

[0120]

[0121] Input the historical multi-source data into the initial neural network model, so that the initial neural network model performs local feature extraction and dimensionality reduction processing on the input data through a convolutional neural network layer to generate first multi-source data;

[0122] Wherein, convolution is a mathematical operation. In a CNN, it slides a sliding window over the input image or feature map and calculates the weighted sum of the elements within the window and the corresponding elements of the convolution kernel to generate an output feature map. Convolution is a special linear operation used to extract local features in an image. Pooling is a downsampling operation in a convolutional neural network. It defines a spatial neighborhood and statistically processes the features within that neighborhood to generate a new feature map. The pooling operation reduces the size of the feature map, reducing the computational amount and the number of parameters in the subsequent convolutional layer, thereby improving the computational efficiency. Through the pooling operation, the CNN can further extract the features of the input data, enabling the model to learn more abstract and high-level feature representations. The pooling operation reduces the dimensionality and the number of parameters of the feature map, reducing the complexity of the model, thereby preventing the occurrence of overfitting to a certain extent. The pooling operation reduces the size of the feature map, reducing the computational amount and the number of parameters in the subsequent convolutional layer, thereby improving the computational efficiency.

[0123] Based on the preset bidirectional long short-term memory network, establish a bidirectional time dependence relationship for the first multi-source data, perform dynamic weight allocation during the training of the first multi-source data according to the attention mechanism model, and perform global search and local optimization on each hyperparameter of the bidirectional long short-term memory network according to the crown porcupine optimization algorithm;

[0124] More specifically, the bidirectional long short-term memory network consists of two independent LSTM layers. One processes the input sequence from front to back (forward), and the other processes the sequence from back to front (backward). The outputs of these two LSTMs are concatenated together at each time step and then passed to the next layer or the output layer to capture the global context at the current time step. Compared with the traditional LSTM, BiLSTM can utilize both past and future information simultaneously, so it is more suitable for tasks that require capturing bidirectional dependencies, such as understanding mood or trend changes that fully consider historical and future states. BiLSTM can capture longer dependencies, which is beneficial for some sequence data containing long-term dependencies.

[0125] More specifically, the attention mechanism model is a technology that enables the model to focus on important information and fully learn and absorb it. By calculating the importance scores of each element in the input sequence related to the current task, and then performing a weighted sum of the input elements according to these scores, a weighted average representation is obtained for subsequent processing or prediction. When processing sequence data, the attention mechanism allows the model to dynamically assign different weights to each element in the input sequence, enabling the model to focus on the information that is most useful for the current task.

[0126] Among them, each hyperparameter includes the learning rate, the random dropout ratio, and the number of units in each of the bidirectional long short-term memory networks;

[0127] In the optimization, the CPO hyperparameter optimization mechanism is used to avoid local optimal traps in the solution space. The crown porcupine will share information through group collaboration to improve the efficiency of foraging. In the algorithm, this is similar to information sharing or the propagation of global solutions, which is used to accelerate convergence. CPO hyperparameter optimization can find the optimal parameter permutation and combination in the CNN-BiLSTM-ATTENTION model. In this model, the parameters involved include the number of units in the LSTM layer, the number of data samples input to the model each time, the number of times the model is trained on the training set, the learning rate of the optimizer, and the ratio of randomly discarded neurons.

[0128] CPO designs and optimizes the process by simulating the following characteristics and behaviors of the crested porcupine: (1) exploration behavior, (2) development behavior, (3) defense behavior, and (4) group collaboration. When foraging, the crested porcupine explores the surrounding environment. This process is used in the algorithm to search the solution space to discover potential global optimal solutions. Once a high-quality food source (i.e., an optimal solution in the solution space) is found, the crested porcupine further optimizes around this area, which corresponds to local search in the algorithm. The crested porcupine protects itself by adjusting its distance from other organisms (e.g., the length and direction of its quills). In optimization, this mechanism is used to avoid local optimal traps in the solution space. The crested porcupine shares information through group collaboration to improve the efficiency of foraging. In the algorithm, this is similar to information sharing or the propagation of global solutions and is used to accelerate convergence.

[0129] When the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model.

[0130] As Figure 2 shown, Figure 2 This is the prediction model structure of the present application based on CPO-CNN-BiLSTM-Attention. This model consists of CPO hyperparameter optimization, an input layer, a CNN layer (convolution layer + pooling layer), a BiLSTM layer (forward LSTM layer and backward LSTM layer), an Attention layer, and an output layer.

[0131] In this preferred embodiment, the present application realizes the efficient processing of power multi-source data and accurate electricity price prediction through an optimized composite neural network model. Specifically, first, historical multi-source data containing various influencing factors is obtained and input into the initial neural network model. The convolutional neural network (CNN) layer is used to perform local feature extraction and dimensionality reduction on the input data to generate the first multi-source data. This process effectively reduces the data complexity and extracts key features. Subsequently, a preset bidirectional long short-term memory network (BiLSTM) is used to establish the bidirectional time-dependent relationship of the data. At the same time, the attention mechanism model is combined to perform dynamic weight allocation on the data during the training process, strengthening the model's ability to focus on important information. On this basis, the crested porcupine optimization algorithm is introduced to perform global search and local optimization on the hyperparameters of BiLSTM (such as the number of units, learning rate, and dropout ratio) to ensure that the model achieves optimal performance in a complex and changing data environment. When the prediction error coefficient of the model meets the preset threshold, the training is terminated. The obtained composite neural network model has high accuracy, strong robustness, and good interpretability, and can effectively improve the accuracy and efficiency of electricity price prediction, providing reliable decision-making support for power market participants.

[0132] As a preferred embodiment of the second embodiment, when the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model, specifically:

[0133] The prediction errors of the initial neural network model include the coefficient of determination, the root mean square error, and the mean absolute percentage error;

[0134] When the coefficient of determination reaches a preset first threshold, the root mean square error reaches a preset second threshold, and the mean absolute percentage error reaches a preset third threshold, the training is stopped to obtain the preset composite neural network model.

[0135] More specifically, R 2 The coefficient of determination measures the explanatory ability of the model for data variation; RMSE measures the average error between the predicted value and the true value of the model; MAPE measures the percentage of the average error between the predicted value and the true value of the model. During the model training process, when the above three indicators simultaneously meet the following conditions, it can be considered that the model training is completed: R 2 Coefficient of determination > 70%, RMSE < 0.1, MAPE < 15%.

[0136] In practical applications, when users obtain independent variable data or have corresponding expectations, these independent variable indicators can be brought into the trained model to predict the day-ahead average price of the Guangdong power spot market on the (t + 1)th day. In this way, users can utilize the prediction ability of the model to plan and make decisions in advance, thereby improving operational efficiency and economic benefits.

[0137] In this preferred embodiment, the present application ensures the high precision and reliability of the composite neural network model through a strict error evaluation system. Specifically, in the training process of the initial neural network model, the coefficient of determination, the root mean square error (RMSE), and the mean absolute percentage error (MAPE) are used as comprehensive evaluation indicators for prediction errors. The coefficient of determination measures the explanatory ability of the model for data variation, RMSE reflects the average error between the predicted value and the true value, while MAPE provides a relative percentage evaluation of the error. When the coefficient of determination reaches the preset first threshold, it indicates that the model has a high degree of fitting to the data; at the same time, when RMSE and MAPE respectively reach the preset second and third thresholds, it shows that the prediction accuracy and stability of the model both meet the requirements. At this time, the training is terminated, and the obtained composite neural network model not only performs well on the training data but also has good generalization ability, which can provide high-precision and reliable electricity price prediction results for power market participants, significantly improving decision-making efficiency and market operation benefits.

[0138] As a preferred embodiment of the second embodiment, obtaining the electricity price prediction result for the target area at a future moment according to the multi-source power data and the preset composite neural network model specifically includes:

[0139] Input the multi-source power data into the composite neural network model, so that the convolutional neural network layer of the composite neural network model performs local feature extraction and dimensionality reduction processing on the multi-source power data to generate first feature data;

[0140] Input the first feature data into the bidirectional long short-term memory network of the composite neural network model, so that the bidirectional long short-term memory network models the bidirectional time dependence through forward and backward chain processing to generate second feature data;

[0141] Input the first feature data into the attention mechanism model of the composite neural network model, so that the attention mechanism model performs dynamic weight allocation on the second feature data, calculates the contribution degree of each time-step feature to the prediction result, and generates weighted feature data;

[0142] According to the weighted feature data, calculate and output the electricity price prediction value for the target area at a future moment through the output layer.

[0143] In this preferred embodiment, the present application realizes the efficient processing of multi-source power data and accurate electricity price prediction through the collaborative action of the multi-layer structure of the composite neural network model. Specifically, first, the multi-source power data is input into the model, and the convolutional neural network (CNN) layer performs local feature extraction and dimensionality reduction processing on the data to generate first feature data. This process effectively extracts the key local information in the data and reduces the computational complexity. Subsequently, the first feature data is input into the bidirectional long short-term memory network (BiLSTM), and its forward and backward chain processing is used to model the bidirectional time dependence to generate second feature data, thereby capturing the long-term dynamic characteristics of the electricity price sequence. Further, the second feature data is input into the attention mechanism model, which dynamically allocates weights and calculates the contribution degree of each time-step feature to the prediction result to generate weighted feature data. This process significantly enhances the model's ability to focus on important information, improving the accuracy and interpretability of the prediction. Finally, based on the weighted feature data, the electricity price prediction value for the target area at a future moment is calculated and output through the output layer. Through this hierarchical processing and feature optimization mechanism, the model can not only accurately predict the electricity price but also adapt to the complex dynamic changes in the power market, providing reliable decision-making support for market participants and significantly improving the operation efficiency of the power market and the rationality of resource allocation.

[0144] This device uses two modules to divide labor and work in coordination, which can more accurately predict electricity prices. This application provides comprehensive and multi-dimensional input information for electricity price prediction by obtaining multi-source power data including meteorological data, energy costs, and market supply and demand indicators at the current moment. These data cover the key factors affecting electricity prices, thus providing a rich feature basis for the model. On this basis, the Crown Porcupine Optimization Algorithm (CPO) is used to optimize the hyperparameters of the initial neural network, ensuring that the model can efficiently find a parameter combination close to the optimal in the high-dimensional non-convex search space, thereby improving the performance and training efficiency of the model. Further, by combining the preset Bidirectional Long Short-Term Memory Network (BiLSTM) and attention mechanism model, the long-term and short-term dependencies of the electricity price sequence can be effectively captured, key features can be highlighted, and the model's ability to focus on important information can be enhanced. Through the training of the historical multi-source data by this composite neural network model, the electricity price prediction results for the future moment in the target area not only have higher accuracy but also stronger robustness and interpretability. This application effectively solves the problem that the prior art cannot accurately predict the future price of the electricity market.

[0145] Embodiment Three:

[0146] An embodiment of this application provides a computer-readable storage medium, which includes a stored computer program. When the computer program runs, it controls the device where the computer-readable storage medium is located to execute the described method for predicting electricity market prices.

[0147] Among them, for the described method for predicting electricity market prices, if it is implemented in the form of a software functional unit and used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, to implement all or part of the processes in the above embodiment methods of the present invention, it can also be completed by a computer program instructing relevant hardware. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by a processor, the steps of the above various method embodiments can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in the form of source code, object code, executable file, or some intermediate form, etc. The computer-readable medium can include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electrical carrier signal, telecommunication signal, and software distribution medium, etc.

[0148] Embodiment Four

[0149] The present application provides a terminal device, including a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements any one of the electricity market price prediction methods described in Embodiment 1.

[0150] In the above specific embodiments, the objectives, technical solutions, and beneficial effects of the present invention have been further described in detail. It should be understood that the above are only specific embodiments of the present invention and are not used to limit the protection scope of the present invention. In particular, for those skilled in the art, any modifications, equivalent replacements, improvements, etc. made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.

Claims

1. A method for predicting electricity market prices, characterized in that: include: Acquire multi-source power data; wherein the multi-source power data includes current meteorological data, energy costs, and market supply and demand indicators; Obtaining a prediction result of the electricity price in the target area at a future time according to the multi-source power data and a preset composite neural network model; Among them, the preset composite neural network model is obtained by training historical multi-source data on the initial neural network based on the crown porcupine optimization algorithm, the preset bidirectional long short-term memory network and the preset attention mechanism model.

2. The method for predicting power market prices according to claim 1, characterized in that: The preset composite neural network model is obtained by training historical multi-source data on the initial neural network according to the crown porcupine optimization algorithm, the preset bidirectional long short-term memory network and the preset attention mechanism model, specifically: Obtain historical multi-source data; Inputting the historical multi-source data into an initial neural network model, so that the initial neural network model performs local feature extraction and dimensionality reduction processing on the input data through a convolutional neural network layer to generate first multi-source data; According to the preset bidirectional long short-term memory network, a bidirectional time dependency relationship is established for the first multi-source data, dynamic weight allocation is performed when the first multi-source data is trained according to the attention mechanism model, and each hyperparameter of the bidirectional long short-term memory network is globally searched and locally optimized according to the crown porcupine optimization algorithm; Wherein, the various hyperparameters include learning rate, random dropout ratio and the number of units of the bidirectional long short-term memory network; When the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model.

3. The method for predicting power market price according to claim 1, characterized in that: The historical multi-source data includes historical meteorological data, historical energy costs and historical market supply and demand indicators; The historical meteorological data include historical wind speed, historical temperature and historical typhoon conditions; The historical energy costs include historical liquefied natural gas prices and coal-fired machine costs; The historical market supply and demand indicators include historical load and historical market prices.

4. The method for predicting power market price according to claim 2, characterized in that: When the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model, which is specifically: The prediction error of the initial neural network model includes R 2 coefficient of determination, root mean square error, and mean absolute percentage error; When the R 2 When the determination coefficient reaches a preset first threshold, the root mean square error reaches a preset second threshold, and the mean absolute percentage error reaches a preset third threshold, the training is stopped to obtain the preset composite neural network model.

5. The method for predicting power market price according to claim 1, characterized in that: The electricity price prediction result of the target area at a future time is obtained based on the electric power multi-source data and the preset composite neural network model, specifically: Inputting the electric power multi-source data into the composite neural network model, so that the convolutional neural network layer of the composite neural network model performs local feature extraction and dimensionality reduction processing on the electric power multi-source data to generate first feature data; Inputting the first feature data into a bidirectional long short-term memory network of a composite neural network model, so that the bidirectional long short-term memory network models a bidirectional time dependency through forward and backward chain processing to generate second feature data; Inputting the first feature data into the attention mechanism model of the composite neural network model, so that the attention mechanism model dynamically assigns weights to the second feature data, calculates the contribution of each time step feature to the prediction result, and generates weighted feature data; According to the weighted feature data, the predicted electricity price value of the target area at a future time is calculated and output through the output layer.

6. A power market price prediction device, characterized in that: include: Acquisition module and prediction module; The acquisition module is used to acquire multi-source power data; wherein the multi-source power data includes current meteorological data, energy costs and market supply and demand indicators; The prediction module is used to obtain the electricity price prediction result of the target area at a future time according to the multi-source power data and the preset composite neural network model; Among them, the preset composite neural network model is obtained by training historical multi-source data on the initial neural network based on the crown porcupine optimization algorithm, the preset bidirectional long short-term memory network and the preset attention mechanism model.

7. The power market price prediction device according to claim 6, characterized in that: The preset composite neural network model is obtained by training historical multi-source data on the initial neural network according to the crown porcupine optimization algorithm, the preset bidirectional long short-term memory network and the preset attention mechanism model, specifically: Obtain historical multi-source data; Inputting the historical multi-source data into an initial neural network model, so that the initial neural network model performs local feature extraction and dimensionality reduction processing on the input data through a convolutional neural network layer to generate first multi-source data; According to the preset bidirectional long short-term memory network, a bidirectional time dependency relationship is established for the first multi-source data, dynamic weight allocation is performed when the first multi-source data is trained according to the attention mechanism model, and each hyperparameter of the bidirectional long short-term memory network is globally searched and locally optimized according to the crown porcupine optimization algorithm; Wherein, the various hyperparameters include learning rate, random dropout ratio and the number of units of the bidirectional long short-term memory network; When the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model.

8. The power market price prediction device according to claim 7, characterized in that: When the prediction error coefficient of the initial neural network model meets the preset error threshold, the training is terminated to obtain the preset composite neural network model, which is specifically: The prediction error of the initial neural network model includes R 2 coefficient of determination, root mean square error, and mean absolute percentage error; When the R 2 When the determination coefficient reaches a preset first threshold, the root mean square error reaches a preset second threshold, and the mean absolute percentage error reaches a preset third threshold, the training is stopped to obtain the preset composite neural network model.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored computer program, wherein when the computer program is executed, the device where the computer-readable storage medium is located is controlled to execute the method for predicting electricity market prices according to any one of claims 1 to 5.

10. A terminal device, characterized in that: The method comprises a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein the processor implements the method for predicting electricity market prices as described in any one of claims 1 to 5 when executing the computer program.

Citation Information

Cited By

  • Electric power spot market price abnormity early warning method, device, equipment and medium

    CN121073521A