Multi-disturbance scene power grid inertia online measurement method, system equipment and storage medium
By preprocessing multi-source power grid data and dynamically adjusting the window of the conditional attention network, combined with online evaluation using an LSTM model, the accuracy and real-time performance issues of inertia evaluation under multi-disturbance scenarios are resolved, achieving high-precision power grid frequency stability control.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-19
- Publication Date
- 2026-04-03
AI Technical Summary
Existing technologies struggle to achieve accurate monitoring of inertia assessment in power systems with a high proportion of renewable energy grid connection, especially under various disturbance scenarios. These technologies suffer from incomplete coverage of disturbance types, cumbersome preprocessing procedures, complex acquisition of disturbance types, and inability to adapt to dynamic changes in inertia. Consequently, inertia assessment accuracy is low, scenario adaptability is poor, and real-time performance is insufficient.
By collecting multi-source core measurement data of the power grid in real time, preprocessing operations such as noise suppression, timing alignment, and outlier removal are performed. A conditional attention network is constructed to dynamically adjust the window length, and a long short-term memory network (LSTM) is used for online evaluation to output the power grid inertia and impedance values.
It achieves high-precision and rapid coordinated assessment of power grid inertia and damping under multiple disturbance scenarios, significantly improving the real-time performance and reliability of power grid frequency stability control.
Smart Images

Figure CN121786538A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of power grid inertia assessment technology, and in particular to an online measurement method, system equipment, and storage medium for power grid inertia under multiple disturbance scenarios. Background Technology
[0002] With the rapid development of power systems with a high proportion of renewable energy connected to the grid, power grid inertia assessment faces the challenge of accurate monitoring under multiple disturbance scenarios. Existing technologies for inertia assessment generally suffer from problems such as incomplete coverage of disturbance types, cumbersome preprocessing procedures, complex acquisition of disturbance types, and inability to adapt to dynamic changes in inertia. As a result, in scenarios such as load abrupt changes, renewable energy fluctuations, and multiple disturbance coupling, the accuracy of inertia assessment is low, the adaptability to scenarios is poor, and the real-time performance is insufficient.
[0003] Traditional methods are difficult to effectively capture the key transient response characteristics of different disturbance types, cannot dynamically adjust the analysis window according to the disturbance characteristics, and have lengthy processes for noise suppression, timing alignment and outlier handling of frequency and power data, which cannot meet the real-time monitoring needs of high-proportion new energy power systems for grid frequency stability control.
[0004] The information disclosed in this background section is intended only to enhance the understanding of the general background of the invention and should not be construed as an admission or in any way implying that the information constitutes prior art known to those skilled in the art. Summary of the Invention
[0005] This invention provides a method, system equipment, and storage medium for online measurement of power grid inertia in multi-disturbance scenarios, thereby effectively solving the problems in the background art.
[0006] To achieve the above objectives, the technical solution adopted by this invention is: an online measurement method for power grid inertia in multi-disturbance scenarios, comprising the following steps:
[0007] Multi-source core measurement data of real-time power grid operation is collected and preprocessed to obtain standardized target input features. The multi-source core measurement data includes: power management unit (PMU) high-frequency measurement data, SCADA power data, new energy power output time series, DC power time series, energy storage power time series, and disturbance identification data.
[0008] The window length is dynamically adjusted for the target input features according to different disturbance types, and the target window input feature matrix adapted to the disturbance type, as well as the disturbance type label and the power disturbance component combination information specified by the expert, are output.
[0009] A conditional attention network is constructed, using the perturbation type label as a control signal to adaptively select the corresponding attention weight calculation logic and extract weighted features;
[0010] The weighted features are input into the Long Short-Term Memory (LSTM) dual-output model, and the grid inertia and impedance values are evaluated simultaneously online. The evaluation confidence level and key traceability information are then output.
[0011] Furthermore, the preprocessing operation includes:
[0012] Noise suppression: Low-frequency drift and high-frequency electromagnetic interference are filtered out using a complex bandpass filter, and then noise is denoised by wavelet thresholding of the time series data signal standard deviation set as a multiple of the target window period.
[0013] Timing alignment: Using the PMU clock as a reference, timing calibration is performed on SCADA power data and disturbance identification data;
[0014] Outlier removal: An isolated forest algorithm with an outlier ratio of 5% is used to identify and mark outliers in frequency and power data; data with missing duration ≤ 5ms is imputed by linear interpolation; data with missing duration > 5ms is marked as invalid samples.
[0015] Power disturbance calculation: Based on the power grid topology, the dominant characteristics of the disturbance source, and the real-time operating scenario, specify the set of components involved in the power disturbance calculation; calculate the total power deviation of the specified components;
[0016] Frequency differential quantization and per-unit quantization: Differential quantization ,in The steady-state value of the power grid frequency before the disturbance. For the frequency timing sequence within the window period in the high-frequency measurement data of the power management unit (PMU); per unit: ,in The rated frequency;
[0017] Frequency change calculation: Calculation of frequency timing after standardization By performing differentiation, we obtain the frequency change rate time series that simultaneously satisfies both differential quantization and per-unit quantization.
[0018] Disturbance type coding: Disturbance type labels are divided into three categories: large, medium, and small, and one-hot coding is used;
[0019] Feature standardization: frequency timing Frequency change rate timing Total power deviation of specified components Z-score normalization is performed, while the one-hot encoding of the perturbation type remains unchanged, resulting in an input feature matrix of dimension T×4, where T is the window length. The four features are: per-unit, differential quantization, frequency, and time series. Per-unit differential quantization frequency change rate time series Perimeter power disturbance Disturbance type one-hot encoding.
[0020] Further, the calculation of the total power deviation of the specified component includes:
[0021] ;
[0022] in,{ , ,..., } represents the set of components that participate in the calculation of power disturbances. This represents the total steady-state value of the corresponding component before the disturbance;
[0023] Per-unit: ,in The rated power of the power grid is used to eliminate the influence of dimensions.
[0024] Furthermore, the directly calibrated permuted frequency timing... Differentiation yields a time series of frequency change rates that simultaneously satisfy differential quantization and per-unit quantization, including:
[0025] ;
[0026] Differential calculations were performed using the central difference method with a window step size of 5 ms.
[0027] .
[0028] Furthermore, the step of dynamically adjusting the window period length for the target input feature according to different perturbation types includes:
[0029] For large disturbances: Set T=50-100ms to cover the critical transient response period before and after the disturbance occurrence time t0;
[0030] For medium disturbances: Set T=150-250ms to fully cover the rise-peak-decay cycle of power / frequency fluctuations;
[0031] For small disturbances: Set T=300-500ms to ensure that statistical characteristics are captured for a sufficient period of time to support damping assessment;
[0032] Where T is the window length.
[0033] Furthermore, the construction of the conditional attention network, using the perturbation type label as a control signal, adaptively selects the corresponding attention weight calculation logic and extracts weighted features, including:
[0034] The basic time series features correspond to the target input features, with a dimension of T×4: frequency time series features: differentially quantized, standardized, and normalized. Time-series characteristics of frequency change rate: per-unit differential quantization Power disturbance characteristics: per-unit and normalized Perturbation type characteristics: Perturbation type label after one-hot encoding;
[0035] Using the perturbation type label as a control signal, the corresponding attention weight calculation logic is adaptively selected:
[0036] The goal of the large perturbation attention mechanism is to strengthen the weights of data points near the time t0 when the perturbation occurs, thus highlighting the characteristics of the initial transient response; the time distance function is defined as follows: , where t i Let t be the time of the i-th time step, and t0 be the time when the disturbance occurs; Attention weight formula: ,in Weighting characteristics: and The smaller the time difference, The larger the disturbance, the more attention should be paid to the rapid frequency / power change period of the initial 0-20ms of the disturbance.
[0037] The goal of the small perturbation attention mechanism is to uniformly cover all time steps, capture overall statistical regularities, and avoid interference from local fluctuations; the attention weight formula adopts a near-uniform weight distribution. Where β2 = 0.001; or a uniform distribution can be directly adopted. Weighting characteristics: The weight difference between each time step is ≤5%, achieving balanced extraction of features across all time periods and supporting the statistical evaluation of damping parameters;
[0038] The goal of the perturbation attention mechanism is to focus on periods of large fluctuations and capture core fluctuation characteristics; the importance score is defined as: quantifying fluctuation intensity based on a sliding window integral of the frequency change rate. Where W is the sliding window radius; attention weight formula: Weighting characteristics: within the sliding window The larger the sum of absolute values, the more drastic the fluctuation. The higher, The larger the value, the more automatically it focuses on the peak periods of power / frequency fluctuations;
[0039] The conditional attention network encodes labels one-hot based on the perturbation type, adaptively selects the corresponding weight calculation logic, and combines the T×4 basic temporal features with the corresponding attention weights. Element-wise multiplication yields conditional attention-weighted features.
[0040] Furthermore, the step of inputting the weighted features into the Long Short-Term Memory (LSTM) dual-output model and simultaneously evaluating online to obtain the grid inertia and impedance values includes:
[0041] A dual-output end-to-end model combining Conditional Attention (CAT) and Long Short-Term Memory (LSTM) networks is constructed: the input layer has a dimension of T×4; the CAT layer connects to the CAT network and outputs weighted features; there are two LSTM hidden layers with the activation function tanh; one fully connected layer with the activation function ReLU; and the output layer has two output nodes with the activation function ReLU, corresponding to the inertia evaluation value H (in seconds) and the damping evaluation value D (in % rated power / Hz).
[0042] Training sample set: Covering several scenarios involving multiple types of disturbances, multiple types of new energy penetration rates, multiple interval inertia values, multiple interval damping values, and multiple expert-specified power component combinations. For each scenario, a set of historical real samples are collected to form high-quality samples, including preprocessed input features, disturbance type labels, expert-specified component combinations, and real inertia values. True damping value Validation and Test Sets: The ratio of validation to test sets is set, with samples drawn from different power grid operating periods and topology scenarios than the training set; Loss Function: Joint Mean Square Error (MSE) loss is used to balance the evaluation accuracy of inertia and damping.
[0043] ;
[0044] Training strategy: The AdamW optimizer is used in conjunction with early stopping. Training stops if the joint loss on the validation set does not decrease for five consecutive rounds to avoid overfitting. Online inference: Weighted features are input into the trained model, and real-time inertia evaluation values are output. Damping assessment value .
[0045] Furthermore, the output assessment confidence level and key traceability information include:
[0046] The output includes core evaluation parameters: real-time inertia values. Real-time damping value Auxiliary information: disturbance type identifier, window duration T, expert-specified power disturbance component combination, and assessment confidence level C; tracing information: the identifier includes the attention mechanism type, key parameters, and key preprocessing indicators; among which, the assessment confidence level C is calculated based on the dynamic change of the adaptive inertia and the multi-sample distribution).
[0047] ;
[0048] In the formula, The mean of the real inertia values in the historical sample set that matches the current scene; The mean of the actual damping values in the historical sample set that matches the current scenario; The standard deviation of the error inertia predicted by the model in the above matched sample set; The standard deviation of the model's predicted damping error in the above matched sample set; It is a very small positive number; This is a scenario reliability correction factor;
[0049] Confidence level determination: When C≥90%, the result is determined to be reliable; when 80%≤C<90%, it is marked as requiring attention; when C<80%, it is marked as low confidence, prompting dispatchers to verify it in conjunction with other monitoring methods.
[0050] The present invention also includes an online measurement system for power grid inertia in multi-disturbance scenarios, using the method described above, wherein the system comprises:
[0051] The acquisition unit is used to acquire multi-source core measurement data of the power grid in real time and perform preprocessing operations to obtain standardized target input features. The multi-source core measurement data includes: power management unit (PMU) high-frequency measurement data, SCADA power data, new energy power output time series, DC power time series, energy storage power time series, and disturbance identification data.
[0052] The window adjustment unit is used to dynamically adjust the window length of the target input features according to different disturbance types, and output the target window input feature matrix adapted to the disturbance type, as well as the disturbance type label and the power disturbance component combination information specified by the expert.
[0053] The conditional attention unit is used to construct the conditional attention network. It uses the perturbation type label as a control signal to adaptively select the corresponding attention weight calculation logic and extract weighted features.
[0054] The evaluation unit is used to input the weighted features into the Long Short-Term Memory (LSTM) dual-output model, synchronously evaluate the grid inertia and impedance values online, and output the evaluation confidence level and key traceability information.
[0055] The present invention also includes a computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the method as described above.
[0056] The beneficial effects of this invention are as follows: By combining the per-unit frequency, the per-unit frequency change rate, and the disturbance type encoding, a standardized input feature matrix is formed; then, according to different types of disturbances (large, medium, and small), window period data of corresponding time lengths are dynamically extracted, and key time-series features are adaptively strengthened using a conditional attention mechanism; finally, the weighted features are input into the LSTM dual-output model, and the grid inertia and damping values are evaluated online simultaneously, and the evaluation confidence and key traceability information are output. This achieves high-precision and rapid collaborative evaluation of grid inertia and damping under multiple disturbance scenarios, significantly improving the real-time performance and reliability of grid frequency stability control. Attached Figure Description
[0057] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0058] Figure 1 This is a flowchart of the method in Example 1;
[0059] Figure 2 This is a schematic diagram of the system structure in Example 1;
[0060] Figure 3 This is a flowchart of the method in Example 2;
[0061] Figure 4 This is a schematic diagram of the structure of the computer device of the present invention. Detailed Implementation
[0062] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments.
[0063] Example 1:
[0064] like Figure 1 As shown: A method for online measurement of power grid inertia in a multi-disturbance scenario, comprising the following steps:
[0065] The system collects multi-source core measurement data of the power grid in real time and performs preprocessing operations to obtain standardized target input features. The multi-source core measurement data includes: high-frequency measurement data of the power management unit (PMU), power data of the data acquisition and monitoring system (SCADA), power output time series of new energy sources, DC power time series, energy storage power time series, and disturbance identification data.
[0066] The window length is dynamically adjusted according to different disturbance types for the target input features, and the target window input feature matrix adapted to the disturbance type, as well as the disturbance type label and the power disturbance component combination information specified by the expert are output.
[0067] A conditional attention network is constructed, using the perturbation type label as a control signal to adaptively select the corresponding attention weight calculation logic and extract weighted features;
[0068] The weighted features are input into the Long Short-Term Memory (LSTM) dual-output model, and the grid inertia and impedance values are evaluated simultaneously online. The evaluation confidence level and key traceability information are then output.
[0069] By combining the encoding of per-unit frequency, per-unit frequency change rate, and disturbance type, a standardized input feature matrix is formed. Then, according to different types of disturbances (large, medium, and small), window periods of corresponding time lengths are dynamically extracted, and key time-series features are adaptively strengthened using a conditional attention mechanism. Finally, the weighted features are input into the LSTM dual-output model, and the grid inertia and damping values are evaluated online simultaneously. The evaluation confidence and key traceability information are output, achieving high-precision and rapid collaborative evaluation of grid inertia and damping under multiple disturbance scenarios, significantly improving the real-time performance and reliability of grid frequency stability control.
[0070] In this embodiment, the preprocessing operation includes:
[0071] Noise suppression: Low-frequency drift and high-frequency electromagnetic interference are filtered out using a complex bandpass filter, and then noise is denoised by wavelet thresholding of the time series data signal standard deviation set as a multiple of the target window period.
[0072] Timing alignment: Using the PMU clock as a reference, timing calibration is performed on SCADA power data and disturbance identification data;
[0073] Outlier removal: An isolated forest algorithm with an outlier ratio of 5% is used to identify and mark outliers in frequency and power data; data with missing duration ≤ 5ms is imputed by linear interpolation; data with missing duration > 5ms is marked as invalid samples.
[0074] Power disturbance calculation: Based on the power grid topology, the dominant characteristics of the disturbance source, and the real-time operating scenario, specify the set of components involved in the power disturbance calculation; calculate the total power deviation of the specified components;
[0075] Frequency differential quantization and per-unit quantization: Differential quantization ,in The steady-state value of the power grid frequency before the disturbance. For the frequency timing sequence within the window period in the high-frequency measurement data of the power management unit (PMU); per unit: ,in The rated frequency;
[0076] Frequency change calculation: Calculation of frequency timing after standardization By performing differentiation, we obtain the frequency change rate time series that simultaneously satisfies both differential quantization and per-unit quantization.
[0077] Disturbance type coding: Disturbance type labels are divided into three categories: large, medium, and small, and one-hot coding is used;
[0078] Feature standardization: frequency timing Frequency change rate timing Total power deviation of specified components Z-score normalization is performed, while the one-hot encoding of the perturbation type remains unchanged, resulting in an input feature matrix of dimension T×4, where T is the window length. The four features are: per-unit, differential quantization, frequency, and time series. Per-unit differential quantization frequency change rate time series Perimeter power disturbance Disturbance type one-hot encoding.
[0079] Calculate the total power deviation of a specified component, including:
[0080] ;
[0081] in,{ , ,..., } represents the set of components that participate in the calculation of power disturbances. This represents the total steady-state value of the corresponding component before the disturbance;
[0082] Per-unit: ,in The rated power of the power grid is used to eliminate the influence of dimensions.
[0083] Among them, the frequency timing directly compared to the perturbation is... Differentiation yields a time series of frequency change rates that simultaneously satisfy differential quantization and per-unit quantization, including:
[0084] ;
[0085] Differential calculations were performed using the central difference method with a window step size of 5 ms.
[0086] .
[0087] The window length is dynamically adjusted based on different perturbation types for the target input features, including:
[0088] For large disturbances: Set T=50-100ms to cover the critical transient response period before and after the disturbance occurrence time t0;
[0089] For medium disturbances: Set T=150-250ms to fully cover the rise-peak-decay cycle of power / frequency fluctuations;
[0090] For small disturbances: Set T=300-500ms to ensure that statistical characteristics are captured for a sufficient period of time to support damping assessment;
[0091] Where T is the window length.
[0092] In this embodiment, a conditional attention network is constructed, using the perturbation type label as a control signal to adaptively select the corresponding attention weight calculation logic and extract weighted features, including:
[0093] The basic time series features correspond to the target input features, with a dimension of T×4: frequency time series features: differentially quantized, standardized, and normalized. Time-series characteristics of frequency change rate: per-unit differential quantization Power disturbance characteristics: per-unit and normalized Perturbation type characteristics: Perturbation type label after one-hot encoding;
[0094] Using the perturbation type label as a control signal, the corresponding attention weight calculation logic is adaptively selected:
[0095] The goal of the large perturbation attention mechanism is to strengthen the weights of data points near the time t0 when the perturbation occurs, thus highlighting the characteristics of the initial transient response; the time distance function is defined as follows: , where t i Let t be the time of the i-th time step, and t0 be the time when the disturbance occurs; Attention weight formula: ,in Weighting characteristics: and The smaller the time difference, The larger the disturbance, the more attention should be paid to the rapid frequency / power change period of the initial 0-20ms of the disturbance.
[0096] The goal of the small perturbation attention mechanism is to uniformly cover all time steps, capture overall statistical regularities, and avoid interference from local fluctuations; the attention weight formula adopts a near-uniform weight distribution. Where β2 = 0.001; or a uniform distribution can be directly adopted. Weighting characteristics: The weight difference between each time step is ≤5%, achieving balanced extraction of features across all time periods and supporting the statistical evaluation of damping parameters;
[0097] The goal of the perturbation attention mechanism is to focus on periods of large fluctuations and capture core fluctuation characteristics; the importance score is defined as: quantifying fluctuation intensity based on a sliding window integral of the frequency change rate. Where W is the sliding window radius; attention weight formula: Weighting characteristics: within the sliding window The larger the sum of absolute values, the more drastic the fluctuation. The higher, The larger the value, the more automatically it focuses on the peak periods of power / frequency fluctuations;
[0098] The conditional attention network encodes labels one-hot based on the perturbation type, adaptively selects the corresponding weight calculation logic, and combines the T×4 basic temporal features with the corresponding attention weights. Element-wise multiplication yields conditional attention-weighted features.
[0099] The weighted features are input into the Long Short-Term Memory (LSTM) dual-output model, and the grid inertia and impedance values are obtained simultaneously online, including:
[0100] A dual-output end-to-end model combining Conditional Attention (CAT) and Long Short-Term Memory (LSTM) networks is constructed: the input layer has a dimension of T×4; the CAT layer connects to the CAT network and outputs weighted features; there are two LSTM hidden layers with the activation function tanh; one fully connected layer with the activation function ReLU; and the output layer has two output nodes with the activation function ReLU, corresponding to the inertia evaluation value H (in seconds) and the damping evaluation value D (in % rated power / Hz).
[0101] Training sample set: Covering several scenarios involving multiple types of disturbances, multiple types of new energy penetration rates, multiple interval inertia values, multiple interval damping values, and multiple expert-specified power component combinations. For each scenario, a set of historical real samples are collected to form high-quality samples, including preprocessed input features, disturbance type labels, expert-specified component combinations, and real inertia values. True damping value Validation and Test Sets: The ratio of validation to test sets is set, with samples drawn from different power grid operating periods and topology scenarios than the training set; Loss Function: Joint Mean Square Error (MSE) loss is used to balance the evaluation accuracy of inertia and damping.
[0102] ;
[0103] Training strategy: The AdamW optimizer is used in conjunction with early stopping. Training stops if the joint loss on the validation set does not decrease for five consecutive rounds to avoid overfitting. Online inference: Weighted features are input into the trained model, and real-time inertia evaluation values are output. Damping assessment value .
[0104] The output includes assessment confidence level and key traceability information, including:
[0105] The output includes core evaluation parameters: real-time inertia values. Real-time damping value Auxiliary information: disturbance type identifier, window duration T, expert-specified power disturbance component combination, and assessment confidence level C; tracing information: the identifier includes the attention mechanism type, key parameters, and key preprocessing indicators; among which, the assessment confidence level C is calculated based on the dynamic change of the adaptive inertia and the multi-sample distribution).
[0106] ;
[0107] In the formula, The mean of the real inertia values in the historical sample set that matches the current scene; The mean of the actual damping values in the historical sample set that matches the current scenario; The standard deviation of the error inertia predicted by the model in the above matched sample set; The standard deviation of the model's predicted damping error in the above matched sample set; It is a very small positive number; This is a scenario reliability correction factor;
[0108] Confidence level determination: When C≥90%, the result is determined to be reliable; when 80%≤C<90%, it is marked as requiring attention; when C<80%, it is marked as low confidence, prompting dispatchers to verify it in conjunction with other monitoring methods.
[0109] like Figure 2 As shown, this embodiment also includes an online power grid inertia measurement system for multi-disturbance scenarios, using the method described above. The system includes:
[0110] The acquisition unit is used to acquire multi-source core measurement data of the power grid in real time and perform preprocessing operations to obtain standardized target input features. The multi-source core measurement data includes: high-frequency measurement data of the power management unit (PMU), power data of the data acquisition and monitoring system (SCADA), power output time series of new energy sources, DC power time series, energy storage power time series, and disturbance identification data.
[0111] The window adjustment unit is used to dynamically adjust the window length of the target input features according to different disturbance types, and output the target window input feature matrix adapted to the disturbance type, as well as the disturbance type label and the power disturbance component combination information specified by the expert.
[0112] The conditional attention unit is used to construct the conditional attention network. It uses the perturbation type label as a control signal to adaptively select the corresponding attention weight calculation logic and extract weighted features.
[0113] The evaluation unit is used to input the weighted features into the Long Short-Term Memory (LSTM) dual-output model, synchronously evaluate the grid inertia and impedance values online, and output the evaluation confidence level and key traceability information.
[0114] Example 2:
[0115] like Figure 3 As shown, this embodiment includes a method for evaluating power grid inertia in multi-disturbance scenarios based on temporal attention LSTM, the steps of which are as follows:
[0116] Step A: Multi-source time-series data acquisition and preprocessing. Acquire multi-source core measurement data of the power grid in real time. The multi-source core measurement data includes PMU high-frequency measurement data (including frequency time-series sequences within the window period). SCADA power data (including the time series of total active power of the load within the window period) Time series of power output from new energy sources DC power timing sequence Energy storage power time series Disturbance identification data (including disturbance occurrence time t0 and disturbance type label); the following preprocessing operations are performed on the multi-source real measurement data to obtain the standardized target input features:
[0117] A1. Noise Suppression: A complex bandpass filter with a passband frequency of 0.1-50Hz is used to filter low-frequency drift and high-frequency electromagnetic interference. Then, wavelet threshold noise reduction is performed using 0.05 times the standard deviation of the time series data signal of the target window period to further purify the frequency and power data.
[0118] A2. Timing Alignment: Using the PMU clock as a reference, perform timing calibration on SCADA power data and disturbance identification data to ensure that the timing deviation of all timing data is < 1ms;
[0119] A3. Outlier Removal: An isolated forest algorithm with an outlier ratio of 5% is used to identify and mark outliers in frequency and power data; data with missing duration ≤ 5ms is filled in by linear interpolation; data with missing duration > 5ms is marked as invalid samples and is not used in model training and online inference.
[0120] A4. Power Disturbance Calculation: Based on the power grid topology, the dominant characteristics of the disturbance source, and the real-time operating scenario, specify the set of components participating in the power disturbance calculation. , ,..., Differential quantization: Calculates the total power deviation of a specified component.
[0121] ;
[0122] in The total steady-state value of the corresponding component before the disturbance (calculated by moving average of time series data in the 100ms before the disturbance); per unit: ,in The rated power of the power grid is used to eliminate the influence of dimensions.
[0123] A5. Frequency Differential Quantization and Perimeterization: Differential Quantization ,in The steady-state value of the power grid frequency before the disturbance (calculated by moving average of time series data 100ms before the disturbance occurs);
[0124] Per-unit: ,in This is the rated frequency (default 50Hz, can be adjusted as needed).
[0125] A6. Calculation of frequency change: Directly compare the normalized frequency timing. By performing differentiation, we obtain the time series of frequency change rates that simultaneously satisfy both differential quantization and per-unit quantization:
[0126] ;
[0127] Differential calculations employ the central difference method with a window step size of 5ms to ensure computational accuracy. The formula is:
[0128] ;
[0129] A7. Disturbance type coding: Disturbance type labels are divided into three categories: large, medium, and small, using one-hot coding: large disturbance = [1,0,0], medium disturbance = [0,1,0], small disturbance = [0,0,1];
[0130] A8. Feature Standardization: For , , Z-score standardization (mean = 0, variance = 1) is performed, while the one-hot perturbation coding remains unchanged, resulting in an input feature matrix of dimension T×4 (T is the window length, and the four features are: per-unit, differential, quantization, frequency, and time series). Per-unit differential quantization frequency change rate time series Perimeter power disturbance (Perturbation type one-hot encoding).
[0131] Step B: Dynamic window period truncation. Based on the disturbance type label obtained in Step 1, dynamically adjust the window period length T.
[0132] Large disturbance: T=50-100ms, covering the critical transient response period before and after the disturbance occurrence time t0;
[0133] Medium disturbance: T=150-250ms, fully covering the "rise-peak-decay" cycle of power / frequency fluctuations;
[0134] Small perturbation: T=300-500ms, ensuring sufficient time to capture statistical characteristics to support damping assessment;
[0135] Output the target window period input feature matrix and disturbance type label, and expert-specified power disturbance component combination information, which are adapted to the disturbance type.
[0136] Step C: Temporal attention-weighted feature extraction:
[0137] C1. Confirmation of basic time series characteristics;
[0138] The basic time series features directly correspond to the four types of input features output in step A, with a dimension of T×4: frequency time series features: differentially quantized, standardized, and normalized. Time-series characteristics of frequency change rate: per-unit differential quantization Power disturbance characteristics: per-unit and normalized Perturbation type feature: Perturbation type label after one-hot encoding.
[0139] C2. Design of conditional attention mechanism;
[0140] A conditional attention network is constructed, using perturbation type labels as control signals to adaptively select the corresponding attention weight calculation logic, thereby enhancing the extraction of key temporal features:
[0141] The goal of the large perturbation attention mechanism is to strengthen the weights of data points near the time t0 when the perturbation occurs, thus highlighting the characteristics of the initial transient response; the time distance function is defined as follows: , where t i Let t be the time of the i-th time step, and t0 be the time when the disturbance occurs; Attention weight formula: Where β1=0.1; Weighting characteristics: t i The smaller the time difference with t0, The larger the disturbance, the more attention should be paid to the period of rapid frequency / power change during the initial 0-20ms of the disturbance.
[0142] The goal of the small perturbation attention mechanism is to uniformly cover all time steps, capture overall statistical regularities, and avoid interference from local fluctuations; the attention weight formula adopts a near-uniform weight distribution. Where β2 = 0.001; or a uniform distribution can be directly adopted. Weight characteristics: The weight difference between each time step is ≤5%, which realizes the balanced extraction of features across all time periods and supports the statistical evaluation of damping parameters.
[0143] The goal of the perturbation attention mechanism is to focus on periods of large fluctuations and capture core fluctuation characteristics; the importance score is defined as: quantifying fluctuation intensity based on a sliding window integral of the frequency change rate. Where W is the sliding window radius (taken as 50ms, corresponding to 50 timing steps, since the PMU sampling rate is 1kHz, each step is 1ms); Attention weight formula: Weighting characteristics: within the sliding window The larger the sum of absolute values (the more drastic the fluctuation), the higher S(i). The larger the value, the more automatically it focuses on the peak periods of power / frequency fluctuations.
[0144] Next is the selection of the attention mechanism and the generation of weighted features. The conditional attention network encodes labels one-hot according to the perturbation type and adaptively selects the corresponding weight calculation logic, combining the T×4 basic temporal features with the corresponding attention weights. Element-wise multiplication yields conditional attention-weighted features.
[0145] Step D: LSTM Dual-Output Modeling and Inertia-Damping Co-evaluation:
[0146] D1. Construct an end-to-end dual-output model of "Conditional Attention + LSTM": Input layer dimension is T×4; Conditional attention layer: connects to the conditional attention module designed in step C, outputting weighted features; 2 LSTM hidden layers (64 neurons per layer, activation function tanh, initial weight of forget gate 0.7 to avoid gradient vanishing); 1 fully connected layer (128 neurons, activation function ReLU, to enhance nonlinear fitting ability); Output layer: two output nodes (activation function ReLU, to ensure non-negative output), corresponding to the inertia evaluation value H (unit: s) and the damping evaluation value D (unit: % rated power / Hz), respectively.
[0147] D2. Training Sample Set: Covering "3 types of disturbances × 3 types of new energy penetration rates (30%-70%) × multiple interval inertia values (e.g., 10 consecutive small intervals within 0.5-3.0s) × multiple interval damping values (e.g., 8 consecutive small intervals within 1%-5%) × 5 types of expert-specified power component combinations", totaling 3×3×10×8×5=3600 scenarios. For each scenario, 30-50 sets of historical real samples are collected to form high-quality samples (including preprocessed input features, disturbance type labels, expert-specified component combinations, and real inertia values). True damping value ); Validation and test sets: The validation set accounts for 20%, and the test set accounts for 10%. The samples come from different power grid operating periods and topology scenarios than the training set to ensure the model's generalization ability; Loss function: Joint mean squared error (MSE) loss is used to balance the evaluation accuracy of inertia and damping.
[0148] ;
[0149] Training strategy: Use AdamW optimizer (learning rate 1e) -4 Weight decay 1e -5 The model is combined with early stopping (training stops if the joint loss on the validation set does not decrease for 5 consecutive rounds) to avoid overfitting; online inference: the weighted features from step 3 are input into the trained model, and the real-time inertia evaluation value is output. Damping assessment value .
[0150] Step E: Output the evaluation results, including the core evaluation parameter: real-time inertia value. Real-time damping value Auxiliary information: disturbance type identifier, window duration T, expert-specified power disturbance component combination, assessment confidence level C; tracing information: attention mechanism type and key parameters are attached to the identifier. The evaluation process includes key preprocessing indicators (per-unit coefficient, standardized mean / variance) to facilitate grid dispatchers' traceability of the evaluation process. The evaluation confidence level C is calculated based on the dynamic changes in adaptive inertia and the multi-sample distribution.
[0151] ;
[0152] The parameters in the formula are defined as follows:
[0153] The mean of the real inertia values in the historical sample set that matches the current scene;
[0154] : The mean of the actual damping values in the historical sample set that matches the current scenario (Scenario matching conditions: consistent disturbance type, same combination of power components specified by experts, and deviation of new energy penetration rate ≤ 5%).
[0155] The standard deviation of the model's predicted inertia in the above matched sample set (reflecting the predictive stability of dynamic changes in inertia under this scenario).
[0156] The standard deviation of the model's prediction of damping in the above matched sample set (reflecting the predictive stability of the dynamic changes in damping under this scenario).
[0157] Minimal positive number (take) ), to avoid the denominator being 0;
[0158] Scenario reliability correction coefficient (determined by the number of matched samples: when the number of matched samples is ≥50) =0.8; 30 groups ≤ number of matched samples < 50 groups =1.0; when the number of matched samples is < 10 =1.2);
[0159] Confidence level determination: When C≥90%, the result is determined to be reliable; when 80%≤C<90%, it is marked as "needs attention"; when C<80%, it is marked as "low confidence level", prompting dispatchers to verify it in conjunction with other monitoring methods.
[0160] In step 1, when experts specify power disturbance components, they need to consider the real-time operating status of the power grid (such as the penetration rate of new energy sources, the proportion of energy storage in operation, and the proportion of DC transmission power) and the disturbance source tracing results, and prioritize the power components directly related to the current disturbance to ensure... It can accurately reflect the overall power imbalance characteristics of the power grid.
[0161] In the training sample set of step 4, the true inertia values True damping value The data are obtained from offline power grid tests (such as load shedding tests and disturbance simulation tests) or high-precision electromagnetic transient simulations (such as PSCAD / EMTDC), and the number of samples in each inertia / damping interval is balanced to ensure that the model has consistent fitting accuracy for dynamically changing inertia and damping.
[0162] In step 5, the confidence score calculation requires that historical samples of scene matching undergo validity screening: outlier samples and abnormally fitted samples with prediction errors exceeding 3 times the standard deviation are removed to ensure... , , , The statistical reliability.
[0163] In the disturbance attention mechanism of step 3, the sliding window radius W can be finely adjusted within the range of 30-70ms according to the characteristics of power grid fluctuations to ensure accurate capture of the peak period of fluctuations.
[0164] In the differential quantization process of step 1, the steady-state value before the disturbance ( , The value is calculated by moving average of time series data 100ms before the disturbance occurs, with a sliding window step size of 10ms to ensure that the steady-state reference value is not affected by instantaneous noise.
[0165] Please see Figure 4 The diagram shows a structural schematic of a computer device provided in an embodiment of this application. An embodiment of this application provides a computer device 400, including a processor 410 and a memory 420. The memory 420 stores a computer program executable by the processor 410, and when the computer program is executed by the processor 410, it performs the method described above.
[0166] This application embodiment also provides a storage medium 430, on which a computer program is stored, and the computer program is executed by a processor 410 to perform the above method.
[0167] The storage medium 430 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Red-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0168] In the description of this invention, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. "A plurality of" means two or more, unless otherwise explicitly specified.
[0169] In this invention, unless otherwise explicitly specified and limited, the terms "installation," "connection," "linking," and "fixing," etc., should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components. Those skilled in the art can understand the specific meaning of the above terms in this invention according to the specific circumstances.
[0170] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the present invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Furthermore, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.
[0171] Any process or method description in the flowchart or otherwise herein can be understood as representing a module, segment, or portion of code comprising one or more executable instructions for implementing a particular logical function or process, and the scope of the preferred embodiments of the invention includes additional implementations in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order depending on the functions involved, as will be understood by those skilled in the art to which embodiments of the invention pertain.
[0172] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a ordered list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (such as a computer-based system, a processor-included system, or other system that can fetch and execute instructions from, an instruction execution system, apparatus, or device). For the purposes of this specification, "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transmit programs for use by, or in conjunction with, an instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of computer-readable media include: an electrical connection having one or more wires (electronic device), a portable computer disk drive (magnetic device), random access memory (RAM), read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disc read-only memory (CDROM). Alternatively, the computer-readable medium may be paper or other suitable media on which the program can be printed, since the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in a computer memory.
[0173] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.
[0174] Those skilled in the art will understand that all or part of the steps of the methods in the above embodiments can be implemented by a program instructing related hardware. The program can be stored in a computer-readable storage medium, and when executed, the program includes one or a combination of the steps of the method embodiments.
[0175] The storage medium mentioned above can be a read-only memory, a disk, or an optical disk, etc. Although embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and should not be construed as limiting the present invention. Those skilled in the art can make changes, modifications, substitutions, and variations to the above embodiments within the scope of the present invention.
Claims
1. A method for online measurement of power grid inertia in multi-disturbance scenarios, characterized in that, Includes the following steps: Multi-source core measurement data of real-time power grid operation is collected and preprocessed to obtain standardized target input features. The multi-source core measurement data includes: power management unit (PMU) high-frequency measurement data, SCADA power data, new energy power output time series, DC power time series, energy storage power time series, and disturbance identification data. The window length is dynamically adjusted for the target input features according to different disturbance types, and the target window input feature matrix adapted to the disturbance type, as well as the disturbance type label and the power disturbance component combination information specified by the expert, are output. A conditional attention network is constructed, using the perturbation type label as a control signal to adaptively select the corresponding attention weight calculation logic and extract weighted features; The weighted features are input into the Long Short-Term Memory (LSTM) dual-output model, and the grid inertia and impedance values are evaluated simultaneously online. The evaluation confidence level and key traceability information are then output.
2. The online measurement method for power grid inertia in multi-disturbance scenarios according to claim 1, characterized in that, The preprocessing operations include: Noise suppression: Low-frequency drift and high-frequency electromagnetic interference are filtered out using a complex bandpass filter, and then noise is denoised by wavelet thresholding of the time series data signal standard deviation set as a multiple of the target window period. Timing alignment: Using the PMU clock as a reference, timing calibration is performed on SCADA power data and disturbance identification data; Outlier removal: An isolated forest algorithm with an outlier ratio of 5% is used to identify and mark outliers in frequency and power data; data with missing duration ≤ 5ms is imputed by linear interpolation; data with missing duration > 5ms is marked as invalid samples. Power disturbance calculation: Based on the power grid topology, the dominant characteristics of the disturbance source, and the real-time operating scenario, specify the set of components involved in the power disturbance calculation; calculate the total power deviation of the specified components; Frequency differential quantization and per-unit quantization: Differential quantization ,in The steady-state value of the power grid frequency before the disturbance. For the frequency timing sequence within the window period in the high-frequency measurement data of the power management unit (PMU); per unit: ,in The rated frequency; Frequency change calculation: Calculation of frequency timing after standardization By performing differentiation, we obtain the frequency change rate time series that simultaneously satisfies both differential quantization and per-unit quantization. Disturbance type coding: Disturbance type labels are divided into three categories: large, medium, and small, and one-hot coding is used; Feature standardization: frequency timing Frequency change rate timing Total power deviation of specified components Z-score normalization is performed, while the one-hot encoding of the perturbation type remains unchanged, resulting in an input feature matrix of dimension T×4, where T is the window length. The four features are: per-unit, differential, frequency, and time series. Per-unit differential quantization frequency change rate time series Perimeter power disturbance Disturbance type one-hot encoding.
3. The online measurement method for power grid inertia in multi-disturbance scenarios according to claim 2, characterized in that, The calculation of the total power deviation of the specified component includes: ; in,{ , ,..., } represents the set of components that participate in the calculation of power disturbances. This represents the total steady-state value of the corresponding component before the disturbance; Per-unit standardization: ,in The rated power of the power grid is used to eliminate the influence of dimensions.
4. The online measurement method for power grid inertia in multi-disturbance scenarios according to claim 2, characterized in that, The frequency timing sequence directly after standardization Differentiation yields a time series of frequency change rates that simultaneously satisfy differential quantization and per-unit quantization, including: ; Differential calculations were performed using the central difference method with a window step size of 5 ms. 。 5. The online measurement method for power grid inertia in multi-disturbance scenarios according to claim 1, characterized in that, The dynamic adjustment of the window period length for the target input features based on different perturbation types includes: For large disturbances: Set T=50-100ms to cover the critical transient response period before and after the disturbance occurrence time t0; For medium disturbances: Set T=150-250ms to fully cover the rise-peak-decay cycle of power / frequency fluctuations; For small disturbances: Set T=300-500ms to ensure that statistical characteristics are captured for a sufficient period of time to support damping assessment; Where T is the window length.
6. The online measurement method for power grid inertia in multi-disturbance scenarios according to claim 1, characterized in that, The construction of the conditional attention network uses the perturbation type label as a control signal to adaptively select the corresponding attention weight calculation logic and extract weighted features, including: The basic time series features correspond to the target input features, with a dimension of T×4: frequency time series features: differentially quantized, standardized, and normalized. Time-series characteristics of frequency change rate: per-unit differential quantization Power disturbance characteristics: per-unit and normalized Perturbation type characteristics: Perturbation type label after one-hot encoding; Using the perturbation type label as a control signal, the corresponding attention weight calculation logic is adaptively selected: The goal of the large perturbation attention mechanism is to strengthen the weights of data points near the time t0 when the perturbation occurs, highlighting the characteristics of the initial transient response; the time distance function is defined as follows: , where t i Let t be the time of the i-th time step, and t0 be the time when the disturbance occurs; Attention weight formula: ,in Weighting characteristics: and The smaller the time difference, The larger the disturbance, the more attention should be paid to the rapid frequency / power change period of the initial 0-20ms of the disturbance. The goal of the small perturbation attention mechanism is to uniformly cover all time steps, capture overall statistical regularities, and avoid interference from local fluctuations; the attention weight formula adopts a near-uniform weight distribution. Where β2 = 0.001; or a uniform distribution can be directly adopted. Weighting characteristics: The weight difference between each time step is ≤5%, achieving balanced extraction of features across all time periods and supporting the statistical evaluation of damping parameters; The goal of the perturbation attention mechanism is to focus on periods of large fluctuations and capture core fluctuation characteristics; the importance score is defined as: quantifying fluctuation intensity based on a sliding window integral of the frequency change rate. Where W is the sliding window radius; attention weight formula: Weighting characteristics: within the sliding window The larger the sum of absolute values, the more drastic the fluctuation. The higher, The larger the value, the more automatically it focuses on the peak periods of power / frequency fluctuations; The conditional attention network encodes labels one-hot based on the perturbation type, adaptively selects the corresponding weight calculation logic, and combines the T×4 basic temporal features with the corresponding attention weights. Element-wise multiplication yields conditional attention-weighted features.
7. The online measurement method for power grid inertia in multi-disturbance scenarios according to claim 6, characterized in that, The process of inputting weighted features into a Long Short-Term Memory (LSTM) dual-output model and simultaneously evaluating online to obtain the power grid inertia and impedance values includes: A dual-output end-to-end model combining Conditional Attention (CAT) and Long Short-Term Memory (LSTM) networks is constructed: the input layer has a dimension of T×4; the CAT layer connects to the CAT network and outputs weighted features; there are two LSTM hidden layers with the activation function tanh; one fully connected layer with the activation function ReLU; and the output layer has two output nodes with the activation function ReLU, corresponding to the inertia evaluation value H (in seconds) and the damping evaluation value D (in % rated power / Hz). Training sample set: Covering several scenarios involving multiple types of disturbances, multiple types of new energy penetration rates, multiple interval inertia values, multiple interval damping values, and multiple expert-specified power component combinations. For each scenario, a set of historical real samples are collected to form high-quality samples, including preprocessed input features, disturbance type labels, expert-specified component combinations, and real inertia values. True damping value Validation and Test Sets: The ratio of validation to test sets is set, with samples drawn from different power grid operating periods and topology scenarios than the training set; Loss Function: Joint Mean Square Error (MSE) loss is used to balance the evaluation accuracy of inertia and damping. ; Training strategy: The AdamW optimizer is used in conjunction with early stopping. Training stops if the joint loss on the validation set does not decrease for five consecutive rounds to avoid overfitting. Online inference: Weighted features are input into the trained model, and real-time inertia evaluation values are output. Damping assessment value .
8. The online measurement method for power grid inertia in multi-disturbance scenarios according to claim 1, characterized in that, The output includes assessment confidence level and key traceability information, including: The output includes core evaluation parameters: real-time inertia values. Real-time damping value Auxiliary information: disturbance type identifier, window duration T, expert-specified power disturbance component combination, and assessment confidence level C; tracing information: the identifier includes the attention mechanism type, key parameters, and key preprocessing indicators; among which, the assessment confidence level C is calculated based on the dynamic change of the adaptive inertia and the multi-sample distribution). ; In the formula, The mean of the real inertia values in the historical sample set that matches the current scene; The mean of the actual damping values in the historical sample set that matches the current scenario; The standard deviation of the error inertia predicted by the model in the above matched sample set; The standard deviation of the model's predicted damping error in the above matched sample set; It is a very small positive number; This is a scenario reliability correction factor; Confidence level determination: When C≥90%, the result is determined to be reliable; when 80%≤C<90%, it is marked as requiring attention; when C<80%, it is marked as low confidence, prompting dispatchers to verify it in conjunction with other monitoring methods.
9. An online measurement system for power grid inertia in multi-disturbance scenarios, characterized in that, Using the method of any one of claims 1 to 8, the system comprises: The acquisition unit is used to acquire multi-source core measurement data of the power grid in real time and perform preprocessing operations to obtain standardized target input features. The multi-source core measurement data includes: power management unit (PMU) high-frequency measurement data, SCADA power data, new energy power output time series, DC power time series, energy storage power time series, and disturbance identification data. The window adjustment unit is used to dynamically adjust the window length of the target input features according to different disturbance types, and output the target window input feature matrix adapted to the disturbance type, as well as the disturbance type label and the power disturbance component combination information specified by the expert. The conditional attention unit is used to construct the conditional attention network. It uses the perturbation type label as a control signal to adaptively select the corresponding attention weight calculation logic and extract weighted features. The evaluation unit is used to input the weighted features into the Long Short-Term Memory (LSTM) dual-output model, synchronously evaluate the grid inertia and impedance values online, and output the evaluation confidence level and key traceability information.
10. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the method as described in any one of claims 1-8.