User adjustable capability mining method and system based on optimized neural network

By improving the combination of particle swarm optimization and LSTM network, the stability and accuracy problems of traditional algorithms in load forecasting in power systems are solved, the accurate classification of power user loads and the mining of adjustable capabilities are achieved, and the dispatching capability and system stability of the power grid are improved.

CN116522230BActive Publication Date: 2025-09-26YANGZHOU JIANGDU POWER SUPPLY COMPANY OF JIANGSU ELECTRIC POWER +2
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202310499187.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-05
Publication Date
2025-09-26
Estimated Expiration
2043-05-05

AI Technical Summary

Technical Problem

Traditional intelligent algorithms have stability issues when optimizing the selection of initial values, making it difficult to obtain a global optimal solution. In addition, in the context of massive electricity user data, system stability is difficult to guarantee, and it is difficult to meet the complexity and diversified needs of grid demand-side scheduling.

Method used

A method based on optimized neural networks is adopted to perform load classification through LSTM network. The LSTM hyperparameters are optimized in combination with the improved particle swarm algorithm. Multi-particle initial values ​​and multi-objective functions are introduced to optimize the position and velocity equations of the particle swarm algorithm. Gradient targets are introduced into the fitness function to realize the training of LSTM network and load forecasting.

Benefits of technology

It improves the accuracy of load forecasting and the stability of the system, can identify the adjustable power range and time period according to load characteristics, comprehensively calculate the overall adjustable capacity, and improve the dispatching efficiency and stability of the power system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116522230B_ABST
    Figure CN116522230B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and system for mining user adjustable capacity based on an optimized neural network, comprising the following steps: after load classification under LSTM, based on the introduction of nonlinear variable weights and mutation operations into the traditional particle swarm algorithm, multi-particle initial values ​​and multi-objective functions are introduced to further improve the particle swarm algorithm, the improved particle swarm algorithm is combined with LSTM, the stability of the algorithm is taken into account, overload convergence is guaranteed, and the load prediction accuracy is improved. The LSTM hyperparameters are optimized using the improved particle swarm algorithm to solve the problem of LSTM parameters being difficult to obtain. By accurately classifying and predicting the load, the adjustable power range and adjustable time period of the load can be identified according to various load characteristics, and the total adjustable load at each time point can be comprehensively calculated, thereby having user adjustable capacity overall.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of intelligent dispatching of power systems, and in particular to a method and system for mining user adjustable capabilities based on an improved PSO parameter optimization neural network. Background Art

[0002] With the introduction and development of new power systems, more and more power users are participating in the various services of power grid companies. The interaction between power sources, the grid, and loads is increasing. While this provides energy reserves for the grid, it also increases the difficulty of demand-side dispatch. Furthermore, conventional power services are limited in scope and cannot fully meet the differentiated and diverse service needs of customers. Therefore, there is an urgent need to identify power users and accurately classify and predict their loads, so as to timely understand the changing patterns and development of power loads and achieve scientific management of power loads.

[0003] Advances in modern communications, measurement, and data management technologies have enabled the collection of massive amounts of data from electricity users, highlighting the inherent characteristics of these users. Conducting load characteristic research based on this vast amount of user data and repeatedly exploring the dispatch potential of industrial, commercial, and residential loads is of great theoretical and practical significance for adapting to future interactions across diverse objectives, levels, and timescales.

[0004] Currently, traditional intelligent optimization algorithms can face stability issues due to issues with the selection of initial values, making convergence difficult or even impossible to achieve a global optimal solution. Furthermore, even when a traditional algorithm achieves a global optimal solution, it is typically only a single-point optimal solution, making it difficult to guarantee system stability near that point. Given the vast amount of electricity user data available, addressing these issues is urgent. Summary of the Invention

[0005] In response to the above problems, the present invention provides a method and system for mining user adjustable capabilities based on optimized neural networks.

[0006] The technical solution of the present invention is: a method for mining user adjustable capabilities based on an optimized neural network, comprising the following steps:

[0007] S1. Load classification through LSTM network;

[0008] S2. Based on nonlinear variable weight and mutation operation, multi-particle initial value and multi-objective function are introduced to improve the particle swarm optimization algorithm;

[0009] S3. Combine the improved particle swarm algorithm with LSTM, use the improved particle swarm algorithm to optimize the LSTM hyperparameters, and train the LSTM network;

[0010] S4. Based on the results of load classification, the adjustable range and adjustable time period of the load of this type are given to obtain the overall adjustable capability.

[0011] In step S1, users are divided into three categories: fully adjustable load, semi-adjustable load, and completely non-adjustable load through the LSTM network.

[0012] Step S2 includes:

[0013] First, multiple groups of iterative initial values ​​are selected to perform iterative optimization of the particle swarm algorithm;

[0014] Then, the position and velocity equations in the improved particle swarm algorithm are updated and the mutation strategy is introduced;

[0015] Finally, a gradient objective that reflects the spatial variation near the variable is introduced into the fitness function.

[0016] Select multiple groups of iterative initial values ​​to perform particle swarm algorithm iterative optimization. The iterative process for any group is as follows:

[0017] In the D-dimensional space composed of particles of size N, the optimal position x of particle i (i = 1, 2, ..., N) in the space is constructed respectively. i (x i1 ,x i2 ,...,x iD ), speed v i (v i1 ,v i2 ,...,v iD ), individual optimal solution pb i (pb i1 ,pb i2 ,...,pb iD ) and the group optimal solution gb i (gb i1 ,gb i2 ,...,gb iD ) information vector, the update formulas for speed and position are as follows:

[0018]

[0019]

[0020] Where: t is the number of iterations, ω is the inertia weight, U1, U2 are random numbers in [0,1];

[0021] Among them, the design inertia weight shows a nonlinear decrease, and the calculation formula of the inertia weight coefficient is as follows:

[0022]

[0023] Where: k = 1, 2, ... K is the number of optimization iterations, ω min With ω max are the minimum and maximum values ​​of the inertia coefficient during the optimization process.

[0024] The position and velocity equation updates in the improved particle swarm optimization algorithm are expressed as follows:

[0025]

[0026]

[0027] At the same time, the mutation strategy is introduced, and the calculation formula of the mutation operation is as follows:

[0028]

[0029] Where: δ is the variation factor, rand is a random number in [0,1], b i -a i is the search range of the i-th particle during the iteration process;

[0030] The mutation rate p is set as follows:

[0031]

[0032] Where: p max and p min are the maximum mutation rate and the minimum mutation rate respectively, k is the number of optimization iterations, and K is the maximum number of optimization iterations.

[0033] A gradient objective that reflects spatial changes near the variable is introduced into the fitness function. The objective function is as follows:

[0034]

[0035] in,

[0036]

[0037] Where: μ1, μ2 are the weight coefficients of functions f1, f2 respectively, f1 indicates the minimum total deviation of the expected prediction, which is expressed by the mean absolute percentage error of user load prediction, N is the number of sampling points for prediction, y i and are the actual value and the predicted value respectively; f2 represents the minimum variance of the function value in the space near the expected variable set, Ω is the space near the expected variable set, m is the number of input variable groups randomly selected in Ω, MAPE i is the output MAPE under the i-th group of input variables, MAPE j is the output MAPE under the jth set of input variables.

[0038] In step S3, the three key hyperparameters of the LSTM network, namely the number of neurons L1, the learning rate ε, and the number of training iterations k, are used as optimization variables for the improved particle algorithm;

[0039] By minimizing the fitness function value, the optimized model parameters of the LSTM network are obtained.

[0040] In step S3, the specific process of optimizing the LSTM model parameters using the improved particle algorithm is as follows:

[0041] 1) Preprocess user load data, remove erroneous data and normalize the data;

[0042] 2) Determine the optimization range of the hyperparameters L1, ε, and k to be optimized in the LSTM model;

[0043] 3) Initialize the parameters of the improved particle algorithm and substitute a set of initial values ​​of the particle swarm;

[0044] 4) According to the fitness function of the improved particle algorithm, in each iteration, the individual optimal position and the global optimal position are updated according to the fitness value, and the speed and position are updated according to equations (4)-(5) to find the LSTM network hyperparameters of the optimal model;

[0045] 5) Determine whether the maximum number of iterations has been reached; if so, pass the optimized parameters to the LSTM model and train it; if not, return to step 4);

[0046] 6) Determine whether all particle groups have been substituted; if so, compare the optimization results of all particle groups and select the best result as the output; if there are still particle groups that have not been substituted, return to step 3).

[0047] In step S4,

[0048] 1) Fully adjustable load: The load can be adjusted within the full range of adjustable power in all time periods;

[0049] Semi-adjustable loads: their power supply time period can be changed according to the plan, as long as the total power supply within a fixed time period remains unchanged;

[0050] Non-adjustable loads have a fixed operating time and cannot be changed, and their power is considered an immutable fixed value;

[0051] 2) Combining the load forecasting results of the LSTM network with the improved particle physics algorithm, the power of various adjustable loads is accumulated according to different load characteristics, and the overall adjustable capacity of the power system in each time period is finally obtained. The formula is as follows:

[0052]

[0053] Where: R represents the overall adjustable capacity of the system, η1, η2, η3 are the adjustment coefficients of fully adjustable load, semi-adjustable load, and completely non-adjustable load respectively, P L1 ,P L2 ,P L3 They are the predicted powers of the three types of loads at a certain moment.

[0054] User-adjustable capability mining system based on optimized neural networks, including:

[0055] Classification module, used to classify loads through LSTM network;

[0056] Improvement module, which is used to improve the particle swarm optimization algorithm by introducing multi-particle initial values ​​and multi-objective functions based on nonlinear variable weights and mutation operations;

[0057] The optimization module is used to combine the improved particle swarm algorithm with LSTM, optimize the LSTM hyperparameters using the improved particle swarm algorithm, and train the LSTM network;

[0058] The adjustment module is used to combine the results of load classification to give the adjustable range and adjustable time period of this type of load to obtain the overall adjustable capability.

[0059] In operation, this invention uses an LSTM network to classify loads. Building on the traditional particle swarm algorithm's introduction of nonlinear variable weights and mutation operations, it further improves the particle swarm algorithm by introducing multi-particle initialization and multi-objective functions, ensuring overload convergence and improving load forecasting accuracy. The improved particle swarm algorithm is used to optimize LSTM hyperparameters to address the difficulty in obtaining LSTM parameters. By accurately classifying and predicting loads, the load's adjustable power range and adjustable time period can be identified based on various load characteristics, and the total adjustable load at each time point can be comprehensively calculated, thereby providing overall user-adjustable capabilities. BRIEF DESCRIPTION OF THE DRAWINGS

[0060] Figure 1 is a flow chart of the present invention,

[0061] Figure 2 It is a schematic diagram of system stability;

[0062] Figure 3 To improve the overall flow chart of PSO;

[0063] Figure 4 It is the LSTM network unit diagram;

[0064] Figure 5 Schematic diagram of optimizing LSTM model parameters to improve PSO;

[0065] Figure 6 It is a load power prediction curve diagram in the embodiment. DETAILED DESCRIPTION

[0066] The present application will be further described below in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solutions of the present invention and are not intended to limit the scope of protection of the present application.

[0067] The present invention Figure 1 As shown, the user adjustable capability mining method based on the optimized neural network includes the following steps:

[0068] S1. Load classification through LSTM network (Long Short-Term Memory).

[0069] S2. Based on nonlinear variable weights and mutation operations, multi-particle initial values ​​and multi-objective functions are introduced to improve the particle swarm optimization algorithm (PSO).

[0070] S3. Combine the improved particle swarm algorithm with LSTM, use the improved particle swarm algorithm to optimize the LSTM hyperparameters, and train the LSTM network;

[0071] S4. Based on the results of load classification, the adjustable range and adjustable time period of the load of this type are given to obtain the overall adjustable capability.

[0072] In step S1, users are divided into three categories: fully adjustable load, semi-adjustable load, and completely non-adjustable load through the LSTM network.

[0073] In step S2, the traditional PSO algorithm is a method for optimizing individual flight paths, developed based on observations and research on the collective activities of species like birds. By constructing a multi-dimensional, multi-scale particle swarm, the algorithm iterates, updating both the individual and swarm optimal solutions. The fitness function is then used to determine the quality of the optimization results.

[0074] Step S2 includes:

[0075] First, multiple groups of iterative initial values ​​are selected to perform iterative optimization of the particle swarm algorithm;

[0076] Then, the position and velocity equations in the improved particle swarm algorithm are updated and the mutation strategy is introduced;

[0077] Finally, a gradient objective that reflects the spatial variation near the variable is introduced into the fitness function.

[0078] Considering that traditional PSO is significantly affected by the initial values ​​of the iterations, it is usually difficult to obtain the global optimal solution, and in some cases the iterations may even fail to converge. To improve the optimization and stability of traditional PSO, the improved algorithm considers increasing the number of initial value groups and selecting the optimal iteration result as the system's optimization output.

[0079] First, multiple groups of iterative initial values ​​are selected for PSO iterative optimization. The iterative process for any group is as follows:

[0080] In the D-dimensional space composed of particles of size N, the optimal position x of particle i (i = 1, 2, ..., N) in the space is constructed respectively. i (x i1 ,x i2 ,...,x iD ), speed v i (v i1 ,v i2 ,...,v iD ), individual optimal solution pb i (pb i1 ,pb i2 ,...,pb iD ) and the group optimal solution gb i (gb i1 ,gb i2 ,...,gb iD ) information vector, the update formulas for speed and position are as follows:

[0081]

[0082]

[0083] Where: t is the number of iterations, ω is the inertia weight, U1, U2 are random numbers in [0,1];

[0084] In the improved PSO algorithm, the inertia weight is used as an example to inherit the position and velocity information of the previous generation of particles during the optimization process. By adjusting the inertia weight, the goal of balancing convergence speed and optimization accuracy can be achieved. Considering that the emphasis on speed and accuracy varies at the beginning and end of the algorithm, the improved PSO changes the inertia weight based on the characteristics of the cosine function, and designs the inertia weight to show a nonlinear decrease. The calculation formula of the inertia weight coefficient is as follows:

[0085]

[0086] Where: k = 1, 2, ... K is the number of optimization iterations, ω min With ω maxare the minimum and maximum values ​​of the inertia coefficient during the optimization process; generally speaking, in order to obtain better optimization performance, the minimum and maximum values ​​are usually 0.4 and 0.9 respectively.

[0087] Furthermore, the position and velocity equations in the improved particle swarm optimization algorithm are updated as follows:

[0088]

[0089]

[0090] At the same time, the mutation strategy is introduced. In actual engineering applications, the particle swarm will experience "aggregation" during global search and local search. In order to prevent the algorithm from falling into a local optimal solution too early, the present invention introduces the mutation strategy into the traditional particle swarm algorithm. The calculation formula of the mutation operation is as follows:

[0091]

[0092] Where: δ is the variation factor, rand is a random number in [0,1], b i -a i is the search range of the i-th particle during the iteration process;

[0093] The mutation operation expands the search range of particles and can effectively solve the problem of falling into local optimality at the edge and local optimality during global optimization. However, performing mutation operation in each iteration may slow down the convergence speed. In order to improve the optimization ability of particles and better reflect the nonlinear process in the particle swarm search process, the mutation rate p is usually set as follows:

[0094]

[0095] Where: p max and p min are the maximum mutation rate and the minimum mutation rate respectively, k is the number of optimization iterations, and K is the maximum number of optimization iterations; as k increases, the mutation rate p shows an exponential decay trend.

[0096] The global optimal solution of the traditional particle swarm algorithm may not have good system stability. Figure 2As shown in the figure, taking one-dimensional space as an example, point A is the global optimal solution for the system, but the gradient near it is large. When the system is near point A, the target value fluctuates greatly. In a real system, disturbances may cause the system to crash and have poor stability. In contrast, for the local optimal solution at point B, the spatial variation near the solution is stable, balancing the system's efficiency and safety. Traditional PSO algorithms typically solve for a single-point global optimal solution, resulting in weak disturbance resistance and system safety issues. While stability may be enhanced for each local optimal solution, it is difficult to measure the stability of the solution within the spatial neighborhood.

[0097] To solve the above problems, the fitness function of the traditional PSO is improved. Finally, a gradient target that reflects the spatial changes near the variable is introduced into the fitness function. The objective function is as follows:

[0098]

[0099] in,

[0100]

[0101] Where: μ1, μ2 are the weight coefficients of functions f1, f2 respectively, f1 indicates the minimum total deviation of the expected prediction, which is expressed by the mean absolute percentage error of user load prediction, N is the number of sampling points for prediction, y i and are the actual value and the predicted value respectively; f2 represents the minimum variance of the function value in the space near the expected variable set, Ω is the space near the expected variable set, m is the number of input variable groups randomly selected in Ω, MAPE i is the output MAPE under the i-th group of input variables, MAPE j is the output MAPE under the jth group of input variables. The overall process of improving PSO is as follows Figure 3 shown.

[0102] In step S3, in order to better solve the problem that traditional recurrent neural networks are difficult to process time series data, the long short-term memory neural network introduces a gating mechanism. The main unit structure of LSTM is shown in the attached figure. Figure 4 As shown in the figure. t ,i t ,o t Represent the forget gate, input gate and output gate respectively, c t represents the neuron state, h tRepresents the hidden layer state variable, σ and tanh represent the Sigmoid function and the Tanh function, respectively, which act as gates. They represent the proportion of information transmitted forward by the previous load. The size of the activation function changes from 1 to 0 as the load information transmitted decreases. The formula for information transmission within LSTM neurons is as follows:

[0103] f t =σ(W f ·[h t-1 ,x t ]+b f ) (10)

[0104] f t =σ(W i ·[h t-1 ,x t ]+b i ) (11)

[0105] o t =σ(W o ·[h t-1 ,x t ]+b o ) (12)

[0106]

[0107]

[0108] h t =o t tanh(c t ) (15)

[0109] Neural network models contain network structure parameters and hyperparameters. The network structure parameters primarily consist of the weight matrix and the bias matrix. Common hyperparameters include the learning rate, number of training cycles, number of neurons, and output dimension. Hyperparameters are typically set before training begins and remain constant throughout the training process. Adjusting these hyperparameters to obtain an optimal set of hyperparameters can improve model effectiveness and performance. The learning rate represents the step size parameter in the gradient descent algorithm. A high learning rate can lead to solution difficulties, while a low learning rate can result in excessive learning time. The learning rate is typically set within the range [0.001, 0.01]. The number of training cycles refers to the number of times the learning rate is used to adjust the network weights. A high number of training cycles can waste resources, while a low number can result in suboptimal training results. Given that network hyperparameters significantly influence the accuracy of the results, and that traditional model parameter settings are often based on empirical experience, making it difficult to determine optimal parameters, this paper introduces an improved PSO algorithm to optimize the hyperparameters of the LSTM.

[0110] The three key hyperparameters of the LSTM network, namely the number of neurons L1, the learning rate ε and the number of training iterations k, are used as optimization variables for the improved particle algorithm;

[0111] By making the fitness function value of PSO reach the minimum, the model parameters of the LSTM network are obtained. The overall structure of the LSTM network model based on the improved PSO is shown in the attached figure. Figure 5 shown.

[0112] In step S3, the specific process of optimizing the LSTM model parameters using the improved particle algorithm is as follows:

[0113] 1) Preprocess user load data, remove erroneous data and normalize the data;

[0114] 2) Determine the optimization range of the hyperparameters L1, ε, and k to be optimized in the LSTM model;

[0115] 3) Initialize the parameters of the improved particle algorithm and substitute a set of initial values ​​of the particle swarm;

[0116] 4) According to the fitness function of the improved particle algorithm, in each iteration, the individual optimal position and the global optimal position are updated according to the fitness value, and the speed and position are updated according to equations (4)-(5) to find the LSTM network hyperparameters of the optimal model;

[0117] 5) Determine whether the maximum number of iterations has been reached; if so, pass the optimized parameters to the LSTM model and train it; if not, return to step 4);

[0118] 6) Determine whether all particle groups have been substituted; if so, compare the optimization results of all particle groups and select the best result as the output; if there are still particle groups that have not been substituted, return to step 3).

[0119] In step S4,

[0120] 1) For fully adjustable loads, also known as adjustable loads, historical data is usually combined with electricity price incentives to achieve full range adjustment of the load adjustable power within the entire time period. Common fully adjustable loads include air conditioners; semi-adjustable loads, also known as transferable loads, have power supply time periods that can be changed according to plan, as long as the total power supply within a fixed time period remains unchanged. Common semi-adjustable loads include washing machines, water heaters, etc.; non-adjustable loads are usually regarded as important loads, whose operating time is fixed and cannot be changed, and their power is regarded as an immutable fixed value. Common non-adjustable loads include loads at important transportation hubs and important communication hubs.

[0121] 2) Combining the load forecasting results of the LSTM network with the improved particle physics algorithm, the power of various adjustable loads is accumulated according to different load characteristics, and the overall adjustable capacity of the power system in each time period is finally obtained. The formula is as follows:

[0122]

[0123] Where: R represents the overall adjustable capacity of the system, η1, η2, and η3 are the adjustment coefficients of fully adjustable load, semi-adjustable load, and completely non-adjustable load, respectively. According to the specific type of load L1, the value of η1 ranges from 0.6 to 1.0. For load L2, when it is within the adjustable time range and the transferable load does not exceed its maximum allowable transfer amount, η2 takes the value of 1, and takes the value of 0 in the rest of the time period. For load L3, η3 is close to 0 in the entire time period, P L1 ,P L2 ,P L3 They are the predicted powers of the three types of loads at a certain moment.

[0124] User-adjustable capability mining system based on optimized neural networks, including:

[0125] Classification module, used to classify loads through LSTM network;

[0126] Improvement module, which is used to improve the particle swarm optimization algorithm by introducing multi-particle initial values ​​and multi-objective functions based on nonlinear variable weights and mutation operations;

[0127] The optimization module is used to combine the improved particle swarm algorithm with LSTM, optimize the LSTM hyperparameters using the improved particle swarm algorithm, and train the LSTM network;

[0128] The adjustment module is used to combine the results of load classification to give the adjustable range and adjustable time period of this type of load to obtain the overall adjustable capability.

[0129] In specific applications, the initialization parameter settings of the improved PSO-LSTM model are shown in Table 1. The number of hidden layer units to be optimized is in the range of [2, 20], the range of learning rate is [0.001, 0.01], and the range of the number of neurons is [1, 400].

[0130] Table 1 Parameter settings

[0131] parameter Initial value Population 20 PSO iteration number 200 Iteration Weight 0.8 Learning factor c1 2 Learning factor c2 2

[0132] Electricity load data for a specific month in a specific city was obtained. Three typical user load categories with labels (fully adjustable, semi-adjustable, and completely non-adjustable) were selected for analysis and potential mining. 100 days of data were selected for each of these three load categories and fed into a traditional LSTM network for training. Then, k groups of 50 days of load data with unknown labels were randomly fed into the network for classification, obtaining the classification labels for these k groups of load data.

[0133] K sets of load data are fed into the PSO-LSTM network for training and prediction. For each set of load data, p sets of iterative initial particle swarms are randomly generated within the population. Each set of initial particle swarms is fed into the improved PSO for optimization.

[0134] The fitness function of the algorithm is set to

[0135]

[0136] in

[0137]

[0138] Where: μ1, μ2 are the weight coefficients of functions f1, f2 respectively, N is the number of predicted sampling points, y i and are the actual value and the predicted value respectively; Ω is the space near the expected variable set, m is the number of input variable groups randomly selected within Ω, MAPE i is the output MAPE under the i-th set of input variables.

[0139] After adopting nonlinear inertia weight, the position and velocity equations of the algorithm are

[0140]

[0141]

[0142] Where: t is the number of iterations, ω is the inertia weight, U1, U2 are random numbers in [0,1], k=1,2,..K is the number of optimization iterations, ω min With ω max are the minimum and maximum values ​​of the inertia coefficient during the optimization process.

[0143] After introducing the mutation operation,

[0144]

[0145] Where: δ is the variation factor, rand is a random number in [0,1], b i -a i is the search range of the i-th particle during the iteration process.

[0146] The output of the improved PSO is used as the three hyperparameters of LSTM, namely the number of neurons L1, the learning rate ε and the number of training iterations k. The neuron information transmission formula of the LSTM network is as follows:

[0147] f t =σ(W f ·[h t-1 ,x t ]+b f )

[0148] f t =σ(W i ·[h t-1 ,x t ]+b i )

[0149] o t =σ(W o ·[h t-1 ,x t ]+b o )

[0150]

[0151]

[0152] h t =o t tanh(c t )

[0153] Where: f t ,i t ,o t Represent the forget gate, input gate and output gate respectively, c t represents the neuron state, h t Represents the hidden layer state variable, σ and tanh represent the Sigmoid function and Tanh function respectively,

[0154] Each set of load data passes through the PSO-LSTM network, generating p fitness function results. The smallest of these p outputs is selected as the optimal output. This optimal output is then used to train the LSTM network with the optimal LSTM hyperparameters to obtain the predicted curve for that set of load data.

[0155] Repeat the above steps to obtain the classification and prediction curves of k groups of load data. Then, for group k1 fully adjustable loads, group k2 semi-adjustable loads, and group k3 non-adjustable loads, the overall load regulation capacity of the negative system at time T can be calculated as follows:

[0156]

[0157] Where: η1, η2, η3 are the adjustment coefficients of three types of loads, P L1 (α,T) is the predicted power of the first type of load at time T, is the predicted power of the second type of load at time T, is the predicted power of the third type of load at time T.

[0158] Assume that the three identified loads A, B, and C belong to these three types of loads respectively, and their respective load prediction curves and total load curves are as follows: Figure 6 As shown, the adjustment coefficients are η1 = 0.8, η2 = 1, and η3 = 0, and it is assumed that the transferable time of load B is 18:00-24:00 and 0:00-8:00.

[0159] Assuming the user's total load power is limited to 15kW throughout the day, the figure shows that there is a risk of exceeding the limit between 19:00 and 21:00. The load needs to be adjusted during this period. Taking the total load adjustability at T = 20:00 as an example, the calculation mainly consists of load A and transferable load B. The adjustability calculation formula can be expressed as follows:

[0160]

[0161] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A method for mining user adjustable capabilities based on an optimized neural network, characterized in that: The following steps are involved: S1. Load classification through LSTM network; In step S1, users are divided into three categories: fully adjustable load, semi-adjustable load, and completely non-adjustable load through the LSTM network; S2. Based on nonlinear variable weight and mutation operation, multi-particle initial value and multi-objective function are introduced to improve the particle swarm optimization algorithm; S3. Combine the improved particle swarm algorithm with LSTM, use the improved particle swarm algorithm to optimize the LSTM hyperparameters, and train the LSTM network; S4. Based on the load classification results, the adjustable range and adjustable time period of the load are given to obtain the overall adjustable capacity; In step S4, 1) Fully adjustable load: The load can be adjusted within the full range of adjustable power in all time periods; Semi-adjustable loads: their power supply time period can be changed according to the plan, as long as the total power supply within a fixed time period remains unchanged; Completely non-adjustable loads, whose operating time is fixed and cannot be changed, and whose power is regarded as an immutable fixed value; 2) Combining the load forecasting results of the LSTM network with the improved particle physics algorithm, the power of various adjustable loads is accumulated according to different load characteristics, and the overall adjustable capacity of the power system in each time period is finally obtained. The formula is as follows: Where: R represents the overall adjustable capacity of the system, η1, η2, η3 are the adjustment coefficients of fully adjustable load, semi-adjustable load, and completely non-adjustable load respectively, P L1 ,P L2 ,P L3 They are the predicted powers of the three types of loads at a certain moment.

2. The user adjustable capability mining method based on optimized neural network according to claim 1, characterized in that: Step S2 includes: First, multiple groups of iterative initial values ​​are selected to perform iterative optimization of the particle swarm algorithm; Then, the position and velocity equations in the improved particle swarm algorithm are updated and the mutation strategy is introduced; Finally, a gradient objective that reflects the spatial variation near the variable is introduced into the fitness function.

3. The user adjustable capability mining method based on optimized neural network according to claim 2, characterized in that: Select multiple groups of iterative initial values ​​to perform particle swarm algorithm iterative optimization. The iterative process for any group is as follows: In the D-dimensional space composed of particles of size N, the optimal position x of particle i (i = 1, 2, ..., N) in the space is constructed respectively. i (x i1 ,x i2 ,...,x iD ), speed v i (v i1 ,v i2 ,...,v iD ), individual optimal solution pb i (pb i1 ,pb i2 ,...,pb iD ) and the group optimal solution gb i (gb i1 ,gb i2 ,...,gb iD ) information vector, the update formulas for speed and position are as follows: Where: t is the number of iterations, ω is the inertia weight, U1, U2 are random numbers in [0,1]; Among them, the design inertia weight shows a nonlinear decrease, and the calculation formula of the inertia weight coefficient is as follows: Where: k = 1, 2, ... K is the number of optimization iterations, ω min With ω max are the minimum and maximum values ​​of the inertia coefficient during the optimization process.

4. The user adjustable capability mining method based on optimized neural network according to claim 3 is characterized by: The position and velocity equation updates in the improved particle swarm optimization algorithm are expressed as follows: At the same time, the mutation strategy is introduced, and the calculation formula of the mutation operation is as follows: Where: δ is the variation factor, rand is a random number in [0,1], b i -a i is the search range of the i-th particle during the iteration process; The mutation rate p is set as follows: Where: p max and p min are the maximum mutation rate and the minimum mutation rate respectively, k is the number of optimization iterations, and K is the maximum number of optimization iterations.

5. The user adjustable capability mining method based on optimized neural network according to claim 4 is characterized in that: A gradient objective that reflects spatial changes near the variable is introduced into the fitness function. The objective function is as follows: in, Where: μ1, μ2 are the weight coefficients of functions f1, f2 respectively, f1 indicates the minimum total deviation of the expected prediction, which is expressed by the mean absolute percentage error of user load prediction, M is the number of sampling points for prediction, y i and are the actual value and the predicted value respectively; f2 represents the minimum variance of the function value in the space near the expected variable set, Ω is the space near the expected variable set, m is the number of input variable groups randomly selected in Ω, MAPE i is the output MAPE under the i-th group of input variables, MAPE j is the output MAPE under the jth set of input variables.

6. The user adjustable capability mining method based on optimized neural network according to claim 4, characterized in that: In step S3, The three key hyperparameters of the LSTM network, namely the number of neurons L1, the learning rate ε and the number of training iterations k, are used as optimization variables for the improved particle algorithm; By minimizing the fitness function value, the optimized model parameters of the LSTM network are obtained.

7. The method for mining user adjustable capabilities based on an optimized neural network according to claim 6, characterized in that: In step S3, the specific process of optimizing the LSTM model parameters using the improved particle algorithm is as follows: 3-1) preprocessing user load data, removing erroneous data and normalizing the data; 3-2) Determine the optimization range of the hyperparameters L1, ε, and k to be optimized in the LSTM model; 3-3) Initialize the parameters of the improved particle algorithm and substitute a set of initial values ​​of the particle swarm; 3-4) According to the fitness function of the improved particle algorithm, in each iteration, the individual optimal position and the global optimal position are updated according to the fitness value, and the speed and position are updated according to formulas (4)-(5) to find the LSTM network hyperparameters of the optimal model; 3-5) Determine whether the maximum number of iterations has been reached; If the result is achieved, the optimized parameters are passed to the LSTM model for training; If the requirements are not met, return to step 3-4); 3-6) Determine whether all particle groups have been substituted; if so, compare the optimization results of all particle groups and select the best result as output; if there are still particle groups that have not been substituted, return to step 3-3).

8. A user adjustable capability mining system based on an optimized neural network, characterized in that: include: The classification module is used to classify loads through the LSTM network. Users are divided into three categories: fully adjustable loads, semi-adjustable loads, and completely non-adjustable loads through the LSTM network. Improvement module, which is used to improve the particle swarm optimization algorithm by introducing multi-particle initial values ​​and multi-objective functions based on nonlinear variable weights and mutation operations; The optimization module is used to combine the improved particle swarm algorithm with LSTM, optimize the LSTM hyperparameters using the improved particle swarm algorithm, and train the LSTM network; The adjustment module is used to determine the adjustable range and adjustable time period of the load according to the load classification results to obtain the overall adjustable capacity; The adjustment module includes: 1) Fully adjustable load: The load can be adjusted within the full range of adjustable power in all time periods; Semi-adjustable loads: their power supply time period can be changed according to the plan, as long as the total power supply within a fixed time period remains unchanged; Completely non-adjustable loads, whose operating time is fixed and cannot be changed, and whose power is regarded as an immutable fixed value; 2) Combining the load forecasting results of the LSTM network with the improved particle physics algorithm, the power of various adjustable loads is accumulated according to different load characteristics, and the overall adjustable capacity of the power system in each time period is finally obtained. The formula is as follows: Where: R represents the overall adjustable capacity of the system, η1, η2, η3 are the adjustment coefficients of fully adjustable load, semi-adjustable load, and completely non-adjustable load respectively, P L1 ,P L2 ,P L3 They are the predicted powers of the three types of loads at a certain moment.

Citation Information

Patent Citations

  • Metro traction energy consumption prediction method for optimizing LSTM based on particle swarmalgorithm

    CN113326960A

  • Short-term power load prediction method and device based on hyper-parameter optimization

    CN114066029A

  • Traffic flow prediction method and device for optimizing LSTM (Long Short Term Memory) based on improved PSO (Particle Swarm Optimization) algorithm

    CN114970815A