Fault diagnosis method and system for parallel power supply system
By building a fault diagnosis network of the parallel power supply system, using example software to control the path sequence and software to control the flow state diagram, the problems of inefficient fault diagnosis and misdiagnosis and misdiagnosis of the parallel power supply system are solved, and high accuracy and high efficiency fault diagnosis are achieved.
Patent Information
- Application Number
- CN202411081879.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-08
- Publication Date
- 2025-04-15
- Estimated Expiration
- 2044-08-08
AI Technical Summary
Fault diagnosis of parallel power systems has problems such as inefficiency and misdiagnosis in traditional methods. Especially due to its complex control logic and diverse fault types, the existing automated fault diagnosis methods still have limitations in practical applications.
By obtaining the example software control path sequence of the parallel power supply system, generating the software control flow state diagram, clustering and generating state diagrams, adjusting diagnostic knowledge points, and building a fault diagnosis network of the parallel power supply system to realize automatic identification and diagnosis of system faults.
It significantly improves the accuracy and efficiency of fault diagnosis of parallel power supply systems, realizes early detection and precise positioning of faults, reduces maintenance costs, and improves the overall operating stability and safety of the system.
Smart Images

Figure CN118760949B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence technology, and more specifically, to a fault diagnosis method and system for a parallel power supply system. Background Art
[0002] In the power system, the parallel power system is a key component, and its stability and reliability are directly related to the normal operation of the entire system. However, with the increasing complexity of the power system, fault diagnosis has become a very challenging task. Traditional fault diagnosis methods often rely on manual experience and field testing, which is not only inefficient, but also easily affected by human factors, resulting in frequent misdiagnosis or missed diagnosis.
[0003] In order to overcome the shortcomings of traditional fault diagnosis methods, artificial intelligence automated fault diagnosis technologies based on data and model-driven have gradually emerged in recent years. These artificial intelligence technologies collect a large amount of data during system operation and use data analysis, machine learning and other methods to automatically identify and diagnose system faults. However, for parallel power supply systems, due to the complexity of their control logic and the diversity of fault types, the existing automated fault diagnosis methods still have certain limitations in practical applications.
[0004] Specifically, the fault diagnosis of parallel power supply systems requires comprehensive consideration of the operating event sequence of the system control software, the software control path, and the interaction between the components. Traditional fault diagnosis methods often fail to fully capture this information, resulting in inaccurate diagnostic results. Summary of the invention
[0005] In view of the above-mentioned problems, in combination with the first aspect of the present application, an embodiment of the present application provides a fault diagnosis method for a parallel power supply system, the method comprising:
[0006] Obtaining a sample software control path sequence corresponding to a sample system control software running event sequence of a parallel power supply system; the sample software control path sequence includes a first sample software control path and a second sample software control path; the first sample software control path carries non-fault diagnosis knowledge points, and the second sample software control path carries fault diagnosis knowledge points;
[0007] Determine a software control flow state graph corresponding to each example software control path in the example software control path sequence, cluster the multiple software control flow state graphs corresponding to the example software control path sequence to generate multiple state graph groups, and determine a target state graph group based on the software control flow state graphs respectively corresponding to the multiple state graph groups;
[0008] Adjusting the diagnostic knowledge points of the first example software control path corresponding to the target state diagram group to the fault diagnosis knowledge points to generate a target example software control path sequence;
[0009] Based on the target example software control path sequence, parameter learning is performed on the initialization classification network to generate a parallel power system fault diagnosis network;
[0010] Obtain a candidate software control path of a candidate system control software running event, load the candidate software control path into the parallel power supply system fault diagnosis network, generate a fault diagnosis result, and if the fault diagnosis result reflects that the candidate software control path is a faulty software control path, output the candidate system control software running event as a faulty system control software running event.
[0011] On the other hand, an embodiment of the present application also provides a fault diagnosis system, including a processor and a machine-readable storage medium, wherein the machine-readable storage medium is connected to the processor, the machine-readable storage medium is used to store programs, instructions or codes, and the processor is used to execute the programs, instructions or codes in the machine-readable storage medium to implement the above method.
[0012] Based on the above aspects, the embodiment of the present application significantly improves the accuracy and efficiency of fault diagnosis of parallel power supply system by comprehensively utilizing the example software control path sequence, software control flow state diagram and deep learning technology. Specifically, firstly, by distinguishing and adjusting the example software control path carrying different knowledge points, a target example software control path sequence that is closer to the actual fault scenario is generated. Subsequently, the initialization classification network is parameterized using these target path sequences, and a parallel power supply system fault diagnosis network is successfully constructed. The parallel power supply system fault diagnosis network can not only automatically identify and distinguish the system control software running events under normal and fault states, but also respond quickly when a fault is detected, and output specific fault system control software running events, thereby realizing early detection and precise positioning of the fault. In addition, by clustering to generate state diagram groups and determining target state diagram groups, redundant information is effectively reduced, the efficiency of data processing and analysis is improved, and the real-time and reliability of fault diagnosis are further enhanced. Thus, an intelligent and automated solution is provided for fault diagnosis of parallel power supply systems, which significantly reduces maintenance costs and improves the overall operation stability and safety of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] Figure 1 It is a schematic diagram of the execution flow of the fault diagnosis method for the parallel power supply system provided in an embodiment of the present application.
[0014] Figure 2It is a schematic diagram of the hardware architecture of the fault diagnosis system provided in the embodiment of the present application. DETAILED DESCRIPTION
[0015] The present application will be described in detail below with reference to the accompanying drawings. Figure 1 It is a flow chart of a fault diagnosis method for a parallel power supply system provided by an embodiment of the present application. The fault diagnosis method for a parallel power supply system is introduced in detail below.
[0016] Step S110, obtaining a sample software control path sequence corresponding to a sample system control software running event sequence of a parallel power supply system. The sample software control path sequence includes a first sample software control path and a second sample software control path. The first sample software control path carries non-fault diagnosis knowledge points, and the second sample software control path carries fault diagnosis knowledge points.
[0017] In this embodiment, the server first connects to the historical database of the parallel power supply system, and obtains the example control software operation event sequence of the parallel power supply system. These example control software operation event sequences are a series of states and operation instructions recorded by the control software during the past operation of the power supply system. They are arranged in chronological order and reflect the behavior and control flow of the system in a specific time period.
[0018] The server preprocesses these example control software running event sequences, including cleaning noise and irrelevant data, to ensure the accuracy and consistency of the data. Then, the server converts the preprocessed data into an example software control path sequence, which includes two example software control paths: a first example software control path and a second example software control path.
[0019] The first example software control path carries non-fault diagnosis knowledge points, that is, the control process and behavior characteristics of the parallel power system under normal operation. For example, it may describe how the parallel power system gradually starts each component after receiving the power-on command, as well as the interaction and state changes between the components.
[0020] The second example software control path carries fault diagnosis knowledge points, that is, the control process and behavior characteristics of the power system when an abnormality or failure occurs. For example, it may describe how the power system triggers the fault protection mechanism, shuts down the faulty component, and sends an alarm message to the maintenance personnel when it detects that the temperature of a component is too high.
[0021] Step S120, determining the software control flow state diagram corresponding to each example software control path in the example software control path sequence, clustering the multiple software control flow state diagrams corresponding to the example software control path sequence, generating multiple state diagram groups, and determining the target state diagram group based on the software control flow state diagrams corresponding to the multiple state diagram groups.
[0022] In this embodiment, the server then analyzes the two example software control paths to determine their corresponding software control flow state diagrams. The software control flow state diagram is a graphical tool for describing the system state, which can better understand the control logic and state changes of the system.
[0023] For each example software control path, the server will generate a corresponding software control flow state diagram, which includes a series of nodes and edges. The nodes represent different states of the system, and the edges represent the transition relationship between states. For example, in the state diagram of the first example software control path, there may be a node representing "power system starting up" and another node representing "power system normal operation", and there is an edge between them to represent the transition from the "starting up" state to the "normal operation" state.
[0024] Then, the server will perform clustering operations based on the similarities and differences of these software control flow state diagrams to generate multiple state diagram groups. The purpose of clustering is to group state diagrams with similar control logic and state changes into one category for subsequent analysis and processing. The server will use a clustering algorithm to group these software control flow state diagrams, grouping similar software control flow state diagrams into one category to form different state diagram groups.
[0025] Finally, the server determines the target state diagram grouping based on the software control flow state diagrams corresponding to the multiple state diagram groups. The target state diagram grouping should be representative and reflect the typical control flow and behavior characteristics of the power system under specific operating conditions. For example, if the current focus is to improve the power system's ability to diagnose overheating faults, the server will select the state diagram grouping that contains the overheating fault handling logic as the target state diagram grouping.
[0026] Step S130 , adjusting the diagnostic knowledge points of the first example software control path corresponding to the target state diagram group to the fault diagnosis knowledge points, and generating a target example software control path sequence.
[0027] In this embodiment, after determining the target state diagram group, the server will adjust the non-fault diagnosis knowledge points (i.e., control logic and behavior characteristics under normal operation) originally carried by the first example software control path corresponding to the target state diagram group to fault diagnosis knowledge points. Thus, these paths are re-labeled or interpreted based on the target state diagram group (usually containing control logic related to a specific fault) so that they can reflect the control process and behavior characteristics of the power supply system under fault conditions.
[0028] In this way, a new target example software control path sequence is generated. The path in the target example software control path sequence not only contains the control logic of the power system under normal operation (provided by the second example software control path), but also indirectly contains the control logic and state change information when a fault occurs by adjusting the diagnostic knowledge points. Such a target example software control path sequence provides a richer and more comprehensive data foundation for subsequent fault diagnosis network training.
[0029] Step S140 , performing parameter learning on the initialization classification network based on the target example software control path sequence to generate a parallel power system fault diagnosis network.
[0030] In this embodiment, after generating the target example software control path sequence, the server can start training the fault diagnosis network, the goal of which is to learn how to diagnose the fault of the power system based on the software control path.
[0031] The server first selects a suitable deep learning framework and algorithm to build an initial classification network. Then, it uses the paths in the target example software control path sequence as input data and the corresponding fault diagnosis results as label data to train the network. By continuously learning and adjusting network parameters, the server will gradually improve the network's ability to diagnose power system faults.
[0032] During the training process, the server will use some optimization algorithms and regularization techniques to improve the performance and generalization ability of the network. For example, the gradient descent algorithm can be used to accelerate the network training process, and the dropout technology can be used to reduce the overfitting phenomenon of the network. At the same time, the server will also divide the training data and use the cross-validation method to evaluate the performance and stability of the network.
[0033] Finally, the server will generate a parallel power system fault diagnosis network, which can accurately diagnose the fault type and cause of the power system according to the input software control path. In practical applications, this parallel power system fault diagnosis network can be used as an important tool for power system fault diagnosis, helping maintenance personnel to quickly and accurately locate and solve problems.
[0034] Step S150, obtaining a candidate software control path of a candidate system control software running event, loading the candidate software control path into the parallel power supply system fault diagnosis network, generating a fault diagnosis result, and if the fault diagnosis result reflects that the candidate software control path is a faulty software control path, outputting the candidate system control software running event as a faulty system control software running event.
[0035] In this embodiment, after the fault diagnosis network is trained, the server can start actual application. For example, new candidate system control software running events can be continuously obtained and corresponding candidate software control paths can be generated. Then, the server will load this candidate software control path into the fault diagnosis network to generate a fault diagnosis result.
[0036] If the fault diagnosis result shows that the candidate software control path represents a fault state, the server will output the corresponding candidate system control software operation event as a faulty system control software operation event and perform corresponding processing. For example, an alarm can be issued to notify maintenance personnel to check and repair, or a backup system can be automatically started to ensure continuous operation of the system.
[0037] If the fault diagnosis result shows that the candidate software control path does not represent any fault status, the server will regard the corresponding candidate system control software operation event as a normal event and continue to monitor the operation status of the power system. In this way, the server can realize real-time fault diagnosis and monitoring of the power system, improving the reliability and stability of the system.
[0038] Based on the above steps, the embodiment of the present application significantly improves the accuracy and efficiency of fault diagnosis of parallel power supply system by comprehensively utilizing the example software control path sequence, software control flow state diagram and deep learning technology. Specifically, firstly, by distinguishing and adjusting the example software control path carrying different knowledge points, a target example software control path sequence that is closer to the actual fault scenario is generated. Subsequently, these target path sequences are used to perform parameter learning on the initialization classification network, and a parallel power supply system fault diagnosis network is successfully constructed. The parallel power supply system fault diagnosis network can not only automatically identify and distinguish the system control software running events under normal and fault states, but also respond quickly when a fault is detected, and output specific fault system control software running events, thereby realizing early detection and precise positioning of the fault. In addition, by clustering to generate state diagram groups and determining target state diagram groups, redundant information is effectively reduced, the efficiency of data processing and analysis is improved, and the real-time and reliability of fault diagnosis are further enhanced. Thus, an intelligent and automated solution is provided for fault diagnosis of parallel power supply systems, which significantly reduces maintenance costs and improves the overall operation stability and safety of the system.
[0039] In a possible implementation, step S120 includes:
[0040] Step S121 , determining the path vector correlation between the first example software control path and the second example software control path according to the software control flow state diagrams corresponding to the first example software control path and the second example software control path respectively.
[0041] Step S122 , clustering the multiple path vector associations corresponding to the example software control path sequence to generate the multiple state diagram groups.
[0042] The determining the target state diagram grouping based on the software control flow state diagrams respectively corresponding to the multiple state diagram groups includes: determining the target state diagram grouping based on the path vector associations respectively corresponding to the multiple state diagram groups.
[0043] In this embodiment, the server first needs to vectorize each software control flow state graph, that is, convert the nodes and edges in the software control flow state graph into numerical vectors. This can be achieved through graph embedding technology, such as Node2Vec, Graph Convolutional Networks (GCN), etc. These technologies can map the nodes in the software control flow state graph to a low-dimensional vector space while retaining the structural information between the nodes.
[0044] For the state diagrams of the first example software control path and the second example software control path, the server calculates their vector representations respectively, and then uses cosine similarity, Euclidean distance or other similarity measurement methods to calculate the association degree between the two vectors, i.e., the path vector association degree, which reflects the similarity between the two state diagrams in control logic and structure.
[0045] For example, suppose the state diagram of the first example software control path mainly describes the normal startup process of the power system, while the state diagram of the second example software control path describes the processing process of overheating faults. The server converts these two state diagrams into vectors V1 and V2 through graph embedding technology, and then calculates the cosine similarity between V1 and V2 as their path vector correlation. Since these two processes have significant differences in structure and control logic, their path vector correlation will be relatively low.
[0046] Next, the server uses a clustering algorithm (such as K-means, DBSCAN, etc.) to cluster all path vector associations. The clustering algorithm groups the state graphs according to the similarity and difference of the associations, so that the state graphs in the same group have a high similarity, while the similarity between different groups is low. During the clustering process, the server sets appropriate clustering parameters (such as the number of clusters, distance threshold, etc.) to ensure that the clustering results are neither too detailed nor too general. The server calculates the association between each state graph and other state graphs and assigns them to different clusters based on the association.
[0047] For example, the server uses the K-means algorithm to cluster the path vector associations of all state graphs, and sets the number of clusters to 3. Through iterative calculations, the server eventually divides the state graphs into three groups: one group contains state graphs describing the normal startup process, one group contains state graphs describing the overheating fault handling process, and another group can contain state graphs describing other types of fault handling processes.
[0048] After completing the clustering operation, the server obtains multiple state graph groups, and the state graphs in each state graph group have similar control logic and structure. Next, the server needs to determine the target state graph group according to specific requirements.
[0049] In detail, the server analyzes the path vector correlation of each state graph group to understand the similarity of the state graphs within each state graph group and the differences between groups. By comparing the correlation distribution of different groups, the server can preliminarily determine which groups can contain the target state graph.
[0050] For example, the server found that the state graph group describing the overheating fault handling process has a low intra-group correlation variation (that is, the similarity between the state graphs within the group is high) and a significant difference in correlation with other groups, which indicates that the group is likely to contain the target state graph related to the overheating fault.
[0051] Based on specific requirements (such as improving the diagnostic capability of overheating faults), the server will select the state diagram group containing relevant control logic as the target state diagram group. In this process, the server may combine domain knowledge, expert opinions or historical data to assist in the judgment.
[0052] For example, assuming that the current focus is to improve the power supply system's ability to diagnose overheating faults, the server will select the state diagram grouping that contains the overheating fault handling process as the target state diagram grouping. The state diagram in this group describes in detail the control process and behavioral characteristics of the power supply system when an overheating fault is detected, and is an important data basis for subsequent fault diagnosis network training.
[0053] To ensure that the selected target state graph grouping meets actual needs, the server may further verify and adjust it, which can be achieved by communicating with domain experts, analyzing historical failure cases, or using cross-validation. For example, the server compares and analyzes the state graphs in the target state graph grouping with known overheating failure cases and finds that they are highly consistent in control logic and structure, which indicates that the target state graph grouping selected by the server is accurate and effective. If problems or deficiencies are found during the verification process, the server will adjust the grouping or reselect the target state graph grouping in a timely manner.
[0054] In another possible implementation, the determining of the target state diagram grouping based on the software control flow state diagrams corresponding to the multiple state diagram groups may also include: outputting the state diagram group including the faulty software control flow state diagram among the multiple state diagram groups as the target state diagram group.
[0055] The step of determining the fault software control flow state diagram includes:
[0056] Step A110, obtaining a set software control path sequence corresponding to a set system control software running event sequence, wherein the set software control path sequence includes setting a non-faulty software control path and setting a faulty software control path.
[0057] Step A120, determining a software control flow state diagram corresponding to each set software control path in the set software control path sequence.
[0058] Step A130 , clustering the plurality of set software control flow state diagrams corresponding to the set software control path sequence to generate a plurality of set state diagram groups.
[0059] Step A140, determining the weight of the setting fault software control path corresponding to each setting state diagram group.
[0060] Step A150, grouping the set state graphs whose weights of the set fault software control paths are greater than the first threshold value, and outputting them as fault state graph groups.
[0061] Step A160: output the setting software control flow state diagram in the fault state diagram group as the fault software control flow state diagram.
[0062] In this embodiment, the server first connects to the setting database or simulation environment of the parallel power supply system, and obtains a series of setting system control software operation event sequences from it. These event sequences are pre-designed and used to simulate the operation state of the power supply system under specific conditions, including normal state and fault state. For example, the server obtains event sequences including power supply system startup, stable operation, overload protection triggering and other stages. These event sequences record in detail the instructions received by the system control software at each stage, the operations performed and the state changes generated.
[0063] Next, the server analyzes the acquired set system control software operation event sequence, and generates the corresponding set software control path sequence based on the logical relationship and time sequence between the events. These path sequences include setting non-fault software control paths (such as normal startup paths) and setting fault software control paths (such as overload protection paths).
[0064] For example, after analyzing the event sequence, the server generates a set non-fault software control path including "receiving the start command->component initialization->system stable operation" and a set fault software control path including "load increase->overload detection->cutting off the fault source->sending an alarm".
[0065] For each path in the set software control path sequence, the server will generate a corresponding software control flow state diagram. These state diagrams represent different states of the system and the conversion relationships between states through nodes and edges.
[0066] For example, the server generates a state graph for setting a non-faulty software control path, which includes nodes such as "initial state", "starting state", and "stable operation state", as well as the transition edges between these nodes. Similarly, a state graph containing nodes such as "normal operation state", "overload detection state", "fault isolation state", and "alarm sending state" is generated for setting a faulty software control path.
[0067] The server uses clustering algorithms (such as K-means, DBSCAN, etc.) to cluster all the setting software control flow state graphs and group them according to the similarities and differences between the state graphs. For example, the server clusters all the generated setting software control flow state graphs and divides them into multiple setting state graph groups according to the types and numbers of nodes in the state graphs and the conversion relationships between the nodes. These groups may include "normal operation process grouping", "fault handling process grouping", etc.
[0068] In each set state diagram group, the server calculates the weight of each set fault software control path. The weight calculation can be based on factors such as the complexity of the path, its importance in fault handling, and the frequency of occurrence in historical fault records. For example, in the "Fault Handling Process Group", the server calculated the weights of the "Overload Protection Path" and the "Short Circuit Protection Path". Since overload is a common type of fault in the power supply system, and the operations and state transitions involved in the "Overload Protection Path" are relatively complex, the server gives it a higher weight.
[0069] The server sets a first threshold value for filtering the set state diagram group containing important fault handling processes. The set state diagram group whose weight of the set fault software control path is greater than the first threshold value is output as the fault state diagram group. For example, the server sets the weight threshold value to 0.8, and after comparison, it is found that the weight of the "overload protection path" is 0.9, which is greater than the threshold value. Therefore, the server outputs the set state diagram group containing the "overload protection path" as the fault state diagram group.
[0070] Finally, the server outputs all the set software control flow state diagrams in the fault state diagram group as fault software control flow state diagrams, which will serve as an important data basis for subsequent fault diagnosis network training. For example, the server outputs the software control flow state diagram corresponding to the "overload protection path", which describes in detail the control process and behavior characteristics of the power system when an overload fault is detected, including key information such as state transitions and operation instructions.
[0071] Through the above steps, the target state diagram group containing the faulty software control flow state diagram is determined from multiple state diagram groups, providing accurate and effective data support for subsequent fault diagnosis network training.
[0072] In a possible implementation, step A130 includes:
[0073] Step A131, determining the set path vector correlation between the set non-faulty software control path and the set faulty software control path according to the set software control flow state diagrams respectively corresponding to the set non-faulty software control path and the set faulty software control path.
[0074] Step A132: clustering is performed based on the correlation degrees of the multiple setting path vectors corresponding to the setting software control path sequence to generate the multiple setting state diagram groups.
[0075] The method further includes: outputting the sampling path vector association degree in the fault state diagram group as a set association degree. The sampling path vector association degree in the fault state diagram group is less than a first association degree. The first association degree is the association degree in the fault state diagram group other than the sampling path vector association degree.
[0076] Determining the target state diagram grouping based on the path vector associations corresponding to the plurality of state diagram groups, comprises: determining the target path vector association in each state diagram grouping. The target path vector association in any one of the state diagram groups is less than a second association in the any one of the state diagram groups. The second association in any one of the state diagram groups is an association in the any one of the state diagram groups other than the target path vector association. The state diagram grouping whose target path vector association is not greater than the set association is output as the target state diagram grouping.
[0077] In this embodiment, the server has obtained the set system control software running event sequence and generated the corresponding set software control path sequence, including the set non-fault software control path and the set fault software control path. Next, the server needs to calculate the set path vector correlation between the set software control flow state diagrams corresponding to these paths.
[0078] The server first generates a corresponding software control flow state diagram for each set software control path. These software control flow state diagrams represent the system status and its conversion relationship through nodes and edges.
[0079] Next, graph embedding techniques (such as Node2Vec, GraphSAGE, etc.) are used to convert each state graph into a low-dimensional numerical vector, namely, the vector representation of the state graph, which can capture the structural information and key features of the state graph.
[0080] For each pair of state graphs of the set non-faulty software control path and the set faulty software control path, the server calculates the similarity between their corresponding vectors as the set path vector association degree. Commonly used similarity measurement methods include cosine similarity, Euclidean distance, etc.
[0081] For example, suppose the server generates a state graph A of a set non-faulty software control path representing a normal startup process, and a state graph B of a set faulty software control path representing an overload protection process. Through graph embedding technology, the server converts A and B into vectors VA and VB, respectively. Subsequently, the server calculates the cosine similarity between VA and VB to obtain the set path vector association rAB. Since A and B are quite different in structure and function, the value of rAB will be relatively low.
[0082] The server has calculated the correlations of multiple setting path vectors. Next, it is necessary to perform clustering operations on the setting software control flow state graph according to these correlations to generate multiple setting state graph groups.
[0083] In detail, the server selects an appropriate clustering algorithm (such as K-means, DBSCAN, etc.) and sets clustering parameters (such as the number of clusters, distance threshold, etc.). Then, the set path vector relevance is used as input to execute the clustering algorithm. The algorithm will assign state graphs to different clusters based on the similarity and difference of the relevance. After clustering is completed, the server obtains multiple set state graph groups, and the state graphs in each set state graph group have high similarity in structure and function. For example, the server uses the K-means algorithm to cluster the set path vector relevance, and sets the number of clusters to 3. After clustering is completed, the server obtains three set state graph groups: Group 1 contains state graphs for normal operation processes, Group 2 contains state graphs for various fault handling processes, and Group 3 can contain state graphs for some special cases or edge cases.
[0084] After determining the fault state graph group, the server needs to select a sampling path vector correlation degree from the fault state graph group as a benchmark for subsequent comparison, that is, set the correlation degree.
[0085] In detail, the server calculates the path vector correlations of all state graph pairs in the fault state graph group. Then, a relatively small value is selected from these path vector correlations as the sampled path vector correlation, which should be smaller than most other correlations in the group to ensure its representativeness.
[0086] Analysis: The server outputs the sampling path vector correlation as the set correlation for the subsequent target state graph grouping determination process. For example, in the fault state graph grouping, the server calculates the path vector correlation of all state graph pairs and selects the smallest value as the sampling path vector correlation, denoted as rSample. This value reflects the minimum similarity between the fault handling process state graphs and is used as the set correlation for subsequent comparisons.
[0087] The server has obtained multiple state graph groups and their corresponding path vector correlations, and now needs to determine the target state graph group according to these correlations, that is, the state graph group containing the key fault handling process.
[0088] In detail, for each state diagram group, the server determines a target path vector correlation, which should be a relatively small one among all correlations within the state diagram group to ensure that it can reflect the typical similarity between the state diagrams within the state diagram group. Then, the target path vector correlation of each state diagram group is compared with the set correlation. If the target path vector correlation is not greater than the set correlation, it means that the state diagram within the state diagram group is structurally similar to the fault handling process state diagram and may be a target state diagram group. Thus, the state diagram group that meets the conditions can be output as a target state diagram group.
[0089] For example, for the three set state graph groups obtained previously, the server calculated their target path vector correlations respectively. Assume that the target path vector correlation rTarget2 of group 2 (fault handling process group) is less than or equal to the set correlation rSample, while the target path vector correlations of group 1 and group 3 are greater than rSample. Therefore, the server outputs group 2 as the target state graph group, assuming that it contains the key fault handling process state graph.
[0090] In a possible implementation, the method further includes:
[0091] Step B110: determining software control node sequences corresponding to the first example software control path and the second example software control path respectively.
[0092] Step B120 , determining a target shared software control path of the first example software control path and the second example software control path according to the software control node sequences corresponding to the first example software control path and the second example software control path respectively.
[0093] Step B130 , determining the path unit values corresponding to the first example software control path and the second example software control path respectively.
[0094] Step B140, determining a first node association degree between the first example software control path and the second example software control path based on the path unit values respectively corresponding to the first example software control path and the second example software control path and the target shared software control path.
[0095] Step B150: determining the shared software control nodes of the first example software control path and the second example software control path according to the software control node sequences corresponding to the first example software control path and the second example software control path respectively.
[0096] Step B160: determining a second node association degree between the first example software control path and the second example software control path based on the path unit values corresponding to the first example software control path and the second example software control path and the shared software control node.
[0097] Step B170, determining the encoding vector weights corresponding to the first example software control path and the second example software control path respectively according to the software control node sequences corresponding to the first example software control path and the second example software control path respectively.
[0098] Step B180: determining a third node association degree between the first example software control path and the second example software control path according to the code vector weights corresponding to the first example software control path and the second example software control path respectively.
[0099] Step B190: determining the node association between the first example software control path and the second example software control path based on the first node association, the second node association, and the third node association.
[0100] Step S122 includes: clustering a plurality of path vector associations and a plurality of node associations corresponding to the example software control path sequence to generate the plurality of state diagram groups.
[0101] In this embodiment, the server first parses the first example software control path and the second example software control path, converts the software control operations in each path into a series of software control nodes, and thus generates a corresponding software control node sequence.
[0102] In detail, the server reads the detailed steps of the first example software control path, such as "start power->initialize components->stable operation", and converts these steps into a software control node sequence, such as [node 1: start power, node 2: initialize components, node 3: stable operation]. Similarly, the server reads the detailed steps of the second example software control path, such as "fault detected->isolate faulty components->send alarm", and generates a corresponding software control node sequence, such as [node A: fault detected, node B: isolate faulty components, node C: send alarm].
[0103] The server analyzes the node sequences of the two example software control paths, finds out the possible shared control processes or nodes between them, and forms a target shared software control path.
[0104] In detail, the server compares the two node sequences and finds that there is no direct node name that is the same, but there may be logically similar control processes, such as the "initialization component" may be implicit in the preparation work before fault handling. Based on domain knowledge and expert judgment, the server assumes that the "initialization component" is a shared process, but due to the different names, the server marks this part as logically shared and does not directly generate a shared node sequence, but considers it in the subsequent correlation calculation.
[0105] The server assigns a path unit value to each node, which reflects the importance or complexity of the node in the path. Then, based on the path unit value and the target shared software control path (logically), the first node relevance is calculated.
[0106] In detail, the server assigns a path unit value to each node. For example, node 1 (starting power) may have a higher unit value because it is the starting point of the path and is critical. Since there is no direct target shared node sequence, the server calculates a hypothetical first node relevance based on the logical shared flow (such as the concept of initializing components) and the path unit value. The relevance reflects the similarity of the logical flow between paths.
[0107] Although the direct node names may be different, the server attempts to identify nodes with similar functions or roles as shared software control nodes and calculates the second node association based on these nodes and the path unit value.
[0108] In detail, the server identifies nodes with similar functions through domain knowledge or node descriptions, such as "initialization components" and certain preparatory nodes before fault handling, which may be considered shared. For the shared nodes actually identified, the server calculates the second node association degree based on the path unit values of these nodes, and the second node association degree directly reflects the importance of the shared nodes in the two paths.
[0109] Next, the server generates encoding vectors for each node and assigns weights based on the similarity or importance of these vectors. Then, the third node association degree is calculated based on the encoding vector weights.
[0110] In detail, the server generates a coding vector for each node using graph embedding technology. Weights are assigned according to the similarity of the coding vectors and the role of the node in the path. Based on the coding vector weights, the server calculates the third node association degree, which measures the similarity between nodes from the perspective of vector space.
[0111] The server calculates the total node association of the first example software control path and the second example software control path based on the first node association, the second node association and the third node association. Then, clustering is performed based on the node association and path vector association of multiple paths to generate state diagram groups.
[0112] In detail, the server synthesizes the three node associations according to a certain weight ratio (such as equal weight or adjusted according to importance) to obtain the total node association. Then, the path vector association and node association are used as input features, and a clustering algorithm (such as K-means) is used to cluster all paths. After clustering, the server obtains multiple state graph groups, and the paths in each state graph group have high similarity in control logic, node similarity, and overall structure.
[0113] As a result, the relationship between the control paths of the example software can be analyzed more carefully, providing more accurate data grouping for subsequent fault diagnosis network training.
[0114] In a possible implementation, the method further includes:
[0115] Step C110, configuring a first setting execution instance corresponding to a software control node sequence in the example software control path. The first setting execution instance includes editing the software control nodes of the assignment type operation code into a first coding vector, editing the software control nodes of the determination type operation code into a second coding vector, and editing the software control nodes of the loop type operation code into a third coding vector.
[0116] The determining of the software control flow state diagram corresponding to each example software control path in the example software control path sequence includes:
[0117] According to the first setting execution instance, each example software control path in the example software control path sequence is converted into a first software control flow state diagram.
[0118] According to the first software control flow state diagram corresponding to each of the example software control paths, the software control flow state diagram corresponding to each of the example software control paths is determined.
[0119] ,In this embodiment, when processing the example software control path, the server first needs to configure an ,execution instance to convert the software control nodes in the example software ,control path into different encoding vectors according to their operation code types. ,This conversion helps to subsequently generate a structured software control ,flow state diagram.
[0120] In detail, the server defines rules for the first set execution instance, which specify how software control nodes of different types of opcodes should be converted into encoding vectors. Specifically, the rules include:
[0121] The software control nodes of assignment type operation codes (such as variable assignment, parameter setting, etc.) are edited into the first encoding vector.
[0122] The software control nodes of the judgment type operation codes (such as condition judgment, branch selection, etc.) are edited into the second encoding vector.
[0123] Software control nodes of loop-type operation codes (such as loop start, loop end, operations within the loop body, etc.) are compiled into a third encoding vector.
[0124] Next, define a specific encoding scheme for each type of encoding vector, which may involve assigning a unique identifier to each opcode, and defining the length, structure, and other properties of the encoding vector. For example, the first encoding vector may be a fixed-length vector containing fields representing assignment type, assignment target, assignment value, and other information; the second encoding vector may contain fields such as conditional expressions and branch selections; and the third encoding vector may contain fields such as loop type, loop counter, and key operations in the loop body.
[0125] After configuring the first set execution instance, the server begins to convert each path in the example software control path sequence into a corresponding software control flow state diagram. This process is divided into two main steps: first, the path is converted into a first software control flow state diagram, and then the final software control flow state diagram is determined based on this preliminary state diagram.
[0126] In detail, the server reads the first example software control path in the example software control path sequence. Then, each software control node in the example software control path is traversed, and the node is converted into a corresponding encoding vector according to the node's operation code type (assignment type, judgment type, loop type) and the rule of the first set execution instance. Using these encoding vectors as nodes, and according to the execution order and logical relationship of the nodes in the path (such as sequential execution, conditional branching, loop iteration, etc.), a preliminary software control flow state diagram is constructed, that is, the first software control flow state diagram, which uses encoding vectors as nodes and directed edges between nodes to represent the execution order and logical relationship.
[0127] Then, the first software control flow state diagram is optimized and organized, which may include removing redundant nodes, merging similar nodes, adjusting the direction of edges, etc., to ensure that the state diagram is both concise and accurately reflects the control logic of the path. As needed, the server can also add additional labels or attributes to the nodes and edges in the state diagram, such as operation code name, execution condition, number of loops, etc., for use in subsequent analysis. Finally, the server determines the optimized state diagram as the software control flow state diagram corresponding to the example software control path, and stores it in the database for subsequent use.
[0128] Through this process, the example software control path can be converted into a structured software control flow state diagram, providing strong data support for subsequent fault diagnosis network training.
[0129] In a possible implementation, the method further includes:
[0130] Step C120, configure the second set execution instance corresponding to the software control node sequence. The second set execution instance is an execution space configured with a set length. Wherein, the set length corresponds to a set number of unit slots, and the set number of unit slots includes multiple first unit slots and multiple second unit slots. Each first unit slot corresponds to an assignment class operation code, and the encoding vector in each first unit slot is used to reflect whether there is an assignment class operation code corresponding to each first unit slot in the software control node sequence. Each second unit slot corresponds to a non-assignment class operation code software control node. Non-assignment class operation codes include judgment class operation codes and loop class operation codes. The encoding vector in each second unit slot is used to reflect whether there is a non-assignment class operation code corresponding to each second unit slot in the software control node sequence.
[0131] Determining the software control flow state diagram corresponding to each example software control path according to the first software control flow state diagram corresponding to each example software control path includes:
[0132] According to the second setting execution instance, each of the example software control paths is converted into a second software control flow state diagram.
[0133] According to the first software control flow state diagram and the second software control flow state diagram corresponding to each of the example software control paths, the software control flow state diagram corresponding to each of the example software control paths is determined.
[0134] In this embodiment, when further processing the software control node sequence, the server configures a second set execution instance, which defines an execution space with a set length for efficiently representing and querying the operation code type in the node sequence. The execution space is divided into multiple unit slots, each slot corresponds to a different type of operation code, and a coding vector is used to mark whether there is an operation code of the corresponding type in the node sequence.
[0135] In detail, the set length of the execution space and the unit slot allocation are first determined. Based on historical data and domain knowledge, the server pre-sets a reasonable execution space length, which should be sufficient to cover the needs of most software control node sequences. Then, the server divides the execution space into multiple unit slots, including multiple first unit slots (corresponding to assignment type opcodes) and multiple second unit slots (corresponding to non-assignment type opcodes, such as judgment type and loop type opcodes).
[0136] Next, configure the encoding vector for each unit slot. For each first unit slot, the server defines an encoding vector in which each element (or bit) corresponds to a specific assignment opcode. If the opcode exists in the node sequence, the corresponding element is set to a specific value (such as 1), otherwise it is set to another value (such as 0). Similarly, for each second unit slot, the server also defines an encoding vector to mark the existence of non-assignment opcodes.
[0137] Then, the rules and coding scheme of the second set execution instance are stored in an internal database so as to be directly called when processing a specific example software control path.
[0138] After configuring the second setting execution instance, the server begins to use this second setting execution instance to further transform the example software control path and generate a more refined software control flow state diagram. This process combines the first software control flow state diagram and the second software control flow state diagram generated previously.
[0139] The server reads a sample software control path and traverses the software control node sequence therein. For each node in the software control node sequence, the server finds the corresponding unit slot in the execution space of the second set execution instance according to its opcode type (assignment type, judgment type, loop type). The server updates the encoding vector in the unit slot and sets the corresponding element to a value indicating the existence of the opcode. By traversing the entire node sequence and updating the encoding vector in the execution space, the server constructs a second software control flow state diagram, which is based on the unit slot and encoding vector, and intuitively shows the existence and distribution of opcodes in the node sequence.
[0140] The server has generated a first software control flow state diagram and a second software control flow state diagram for each example software control path. The first state diagram focuses on the execution order and logical relationship of the nodes, while the second state diagram focuses on the existence and distribution of the operation code.
[0141] The server merges the two state graphs. During the merging process, the server may retain the nodes and edges in the first state graph as the main skeleton of the state graph, and add the encoding vector information in the second state graph as additional attributes to the corresponding nodes or edges.
[0142] After the merger is completed, the server obtains a more complete and refined software control flow state diagram, which not only includes the execution order and logical relationship of the nodes, but also clearly shows the existence and distribution of the opcodes through the encoding vector, providing richer information for subsequent analysis and processing.
[0143] In a possible implementation, the method further includes:
[0144] Step C130, configuring a third setting execution instance corresponding to the software control node sequence. The third setting execution instance includes dividing the software control node sequence into two software control node sub-sequences according to the target software control node in the software control node sequence. Converting the two software control node sub-sequences into software control flow state sub-graphs respectively according to the first setting execution instance.
[0145] Step C140, determining the weighted calculation results of the two software control flow state subgraphs, and generating a software control flow state graph.
[0146] Determining the software control flow state diagram corresponding to each example software control path according to the first software control flow state diagram and the second software control flow state diagram corresponding to each example software control path includes:
[0147] According to the third setting execution instance, each of the example software control paths is converted into a third software control flow state diagram.
[0148] According to the first software control flow state diagram, the second software control flow state diagram and the third software control flow state diagram corresponding to each of the example software control paths, the software control flow state diagram corresponding to each of the example software control paths is determined.
[0149] In this embodiment, in order to further analyze the structure and characteristics of the software control node sequence, the server configures a third setting execution instance, which allows the server to split the node sequence into two subsequences according to a specific target software control node, and convert the two subsequences into software control flow state subgraphs respectively. Finally, a comprehensive software control flow state graph is generated by weighted calculation of the two subgraphs.
[0150] In detail, the target software control node is first determined. The server determines one or more key target software control nodes based on domain knowledge, historical data or user specification. These nodes usually have special meanings in the software control process, such as decision points, branch points or loop starting points.
[0151] Then, the software control node sequence is split. The server traverses the software control node sequence and finds the positions of all target software control nodes. Then, the node sequence is split into two subsequences based on these positions. If there are multiple target nodes, the server can select one of them as the split point, or split each target node once to generate multiple subsequences.
[0152] The subsequences are converted into software control flow state subgraphs. For each subsequence, the server converts the subsequences into corresponding software control flow state subgraphs according to the first set execution instance (i.e., the rules for converting assignment type, judgment type, and loop type opcodes into different encoding vectors). This process is similar to the method for generating the first software control flow state graph, but processes the segmented subsequences.
[0153] After obtaining the two software control flow state subgraphs, the server needs to determine the relative importance or contribution between the two subgraphs and merge them into a comprehensive software control flow state graph through weighted calculation.
[0154] In detail, the weighted calculation rules are first determined. The server assigns different weights to the two subgraphs based on domain knowledge, historical data, or user preferences. The weight assignment can be based on factors such as the number of nodes contained in the subgraph, the complexity of the operation code, and the importance of the subgraph in the overall process.
[0155] Then, weighted calculation is performed. The server performs weighted summation or weighted merging operations on the two software control flow state subgraphs according to the determined weighted calculation rules. This process may involve direct weighting of nodes, edges or encoding vectors in the subgraphs, or may involve more complex graph structure merging algorithms.
[0156] Finally, a comprehensive software control flow state diagram is generated. After the weighted calculation is completed, the server obtains a comprehensive software control flow state diagram, which not only contains the information of the two sub-graphs, but also reflects the relative importance between the sub-graphs through weighted calculation. The state diagram can be used for subsequent analysis, visualization or as input data for the fault diagnosis network.
[0157] In the previous steps, the server has generated the first, second and third software control flow state diagrams for each example software control path. Now, the server needs to combine these state diagrams to generate a more comprehensive and accurate software control flow state diagram.
[0158] In detail, first, integrate the state graph information. The server first extracts the key information in each state graph (first, second, third), such as nodes, edges, encoding vectors, weighted results, etc., which will serve as the basis for the subsequent merging of state graphs.
[0159] Then, determine the merging strategy. The server determines a suitable merging strategy based on the characteristics of the state graph and demand analysis. The strategy may involve merging nodes and edges, superposition of coding vectors, averaging or selecting the maximum value of weighted results, etc.
[0160] Next, a merge operation is performed. The server merges the first, second, and third software control flow state graphs into a comprehensive state graph according to the determined merge strategy. During the merge process, the server may need to handle issues such as node and edge conflicts, normalization of encoding vectors, and adjustment of weighted results.
[0161] Finally, verify and optimize the state diagram. After the merge is completed, the server verifies and optimizes the generated comprehensive software control flow state diagram. The verification process may include comparison with the original node sequence, consistency and integrity check of the state diagram, etc. The optimization process may involve simplification of the state diagram, removal of redundant information, adjustment of layout, etc., to improve the readability and practicality of the state diagram.
[0162] Through the above steps, the server can generate a comprehensive, accurate and easy-to-understand software control flow state diagram, providing strong support for subsequent fault diagnosis, process optimization and other tasks.
[0163] In a possible implementation, the method further includes:
[0164] Step C150, configuring a fourth setting execution instance corresponding to the software control node sequence. The fourth setting execution instance includes dividing the software control node sequence into two software control node subsequences according to the target software control node in the software control node sequence. Converting the two software control node subsequences into software control flow state subgraphs respectively according to the second setting execution instance. Determining the weighted calculation results of the two software control flow state subgraphs, and generating a software control flow state graph.
[0165] The determining of the software control flow state diagram corresponding to each of the example software control paths according to the first software control flow state diagram, the second software control flow state diagram, and the third software control flow state diagram corresponding to each of the example software control paths comprises: converting each of the example software control paths into a fourth software control flow state diagram according to the fourth setting execution instance. The determining of the software control flow state diagram corresponding to each of the example software control paths according to the first software control flow state diagram, the second software control flow state diagram, the third software control flow state diagram, and the fourth software control flow state diagram corresponding to each of the example software control paths.
[0166] In order to analyze and represent the structure and process characteristics of the software control node sequence in more detail, the server configures a fourth set execution instance. This instance divides the sequence into two parts by identifying the target software control node, and converts the two parts into software control flow state subgraphs based on the second set execution instance (configuring an execution space of a set length). Finally, a comprehensive software control flow state graph is generated by weighted calculation of the two subgraphs.
[0167] In detail, the software control node sequence is first traversed, and the target software control nodes are identified according to preset rules or domain knowledge. These nodes may be decision points, loop starting points, key operation points, etc., which have important logical significance in the process.
[0168] Once the target software control node is identified, the server uses it as a split point to divide the software control node sequence into two subsequences, and the two subsequences represent the process parts before and after the target node respectively.
[0169] The server then generates a corresponding software control flow state subgraph for each subsequence based on the second set execution instance. During this process, the server uses an execution space of a set length to map each node in the subsequence to the corresponding unit slot of the execution space according to its operation code type (assignment type, judgment type, loop type, etc.), and generates a corresponding encoding vector to represent the existence and characteristics of the node.
[0170] After obtaining the two software control flow state subgraphs, the server needs to determine the importance or contribution of the two subgraphs in the overall process, and merge them into a comprehensive software control flow state graph through weighted calculation.
[0171] The server assigns a weight to each subgraph based on domain knowledge, historical data, or user preferences. The weight assignment can be based on factors such as the complexity of the subgraph, the number of key nodes it contains, and its role in the overall process.
[0172] The server performs weighted calculation on the two software control flow state subgraphs according to the determined weighting rules. This process may involve weighted summation of nodes, edges or encoding vectors in the subgraphs, or may involve a more complex graph structure weighted merging algorithm.
[0173] After the weighted calculation is completed, the server merges the two weighted software control flow state subgraphs into a comprehensive software control flow state graph, which not only contains the information of the two subgraphs, but also reflects the relative importance between the subgraphs through weighted calculation.
[0174] In the previous steps, the server has generated the first, second, third and fourth software control flow state diagrams for each sample software control path. Now, the server needs to combine these state diagrams to generate a more comprehensive and accurate software control flow state diagram.
[0175] The server first collects all information in the first, second, third and fourth software control flow state graphs corresponding to each example software control path, including nodes, edges, encoding vectors, weighted results, etc.
[0176] The server determines an appropriate merging strategy based on the characteristics and requirements of the state graph, which may need to consider the complementarity and redundancy between different state graphs and their importance in the overall process.
[0177] The server merges the four software control flow state graphs into a comprehensive state graph based on the determined merging strategy. During this process, the server may need to deal with issues such as node and edge conflicts, superposition of coding vectors, and adjustment of weighted results to ensure that the merged state graph is both comprehensive and accurate.
[0178] After the merge is completed, the server verifies and optimizes the generated comprehensive software control flow state diagram. The verification process includes comparison with the original node sequence, consistency and integrity check of the state diagram, etc. The optimization process may involve simplification of the state diagram, removal of redundant information, adjustment of layout, etc., to improve the readability and practicality of the state diagram. Through the above steps, the server can generate a comprehensive, accurate and easy-to-understand software control flow state diagram, providing strong support for subsequent fault diagnosis, process optimization and other work.
[0179] In a possible implementation, step S140 includes:
[0180] Step S141, loading each target example software control path in the target example software control path sequence into the initialized classification network, and generating graph self-attention features corresponding to each target example software control path.
[0181] Step S142, determining the training diagnosis knowledge points corresponding to each target example software control path according to the self-attention features of the corresponding graph of each target example software control path.
[0182] Step S143, based on the loss function value between the training diagnostic knowledge points corresponding to the target example software control paths and the labeled diagnostic knowledge points corresponding to the target example software control paths, update the network parameter information of the initialized classification network to generate the parallel power system fault diagnosis network.
[0183] In this embodiment, the target example software control path sequence contains the control process information of the power system under normal operation and fault conditions. Now, the server needs to load these paths into the initialization classification network and generate corresponding graph self-attention features for subsequent diagnosis knowledge point determination and parameter learning.
[0184] In detail, the target example software controls the sequence of paths and the logical relationships between them.
[0185] Step 1.2: For each target example software control path in the sequence, the server inputs it into the initialization classification network, which may be a graph neural network-based model that can process graph-structured data. Inside the classification network, the server uses the graph self-attention mechanism to process the input software control path. The graph self-attention mechanism allows the model to take into account the information of all nodes and edges in the graph when generating features, and give different weights according to their importance. Through the graph self-attention mechanism, the server generates corresponding graph self-attention features for each target example software control path. These features are high-dimensional vectors that capture the key information and structural characteristics in the path.
[0186] After obtaining the graph self-attention features of each target example software control path, the server needs to determine the corresponding training diagnostic knowledge points based on these graph self-attention features. These training diagnostic knowledge points will be used for subsequent network parameter updates and fault diagnosis.
[0187] Specifically, the server designs one or more classifiers (or regressors) that can receive graph self-attention features as input and output corresponding diagnostic knowledge points. Diagnostic knowledge points can include information such as fault type, fault location, and fault severity. For each target example software control path, the server inputs its graph self-attention features into the classifier to obtain the corresponding training diagnostic knowledge points. This process is a forward propagation process and does not involve the update of network parameters.
[0188] After determining the training diagnostic knowledge points, the server needs to calculate the loss function values between these knowledge points and the labeled diagnostic knowledge points, and update the parameters of the initialized classification network according to the loss function values to generate a parallel power system fault diagnosis network.
[0189] In detail, the server obtains the annotated diagnostic knowledge points corresponding to each target example software control path. These annotated knowledge points are determined in advance by experts or historical data and represent the real fault information of the path. For each target example software control path, the server calculates the loss function value between its training diagnostic knowledge points and the annotated diagnostic knowledge points. The loss function value measures the difference between the two and is the basis for subsequent parameter updates. The server uses the back propagation algorithm and optimizer (such as the gradient descent algorithm) to update the parameters of the initialized classification network. During the back propagation process, the loss function value is used to calculate the gradient of each parameter in the network, and then the parameter value is updated according to the gradient. Repeat the above steps until the stop condition is met (such as the loss function value converges, reaches the preset number of iterations, etc.). During the iteration process, the parameters of the network are gradually optimized, and the diagnostic ability of the target example software control path is gradually improved. When the stop condition is met, the server generates the final parallel power system fault diagnosis network, which has learned the fault characteristics in the target example software control path and can accurately diagnose the fault type and location of the power system.
[0190] Through the above steps, the initialized classification network is trained into a parallel power system fault diagnosis network, which provides a powerful tool for subsequent real-time fault diagnosis.
[0191] Figure 2 The hardware structure of the fault diagnosis system 100 provided in the embodiment of the present application for implementing the fault diagnosis method of the parallel power supply system is shown. Figure 2 As shown, the fault diagnosis system 100 may include a processor 110 , a machine-readable storage medium 120 , a bus 130 , and a communication unit 140 .
[0192] In a possible design, the fault diagnosis system 100 can be a single server or a server group. The server group can be centralized or distributed (for example, the fault diagnosis system 100 can be a distributed system). In some embodiments, the fault diagnosis system 100 can be local or remote. For example, the fault diagnosis system 100 can access information and / or data stored in the machine-readable storage medium 120 via a network. For another example, the fault diagnosis system 100 can be directly connected to the machine-readable storage medium 120 to access the stored information and / or data. In some embodiments, the fault diagnosis system 100 can be implemented on a fault diagnosis system. As an example only, the fault diagnosis system can include a private cloud, a public cloud, a hybrid cloud, a community cloud, a distributed cloud, an internal cloud, a multi-layer cloud, etc. or any convergence thereof.
[0193] The machine-readable storage medium 120 may store data and / or instructions. In some embodiments, the machine-readable storage medium 120 may store data acquired from an external terminal. In some embodiments, the machine-readable storage medium 120 may store data and / or instructions that the fault diagnosis system 100 uses to execute or use to complete the exemplary methods described in this application.
[0194] During the specific implementation process, one or more processors 110 execute computer executable instructions stored in the machine-readable storage medium 120, so that the processor 110 can execute the fault diagnosis method of the parallel power supply system in the above method embodiment. The processor 110, the machine-readable storage medium 120 and the communication unit 140 are connected through the bus 130, and the processor 110 can be used to control the sending and receiving actions of the communication unit 140.
[0195] The specific implementation process of the processor 110 can refer to the various method embodiments executed by the above-mentioned fault diagnosis system 100. The implementation principles and technical effects are similar, and this embodiment will not be repeated here.
[0196] In addition, an embodiment of the present application further provides a readable storage medium, in which computer executable instructions are set. When a processor executes the computer executable instructions, the fault diagnosis method of the parallel power supply system as above is implemented.
[0197] It should be noted that in order to simplify the description disclosed in this application and thus help understand one or more embodiments of the invention, in the foregoing description of the embodiments of the present application, multiple features are sometimes combined into one embodiment, drawings, or descriptions thereof. Similarly, it should be noted that in order to simplify the description disclosed in this application and thus help understand one or more embodiments of the invention, in the foregoing description of the embodiments of the present application, multiple features are sometimes combined into one embodiment, drawings, or descriptions thereof.
Claims
1. A fault diagnosis method for a parallel power supply system, characterized in that: The method comprises: Obtaining a sample software control path sequence corresponding to a sample system control software running event sequence of a parallel power supply system; the sample software control path sequence includes a first sample software control path and a second sample software control path; the first sample software control path carries non-fault diagnosis knowledge points, and the second sample software control path carries fault diagnosis knowledge points; Determine a software control flow state graph corresponding to each example software control path in the example software control path sequence, cluster the multiple software control flow state graphs corresponding to the example software control path sequence to generate multiple state graph groups, and determine a target state graph group based on the software control flow state graphs respectively corresponding to the multiple state graph groups; Adjusting the diagnostic knowledge points of the first example software control path corresponding to the target state diagram group to the fault diagnosis knowledge points to generate a target example software control path sequence; Based on the target example software control path sequence, parameter learning is performed on the initialization classification network to generate a parallel power system fault diagnosis network; Obtaining a candidate software control path of a candidate system control software running event, loading the candidate software control path into the parallel power system fault diagnosis network, generating a fault diagnosis result, and if the fault diagnosis result reflects that the candidate software control path is a faulty software control path, outputting the candidate system control software running event as a faulty system control software running event; The step of clustering the plurality of software control flow state diagrams corresponding to the example software control path sequence to generate a plurality of state diagram groups includes: Determining the path vector association degree between the first example software control path and the second example software control path according to the software control flow state diagrams respectively corresponding to the first example software control path and the second example software control path; Clustering the multiple path vector associations corresponding to the example software control path sequence to generate the multiple state diagram groups; The determining of the target state diagram group based on the software control flow state diagrams respectively corresponding to the plurality of state diagram groups comprises: Determining a target state diagram group based on the path vector associations respectively corresponding to the plurality of state diagram groups; The method of performing parameter learning on the initialization classification network based on the target example software control path sequence to generate a parallel power system fault diagnosis network includes: Loading each target example software control path in the target example software control path sequence into the initialized classification network, generating a graph self-attention feature corresponding to each target example software control path; Determine the training diagnosis knowledge points corresponding to each target example software control path according to the self-attention features of the corresponding graph of each target example software control path; Based on the loss function values between the training diagnostic knowledge points corresponding to the target example software control paths and the labeled diagnostic knowledge points corresponding to the target example software control paths, the network parameter information of the initialized classification network is updated to generate the parallel power system fault diagnosis network.
2. The fault diagnosis method of the parallel power supply system according to claim 1, characterized in that: The determining of the target state diagram group based on the software control flow state diagrams respectively corresponding to the plurality of state diagram groups comprises: Outputting the state diagram group including the fault software control flow state diagram among the plurality of state diagram groups as a target state diagram group; The step of determining the fault software control flow state diagram includes: Acquire a set software control path sequence corresponding to a set system control software running event sequence; the set software control path sequence includes setting a non-faulty software control path and setting a faulty software control path; Determine a setting software control flow state diagram corresponding to each setting software control path in the setting software control path sequence; Clustering the plurality of setting software control flow state diagrams corresponding to the setting software control path sequence to generate a plurality of setting state diagram groups; Determine the weight of the set fault software control path corresponding to each set state diagram group; Grouping the set state graphs whose weights of the set fault software control paths are greater than the first threshold value, and outputting them as fault state graph groups; The setting software control flow state diagram in the fault state diagram group is output as the fault software control flow state diagram.
3. The fault diagnosis method of the parallel power supply system according to claim 2, characterized in that: The clustering of the plurality of set software control flow state diagrams corresponding to the set software control path sequence to generate a plurality of set state diagram groups includes: Determine the set path vector correlation degree between the set non-faulty software control path and the set faulty software control path according to the set software control flow state diagrams respectively corresponding to the set non-faulty software control path and the set faulty software control path; Clustering is performed based on the correlation degree of a plurality of setting path vectors corresponding to the setting software control path sequence to generate the plurality of setting state diagram groups; The method further comprises: Outputting the sampling path vector correlation degree in the fault state diagram group as a set correlation degree; the sampling path vector correlation degree in the fault state diagram group is less than a first correlation degree; the first correlation degree is the correlation degree in the fault state diagram group except the sampling path vector correlation degree; The determining the target state diagram group based on the path vector associations respectively corresponding to the plurality of state diagram groups comprises: Determine the target path vector association degree in each state diagram group; the target path vector association degree in any one of the state diagram groups is less than the second association degree in the any one of the state diagram groups; the second association degree in any one of the state diagram groups is the association degree in the any one of the state diagram groups except the target path vector association degree; The state graphs whose target path vector correlation is not greater than the set correlation are grouped and output as the target state graph group.
4. The fault diagnosis method of the parallel power supply system according to claim 1, characterized in that: The method further comprises: Determine a software control node sequence corresponding to the first example software control path and the second example software control path respectively; Determine a target shared software control path of the first example software control path and the second example software control path according to the software control node sequences corresponding to the first example software control path and the second example software control path respectively; Determine the path unit values corresponding to the first example software control path and the second example software control path respectively; Determining a first node association degree between the first example software control path and the second example software control path based on the path unit values respectively corresponding to the first example software control path and the second example software control path and the target shared software control path; Determine the shared software control nodes of the first example software control path and the second example software control path according to the software control node sequences corresponding to the first example software control path and the second example software control path respectively; Determining a second node association degree between the first example software control path and the second example software control path based on the path unit values respectively corresponding to the first example software control path and the second example software control path and the shared software control node; Determine, according to the software control node sequences respectively corresponding to the first example software control path and the second example software control path, the code vector weights respectively corresponding to the first example software control path and the second example software control path; Determining a third node association degree between the first example software control path and the second example software control path according to the code vector weights respectively corresponding to the first example software control path and the second example software control path; Determining a node association degree between the first example software control path and the second example software control path based on the first node association degree, the second node association degree, and the third node association degree; The clustering of the plurality of path vector associations corresponding to the example software control path sequence to generate the plurality of state diagram groups includes: The plurality of path vector associations and the plurality of node associations corresponding to the example software control path sequence are clustered to generate the plurality of state diagram groups.
5. The fault diagnosis method of the parallel power supply system according to claim 1, characterized in that: The method further comprises: A first setting execution instance corresponding to a software control node sequence in a configuration example software control path; the first setting execution instance includes editing the software control node of the assignment type operation code into a first coding vector, editing the software control node of the determination type operation code into a second coding vector, and editing the software control node of the loop type operation code into a third coding vector; The determining of the software control flow state diagram corresponding to each example software control path in the example software control path sequence includes: According to the first setting execution instance, converting each example software control path in the example software control path sequence into a first software control flow state diagram; According to the first software control flow state diagram corresponding to each of the example software control paths, the software control flow state diagram corresponding to each of the example software control paths is determined.
6. The fault diagnosis method of the parallel power supply system according to claim 5, characterized in that: The method further comprises: A second set execution instance corresponding to the software control node sequence is configured; the second set execution instance is an execution space configured with a set length; wherein the set length corresponds to a set number of unit slots, and the set number of unit slots includes a plurality of first unit slots and a plurality of second unit slots; each first unit slot corresponds to an assignment type operation code, and the coding vector in each first unit slot is used to reflect whether there is an assignment type operation code corresponding to each first unit slot in the software control node sequence; each second unit slot corresponds to a non-assignment type operation code software control node; the non-assignment type operation code includes a judgment type operation code and a loop type operation code; the coding vector in each second unit slot is used to reflect whether there is a non-assignment type operation code corresponding to each second unit slot in the software control node sequence; Determining the software control flow state diagram corresponding to each example software control path according to the first software control flow state diagram corresponding to each example software control path includes: According to the second setting execution instance, each of the example software control paths is converted into a second software control flow state diagram; According to the first software control flow state diagram and the second software control flow state diagram corresponding to each of the example software control paths, the software control flow state diagram corresponding to each of the example software control paths is determined.
7. The fault diagnosis method of the parallel power supply system according to claim 6, characterized in that: The method further comprises: configuring a third setting execution instance corresponding to the software control node sequence; the third setting execution instance comprises dividing the software control node sequence into two software control node sub-sequences according to the target software control node in the software control node sequence; converting the two software control node sub-sequences into software control flow state sub-graphs respectively according to the first setting execution instance; Determine the weighted calculation results of the two software control flow state subgraphs to generate a software control flow state graph; Determining the software control flow state diagram corresponding to each example software control path according to the first software control flow state diagram and the second software control flow state diagram corresponding to each example software control path includes: According to the third setting execution instance, each of the example software control paths is converted into a third software control flow state diagram; According to the first software control flow state diagram, the second software control flow state diagram and the third software control flow state diagram corresponding to each of the example software control paths, the software control flow state diagram corresponding to each of the example software control paths is determined.
8. The fault diagnosis method of the parallel power supply system according to claim 7, characterized in that: The method further comprises: configuring a fourth setting execution instance corresponding to the software control node sequence; the fourth setting execution instance includes dividing the software control node sequence into two software control node subsequences according to the target software control node in the software control node sequence; converting the two software control node subsequences into software control flow state subgraphs respectively according to the second setting execution instance; determining a weighted calculation result of the two software control flow state subgraphs to generate a software control flow state graph; Determining the software control flow state diagram corresponding to each example software control path according to the first software control flow state diagram, the second software control flow state diagram, and the third software control flow state diagram corresponding to each example software control path includes: According to the fourth setting execution instance, each of the example software control paths is converted into a fourth software control flow state diagram; According to the first software control flow state diagram, the second software control flow state diagram, the third software control flow state diagram and the fourth software control flow state diagram corresponding to each of the example software control paths, the software control flow state diagram corresponding to each of the example software control paths is determined.
9. A fault diagnosis system, characterized in that: The fault diagnosis system includes a processor and a memory, the memory is connected to the processor, the memory is used to store programs, instructions or codes, and the processor is used to execute the programs, instructions or codes in the memory to implement the fault diagnosis method for the parallel power supply system described in any one of claims 1 to 8.
Citation Information
Patent Citations
Parallel arc fault positioning method and system of low-voltage distribution network
CN112964966A
Electronic mall operation data analysis method and system applied to plasticizing industry platform
CN118132327A