A priori knowledge guided nonmechanistic analytical method for general inverter power supply models

CN121389754BActive Publication Date: 2026-08-28GUANGDONG UNIV OF TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511516245.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-22
Publication Date
2026-08-28
Estimated Expiration
2045-10-22

AI Technical Summary

Technical Problem

[0004]与此同时,在线解析场景存在显著局限:一方面,测量数据的工况覆盖范围与数据量均有限,而增大数据量会导致数据采集成本高、耗时费力,还会引发计算成本攀升、存储开销增加及模型训练时间过长等问题,无法满足在线解析对“短时快速”的核心要求;另一方面,经调研发现,当前多数非机制解析建模方法普遍存在短板,具体包括:所需训练数据量大、对训练数据质量要求高、预测频段覆盖范围窄、仅适用于跟网型控制(GFLI)、需覆盖的训练工况多、模型泛化能力弱、人工超参数调优耗时费力,且仅能预测系统稳态工作点

Benefits of technology

本发明提供的阻抗模型非机制解析方法,仅需输入少工况的在线测量数据,经训练即可实现精确建模。该特性有效解决实际工程中数据采集成本高、耗时费力的问题,同时避免计算成本、存储成本攀升及模型训练时间过长的痛点,大幅降低数据与成本压力,可直接用于在线实时场景。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121389754B_ABST
    Figure CN121389754B_ABST
Patent Text Reader

Abstract

The application discloses a priori knowledge guided general inverter power supply model non-mechanism analysis method, which can realize accurate impedance prediction in a large frequency range by only a small amount of data and working condition points, meets general network following and network construction, and has strong generalization capability. The core is to perform rough sweep frequency on an unknown inverter-based power supply (IBPS) in a range of 1-1000 Hz, divide the frequency range according to the impedance change slope, retain the measured points in the fast change frequency range, use segmented cubic Hermite interpolation to enhance the data in the smooth frequency range, greatly reduce the test points while ensuring the accuracy of the key frequency range, further introduce the Bayesian optimization neural network structure, L 2regularization, EI sampling function and Z-score standardization, and improve the model robustness and generalization capability. The method is suitable for limited working conditions and small sample conditions, and is suitable for network following and network construction control, and has strong generalization capability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of impedance modeling and analysis of novel power systems, and more specifically, to a non-mechanistic analytical method for general inverter power source models guided by prior knowledge. Background Technology

[0002] In new power systems, inverter-type power supplies are increasingly serving as a crucial interface for renewable energy grid connection, playing an unprecedentedly vital role. However, the power system instability caused by large-scale inverter power supply integration is becoming increasingly prominent. Especially under high-penetration grid connection conditions, power grids worldwide have successively experienced oscillations in the 2Hz-2kHz range, the root cause of which lies in the interaction between the control loops of power electronic devices and the power system. Therefore, accurately constructing an IBPS output impedance model and evaluating its impact on grid stability at multiple operating points has become a current research hotspot.

[0003] Impedance modeling methods for power systems are mainly divided into two categories: mechanistic analytical modeling and non-mechanistic identification modeling. The former typically requires establishing an accurate state-space or admittance model and relies on detailed parameter information of the actual product, using theoretical mathematical formulas to analyze the internal operating mechanism of the system. However, in practical applications, due to manufacturers' confidentiality policies, key internal control architecture and parameter information of inverter power supplies are often difficult to obtain, thus limiting the application of analytical modeling in practical engineering. The latter, non-mechanistic identification modeling based on data-driven methods, is often proposed by researchers. This method typically constructs an equivalent impedance model through external disturbance injection and system frequency domain response measurement. Its advantage lies in that it does not require knowledge of the internal physical details of the equipment, meaning modeling can be completed under external conditions. However, during implementation, the selection of sampling frequency points, the amplitude of the disturbance signal, and the quality and coverage of the training data directly affect the model dimensionality and final identification accuracy. If the data quality is insufficient or the coverage is limited, the model's accuracy and generalization ability will be significantly weakened. Therefore, under black-box conditions, impedance measurement based on small-signal injection is highly practical, but it still has limitations: impedance characteristics depend on active power, reactive power, frequency, and operating point. Existing studies mostly target fixed operating points, and the original models become invalid when operating conditions change, making it impossible to accurately assess system stability. This highlights the necessity of developing more universal impedance modeling methods that are adaptable to multiple operating conditions.

[0004] Meanwhile, online analysis scenarios have significant limitations: on the one hand, the coverage and volume of measurement data are limited, and increasing the data volume leads to high data acquisition costs, time and effort, and also causes problems such as rising computational costs, increased storage overhead, and excessively long model training time, failing to meet the core requirement of "short time and fast speed" for online analysis; on the other hand, research has found that most current non-mechanism-based analytical modeling methods generally have shortcomings, including: large required training data volume, high requirements for training data quality, narrow prediction frequency band coverage, applicability only to grid-like control (GFLI), many training conditions to be covered, weak model generalization ability, time-consuming and laborious manual hyperparameter tuning, and the ability to predict only the steady-state operating point of the system. Therefore, there is an urgent need for a general-purpose model with the advantages of "wide prediction frequency band, few training conditions, small required training data volume, and strong generalization ability," which can meet the needs of online analysis and simultaneously adapt to grid-like and grid-like (GFMI) control. Summary of the Invention

[0005] To address the aforementioned technical problems, this invention discloses a non-mechanistic analytical method for general inverter power supply models guided by prior knowledge. This method requires only a small amount of data and operating points to achieve accurate impedance prediction over a wide frequency range, satisfying both grid integration and network construction versatility, and exhibiting strong generalization ability. By combining numerical analysis, model optimization, and experimental prior knowledge, a coarse frequency sweep of 1-1000 Hz is performed on unknown IBPS. The frequency band is divided according to the impedance change slope. Real measurement points are retained in rapidly changing frequency bands, while piecewise cubic Hermite interpolation is used for data augmentation in smooth frequency bands. This significantly reduces the number of test points while maintaining the modeling accuracy of key frequency bands. Furthermore, a Bayesian optimized neural network structure is introduced. L 2. Regularization, expectation-based improvement of the EI sampling function, and Z-score data standardization are used to enhance the robustness and generalization ability of the model. This method is applicable to finite working conditions and small sample conditions, and has good applicability and strong generalization ability under both following-network and network-based control.

[0006] To achieve the above objectives, a first aspect of the present invention provides a priori knowledge-guided non-mechanistic analytical method for general inverter power supply models, comprising:

[0007] S10: Based on the inverter power supply measurement dataset and validation set, a matching impedance model is constructed according to the characteristics of the dataset. The identification framework of the impedance model consists of a basic layer, a core layer, and a target layer. S20: The basic layer of the impedance identification framework uses coarse impedance scanning to obtain the a priori impedance change slope. The knowledge of the a priori impedance change slope is used to guide the sampling of differentiated frequency bands, and combined with segmented cubic Hermite interpolation to complete data enhancement. Finally, Z-score normalization is performed. In this process, a coarse scan is performed on the 1-1000 Hz frequency band under a single operating condition. The frequency band is divided into a critical frequency band and a smooth frequency band according to the first-order rate of change of impedance amplitude and impedance phase relative to frequency. Based on the prior impedance change slope, high-density real sampling points are arranged in the critical frequency band, while only a small number of sampling points are retained in the smooth frequency band. For the smooth frequency band, piecewise cubic Hermite interpolation is used for data enhancement. The piecewise cubic Hermite interpolation formula is as follows:

[0008] In the formula a i ( x )and b i ( x )for:

[0009] in, y i , y i+1 For the corresponding node function value, m i , m i+1 The first derivative of the corresponding node. a i ( x ), a i+1 ( x ) is the weight function for the node function values; b i ( x ), b i+1 ( x ) is the weight function for the nodal derivatives, which guarantees that H i ( x i ) = y i , H i+1 ( x i+1 ) = y i+1 , H ' i ( x i ) = m i , H ' i +1 ( x i+1 ) = mi+1 ; The augmented data is then subjected to Z-score normalization, and the formula for Z-score normalization is as follows:

[0010] in, x normal For the standardized results, x i For the first part of the original data i One sample, x mean The mean of the original data. x std The standard deviation of the original data; S30: Introduction of the core layer of the impedance identification framework L 2. Train a regularized neural network; S40: The target layer of the impedance identification framework uses Bayes' theorem prior knowledge transfer to optimize the model hyperparameters. It performs efficient small-sample search in the space of network depth and width, learning rate, and regularization strength. In each iteration, the historical evaluation of the source task is incorporated into the surrogate model as a prior. After dynamic correction, it is combined with the EI function to maximize the selection of the next evaluation point. The optimal hyperparameter combination is returned for training and the target function value of this round is obtained. After the iteration ends, the optimal hyperparameter combination is used as the final weight and structure configuration of the model.

[0011] Preferably, the dataset and validation set are obtained through a nested parameter scanning method. Specifically, the inverter power supply circuit is built on a hardware-in-the-loop semi-physical simulation platform, and the measured active power data are different. P e reactive power Q e The work point data, and at each work point in different... f The dataset and validation set consist of the true values ​​of the order impedance amplitude and phase. The impedance model employs a four-channel joint prediction structure, which can simultaneously output the amplitude and phase of the positive-sequence and negative-sequence impedances, forming a four-channel joint output impedance model structure. The output impedance is:

[0012] Where |Z + | represents the positive-sequence impedance magnitude, ∠Z + For positive sequence impedance phase, |Z - | represents the magnitude of the negative sequence impedance, ∠Z - It is the negative sequence impedance phase; The error function of the impedance model is defined as the mean of the sum of squares of the four-channel errors. This value also serves as the objective function for Bayesian optimization, and its mathematical expression is:

[0013] in, This represents the predicted value of the neural network; y i_real The values ​​represent the true values ​​of the training samples; the number 4 in the denominator represents the average value of the four channels. i = 4 means the sum of the squares of the four channels; M SE As a loss function, its magnitude directly reflects the accuracy of the established model.

[0014] Preferably, the L 2. Regularization is suitable for handling models with low correlation between four-channel features. Its mathematical expression is:

[0015] in Network weights w The 2-norm, M SE λ is the original loss function, and λ is the regularization parameter.

[0016] Preferably, the Bayesian optimization algorithm serves as prior knowledge to guide model training and obtain optimal hyperparameters. As a global optimization algorithm, it follows Bayes' theorem to fit the probability distribution of the objective function when searching for the optimal hyperparameters, and its formula is as follows:

[0017] in f For black-box objective function, D kn ={( x 1, y 1),( x 2, y 2),…,( x n , y n )} represents the hyperparameter combinations that have already been collected. x n and the corresponding function values y n The set, y n = f ( x n )+ , To account for data acquisition error, , , , They are fMarginal likelihood probability distribution, prior probability distribution, posterior probability distribution, and likelihood probability distribution; The main steps of the Bayesian optimization algorithm are as follows: (1) Use the Gaussian process GP surrogate model to model the relationship between the model prediction effect and the hyperparameter combination, and construct a black box function; (2) Randomly initialize the black box function, and use the expected improvement function EI acquisition function to select the hyperparameter combination with the highest probability that makes the model prediction effect optimal as the next set of evaluation points; (3) Substitute the evaluation points into the objective function to obtain the evaluation value; (4) After training the above steps, select the evaluation point with the best evaluation value from the evaluation set as the model hyperparameter combination; Optimal hyperparameters x best Represented as:

[0018] in f ( x Let ) be the objective function. x best The set of hyperparameters that minimizes the loss in the test dataset; The Gaussian process parameter combination formula for constructing the relationship between the neural network model and its hyperparameters is as follows:

[0019] in x For hyperparameter vectors, f ( x ) is the objective function, which is MSE in this case. m ( x ) is the mean function, K ( x , x' () is the covariance function, which describes the correlation between two input points in the hyperparameter space; The EI function expression is as follows:

[0020]

[0021] in f ( x + () represents the current optimal objective function value. The cumulative distribution function of the standard normal distribution. It is the probability density function of the standard normal distribution.

[0022] This application provides a prior knowledge-guided non-mechanistic analytical method for general inverter power supply models, which has at least the following beneficial effects: The non-mechanical analytical method for impedance modeling provided by this invention requires only a limited amount of online measurement data under a few operating conditions to achieve accurate modeling after training. This feature effectively solves the problems of high data acquisition costs and time-consuming processes in practical engineering, while avoiding the pain points of escalating computational and storage costs and excessively long model training times, significantly reducing data and cost pressures, and can be directly applied to online real-time scenarios.

[0023] The non-mechanical analytical method for impedance modeling provided by this invention can still achieve predictions with a wide frequency band coverage under conditions of few samples. It is applicable to frequency bands where oscillations may occur in real-world scenarios and fully meets the needs of practical engineering for oscillation frequency band analysis.

[0024] The non-mechanistic analytical method for impedance modeling provided by this invention, through the proposed frequency-band sampling strategy, enables the model to achieve accurate modeling in a wider range of applications. It not only supports accurate prediction in grid-type control scenarios, but also adapts to grid-type control scenarios, significantly enhancing its versatility and outperforming existing methods that are only applicable to grid-type conditions.

[0025] The non-mechanical analytical method for impedance models provided by this invention eliminates the need for time-consuming and laborious manual hyperparameter tuning, and still possesses stronger generalization ability even without training. At the same time, the introduction of regularization effectively reduces model complexity, avoids overfitting problems, and further improves the overall performance and stability of the model. Attached Figure Description

[0026] To more clearly illustrate the technical solution of this invention, a portion of the accompanying drawings are provided to offer a further understanding of this application and are not intended to limit this application. In the drawings: Figure 1 This is a flowchart of a non-mechanism-based analytical method for a general inverter power supply model guided by prior knowledge, as described in this invention. Figure 2 This is a block diagram of the connection structure between the inverter power supply and the power grid; Figure 3 This forms the framework for identifying impedance models. Figure 4 This is a schematic diagram of a differentiated frequency band sampling strategy; Figure 5 This is a graph showing the impedance curve variations under multiple operating conditions. Figure 6 A comparison chart of different interpolation strategies; Figure 7 This is a schematic diagram of the model structure of the present invention; Figure 8 This is a graph showing the prediction results of a follow-up network ANN with a small sample size. Figure 9 The image shows the prediction results of the proposed model based on the network pattern in this invention under a small sample size. Figure 10This is a graph showing the prediction results of a network-type ANN with a small sample size. Figure 11 The figure shows the prediction results of the proposed model for the network structure of this invention under small sample conditions. Detailed Implementation

[0027] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, 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.

[0028] Specifically, such as Figure 1 The diagram shown is a flowchart of a non-mechanistic analytical method for a general inverter power supply impedance model guided by prior knowledge, provided in an embodiment of this application. The method includes the following steps S10-S40.

[0029] S10: Based on the inverter power supply measurement dataset and validation set, a matching impedance model is constructed according to the characteristics of the dataset. The identification framework of the impedance model consists of a basic layer, a core layer, and a target layer. S20: The basic layer of the impedance identification framework uses coarse impedance scanning to obtain the a priori impedance change slope. The knowledge of the a priori impedance change slope is used to guide the sampling of differentiated frequency bands, and combined with segmented cubic Hermite interpolation to complete data enhancement. Finally, Z-score normalization is performed. S30: Introduction of the core layer of the impedance identification framework L 2. Train a regularized neural network; S40: The target layer of the impedance identification framework uses Bayes' theorem prior knowledge transfer to optimize the model hyperparameters. It performs efficient small-sample search in the space of network depth and width, learning rate, and regularization strength. In each iteration, the historical evaluation of the source task is incorporated into the surrogate model as a prior. After dynamic correction, it is combined with the EI function to maximize the selection of the next evaluation point. The optimal hyperparameter combination is returned for training and the target function value of this round is obtained. After the iteration ends, the optimal hyperparameter combination is used as the final weight and structure configuration of the model.

[0030] In one specific embodiment, the connection structure between the inverter power supply and the power grid is shown in Figure 2. In traditional power grids, inverter power supplies mostly adopt grid-following control; with the development of the new energy industry, grid-building control is gradually being applied. Therefore, there are currently two main control methods for inverter power supplies, namely grid-following control (GFLI) and grid-building control (GFMI) as shown in Figure 2.

[0031] The steps described above are further explained in detail below as a preferred embodiment.

[0032] The above-mentioned S10 may further include the following steps: S11, by measuring data, we can identify the key factors affecting impedance and construct an impedance matching model based on the data characteristics of these factors. S12, using the impedance model established in S11, measures different active power data. P e reactive power Q e An impedance identification framework is built using the operating point data and the precise impedance values ​​obtained from frequency sweeping. The impedance identification framework consists of three layers.

[0033] In one specific embodiment, in step S12, as follows Figure 3 As shown, this application's impedance model identification framework extends from the conceptual layer to the application layer. Extending the impedance identification framework from the conceptual layer to the application layer forms a three-layer framework consisting of a foundational layer, a core layer, and a target layer, with prior knowledge integrated into this three-layer structure.

[0034] Base Layer: This layer is responsible for data acquisition and preprocessing, including impedance-differentiated frequency band sampling, segmented cubic Hermite interpolation data enhancement, and Z-score normalization to avoid the problem of uneven contributions of features with different dimensions to gradient updates. Furthermore, it enhances the model's robustness while improving convergence speed and stability. This step ensures that the input data covers the dynamic characteristics of key frequency bands and guarantees the consistency of data distribution, providing high-quality driving data for subsequent training.

[0035] Core Layer: This layer is responsible for the main training process of the neural network. The dataset is divided into training and validation sets proportionally, and parameters are updated by establishing a non-linear mapping relationship between the input and output. During training, the following is introduced... L 2. Regularization is used to suppress overfitting, while an early stopping mechanism is used to prevent the model from getting overtrained.

[0036] Target Layer: This layer aims to obtain the final optimal model result. To improve the model's generalization ability and prediction accuracy, this paper introduces Bayes' theorem prior knowledge transfer to optimize the model's hyperparameters. It performs efficient small-sample searches within the space of network depth / width, learning rate, and regularization strength. During each iteration of training, the historical evaluation pairs of the source task are incorporated into the surrogate model as prior knowledge. After dynamic correction, the next evaluation point is selected based on maximizing the expected improvement in the EI function value, and the optimal hyperparameter combination for the next round is returned. This combination is then fed into the model for training, yielding the model's objective function value for this round. After iteration, the optimal hyperparameter combination from the training rounds is used as the model's final weights and structure configuration. This ensures prediction accuracy while avoiding excessive model complexity and getting trapped in local optima, maintaining good generalization ability.

[0037] S13: Using the data from S11 to construct the training and validation sets and the identification framework from S12, an impedance identification model is established.

[0038] In one specific embodiment, a schematic diagram of the differentiated frequency band sampling strategy of this application is shown in Figure 4. The implementation process of this strategy is as follows: First, the prior impedance change slope is obtained through a preliminary impedance coarse scan. Then, key frequency bands and non-key frequency bands are divided by combining key frequency band points. Finally, the above-mentioned prior knowledge is introduced into the subsequent sampling stage to form a differentiated frequency band sampling strategy.

[0039] The multi-condition impedance curve variation of this application is shown in Figure 5. This figure shows the impedance variation of the inverter power supply under different active power conditions. P e With reactive power Q e Under these conditions, both the amplitude and phase of the impedance will change significantly. The upper part of Figure 5 shows the constant reactive power. Q e Variable active power P e The impedance curve variation under the given conditions, with the lower half representing constant active power. P e , variable reactive power Q e The impedance curve changes under various conditions. This phenomenon indicates that the model needs to accurately predict the true impedance values ​​under multiple operating conditions and effectively cover the differences in impedance values ​​between different operating conditions in order to meet the needs of practical applications.

[0040] Figure 6 shows a comparison of different interpolation strategies used in this application. This figure illustrates that when transferring knowledge from numerical analysis to this field, it is crucial to fully consider the unique characteristics of inverter power supply impedance modeling and avoid blindly applying it. Ignoring the specific characteristics of the domain and arbitrarily transferring the knowledge, as shown in Figure 6 under different interpolation position strategies, incorrect interpolation may actually lead to a significant deterioration in model prediction performance.

[0041] In one specific embodiment, in step S13, as Figure 7 The diagram shown is a schematic of the model structure of this application. This framework model adopts a four-channel joint prediction structure, which can simultaneously output the amplitude and phase of the positive-sequence and negative-sequence impedances, forming a four-channel joint output impedance model structure. The output impedance is:

[0042] Where |Z + | represents the positive-sequence impedance magnitude, ∠Z + For positive sequence impedance phase, |Z - | represents the magnitude of the negative sequence impedance, ∠Z - It is the negative sequence impedance phase; The error function of the impedance model is defined as the mean of the sum of squares of the four-channel errors. This value also serves as the objective function for Bayesian optimization, and its mathematical expression is:

[0043] in, This represents the predicted value of the neural network; y i_real The values ​​represent the true values ​​of the training samples; the number 4 in the denominator represents the average value of the four channels. i = 4 means the sum of the squares of the four channels; M SE As a loss function, its magnitude directly reflects the accuracy of the established model.

[0044] In a preferred embodiment, the above-described S20 may further include the following steps: S21, differentiated frequency band sampling: Under a single operating condition, a coarse scan of the 1-1000 Hz frequency band is performed. Based on the first-order rate of change of impedance amplitude / phase relative to frequency, this frequency band is divided into critical frequency bands and smooth frequency bands. Subsequently, high-density real sampling points are deployed in the critical frequency bands, while only a small number of sampling points are retained in the smooth frequency bands. The formation of this strategy is guided by prior knowledge provided by the experimental results shown in Figure 4.

[0045] S22, segmented cubic Hermite interpolation data enhancement. In the experimental phase, data was collected through the injection point of common connection (PCC) to record the active power, reactive power and frequency information of the port. The frequency band corresponding to the collected data was selected as 1-1000Hz.

[0046] In one specific embodiment, in step S22, guided by the prior knowledge shown in Figure 6, a logarithmic non-uniformly distributed sampling method is adopted—sufficient real sample values ​​are preferentially collected in the critical frequency band and the 50Hz negative impedance characteristic frequency band; in non-critical frequency bands, the above-mentioned segmented cubic Hermite interpolation is used for data augmentation, and the augmented data is included in the training set. This method ensures both the smoothness and physical consistency of the impedance curve and significantly reduces redundant measurements. Subsequently, all samples are randomly shuffled and divided into training and validation datasets in a 7:3 ratio to ensure that the model has good generalization ability under different data distributions.

[0047] The interpolation formula is as follows:

[0048] In the formula a i ( x )and b i ( x )for:

[0049] in, y i , y i+1 For the corresponding node function value, m i , m i+1 The first derivative of the corresponding node. a i ( x ), a i+1 ( x ) is the weight function for the node function values; b i ( x ), b i+1 ( x ) is the weight function for the nodal derivatives, which guarantees that H i ( x i ) = y i , H i+1 ( x i+1 ) = y i+1 , H ' i ( x i ) =m i , H ' i+1 ( x i+1 ) = m i+1 ; S23, Z-score normalization, takes into account the differences in scale and measurement errors among different data. Performing this normalization step before actual model training not only avoids the uneven contribution of various features to gradient updates due to different scales, but also improves the model's convergence speed and training stability, further enhancing the model's robustness and effectively improving its generalization ability.

[0050] In one specific embodiment, in step S23, this application employs Z-score normalization to unify the dimensions of the input features, effectively reducing gradient imbalance caused by differences in the dimensions of different physical quantities, improving the numerical stability and convergence speed of training, and suppressing overfitting to a certain extent. It also enhances generalization ability and avoids the drawbacks of maximum and minimum value normalization methods, which are susceptible to outliers and measurement errors. After training, the prediction results are restored to the physical quantity scale through inverse normalization. The normalization formula is shown below:

[0051] in x normal For the standardized results, x i For the first part of the original data i One sample, x mean The mean of the original data. x std This represents the standard deviation of the original data.

[0052] In a preferred embodiment, the above-described S30 may further include the following steps: S31 introduces a regularization mechanism to alleviate overfitting and improve the model's generalization ability. This involves adding a regularization term to the loss function so that the regularization term does not become too large when the loss function is reduced, thus preventing the model from becoming more complex and reducing overfitting.

[0053] In one specific embodiment, in step S31, this application selects L 2. Regularization, its mathematical expression is:

[0054] in Network weights w The 2-norm, MSE λ is the original loss function, and λ is the regularization parameter.

[0055] S32, will L 2. Regularization is combined with artificial neural networks to fit and train the data.

[0056] In a preferred embodiment, the above-described S40 may further include the following steps: S41. An optimization algorithm is selected. Under the constraint of small sample size, in order to enable the model to train more autonomously and have better generalization ability, Bayesian optimization of model hyperparameters is adopted. Prior knowledge guides the completion of target task training, and the prior information of historical results guides the next search direction, which greatly improves the training and search speed and efficiency.

[0057] In one specific embodiment, in step S41, the Bayesian optimization algorithm is used as the global optimization algorithm. When searching for the optimal hyperparameters of the model, Bayes' theorem is followed to fit the probability distribution of the objective function, and its formula is as follows:

[0058] in f For black-box objective function, D kn ={( x 1, y 1),( x 2, y 2),…,( x n , y n )} represents the hyperparameter combinations that have already been collected. x n and the corresponding function values y n The set, y n = f ( x n )+ , To account for data acquisition error, , , , They are f The marginal likelihood probability distribution, prior probability distribution, posterior probability distribution, and likelihood probability distribution.

[0059] S42 uses a Gaussian process (GP) surrogate model to model the relationship between the model's prediction performance and the combination of hyperparameters, and constructs a black-box function.

[0060] S43, randomly initialize the black-box function, and use the hyperparameter combination with the highest probability of maximizing the model's prediction effect as the next set of evaluation points based on the expectation boosting function (EI) acquisition function.

[0061] S44, substitute the points to be evaluated into the objective function to obtain the evaluation value.

[0062] S45. Repeat the above steps until the end, and select the evaluation point with the best evaluation value from the evaluation set as the model hyperparameter combination.

[0063] In one specific embodiment, in step S45, the optimal hyperparameters are... x best Represented as:

[0064] in f ( x Let ) be the objective function. x best The set of hyperparameters that minimizes the loss in the test dataset; The Gaussian process parameter combination formula for constructing the relationship between the neural network model and its hyperparameters is as follows:

[0065] in x For hyperparameter vectors, f ( x ) is the objective function, which is MSE in this case. m ( x ) is the mean function, K ( x , x' () is the covariance function, which describes the correlation between two input points in the hyperparameter space; The EI function expression is as follows:

[0066]

[0067] in f ( x + () represents the current optimal objective function value. The cumulative distribution function of the standard normal distribution. It is the probability density function of the standard normal distribution.

[0068] S46, validate the model obtained by training the artificial neural network.

[0069] In one specific embodiment, in step S46, this application establishes an efficient impedance prediction framework suitable for limited operating points and small sample conditions through a complete process of "coarse frequency sweep → frequency band division → differentiated sampling and interpolation enhancement → BO neural network optimization". Compared with traditional methods that rely on dense measurements across the entire frequency band, this model not only significantly reduces testing costs, but also exhibits good prediction accuracy and adaptability across control structures under both GFLI and GFMI.

[0070] Table 1 shows the parameters of the VSC used in this experiment. To verify the accuracy of the proposed method under the following network configuration, a dataset not used in the training was used to validate the model. The training set was set at a voltage of 311 V. P e ∈[7KW,13KW], Q e ∈[-5KVar, 5KVar], with an interval of 2500W, 2500Var, and 23 frequency sampling points within the range of 1-1000Hz under single operating conditions.

[0071] Table 1 VSC Parameters

[0072] Verification point set P e =15KW, Q e =1KVar, Figure 8 To match the offline ANN prediction results, Figure 8 (a) is a comparison of the predicted and actual values ​​of the two-dimensional positive and negative sequence impedance amplitude and phase of the ANN under the above operating conditions. Figure 8 (b) shows the three-dimensional plot of the positive and negative sequence impedance magnitudes and phases predicted by the ANN model. Figure 8 (c) shows the positive and negative sequence impedance magnitudes, phase diagrams, and error diagrams of the ANN training dataset and prediction dataset; Figure 8 In the middle (d), there is a scatter plot of the positive and negative sequence impedance magnitudes and phases of the ANN training dataset. Figure 9 To match the prediction results of the model proposed offline, Figure 9 (a) is a comparison of the predicted and actual values ​​of the two-dimensional positive and negative sequence impedance amplitude and phase diagram under the above working conditions of the proposed model; Figure 9 (b) shows the three-dimensional plots of the positive and negative sequence impedance amplitudes and phases predicted by the proposed model. Figure 9 (c) shows the positive and negative sequence impedance magnitudes, phase diagrams, and error diagrams of the training and prediction datasets of the proposed model. Figure 9(d) shows the scatter plots of positive and negative sequence impedance amplitudes and phase diagrams in the training dataset of the proposed model. As can be seen from the figure, under small sample conditions, the ANN model performs poorly, and its predicted phase characteristics even deviate significantly from the true values; while the proposed model can still output prediction results close to the true values. The maximum amplitude error of the proposed model is 0.012 dB, and the maximum phase error is 0.1 deg.

[0073] To verify the applicability of the method under the GFMI (Grid-based Management) model, this paper follows the same training / validation steps as the previous section under the GFLI model, except that the measurement model is changed to a GFMI-controlled model and the model structure parameters are unknown. Figure 10 and Figure 11 The figure shows the experimental results for the above verification conditions under the network construction. As can be seen from the figure, under small sample conditions, the ANN model has a poor fitting effect, and its predicted phase characteristics even deviate significantly from the true values; while the proposed model can still output prediction results close to the true values. The maximum amplitude error of the proposed model is 0.14 dB, and the maximum phase error is 0.07 deg. All comparisons are shown in Table 2.

[0074] Table 2 Comparison of Model Experiment Results

Claims

1. A non-mechanistic analytical method for a general inverter power supply model guided by prior knowledge, characterized in that, include: S10: Based on the inverter power supply measurement dataset and validation set, a matching impedance model is constructed according to the characteristics of the dataset. The identification framework of the impedance model consists of a basic layer, a core layer, and a target layer. S20: The basic layer of the impedance identification framework uses coarse impedance scanning to obtain the a priori impedance change slope. The knowledge of the a priori impedance change slope is used to guide the sampling of differentiated frequency bands, and combined with segmented cubic Hermite interpolation to complete data enhancement. Finally, Z-score normalization is performed. In this process, a coarse scan is performed on the 1-1000 Hz frequency band under a single operating condition. The frequency band is divided into a critical frequency band and a smooth frequency band according to the first-order rate of change of impedance amplitude and impedance phase relative to frequency. Based on the prior impedance change slope, high-density real sampling points are arranged in the critical frequency band, while only a small number of sampling points are retained in the smooth frequency band. For the smooth frequency band, piecewise cubic Hermite interpolation is used for data enhancement. The piecewise cubic Hermite interpolation formula is as follows: In the formula a i ( x )and b i ( x )for: in, y i , y i+1 For the corresponding node function value, m i , m i+1 The first derivative of the corresponding node. a i ( x ), a i+1 ( x ) is the weight function for the node function values; b i ( x ), b i+1 ( x ) is the weight function for the nodal derivatives, which guarantees that H i ( x i ) = y i , H i+1 ( x i+1 ) = y i+1 , H ' i ( x i ) = m i , H ' i +1 ( x i+1 ) = m i+1 ; The augmented data is then subjected to Z-score normalization, and the formula for Z-score normalization is as follows: in, x normal For the standardized results, x i For the first part of the original data i One sample, x mean The mean of the original data. x std The standard deviation of the original data; S30: Introduction of the core layer of the impedance identification framework L 2. Train a regularized neural network; S40: The target layer of the impedance identification framework uses Bayes' theorem prior knowledge transfer to optimize the model hyperparameters. It performs efficient small-sample search in the space of network depth and width, learning rate, and regularization strength. In each iteration, the historical evaluation of the source task is incorporated into the surrogate model as a prior. After dynamic correction, it is combined with the EI function to maximize the selection of the next evaluation point. The optimal hyperparameter combination is returned for training and the target function value of this round is obtained. After the iteration ends, the optimal hyperparameter combination is used as the final weight and structure configuration of the model.

2. The non-mechanistic analytical method for a general inverter power supply model guided by prior knowledge according to claim 1, characterized in that, The dataset and validation set were obtained through a nested parameter scanning method. Specifically, an inverter power supply circuit was built on a hardware-in-the-loop semi-physical simulation platform, and different active power measurements were performed. P e reactive power Q e The work point data below, and at each work point in different... f The dataset and validation set consist of the true values ​​of the order impedance amplitude and phase. The impedance model employs a four-channel joint prediction structure, which can simultaneously output the amplitude and phase of the positive-sequence and negative-sequence impedances, forming a four-channel joint output impedance model structure. The output impedance is: Where |Z + | represents the positive-sequence impedance magnitude, ∠Z + For positive sequence impedance phase, |Z - | represents the magnitude of the negative sequence impedance, ∠Z - It is the negative sequence impedance phase; The error function of the impedance model is defined as the mean of the sum of squares of the four-channel errors. This value also serves as the objective function for Bayesian optimization, and its mathematical expression is: in, This represents the predicted value of the neural network; y i_real The values ​​represent the true values ​​of the training samples; the number 4 in the denominator represents the average value of the four channels. i = 4 means the sum of the squares of the four channels; M SE As a loss function, its magnitude directly reflects the accuracy of the established model.

3. The non-mechanistic analytical method for a general inverter power supply model guided by prior knowledge as described in claim 1, characterized in that, The L 2. Regularization is suitable for handling models with low correlation between four-channel features. Its mathematical expression is: in Network weights w The 2-norm, M SE λ is the original loss function, and λ is the regularization parameter.

4. The non-mechanistic analytical method for a general inverter power supply model guided by prior knowledge according to claim 1, characterized in that, Bayesian optimization algorithm, using prior knowledge to guide model training and obtain optimal hyperparameters, is a global optimization algorithm that follows Bayes' theorem to fit the probability distribution of the objective function when searching for the optimal hyperparameters. Its formula is as follows: in f For black-box objective function, D kn ={( x 1, y 1),( x 2, y 2),…,( x n , y n )} represents the hyperparameter combinations that have already been collected. x n and the corresponding function values y n The set, y n = f ( x n )+ , To account for data acquisition error, , , , They are f Marginal likelihood probability distribution, prior probability distribution, posterior probability distribution, and likelihood probability distribution; The main steps of the Bayesian optimization algorithm are as follows: (1) Use the Gaussian process GP surrogate model to model the relationship between the model prediction effect and the hyperparameter combination, and construct a black box function; (2) Randomly initialize the black box function, and use the expected improvement function EI acquisition function to select the hyperparameter combination with the highest probability that makes the model prediction effect optimal as the next set of evaluation points; (3) Substitute the evaluation points into the objective function to obtain the evaluation value; (4) After the above training steps are completed, select the evaluation point with the best evaluation value from the evaluation set as the model hyperparameter combination. Optimal hyperparameters x best Represented as: in f ( x Let ) be the objective function. x best The set of hyperparameters that minimizes the loss in the test dataset; The Gaussian process parameter combination formula for constructing the relationship between the neural network model and its hyperparameters is as follows: in x For hyperparameter vectors, f ( x ) is the objective function, which is MSE in this case. m ( x ) is the mean function, K ( x , x' () is the covariance function, which describes the correlation between two input points in the hyperparameter space; The EI function expression is as follows: in f ( x + () represents the current optimal objective function value. The cumulative distribution function of the standard normal distribution. It is the probability density function of the standard normal distribution.