Wind power prediction method based on multi-source domain deep transfer learning

By optimizing the multi-source domain deep transfer learning model through Euclidean alignment and dynamic weighting modules, the problems of domain data distribution differences and source domain importance in wind power scenarios are solved, thereby improving the accuracy of wind power prediction.

CN121436243APending Publication Date: 2026-01-30NANJING GUODIAN NANZI WEIMEIDE AUTOMATION CO LTD
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202511402843.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-09-28
Publication Date
2026-01-30

AI Technical Summary

Technical Problem

Existing multi-source domain transfer learning methods in wind power scenarios suffer from problems such as large differences in domain data distribution, Euclidean alignment methods being unsuitable for wind power prediction tasks, and failure to distinguish the importance of source domains, resulting in low prediction accuracy and negative transfer effects.

Method used

The Euclidean alignment method is used to reduce the data distribution difference between the multi-source domain and the target domain. The transfer weight factor is set by the maximum mean difference, a weighted transfer training set is constructed, and a multi-source domain deep transfer learning model is constructed and trained by incorporating a dynamic weight module to adapt to the temporal characteristics of wind power data.

Benefits of technology

It improves the accuracy of wind power prediction, reduces the difference in domain data distribution and the risk of negative migration, optimizes the distinction of the importance of source domain data, and improves the prediction accuracy of new wind farms.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121436243A_ABST
    Figure CN121436243A_ABST
Patent Text Reader

Abstract

The invention discloses a wind power prediction method based on multi-source domain deep transfer learning, and relates to the field of new energy power prediction.The method comprises the steps that the data distribution difference between a multi-source domain and a target domain is reduced through an Euclidean alignment method, and the maximum mean value difference between the domains after optimization is obtained; setting a migration weight factor for each source domain based on the maximum mean value difference, and constructing a weighted migration training set; constructing a multi-source domain deep migration learning model, and carrying out migration training on the model based on a weighted migration training set; and finely tuning the pre-training model according to a small amount of data of the target domain to obtain a target domain wind power prediction model. The wind power data distribution difference between the multi-source domain and the target domain is reduced through the Euclidean alignment method, the knowledge migration efficiency is improved, and the negative migration risk is reduced; setting a migration weight factor for each source domain based on inter-domain MMD, so that the model preferentially learns high-correlation source domain wind power characteristics; and the multi-source domain deep migration learning model is fused into a dynamic weight module, so that low-efficiency migration is avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of new energy power prediction technology, and in particular to a wind power prediction method based on multi-source domain deep transfer learning. Background Technology

[0002] In the field of wind power prediction, newly built wind farms often face underfitting problems in the prediction modeling process due to insufficient accumulation of historical operating data, which seriously restricts the improvement of prediction accuracy. Multi-source domain transfer learning, as a technique that can transfer knowledge from the source domain to the target domain from similar but non-homogeneous tasks, provides a potential path to solve the above problems and has received widespread attention in recent years.

[0003] However, existing multi-source domain transfer learning methods still face significant technical bottlenecks in wind power applications. First, the problem of data distribution differences across multiple source domains is prominent. Specifically, there is a significant inconsistency between the source and target domains in the covariance matrices of key meteorological features such as wind speed and direction. This distribution shift directly leads to increased generalization error in the transfer model, making it difficult to meet actual prediction requirements. Second, although existing Euclidean alignment methods in EEG signal processing can reduce the distribution differences of multi-source data to some extent, these methods cannot directly adapt to the temporal characteristics of wind power prediction tasks and ignore the weight heterogeneity of different meteorological features in wind power scenarios. Therefore, targeted improvements based on the characteristics of wind power data are urgently needed. Finally, existing methods lack effective differentiation of the importance of each source domain and fail to differentiate their utilization based on the actual contribution of different source domains to the target domain's power prediction. This imbalance in source domain importance not only reduces model performance but may also trigger negative transfer effects due to noise introduced by low-importance source domains, further worsening the prediction results. Summary of the Invention

[0004] In view of the prominent problems of existing domain data distribution differences, the inadequacy of existing Euclidean alignment methods for wind power forecasting tasks, and the lack of effective differentiation of the importance of source domain data, this invention is proposed.

[0005] Therefore, the problem to be solved by this invention is how to achieve the above-mentioned goals of reducing the differences in domain data distribution, adaptively modifying the Euclidean alignment method, and optimizing the distinction of the importance of source domain data.

[0006] To solve the above-mentioned technical problems, the present invention provides the following technical solution:

[0007] In a first aspect, embodiments of the present invention provide a wind power prediction method based on multi-source domain deep transfer learning, including: using a Euclidean alignment method to reduce the data distribution difference between the multi-source domain and the target domain, and obtaining the optimized maximum mean difference between the domains;

[0008] A weighted transfer training set is constructed by setting transfer weight factors for each source domain based on the maximum mean difference.

[0009] Construct a multi-source domain deep transfer learning model and perform transfer training on the model based on a weighted transfer training set;

[0010] By fine-tuning the pre-trained model based on a small amount of data from the target domain, a wind power prediction model for the target domain is obtained.

[0011] As a preferred embodiment of the wind power prediction method based on multi-source domain deep transfer learning described in this invention, the method uses Euclidean alignment to reduce the data distribution difference between the multi-source domain and the target domain, and obtains the optimized maximum mean difference between the domains, including:

[0012] Obtain wind power data from N source domains and 1 target domain, where N>2. Perform Z-score standardization independently on the meteorological characteristics and power data of each domain, and use a sliding window to segment the standardized data. The window duration is set to 24 hours by default, the overlap rate is 50% to 75%, and the default sliding step size is 6 to 12 hours.

[0013] Calculate the covariance matrix of each domain, and then combine them using the arithmetic mean to obtain the global average covariance; the formula for calculating the single-domain covariance matrix is:

[0014]

[0015] Among them, X k (t) is a column vector representing the data of the k-th field at time step t;

[0016] The formula for calculating the global average covariance is:

[0017]

[0018] Among them, C s and C t These are the covariance matrices of the wind farm data in the source and target domains, respectively.

[0019] Eigenvalue decomposition is performed on the global average covariance matrix to construct a whitening matrix, and the whitening matrix is ​​used to achieve multi-domain data alignment transformation.

[0020] As a preferred embodiment of the wind power prediction method based on multi-source domain deep transfer learning described in this invention, the method comprises: setting transfer weight factors for each source domain based on the maximum mean difference, and constructing a weighted transfer training set, including:

[0021] Based on the Euclidean-aligned feature data, MMD is used to quantify the similarity between each source domain and the target domain, where the kernel function of MMD is k(X). Si ,X TThe Gaussian kernel is used for calculation, and the calculation formula is as follows:

[0022]

[0023] Among them, For source domain data X Si and target domain data X T The square of the Euclidean distance, with the kernel width σ set to the median d of the pairwise Euclidean distances between all source and target domain feature data samples after Euclidean alignment. med ;

[0024] The embedding vector μ of the source domain S in the reproducing kernel Hilbert space S for:

[0025]

[0026] Where φ is the feature mapping function;

[0027] The embedding vector μ of the target domain T in the reproducing kernel Hilbert space T for:

[0028]

[0029] As a preferred embodiment of the wind power prediction method based on multi-source domain deep transfer learning described in this invention, the method employs MMD to quantify the similarity between each source domain and the target domain, including:

[0030] The formula for calculating MMD is:

[0031]

[0032] Where n and m are the number of samples in the source domain and the target domain, respectively;

[0033] Introduce a regularization term ∈=10 to the base weights. -5 Set MMD threshold ∈ MMD Remove source domain samples with excessively low MMD similarity. For each sample in the source domain, combine the basic weight w. k We integrate weighted source domain samples and target domain samples to construct a weighted transfer learning training set.

[0034] As a preferred embodiment of the wind power prediction method based on multi-source domain deep transfer learning described in this invention, the method comprises: constructing a multi-source domain deep transfer learning model, including:

[0035] The multi-source domain deep transfer learning model includes an input layer, a shared TCN encoder, a dynamic weight module, a regression predictor, and a loss function calculation module. Each module is designed to adapt to the characteristics of wind power data.

[0036] As a preferred embodiment of the wind power prediction method based on multi-source domain deep transfer learning described in this invention, the input layer receives the historical wind power sequence and corresponding meteorological features after sliding window processing, with the input dimension being [window length × number of features]; multi-source domain data X = {X S1 ,X S2 ,…,X Sn}, where X Si =[T Si M Si ,P Si ], T Si Let M be the timestamp sequence of the i-th source region wind farm. Si This is a meteorological feature sequence, including wind speed, wind direction, and air density characteristics, P Si The data consists of historical active power sequence labels, where n represents the number of wind farms in the source domain; the target domain data is X. T =[T T M T ,P T ], where T T M T and P T These are the timestamps, meteorological characteristics, and power sequences of the wind farms in the target domain, respectively.

[0037] A temporal convolutional network is used as a shared encoder E(·). All source and target domain data are input into this encoder to extract the long-term and short-term dependency features of wind power-meteorological data. Specifically, for the i-th source domain data X... si After processing by a temporal convolutional network, the temporal feature representation h of the source domain is obtained. i =E(X) si ); for target domain data X T After processing by a temporal convolutional network, the temporal feature representation h of the target domain is obtained. T =E(X) T The temporal convolutional network employs four layers of causal dilated convolutions. The bottom two layers have 64 filters, and the top two layers have 256 filters. The kernel size is 3, and the dilation factors are [1, 2, 4, 8]. The temporal convolutional network has fewer filters at the bottom layer to capture the basic variation patterns of wind speed and power, and more filters at the top layer to capture the complex features of turbulence and sudden changes in wind direction.

[0038] The dynamic weighting module for optimizing wind power source domain contributions calculates the weights of each source domain to the target domain in real time, taking into account the differences between multiple wind power source domains. The calculation formula is as follows:

[0039]

[0040] in, Let be the weight of the i-th source domain in the t-th training iteration. Based on the maximum mean difference in wind speed distribution, Let α and β be the power prediction loss of the i-th source domain in the t-th iteration, and α and β be the weight adjustment coefficients.

[0041] The regression predictor for wind power output employs a two-layer fully connected network, consisting of an input layer, a fully connected layer, and an output layer. The input layer receives the h output from the temporal convolutional network. T The features are mapped to the wind power prediction values ​​of the target domain after fusion, and the output is the predicted power for the next hour.

[0042] As a preferred embodiment of the wind power prediction method based on multi-source domain deep transfer learning described in this invention, the wind power prediction model training part includes a pre-training stage and a dynamic weight training stage; the pre-training stage uses historical data X = {X} from all source domains. S1 ,X S2 ,…,X Sn The training samples are divided according to a time sliding window, and static MMD weights are used, where the static weights of the i-th source domain are... The static MMD weights are calculated by normalizing the MMD distance of the target domain.

[0043]

[0044] Where γ is the temperature coefficient;

[0045] The dynamic weight training phase includes the following steps: In each iteration, random samples are taken from sliding window samples in both the source and target domains. The default source-to-target domain sample ratio is 7:3, which is dynamically adjusted to 5:5 when the target domain sample size is insufficient. The sampled samples are input into a temporal convolutional network encoder to obtain the source domain features h. i and target domain features h T ;

[0046] The loss of each source domain is calculated using a regression predictor. and target domain loss f MAPE (P(h T ),P T The The calculation formula is:

[0047]

[0048] Where N is the sample size. This represents the predicted power value for the k-th source domain sample. This represents the measured power value of the k-th source domain sample;

[0049] Based on the dynamic weighting formula, the contribution ratio of each source domain is updated, and the total loss L is calculated. The calculation formula is as follows:

[0050]

[0051] Where λ is the target domain loss weight;

[0052] The backpropagation algorithm is used in conjunction with the gradient descent strategy to calculate and update the parameters of the temporal convolutional network encoder and regression predictor, and an early stopping mechanism is used to prevent overfitting.

[0053] As a preferred embodiment of the wind power prediction method based on multi-source domain deep transfer learning described in this invention, the method includes: fine-tuning the pre-trained model based on a small amount of data from the target domain to obtain the wind power prediction model for the target domain, comprising:

[0054] Perform time-series sliding window resampling on the target domain data, keeping the window length consistent with that used during training, and adjust the sampling based on the effective sample size N of the target domain. T Dynamically partition and fine-tune the training and validation sets, N T If the value is greater than 500, set the number of iterations to N. i Every 20 iterations, the MAPE of the fine-tuned test set is calculated, when 500 ≤ N. T <2000, divided at a ratio of 9:1, N i Take 100; if N T ≥2000, divide the training set and test set into an 8:2 ratio for fine-tuning, N i Take 200;

[0055] The Adam optimizer is used, and the initial learning rate is dynamically set according to the amount of data in the target domain. The learning rate decays by 5% every 50 iterations. A mini-batch training process is adopted, with the batch size set to 8. The model with the smallest MAPE on the test set during the fine-tuning process is selected as the final fine-tuned model for wind power prediction in the target domain.

[0056] In a second aspect, embodiments of the present invention provide a computer device, including a memory and a processor, wherein the memory stores a computer program, wherein: when the computer program instructions are executed by the processor, they implement the steps of the wind power prediction method based on multi-source domain deep transfer learning as described in the first aspect of the present invention.

[0057] Thirdly, embodiments of the present invention provide a computer-readable storage medium having a computer program stored thereon, wherein: when the computer program instructions are executed by a processor, they implement the steps of the wind power prediction method based on multi-source domain deep transfer learning as described in the first aspect of the present invention.

[0058] The beneficial effects of this invention are as follows: This invention reduces the distribution difference of wind power data between the multi-source domain and the target domain through the Euclidean alignment method, improves knowledge transfer efficiency, and reduces the risk of negative transfer; it sets transfer weight factors for each source domain based on inter-domain MMD, so that the model prioritizes learning the wind power features of highly correlated source domains; the multi-source domain deep transfer learning model incorporates a dynamic weight module to avoid inefficient transfer caused by initial cognitive bias and adapts to the temporal fluctuations of wind power data and the dynamic revelation process of domain features; the combined methods can effectively improve the accuracy of wind power prediction in the stage of scarce historical data for newly built wind farms. Attached Figure Description

[0059] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0060] Figure 1 This is a flowchart of a wind power prediction method based on multi-source domain deep transfer learning.

[0061] Figure 2 This is a flowchart illustrating a wind power prediction method based on multi-source domain deep transfer learning.

[0062] Figure 3 This is a schematic diagram of the power prediction model framework for a wind power prediction method based on multi-source domain deep transfer learning.

[0063] Figure 4 This is a diagram of a computer device for a wind power prediction method based on multi-source domain deep transfer learning. Detailed Implementation

[0064] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings.

[0065] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.

[0066] Secondly, the term "one embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in different places in this specification does not necessarily refer to the same embodiment, nor is it a single or selective embodiment that is mutually exclusive with other embodiments.

[0067] Example 1

[0068] Reference Figures 1-4 This is the first embodiment of the present invention, which provides a wind power prediction method based on multi-source domain deep transfer learning, including:

[0069] S1: Use Euclidean alignment to reduce the data distribution differences between the source domain and the target domain, and obtain the optimized maximum mean difference between the domains.

[0070] Furthermore, wind power data from N source domains and 1 target domain are acquired, where N>2. The meteorological characteristics and power data of each domain are independently Z-score standardized, and the standardized data are segmented using a sliding window. The window duration is set to 24 hours by default, the overlap rate is 50% to 75%, and the default sliding step size is 6 to 12 hours.

[0071] Calculate the covariance matrix of each domain, and then combine them using the arithmetic mean to obtain the global average covariance; the formula for calculating the single-domain covariance matrix is:

[0072]

[0073] Among them, X k (t) is a column vector representing the data of the k-th field at time step t;

[0074] The formula for calculating the global average covariance is:

[0075]

[0076] Among them, C s and C t These are the covariance matrices of the wind farm data in the source and target domains, respectively.

[0077] Eigenvalue decomposition is performed on the global average covariance matrix to construct a whitening matrix, and the whitening matrix is ​​used to achieve multi-domain data alignment transformation.

[0078] It should be noted that the eigenvalue decomposition process is as follows:

[0079] R = UΛU

[0080] Where U is the eigenvector matrix and Λ is the eigenvalue diagonal matrix; the whitening matrix W is calculated based on the decomposition results, and the calculation formula is:

[0081] W = U(Λ + εI) -1 / 2 U

[0082] Where I is the identity matrix, and the regularization term ∈ is set to 10. -5Numerical instability is avoided by adding a small regularization term to the eigenvalue matrix; the whitening matrix W is applied to all source and target domain data to achieve data alignment, and the transformation formula is:

[0083]

[0084] in, Wind farm data aligned with the k-th source and target domains.

[0085] S2: Set transfer weight factors for each source domain based on the maximum mean difference, and construct a weighted transfer training set.

[0086] Furthermore, based on the Euclidean-aligned feature data, MMD is used to quantify the similarity between each source domain and the target domain, where the kernel function of MMD is k(X). Si ,X T The Gaussian kernel is used for calculation, and the calculation method is as follows:

[0087]

[0088] Among them, For source domain data X Si and target domain data X T The square of the Euclidean distance, with the kernel width σ set to the median d of the pairwise Euclidean distances between all source and target domain feature data samples after Euclidean alignment. med ;

[0089] The embedding vector μ of the source domain S in the reproducing kernel Hilbert space S for:

[0090]

[0091] Where φ is the feature mapping function;

[0092] The embedding vector μ of the target domain T in the reproducing kernel Hilbert space T for:

[0093]

[0094] Furthermore, the MMD calculation method is as follows:

[0095]

[0096] Where n and m are the number of samples in the source domain and the target domain, respectively;

[0097] Introduce a regularization term ∈=10 to the base weights. -5 Set MMD threshold ∈ MMDRemove source domain samples with excessively low MMD similarity. For each sample in the source domain, combine the basic weight w. k We integrate weighted source domain samples and target domain samples to construct a weighted transfer learning training set.

[0098] S3: Construct a multi-source domain deep transfer learning model and perform transfer training on the model based on a weighted transfer training set.

[0099] Furthermore, the multi-source domain deep transfer learning model includes an input layer, a shared TCN encoder, a dynamic weight module, a regression predictor, and a loss function calculation module, with each module designed to adapt to the characteristics of wind power data.

[0100] Furthermore, the input layer receives the historical wind power sequence and corresponding meteorological features after sliding window processing, with the input dimension being [window length × number of features]; multi-source domain data X = {X S1 ,X S2 ,…,X Sn}, where X Si =[T Si M Si ,P Si ], T Si Let M be the timestamp sequence of the i-th source region wind farm. Si This is a meteorological feature sequence, including wind speed, wind direction, and air density characteristics, P Si The data consists of historical active power sequence labels, where n represents the number of wind farms in the source domain; the target domain data is X. T =[T T M T ,P T ], where T T M T and P T These are the timestamps, meteorological characteristics, and power sequences of the wind farms in the target domain, respectively.

[0101] A temporal convolutional network is used as a shared encoder E(·). All source and target domain data are input into this encoder to extract the long-term and short-term dependency features of wind power-meteorological data. Specifically, for the i-th source domain data X... si After processing by a temporal convolutional network, the temporal feature representation h of the source domain is obtained. i =E(X) si ); for target domain data X T After processing by a temporal convolutional network, the temporal feature representation h of the target domain is obtained. T =E(X) TThe temporal convolutional network employs four layers of causal dilated convolutions. The bottom two layers have 64 filters, and the top two layers have 256 filters. The kernel size is 3, and the dilation factors are [1, 2, 4, 8]. The temporal convolutional network has fewer filters at the bottom layer to capture the basic variation patterns of wind speed and power, and more filters at the top layer to capture the complex features of turbulence and sudden changes in wind direction.

[0102] The dynamic weighting module for optimizing wind power source domain contributions calculates the weights of each source domain to the target domain in real time, taking into account the differences between multiple wind power source domains. The calculation method is as follows:

[0103]

[0104] in, Let be the weight of the i-th source domain in the t-th training iteration. Based on the maximum mean difference in wind speed distribution, Let α and β be the power prediction loss of the i-th source domain in the t-th iteration, and α and β be the weight adjustment coefficients.

[0105] The regression predictor for wind power output employs a two-layer fully connected network, consisting of an input layer, a fully connected layer, and an output layer. The input layer receives the h output from the temporal convolutional network. T The features are mapped to the wind power prediction values ​​of the target domain after fusion, and the output is the predicted power for the next hour.

[0106] S4: Fine-tune the pre-trained model based on a small amount of data from the target domain to obtain the wind power prediction model for the target domain.

[0107] Furthermore, the wind power prediction model training component includes a pre-training phase and a dynamic weight training phase; the pre-training phase uses historical data X = {X} from all source domains. S1 ,X S2 ,…,X Sn The learning rate is set to 1e-3, the batch size is 32, and the number of iterations is 200. Training samples are divided using a time sliding window, and static MMD weights are used, where the static weights of the i-th source domain are... The static MMD weights are calculated by normalizing the MMD distance of the target domain.

[0108]

[0109] Where γ is the temperature coefficient;

[0110] The dynamic weight training phase includes the following steps: In each iteration, random samples are taken from sliding window samples in both the source and target domains. The default source-to-target domain sample ratio is 7:3, which is dynamically adjusted to 5:5 when the target domain sample size is insufficient. The sampled samples are input into a temporal convolutional network encoder to obtain the source domain features h. i and target domain features h T ;

[0111] The loss of each source domain is calculated using a regression predictor. and target domain loss f MAPE (P(h T ),P T The The calculation formula is:

[0112]

[0113] Where N is the sample size. This represents the predicted power value for the k-th source domain sample. This represents the measured power value of the k-th source domain sample;

[0114] Based on the dynamic weighting formula, the contribution ratio of each source domain is updated, and the total loss L is calculated. The calculation formula is as follows:

[0115]

[0116] Where λ is the target domain loss weight;

[0117] The backpropagation algorithm is used in conjunction with the gradient descent strategy to calculate and update the parameters of the temporal convolutional network encoder and regression predictor, and an early stopping mechanism is used to prevent overfitting.

[0118] Furthermore, time-series sliding window resampling is performed on the target domain data, with the window length remaining consistent with that during the training phase, and adjusted according to the effective sample size N of the target domain. T Dynamically partition and fine-tune the training and validation sets, N T If the value is greater than 500, set the number of iterations to N. i Every 20 iterations, the MAPE of the fine-tuned test set is calculated, when 500 ≤ N. T <2000, divided at a ratio of 9:1, N i Take 100; if N T ≥2000, divide the training set and test set into an 8:2 ratio for fine-tuning, N i Take 200;

[0119] The Adam optimizer is used, and the initial learning rate is dynamically set according to the amount of data in the target domain. The learning rate decays by 5% every 50 iterations. A mini-batch training process is adopted, with the batch size set to 8. The model with the smallest MAPE on the test set during the fine-tuning process is selected as the final fine-tuned model for wind power prediction in the target domain.

[0120] It should be noted that time-series sliding window resampling was performed on the target domain data, with the window length consistent with that in the training phase. An overlapping sliding window strategy with a step size of 1 was adopted, and the window length was set to 96. The training set and test set were fine-tuned in an 8:2 ratio. The original dimension of the target domain data was (8640, 10), that is, 8640 points and 10 as the feature dimension. After sliding windowing, 8545 samples were generated, and the dataset dimension was (8545, 96, 10), of which 6836 were the training set and 1709 were the test set.

[0121] Using the Adam optimizer, the number of iterations N i The initial learning rate is set to 200, and is dynamically adjusted based on the amount of data in the target domain. When N... T When the value is greater than 2000, the learning rate is 2e-4. Therefore, in this example, the learning rate is set to 2e-4, and it decreases by 5% every 50 iterations. The number of iterations N is selected. i The learning rate is set to 200. After 200 iterations, the learning rate decays to 1.63e-4. The MAPE of the fine-tuned test set is calculated every 20 iterations. A checkpoint saving strategy is adopted. If the loss is lower than the historical best record, the current model parameters are saved as the best checkpoint.

[0122] This embodiment also provides a computer device applicable to the wind power prediction method based on multi-source domain deep transfer learning, including a memory and a processor; the memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions to implement the wind power prediction method based on multi-source domain deep transfer learning proposed in the above embodiment.

[0123] The computer device can be a terminal, comprising a processor, memory, communication interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, carrier networks, NFC (Near Field Communication), or other technologies. The display screen can be an LCD screen or an e-ink screen. The input devices can be a touch layer covering the display screen, buttons, a trackball, or a touchpad on the computer device's casing, or an external keyboard, touchpad, or mouse.

[0124] This embodiment also provides a storage medium storing a computer program that, when executed by a processor, implements the wind power prediction method based on multi-source domain deep transfer learning as proposed in the above embodiments.

[0125] In summary, this invention reduces the distribution differences of wind power data between the multi-source domain and the target domain through Euclidean alignment, thereby improving knowledge transfer efficiency and reducing the risk of negative transfer. Based on inter-domain MMD, it sets transfer weight factors for each source domain, enabling the model to prioritize learning wind power features from highly correlated source domains. The multi-source domain deep transfer learning model incorporates a dynamic weight module to avoid inefficient transfer caused by initial cognitive biases and adapts to the temporal volatility of wind power data and the dynamic revelation process of domain features. Combining these methods, the accuracy of wind power prediction can be effectively improved during periods of scarce historical data for newly built wind farms.

[0126] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.

Claims

1. A wind power prediction method based on multi-source domain deep migration learning, characterized in that, The method comprises the following steps: using the Euclidean alignment method to reduce the data distribution difference between the multi-source domain and the target domain, and obtaining the optimized maximum mean difference between domains; setting a transfer weight factor for each source domain based on the maximum mean difference, and constructing a weighted transfer training set; constructing a multi-source domain deep transfer learning model, and performing transfer training on the model based on the weighted transfer training set; fine-tuning the pre-trained model according to a small amount of data of the target domain to obtain a target domain wind power prediction model.

2. The wind power prediction method based on multi-source domain deep transfer learning according to claim 1, wherein, The method for reducing the data distribution difference between the multi-source domain and the target domain using the Euclidean alignment method, and obtaining the optimized maximum mean difference between domains, comprises the following steps: obtaining wind power data of N source domains and 1 target domain, wherein N>2, independently performing Z-score standardization on the meteorological features and power data of each domain data, and segmenting the standardized data by using a sliding window, wherein the window length is set to 24 hours by default, the overlap rate is 50% to 75%, and the sliding step is 6 to 12 hours by default; calculating the covariance matrix of each domain, and integrating the global average covariance by using the arithmetic mean, wherein the single-domain covariance matrix calculation formula is: where X k (t) is a column vector representing the data of the kth domain at the tth time step; the global average covariance calculation formula is: where C s and C t are the covariance matrices of the source and target wind farm data, respectively. performing eigenvalue decomposition on the global average covariance matrix, constructing a whitening matrix, and applying the whitening matrix to realize multi-domain data alignment transformation.

3. The wind power prediction method based on multi-source domain deep transfer learning according to claim 1, characterized in that: The method for setting a transfer weight factor for each source domain based on the maximum mean difference, and constructing a weighted transfer training set, comprises the following steps: Based on the Euclidean alignment feature data, the MMD is used to quantify the similarity between each source domain and the target domain, wherein the kernel function k(X Si ,X T ) of the MMD is calculated by using a Gaussian kernel, and the calculation formula is as follows: wherein, wherein is the source domain data X Si and target domain data X T is the square of the Euclidean distance, the kernel width σ is set to the median d of all pairwise Euclidean distances between the source domain and target domain feature data samples after Euclidean alignment med ; Embedding vector μ of source domain S in reproducing kernel Hilbert space S is: wherein φ is a feature mapping function; Embedding vector μ in the reproducing kernel hilbert space of the target domain T T is:

4. The wind power prediction method based on multi-source domain deep transfer learning according to claim 3, characterized in that: The method for quantifying the similarity between each source domain and the target domain by using MMD, comprises the following steps: the MMD calculation formula is: wherein n and m are the sample numbers of the source domain and the target domain, respectively. In the basic weight, introduce the regularization term ∈ = 10 -5 , set the MMD threshold ∈ MMD , eliminate the source domain with low MMD similarity, for each sample of the source domain, combine the basic weight w k , integrate the weighted source domain sample and the target domain sample, and construct a weighted transfer learning training set.

5. The wind power prediction method based on multi-source domain deep transfer learning according to claim 1, wherein, The method for constructing a multi-source domain deep transfer learning model, comprises the following steps: The multi-source domain deep transfer learning model comprises an input layer, a shared TCN encoder, a dynamic weight module, a regression predictor, and a loss function calculation module, and each module is designed to adapt to the characteristics of wind power data.

6. The wind power prediction method based on multi-source domain deep transfer learning according to claim 5, characterized in that: The input layer receives the wind power historical power sequence and corresponding meteorological characteristics after sliding window processing, and the input dimension is [window length x feature number]; multi-source domain data X={X S1 , X S2 , …,X Sn} , wherein X Si =[T Si ,M Si ,P Si ], T Si is the time stamp sequence of the i-th source domain wind farm, M Si is the meteorological feature sequence, including wind speed, wind direction and air density features, P Si is the historical active power sequence label data, and n is the number of source domain wind farms; target domain data X T =[T T ,M T ,P T ], wherein T T , M T and P T are the time stamp, meteorological feature and power sequence of the target domain wind farm respectively; The time series convolution network is used as a shared encoder E(·), and all source domain and target domain data are input into the encoder to extract long and short term dependence features of wind power-weather data. Wherein, the i-th source domain data X si is processed by the time series convolution network to obtain the source domain time series feature representation h i =E(X si ); the target domain data X T is processed by the time series convolution network to obtain the target domain time series feature representation h T =E(X T ); 4 layers of causal dilated convolution are used, the bottom two layers of convolution are set to 64, the top two layers of convolution are set to 256 filters, the convolution kernel size is 3, and the dilated factor is [1, 2, 4, 8]; the number of filters at the bottom of the time series convolution network is small, which is used to capture the basic change law of wind speed and power; the number of filters at the top is large, which is used to capture the complex features of turbulence and wind direction mutation; The dynamic weight module of the wind power source domain contribution optimization calculates the weight of each source domain to the target domain in real time according to the differences among the wind power source domains The calculation formula is: wherein, is the weight of the ith source domain in the tth training iteration, is the maximum mean discrepancy based on wind speed distribution, is the power prediction loss of the ith source domain in the tth iteration, and a, b are weight adjustment coefficients. The regression predictor of the wind power output adopts a two-layer fully connected network, and the structure includes an input layer, a fully connected layer and an output layer. The input layer is used for receiving the h T The features are mapped to the target domain wind power prediction value, and the output is the future 1-hour predicted power.

7. The wind power prediction method based on multi-source domain deep transfer learning according to claim 1, characterized in that: The wind power prediction model training part comprises a pre-training stage and a dynamic weight training stage; the pre-training stage adopts historical data X = {X S1 ,X S2 ,…,X Sn} of all source domains, divides training samples according to a time sliding window, and adopts a static MMD weight, wherein the static weight of the i th source domain is obtained by normalizing the MMD distance of the target domain, and the static MMD weight calculation formula is: wherein γ is a temperature coefficient; The dynamic weight training stage includes the following steps: randomly sampling from the sliding window samples of each source domain and the target domain in each iteration, and the source-target domain sample ratio is 7:3 by default. When the amount of target domain samples is insufficient, it is dynamically adjusted to 5:5; the sampled samples are input into the time sequence convolution network encoder to obtain the source domain feature h i and the target domain feature h T ; calculating the loss of each source domain by a regression predictor and target domain loss f MAPE (P(h T ), P T ), the calculation formula is: ​ wherein N is the number of samples, is a power prediction value of the kth source domain sample, denotes a power measured value of the kth source domain sample; According to the dynamic weight formula, the contribution proportion of each source domain is updated, and the total loss L is calculated, wherein the calculation formula is: wherein λ is the loss weight of the target domain; The back propagation algorithm is used to calculate the updated parameters of the time series convolutional network encoder and the regression predictor in combination with the gradient descent strategy, and the early stopping mechanism is used to prevent overfitting. 8.The wind power prediction method based on multi-source domain deep transfer learning according to claim 1, wherein: The method for fine-tuning the pre-trained model according to a small amount of data of the target domain to obtain a target domain wind power prediction model, comprises the following steps: Perform time series sliding window resampling on target domain data, window length consistent with training phase, and according to target domain effective sample size N T Dynamically divide fine-tuning training set and validation set, N T >500, the number of iterations is set to N i times, and the MAPE of the fine-tuning test set is calculated every 20 iterations, when 500≤N T <2000, divide according to the ratio of 9:1, N i Take 100; if N T ≥2000, divide the fine-tuning training set and test set according to the ratio of 8:2, N i Take 200; The Adam optimizer is used to dynamically set the initial learning rate according to the data amount of the target domain, and the learning rate is attenuated by 5% every 50 iterations; the process of small batch training is used, the batch size is set to 8, the model with the minimum MAPE of the test set in the fine-tuning process is selected as the final fine-tuned model, and is used for target domain wind power prediction. 9.A computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the computer device is characterized in that: The processor executes the computer program to realize the steps of the wind power prediction method based on multi-source domain deep transfer learning according to any one of claims 1 to 8.

10. A computer readable storage medium having stored thereon a computer program, characterized in that: The computer program is executed by the processor to realize the steps of the wind power prediction method based on multi-source domain deep transfer learning according to any one of claims 1 to 8.

Citation Information

Cited By

  • TCN-based cross-basin water quality migration prediction method and system

    CN121598024A

  • Shield tunneling parameter prediction method based on multi-source domain transfer learning

    CN121659285A

  • A wind farm power prediction method and system without historical power data

    CN122286206A