XGBoost low-voltage transformer area missing voltage completion method

Through the XGBoost model and Gray Wolf algorithm, the feature selection and hyperparameter optimization of the voltage data in the low-voltage platform area is solved, and the problem that the distribution network in the low-voltage platform area cannot obtain the key operating data of the power grid is achieved, and the accurate completion of the voltage in the low-voltage platform area is achieved. and analysis, improve decision-making reference for low voltage governance.

CN119180456APending Publication Date: 2024-12-24NANJING INST OF TECH
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411298811.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-18
Publication Date
2024-12-24

AI Technical Summary

Technical Problem

The distribution network in the low-voltage platform area cannot accurately obtain the key operating data of the power grid, resulting in the inability to effectively evaluate the voltage in the low-voltage platform area. The traditional distribution network voltage calculation method cannot be applied.

Method used

The XGBoost model is used to combine the Gray Wolf algorithm to select the secondary side voltage and line parameters of the head-end distribution transformer in the low-voltage table area, and complete the missing voltage through data preprocessing and hyperparameter optimization.

Benefits of technology

It realizes accurate completion of the missing voltage of users in low-voltage table areas, improves the accuracy of low-voltage cause analysis, and provides decision-making reference for low-voltage governance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119180456A_ABST
    Figure CN119180456A_ABST
Patent Text Reader

Abstract

The invention discloses an XGBoost low-voltage transformer area missing voltage completion method, which comprises the following steps of: obtaining data from marketing and ledger, selecting head end measurement and line parameters of a low-voltage transformer area as features in feature selection, and taking user voltage as a label to form a data set; performing preprocessing and data set division on the data, defining an XGboost model, performing hyper-parameter optimization on the XGboost model based on a grey wolf algorithm, and training the model by using a data set; and training the feature input model to form a prediction model, and applying the trained model to power distribution network voltage prediction. According to the method, the hyper-parameter of the XGBoost is optimized by using the grey wolf algorithm, the optimal performance of the XGBoost is obtained, and the missing voltage data of the low-voltage transformer area are complemented through the optimized model. The defects of a traditional power distribution network voltage calculation method can be overcome, the missing voltage of the users in the low-voltage transformer area can be complemented more accurately, and a decision reference is provided for low-voltage treatment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of missing voltage complementation in low-voltage areas, and in particular relates to an XGBoost missing voltage complementation method in low-voltage areas. Background Art

[0002] Voltage quality is an important indicator for measuring power quality, and it is also an important part of improving the efficiency of distribution network operation and maintenance, as well as the quality of service, and ensuring the reliability and stability of power supply. Due to the power supply radius, heavy overload caused by seasonal loads, three-phase imbalance, virtual connection and other reasons, the voltage level on the user side of the low-voltage substation is often low or even the substation voltage is unqualified, which seriously affects the voltage qualification rate. Therefore, it is particularly important to reasonably evaluate the voltage level of the low-voltage substation. However, due to the complex grid structure of the low-voltage distribution network, the large number of nodes and the low coverage of measurement units, it is impossible to accurately obtain the key operation data of the power grid, resulting in the inability to apply the traditional distribution network voltage calculation method, and the user's complete voltage data cannot be obtained, so that the low-voltage substation voltage cannot be effectively evaluated.

[0003] In view of the above problems, there is an urgent need for a new voltage completion method that can overcome the shortcomings of the traditional distribution network voltage calculation method, more accurately complete the missing voltage of low-voltage users, and effectively deal with the problem of missing collected data. Complete voltage data can help improve the accuracy of low-voltage cause analysis and provide decision-making reference for low-voltage management. Summary of the invention

[0004] 1. Technical problems to be solved:

[0005] The existing low-voltage distribution network is unable to accurately obtain key grid operation data and cannot obtain complete voltage data from users, making it impossible to effectively evaluate the low-voltage distribution network voltage.

[0006] 2. Technical solution:

[0007] In order to solve the above problems, the present invention provides a method for filling missing voltage in a low-voltage area of ​​XGBoost, which is characterized by comprising the following steps:

[0008] Step 1: Obtain the head-end substation voltage and line parameters from the marketing and ledger respectively. Feature selection selects the secondary side voltage and line parameters of the low-voltage substation head-end distribution transformer as features and the user voltage as a label to form a data set. The line parameters include the line length and line impedance from the head-end to the user.

[0009] Step 2: Preprocess the data and divide the data set.

[0010] Step 3: Define the XGboost model, optimize the hyperparameters of the XGboost model based on the Grey Wolf Algorithm, and train the model with the dataset.

[0011] Step 4: Use the trained model to complete the missing voltage in the low-voltage area.

[0012] Furthermore, in the step one: the data obtained from marketing is that marketing provides data at 15-minute intervals for the head-end substation in the substation area, and provides hourly collection data for the user's data; the voltage, line parameters and secondary side voltage data of the head-end distribution transformer of users with complete measurement data in the low-voltage substation area are selected to form a data set, wherein the secondary side voltage and line parameters of the head-end distribution transformer are used as feature data, and the user voltage data is used as label data.

[0013] Furthermore, in the step 2: preprocessing the data and dividing the data set includes filling in missing data values, processing data outliers, normalizing the data, and allocating the data.

[0014] Filling in missing data values: The mean filling method is used to fill in the missing voltage on the secondary side of the low-voltage distribution transformer at the head end of the low-voltage substation.

[0015] Data outlier processing: Take the three criteria as the judgment standard, perform data cleaning, and eliminate outliers in voltage data.

[0016] Data normalization: Z-score normalization method was used to normalize the data.

[0017] Data allocation: Use the leave-one-out cross-validation method to allocate data. Divide the data into N samples according to the size of the data set, and cycle from 1 to N, with one sample corresponding to each cycle. In each cycle, select the sample with sequence number i (i∈[1, N]) as the test set, that is, leave the i-th sample, and form the training set with all samples except the i-th sample. Use the current training set to train your model. After the model training is completed, predict the remaining test set (single sample) and record the performance indicators of the model.

[0018] Furthermore, the missing data value filling is specifically as follows: for the missing values, a data filling method is used, and the filled data is the average value calculation formula:

[0019]

[0020] in is the filling value of the missing voltage data at a certain moment on the secondary side of the head-end power distribution, x i It is the voltage value of the secondary side of the head-end distribution transformer at the time when the voltage is missing on different dates.

[0021] The specific processing of data outliers is as follows: taking the 3σ criterion as the judgment standard, the standard deviation σ is calculated as follows:

[0022]

[0023] N is the total sample size, X i For each sample observation, μ is the mean value of the total sample. When the data value falls within the interval (μ-3σμ+3σ), the data is considered normal. If the data falls outside this interval, it is judged as an outlier and discarded. After discarding, it is filled in according to the method of handling missing values.

[0024] The data normalization is specifically: using the Z score normalization method to normalize the data, and the calculation formula is as follows:

[0025]

[0026] Among them, μ is the mean of all data points, σ ​​is the standard deviation, which is used to measure the dispersion of data points relative to the mean, and x is the standard deviation. i Every data point in the dataset.

[0027] The data allocation is specifically as follows: first, divide the data set into N samples, and loop from 1 to N, with each loop corresponding to one sample. In each loop, select the sample with serial number i (i∈[1, N]) as the test set, that is, keep the i-th sample, and use all samples except the i-th sample to form a training set. Use the current training set to train your model. After the model training is completed, predict the remaining test set and record the performance indicators of the model. Store the performance indicators of the model in each loop, and continue to loop this step until all samples are used as a test set. After all samples are used as test sets, calculate the average of all stored performance indicators.

[0028] Furthermore, in the step three, the specific method is: first establish an XGBoost model, randomly initialize the population of the gray wolf algorithm, calculate the individual fitness of the gray wolf, divide the wolf pack into levels, capture prey, update the head wolf α, the first level β, the second level δ and the position of the prey, and obtain the optimal solution. The wolf pack level division is specifically as follows: the entire wolf pack is divided into 4 levels according to fitness, and the top three wolves with the best fitness are saved and defined as the head wolf α, the first level β, and the second level δ respectively; the remaining wolf pack is ω, among which α is the highest-level wolf, responsible for leading the entire wolf pack and deciding the direction of capture during hunting. The lower-level wolf packs must obey the command of the higher-level wolf packs to carry out group hunting actions.

[0029] Furthermore, the initialization setting is specifically as follows: firstly, XGBoos is established, and the gray wolf algorithm is initialized and parameterized, including the number of gray wolves N, as well as multiple parameters such as a, A and C and the maximum number of iterations t, and the gray wolf population X = (X1, X2...X N ) and the position X of the individual wolves i =(X i1 , Xi2 …X iD ), where i∈{1, 2, 3…N}, and where A and C are collaboration coefficient vectors.

[0030] Furthermore, the calculation of the individual fitness of the gray wolf is specifically as follows: in the XGBoost model parameter optimization stage, the fitness function of the individual wolf population is the root mean square error RMSE between the prediction result of the XGBoost model and the real data under the individual parameters. After randomly initializing the population of the gray wolf algorithm, the search range is determined, and the parameter data represented by the current round of population is sequentially imported into the XGBoost model. By training the XGBoost model, the calculation result of the XGBoost model is obtained, and then the validation set is used to verify the model that has completed the training, and finally the fitness function is obtained.

[0031] Furthermore, the trapping of prey is specifically: this behavior is described by a mathematical model, and the formula is as follows:

[0032] D=|C·X p (t)-X(t)|

[0033] X(t+1)=X (p) (t)-A·D

[0034] Where A and C are the collaboration coefficient vectors; t is the number of iterations; X p represents the position vector of the prey; X represents the current position vector of the gray wolf. The values ​​of A and C can be obtained by the following formula:

[0035] A=2a·r1-a

[0036]

[0037] C=2r2

[0038] According to A=2a·r1-a, the distances from each wolf ω to the leader wolf α, the first level β, and the second level δ are calculated.

[0039] Where a is the convergence factor, which decreases linearly from 2 to 0 as the number of iterations increases; r1 and r2 are random number vectors in [0, 1].

[0040] Furthermore, the updating of α, β, δ and the position of the prey is specifically as follows: the coordinates of the prey are unknown to the wolf pack. Assuming that the leader wolf α is the wolf closest to the prey, and β and δ are the wolves next closest to the prey, firstly measure the distance D between α, β, δ and the prey. α , D β , D δ , the calculation formula is as follows:

[0041] D α =|C1·Xa |

[0042] D β =|C2·X β |

[0043] D δ =|C3·X δ |

[0044] Then by constantly updating α, β, δ, the wolf's coordinate X α , X β , X δ To summon other gray wolves in the wolf pack to keep approaching the prey, set the coordinates of the prey to X (t+1) Finally, it is determined that the coordinates of the leader wolf α are the coordinates of the prey, that is, X (t+1) is the optimal solution, whose X α , X β , X δ and X (t+1) The calculation formula is as follows:

[0045] X1=X α -A1(D α ), X2=X β -A2(D β ), X3=X δ -A3(D β )

[0046]

[0047] Furthermore, the obtaining of the optimal solution is specifically as follows: Obtaining the optimal solution: The last step of wolf hunting is to attack and prey, calculate the optimal solution, and determine whether the result meets the requirements. If the maximum number of iterations is reached, the operation ends and the optimal solution is output. Otherwise, the hunting process is returned to continue the optimization calculation until the optimal XGBoost hyperparameters are output. The optimized XGBoost model is trained using the training set data to obtain the final low-voltage area missing voltage completion model.

[0048] 3. Beneficial effects:

[0049] The present invention applies machine learning technology to the calculation of low-voltage substation voltage, selects the XGxgboost model, takes advantage of the strong global parameter search convergence ability of the Gray Wolf optimization algorithm, uses the Gray Wolf algorithm to optimize the hyperparameters of XGBoost, obtains the best performance of XGBoost, and completes the missing voltage data of the low-voltage substation through the optimized model. It solves the problem that due to the complex grid structure of the low-voltage distribution network, the large number of nodes, and the low coverage of the measurement unit, the key operation data of the power grid cannot be accurately obtained, resulting in the inability to apply the traditional distribution network voltage calculation method and the inability to obtain the complete voltage data of the user. In order to solve this problem, the present method can overcome the shortcomings of the traditional distribution network voltage calculation method, more accurately complete the missing voltage of the low-voltage substation users, and effectively deal with the problem of missing collected data. The complete voltage data helps to improve the accuracy of the low-voltage cause analysis and provide a decision-making reference for low-voltage governance. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 It is a flow chart of the method for completing missing voltage in the low-voltage area of ​​XGBoostX provided by the present invention.

[0051] Figure 2 3 is a voltage comparison diagram between the predicted voltage value and the actual value in the embodiment. DETAILED DESCRIPTION

[0052] The technical solution of the present invention is further described in detail below through specific implementation methods. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.

[0053] The present invention provides a method for filling missing voltage in low-voltage area based on gray wolf algorithm optimized XGBoost, referring to Figure 1 As shown, the following steps are included:

[0054] Step 1: Obtain the head-end substation voltage and line parameters from the marketing and ledger respectively. Feature selection selects the secondary side voltage and line parameters of the low-voltage substation head-end distribution transformer as features and the user voltage as a label to form a data set. The line parameters include the line length and line impedance from the head-end to the user.

[0055] In a specific example, step one includes: obtaining data from marketing, which provides data at 15-minute intervals (96:00 a.m. daily) to the head-end substation in the substation area, and provides hourly data collection (24:00 a.m. daily) to the user's data, and selects the voltage (24:00 a.m. daily), line parameters and head-end distribution transformer secondary side voltage data (hourly data collection, 24:00 a.m. daily) of users with complete measurement data in the low-voltage substation area to form a data set, in which the head-end distribution transformer secondary side voltage and line parameters are used as feature data, and the user voltage data is used as label data.

[0056] Step 2: Perform data preprocessing and divide the data into a training set and a test set; in a specific example, step 2 further includes:

[0057] Data missing value filling: For missing values, the data filling method is used, and the filled data is the average value calculation formula:

[0058]

[0059] in is the filling value of the missing voltage data at a certain moment on the secondary side of the head-end power distribution, x i It is the voltage value of the secondary side of the head-end distribution transformer at the time when the voltage is missing on different dates.

[0060] Data outlier detection: The 3σ criterion is used as the judgment standard, and the standard deviation σ is calculated as follows:

[0061]

[0062] N is the total sample size, X i is the observation of each sample, and μ is the average value of the total sample. When the data value falls within the interval (μ-3σ, μ+3σ), the data is considered normal. If the data falls outside the interval (, it is considered an outlier and discarded. After discarding, the method of handling missing values ​​is implemented.

[0063] Data normalization: The Z score normalization method is used to normalize the data. The calculation formula is as follows:

[0064]

[0065] Among them, μ is the mean of all data points, σ ​​is the standard deviation, which is used to measure the dispersion of data points relative to the mean, and x is the standard deviation. i Every data point in the dataset.

[0066] Data allocation: First, divide the data set into N samples, and loop from 1 to N, with one sample corresponding to each loop. In each loop, select the sample with serial number l (i∈[1, N]) as the test set, that is, keep the i-th sample, and use all samples except the i-th sample to form the training set. Use the current training set to train your model. After the model training is completed, predict the remaining test set (single sample) and record the performance indicators of the model. Store the performance indicators of the model in each loop, and continue to loop this step until all samples are used as a test set. After all samples are used as test sets, calculate the average of all stored performance indicators. This average can be used as an estimate of the performance of the model on unknown data.

[0067] Step 3: Use the Grey Wolf Algorithm (GW0) to search for hyperparameters on the training set, evaluate the model performance on the validation set, and update and select hyperparameters based on the performance on the validation set.

[0068] In a specific example, the step three further includes:

[0069] Initialization settings: First, the XGBoos model is established, and the gray wolf algorithm is initialized with parameters including the number of gray wolves N, a, A, C, the maximum number of iterations t, and the gray wolf population X = (X1, X2...X N ) and the position X of the individual wolves i =(X i1 , X i2 ...X iD ), where i∈{1,2,3…N}.

[0070] Calculate the fitness of individual gray wolves: In the XGBoost model parameter optimization stage, the fitness function of individual wolf populations is the root mean square error (RUSE) between the prediction results of the XGBoost model and the real data under the individual parameters. After randomly initializing the population of the gray wolf algorithm, determine the search range. Import the parameter data represented by the current round of populations into the XGBoost model in sequence, and obtain the calculation results of the XGBoost model by training the XGBoost model. Then use the validation set to verify the trained model, and finally obtain the fitness function.

[0071] Wolf pack level division: The entire wolf pack is divided into four levels according to fitness, and the top three wolves with the best fitness are saved and defined as the alpha wolf α, the first level β, and the second level δ; the remaining wolves are ω.

[0072] Among them, α is the wolf with the highest level, which is responsible for leading the entire wolf pack and deciding the direction of capture during the hunting (optimization) process. The wolf packs with lower levels must obey the command of the wolf packs with higher levels to carry out group hunting operations.

[0073] Surrounding prey: This behavior is described by a mathematical model, the formula is as follows:

[0074] D=|C·X p (t)-X(t)|

[0075] X(t+1)=X (p) (t)-A·D

[0076] Where A and C are the collaboration coefficient vectors; t is the number of iterations; X p represents the position vector of the prey; X represents the current position vector of the gray wolf. The values ​​of A and C can be obtained by the following formula:

[0077] A=2a·r1-a

[0078]

[0079] C=2r2

[0080] According to A=2a·r1-a, the distance from each wolf ω to each wolf α, β, δ is calculated.

[0081] Where a is the convergence factor, which decreases linearly from 2 to 0 as the number of iterations increases; r1 and r2 are random number vectors in [0, 1].

[0082] Update α, β, δ and the position of the prey: The coordinates of the prey are unknown to the wolf pack. Assume that the leader α is the wolf closest to the prey, and β and δ are the wolves next closest to the prey. First, calculate the distance D between α, β, δ and the prey. α , D β , D δ , the calculation formula is as follows:

[0083] D α =|C1·X α |

[0084] D β =|C2·X β |

[0085] D δ =|C3·X δ |

[0086] Then by constantly updating α, β, δ, the wolf's coordinate X α , X β , X δ To summon other gray wolves in the wolf pack to keep approaching the prey, set the coordinates of the prey to X (t+1) Finally, it is determined that the coordinates of the leader wolf α are the coordinates of the prey, that is, X (t+1) is the optimal solution. α , X β , X δ and X (t+1) The calculation formula is as follows:

[0087] X1=X α -A1(D α ), X2=X β -A2(D β ), X3=X δ -A3(D β )

[0088]

[0089] Obtaining the optimal solution: The last step of the wolf pack hunting is to attack and prey on the prey and calculate the optimal solution. Determine whether the result meets the requirements. If the maximum number of iterations is reached, the operation ends and the optimal solution is output. Otherwise, return to the hunting process to continue the optimization calculation until the optimal XGBoost hyperparameters are output. Use the training set data to train the optimized XGBoost model to obtain the final low-voltage area missing voltage completion model.

[0090] The experiment selected data from a low-voltage area in a western province from April 1, 2024 to April 7, 2024. There are 384 users in this low-voltage area, and each user has 168 data in a week, totaling 64,515 data as model samples. Taking a certain user as an example, the comparison between the predicted voltage value and the actual value at a certain time point is as follows Figure 2 After analyzing the prediction results, the model prediction value can guarantee a high accuracy.

[0091] Specifically, this technical solution is suitable for completing the missing voltage data in low-voltage substations. It applies machine learning technology to the voltage calculation of low-voltage substations. The XGxgboost model is selected. The advantages of the gray wolf optimization algorithm's strong global parameter search and convergence ability are utilized. The gray wolf algorithm is used to optimize the hyperparameters of XGBoost to obtain the best performance of XGBoost. The optimized model is used to complete the missing voltage data in the low-voltage substation. It solves the problem that due to the complex grid structure of the low-voltage distribution network, the large number of nodes, and the low coverage of measurement units, the key operation data of the power grid cannot be accurately obtained, resulting in the inability to apply the traditional distribution network voltage calculation method and the inability to obtain the complete voltage data of the user. In order to solve this problem, this method can overcome the shortcomings of the traditional distribution network voltage calculation method, more accurately complete the missing voltage of low-voltage substation users, and effectively deal with the problem of missing collected data. The complete voltage data helps to improve the accuracy of low-voltage cause analysis and provide a decision-making reference for low-voltage governance.

Claims

1. A method for filling missing voltage in low-voltage areas of XGBoost, characterized in that: The following steps are involved: Step 1: Obtain the head-end transformer voltage and line parameters from the marketing and ledgers respectively. Feature selection selects the secondary side voltage and line parameters of the low-voltage substation head-end distribution transformer as features and the user voltage as a label to form a data set. The line parameters include the line length from the head-end to the user and the line impedance. Step 2: Preprocess the data and divide the data set; Step 3: Define the XGboost model, optimize the hyperparameters of the XGboost model based on the Gray Wolf Algorithm, and train the model with the dataset; Step 4: Use the trained model to complete the missing voltage in the low-voltage area.

2. The method for compensating missing voltage in low-voltage areas of XGBoost according to claim 1, characterized in that: In the step 1: obtaining data from marketing means that marketing provides data at 15-minute intervals to the head-end substation in the substation area and provides hourly data collection to users; The voltage, line parameters and secondary voltage data of the head-end distribution transformer of users with complete measurement data in the low-voltage substation are selected to form a data set, in which the secondary voltage of the head-end distribution transformer and the node load distance are used as feature data, and the user voltage data is used as label data.

3. The method for compensating missing voltage in low-voltage areas of XGBoost according to claim 1, characterized in that: In the step 2: preprocessing the data and dividing the data set includes filling in missing values, processing data outliers, normalizing data, and allocating data. Filling in missing data values: The mean filling method is used to fill in the missing voltage on the secondary side of the low-voltage distribution transformer at the head end of the low-voltage station area; Data outlier processing: Take the three criteria as the judgment standard, perform data cleaning, and remove voltage data outliers; Data normalization: The Z score normalization method was used to normalize the data; Data allocation: Use the leave-one-out cross-validation method to allocate data. Divide the data into N samples according to the size of the data set, and cycle from 1 to N, with one sample corresponding to each cycle. In each cycle, select the sample with sequence number i (i∈[1,N]) as the test set, that is, leave the i-th sample, and form the training set with all samples except the i-th sample. Use the current training set to train your model. After the model training is completed, predict the remaining test set (single sample) and record the performance indicators of the model.

4. The method for compensating missing voltage in low-voltage areas of XGBoost according to claim 3, characterized in that: The missing value filling method is as follows: for missing values, the data filling method is used, and the filled data is the average value calculation formula: in is the filling value of the missing voltage data at a certain moment on the secondary side of the head-end power distribution, x i The voltage value of the secondary side of the head-end distribution transformer at the time of missing voltage on different dates; The specific processing of data outliers is as follows: taking the 3σ criterion as the judgment standard, the standard deviation σ is calculated as follows: N is the total sample size, X i For each sample observation, μ is the average value of the overall sample. When the data value falls within the interval (μ-3σ, μ+3σ), the data is considered normal. If the data falls outside the interval, it is considered an outlier and discarded. After discarding, it is filled in according to the method of handling missing values. The data normalization is specifically: using the Z score normalization method to normalize the data, and the calculation formula is as follows: Among them, μ is the mean of all data points, σ ​​is the standard deviation, which is used to measure the dispersion of data points relative to the mean, and x is the standard deviation. i Each data point in the dataset; The data allocation is specifically as follows: first, divide the data set into N samples, and loop from 1 to N, with each loop corresponding to one sample. In each loop, select the sample with serial number i (i∈[1,N]) as the test set, that is, keep the i-th sample, and use all samples except the i-th sample to form a training set. Use the current training set to train your model. After the model training is completed, predict the remaining test set and record the performance indicators of the model. Store the performance indicators of the model in each loop, and continue to loop this step until all samples are used as a test set. After all samples are used as test sets, calculate the average of all stored performance indicators.

5. The method for compensating missing voltage in low-voltage area of ​​XGBoost according to claim 1, characterized in that: In the step three, the specific method is: first establish an XGBoost model, randomly initialize the population of the gray wolf algorithm, calculate the individual fitness of the gray wolf, divide the wolf pack into levels, capture prey, update the head wolf α, the first level β, the second level δ and the position of the prey, and obtain the optimal solution. The wolf pack level division is specifically as follows: the entire wolf pack is divided into 4 levels according to fitness, and the top three wolves with the best fitness are saved and defined as the head wolf α, the first level β, and the second level δ respectively; the remaining wolf pack is ω, among which α is the highest-level wolf, responsible for leading the entire wolf pack and deciding the capture direction during the hunting process. The lower-level wolf packs must obey the command of the higher-level wolf packs to carry out group hunting operations.

6. The method for compensating missing voltage in low-voltage areas of XGBoost according to claim 5, characterized in that: The initialization setting is specifically as follows: first, XGBoos is established, and the gray wolf algorithm is initialized and parameterized. The parameters include the number of gray wolves N, as well as multiple parameters such as a, A, and C, and the maximum number of iterations t, and the gray wolf population X = (X1, X2…X N ) and the position X of the individual wolves i =(X i1 ,X i2 …X iD ), where i∈{1,2,3…N}, and A and C are collaboration coefficient vectors.

7. The method for compensating missing voltage in low-voltage areas of XGBoost according to claim 5, characterized in that: The calculation of the individual fitness of the gray wolf is specifically as follows: in the XGBoost model parameter optimization stage, the fitness function of the individual wolf population is the root mean square error RMSE between the prediction result of the XGBoost model and the real data under the individual parameters. After randomly initializing the population of the gray wolf algorithm, the search range is determined, and the parameter data represented by the current round of population is sequentially imported into the XGBoost model. By training the XGBoost model, the calculation result of the XGBoost model is obtained, and then the validation set is used to verify the model that has completed the training, and finally the fitness function is obtained.

8. The method for compensating missing voltage in low-voltage areas of XGBoost according to claim 5, characterized in that: The specific behavior of trapping prey is as follows: This behavior is described by a mathematical model, and the formula is as follows: D=|C·X p (t)-X(t)| X(t+1)=X (p) (t)-A·D Where A and C are the collaboration coefficient vectors; t is the number of iterations; X p represents the position vector of the prey; X represents the current position vector of the gray wolf. The values ​​of A and C can be obtained by the following formula: A=2a·r1-a C=2r2 According to A=2a·r1-a, the distances from each wolf ω to the leader wolf α, the first level β, and the second level δ are calculated. Where a is the convergence factor, which decreases linearly from 2 to 0 as the number of iterations increases; r1 and r2 are random number vectors in [0, 1].

9. The method for compensating missing voltage in low-voltage areas of XGBoost according to claim 8, characterized in that: The updating of the positions of the alpha wolf, the first level β, the second level δ and the prey is as follows: the prey coordinates are unknown to the wolf pack. Assuming that the alpha wolf is the wolf closest to the prey, and β and δ are the wolves next closest to the prey, firstly measure the distance D between α, β, δ and the prey. α , D β , D δ , the calculation formula is as follows: D α =|C1·X a | D β =|C2·X β | D δ =|C3·X δ | Then by constantly updating α, β, δ, the wolf's coordinate X α , X β , X δ To summon other gray wolves in the wolf pack to keep approaching the prey, set the coordinates of the prey to X (t+1) Finally, it is determined that the coordinates of the leader wolf α are the coordinates of the prey, that is, X (t+1) is the optimal solution, whose X α , X β , X δ and X (t+1) The calculation formula is as follows: X1=X α -A1(D α ),X2=X β -A2(D β ),X3=X δ -A3(D β ) 10. The method for filling missing voltage in low-voltage area of ​​XGBoost according to claim 9 is characterized in that: The obtaining of the optimal solution is specifically as follows: obtaining the optimal solution: the last step of wolf hunting is to attack and prey, calculate the optimal solution, and determine whether the result meets the requirements. If the maximum number of iterations is reached, the operation ends and the optimal solution is output. Otherwise, the hunting process is returned to continue the optimization calculation until the optimal XGBoost hyperparameters are output. The optimized XGBoost model is trained using the training set data to obtain the final low-voltage area missing voltage completion model.

Citation Information

Cited By

  • Archive management system based on artificial intelligence

    CN120216747A