Anti-fact reasoning-based confrontation simulation experiment result root cause analysis method and system
Through the method based on counterfactual reasoning, event causal diagrams and twin networks are constructed to determine the cause of the adversarial simulation results, solve the problem of analysis misjudgment in the existing technology, and achieve accurate analysis and improvement of the adversarial simulation results.
Patent Information
- Application Number
- CN202410768739.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-14
- Publication Date
- 2024-10-08
- Estimated Expiration
- 2044-06-14
AI Technical Summary
The existing root cause analysis method of adversarial simulation experiment results is based on correlation, which easily leads to misjudgment, reduces the accuracy of the analysis results, and makes it difficult to accurately analyze the causes of the simulation results.
Using a method based on counterfactual reasoning, we calculate counterfactual sufficiency and necessity by constructing event causal diagrams and twin networks, determine the cause events, and construct a counterfactual structural causal model, and use random search-adaptive particle swarm optimization algorithm to find the best Intervene parameters and values to generate root cause analysis results.
Accurately analyze the causes of the confrontation simulation results, and provide factors and state variable settings to improve the simulation results, improving the accuracy and reliability of the analysis results.
Smart Images

Figure CN118747531A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of adversarial simulation analysis, and in particular to a method and system for root cause analysis of adversarial simulation experiment results based on counterfactual reasoning. Background Art
[0002] Using adversarial simulation methods to describe operational elements and processes is the most effective way to study the complexity of warfare under dynamic conditions during peacetime. Adversarial simulation involves constructing a virtual battlefield environment encompassing the weapons and equipment of opposing sides, simulating the information, firepower, mobility, protection, and support capabilities of combat forces. This allows for the full simulation of command, action, and support under different combat styles, scenarios, timeframes, and conditions, capturing data on the processes and outcomes of various combat operations. This provides support for research on decision-making issues such as weapon and equipment system demonstration, operational concept and tactics research, operational plan verification, battlefield situation and outcome prediction, and unit combat capability assessment.
[0003] Current root cause analysis methods for adversarial simulation experiment results primarily rely on correlation-based analysis. These methods include association analysis, knowledge graphs, event graphs, behavioral modeling, Bayesian networks, and fuzzy cognitive graphs. However, correlation-based methods can easily lead to misjudgment of the root cause, reducing the accuracy of root cause analysis results and making it difficult to accurately identify the causes of adversarial simulation results. Summary of the Invention
[0004] The purpose of the present invention is to disclose a root cause analysis method and system for adversarial simulation experiment results based on counterfactual reasoning, so as to accurately analyze the causes leading to adversarial simulation results and provide factors and state variable settings to improve the simulation results.
[0005] To achieve the above objectives, in a first aspect, the present invention discloses a method for root cause analysis of adversarial simulation experiment results based on counterfactual reasoning, comprising:
[0006] S1: Develop an adversarial simulation experiment for the target adversarial simulation scenario and collect experimental data of the adversarial simulation experiment, wherein the experimental data includes factor data, state variable data, response data, and log data;
[0007] S2: constructing an event causal graph of the adversarial simulation experiment based on the test data, calculating counterfactual sufficiency according to the twin network of the event causal graph, and calculating counterfactual necessity according to the twin network of the event causal graph;
[0008] S3: determining the causal event that leads to the occurrence of the adversarial simulation result based on the counterfactual sufficiency and the counterfactual necessity;
[0009] S4: Construct a counterfactual structural causal model of the causal event and the factors and states that affect the occurrence of the event;
[0010] S5: Determine the values of each intervention parameter based on the counterfactual structural causal model, determine the optimal intervention parameter and the optimal intervention value, and generate a root cause analysis result.
[0011] In a second aspect, the present invention also discloses a root cause analysis system for adversarial simulation experiment results based on counterfactual reasoning, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above method when executing the computer program.
[0012] The present invention has the following beneficial effects:
[0013] This application provides a root cause analysis method for adversarial simulation experiment results based on counterfactual reasoning. The concepts of counterfactual sufficiency and counterfactual necessity are proposed. The causal event that leads to the adversarial simulation experiment result is found based on counterfactual sufficiency and counterfactual necessity. Then, a probability model of the factors, state variables and probability of occurrence of the event that affect the occurrence of the event is constructed. Then, a counterfactual structural causal model between the factors and state variables that cause the event is constructed. Finally, a random search-adaptive particle swarm optimization algorithm is used to find the factor and state variable settings that can minimize the probability of the classification model, and the adversarial simulation experiment results are improved accordingly. The method can accurately analyze the causes of the adversarial simulation results and provide the factor and state variable settings that improve the simulation results.
[0014] The present invention will be described in further detail below with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] The accompanying drawings, which constitute part of this application, are intended to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are intended to explain the present invention and do not constitute an undue limitation of the present invention. In the accompanying drawings:
[0016] Figure 1 This is a flowchart of a root cause analysis method for adversarial simulation experiment results based on counterfactual reasoning in a preferred embodiment of the present application.
[0017] Figure 2 This is a twin network diagram for calculating counterfactual sufficiency in a preferred embodiment of the present application.
[0018] Figure 3 Schematic diagram of a twin network for calculating counterfactual necessity in a preferred embodiment of the present application. DETAILED DESCRIPTION
[0019] The following is a clear and complete description of the technical solutions of the present invention. It should be understood that the embodiments described are only a portion of the embodiments of the present invention, not all of them. All other embodiments derived by persons of ordinary skill in the art based on the embodiments of the present invention without inventive effort are intended to fall within the scope of protection of the present invention.
[0020] Unless otherwise defined, the technical or scientific terms used in the present invention shall have the usual meanings understood by persons of ordinary skill in the field to which the present invention belongs. The words "first", "second" and similar terms used in the present invention do not indicate any order, quantity or importance, but are only used to distinguish different components. Similarly, words such as "one" or "a" do not indicate a quantity limitation, but rather indicate the existence of at least one. Words such as "connected" or "connected" are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the object being described changes, the relative positional relationship also changes accordingly.
[0021] See Figure 1 , this application provides a root cause analysis method for adversarial simulation experiment results based on counterfactual reasoning, including:
[0022] S1: Develop an adversarial simulation experiment for the target adversarial simulation scenario and collect experimental data of the adversarial simulation experiment, wherein the experimental data includes factor data, state variable data, response data, and log data;
[0023] S2: constructing an event causal graph of the adversarial simulation experiment based on the test data, calculating counterfactual sufficiency according to the twin network of the event causal graph, and calculating counterfactual necessity according to the twin network of the event causal graph;
[0024] S3: determining the causal event that leads to the occurrence of the adversarial simulation result based on the counterfactual sufficiency and the counterfactual necessity;
[0025] S4: Construct a counterfactual structural causal model of the causal event and the factors and states that affect the occurrence of the event;
[0026] S5: Determine the values of each intervention parameter based on the counterfactual structural causal model, determine the optimal intervention parameter and the optimal intervention value, and generate a root cause analysis result.
[0027] It's important to note that during the simulation, a wealth of factor data reflecting information such as the opposing parties' firepower settings, troop strength settings, environmental settings, and confrontation outcomes is recorded, as well as status data reflecting the combat process. Log data also records the occurrence and timing of various events during the simulation, along with response data used to evaluate the combat process. These factor data, status data, response data, and log data are collectively referred to as experimental data. Analyzing this experimental data can identify the causes of varying simulation results and provide constructive guidance for improving them.
[0028] The aforementioned root cause analysis method for adversarial simulation experiment results based on counterfactual reasoning proposes the concepts of counterfactual sufficiency and counterfactual necessity. Based on these concepts, the causal event leading to the adversarial simulation experiment result is identified. A classification model is then constructed that identifies the factors and state variables that influence the occurrence of this event and the probability of its occurrence. A counterfactual structural causal model is then constructed between the factors and state variables that caused the event. Finally, a random search-adaptive particle swarm optimization algorithm is used to identify the factor and state variable settings that minimize the probability of the classification model, which are then used to improve the adversarial simulation experiment results. This method accurately analyzes the causes of the adversarial simulation results and identifies the factor and state variable settings that can improve the simulation results.
[0029] Optionally, computing counterfactual sufficiency based on the twin network of the event causal graph includes the following steps:
[0030] S21: Obtain the event causal graph of the i-th adversarial simulation based on expert knowledge Represents the set of events that occurred, Q represents the number of event types that occurred in this simulation, and the last event Represents the results of this simulation, represents the edge set of the causal graph of the i-th simulation event, represents the field of real numbers;
[0031] S22: Obtaining a causal diagram of influencing events based on knowledge Each event in Factors and state variables that occur;
[0032] S23: Will affect events The factors and state variables that occur are abstracted as exogenous variables
[0033] S24: Construct a structural causal model of an event causal graph, which is defined as: there is a set of node variables in the model (node variables of events) A set of latent variables A directed acyclic graph It is called the causal structure of the model, and its node variable is E i ∪Ui , and the function set F={f1,…,f Q}, where f j yes arrive The mapping, Represents E ij The value of the parent variable. The set F is formed from U i to E i The mapping can be expressed as:
[0034]
[0035] When the set of functions F is formed from the noise variables U i To node variable E i When the mapping is done, the distribution on the noise variables induces the distribution on the node variables, which is given by:
[0036]
[0037] In the formula, := represents assignment, and the event node is a Bernoulli variable with only two states: 0 and 1. Any cause event may lead to the occurrence of the result event. Let its parent variable be {Y1, ..., Y L}, its corresponding generating function f j As shown below:
[0038]
[0039] Indicates Under the exogenous variable value of The probability that it will not happen spontaneously. As shown below:
[0040]
[0041] Indicates that there is only cause event Y k In case of occurrence, the event The probability of not happening. The uniform value is 0.001 (if the cause event of an event occurs, then the event is likely to occur)
[0042] S25: Constructing a twin event causal diagram like Figure 2 As shown, the counterfactual sufficiency of each event is calculated based on the structural causal model of the twin event causal graph and the event causal graph. The definition of counterfactual sufficiency is as follows: Divide Y k All other causal events {Y1, ..., Y L}\Y k The probability that the event will still occur even if intervention is made to prevent it from happening is shown in the following formula.
[0043]
[0044] represents the state of the event in the counterfactual, ε represents the evidence, except for the event The state of other events with the cause event. do({Y1, ..., Y L}\Y k =0) in the counterfactual event, except for Y k All other causal events {Y1, ..., Y L}\Y k Intervene so that it doesn't happen.
[0045] Calculate counterfactual necessity based on the twin network of the event causal graph, including:
[0046] S26: Based on the twin event causal diagram Cause-effect diagram of impact events The structural causal model of computes the counterfactual necessity of each event, such as Figure 3 As shown, the definition of counterfactual necessity is as follows: for the event For cause event Y k Intervene so that it does not happen, event The probability of not happening is as follows:
[0047]
[0048] represents the state of the event in the counterfactual, ε represents the evidence, except for the event The status of other events with the cause event. do(Y k =0) represents Y k Intervene so that it doesn't happen.
[0049] Optionally, finding the causal event that leads to the adversarial simulation result based on counterfactual sufficiency and counterfactual necessity includes the following steps:
[0050] For the result event, the counterfactual sufficiency and counterfactual necessity are calculated for each of its cause events, and the cause event with the largest sum is the one that causes the result event.
[0051] Optionally, constructing a counterfactual structural causal model of a cause event and factors and states that affect the occurrence of the event specifically includes the following steps:
[0052] S41: Using One-Class Support Vector Machine (OCSVM) to construct factor data X i,j, state variable data S i,j and events The input-output model between i,j 、S i,j , the output is the event The probability of occurrence. This model is a probability model. To represent, h represents the probability model, let If h(·) is greater than 0.5, it means that the event will occur, and if it is less than 0.5, it means that the event will not occur;
[0053] S42: Construct a structural causal model of factors and state variables that affect the occurrence of the event. The Gaussian process SCM (CP-SCM) on refers to the following model:
[0054]
[0055] There is a covariance function refers to Gaussian distribution, d refers to the number of all variables, U r refers to the exogenous variable, f r Refers to the mapping function, X pa(r) Refers to the parent variable set of each parameter, represents a normal distribution, represents variance, r represents variable, and ~ represents compliance. For example: continuous X pa(r) The RBF kernel is simulated multiple times. The data were fitted to obtain GP-SCM.
[0056] S43: Construct a counterfactual structural causal model of the factors and state variables that affect the occurrence of the event. The counterfactual structural causal model is based on the structural causal model constructed in S42 and is defined as follows: Is from For observation samples of |pa(r)|>0, r∈[d], X r The counterfactual structural causal model makes it possible for a single It is given by:
[0057]
[0058] in, and K represents the Gram matrix. , and The posterior mean and variance of Represents the parent variable for each parameter in the counterfactual world.
[0059] Factor the counterfactual and set the state variable x CF, the counterfactual x CF Input the OCSVM model to obtain the probability of the event occurring after resetting the factors and states.
[0060] Optionally, S5 specifically includes the following steps:
[0061] S51: Define the best course of action. The best course of action must meet the following three conditions:
[0062] 1. The best intervention should be able to successfully prevent the causal event from occurring;
[0063] 2. When selecting intervention parameters, it is necessary to ensure that the selected parameters are easy to intervene;
[0064] 3. The values of each intervention parameter must be within the normal value range of the parameter, and the closer to the original value of the parameter, the better.
[0065] For impact events Parameters that occur The array I=<0,...,1,...,1> is used to indicate whether to intervene in these parameters, where 0 indicates intervention and 1 indicates no intervention; the array do={do1,...,do K+P} represents the difficulty of intervening on these variables. The smaller the value, the simpler the intervention on this variable is and the easier it is to operate. V =<0,...,a i ,...,a K+P > represents the value of each intervention parameter, parameter a i The value of needs to be within the normal range of parameter i;
[0066] S52: Assume that the objective function of the optimization algorithm is Tar, which is composed of three sub-objective functions: Tar1, Tar2, and Tar3, which correspond to the three conditions of the best preventive measures respectively.
[0067] After intervening in the parameters, the counterfactual structural causal model is used to obtain the counterfactual values of each parameter, assuming that it is Will Input the OCSVM model to get the probability of the event occurring. The smaller the better. Tar1 is as follows:
[0068]
[0069] The selected intervention parameters should be as easy to operate as possible, and Tar2 is shown as follows:
[0070] Tar2=min|I T *do| (10);
[0071] The symbol T represents the transpose of the matrix.
[0072] set up represents the original value of the intervened variable. The intervention value should be as close to the original value of the variable as possible. Tar3 is shown in the following formula:
[0073]
[0074] In summary, the objective function of the optimization algorithm is:
[0075] Tar=w1Tar1+w2Tar2+w3Tar3 (12);
[0076] w1, w2, and w3 represent the weights of each sub-objective function.
[0077] S53: Generate a large number of initial intervention variables I and intervention values I according to the constraints V , generate I, I V The constraints are as follows:
[0078] The intervention variable I is a binary array with a value of 0 or 1, where 0 represents no intervention and 1 represents intervention.
[0079] Intervention value I V It is a real number array. For each parameter, there is a normal range. The intervention value should be within the normal range of the corresponding parameter. The intervention value I V This is the final part to be optimized based on the random search-adaptive particle swarm optimization algorithm.
[0080] The optimization algorithm based on random search-adaptive particle swarm requires setting a large number of initial populations, i.e. candidate intervention measures. Let the initial population size be size, and the population includes intervention variables and intervention values. Assume that the number of intervention variables I randomly generated by the above rules is s_size, that is, assume that the set of randomly generated intervention variables is {I1, ..., I s_size}, the size of the initial population, s_size, and the intervention value I V is the variable optimized by the optimization algorithm, and I is obtained. The counterfactual SCM can be used to calculate the possible worlds. Through the optimization algorithm based on random search-adaptive particle swarm, and judging whether the convergence conditions are met, the best intervention measure I is finally obtained. best 、 They represent the optimal intervention parameter and the optimal intervention value respectively, to find the optimal value to avoid the occurrence of the cause event.
[0081] The following describes the steps of the root cause analysis method for adversarial simulation experiment results based on counterfactual reasoning using a complete example:
[0082] In the following adversarial simulation scenario, a swarm of Blue UAVs destroys a key Red target and then retreats to a mountainous and jungle area. The Red side quickly dispatches reconnaissance drones and a swarm of attack UAVs to coordinate a siege in the mountainous and jungle area, attempting to destroy or encircle the Blue UAVs. This adversarial simulation experiment was repeated 100 times, and factor data, state data, response data, and log data from the experiment were collected.
[0083] In the 10th simulation, the blue team did not retreat to the safe zone within the specified time. It is necessary to find the cause of the blue team's failure to retreat within the specified time. First, a causal diagram of the simulation event is constructed based on expert knowledge. The events that occurred include the red team's drone detecting the blue team's unmanned cluster. Blue team encounters an obstacle War Interaction The Blue team failed to retreat to a safe zone within the specified time and All events Cause of occurrence.
[0084] According to expert knowledge, factors and state variables that affect the occurrence of each event are obtained, and the events are affected. The factors that cause this are the red team's reconnaissance capability x1 and the blue team's anti-reconnaissance capability x2; The factors that occur include the blue team's environmental adaptability X3; The factors that affect the occurrence of E3 are the blue team's cluster reliability X4 and the blue team's cluster anti-destruction capability X5. The state variables that affect the occurrence of E3 are the blue team's force S1 and the red team's force S2. The factors that occur are the blue team's forward speed X6.
[0085] Will affect events The factors and state variables that occur are abstracted as exogenous variables Will affect events The factors and state variables that occur are abstracted as exogenous variables Will affect events The factors and state variables that occur are abstracted as exogenous variables Will affect events The factors and state variables that occur are abstracted as exogenous variables
[0086] structure Structural causal model between.
[0087] According to the structural causal model of the event graph and the twin network of the event graph, we calculate The counterfactual sufficiency of .
[0088] According to the structural causal model of the event graph and the twin network of the event graph, we calculate The counterfactual necessity.
[0089] right The counterfactual sufficiency and counterfactual necessity of the four events are added together and compared. The largest value is the war interaction. Therefore, the war interaction is the causal event that leads to the simulation results.
[0090] Influence War Interaction The factors that affect the blue team's cluster reliability X4 and the blue team's cluster anti-destruction capability X5 are: The state variables that occur are the blue side's troop strength S1 and the red side's troop strength S2. Record whether these 100 simulated war interactions occur, as well as the corresponding values of X4, X5, S1, and S2. Use a one-class support vector machine (OCSVM) to construct the relationship between X4, X5, S1, and S2. The probability model has the values of X4, X5, S1, and S2 as input and the output is Probability of occurrence;
[0091] Construct a structural causal model among X4, X5, S1, and S2;
[0092] According to the structural causal model between X4, X5, S1 and S2, a counterfactual structural causal model between X4, X5, S1 and S2 is constructed;
[0093] The counterfactual structural causal model of X4, X5, S1, and S2 is used to evaluate X4, X5, S1, and S2, which is called counterfactual evaluation. That is the intervention measure.
[0094] Set the objective function of the optimization algorithm as follows: Input the OCSVM model, and the output should be as small as possible; the operational difficulty of X4 and X5 interventions is 0.1, and the operational difficulty of S1 and S2 is 0.5; The further away from the original value is, the better. The weights of the three sub-objective functions are all 1.
[0095] Generate a large number of initial intervention variables and intervention values, and use the random search-adaptive particle swarm optimization algorithm to obtain the best values of X4, X5, S1, and S2, which is a measure to improve the simulation results.
[0096] The present application also provides a root cause analysis system for adversarial simulation experiment results based on counterfactual reasoning, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the corresponding methods in the above two embodiments are implemented.
[0097] The root cause analysis system for adversarial simulation experiment results based on counterfactual reasoning can implement the various embodiments of the above-mentioned root cause analysis method for adversarial simulation experiment results based on counterfactual reasoning, and can achieve the same beneficial effects, which will not be described here.
[0098] In summary, the above-mentioned embodiments of the present invention respectively disclose a method and system for root cause analysis of adversarial simulation experiment results based on counterfactual reasoning, which has at least the following beneficial effects:
[0099] The present invention first proposes the concepts of counterfactual sufficiency and counterfactual necessity based on counterfactual reasoning, and finds the causal event leading to the results of the adversarial simulation experiment based on counterfactual sufficiency and counterfactual necessity. Then, a classification model of the factors, state variables and the probability of occurrence of the event is constructed, and then a counterfactual structural causal model between the factors and state variables of the event is constructed. Finally, a random search-adaptive particle swarm optimization algorithm is used to find the factor and state variable settings that can minimize the probability of the classification model, and the adversarial simulation experiment results are improved accordingly.
[0100] The foregoing description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Those skilled in the art will readily appreciate that various modifications and variations of the present invention are possible. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention are intended to be within the scope of protection of the present invention.
Claims
1. A root cause analysis method for adversarial simulation experiment results based on counterfactual reasoning, characterized in that: include: S1: formulate an adversarial simulation experiment for the target adversarial simulation scenario, and collect experimental data of the adversarial simulation experiment, wherein the experimental data includes factor data, state variable data, response data, and log data; S2: constructing an event causal graph of the adversarial simulation experiment based on the test data, calculating counterfactual sufficiency according to the twin network of the event causal graph, and calculating counterfactual necessity according to the twin network of the event causal graph; S3: determining the cause event that leads to the occurrence of the adversarial simulation result according to the counterfactual sufficiency and the counterfactual necessity; S4: Construct a counterfactual structural causal model of the causal event and the factors and states that affect the occurrence of the event; S5: Determine the value of each intervention parameter based on the counterfactual structural causal model, determine the optimal intervention parameter and the optimal intervention value, and generate a root cause analysis result.
2. The root cause analysis method of adversarial simulation experiment results based on counterfactual reasoning according to claim 1 is characterized in that: The calculation of counterfactual sufficiency based on the twin network of the event causal graph includes: S21: Obtain the causal graph of the impact events of the i-th adversarial simulation based on expert knowledge represents the set of events that occurred, Q represents the number of event types that occurred in this simulation, and event Represents the result of this simulation, represents the edge set of the causal graph of the i-th simulation event, represents the field of real numbers; S22: Obtaining a causal diagram of influencing events based on expert knowledge Each impact event in Factors and state variables that occur; S23: Will affect events The factors and state variables that occur are abstracted as exogenous variables S24: constructing a structural causal model that affects the event causal graph, wherein the structural causal model includes a set of node variables A set of potential noise variables A directed acyclic graph Its node variable is E i ∪U i , function set F = {f1,…,f Q }, where f j yes arrive The mapping of represent The value of the parent variable, the function set F forms the i To E i The mapping is expressed as follows: When the function set F is formed from the noise variable U i To node variable E i When the mapping is performed, the distribution on the noise variable causes the distribution on the node variable, which is expressed as follows: In the formula, := represents assignment, and the event node is a Bernoulli variable with only two states: 0 and 1. Any cause event may lead to the occurrence of the result event. Let its parent variable be {Y1,…,Y L }, and its corresponding generating function f j As shown below: In the formula, Indicated in Under the exogenous variable value of The probability that it will not happen spontaneously, Indicates that there is only cause event Y k In case of occurrence, the event The probability of not happening is as follows: S25: Constructing a twin event causal diagram The counterfactual sufficiency of each event is calculated based on the structural causal model of the twin event causal graph and the influencing event causal graph, where the counterfactual sufficiency means: for the event Divide Y k All other causal events {Y1,…,Y L }\Y k The probability that the event will still occur even if intervention is made to prevent it from happening Satisfies the following relationship: In the formula, represents the event state in the counterfactual, and ε represents the event except The state of other events with the cause event, do({Y1,…,Y L }\Y k =0) indicates that in the counterfactual event, k All other causal events {Y1,…,Y L }\Y k Intervene so that it doesn't happen.
3. The root cause analysis method of adversarial simulation experiment results based on counterfactual reasoning according to claim 2 is characterized in that: The calculation of counterfactual necessity based on the twin network of the event causal graph includes: S26: Based on the twin event causal diagram Cause and effect diagram of impact events The structural causal model of Calculate the counterfactual necessity of each event, counterfactual necessity means: for the event For cause event Y k To intervene so that it does not happen, event Probability of not happening Satisfies the following relationship: In the formula, do(Y k =0) indicates that in the counterfactual event, the cause event Y k Intervene so that it doesn't happen.
4. The root cause analysis method of adversarial simulation experiment results based on counterfactual reasoning according to claim 1 is characterized in that: The S3 includes: For the result event, the counterfactual sufficiency and counterfactual necessity are calculated for each cause event corresponding to the result time, and the cause that causes the result event to occur is the one with the largest sum of the counterfactual sufficiency and the counterfactual necessity.
5. The root cause analysis method of adversarial simulation experiment results based on counterfactual reasoning according to claim 1 is characterized in that: The S4 includes: S41: Constructing factor data X using one-class support vector machine OCSVM i,j , state variable data S i,j With events The input-output model between i,j , S i,j , the output is the event The probability of occurrence, this model is a probability model, using represents, h represents the probability model, let If h(·) is greater than 0.5, it means that the event will occur, and if it is less than 0.5, it means that the event will not occur; S42: Construct a structural causal model of the factor data and state variable data that affect the occurrence of the event. The Gaussian process SCM above refers to the following model: Among them, the covariance function refers to Gaussian distribution, d refers to the number of all variables, U r refers to the exogenous variable, f r refers to the mapping function, X pa(r) Refers to the set of parent variables for each parameter, represents a normal distribution, represents variance, r represents variable, and ~ represents obedience; S43: Construct a counterfactual structural causal model of the factor data and state variable data that affect the occurrence of the event. The counterfactual structural causal model is based on the structural causal model constructed in S42 and is defined as follows: set up Is from For r∈[d] with |pa(r)|>0, X r The counterfactual structural causal model makes it possible for a single Given by: in, and K represents the Gram matrix, and represents the posterior mean and variance, The parent variable representing each parameter in the counterfactual world; Set the counterfactual factor data and state variable data to x CF , the counterfactual x CF Input the OCSVM model to obtain the probability of an event occurring after resetting the factors and states.
6. The root cause analysis method of adversarial simulation experiment results based on counterfactual reasoning according to claim 1 is characterized in that: The S5 includes: S51: Define best course of action; for impact events The parameters that occur The array I = <0,…,1,…,1> indicates whether to intervene in these parameters, where 0 indicates intervention and 1 indicates no intervention; the array do = {do1,…,do K+P } represents the difficulty of intervening on these variables. The smaller the value, the simpler the intervention on the variable and the easier it is to operate. V =<0,…,a i ,…,a K+P > represents the value of each intervention parameter, parameter a i The value of needs to be within the normal range of parameter i; S52: Assume that the objective function of the optimization algorithm is Tar, which is composed of three sub-objective functions Tar1, Tar2, and Tar3, which correspond to the three conditions of the best preventive measures respectively; After intervening in the parameters, the counterfactual structural causal model is used to obtain the counterfactual values of each parameter, assuming that it is Will Input the OCSVM model to obtain the probability of the event occurring, Tar1 is as follows: The selected intervention parameters should be as easy to operate as possible, Tar2 is as follows: Tar2=min|I T *do| (10); The symbol T represents the transpose of the matrix; set up represents the original value of the intervened variable, let As shown below: The objective function of the optimization algorithm is set as follows: Tar=w1Tar1+w2Tar2+w3Tar3 (12); w1, w2, and w3 represent the weights of each sub-objective function; S53: Generate a large number of initial intervention variables I and intervention values I according to the constraints V , generate I, I V Constraints of The optimization algorithm based on random search-adaptive particle swarm needs to set a large number of initial populations as candidate intervention measures. Let the initial population size be size. The population includes intervention variables and intervention values. Assume that the number of intervention variables I randomly generated by the above rules is s_size, that is, assume that the set of randomly generated intervention variables is {I1,…,I s_size }, the initial population size is s_size, and the intervention value is I V is the variable optimized by the optimization algorithm, and I is obtained. According to the counterfactual SCM, the possible world is calculated. Through the optimization algorithm based on random search-adaptive particle swarm, the optimal intervention measure I is finally obtained by judging whether the convergence condition is met. best , They represent the optimal intervention parameter and the optimal intervention value respectively, to find the optimal value to avoid the occurrence of the cause event.
7. The method for root cause analysis of adversarial simulation experiment results based on counterfactual reasoning according to claim 6, characterized in that: The best course of action described here meets the following three conditions: The best intervention needs to be able to successfully prevent the causal event from occurring; When selecting intervention parameters, it is necessary to ensure that the selected parameters are easy to intervene; The value of each intervention parameter must be within the normal value range of the parameter, and the closer to the original value of the parameter, the better.
8. The root cause analysis method of adversarial simulation experiment results based on counterfactual reasoning according to claim 6 is characterized in that: The constraints include: The intervention variable I is a binary array with a value of 0 or 1, where 0 represents no intervention and 1 represents intervention; Intervention Value I V is a real number array. For each parameter, there is a normal range. The intervention value is taken within the normal range of the corresponding parameter. V This is the final part to be optimized based on the random search-adaptive particle swarm optimization algorithm.
9. A method system for root cause analysis of adversarial simulation experiment results based on counterfactual reasoning, 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 steps of the method according to any one of claims 1 to 8 are implemented.
Citation Information
Patent Citations
Fault diagnosis method and system, electronic equipment and computer storage medium
CN116049642A
Cognitive disorder digital drug effect evaluation method based on anti-facts
CN116364307A
Anti-fact fairness prediction model training method, anti-fact fairness prediction method and anti-fact fairness prediction model training device
CN117610398A
Causal explanation of attention-based neural network output
US20230325628A1
Cited By
Cross-platform power transaction data interaction optimization method
CN120198166A
Activity strategy generation method and device, storage medium and electronic equipment
CN121258528A
Real-time interactive AI intervention method and device for military simulation
CN122713076A
