Supervision reinforcement learning method and device for operation scheduling of controlled system
The supervised reinforcement learning method is used to optimize sampling and action screening in complex controlled systems, combined with supervisor feedback, to solve the problems of low learning efficiency and poor action accuracy, and achieve efficient operation scheduling and decision-making.
Patent Information
- Application Number
- CN202410804234.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-20
- Publication Date
- 2024-09-20
AI Technical Summary
Complex controlled systems have problems in operation scheduling such as low learning efficiency, poor optimal action accuracy, and the supervisor's experience is not effectively utilized, especially in new energy power systems with large and complex state spaces and action spaces.
Adopt supervised reinforcement learning method, optimize the number of samples and action types through simulation result sampling and data distribution algorithms, screen out non-observed optimal actions and observed optimal actions of high importance, and combine supervisor feedback to determine the optimal action to improve learning Efficiency and accuracy of movement.
It improves the efficiency and performance of reinforcement learning, improves the accuracy of determining optimal actions, reduces learning time and data usage, and significantly improves the efficiency of online decision-making.
Smart Images

Figure CN118674068A
Abstract
Description
Technical Field
[0001] The present invention relates to the field of reinforcement learning, and in particular to a supervised reinforcement learning method and device for operation scheduling of a controlled system. Background Art
[0003] For complex controlled systems (such as smart grids), their economic operation has important engineering requirements. Reinforcement learning has the potential to learn from data and gradually improve strategy performance, so it has received great attention in engineering applications. Take the new energy power system as an example. The new energy power system contains a large number of new energy (such as wind power, solar energy, fuel cells, etc.) power generation equipment, energy storage equipment and power equipment (such as building electricity, electric vehicle charging pile electricity), etc. Its operation strategy needs to decide what action to take after the current system state is given.
[0004] In fact, the above-mentioned system has the characteristics of large state space and action space. The state space includes, for example, the states of various power generation equipment, energy storage equipment, and power consumption equipment, and the action space includes, for example, the charging or discharging power of energy storage equipment, the charging power of electric vehicle charging piles, and the output of thermal power generation units. For the above-mentioned complex controlled system, there are mainly two ways to determine the operation scheduling strategy: one is to directly use the general reinforcement learning method, which requires a large amount of training data to obtain a better operation strategy, so there are problems of low learning efficiency and long time consumption. The other method is to let the system run for a period of time, and then let experienced engineers evaluate the advantages and disadvantages of two actions under the same state, and determine the scheduling strategy based on the evaluation results of the engineers. However, asking engineers to give the optimal action mode for each state is too time-consuming and impractical. In addition, this method does not directly apply the experience of engineers to the optimization of the operation strategy of the controlled system, and there is a problem that the experience of engineers is not effectively utilized. Summary of the invention
[0006] The present invention is used to solve the problems in the prior art that the feedback information of the supervisor is not combined with the environmental interaction data during the operation scheduling of the complex controlled system, resulting in low learning efficiency, poor optimal action accuracy and waste of supervisor experience.
[0007] In order to solve the above technical problems, the first aspect of the present invention provides a supervised reinforcement learning method for operation scheduling of a controlled system, comprising:
[0008] Sampling the simulation results of each state-action pair of the controlled system according to a preset sampling number, and determining the type of each action under each state, the Q factor of each state-action pair, the Q factor sample variance, and the total amount of consumed samples according to the sampled simulation results;
[0009] The importance of each non-observed optimal action in each state is calculated based on the Q factor of each non-observed optimal action and the Q factor of the observed optimal action in each state, and the observed optimal action and importance are ranked first. M The non-observed optimal actions are sent to the supervisor to determine the optimal action;
[0010] Adjust the total amount of consumed samples, and use the sampling data allocation algorithm to analyze the Q factor sample variance and the total amount of consumed samples of each state-action pair to obtain the target sample size of each action under each state. The sampling data allocation algorithm includes the criteria for determining the number of samples for each type of action, which is used to gradually maximize the probability of correctly selecting the optimal action for observation;
[0011] Determine the number of additional samples for each action based on the target sample size of each action and the sample size consumed by each action;
[0012] Perform supplementary sampling according to the number of supplementary sampling of each action, and use the simulation results of supplementary sampling to re-determine the action type steps and recalculate the importance of each non-observed optimal action in each state and the steps of feedback to the supervisor;
[0013] Determine whether the total amount of consumed samples is less than or equal to the preset total sampling amount. If so, re-execute the steps of adjusting the total amount of consumed samples and the steps thereafter. Otherwise, output the optimal action observed in each state.
[0014] As a further embodiment of the present invention, the sampling data allocation algorithm determination process includes:
[0015] According to the equipment information, load information, system status, control action, and optimization target information of the controlled system, establish the objective function of the control strategy, action sampling quantity constraints, and consultation quantity constraints;
[0016] Transforming the objective function of the control strategy to obtain the action Q factor of reinforcement learning;
[0017] According to the action Q factor, an index function for calculating the importance of the non-observed optimal action and an objective function for approximating the probability function of selecting the observed optimal action are constructed;
[0018] According to the objective function, the index function, the action sampling quantity constraint condition and the consultation quantity constraint condition of the approximate observed optimal action selection probability function, the criteria of the sampling data allocation algorithm are determined.
[0019] As a further embodiment of the present invention, the objective function of the approximate observation of the optimal action selection probability function, the action sampling quantity constraint condition and the consultation quantity constraint condition are expressed by the following formula:
[0020] Max APCS;
[0021]
[0022]
[0023] ∑ s,a,a' M(s,a,a')=M;
[0024] Where APCS represents the approximate observed optimal action selection probability function, s represents the state; a represents the unobserved optimal action, b(s) represents the observed optimal action, Q(s,b(s)) represents the Q factor of the observed optimal action b(s) under state s, Q(s,a) represents the Q factor of the unobserved optimal action a under state s, p(s) represents the steady-state probability distribution of state s, e represents a constant, and N sa represents the number of samples of the Q factor corresponding to state s and action a, N represents the total number of samples, M(s,a,a') represents the number of times the supervisor is consulted about actions a and a' under state s, and M represents the total amount of consultations with the supervisor.
[0025] As a further embodiment of the present invention, the importance of each non-observed optimal action in each state is calculated according to the Q factor of each non-observed optimal action in each state and the Q factor of the observed optimal action, including:
[0026] The importance of each non-observable optimal action in each state is calculated using the following formula:
[0027] I(s,α)=1-Pr{Q(s,b(s))≤Q(s,α)};
[0028] Among them, I(s,a) represents the importance of the non-observed optimal action a in state s; Q(s,b(s)) represents the Q factor of the observed optimal action b in state s; Q(s,a) represents the Q factor of the non-observed optimal action a in state s.
[0029] As a further embodiment of the present invention, the sampling data allocation algorithm is used to indicate:
[0030] The larger the noise-to-signal ratio of the non-observed optimal action in each state s, the larger the number of samples of the non-observed optimal action. The noise in the noise-to-signal ratio refers to the sample standard deviation of the Q factor of the non-observed optimal action in each state s, and the information in the noise-to-signal ratio refers to the performance difference between the Q factor of the observed optimal action in each state s and the Q factor of the non-observed optimal action in state s.
[0031] The number of samples of the best observed action in each state should be proportional to the product of the steady-state probability of each state and the sample standard deviation of the Q factor of the best observed action in each state;
[0032] For observed optimal actions and non-observed optimal actions that have not been confirmed by the supervisor, the number of samples of observed optimal actions under each state s should be greater than the number of samples of other non-observed optimal actions.
[0033] As a further embodiment of the present invention, the sampling data allocation algorithm includes the following criteria:
[0034] Criterion 1: For unobserved optimal actions i and j,
[0035] Among them, N si represents the number of samples of action i in state s, N sj represents the number of samples of action j in state s, s si represents the sample standard deviation of the Q factor of action i in state s, s sj represents the sample standard deviation of the Q factor of action j in state s, d si The Q factor representing the observed optimal action in state s and the performance difference between action i in state s, d sj The Q factor representing the observed optimal action for state s and the performance difference of action j in state s;
[0036] Criterion 2: For the best observed action b in state i and the best observed action b in state j,
[0037]
[0038] Among them, N ib N represents the number of samples of the best observed action b(i) in state i. jb represents the number of samples of the observed optimal action b(j) under state j, p(i) represents the steady-state probability distribution of state i, p(j) represents the steady-state probability distribution of state j, s ib represents the sample standard deviation of the Q factor of the observed optimal action b(i) in state i, s jb represents the sample standard deviation of the Q factor of the observed optimal action b(j) in state j;
[0039] Criterion 3: For the observation in state s, the optimal action b is,
[0040] Among them, N sb represents the number of samples of action b(s) in state s, s sb represents the sample standard deviation of the Q factor of action b(s) in state s, N sa represents the number of samples of non-observed optimal action a under state s, s sa represents the sample standard deviation of the Q factor of the non-observed optimal action a in state s, and M(s,b(s),a) represents the number of times the supervisor is consulted about actions b(s) and a in state s.
[0041] As a further embodiment of the present invention, the sample variance of the Q factor of each state-action pair and the total amount of consumed samples are analyzed using a sampling data allocation algorithm to obtain the target sample size of each action in each state, including:
[0042] The Q-factor sample variance of each state-action pair is analyzed according to the sampling data allocation algorithm to obtain the target sample quantity ratio of each action in each state;
[0043] The number of samples that should be obtained for each action in each state is obtained by multiplying the target sample number ratio of each action in each state by the total number of consumed samples;
[0044] The larger of the number of samples that should be obtained for each action in each state and the number of samples actually used for each action in each state is selected as the target number of samples for each action in each state.
[0045] A second aspect of the present invention provides a supervised reinforcement learning device for operation scheduling of a controlled system, comprising:
[0046] A simulation calculation unit is used to sample the simulation results of each state-action pair of the controlled system according to a preset sampling number, and determine the type of each action under each state, the Q factor of each state-action pair, the Q factor sample variance, and the total amount of consumed samples according to the sampled simulation results;
[0047] The supervision unit is used to calculate the importance of each non-observed optimal action in each state according to the Q factor of each non-observed optimal action and the Q factor of the observed optimal action in each state, and rank the observed optimal action and the importance first. M The non-observed optimal actions are sent to the supervisor to determine the optimal action;
[0048] An allocation calculation unit is used to adjust the total amount of consumed samples, and to analyze the Q factor sample variance and the total amount of consumed samples of each state-action pair using a sampling data allocation algorithm to obtain the target sample size of each action under each state. The sampling data allocation algorithm includes a criterion for determining the number of samples of each type of action, which is used to asymptotically maximize the probability of correctly selecting the optimal action for observation;
[0049] A supplementary sampling amount determination unit, used to determine the number of supplementary sampling for each action according to the target sample amount of each action and the consumed sample amount of each action;
[0050] A supplementary sampling unit is used to perform supplementary sampling according to the number of supplementary sampling of each action, and the simulation calculation unit uses the simulation result of the supplementary sampling to re-execute the step of determining the action type and the supervision unit re-calculates the importance of each non-observed optimal action under each state and feeds back to the supervisor;
[0051] The analysis unit is used to determine whether the total amount of consumed samples is less than or equal to the preset total sampling amount. If so, the allocation calculation unit re-executes the adjustment of the total amount of consumed samples and the subsequent steps. Otherwise, the optimal action observed in each state is output.
[0052] A third aspect of the present invention provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method described in any of the foregoing embodiments when executing the computer program.
[0053] A fourth aspect of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor of a computer device, the method described in any of the foregoing embodiments is implemented.
[0054] A fifth aspect of the present invention provides a computer program product, which includes a computer program, and when the computer program is executed by a processor of a computer device, the method described in any of the above embodiments is implemented.
[0055] The supervised reinforcement learning method and device for the operation scheduling of the controlled system provided by the present invention are applicable to complex controlled systems including multiple states and multiple actions, such as smart grids, new energy power systems, etc., and can achieve the following technical effects:
[0056] (1) By optimizing the limited opportunities for communication with the supervisor and the limited opportunities for interaction with the environment, the supervision of the supervisor is integrated with the sampled data, which can improve the efficiency and performance of reinforcement learning.
[0057] (2) By screening out the non-observed optimal actions and observed optimal actions with high importance and sending them to the supervisor so that the supervisor can determine the optimal action, the accuracy of determining the optimal action can be improved.
[0058] (3) By using the sampling quantity to determine the criterion, the probability of correctly selecting the optimal action can be gradually maximized, and the simulation resources can be concentrated on the important actions that really need to be distinguished, so as to achieve effective sampling, reduce learning time, and reduce time costs, so that the observation results of each action are more and more accurate, and finally the optimal action is obtained. At the same time, by controlling the sampling quantity, the data efficiency of online reinforcement learning in the operation and scheduling process of the controlled system can be improved, the time required for online decision-making can be significantly improved, and the amount of data used can be reduced.
[0059] In order to make the above and other purposes, features and advantages of this article more obvious and easy to understand, the following specifically cites preferred embodiments and describes them in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] In order to more clearly illustrate the technical solutions in the embodiments of this article or the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of this article. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0062] Figure 1 A flow chart showing a process of determining a sampling data allocation algorithm according to an embodiment of the present invention is shown;
[0063] Figure 2 A flow chart of a supervised reinforcement learning method for operation scheduling of a controlled system according to an embodiment of the present invention is shown;
[0064] Figure 3 A flowchart showing a process of determining the sampling amount of each action target in each state of an embodiment of the present invention is shown;
[0065] Figure 4 A structural diagram of a supervised reinforcement learning device for operation scheduling of a controlled system according to an embodiment of the present invention is shown;
[0066] Figure 5 A structural diagram of a computer device according to an embodiment of the present invention is shown;
[0067] Figure 6 A flow chart of supervised reinforcement learning programming for operation scheduling of a controlled system according to an embodiment of the present invention is shown.
[0069] Description of the accompanying symbols:
[0070] 401, simulation calculation unit;
[0071] 402. Supervisory unit;
[0072] 403. Allocate computing units;
[0073] 404. Supplementary sampling amount determination unit;
[0074] 405. Supplementary sampling unit;
[0075] 406. Analysis unit;
[0076] 502. Computer equipment;
[0077] 504, processor;
[0078] 506. Memory;
[0079] 508, driving mechanism;
[0080] 510, input / output module;
[0081] 512. Input devices;
[0082] 514. Output device;
[0083] 516. Presentation equipment;
[0084] 518. Graphical user interface;
[0085] 520, network interface;
[0086] 522, communication link;
[0087] 524. Communication bus. DETAILED DESCRIPTION
[0089] The following will be combined with the drawings in the embodiments of this article to clearly and completely describe the technical solutions in the embodiments of this article. Obviously, the described embodiments are only part of the embodiments of this article, not all of the embodiments. Based on the embodiments of this article, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this article.
[0090] It should be noted that the terms "first", "second", etc. in the specification and claims of this article and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of this article described here can be implemented in an order other than those illustrated or described here. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, device, product or equipment that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or equipment.
[0091] This specification provides method operation steps as described in the embodiments or flow charts, but more or fewer operation steps may be included based on routine or non-creative work. The order of steps listed in the embodiments is only one way of executing the order of many steps and does not represent the only execution order. When the system or device product is executed in practice, it can be executed in the order of the method shown in the embodiments or the drawings or in parallel.
[0092] It should be noted that the data involved in the present invention (including but not limited to data used for analysis, stored data, displayed data, etc.) are all information and data authorized by the user or fully authorized by all parties, and the acquisition, transmission, storage, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions.
[0093] It should be noted that in the embodiments of the present invention, certain software, components, models and other existing solutions in the industry may be mentioned, which should be regarded as exemplary. Their purpose is only to illustrate the feasibility of implementing the technical solution of the present invention, but it does not mean that the applicant has or will necessarily use the solution.
[0094] The controlled system described in the present invention is a system with multiple states and multiple actions, such as a new energy power system, and the corresponding state space includes, for example, the states of various power generation equipment, energy storage equipment, and power consumption equipment, and the corresponding action space includes, for example, the charging or discharging power of energy storage equipment, the charging power of electric vehicle charging piles, the output of thermal power generators, etc. In specific implementation, it can also be other multi-state and multi-action systems, and the present invention does not specifically limit the controlled system.
[0095] Before implementing the supervised reinforcement learning method for the operation scheduling of the controlled system described in the present invention, a sampling data allocation algorithm needs to be established to indicate:
[0096] (1) The larger the noise-to-signal ratio of the non-observable optimal action in each state s, the larger the number of samples of the non-observable optimal action.
[0097] The noise in the noise-to-signal ratio refers to the sample standard deviation of the Q factor of the non-observed optimal action under each state s, and the information in the noise-to-signal ratio refers to the performance difference between the Q factor of the observed optimal action under each state s and the Q factor of the non-observed optimal action under state s.
[0098] (2) The number of samples of the best observed action in each state should be proportional to the product of the steady-state probability of each state and the sample standard deviation of the Q factor of the best observed action in each state.
[0099] (3) For observed optimal actions and non-observed optimal actions that have not been confirmed by the supervisor, the number of samples of observed optimal actions in each state s should be greater than the number of samples of other non-observed optimal actions.
[0100] Specifically, Figure 1 As shown, the sampling data allocation algorithm determination process includes:
[0101] Step 101, based on the equipment information, load information, system status, control action, and optimization target information of the controlled system, establish the objective function of the control strategy, action sampling quantity constraint conditions, and consultation quantity constraint conditions.
[0102] Step 102: convert the objective function of the control strategy to obtain the action Q factor of reinforcement learning.
[0103] Step 103: construct an index function for calculating the importance of the unobserved optimal action and an objective function for approximating the observed optimal action selection probability function according to the action Q factor.
[0104] Step 104, determining the criteria of the sampling data allocation algorithm according to the objective function, the index function, the action sampling quantity constraint condition and the consultation quantity constraint condition of the approximate observed optimal action selection probability function.
[0105] Specifically, the device information, load information, system status, control action, and optimization target information in step 101 may be determined according to the specific conditions of the controlled system, and the present invention does not limit the specific parameters included therein. An objective function is established according to the device information, load information, system status, control action, and optimization target.
[0106] Taking the controlled system as a new energy power system as an example, the new energy power system has power generation equipment (such as solar energy, wind energy, fuel cells, thermal power generators, etc.), energy storage equipment, and power equipment (such as building electricity, electric vehicle charging station electricity, etc.). It is necessary to determine the action based on the current state of the new energy power system (such as the charging or discharging power of the energy storage equipment, the charging power of the electric vehicle, etc.). There are experienced engineers in the new energy power system who can accurately feedback which of the two actions is better under a given state. It is also possible to interact with the environment and conduct reinforcement learning driven by data.
[0107] In some implementations, the control target of the controlled system is expressed using the following expression:
[0108]
[0109] Among them, s t represents the system state at time t; d represents the strategy, which needs to be based on the state s t Determine the action; c represents the cost function, T represents the number of stages before the simulation; T represents the total simulation time; J(d) represents the average operating cost of strategy d.
[0110] Furthermore, the above step 102 can obtain the action Q factor expressed by the following formula according to formula (1):
[0111] Q d (s,a)=c(s,a)+ΣP(s'|s,a)Q d (s',d(s'))-J(d) (2 )
[0112] Among them, Q d (s,a) represents the Q factor of action a in state s; d represents the given strategy; for simplicity, the above Q d(s,a) can also be expressed as Q(s,a); c represents the target object value corresponding to state s and action a; the second term on the right side of the above formula represents the future target object value; s' represents the future state; P(s'|s,a) represents the probability of taking action a from state s to the next state s'; Q d (s',d(s')) represents the Q factor under state s' and its strategy d'.
[0113] The Q factor expressed by formula (2) can be obtained by taking samples We get, where k = 1, 2, ..., N sa , N sa Represents the number of samples of (state, action) pairs, and uses the sample mean to represent Q(s,a), as shown in the following formula:
[0114]
[0115] Furthermore, according to formula (3), the greedy strategy based on this estimate can be obtained, namely:
[0116]
[0117] For any state in the state space and any action in the control space, when N sa →¥, Converges to Q(s,a), Converges to:
[0118]
[0119] When all (s, a) are visited infinitely many times, we can get d b (s) converges to the optimal strategy d * (s)°argmin d∈D Q(s,a), where D represents the set of all strategies. Given the total number of samples N, different allocations may lead to different strategies. In addition to samples, we also seek guidance from a supervisor. When given a state s and two actions i and j, the supervisor will tell us the true order of Q(s,i) and Q(s,j), or Q(s,i) £Q(s,j), or vice versa. This kind of guidance provides much more accurate information than samples and is therefore more valuable. Compared to the total sample size N, our requests to the supervisor are limited to a much smaller M, M = |S|(A|-1), which means that we do not have enough budget to determine all the optimal actions simply by interacting with the supervisor. Combining the samples and the guidance of the supervisor, we hope to minimize the control objective of the strategy, so we can get the objective function of the control strategy of the controlled system as follows:
[0120]
[0121] in, represents the objective function of the control strategy, for example, the average cost of the strategy; N sa represents the number of samples of the Q factor corresponding to the state s and action a, and N represents the total number of samples;
[0122] M(s,a,a') represents the number of times the supervisor is consulted for actions a and a' in state s. In order to improve efficiency, the supervisor is generally consulted at most once, that is, M(s,a,a')∈{0,1}, and M represents the total amount of consultations with the supervisor. Among them, N and M are preset quantities and can be set by the user according to actual needs. For convenience, the problem represented by formula (6) can be recorded as P1.
[0123] In detail, the supervisor described in the present invention can be an engineer who is familiar with the control of the controlled system, or can be an intelligent algorithm for evaluating the superiority of two actions, that is, making a judgment on which of the two actions is better. The present invention does not limit the specific supervisor, and the supervisor can make an accurate judgment on the superiority of the two actions.
[0124] When step 103 is implemented, the problem P1 represented by formula (6) can be refined into a more specific optimization problem form for the problem structure of online reinforcement learning, which is recorded as problem P2, as shown in the following formula:
[0125]
[0126] Among them, the final strategy is the strategy corresponding to the maximum probability of the target object (such as average operating cost) within the given ε; the action sampling quantity constraint and the consultation quantity constraint are the same as the previous problem, representing the total sampling quantity and the total consultation quantity respectively.
[0127] Compared with problem P1 represented by formula (6), problem P2 represented by formula (7) has an objective function that is easier to calculate, and the difficulty of solving the problem can be adjusted by adjusting the value of the constant ε, which is more practical.
[0128] Notice:
[0129]
[0130] Among them, the first term ∩ s ∩ a≠b(s) (Q(s, b(s))≤Q(s, a)) indicates that the observed optimal action is the true optimal action, and the second term ∑ s π(s)Q(s, b(s))≤∩ means that the authenticity of the observed optimal action is no greater than a given constant ε, which is determined by the given basic strategy.
[0131] Based on the Bonferroni inequality, we can get the following inequality for the right side of formula (8):
[0132]
[0133] Where s represents the state, a represents the unobserved optimal action, b(s) represents the observed optimal action, Q(s, b(s)) represents the Q factor of the observed optimal action b(s) under state s, Q(s, a) represents the Q factor of the unobserved optimal action a under state s, π(s) represents the steady-state probability distribution of state s, ε represents a constant, and N s a represents the number of samples of the Q factor corresponding to state s and action a, N represents the total number of samples, M(s, a, a′) represents the number of times the supervisor is consulted about actions a and a′ under state s, and M represents the total amount of consultations with the supervisor. The right side of formula (9) is called the approximate observed optimal action selection probability function, namely APCS, Approximate Probability of Correct Selection,
[0134] Furthermore, the problem P2 expressed by formula (7) can be expressed as the problem P3 expressed by the following formula:
[0135]
[0136] Next, optimize the supervisor's guidance, which tells the true order between Q(s, a) and Q(s, a′), where a and a′ are any two actions. Of course, we can choose any pair of actions to send to the supervisor for guidance. However, some requests provide more information than others and improve APCS better. For example, when a=b(s) (b(s) is the best action observed in state s), and a' is the second best action observed in state s, sending a request to the supervisor can directly tell which action between a and a' is better, thereby reducing 1-Pr{Q(s, b(s)≤Q(s, a)} to 0. On the other hand, when a, a′≠b(s), the request result will not affect APCS. Therefore, we need to choose certain actions to request guidance from the supervisor. In addition, since we look at it from a Bayesian perspective, the sample average are given and fixed. Their true values are random variables that follow the posterior distribution. Then, the supervisor’s guidance can directly determine the order of the random true values Q(s, a) and Q(s, a′) with and Then, we no longer need to consider the possibility that their true order is something else, and this term can be removed in APCS, so we choose a pair of actions that maximizes APCS.
[0137] Based on the above analysis, we can get the importance formula of the non-observed optimal action a under state s expressed as follows:
[0138] I(s,a)≡1-Pr{Q(s,b(s))≤Q(s,a)} (12)
[0139] Furthermore, combined with formula (12), the APCS of formula (10) can be expressed as:
[0140]
[0141] In the above step 104, according to the objective function, the index function, the action sampling quantity constraint condition and the consultation quantity constraint condition of the approximate observation optimal action selection probability function, the criteria of the sampling data allocation algorithm are determined as follows:
[0142] Criterion 1: For unobserved optimal actions i and j,
[0143] Among them, N si represents the number of samples of action i in state s, N sj represents the number of samples of action j in state s, σ si represents the sample standard deviation of the Q factor of action i in state s, σ sj represents the sample standard deviation of the Q factor of action j in state s, δ si The Q factor representing the observed optimal action at state s and the performance difference between action i at state s, δ sj The Q factor representing the observed optimal action for state s and the performance difference of action j in state s;
[0144] Criterion 2: For the best observed action b in state i and the best observed action b in state j,
[0145]
[0146] Among them, N ib N represents the number of samples of the best observed action b(i) in state i. jb represents the number of samples of the observed optimal action b(j) under state j, π(i) represents the steady-state probability distribution of state i, π(j) represents the steady-state probability distribution of state j, σ ib represents the sample standard deviation of the Q factor of the observed optimal action b(i) in state i, σ jb represents the sample standard deviation of the Q factor of the observed optimal action b(j) in state j;
[0147] Criterion 3: For the observation in state s, the optimal action b is,
[0148] Among them, N sb represents the number of samples of action b(s) in state s, σ sb represents the sample standard deviation of the Q factor of action b(s) in state s, N sa represents the number of samples of non-observed optimal action a under state s, s sa represents the sample standard deviation of the Q factor of the non-observed optimal action a in state s, and M(s,b(s),a) represents the number of times the supervisor is consulted about actions b(s) and a in state s.
[0149] Specifically, The Q factor represents the performance difference between the observed optimal action b(s) and the unobserved optimal action a in state s.
[0150] Rule 1 states that for actions i and j that are not optimal in state s, the amount of samples should be proportional to the square of the "noise-to-signal ratio". Here, "noise" refers to the sample standard deviation of the Q factor, and "signal" refers to the difference in Q factor performance between the optimal action in state s and another action a. The original intention of Rule 1 is to allocate more samples to actions that are inaccurately observed or close to the true value.
[0151] Criterion 2 states that for the best observed actions in two different states i and j, the number of samples obtained should be proportional to the steady-state distribution of the corresponding state and the sample standard deviation of the Q factor. Therefore, the more common a state is, the less accurate the corresponding Q factor observation is, and more samples should be obtained.
[0152] Criterion 3 states that for the best observed action b(s) in state s, the square of the normalized sample size should be the sum of the squares of the "normalized" sample sizes of other actions in the same state. And considering the high accuracy of the supervisor's information, once the supervisor has been consulted, there is no need to waste data and samples to ask the same question (i.e., the question of which of the two actions is better).
[0153] In one implementation, the specific implementation process of step 104 includes:
[0154] Based on APCS, the Lagrangian function F is introduced, from which we can get:
[0155]
[0156] Here, λ is the Lagrange multiplier.
[0157] First, consider an action a1b(s), and take the partial derivative of formula (14) with respect to the sampling amount of action a to obtain:
[0158]
[0159] According to formula (13)
[0160]
[0161] Among them, the second term M(s,b(s),a)=0 in formula (16) means that the supervisor is not consulted to determine whether Q(s,b(s)) or Q(s,a) is better. Please note that N sa It does not affect the first term in formula (16), so we can get:
[0162]
[0163] If M(s,b(s),a)=1, then:
[0164]
[0165] If M(s,b(s),a)=1, then:
[0166]
[0167] Combining formula (12) we can get:
[0168]
[0169] Note that Q(s,b(s))-Q(s,a) is a Gaussian random variable in, Further we get:
[0170]
[0171]
[0172]
[0173] Combining formulas (19)-(23), we can obtain:
[0174]
[0175] Combining formulas (19)-(20), we can obtain:
[0176]
[0177] Next, considering the optimal action b(s), based on formula (14), we can get:
[0178]
[0179] For the first term on the right side of formula (26), note that The mean is The variance is A Gaussian random variable, from which we know in, From this we can get:
[0180]
[0181]
[0182]
[0183] By integrating formulas (27)-(29), we can obtain:
[0184]
[0185] For the second term of formula (26), note that N sb It only affects I(s,a), where a 1b(s) and M(s,b(s),a)=0, from which we can get:
[0186]
[0187]
[0188]
[0189]
[0190] By integrating formulas (32)-(34), we can obtain:
[0191]
[0192] Integrating (31) to (35), we can obtain:
[0193]
[0194] Integrating (26), (30) and (36), we can obtain:
[0195]
[0196] Next, we analyze N si With N sj The relationship between i and j is 1b(s). Note that the local optimal solution Karush-KuhnTucker (KKT) condition states According to formulas (15) and (24), we can obtain:
[0197]
[0198]
[0199] By integrating formulas (38)-(39), we can obtain:
[0200]
[0201] Rearranging formula (40) yields:
[0202]
[0203] When the total sampling volume N is assumed to be infinite, the sampling volume of the optimal action b(s) is much larger than that of other actions, so we can get:
[0204]
[0205]
[0206] Integrating (41) to (43), we can obtain:
[0207]
[0208] Taking the logarithm of both sides we get:
[0209]
[0210] Since the growth rate of the logarithmic term is much slower than other terms, other terms can be omitted. According to the above formula, we can further obtain:
[0211]
[0212] After reorganizing the formula, we get:
[0213]
[0214] Next, we analyze the sampling amount N for observing the optimal action sb and the number of samples of non-observable optimal actions N sa , a≠b(s), M(s, b(s), a) = 0. Formula (37), let N sb1 =N sb2 , N sb1 Corresponding to Pr{∑ s π(s)Q(N,b(s))≤∈},N sb2 Corresponding to Pr{Q(s, b(s))≤Q(N, a)}, we can get:
[0215]
[0216]
[0217] Considering the optimal actions observed in different states, named b(s1) and b(s2), according to formula (35), we can get:
[0218]
[0219] After sorting, we get:
[0220]
[0221] Arranging (24) and (46), we can obtain:
[0222]
[0223] Furthermore, according to formulas (44), (47), and (48), the criteria for the sampling data allocation algorithm can be obtained.
[0224] On the basis of determining the sampling data allocation algorithm, the supervised reinforcement learning method for the operation scheduling of the controlled system can be executed. Specifically, Figure 2 As shown in Figure 1, the supervised reinforcement learning method for the operation scheduling of the controlled system includes:
[0225] Step 201, sampling the simulation results of each state-action pair of the controlled system according to a preset sampling number, and determining the type of each action under each state, the Q factor of each state-action pair, the Q factor sample variance, and the total amount of consumed samples according to the sampled simulation results.
[0226] When this step is implemented, each action in each state and each state-action pair can be recorded as (state, action). Action types include observed optimal and non-observed optimal.
[0227] The preset sampling amount (N0) can be set according to the preset total sampling amount N, the preset number of cycles, the action space and the newly added sampling amount △. Generally, the preset number of cycles is greater than 10, and the preset total sampling amount N is much greater than the preset sampling amount N0 multiplied by the action amount in the action space.
[0228] The action in this step can be determined according to the action space. The state in this step can be determined according to the state space.
[0229] In this step, (state, action) can directly act on the simulation model of the controlled system (such as a digital twin model), and the simulation results of each (state, action) can be determined through the simulation model. In specific implementation, the execution results of the preset sampling amount can also be obtained from the historical data according to the state and action, and the obtained execution results are used as simulation results.
[0230] The total amount of consumed samples in this step is the product of the total state amount, the total action amount and the preset sampling number, which can be calculated using the following formula during implementation:
[0231]
[0232] Among them, n0 represents the preset sampling amount; S represents the state quantity in the state space; A represents the action quantity in the action space.
[0233] Step 202: Calculate the importance of each non-observed optimal action in each state according to the Q factor of each non-observed optimal action and the Q factor of the observed optimal action in each state, and rank the observed optimal action and the importance first. M The unobserved optimal actions are sent to the supervisor to determine the optimal action.
[0234] In detail, the importance of each non-observed optimal action in each state can reflect the closeness between the non-observed optimal action and the observed optimal action. The greater the importance, the greater the possibility that the non-observed optimal action is the optimal action.
[0235] Based on this, we can construct the following formula to express the importance of each non-observable optimal action in each state:
[0236] I(s,α)=1-Pr{Q(s,b(s))≤Q(s,α)};
[0237] Among them, I(s,a) represents the importance of the non-observed optimal action a under state s, and I(s,a) quantifies the probability that the non-observed optimal action a under state s is truly better than the observed optimal action b; Q(s,b(s)) represents the Q factor of the observed optimal action b(s) under state s; Q(s,a) represents the Q factor of the non-observed optimal action a under state s.
[0238] Specifically, the above formula takes into account the minimization problem. If Pr{Q(s,b)<=Q(s,a)} is larger, it means that the selection of the observed optimal action b(s) is more correct. Therefore, the smaller I(s,a) is, the closer it is to 0, indicating that it is not necessary to consider the possibility that the non-observed optimal action a is the best action. On the contrary, if Pr is smaller, it means that the selection of the observed optimal action b(s) may be incorrect. Therefore, the larger I(s,a) is, the closer it is to 1, indicating that it is necessary to consider the possibility that the non-observed optimal action a is the optimal action.
[0239] Therefore, after calculating I(s,a) for all non-observed optimal actions a, the size of I can reflect the possibility that the non-observed optimal action may be the optimal action. The larger I is, the greater the possibility that the corresponding non-observed optimal action a is the optimal action.
[0240] In this step, D M is the default value. Generally, in order to save resources, D M The value is usually 1.
[0241] When this step is implemented, in order to save resources for communicating with the supervisor, it is also possible to determine whether the importance of each non-observed optimal action is less than a preset value, such as 0.5. If so, the optimal action and the importance ranking are omitted. M The step where the non-observed optimal actions are sent to the supervisor, if not, the top D ranked M non-observed optimal actions, rank the importance of the top M The non-observed optimal actions and the observed optimal actions are sent to the supervisor.
[0242] Step 203, adjust the total amount of consumed samples, use the sampling data allocation algorithm to analyze the Q factor sample variance and the total amount of consumed samples of each state-action pair to obtain the target sample size of each action under each state, and the sampling data allocation algorithm includes a criterion for determining the number of samples for each type of action, which is used to gradually maximize the probability of correctly selecting the optimal action for observation.
[0243] The specific criteria included in the sampling data allocation algorithm in this step refer to the above-mentioned embodiment and will not be described again here.
[0244] When this step is implemented, the consumed sampling volume is increased by the newly added sampling volume △ to obtain the adjusted total consumed sampling volume.
[0245] In some embodiments, Figure 3 As shown, the real-time process of this step specifically includes:
[0246] Step 301 : Analyze the Q factor sample variance of each state-action pair according to the sampling data allocation algorithm to obtain the target sample quantity ratio of each action in each state.
[0247] Step 302, the number of samples that should be obtained for each action in each state is obtained by multiplying the target sample number ratio of each action in each state by the total number of consumed samples.
[0248] Step 303 , selecting the larger of the number of samples that should be obtained for each action in each state and the number of samples actually used for each action in each state as the target number of samples for each action in each state.
[0249] Step 204, determining the number of supplementary samples for each action according to the target sample size of each action and the consumed sample size of each action.
[0250] When this step is implemented, the target sample size of each action is subtracted from the consumed sample size of each action to obtain the number of supplementary samples for each action.
[0251] Step 205, performing supplementary sampling according to the number of supplementary samplings for each action, using the simulation results of the supplementary sampling to re-determine the action type and the Q factor sample variance of each state-action pair, and recalculate the importance of each non-observed optimal action under each state and the step of feeding back to the supervisor.
[0252] In detail, the process of performing supplementary sampling according to the supplementary sampling quantity in this step can refer to step 201, and its specific implementation process will not be repeated here.
[0253] The sample variance of the Q factor of each state-action pair can be calculated based on the Q factor sampled from each state-action pair. For details, please refer to the existing variance calculation formula, which will not be described in detail here.
[0254] Step 206, determine whether the total amount of consumed samples is less than or equal to the preset total sampling amount, if so, re-execute the steps of adjusting the total amount of consumed samples and the steps thereafter, if not, output the optimal action observed in each state.
[0255] The preset total sampling amount N can be set jointly according to the preset sampling amount initial value and the action space in step 201, as long as the preset number of repeated cycles from step 201 to step 206 can be met.
[0256] In this step, if the total amount of consumed samples is less than or equal to the action sampling amount constraint, it means that the consumed sampling amount after the next iteration has not reached or is exactly equal to the preset total sampling amount, and the feasibility of the action can continue to be observed in a loop. If the total amount of consumed samples is greater than the action sampling amount constraint, it means that the consumed sampling amount after the next iteration exceeds the preset total sampling amount, and the feasibility of the action cannot be observed.
[0257] In a specific implementation manner, the process of the algorithm of this embodiment is as follows Figure 6 shown. Figure 6 Where d0 represents the initial strategy, n is the preset sampling amount, Δ N Indicates the amount of additional sampling, Δ M Indicates the amount of consultation to be made, n, Δ N Table Δ M Can be pre-set.
[0258] a and a' indicate actions, Represents action space, s represents state, S represents state space, M(s, a, a') represents the number of consultations on which action a or a' is better under state s. During initialization, the number of consultations between any two actions under each state s is 0, that is, M(s, a, a') = 0.
[0259] a sa represents the sample standard deviation of the Q factor of state s-action a, represents the number of samples actually consumed, I(s, a) represents the importance of action a under state s, and when implementing, the top Δ in importance are selected M action a, set M(s, b(s), a) = 1 for the selected action a, that is, each selected action needs to be combined with the optimal action and sent to the supervisor for consultation.M In the subsequent actions, M(s, b(s), ) = 0, that is, there is no need to rank the importance in Δ M Consult supervisor for subsequent actions.
[0260] N represents the preset total sample size, α sa Indicates the sample size ratio between state s and action a. is the number of samples that should be obtained for state s-action a, N sa is the number of samples consumed by state s-action i, N sa ' is the target sample size of state s-action i, N sa '-N sa is the supplementary sampling amount of state s-action a.
[0261] d(s) represents the control strategy determined under state s.
[0262] After the control strategies in each state are obtained through the above embodiments, the controlled system can be controlled according to the control strategies in each state. Specifically, for example, the control strategies in each state are sent to the controlled system, and the control device of the controlled system controls the controlled device of the controlled system according to the control strategies in each state.
[0263] The supervised reinforcement learning method for operation scheduling of a controlled system provided in this embodiment is applicable to complex controlled systems including multiple states and multiple actions, such as smart grids, new energy power systems, etc., and can achieve the following technical effects:
[0264] (1) By optimizing the limited opportunities for communication with the supervisor and the limited opportunities for interaction with the environment, the supervision of the supervisor is integrated with the sampled data, which can improve the efficiency and performance of reinforcement learning.
[0265] (2) By screening out the non-observed optimal actions and observed optimal actions with high importance and sending them to the supervisor, so that the supervisor can determine the optimal action type, the accuracy of determining the optimal action can be improved.
[0266] (3) By using the sampling quantity to determine the criterion, the probability of correctly selecting the optimal action can be gradually maximized, and the simulation resources can be concentrated on the important actions that really need to be distinguished, so as to achieve effective sampling, reduce learning time, and reduce time costs, so that the observation results of each action are more and more accurate, and finally the optimal action is obtained. At the same time, by controlling the sampling quantity, the data efficiency of online reinforcement learning in the operation and scheduling process of the controlled system can be improved, the time required for online decision-making can be significantly improved, and the amount of data used can be reduced.
[0267] Based on the same inventive concept, this article also provides a supervised reinforcement learning device for operation scheduling of a controlled system, as described in the following embodiments. Since the principle of solving the problem by the supervised reinforcement learning device for operation scheduling of a controlled system is similar to the supervised reinforcement learning method for operation scheduling of a controlled system, the implementation of the supervised reinforcement learning device for operation scheduling of a controlled system can refer to the supervised reinforcement learning method for operation scheduling of a controlled system, and the repeated parts will not be repeated.
[0268] Specifically, Figure 4 As shown, the supervised reinforcement learning device for the operation scheduling of the controlled system includes:
[0269] The simulation calculation unit 401 is used to sample the simulation results of each state-action pair of the controlled system according to a preset sampling number, and determine the type of each action in each state, the Q factor of each state-action pair, the Q factor sample variance, and the total amount of consumed samples according to the sampled simulation results;
[0270] The supervision unit 402 is used to calculate the importance of each non-observed optimal action in each state according to the Q factor of each non-observed optimal action in each state and the Q factor of the observed optimal action, and to rank the observed optimal action and the importance first. M The non-observed optimal actions are sent to the supervisor to determine the optimal action;
[0271] The allocation calculation unit 403 is used to adjust the total amount of consumed samples, and analyze the Q factor sample variance and the total amount of consumed samples of each state-action pair using a sampling data allocation algorithm to obtain the target sample size of each action under each state. The sampling data allocation algorithm includes a criterion for determining the number of samples of each type of action, which is used to gradually maximize the probability of correctly selecting the optimal action for observation;
[0272] A supplementary sampling amount determination unit 404 is used to determine the number of supplementary samples for each action according to the target sample amount of each action and the consumed sample amount of each action;
[0273] The supplementary sampling unit 405 is used to perform supplementary sampling according to the supplementary sampling quantity of each action, and the simulation calculation unit 401 uses the simulation result of the supplementary sampling to re-execute the step of determining the action type and the supervision unit 402 re-calculates the importance of each non-observed optimal action in each state and feeds back to the supervisor;
[0274] The analysis unit 406 is used to determine whether the total amount of consumed samples is less than or equal to the preset total sampling amount. If so, the allocation calculation unit re-executes the adjustment of the total amount of consumed samples and the subsequent steps. Otherwise, the optimal action observed in each state is output.
[0275] This embodiment can apply the supervisor's experience to the process of determining the control strategy of the controlled system. By controlling sampling in the process of determining the control strategy, it can improve the data efficiency of the optimization process of the operation and dispatching strategy of the new energy power system, significantly improve the performance of the obtained strategy, and reduce data usage.
[0276] In one embodiment of the present invention, a computer device is also provided, such as Figure 5 As shown, the computer device 502 may include one or more processors 504, such as one or more central processing units (CPUs), each of which may implement one or more hardware threads. The computer device 502 may also include any memory 506, which is used to store any kind of information such as code, settings, data, etc. Non-limitingly, for example, the memory 506 may include any one or more combinations of the following: any type of RAM, any type of ROM, flash memory device, hard disk, optical disk, etc. More generally, any memory may use any technology to store information. Further, any memory may provide volatile or non-volatile retention of information. Further, any memory may represent a fixed or removable component of the computer device 502. In one case, when the processor 504 executes an associated instruction stored in any memory or a combination of memories, the computer device 502 may perform any operation of the associated instruction. The computer device 502 also includes one or more drive mechanisms 508 for interacting with any memory, such as a hard disk drive mechanism, an optical disk drive mechanism, etc.
[0277] The computer device 502 may also include an input / output module 510 (I / O) for receiving various inputs (via input devices 512) and for providing various outputs (via output devices 514). A specific output mechanism may include a presentation device 516 and an associated graphical user interface 518 (GUI). In other embodiments, the input / output module 510 (I / O), input device 512, and output device 514 may not be included, and the computer device 502 may be used as a computer device in a network. The computer device 502 may also include one or more network interfaces 520 for exchanging data with other devices via one or more communication links 522. One or more communication buses 524 couple the components described above together.
[0278] The communication link 522 may be implemented in any manner, for example, through a local area network, a wide area network (e.g., the Internet), a point-to-point connection, etc., or any combination thereof. The communication link 522 may include any combination of hardwired links, wireless links, routers, gateway functions, name servers, etc., governed by any protocol or combination of protocols.
[0279] The embodiments of the present invention further provide a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the above method are executed.
[0280] The embodiments of this document also provide a computer-readable instruction, wherein when a processor executes the instruction, the program therein causes the processor to execute the method described in any of the aforementioned embodiments.
[0281] It should be understood that in the various embodiments of this document, the size of the serial numbers of the above-mentioned processes does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this document.
[0282] It should also be understood that in the embodiments of this article, the term "and / or" is only a description of the association relationship of the associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0283] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in terms of function in the above description. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this article.
[0284] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0285] In the several embodiments provided herein, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of the units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, or can be electrical, mechanical or other forms of connection.
[0286] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiments of this article.
[0287] In addition, each functional unit in each embodiment of this invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above integrated unit may be implemented in the form of hardware or in the form of software functional unit.
[0288] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this article is essentially or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of this article. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.
[0289] Specific embodiments are used in this article to illustrate the principles and implementation methods of this article. The description of the above embodiments is only used to help understand the methods and core ideas of this article. At the same time, for general technicians in this field, according to the ideas of this article, there will be changes in the specific implementation methods and application scopes. In summary, the content of this specification should not be understood as a limitation on this article.
Claims
1. A supervised reinforcement learning method for operation scheduling of a controlled system, characterized in that: include: Sampling the simulation results of each state-action pair of the controlled system according to a preset sampling number, and determining the type of each action under each state, the Q factor of each state-action pair, the Q factor sample variance, and the total amount of consumed samples according to the sampled simulation results; The importance of each non-observed optimal action in each state is calculated based on the Q factor of each non-observed optimal action and the Q factor of the observed optimal action in each state, and the observed optimal action and importance are ranked first. M The non-observed optimal actions are sent to the supervisor to determine the optimal action; Adjust the total amount of consumed samples, and use the sampling data allocation algorithm to analyze the Q factor sample variance and the total amount of consumed samples of each state-action pair to obtain the target sample size of each action under each state. The sampling data allocation algorithm includes the criteria for determining the number of samples for each type of action, which is used to gradually maximize the probability of correctly selecting the optimal action for observation; Determine the number of additional samples for each action based on the target sample size of each action and the sample size consumed by each action; Perform supplementary sampling according to the number of supplementary sampling of each action, and use the simulation results of supplementary sampling to re-determine the action type steps and recalculate the importance of each non-observed optimal action in each state and the steps of feedback to the supervisor; Determine whether the total amount of consumed samples is less than or equal to the preset total sampling amount. If so, re-execute the steps of adjusting the total amount of consumed samples and the steps thereafter. Otherwise, output the optimal action observed in each state.
2. The method according to claim 1, characterized in that The sampling data allocation algorithm determination process includes: According to the equipment information, load information, system status, control action, and optimization target information of the controlled system, establish the objective function of the control strategy, action sampling quantity constraints, and consultation quantity constraints; Transforming the objective function of the control strategy to obtain the action Q factor of reinforcement learning; According to the action Q factor, an index function for calculating the importance of the non-observed optimal action and an objective function for approximating the probability function of selecting the observed optimal action are constructed; According to the objective function, the index function, the action sampling quantity constraint condition and the consultation quantity constraint condition of the approximate observed optimal action selection probability function, the criteria of the sampling data allocation algorithm are determined.
3. The method according to claim 2, characterized in that The objective function, action sampling quantity constraint condition and consultation quantity constraint condition of the approximate observation optimal action selection probability function are expressed by the following formula: Max APCS; ∑ s,a,a' M(s,a,a')=M; Where APCS represents the approximate observed optimal action selection probability function, s represents the state, a represents the unobserved optimal action, b(s) represents the observed optimal action, Q(s,b(s)) represents the Q factor of the observed optimal action b(s) under state s, Q(s,a) represents the Q factor of the unobserved optimal action a under state s, π(s) represents the steady-state probability distribution of state s, ε represents a constant, and N sa represents the number of samples of the Q factor corresponding to state s and action a, N represents the total number of samples, M(s,a,a') represents the number of times the supervisor is consulted about actions a and a' under state s, and M represents the total amount of consultations with the supervisor.
4. The method according to claim 1, characterized in that The importance of each non-observable optimal action in each state is calculated based on the Q factor of each non-observable optimal action in each state and the Q factor of the observed optimal action, including: The importance of each non-observable optimal action in each state is calculated using the following formula: I(s,a)≡1-Pr{Q(s,b(s))≤Q(s,a)}; Among them, I(s,a) represents the importance of the non-observed optimal action a in state s; Q(s,b(s)) represents the Q factor of the observed optimal action b in state s; Q(s,a) represents the Q factor of the non-observed optimal action a in state s.
5. The method according to claim 1, characterized in that The sample data allocation algorithm is used to indicate: The larger the noise-to-signal ratio of the non-observed optimal action in each state s, the larger the number of samples of the non-observed optimal action. The noise in the noise-to-signal ratio refers to the sample standard deviation of the Q factor of the non-observed optimal action in each state s, and the information in the noise-to-signal ratio refers to the performance difference between the Q factor of the observed optimal action in each state s and the Q factor of the non-observed optimal action in state s. The number of samples of the best observed action in each state should be proportional to the product of the steady-state probability of each state and the sample standard deviation of the Q factor of the best observed action in each state; For observed optimal actions and non-observed optimal actions that have not been confirmed by the supervisor, the number of samples of observed optimal actions under each state s should be greater than the number of samples of other non-observed optimal actions.
6. The method according to claim 5, characterized in that The sample data allocation algorithm includes the following criteria: Criterion 1: For unobserved optimal actions i and j, Among them, N si represents the number of samples of action i in state s, N sj represents the number of samples of action j in state s, σ si represents the sample standard deviation of the Q factor of action i in state s, σ sj represents the sample standard deviation of the Q factor of action j in state s, δ si The Q factor representing the observed optimal action at state s and the performance difference between action i at state s, δ sj The Q factor representing the observed optimal action for state s and the performance difference of action j in state s; Criterion 2: For the best observed action b in state i and the best observed action b in state j, Among them, N ib N represents the number of samples of the best observed action b(i) in state i. jb represents the number of samples of the observed optimal action b(j) under state j, π(i) represents the steady-state probability distribution of state i, π(j) represents the steady-state probability distribution of state j, σ ib represents the sample standard deviation of the Q factor of the observed optimal action b(i) in state i, σ jb represents the sample standard deviation of the Q factor of the observed optimal action b(j) in state j; Criterion 3: For the observation in state s, the optimal action b is, Among them, N sb represents the number of samples of action b(s) in state s, σ sb represents the sample standard deviation of the Q factor of action b(s) in state s, N sa represents the number of samples of non-observed optimal action a in state s, σ sa represents the sample standard deviation of the Q factor of the non-observed optimal action a in state s, and M(s,b(s),a) represents the number of times the supervisor is consulted about actions b(s) and a in state s.
7. The method according to claim 1, characterized in that The sample data allocation algorithm is used to analyze the Q factor sample variance and the total amount of consumed samples of each state-action pair to obtain the target sample size of each action in each state, including: The Q-factor sample variance of each state-action pair is analyzed according to the sampling data allocation algorithm to obtain the target sample quantity ratio of each action in each state; The number of samples that should be obtained for each action in each state is obtained by multiplying the target sample number ratio of each action in each state by the total number of consumed samples; The larger of the number of samples that should be obtained for each action in each state and the number of samples actually used for each action in each state is selected as the target number of samples for each action in each state.
8. A supervised reinforcement learning device for operation scheduling of a controlled system, characterized in that: include: A simulation calculation unit is used to sample the simulation results of each state-action pair of the controlled system according to a preset sampling number, and determine the type of each action under each state, the Q factor of each state-action pair, the Q factor sample variance, and the total amount of consumed samples according to the sampled simulation results; The supervision unit is used to calculate the importance of each non-observed optimal action in each state according to the Q factor of each non-observed optimal action and the Q factor of the observed optimal action in each state, and rank the observed optimal action and the importance first. M The non-observed optimal actions are sent to the supervisor to determine the optimal action; An allocation calculation unit is used to adjust the total amount of consumed samples, and to analyze the Q factor sample variance and the total amount of consumed samples of each state-action pair using a sampling data allocation algorithm to obtain the target sample size of each action under each state. The sampling data allocation algorithm includes a criterion for determining the number of samples of each type of action, which is used to asymptotically maximize the probability of correctly selecting the optimal action for observation; A supplementary sampling amount determination unit, used to determine the number of supplementary sampling for each action according to the target sample amount of each action and the consumed sample amount of each action; A supplementary sampling unit is used to perform supplementary sampling according to the number of supplementary sampling of each action, and the simulation calculation unit uses the simulation result of the supplementary sampling to re-execute the step of determining the action type and the supervision unit re-calculates the importance of each non-observed optimal action under each state and feeds back to the supervisor; The analysis unit is used to determine whether the total amount of consumed samples is less than or equal to the preset total sampling amount. If so, the allocation calculation unit re-executes the adjustment of the total amount of consumed samples and the subsequent steps. Otherwise, the optimal action observed in each state is output.
9. 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, the method according to any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor of a computer device, the method according to any one of claims 1 to 7 is implemented.
