Wind power cluster equivalent modeling method and device based on transformer-biGRU parallel network, equipment and medium
By adopting an equivalent modeling method for wind power clusters based on Transformer-BiGRU parallel networks, the problems of large computational load and difficulty in obtaining parameters in traditional wind power cluster modeling are solved, achieving efficient equivalent modeling of wind power clusters and improving the safety and stability of the power grid.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- 国网重庆市电力公司石柱供电分公司
- Filing Date
- 2026-02-26
- Publication Date
- 2026-06-02
Smart Images

Figure CN122133491A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of wind power cluster modeling technology, and in particular to a method, apparatus, equipment and medium for equivalent modeling of wind power clusters based on Transformer-BiGRU parallel networks. Background Technology
[0002] Currently, with the deepening implementation of the "dual-carbon" target strategy, new energy sources, represented by wind power, are being rapidly integrated into my country's power system on a large scale and in clusters. Large-scale wind power clusters have transformed from "supplementary power sources" to "active power sources," and their dynamic behavior has an increasingly profound and complex impact on the safe and stable operation of the power grid. While traditional detailed electromagnetic transient modeling based on physical mechanisms can accurately characterize the dynamic characteristics of a single or a small number of wind turbines, it faces severe challenges when simulating clusters containing dozens or even hundreds of wind turbines. These challenges include excessively high model order, explosive growth in simulation computation, and difficulties in obtaining parameters, making it difficult to meet the urgent needs of power grid planning and operation mode arrangements.
[0003] As can be seen from the above, how to improve the efficiency of equivalent modeling of wind power clusters is an urgent problem to be solved. Summary of the Invention
[0004] In view of this, the purpose of this invention is to provide a method, apparatus, device, and medium for equivalent modeling of wind power clusters based on Transformer-BiGRU parallel networks, which can improve the efficiency of equivalent modeling of wind power clusters in the process of equivalent modeling based on Transformer-BiGRU parallel networks. The specific solution is as follows: Firstly, this application provides a method for equivalent modeling of wind power clusters based on Transformer-BiGRU parallel networks, including: A wind power cluster simulation model was built using mathematical models corresponding to each wind turbine, and the time series dataset corresponding to the wind power cluster simulation model was divided to obtain a training set, a validation set, and a test set. A two-branch parallel network including a Transformer model and a bidirectional gated recurrent unit is constructed to obtain global dependency features corresponding to the time series dataset by utilizing the multi-head self-attention mechanism and feedforward neural network in the Transformer model. Then, the forward gated recurrent unit layer and the reverse gated recurrent unit layer in the bidirectional gated recurrent unit are used to extract the local bidirectional dynamic features corresponding to the time series dataset. The global dependency features and the local bidirectional dynamic features are fused to obtain the result to be processed. The result to be processed is then subjected to nonlinear fusion and dimensionality reduction using a preset fully connected layer to obtain the prediction sequence. Determine the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network, encode the structural hyperparameters and training hyperparameters to obtain the parameter vector to be optimized, and then use the Grey Wolf optimization algorithm and the prediction sequence to iteratively optimize the parameter vector to be optimized to obtain the target hyperparameter combination. Based on the target hyperparameter combination and the dual-branch parallel network, a model to be processed is constructed. The model to be processed is then processed using the training set, the validation set, and the test set to obtain a target model. The target model is then used to perform equivalent modeling of wind power clusters.
[0005] Optionally, the step of building a wind power cluster simulation model using mathematical models corresponding to each wind turbine, and dividing the time-series dataset corresponding to the wind power cluster simulation model to obtain a training set, a validation set, and a test set, includes: Determine the wind speed, point of common coupling voltage, and turbine parameter set corresponding to each wind turbine, and determine the mathematical model corresponding to each wind turbine; the turbine parameter set includes the control parameters and generator inertia corresponding to the wind turbine. The dynamic characteristics corresponding to the wind turbine are generated by using a preset time state equation and based on the wind speed, the voltage of the point of common coupling, and the set of turbine parameters. The simulation model of the wind power cluster is built using the mathematical model. The preset time state equation is an equation determined based on the turbine type and control strategy corresponding to the wind turbine. The active power and reactive power corresponding to each wind turbine are determined by using a preset nonlinear function and based on the wind speed, the voltage at the point of common coupling, the set of turbine parameters, and the dynamic characteristics. The cut-in wind speed and cut-out wind speed corresponding to the wind speed are determined, and the wind speed is cut in the cut-in wind speed and the cut-out wind speed using a preset step size to obtain a wind speed sequence. Then, the three-phase short circuit fault information with different drop depths and durations is simulated using the wind power cluster simulation model. A time series dataset is constructed based on the wind speed sequence, the three-phase short circuit fault information, the active power and the reactive power. Then, the time series dataset is standardized and divided to obtain a training set, a validation set and a test set.
[0006] Optionally, the construction of a two-branch parallel network including a Transformer model and bidirectional gated recurrent units, to utilize the multi-head self-attention mechanism and feedforward neural network in the Transformer model to obtain global dependency features corresponding to the time-series dataset, includes: A dual-branch parallel network structure including a Transformer model and a bidirectional gated recurrent unit is constructed, and the encoder layer in the Transformer model is determined. The input projection layer in the encoder layer is used to project the time series dataset into a high-dimensional feature space that satisfies the preset high-dimensional conditions based on preset learning parameters, so as to obtain the projection result. The multi-head self-attention mechanism layer and the feedforward neural network layer in the encoder layer are used to capture global dependency features of the projection result based on a preset scaling factor and matrix dimension, so as to obtain global dependency features corresponding to the time series dataset; the feedforward neural network layer includes several linear transformation layers and activation functions.
[0007] Optionally, the step of extracting local bidirectional dynamic features corresponding to the time-series dataset using the forward-gated recurrent unit layer and the reverse-gated recurrent unit layer in the bidirectional gated recurrent unit includes: The time-series dataset is recursively processed from both positive and negative directions using a recurrent neural network layer in the bidirectional gated recurrent unit and a preset activation function to obtain local context information between adjacent time steps in the time-series dataset. The recurrent neural network layer is stacked with a forward gated recurrent unit layer and a reverse gated recurrent unit layer. The forward gated recurrent unit layer is used to capture future time-series information of the time-series dataset, and the reverse gated recurrent unit layer is used to capture historical time-series information of the time-series dataset. Based on the local context information, the weight parameters and configuration parameters corresponding to the time series dataset are determined, and the corresponding local bidirectional dynamic features are determined based on the weight parameters and configuration parameters.
[0008] Optionally, the process of fusing the global dependency features and the local bidirectional dynamic features to obtain the result to be processed, and then using a preset fully connected layer to perform nonlinear fusion and dimensionality reduction on the result to obtain a prediction sequence, includes: A first hidden state corresponding to the Transformer model is determined, and a second hidden state corresponding to the bidirectional gated loop unit is determined. The global dependent feature vector and each of the local bidirectional dynamic feature vectors are then concatenated according to a preset dimension based on the first hidden state and the second hidden state to obtain the result to be processed. The result to be processed is input to each preset fully connected layer including a nonlinear fusion layer, so that the result to be processed is nonlinearly fused by each preset fully connected layer to obtain the fusion result and the weight matrix and bias vector corresponding to the fusion result; The activation function and batch normalization function are used to generate the dimensionality reduction result based on the weight matrix and the bias vector. The dimensionality reduction result is then mapped based on the target dimension to obtain the prediction sequence.
[0009] Optionally, the process of determining the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network, encoding the structural hyperparameters and training hyperparameters to obtain a parameter vector to be optimized, and then using the Grey Wolf optimization algorithm and iteratively optimizing the parameter vector to be optimized based on the prediction sequence to obtain the target hyperparameter combination includes: Determine the hyperparameter combination corresponding to the dual-branch parallel network, and encode the structural hyperparameters and the training hyperparameters to obtain the parameter vector to be optimized; the hyperparameter combination includes structural hyperparameters corresponding to model capacity and expressive power, and training hyperparameters corresponding to the model training process; A current gray wolf population, including the positions of several current gray wolf individuals, is randomly generated within the parameter space corresponding to the parameter vector to be optimized; wherein, each position of the current gray wolf individual corresponds one-to-one with the hyperparameter combination; Based on the hyperparameter combination corresponding to the current position of each gray wolf individual in the current gray wolf population, the dual-branch parallel network is configured to obtain the current configuration result. The performance of the current configuration result is evaluated using the validation set to obtain the current mean square error between the network output predicted sequence and the real sequence. Then, the current mean square error is set as the current fitness value corresponding to the gray wolf individual. Based on the current fitness value, each gray wolf individual in the current population is sorted, and according to the order of fitness value from largest to smallest, the three gray wolves with the top three fitness values are defined as the current first wolf, the current second wolf, and the current third wolf with the corresponding leadership position. The current gray wolf population is obtained by using a position update formula to simulate cooperative hunting in wolf packs and updating the positions of other gray wolves based on the current positions of the first, second, and third wolves respectively. Determine whether the current gray wolf population meets the preset iteration stopping condition. If the current gray wolf population does not meet the preset iteration stopping condition, then jump back to the step of randomly generating the current gray wolf population, which includes the positions of several current gray wolf individuals, in the parameter space corresponding to the parameter vector to be optimized, until the current gray wolf population meets the preset iteration stopping condition, and decode the position vector corresponding to the current first wolf to obtain the target hyperparameter combination.
[0010] Optionally, the step of constructing a model to be processed based on the target hyperparameter combination and the dual-branch parallel network, and processing the model to be processed using the training set, the validation set, and the test set to obtain a target model, and using the target model to perform equivalent modeling of wind power clusters, includes: Based on the target hyperparameter combination, configure the structural parameters and training parameters of the dual-branch parallel network to obtain the model to be processed. Then, use the training set to perform supervised training on the model to be processed to obtain the prediction sequence. The deviation between the predicted sequence and the true sequence is determined using a loss function to obtain the training loss. Then, an optimizer is used to update the initial weight parameters corresponding to the model to be processed based on the training loss to obtain the target weight parameters. The learning rate of the optimizer is dynamically adjusted using a preset learning rate scheduling strategy, and the performance of the model to be processed is monitored using the validation set to obtain the performance monitoring results. If the performance monitoring results indicate that the corresponding loss value has not decreased within several consecutive training cycles, an early stopping mechanism is triggered, and the model weights at the lowest loss are saved to obtain the initial model. The state corresponding to the initial model is set as the verification state, and the initial model is forward propagated using the verification set to obtain the forward propagation calculation result. Based on the forward propagation calculation result, the node corresponding to the early stopping mechanism is determined to obtain the verified model.
[0011] The test set is used to verify the parameters to be verified between the predicted sequence and the actual sequence corresponding to the verified model, including root mean square error, mean absolute error and coefficient of determination. The active power curve and reactive power time series curve of the verified model are analyzed to obtain the analysis results. Determine whether the parameters to be verified and the analysis results meet the preset conditions. If they do, set the verified model as the target model, and use the target model to perform equivalent modeling of the wind power cluster.
[0012] Secondly, this application provides a wind power cluster equivalent modeling device based on a Transformer-BiGRU parallel network, comprising: The simulation model building module is used to build a wind power cluster simulation model using the mathematical model corresponding to each wind turbine, and to divide the time series dataset corresponding to the wind power cluster simulation model to obtain a training set, a validation set and a test set. A dual-branch parallel network construction module is used to construct a dual-branch parallel network including a Transformer model and a bidirectional gated recurrent unit, so as to use the multi-head self-attention mechanism and feedforward neural network in the Transformer model to obtain the global dependency features corresponding to the time series dataset, and then use the forward gated recurrent unit layer and the reverse gated recurrent unit layer in the bidirectional gated recurrent unit to extract the local bidirectional dynamic features corresponding to the time series dataset respectively. The feature fusion module is used to fuse the global dependent features and the local bidirectional dynamic features to obtain the result to be processed, and to use a preset fully connected layer to perform nonlinear fusion and dimensionality reduction processing on the result to be processed to obtain the prediction sequence. The hyperparameter combination determination module is used to determine the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network, encode the structural hyperparameters and training hyperparameters to obtain the parameter vector to be optimized, and then use the Grey Wolf optimization algorithm and the prediction sequence to iteratively optimize the parameter vector to be optimized to obtain the target hyperparameter combination. The model generation module is used to construct a model to be processed based on the target hyperparameter combination and the dual-branch parallel network, and to process the model to be processed using the training set, the validation set and the test set to obtain a target model, and to use the target model to perform equivalent modeling of the wind power cluster.
[0013] Thirdly, this application provides an electronic device, comprising: Memory, used to store computer programs; A processor is used to execute the computer program to implement the aforementioned wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network.
[0014] Fourthly, this application provides a computer-readable medium for storing a computer program, wherein the computer program, when executed by a processor, implements the aforementioned wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network.
[0015] As can be seen from the above, before performing equivalent modeling of wind power clusters based on Transformer-BiGRU parallel networks, this application needs to build a wind power cluster simulation model using mathematical models corresponding to each wind turbine, and divide the time-series dataset corresponding to the wind power cluster simulation model to obtain training, validation, and test sets. A two-branch parallel network including a Transformer model and bidirectional gated recurrent units is constructed to utilize the multi-head self-attention mechanism and feedforward neural network in the Transformer model to obtain global dependency features corresponding to the time-series dataset. Then, the forward gated recurrent unit layer and the reverse gated recurrent unit layer in the bidirectional gated recurrent unit are used to extract the features corresponding to the time-series dataset. The system extracts the local bidirectional dynamic features of each component; it fuses global dependency features with local bidirectional dynamic features to obtain the result to be processed, and uses a pre-defined fully connected layer to perform nonlinear fusion and dimensionality reduction on the result to obtain a prediction sequence; it determines the structural hyperparameters and training hyperparameters corresponding to the bi-branch parallel network, and encodes the structural hyperparameters and training hyperparameters to obtain the parameter vector to be optimized, and then uses the Grey Wolf optimization algorithm and iterative optimization based on the prediction sequence to obtain the target hyperparameter combination; it constructs the model to be processed based on the target hyperparameter combination and the bi-branch parallel network, and uses the training set, validation set and test set to process the model to be processed to obtain the target model, and uses the target model to perform equivalent modeling of wind power clusters.
[0016] Therefore, this application first needs to build a wind power cluster simulation model using mathematical models corresponding to each wind turbine, and then divide the time-series dataset corresponding to the wind power cluster simulation model to obtain training, validation, and test sets. Secondly, a two-branch parallel network including a Transformer model and bidirectional gated recurrent units is constructed to utilize the multi-head self-attention mechanism and feedforward neural network in the Transformer model to obtain global dependency features corresponding to the time-series dataset. Then, the forward and backward gated recurrent unit layers in the bidirectional gated recurrent unit are used to extract local bidirectional dynamic features corresponding to the time-series dataset. Finally, the global dependency features are fused... The system first identifies local bidirectional dynamic features to obtain the result to be processed. Then, a pre-defined fully connected layer is used to perform nonlinear fusion and dimensionality reduction on the result to obtain a predicted sequence. Next, the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network are determined and encoded to obtain a parameter vector to be optimized. Then, the Grey Wolf optimization algorithm is used to iteratively optimize the parameter vector based on the predicted sequence to obtain a target hyperparameter combination. Finally, a model to be processed is constructed based on the target hyperparameter combination and the dual-branch parallel network. This model is then processed using the training, validation, and test sets to obtain the target model, which is used to perform equivalent modeling of wind power clusters. This improves the efficiency of equivalent modeling of wind power clusters, thereby enhancing the user experience. Attached Figure Description
[0017] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.
[0018] Figure 1 This application discloses a flowchart of an equivalent modeling method for wind power clusters based on a Transformer-BiGRU parallel network. Figure 2 This is a schematic diagram of the basic components of a specific Transformer model disclosed in this application; Figure 3 A schematic diagram of the basic components of a specific BiGRU model disclosed in this application; Figure 4 This application discloses a specific method for equivalent modeling of wind power clusters based on Transformer-BiGRU parallel networks. Figure 5This application discloses a schematic diagram of the topology of a typical wind power cluster of a power supply company. Figure 6 This is a schematic diagram showing the active power and irrelevant power output of a detailed model of a wind power cluster built using MATLAB / Simulink software, as disclosed in this application. Figure 7 This is a schematic diagram illustrating the change of the fitness function index during the optimization process of a specific gray wolf algorithm disclosed in this application. Figure 8 This is a schematic diagram illustrating a specific active power prediction and reactive power prediction disclosed in this application; wherein, Figure 8 (a) is a schematic diagram of active power prediction. Figure 8 (b) is a schematic diagram of reactive power prediction; Figure 9 This application discloses a specific schematic diagram of active power scatter distribution and reactive power distribution; wherein, Figure 9 (a) is a schematic diagram of the scatter distribution of active power. Figure 9 (b) is a schematic diagram of reactive power distribution; Figure 10 This application discloses a specific active power error distribution diagram and a reactive power error distribution diagram; wherein, Figure 10 (a) is a schematic diagram of the active power error distribution. Figure 10 (b) is a schematic diagram of reactive power error distribution; Figure 11 This is a schematic diagram of the wind power cluster equivalent modeling device based on Transformer-BiGRU parallel network disclosed in this application; Figure 12 This is a structural diagram of an electronic device disclosed in this application. Detailed Implementation
[0019] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0020] Traditional detailed electromagnetic transient modeling based on physical mechanisms faces severe challenges when simulating wind turbine clusters containing dozens or even hundreds of turbines, including excessively high model order, explosive growth in simulation computation, and difficulties in parameter acquisition, making it difficult to meet the urgent needs of power grid planning and operation mode arrangement. To address this, this application provides an equivalent modeling method for wind turbine clusters based on a Transformer-BiGRU parallel network, which improves the efficiency of equivalent modeling of wind turbine clusters.
[0021] See Figure 1 As shown in the figure, this invention discloses an equivalent modeling method for wind power clusters based on a Transformer-BiGRU parallel network, including: Step S11: Build a wind power cluster simulation model using the mathematical model corresponding to each wind turbine, and divide the time series dataset corresponding to the wind power cluster simulation model to obtain a training set, a validation set and a test set.
[0022] In this embodiment, data preparation and preprocessing are required: First, a large-scale wind power cluster simulation model containing multiple doubly-fed induction generators (DFIGs) is constructed based on a simplified mathematical model of the wind turbine. Then, time-series data of the wind power cluster output power under different wind speeds, point-of-combination voltages, and grid connection voltage dips are obtained through simulation using the simulation model. A historical dataset is constructed, and this dataset is divided into a training set, a validation set, and a test set. That is, a wind power cluster simulation environment is constructed: Based on the simplified general mathematical model of the DFIG, a detailed model of a large-scale wind power cluster containing a specified number, capacity, and topological connections is built in MATLAB (Matrix Labs) or the Simulink simulation platform (simulation and model are based on a system design platform).
[0023] Subsequently, this application embodiment needs to generate a panoramic simulation dataset: by controlling the simulation model, its input conditions are systematically changed, including: a wind speed sequence that changes with a preset step size between the cut-in wind speed and the cut-out wind speed, and a common coupling point voltage disturbance sequence obtained by simulating three-phase short-circuit faults with different drop depths and durations; running the simulation and recording the total active power and total reactive power output sequences at the grid connection point of the wind power cluster at the corresponding time, thereby forming a historical dataset with "input-output" pairing.
[0024] In one specific implementation, suppose the wind power cluster includes The simplified mathematical model of a doubly-fed wind turbine can be expressed in state-space form: ; In the formula, For the first State variables of the generator set; The active power of the unit. Reactive power Wind speed; The voltage at the point of common coupling; For the unit parameter set, and These are nonlinear functions of the unit's dynamics and output response, respectively, determined by the specific unit type and parameter set. And control strategies are jointly determined. For the first Rate of change of state variables of the unit.
[0025] Furthermore, the above formula can be transformed into a difference form: ,in, This is the current state variable; These are past state variables; For the first The state variables of the generator set.
[0026] The total output of the cluster is: ; Furthermore, embodiments of this application can obtain simulation data under different wind speeds, voltage drop depths, and durations. , and corresponding , Time series data, then build a dataset ,in, , .right After standardization, the training set is divided proportionally. Validation set and test set That is, the historical dataset is organized into standard time-series data samples according to time steps, and divided into training set, validation set and test set according to a preset ratio. Then, the input features and output targets of each dataset are standardized to eliminate the difference in units and improve the numerical stability and convergence efficiency of subsequent model training.
[0027] Thus, the dynamic response of a wind power cluster depends on its internal state, grid voltage, and initial operating wind speed. Therefore, this embodiment of the application, by fully mining historical operating and disturbance data, using measured wind speed and grid connection point voltage as inputs and power dynamics as outputs, can select a suitable deep learning framework through the above formula and its difference form to understand its input-output mapping relationship, thereby realizing data-driven dynamic equivalent modeling of wind power clusters.
[0028] Specifically, a wind power cluster simulation model is built using mathematical models corresponding to each wind turbine. The time-series dataset corresponding to the wind power cluster simulation model is divided into training, validation, and test sets. This includes: determining the wind speed, point-of-combination voltage, and turbine parameter sets corresponding to each wind turbine, and determining the mathematical model corresponding to each wind turbine; the turbine parameter sets include the control parameters and generator inertia corresponding to each wind turbine; generating dynamic characteristics corresponding to each wind turbine using a preset time-state equation based on wind speed, point-of-combination voltage, and turbine parameter sets, and building the wind power cluster simulation model using the mathematical model; the preset time-state equation is based on the wind turbine corresponding to... The equations are determined based on the unit type and control strategy; the active and reactive power corresponding to each wind turbine are determined using a preset nonlinear function based on wind speed, point of common coupling voltage, unit parameter set and dynamic characteristics; the cut-in wind speed and cut-out wind speed corresponding to the wind speed are determined, and the wind speed is cut in the cut-in wind speed and cut-out wind speed using a preset step size to obtain the wind speed sequence; then, a wind power cluster simulation model is built to simulate three-phase short-circuit fault information with different drop depths and durations, and a time series dataset is constructed based on the wind speed sequence, three-phase short-circuit fault information, active power and reactive power; then, the time series dataset is standardized and divided to obtain the training set, validation set and test set.
[0029] Step S12: Construct a dual-branch parallel network including a Transformer model and a bidirectional gated recurrent unit, so as to use the multi-head self-attention mechanism and feedforward neural network in the Transformer model to obtain the global dependency features corresponding to the time series dataset, and then use the forward gated recurrent unit layer and the reverse gated recurrent unit layer in the bidirectional gated recurrent unit to extract the local bidirectional dynamic features corresponding to the time series dataset respectively.
[0030] In this embodiment, a parallel Transformer-BiGRU neural network model needs to be constructed. The model includes a Transformer encoder branch for capturing global dependencies in time series and a gated recurrent unit branch for capturing bidirectional time series features. Subsequently, the parallel Transformer-BiGRU neural network model is trained using training set data, and model performance is evaluated and early stopping is performed using a validation set to obtain initial model parameters. It is worth mentioning that the structure of the above-mentioned parallel Transformer-BiGRU network model includes: an input projection layer, used to map the original input features to a high-dimensional space; a parallel processing core, consisting of the following branches: a Transformer encoder branch: containing several layers of multi-head self-attention mechanism and feedforward neural network, used to learn the long-term global dependencies of the time series; a bidirectional gated recurrent unit branch: containing several layers of bidirectional GRU, used to extract the temporal dynamic features of the sequence from both forward and backward directions; and a feature fusion and output layer, used to concatenate the feature vectors output by the two branches, and perform nonlinear fusion and mapping through a fully connected layer, finally outputting the predicted values of active power and reactive power.
[0031] Furthermore, the Transformer model is a neural network architecture based on an attention mechanism. Its function lies in parallel computation and long-range dependency processing capabilities. Its structure mainly consists of two parts: an encoder and a decoder. Each module contains two core layers: a multi-head attention mechanism and a feedforward neural network layer, connected by residual connections and layer normalization parts. Notably, the Transformer model can effectively capture long-range dependencies in the input data and fully utilizes the self-attention mechanism to encode weights for different long sequences. Simultaneously, its modular design achieves high scalability. A schematic diagram of the basic components of the Transformer model is shown below. Figure 2 As shown.
[0032] The input projection layer of the Transformer model maps the original input sequence to a high-dimensional feature space, and the corresponding expression is shown below: ; in, The input sequence; and For learnable parameters, This is the mapped sequence, which is the input to the Transformer encoder.
[0033] Furthermore, each encoder layer of the Transformer model includes a multi-head self-attention and feedforward network to capture global temporal dependencies: ; in, For query matrix; The key matrix; It is a value matrix; Let be the dimension of the key matrix. This is a scaling factor that can be used to prevent the gradient from vanishing due to excessively large dot product values.
[0034] ; in, The hidden state is the input to the feedforward network; It is a feedforward neural network, which includes two linear transformations and an activation function; For layer normalization operation; For residual connection, This represents the new hidden state obtained after processing through a series of neural network layers.
[0035] Specifically, constructing a two-branch parallel network including a Transformer model and bidirectional gated recurrent units to obtain global dependency features corresponding to the time-series dataset using the multi-head self-attention mechanism and feedforward neural network in the Transformer model can include: constructing a two-branch parallel network structure including a Transformer model and bidirectional gated recurrent units, and determining the encoder layer in the Transformer model, so as to use the input projection layer in the encoder layer to project the time-series dataset into a high-dimensional feature space that meets the preset high-dimensional conditions based on preset learning parameters, and obtain the projection result; using the multi-head self-attention mechanism layer and the feedforward neural network layer in the encoder layer, and capturing the global dependency features of the projection result based on the preset scaling factor and matrix dimension, to obtain the global dependency features corresponding to the time-series dataset; the feedforward neural network layer includes several linear transformation layers and activation functions.
[0036] Furthermore, BiGRU is an enhanced RNN architecture that achieves bidirectional information flow through two GRU layers that process forward and reverse sequences respectively. This structure enables BiGRU to effectively capture long-term dependencies in sequences, thereby improving the model's predictive ability. A schematic diagram of the basic components of the BiGRU model is shown below. Figure 3 As shown. The GRU has a reset gate. With the update gate , It controls the amount of new information combined with historical information. It controls the amount of historical information that is saved to the current timestamp in a timely manner.
[0037] When GRU is used Input of time and the output of the previous moment The corresponding expression when used as input is shown below: ; ; ; ; in, , , , , , and , , These are the weight matrices and bias vectors corresponding to different nodes in the neural network. tanh is the activation function; In a hidden state as a candidate; The hidden state is to be passed on to the next time step. For the present Update the gate status constantly; For the present Input at any moment; This is element-wise multiplication.
[0038] The GRU output behavior is shown below: ; in, Output weight parameters for GRU; For output bias parameters; The output of the GRU is noteworthy. The basic structure of BiGRU consists of two GRU units positioned in opposite directions, one capturing past time-series information and the other capturing future time-series information. Finally, the captured information is output and merged according to corresponding dimensions to enhance the overall model's prediction accuracy.
[0039] Specifically, the method utilizes the forward-gated recurrent unit (RNU) layer and the reverse-gated recurrent unit (RRU) layer within the bidirectional gated recurrent unit to extract local bidirectional dynamic features corresponding to the time-series dataset. This can include: using the recurrent neural network layer within the bidirectional gated recurrent unit and a preset activation function to perform temporal recursive processing on the time-series dataset from both forward and reverse directions to obtain local context information between adjacent time steps in the time-series dataset; the RNU layer consists of stacked forward-gated and reverse-gated RRU layers; the forward-gated RRU layer is used to capture future temporal information of the time-series dataset; the reverse-gated RRU layer is used to capture historical temporal information of the time-series dataset; and weight parameters and configuration parameters corresponding to the time-series dataset are determined based on the local context information, thereby determining the corresponding local bidirectional dynamic features based on the weight parameters and configuration parameters.
[0040] Step S13: Fuse the global dependency features and the local bidirectional dynamic features to obtain the result to be processed, and use a preset fully connected layer to perform nonlinear fusion and dimensionality reduction on the result to be processed to obtain the prediction sequence.
[0041] In this embodiment, to fully integrate the complementary features extracted by the dual-branch structure and achieve a stable mapping from the feature space to the output power, the following fusion and output structure is designed: the global features of the Transformer branch and the local dynamic features of the BiGRU branch are concatenated along the feature dimension, and preliminary fusion and dimensionality reduction are performed through a fully connected layer: ; ; in, The hidden state output by the Transformer encoder; The hidden state output by BiGRU; | represents the concatenation operation; This is the concatenated feature matrix; This is the output of the first layer of fusion. This is the weight matrix for the first layer of fusion; This is the bias vector for the first layer of fusion; For batch normalization; To modify the activation function of the linear unit.
[0042] To further enhance the model's nonlinear expressive power and extract deep features directly related to power dynamics, this embodiment stacks two fully connected layers: ; ; in, This is the output of the first layer of fusion; This is the output of the second layer of fusion; This is the final output; This is the weight matrix for the first layer of fusion; This is the bias vector for the first layer of fusion; This is the weight matrix for the second layer of fusion; This is the bias vector for the second layer fusion.
[0043] It is worth mentioning that the above steps construct a "dual nonlinear mapping" from fused features to the output space, which significantly improves the model's ability to fit complex nonlinear relationships in wind power dynamics.
[0044] Finally, in this embodiment of the application, the refined features are mapped to the target dimension to directly output the predicted active and reactive power sequences of the wind power cluster: ; in, Corresponding to each time step and .
[0045] Furthermore, the aforementioned parallel Transformer-BiGRU network model not only effectively combines global temporal patterns with local dynamic changes, but also suppresses irrelevant noise and strengthens key features crucial for dynamic isometric modeling through stepwise dimensionality reduction and nonlinear transformation. Moreover, the mathematical model of the aforementioned network and the mathematical model of wind turbines and their difference forms show certain similarities, indicating that it is feasible to use the Transformer-BiGRU network to simulate the dynamic characteristics of wind power clusters, thus laying a high-performance network topology foundation for subsequent optimization of the Grey Wolf algorithm.
[0046] Specifically, the process involves fusing global dependency features and local bidirectional dynamic features to obtain the result to be processed. Then, a pre-defined fully connected layer is used to perform nonlinear fusion and dimensionality reduction on the result to obtain a prediction sequence. This process may include: determining a first hidden state corresponding to the Transformer model and a second hidden state corresponding to the bidirectional gated recurrent unit; concatenating the global dependency feature vector and each local bidirectional dynamic feature vector according to a pre-defined dimension based on the first and second hidden states to obtain the result to be processed; inputting the result to be processed into each pre-defined fully connected layer, including the nonlinear fusion layer, to perform nonlinear fusion on the result to obtain the fusion result and the corresponding weight matrix and bias vector; using activation functions and batch normalization functions, and based on the weight matrix and bias vector, generating the result to be reduced in dimensionality; and mapping the result to be reduced in dimensionality based on the target dimension to obtain the prediction sequence.
[0047] Step S14: Determine the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network, encode the structural hyperparameters and training hyperparameters to obtain the parameter vector to be optimized, and then use the Grey Wolf optimization algorithm and the prediction sequence to iteratively optimize the parameter vector to be optimized to obtain the target hyperparameter combination.
[0048] In this embodiment, the Grey Wolf optimization algorithm is used to globally optimize the key hyperparameters of the parallel Transformer-BiGRU neural network model. The key hyperparameters include: the model dimension, number of attention heads, and number of encoder layers in the Transformer branch, the hidden layer dimension and number of layers in the BiGRU branch, and the model dropout rate and learning rate. Subsequently, the optimized hyperparameter configuration is used to update and retrain the model to obtain the optimized dynamic equivalent model of the wind power cluster.
[0049] It is worth mentioning that the process of using the gray wolf optimization algorithm for intelligent hyperparameter optimization is as follows: First, parameter encoding and population initialization are performed: the key hyperparameters to be optimized are encoded as the position vectors X of individual gray wolves; within the preset range of hyperparameter values, a certain number of individuals are randomly generated to form the initial gray wolf population, where each individual represents a complete set of neural network hyperparameter configurations; Second, social hierarchy classification and fitness evaluation are performed: for each individual in the initial population, its model prediction performance on the validation set is evaluated; the prediction performance is measured by the mean squared error between the model prediction value and the true value, and this is used as the fitness value. The population is ranked according to its fitness value to determine the social hierarchy: the individual with the best fitness is... Wolf The second-best fittest individuals are Wolf The third best fit individual is Wolf The remaining individuals are Wolves; then, the position update iteration of the simulated hunting behavior is performed: the approximate distance between the leader and the prey (global optimal solution) is calculated, and the wolf pack is guided to move closer to the leader. The distance and position update formulas are as follows: ; in, for , and The optimal solution after updating the wolf's position; The current location of the wolf pack (possible solution); and for Position coefficients that are updated in real time; and A random number between 0 and 1; is the convergence coefficient.
[0050] Subsequently, the embodiments of this application need to be based on , and The location information provided by the three leader wolves updates the position of each member in the population. Wolf's position: ; ; in, , and correspond , and The distance between the three wolves and their prey , , and , , It corresponds , and The parameter vector of the three wolves , and for Precise coordinates of the prey's location at all times. , and For the corresponding population coordinates, express , and The positions of the three wolves are updated. This ensures that the search process is guided by the current optimal solution while maintaining sufficient randomness to avoid getting trapped in local optima.
[0051] Furthermore, to ensure optimal performance of the Transformer-BiGRU parallel network in the dynamic equivalence task of wind power clusters, this embodiment requires precise optimization of the network structure and key hyperparameters during training. Consideration is given to encoding the key hyperparameters that directly affect model capacity, expressiveness, and training dynamics into a position vector: ; in, For the Transformer model dimension, To focus on the number of heads, For encoder layers, and These represent the hidden layer dimension and the number of layers in the BiGRU algorithm. For random inactivation rate, This is the initial learning rate.
[0052] It is worth mentioning that the optimization objective is to minimize the model's performance on the validation set. The mean squared error of the predictions is used, which directly characterizes the generalization accuracy and equivalence reliability of the model. Therefore, it is set as the fitness loss function. ; in, The size of the validation set (number of samples); Input data; The true label (target value); For using parameters and input The predicted value obtained; It is the square of the L2 norm (mean square error).
[0053] Subsequently, the above evaluation-sorting-update process is repeated cyclically. In each iteration, fitness is re-evaluated and updated based on the updated population. , , The wolf's position; when the preset maximum number of iterations or the leadership level is reached. The algorithm is considered converged when the wolf's fitness no longer significantly improves in consecutive iterations. Finally, the current generation of wolves is output. The position vector corresponding to the wolf This refers to the optimal combination of hyperparameters obtained through global optimization. Then, configuring this optimal hyperparameter combination in the Transformer-BiGRU network yields a high-performance model for dynamic equivalent tasks of a specific wind power cluster, thereby significantly improving model development efficiency while ensuring modeling accuracy.
[0054] Specifically, the structural hyperparameters and training hyperparameters corresponding to the two-branch parallel network are determined and encoded to obtain the parameter vector to be optimized. Then, the gray wolf optimization algorithm is used to iteratively optimize the parameter vector to be optimized based on the prediction sequence to obtain the target hyperparameter combination. This can include: determining the hyperparameter combination corresponding to the two-branch parallel network and encoding the structural hyperparameters and training hyperparameters to obtain the parameter vector to be optimized; the hyperparameter combination includes structural hyperparameters corresponding to model capacity and expressive power, and training hyperparameters corresponding to the model training process; randomly generating a current gray wolf population including several current gray wolf individual positions in the parameter space corresponding to the parameter vector to be optimized; wherein each current gray wolf individual position corresponds one-to-one with the hyperparameter combination; configuring the two-branch parallel network based on the hyperparameter combination corresponding to each current gray wolf individual position in the current gray wolf population to obtain the current configuration result; and using the validation set to evaluate the performance of the current configuration result to obtain the network output prediction sequence and the true comparison. The current mean square error between sequences is calculated, and then set as the current fitness value corresponding to the individual gray wolf. Based on the current fitness value, the gray wolves in the current population are sorted, and the three gray wolves with the highest fitness values are defined as the current first wolf, the current second wolf, and the current third wolf, respectively, with corresponding leadership positions. Using the position update formula for simulating cooperative hunting among wolf packs, and based on the current gray wolf positions corresponding to the current first, second, and third wolves, the positions of the remaining gray wolves are updated to obtain the current gray wolf population. It is then determined whether the current gray wolf population meets the preset iteration stopping condition. If the current gray wolf population does not meet the preset iteration stopping condition, the process jumps back to the step of randomly generating the current gray wolf population, including the positions of several current gray wolf individuals, within the parameter space corresponding to the parameter vector to be optimized, until the current gray wolf population meets the preset iteration stopping condition. Finally, the position vector corresponding to the current first wolf is decoded to obtain the target hyperparameter combination.
[0055] Step S15: Construct a model to be processed based on the target hyperparameter combination and the dual-branch parallel network, and process the model to be processed using the training set, the validation set and the test set to obtain the target model, and use the target model to perform equivalent modeling of the wind power cluster.
[0056] In this embodiment, the optimized dynamic equivalent model of the wind power cluster is evaluated using test set data to verify its modeling accuracy and generalization ability. Subsequently, the fully trained model is applied to an extended dataset, with generated wind speed and voltage signals as input, to predict its dynamic active and reactive power output. That is, after obtaining the hyperparameter combination optimized by the Grey Wolf algorithm... Then, the model training and system evaluation steps are carried out to learn the dynamic input-output mapping relationship of the wind power cluster from the data based on the optimal network structure, and to strictly quantify the generalization performance of the model on unknown data to ensure that it meets the accuracy requirements of engineering applications.
[0057] In one specific implementation, the embodiments of this application use a training set. For the configuration of optimal hyperparameters The Transformer-BiGRU parallel network model was trained under supervision. The following strategies were employed during training to ensure convergence efficiency and stability: First, a loss function is adopted: the mean squared error (MSE) is used as the training objective to directly optimize the overall deviation between the model's predicted power sequence and the true power sequence. ; in, This is the size of the training set (number of samples).
[0058] Secondly, an optimizer is employed: the AdamW optimizer is used, whose introduced decoupling weight decay helps prevent overfitting, and sets the weights to be determined by... Initial dynamic learning rate.
[0059] Furthermore, learning rate scheduling is performed: a cosine annealing scheduling strategy is adopted to make the learning rate vary with the training cycle. A smooth descent from a minimum helps the model to converge stably to a better local optimum in the later stages of training.
[0060] Finally, regularization and early stopping are implemented: In addition to the inherent loss value, the validation set loss is monitored during training. If it does not decrease for several consecutive epochs, the early stopping mechanism is triggered, terminating training and rolling back to the model weights with the lowest validation loss, effectively avoiding overfitting.
[0061] It is worth mentioning that after the model is trained, on an independent test set that has not participated in any training or optimization process... A comprehensive evaluation is conducted. This evaluation not only focuses on the overall error but also delves into the model's performance during different dynamic phases (such as steady-state operation, voltage dip transients, and fault recovery). Core evaluation metrics include root mean square error (RMSE), mean absolute error (MAE), and coefficient of determination (COP). And dynamic response fit analysis: ; ; ; in, The number of samples; For the first The true value of each sample; For the first Predicted values for each sample; This is the average of the true values of all samples.
[0062] In this embodiment, RMSE and MAE quantify the magnitude of the prediction error from different perspectives. The model's ability to interpret power data fluctuations is measured, with a value closer to 1 indicating a higher goodness of fit. Dynamic response fit analysis compares the active and reactive power time-series curves predicted by the model with those of the actual simulation output, especially the response speed and recovery trajectory at critical transient moments such as fault occurrence and clearing, thereby qualitatively evaluating the model's ability to capture complex dynamic physical processes.
[0063] Specifically, a model to be processed is constructed based on a target hyperparameter combination and a dual-branch parallel network. This model is then processed using training, validation, and test sets to obtain a target model. This target model is then used to perform equivalent modeling of wind power clusters. The process includes: configuring the structural and training parameters of the dual-branch parallel network based on the target hyperparameter combination to obtain the model to be processed; then performing supervised training on the model using the training set to obtain a predicted sequence; determining the deviation between the predicted and true sequences using a loss function to obtain the training loss; then using an optimizer and updating the initial weight parameters of the model to be processed based on the training loss to obtain the target weight parameters; dynamically adjusting the learner's learning rate using a preset learning rate scheduling strategy; and monitoring the performance of the model using the validation set to obtain performance monitoring results. If the performance monitoring results indicate... If the corresponding loss value does not decrease within several consecutive training cycles, an early stopping mechanism is triggered, and the model weights at the point of lowest loss are saved to obtain the initial model. The state corresponding to the initial model is set as the validation state, and forward propagation calculation is performed on the initial model using the validation set to obtain the forward propagation calculation results. Based on the forward propagation calculation results, the node corresponding to the early stopping mechanism is determined to obtain the validated model. The test set is used to verify the parameters to be verified between the predicted sequence and the actual sequence corresponding to the validated model, including the root mean square error, mean absolute error, and coefficient of determination. The active power curve and reactive power time series curve of the validated model are analyzed for consistency to obtain the analysis results. It is determined whether the parameters to be verified and the analysis results meet the preset conditions. If they do, the validated model is set as the target model to be used for equivalent modeling of the wind power cluster.
[0064] In one specific implementation, the flowchart corresponding to the embodiment of this application is as follows: Figure 4 As shown: First, based on the simplified mathematical model of wind turbine, a detailed simulation model of wind power cluster is built to generate an "input-output" time series dataset covering multiple wind speeds and voltage drop disturbance scenarios, and then the dataset is standardized and partitioned. Figure 5 The diagram shows the topology of a typical wind power cluster of a power supply company, and the detailed parameters of the wind power cluster are shown in Table 1. Table 1 Detailed Parameters of Wind Power Cluster
[0065] As shown in Table 1, the aforementioned wind power cluster consists of 28 wind farms, each containing 5 doubly-fed induction generator (DFIG) wind turbines with a single turbine capacity of 1.5MW, for a total cluster capacity of 210MW. Each wind turbine has a rated voltage of 1.15kV and is connected to the 25kV collection system via a unit connection and a 10MVA step-up transformer. Each wind farm within the cluster is connected to the 25kV collection system via 28 overhead lines, with each line connecting to 5 wind turbines. The collection system steps up the voltage to 110kV and connects to the 110kV busbar of a 220kV substation via a 10km transmission line. During the simulation, all wind turbines were online, and the low-voltage ride-through control strategy employed a specified current control method.
[0066] Furthermore, the schematic diagram of the active power and irrelevant power output of the detailed model of the wind power cluster built based on MATLAB / Simulink software is shown below. Figure 6 As shown, the constructed detailed model of the wind power cluster operates stably. Its output active and reactive power dynamic response waveforms are smooth and stable, accurately following wind speed changes. When the simulated grid experiences voltage dips, the waveforms accurately capture the dynamic process of the wind turbine's low-voltage ride-through control. The active power exhibits standard short-term dip and recovery characteristics, while the reactive power quickly recovers with reasonable oscillations and attenuation. The overall waveform transitions are natural, the dynamic characteristics are clear, and it matches both theoretical and engineering realities, providing a highly reliable benchmark data source for subsequent data-driven modeling.
[0067] In this study, a three-phase short-circuit fault occurred at the grid connection point of the wind power cluster at t=0.1s, and the fault was cleared at t=0.2s. Different voltage drop depths were obtained by adjusting the grounding impedance, taking cases with voltage drop levels of 50%, 60%, 70%, 80%, and 90%. In each case, the wind speed varied between the cut-in wind speed of 3 m / s and the cut-out wind speed of 25 m / s, with a variation interval of 0.5 m / s. The total data sampling time was 1s, and the sampling interval was 0.001s. Therefore, after comprehensive screening, there were a total of 89 sets of data, each with a length of 1000. At the same time, the training set, validation set, and test set were divided in a 3:1:1 ratio.
[0068] Furthermore, to verify the generalization ability of the equivalent modeling method proposed in this application, this embodiment considers designing a new extended dataset. The core of this design lies in changing the structural parameters of the wind power cluster, aiming to test the model's adaptability to unseen wind power cluster topologies and scales that exceed the training set distribution. The improved design of the new scenario is as follows: the original 140 doubly-fed induction generator (DFIG) turbines are reduced to a detailed wind power cluster model containing 70 DFIG turbines. In this embodiment, the single-unit capacity and basic control strategy remain unchanged; only the cluster size is changed. For the new scenario, simulations are performed using the same wind speed and voltage drop disturbance settings as the original dataset, generating corresponding "input-output" time-series data to form the extended dataset. Subsequently, a parallel Transformer-BiGRU network framework based on the Grey Wolf algorithm for collaborative optimization is constructed. This framework deeply embeds the Grey Wolf optimization algorithm into the model building process, achieving self-optimization of network hyperparameters, ultimately generating a dynamic, accurate, and high-performance equivalent model of the wind power cluster.
[0069] It is worth mentioning that in constructing the parallel Transformer-BiGRU network, the network model training configuration is as follows: 150 iterations; AdamW as the optimizer; the learning rate as the optimal value optimized by the Grey Wolf algorithm, with a weight decay of 0.0001; CosineAnnealingLR as the learning rate scheduler; MSELoss as the loss function; an early stopping patience value of 20; a batch size of 16; and gradient clipping using clip_grad_norm_ with a maximum norm of 1.0. The information on the hyperparameters to be optimized, their physical meaning, and the search range is shown in Table 2. Table 2. Information on the hyperparameters to be optimized, their physical meaning, and the search range.
[0070] In one specific implementation, the platform parameters used in the experimental model of this application embodiment are: Intel(R) Core(TM) i5-10200H processor, NVIDIA GeForce GTX 1650 graphics card, 16G memory, using CPU and GPU hybrid training, PyTorch deep learning framework, and Python 3.11 programming language.
[0071] Furthermore, to optimize the overall parallel network performance, this embodiment uses the Grey Wolf algorithm to optimize the hyperparameters in Table 2, and the change of the fitness function index during the Grey Wolf algorithm optimization process is illustrated in the diagram below. Figure 7 As shown, the relevant parameters of the gray wolf algorithm can be set as follows: gray wolf population size is 8, maximum number of iterations is 50, and the fitness function is the mean squared error on the validation set. Figure 7It can be seen that the global optimum is reached in the early stage of iteration, and then the solution rapidly decreases in a stepwise manner and tends to stabilize. The iteration speed is fast and the performance is excellent. It effectively escapes the situation of local optima, so as to continue to find the optimal solution and achieve the best convergence accuracy.
[0072] Subsequently, after optimization using the Grey Wolf algorithm, the optimal parameters obtained were: Transformer model dimension of 92; number of attention heads of 2; number of Transformer encoder layers of 2; BiGRU hidden layer dimension of 128; number of BiGRU hidden layers of 2; random inactivation rate of 0.1000; initial learning rate of 0.001755. Furthermore, the embodiments of this application require the use of a validation set to perform early stopping and performance evaluation on the optimized hyperparameter training network, and finally to verify the model's generalization ability on an independent test set. Finally, dynamic equivalent modeling of the wind power cluster is performed based on the optimized Transformer-BiGRU network.
[0073] In this embodiment, observations were made on the data of the 8th sample in the test set (wind speed of 8.5 m / s, voltage drop to 60%, three-phase short circuit fault occurring at 0.1 s, fault clearing at 0.2 s). The active power prediction and reactive power prediction diagrams are shown below. Figure 8 As shown, where, Figure 8 (a) is a schematic diagram of active power prediction. Figure 8 (b) is a schematic diagram of reactive power prediction. For all test set samples, the active power scatter distribution and reactive power distribution diagrams are as follows: Figure 9 As shown, where, Figure 9 (a) is a schematic diagram of the scatter distribution of active power. Figure 9 (b) is a schematic diagram of reactive power distribution. The active power error distribution diagram and the reactive power error distribution diagram are shown below. Figure 10 As shown, where, Figure 10 (a) is a schematic diagram of the active power error distribution. Figure 10 (b) is a schematic diagram of reactive power error distribution.
[0074] It is worth mentioning that, from Figure 8 As can be seen, the power prediction curve closely matches the measured curve, and the model accurately captures the transient characteristics of power changes, including peak values, trough values, and fluctuation frequencies. The constructed model demonstrates excellent time-series prediction capabilities. Figure 9 As can be seen, all data points are closely distributed near the y = x reference line, indicating that the model has high-precision prediction capability across the entire power range with no significant systematic bias. Figure 10As can be seen, the error distribution is approximately normal, symmetrically distributed around the zero error line. The symmetry and concentration of the distribution prove that the model has no systematic bias, indicating that the model prediction has high stability and low uncertainty. Therefore, the parallel Transformer-BiGRU network model based on gray wolf optimization proposed in this application demonstrates excellent performance in the equivalent modeling of wind power clusters.
[0075] To verify the equivalent effect of the Transformer-BiGRU network model, this application embodiment still uses the above-mentioned examples and training data as examples, employing ①: Transformer network, ②: BiGRU network, ③: Transformer-GRU network, ④: Transformer-BiLSTM network, and ⑤: Transformer-BiGRU network without Gray Wolf algorithm optimization for modeling. The performance comparison information for modeling on active power output data is shown in Table 3, and the performance comparison information for modeling on reactive power output data is shown in Table 4. Table 3. Comparison of Modeling Performance on Active Power Data
[0076] Table 4. Comparison of Modeling Performance on Reactive Power Data
[0077] In Tables 3 and 4, the embodiments of this application deeply integrate the global attention of Transformer with the bidirectional dynamic capture capability of BiGRU through a parallel architecture, and combine it with the automated global optimization of the Grey Wolf algorithm to achieve the optimal configuration of network structure and hyperparameters. This allows for the precise characterization of local dynamics and bidirectional context information while preserving global temporal dependencies, ultimately achieving dynamic high-precision mapping of the equivalent model of wind power clusters.
[0078] Furthermore, to verify the generalization ability of the dynamic equivalent modeling method on wind power cluster topology in practical engineering, this embodiment uses a fixed Transformer-BiGRU model trained and optimized on the original dataset, followed by prediction using an extended dataset without any additional fine-tuning or retraining. Specifically, the extended dataset shows modeling performance of RMSE: 0.0990 and R²: 0.9887 on active power output data; and RMSE: 0.0869 and R²: 0.9914 on reactive power output data; with an overall R² of 0.9901. Notably, the Transformer-BiGRU model optimized with the Grey Wolf algorithm maintains high prediction accuracy on the extended dataset, effectively adapting to changes in wind power cluster structure and meeting the robustness requirements for models in practical engineering applications.
[0079] As can be seen from the above, the embodiments of this application first need to build a wind power cluster simulation model using mathematical models corresponding to each wind turbine, and divide the time series dataset corresponding to the wind power cluster simulation model to obtain a training set, a validation set, and a test set; secondly, a two-branch parallel network including a Transformer model and a bidirectional gated recurrent unit is constructed to obtain global dependency features corresponding to the time series dataset using the multi-head self-attention mechanism and feedforward neural network in the Transformer model, and then the forward gated recurrent unit layer and the reverse gated recurrent unit layer in the bidirectional gated recurrent unit are used to extract the local bidirectional dynamic features corresponding to the time series dataset respectively; then, the global dependency features are fused. The system uses the combined features and local bidirectional dynamic features to obtain the results to be processed. A pre-defined fully connected layer is then used to perform nonlinear fusion and dimensionality reduction on these results, yielding a predicted sequence. Next, the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network are determined and encoded to obtain a parameter vector to be optimized. The Grey Wolf optimization algorithm is then used to iteratively optimize this parameter vector based on the predicted sequence, resulting in a target hyperparameter combination. Finally, a model to be processed is constructed based on the target hyperparameter combination and the dual-branch parallel network. This model is then processed using the training, validation, and test sets to obtain the target model, which is used for equivalent modeling of wind power clusters. This approach improves the efficiency of equivalent modeling of wind power clusters.
[0080] Accordingly, see Figure 11 As shown, this application also provides a wind power cluster equivalent modeling device based on a Transformer-BiGRU parallel network, comprising: The simulation model construction module 11 is used to build a wind power cluster simulation model using the mathematical model corresponding to each wind turbine, and to divide the time series dataset corresponding to the wind power cluster simulation model to obtain a training set, a validation set and a test set. The dual-branch parallel network construction module 12 is used to construct a dual-branch parallel network including a Transformer model and a bidirectional gated recurrent unit, so as to use the multi-head self-attention mechanism and feedforward neural network in the Transformer model to obtain the global dependency features corresponding to the time series dataset, and then use the forward gated recurrent unit layer and the reverse gated recurrent unit layer in the bidirectional gated recurrent unit to extract the local bidirectional dynamic features corresponding to the time series dataset respectively. The feature fusion module 13 is used to fuse the global dependent features and the local bidirectional dynamic features to obtain the result to be processed, and to use a preset fully connected layer to perform nonlinear fusion and dimensionality reduction processing on the result to be processed to obtain a prediction sequence. The hyperparameter combination determination module 14 is used to determine the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network, encode the structural hyperparameters and training hyperparameters to obtain the parameter vector to be optimized, and then use the gray wolf optimization algorithm and the prediction sequence to iteratively optimize the parameter vector to be optimized to obtain the target hyperparameter combination. The model generation module 15 is used to construct a model to be processed based on the target hyperparameter combination and the dual-branch parallel network, and to process the model to be processed using the training set, the validation set and the test set to obtain a target model, and to use the target model to perform equivalent modeling of the wind power cluster.
[0081] In some specific embodiments, the simulation model construction module 11 may specifically include: The mathematical model determination unit is used to determine the wind speed, point of common coupling voltage, and unit parameter set corresponding to each wind turbine, and to determine the mathematical model corresponding to each wind turbine; the unit parameter set includes the control parameters and generator inertia corresponding to the wind turbine. The simulation model construction sub-unit is used to generate the dynamic characteristics corresponding to the wind turbine based on the wind speed, the point of common coupling voltage and the unit parameter set using a preset time state equation, and to build a wind power cluster simulation model using the mathematical model; the preset time state equation is an equation determined based on the unit type and control strategy corresponding to the wind turbine. The power generation unit is used to determine the active power and reactive power corresponding to each wind turbine unit by using a preset nonlinear function and based on the wind speed, the voltage of the common coupling point, the unit parameter set and the dynamic characteristics. The wind speed sequence determination unit is used to determine the cut-in wind speed and cut-out wind speed corresponding to the wind speed, and to cut the wind speed between the cut-in wind speed and the cut-out wind speed using a preset step size to obtain a wind speed sequence. Then, the unit uses the wind power cluster simulation model to simulate three-phase short-circuit fault information with different drop depths and durations to construct a time-series dataset based on the wind speed sequence, the three-phase short-circuit fault information, the active power and the reactive power. The time-series dataset is then standardized and divided to obtain a training set, a validation set and a test set.
[0082] In some specific embodiments, the dual-branch parallel network construction module 12 may specifically include: The projection result generation unit is used to construct a two-branch parallel network structure including a Transformer model and a bidirectional gated recurrent unit, and to determine the encoder layer in the Transformer model, so as to use the input projection layer in the encoder layer and perform high-dimensional feature space projection on the time series dataset based on preset learning parameters to meet preset high-dimensional conditions, and obtain the projection result. The feature capture unit is used to capture global dependent features of the projection result by utilizing the multi-head self-attention mechanism layer and the feedforward neural network layer in the encoder layer, and based on a preset scaling factor and matrix dimension, to obtain global dependent features corresponding to the time series dataset; the feedforward neural network layer includes several linear transformation layers and activation functions.
[0083] In some specific embodiments, the dual-branch parallel network construction module 12 may specifically include: The context information determination unit is used to perform time-series recursive processing on the time-series dataset from both positive and negative directions using the recurrent neural network layer in the bidirectional gated recurrent unit and a preset activation function to obtain local context information between adjacent time steps in the time-series dataset; the recurrent neural network layer is stacked with a forward gated recurrent unit layer and a reverse gated recurrent unit layer; the forward gated recurrent unit layer is used to capture future time-series information of the time-series dataset; the reverse gated recurrent unit layer is used to capture historical time-series information of the time-series dataset; A bidirectional dynamic feature determination unit is used to determine the weight parameters and configuration parameters corresponding to the time series dataset based on the local context information, so as to determine the corresponding local bidirectional dynamic features based on the weight parameters and configuration parameters.
[0084] In some specific embodiments, the feature fusion module 13 may specifically include: The feature vector concatenation unit is used to determine the first hidden state corresponding to the Transformer model and the second hidden state corresponding to the bidirectional gated loop unit, so as to concatenate the global dependent feature vector and each of the local bidirectional dynamic feature vectors according to a preset dimension based on the first hidden state and the second hidden state to obtain the result to be processed. The result fusion unit is used to input the result to be processed into each preset fully connected layer including a nonlinear fusion layer, so as to use each preset fully connected layer to perform nonlinear fusion on the result to be processed, and obtain the fusion result and the weight matrix and bias vector corresponding to the fusion result; The prediction sequence determination unit is used to generate a dimensionality reduction result based on the weight matrix and the bias vector using an activation function and a batch normalization function, and to map the dimensionality reduction result based on the target dimension to obtain a prediction sequence.
[0085] In some specific embodiments, the hyperparameter combination determination module 14 may specifically include: The hyperparameter encoding unit is used to determine the hyperparameter combination corresponding to the dual-branch parallel network, and to encode the structural hyperparameters and the training hyperparameters to obtain the parameter vector to be optimized; the hyperparameter combination includes structural hyperparameters corresponding to model capacity and expressive power, and training hyperparameters corresponding to the model training process; The current gray wolf population generation unit is used to randomly generate a current gray wolf population, including the positions of several current gray wolf individuals, within the parameter space corresponding to the parameter vector to be optimized; wherein, each position of the current gray wolf individual corresponds one-to-one with the hyperparameter combination; The performance evaluation unit is used to configure the dual-branch parallel network based on the hyperparameter combination corresponding to the position of each gray wolf individual in the current gray wolf population, obtain the current configuration result, and use the validation set to evaluate the performance of the current configuration result to obtain the current mean square error between the network output prediction sequence and the real sequence. Then, the current mean square error is set as the current fitness value corresponding to the gray wolf individual. The gray wolf individual ranking unit is used to rank each gray wolf individual in the current population based on the current fitness value, and to define the three gray wolf individuals with the highest fitness values as the current first wolf, the current second wolf, and the current third wolf with the corresponding leadership position according to the order of fitness values from largest to smallest. The current gray wolf population determination unit is used to update the positions of other gray wolves by using a position update formula for simulating wolf pack cooperative hunting and based on the current gray wolf individual positions corresponding to the current first wolf, the current second wolf, and the current third wolf, respectively. The position vector decoding unit is used to determine whether the current gray wolf population meets the preset iteration stopping condition. If the current gray wolf population does not meet the preset iteration stopping condition, it jumps back to the step of randomly generating the current gray wolf population including the positions of several current gray wolf individuals in the parameter space corresponding to the parameter vector to be optimized, until the current gray wolf population meets the preset iteration stopping condition, and decodes the position vector corresponding to the current first wolf to obtain the target hyperparameter combination.
[0086] In some specific embodiments, the model generation module 15 may specifically include: The model training unit is used to configure the structural parameters and training parameters of the dual-branch parallel network based on the target hyperparameter combination to obtain the model to be processed, and then use the training set to perform supervised training on the model to be processed to obtain the prediction sequence; The deviation determination unit is used to determine the deviation between the predicted sequence and the true sequence using a loss function to obtain the training loss, and then use an optimizer to update the initial weight parameters corresponding to the model to be processed based on the training loss to obtain the target weight parameters. The performance monitoring result determination unit is used to dynamically adjust the learning rate of the optimizer using a preset learning rate scheduling strategy, and to monitor the performance of the model to be processed using the validation set to obtain the performance monitoring result. If the loss value corresponding to the performance monitoring result does not decrease within several consecutive training cycles, an early stopping mechanism is triggered, and the model weights at the lowest loss are saved to obtain the initial model. The state setting unit is used to set the state corresponding to the initial model as the verification state, and to perform forward propagation calculation on the initial model using the verification set to obtain the forward propagation calculation result, and to determine the node corresponding to the early stopping mechanism based on the forward propagation calculation result, so as to obtain the verified model.
[0087] The parameter generation unit is used to generate parameters to be verified, including root mean square error, mean absolute error and coefficient of determination, between the predicted sequence and the true sequence corresponding to the verified model using the test set, and to perform a consistency analysis on the active power curve and reactive power time series curve of the verified model to obtain the analysis results. The parameter judgment unit is used to determine whether the parameter to be verified and the analysis result meet the preset conditions. If they meet the conditions, the verified model is set as the target model so as to use the target model to perform equivalent modeling of the wind power cluster.
[0088] Furthermore, embodiments of this application also disclose an electronic device, Figure 12 This is a structural diagram of an electronic device 20 according to an exemplary embodiment. The content of the diagram should not be construed as limiting the scope of this application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. The memory 22 stores a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the wind power cluster equivalent modeling method based on Transformer-BiGRU parallel networks disclosed in any of the foregoing embodiments. Furthermore, the electronic device 20 in this embodiment may specifically be a computer.
[0089] In this embodiment, the power supply 23 is used to provide operating voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol it follows can be any communication protocol applicable to the technical solution of this application, and is not specifically limited here; the input / output interface 25 is used to acquire external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs, and is not specifically limited here.
[0090] In addition, the memory 22, as a carrier for resource storage, can be a read-only memory, random access memory, disk or optical disk, etc. The resources stored thereon can include operating system 221, computer program 222, etc., and the storage method can be temporary storage or permanent storage.
[0091] The operating system 221 is used to manage and control the various hardware devices on the electronic device 20 and the computer program 222, which may be Windows Server, Netware, Unix, Linux, etc. In addition to including a computer program capable of performing the wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network executed by the electronic device 20 as disclosed in any of the foregoing embodiments, the computer program 222 may further include computer programs capable of performing other specific tasks.
[0092] Furthermore, this application also discloses a computer-readable medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the aforementioned wind power cluster equivalent modeling method based on a Transformer-BiGRU parallel network. Specific steps of this method can be found in the corresponding content disclosed in the foregoing embodiments, and will not be repeated here.
[0093] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section.
[0094] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0095] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented directly by hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of media known in the art.
[0096] Finally, it should be noted that in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0097] The technical solutions provided in this application have been described in detail above. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.
Claims
1. A method for equivalent modeling of wind power clusters based on Transformer-BiGRU parallel networks, characterized in that, include: A wind power cluster simulation model was built using mathematical models corresponding to each wind turbine, and the time series dataset corresponding to the wind power cluster simulation model was divided to obtain a training set, a validation set, and a test set. A two-branch parallel network including a Transformer model and a bidirectional gated recurrent unit is constructed to obtain global dependency features corresponding to the time series dataset by utilizing the multi-head self-attention mechanism and feedforward neural network in the Transformer model. Then, the forward gated recurrent unit layer and the reverse gated recurrent unit layer in the bidirectional gated recurrent unit are used to extract the local bidirectional dynamic features corresponding to the time series dataset. The global dependency features and the local bidirectional dynamic features are fused to obtain the result to be processed. The result to be processed is then subjected to nonlinear fusion and dimensionality reduction using a preset fully connected layer to obtain the prediction sequence. Determine the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network, encode the structural hyperparameters and training hyperparameters to obtain the parameter vector to be optimized, and then use the Grey Wolf optimization algorithm and the prediction sequence to iteratively optimize the parameter vector to be optimized to obtain the target hyperparameter combination. Based on the target hyperparameter combination and the dual-branch parallel network, a model to be processed is constructed. The model to be processed is then processed using the training set, the validation set, and the test set to obtain a target model. The target model is then used to perform equivalent modeling of wind power clusters.
2. The wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network according to claim 1, characterized in that, The process involves constructing a wind power cluster simulation model using mathematical models corresponding to each wind turbine, and dividing the time-series dataset corresponding to the wind power cluster simulation model into a training set, a validation set, and a test set, including: Determine the wind speed, point of common coupling voltage, and turbine parameter set corresponding to each wind turbine, and determine the mathematical model corresponding to each wind turbine; the turbine parameter set includes the control parameters and generator inertia corresponding to the wind turbine. The dynamic characteristics corresponding to the wind turbine are generated by using a preset time state equation and based on the wind speed, the voltage of the point of common coupling, and the set of turbine parameters. The mathematical model is then used to build a simulation model of the wind power cluster. The preset time state equation is an equation determined based on the turbine type and control strategy corresponding to the wind turbine. The active power and reactive power corresponding to each wind turbine are determined by using a preset nonlinear function and based on the wind speed, the voltage at the point of common coupling, the set of turbine parameters, and the dynamic characteristics. The cut-in wind speed and cut-out wind speed corresponding to the wind speed are determined, and the wind speed is cut in the cut-in wind speed and the cut-out wind speed using a preset step size to obtain a wind speed sequence. Then, the three-phase short circuit fault information with different drop depths and durations is simulated using the wind power cluster simulation model. A time series dataset is constructed based on the wind speed sequence, the three-phase short circuit fault information, the active power and the reactive power. Then, the time series dataset is standardized and divided to obtain a training set, a validation set and a test set.
3. The wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network according to claim 1, characterized in that, The construction includes a two-branch parallel network comprising a Transformer model and bidirectional gated recurrent units, to utilize the multi-head self-attention mechanism and feedforward neural network in the Transformer model to obtain global dependency features corresponding to the time-series dataset, including: A dual-branch parallel network structure including a Transformer model and a bidirectional gated recurrent unit is constructed, and the encoder layer in the Transformer model is determined. The input projection layer in the encoder layer is used to project the time series dataset into a high-dimensional feature space that satisfies the preset high-dimensional conditions based on preset learning parameters, so as to obtain the projection result. The multi-head self-attention mechanism layer and the feedforward neural network layer in the encoder layer are used to capture global dependency features of the projection result based on a preset scaling factor and matrix dimension, so as to obtain global dependency features corresponding to the time series dataset; the feedforward neural network layer includes several linear transformation layers and activation functions.
4. The wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network according to claim 1, characterized in that, The step of extracting local bidirectional dynamic features corresponding to the time-series dataset using the forward-gated recurrent unit layer and the reverse-gated recurrent unit layer in the bidirectional gated recurrent unit includes: The time-series dataset is recursively processed from both positive and negative directions using a recurrent neural network layer in the bidirectional gated recurrent unit and a preset activation function to obtain local context information between adjacent time steps in the time-series dataset. The recurrent neural network layer is stacked with a forward gated recurrent unit layer and a reverse gated recurrent unit layer. The forward gated recurrent unit layer is used to capture future time-series information of the time-series dataset, and the reverse gated recurrent unit layer is used to capture historical time-series information of the time-series dataset. Based on the local context information, the weight parameters and configuration parameters corresponding to the time series dataset are determined, and the corresponding local bidirectional dynamic features are determined based on the weight parameters and configuration parameters.
5. The wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network according to claim 1, characterized in that, The process involves fusing the global dependency features and the local bidirectional dynamic features to obtain a result to be processed. A preset fully connected layer is then used to perform nonlinear fusion and dimensionality reduction on the result to obtain a predicted sequence, including: A first hidden state corresponding to the Transformer model is determined, and a second hidden state corresponding to the bidirectional gated loop unit is determined. The global dependent feature vector and each of the local bidirectional dynamic feature vectors are then concatenated according to a preset dimension based on the first hidden state and the second hidden state to obtain the result to be processed. The result to be processed is input to each preset fully connected layer including a nonlinear fusion layer, so that the result to be processed is nonlinearly fused by each preset fully connected layer to obtain the fusion result and the weight matrix and bias vector corresponding to the fusion result; The activation function and batch normalization function are used to generate the dimensionality reduction result based on the weight matrix and the bias vector. The dimensionality reduction result is then mapped based on the target dimension to obtain the prediction sequence.
6. The wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network according to claim 1, characterized in that, The process involves determining the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network, encoding the structural hyperparameters and training hyperparameters to obtain a parameter vector to be optimized, and then using the Grey Wolf optimization algorithm based on the prediction sequence to iteratively optimize the parameter vector to obtain a target hyperparameter combination, including: Determine the hyperparameter combination corresponding to the dual-branch parallel network, and encode the structural hyperparameters and the training hyperparameters to obtain the parameter vector to be optimized; the hyperparameter combination includes structural hyperparameters corresponding to model capacity and expressive power, and training hyperparameters corresponding to the model training process; A current gray wolf population, including the positions of several current gray wolf individuals, is randomly generated within the parameter space corresponding to the parameter vector to be optimized; wherein, each position of the current gray wolf individual corresponds one-to-one with the hyperparameter combination; Based on the hyperparameter combination corresponding to the current position of each gray wolf individual in the current gray wolf population, the dual-branch parallel network is configured to obtain the current configuration result. The performance of the current configuration result is evaluated using the validation set to obtain the current mean square error between the network output predicted sequence and the real sequence. Then, the current mean square error is set as the current fitness value corresponding to the gray wolf individual. Based on the current fitness value, each gray wolf individual in the current population is sorted, and according to the order of fitness value from largest to smallest, the three gray wolves with the top three fitness values are defined as the current first wolf, the current second wolf, and the current third wolf with the corresponding leadership position. The current gray wolf population is obtained by using a position update formula to simulate cooperative hunting in wolf packs and updating the positions of other gray wolves based on the current positions of the first, second, and third wolves respectively. Determine whether the current gray wolf population meets the preset iteration stopping condition. If the current gray wolf population does not meet the preset iteration stopping condition, then jump back to the step of randomly generating the current gray wolf population, which includes the positions of several current gray wolf individuals, in the parameter space corresponding to the parameter vector to be optimized, until the current gray wolf population meets the preset iteration stopping condition, and decode the position vector corresponding to the current first wolf to obtain the target hyperparameter combination.
7. The wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network according to any one of claims 1 to 6, characterized in that, The process of constructing a model to be processed based on the target hyperparameter combination and the dual-branch parallel network, processing the model to be processed using the training set, the validation set, and the test set to obtain a target model, and using the target model to perform equivalent modeling of wind power clusters includes: Based on the target hyperparameter combination, configure the structural parameters and training parameters of the dual-branch parallel network to obtain the model to be processed. Then, use the training set to perform supervised training on the model to be processed to obtain the prediction sequence. The deviation between the predicted sequence and the true sequence is determined using a loss function to obtain the training loss. Then, an optimizer is used to update the initial weight parameters corresponding to the model to be processed based on the training loss to obtain the target weight parameters. The learning rate of the optimizer is dynamically adjusted using a preset learning rate scheduling strategy, and the performance of the model to be processed is monitored using the validation set to obtain the performance monitoring results. If the performance monitoring results indicate that the corresponding loss value has not decreased within several consecutive training cycles, an early stopping mechanism is triggered, and the model weights at the lowest loss are saved to obtain the initial model. The state corresponding to the initial model is set as the verification state, and the initial model is forward propagated using the verification set to obtain the forward propagation calculation result. Based on the forward propagation calculation result, the node corresponding to the early stopping mechanism is determined to obtain the verified model. The test set is used to verify the parameters to be verified between the predicted sequence and the actual sequence corresponding to the verified model, including root mean square error, mean absolute error and coefficient of determination. The active power curve and reactive power time series curve of the verified model are analyzed to obtain the analysis results. Determine whether the parameters to be verified and the analysis results meet the preset conditions. If they do, set the verified model as the target model, and use the target model to perform equivalent modeling of the wind power cluster.
8. A wind power cluster equivalent modeling device based on a Transformer-BiGRU parallel network, characterized in that, include: The simulation model building module is used to build a wind power cluster simulation model using the mathematical model corresponding to each wind turbine, and to divide the time series dataset corresponding to the wind power cluster simulation model to obtain a training set, a validation set and a test set. A dual-branch parallel network construction module is used to construct a dual-branch parallel network including a Transformer model and a bidirectional gated recurrent unit, so as to use the multi-head self-attention mechanism and feedforward neural network in the Transformer model to obtain the global dependency features corresponding to the time series dataset, and then use the forward gated recurrent unit layer and the reverse gated recurrent unit layer in the bidirectional gated recurrent unit to extract the local bidirectional dynamic features corresponding to the time series dataset respectively. The feature fusion module is used to fuse the global dependent features and the local bidirectional dynamic features to obtain the result to be processed, and to use a preset fully connected layer to perform nonlinear fusion and dimensionality reduction processing on the result to be processed to obtain the prediction sequence. The hyperparameter combination determination module is used to determine the structural hyperparameters and training hyperparameters corresponding to the dual-branch parallel network, encode the structural hyperparameters and training hyperparameters to obtain the parameter vector to be optimized, and then use the Grey Wolf optimization algorithm and the prediction sequence to iteratively optimize the parameter vector to be optimized to obtain the target hyperparameter combination. The model generation module is used to construct a model to be processed based on the target hyperparameter combination and the dual-branch parallel network, and to process the model to be processed using the training set, the validation set and the test set to obtain a target model, and to use the target model to perform equivalent modeling of the wind power cluster.
9. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor is configured to execute the computer program to implement the wind power cluster equivalent modeling method based on Transformer-BiGRU parallel network as described in any one of claims 1 to 7.
10. A computer-readable medium, characterized in that, Used to store a computer program, wherein the computer program, when executed by a processor, implements the wind power cluster equivalent modeling method based on a Transformer-BiGRU parallel network as described in any one of claims 1 to 7.