Power distribution network fault positioning method and device based on improved edge graph attention mechanism

By improving the fault location method based on the edge graph attention mechanism and combining graph convolutional neural networks and graph attention networks, the accuracy problem of fault location in power distribution networks is solved, and high-precision fault node identification is achieved under complex structures and incomplete data conditions.

CN119291366APending Publication Date: 2025-01-10STATE GRID INFORMATION & TELECOMM GRP CO LTD +1
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411191502.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-28
Publication Date
2025-01-10

AI Technical Summary

Technical Problem

Accurate fault location in distribution networks is difficult, especially in cases of complex structures and distributed power source integration, where traditional methods struggle to obtain accurate fault identification results.

Method used

A fault location method based on an improved edge graph attention mechanism is adopted. By obtaining the adjacency matrix and admittance matrix of the distribution network topology, and combining the node and edge feature vectors, the fault node is located using a graph convolutional neural network and a graph attention network.

Benefits of technology

It improves the accuracy and robustness of fault location, enabling precise extraction of fault features even in the presence of data noise and missing data, thereby enhancing location accuracy and data utilization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119291366A_ABST
    Figure CN119291366A_ABST
Patent Text Reader

Abstract

The invention provides a power distribution network fault positioning method and device based on an improved edge graph attention mechanism, and the method comprises the steps: obtaining a topological structure of a power distribution network, and determining an adjacent matrix and an admittance matrix of the power distribution network; determining a node feature matrix and an edge feature matrix according to the voltage value and the current value; the power distribution network adjacency matrix, the admittance matrix, the node characteristic matrix and the edge characteristic matrix are input into the fault positioning model, the fault nodes in the power distribution network are output through the model, and the fault position in the power distribution network is determined more accurately. According to the method, for different attribute characteristics of admittance and current membership in power distribution network branch information, admittance information is fused into a node characteristic aggregation process and is embedded into an attention coefficient; according to the method, line current information is directly added to adjacent node features, and edge inherent attribute information is fused into the graph attention neural network, so that fault features can be extracted more accurately, the precision of model positioning is improved, and better robustness is provided for data noise and data missing in practical application.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of power systems, and in particular to a distribution network fault location method and device based on an improved edge graph attention mechanism. Background Art

[0002] With the rapid development of social economy, the power system, as the core of energy supply, has attracted wide attention for its stability and reliability. As a component of the power system, the distribution network is directly related to the power safety and power quality of the majority of users.

[0003] Accurately locating distribution network faults is a prerequisite for fault isolation and power supply restoration. However, due to the complexity of the distribution network structure, the particularity of the grounding method, and the different fault resistance values, distribution network fault location has always been a difficult problem. In addition, with the current access to distributed power sources, traditional methods of analyzing the power operation mechanism are difficult to obtain accurate fault identification results. Summary of the invention

[0004] In view of this, the purpose of the present disclosure is to propose a distribution network fault location method and device based on an improved edge graph attention mechanism to solve or partially solve the above problems.

[0005] Based on the above objectives, the first aspect of the present disclosure provides a distribution network fault location method based on an improved edge graph attention mechanism, the method comprising:

[0006] Acquire a distribution network topology structure, and determine a distribution network adjacency matrix and an admittance matrix according to the distribution network topology structure;

[0007] For each target node in the distribution network topology:

[0008] Obtaining a voltage value corresponding to a target node, and determining a node feature vector corresponding to the target node according to the voltage value;

[0009] Obtaining current values ​​corresponding to branches between target nodes, and determining edge feature vectors corresponding to branches between target nodes according to the current values;

[0010] Determine the node feature matrix corresponding to the topology of the distribution network according to the node feature vector corresponding to each target node, and determine the edge feature matrix corresponding to the topology of the distribution network according to the edge feature vector corresponding to the branch between each target node;

[0011] The distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix are input into a pre-trained fault location model, and the fault node in the distribution network is output through the fault location model.

[0012] Based on the same inventive concept, the second aspect of the present disclosure proposes a distribution network fault location device based on an improved edge graph attention mechanism, comprising:

[0013] An adjacency matrix determination module is configured to obtain a distribution network topology structure, and determine a distribution network adjacency matrix and an admittance matrix according to the distribution network topology structure;

[0014] The feature vector determination module is configured to: for each target node in the distribution network topology:

[0015] Obtaining a voltage value corresponding to a target node, and determining a node feature vector corresponding to the target node according to the voltage value;

[0016] Obtaining current values ​​corresponding to branches between target nodes, and determining edge feature vectors corresponding to branches between target nodes according to the current values;

[0017] A feature matrix determination module is configured to determine a node feature matrix corresponding to a distribution network topology structure according to a node feature vector corresponding to each target node, and to determine an edge feature matrix corresponding to a distribution network topology structure according to an edge feature vector corresponding to a branch between each target node;

[0018] The fault node determination module is configured to input the distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix into a pre-trained fault location model, and output the fault node in the distribution network via the fault location model.

[0019] Based on the same inventive concept, the third aspect of the present disclosure proposes an electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable by the processor, wherein the processor implements the distribution network fault location method based on the improved edge graph attention mechanism as described above when executing the computer program.

[0020] Based on the same inventive concept, the fourth aspect of the present disclosure proposes a non-transitory computer-readable storage medium, which stores computer instructions, and the computer instructions are used to enable a computer to execute the distribution network fault location method based on the improved edge graph attention mechanism as described above.

[0021] From the above, it can be seen that the present disclosure proposes a distribution network fault location method and device based on an improved edge graph attention mechanism, obtains the distribution network topology, determines the distribution network adjacency matrix and admittance matrix according to the distribution network topology, and the admittance matrix contains the inherent attribute information of the distribution network. For each target node in the distribution network topology: obtain the voltage value corresponding to the target node, and determine the node feature vector corresponding to the target node according to the voltage value; obtain the current value corresponding to the branch between the target nodes, and determine the edge feature vector corresponding to the branch between the target nodes according to the current value; determine the node feature matrix corresponding to the distribution network topology according to the node feature vector corresponding to each target node, and determine the edge feature matrix corresponding to the distribution network topology according to the edge feature vector corresponding to the branch between each target node. The distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix are input into the pre-trained fault location model, and the fault node in the distribution network is output through the fault location model, which is more accurate for determining the fault location in the distribution network. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] In order to more clearly illustrate the technical solutions in the present disclosure or related technologies, the drawings required for use in the embodiments or related technical descriptions are briefly introduced below. Obviously, the drawings described below are only embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0023] Figure 1 It is a flow chart of a distribution network fault location method based on an improved edge graph attention mechanism according to an embodiment of the present disclosure;

[0024] Figure 2 is a schematic diagram of the hierarchical structure of the initial fault location model of an embodiment of the present disclosure;

[0025] Figure 3 A schematic diagram of a method for calculating an initial attention coefficient corresponding to an embodiment of the present disclosure;

[0026] Figure 4 A schematic diagram of introducing an edge feature matrix in an embodiment of the present disclosure;

[0027] Figure 5 is a schematic diagram of an IEEE 33-node system according to an embodiment of the present disclosure;

[0028] Figure 6 A schematic diagram of algorithm training results when locating a single-phase grounding fault in a distribution network according to an embodiment of the present disclosure;

[0029] Figure 7 It is a structural block diagram of a distribution network fault location device based on an improved edge graph attention mechanism according to an embodiment of the present disclosure;

[0030] Figure 8 It is a schematic diagram of the structure of an electronic device according to an embodiment of the present disclosure. DETAILED DESCRIPTION

[0031] In order to make the objectives, technical solutions and advantages of the present disclosure more clearly understood, the present disclosure is further described in detail below in combination with specific embodiments and with reference to the accompanying drawings.

[0032] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the embodiments of the present disclosure should be understood by people with ordinary skills in the field to which the present disclosure belongs. The "first", "second" and similar words used in the embodiments of the present disclosure do not indicate any order, quantity or importance, but are only used to distinguish different components. "Including" or "comprising" and similar words mean that the elements or objects appearing before the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0033] With the rapid development of social economy, the power system, as the core of energy supply, has received widespread attention for its stability and reliability. As a component of the power system, the distribution network is directly related to the power safety and power quality of the majority of users. A large number of studies have shown that most of the power outages encountered by users when using electricity are attributed to the failure of the distribution network. Accurate positioning of distribution network faults is the prerequisite for fault isolation and power supply restoration. However, due to the complexity of the distribution network structure and the particularity of the grounding method, the fault resistance values ​​are different, etc., making the distribution network fault location has always been a difficult problem. In addition, with the current access to distributed power sources, it is difficult to obtain accurate fault identification results by analyzing the power operation mechanism using traditional methods. Therefore, although previous studies have developed fault detection and location solutions, various algorithms are still being developed and studied to perform this task more accurately and effectively.

[0034] The current fault location methods are roughly divided into four types. The first type is to measure the fault distance based on the steady-state signal generated when the fault occurs, such as the impedance method and the fault analysis method. This type of method is easily affected by line parameters and operation mode, so it is not suitable for the positioning of distribution networks with complex structures; the second type is to measure the fault distance based on the transient traveling wave signal of the fault. The accuracy of this method is heavily dependent on the detection of the wave head and wave velocity of the traveling wave, and it is difficult to adapt to the complex structure of the distribution network and the characteristics of the mixed connection of overhead cables; the third type is to measure the fault distance based on the injection of external high-frequency signals into the power grid system. This method requires the addition of equipment, which greatly increases the positioning cost and is difficult to promote and apply in distribution networks with many points and wide areas; the fourth type is the artificial intelligence method. Compared with the feeder automatic method, the biggest advantage of the artificial intelligence algorithm is that this method can dig out the traditional method mechanism analysis method that is difficult to obtain accurate fault judgment criteria. As distribution network intelligent products are becoming increasingly perfect, distribution network intelligent equipment (DTU, FTU, TTU, LTU, etc.) is marketed, but the monitoring information is scattered, the analysis results are not accurate, and the comprehensive data utilization rate is low. It is difficult to intelligently and accurately guide operation and maintenance personnel to quickly carry out fault location and fault handling. It is urgent to mine the value of complex network information data of distribution networks based on deep learning algorithms on the basis of existing collection devices, realize comprehensive diagnosis and analysis of distribution network data at the lowest cost, improve the accuracy of distribution network fault location, assist operation and maintenance personnel to quickly determine the fault point, shorten the power outage time, and improve power supply reliability.

[0035] In recent years, computer technology has been developing rapidly, big data analysis technology has been continuously promoted and applied, and the new generation of artificial intelligence technology has also made breakthrough progress. All walks of life are moving towards intelligence, digitization, networking and high speed. Graph neural network (GNN) is a type of neural network model specifically used to process graph structure data. Unlike traditional convolutional neural networks that process regular grid data such as images, GNN can process irregular graph structure data, making it very suitable for social network analysis, recommendation systems, molecular structure analysis and other fields. Due to its powerful ability to process graph structure data, graph neural network can comprehensively consider the inherent physical characteristics of distribution network, greatly improve the information fault tolerance of fault location algorithm, and adapt well to the characteristics of incomplete measurement information, easy loss and distortion of measurement data, etc., providing a new solution for distribution network fault location.

[0036] Based on the above description, this embodiment proposes a distribution network fault location method based on an improved edge graph attention mechanism, such as Figure 1 As shown, the method includes:

[0037] Step 101: Acquire a distribution network topology structure, and determine a distribution network adjacency matrix and an admittance matrix according to the distribution network topology structure.

[0038] In specific implementation, the distribution network topology is obtained, and the distribution network topology is composed of vertices and edges. The distribution network topology can be abstracted into a graph composed of vertices and edges according to the topology structure, wherein the vertices are composed of electrical nodes of the distribution network (i.e., the target nodes or sample nodes mentioned below), and the edges are composed of overhead lines or cable lines.

[0039] Step 102, for each target node in the distribution network topology:

[0040] Obtaining a voltage value corresponding to a target node, and determining a node feature vector corresponding to the target node according to the voltage value;

[0041] The current value corresponding to the branch between the target nodes is obtained, and the edge feature vector corresponding to the branch between the target nodes is determined according to the current value.

[0042] In a specific implementation, for each target node in the distribution network topology, the voltage value of the branch between the target nodes is obtained, and the node feature vector corresponding to the branch between the target nodes is determined according to the voltage value of the branch between the target nodes.

[0043] The current value corresponding to the target node is obtained, and the edge eigenvector corresponding to the target node is determined according to the current value and the adjacency matrix, wherein the current value is the current value between the target node and other nodes adjacent to the target node in the adjacency matrix, and the other nodes are also target nodes.

[0044] Step 103: determining a node feature matrix corresponding to the distribution network topology structure according to the node feature vector corresponding to each target node, and determining an edge feature matrix corresponding to the distribution network topology structure according to the edge feature vector corresponding to each target node.

[0045] In a specific implementation, a node feature matrix corresponding to the topological structure of the distribution network is determined according to a node feature vector corresponding to each target node, that is, the node feature matrix contains feature quantity information carried by each target node itself.

[0046] The edge feature matrix corresponding to the topological structure of the distribution network is determined according to the edge feature vector corresponding to each target node, that is, the edge feature matrix contains feature quantity information carried by the edge between two target nodes, that is, the edge of the topological structure itself.

[0047] Step 104: input the distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix into a pre-trained fault location model, and output the faulty node in the distribution network via the fault location model.

[0048] During the specific implementation, the initial fault location model is trained in advance, and the fault location model is obtained after the training is completed, wherein the initial fault location model is a model using a neural network structure, and the model can be a graph convolutional neural network (graph convolutional network, GCN) and a graph attention network (graph attention network, GAT). The fault location model in this embodiment is a graph attention network.

[0049] After determining the adjacency matrix, admittance matrix, node feature matrix and edge feature matrix of the distribution network, the distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix are input into a pre-trained fault location model, and the fault location model outputs the fault node in the distribution network, thereby locating the fault position in the distribution network.

[0050] In this embodiment, the fault location is located, wherein the fault type of the fault location is a line fault, including a single-phase grounding fault and a phase-to-phase short circuit fault. A single-phase grounding fault refers to a short circuit between one phase and the ground, and a phase-to-phase short circuit fault refers to a short circuit between two phases in a power distribution system or a short circuit between three phases in a power distribution network.

[0051] Through the above scheme, the distribution network topology is obtained, and the distribution network adjacency matrix and admittance matrix are determined according to the distribution network topology, and the admittance matrix contains the inherent attribute information of the distribution network. For each target node in the distribution network topology: the voltage value corresponding to the target node is obtained, and the node feature vector corresponding to the target node is determined according to the voltage value; the current value corresponding to the branch between the target nodes is obtained, and the edge feature vector corresponding to the branch between the target nodes is determined according to the current value; the node feature matrix corresponding to the distribution network topology is determined according to the node feature vector corresponding to each target node, and the edge feature matrix corresponding to the distribution network topology is determined according to the edge feature vector corresponding to the branch between each target node. The distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix are input into the pre-trained fault location model, and the fault node in the distribution network is output through the fault location model, so that the fault location in the distribution network is more accurately determined. This method targets the different attribute characteristics of admittance and current in the distribution network branch information, integrates the admittance information into the node feature aggregation process, and embeds it into the attention coefficient; and directly adds the line current information to the adjacent node features. This method of incorporating the edge inherent attribute information into the graph attention neural network can more accurately extract fault features, improve the accuracy of model positioning, and has better robustness to data noise and data missing in practical applications.

[0052] In some embodiments, step 101 specifically includes:

[0053] Step 1011, matrix processing is performed on the distribution network topology structure to obtain a distribution network adjacency matrix.

[0054] Step 1012: Acquire attribute information of distribution network components, and determine the admittance value corresponding to each eigenvector in the distribution network adjacency matrix according to the attribute information of the distribution network components and the distribution network adjacency matrix.

[0055] Step 1013: determine the admittance matrix according to the admittance value corresponding to each eigenvector.

[0056] In specific implementation, the topological structure of the distribution network is matrixed to obtain the distribution network adjacency matrix, which is expressed by the formula:

[0057]

[0058] Where A is the adjacency matrix of the distribution network, which is composed of the feature vectors corresponding to n target nodes, A∈R n×n , the adjacency matrix A represents the topological structure of the distribution network by representing the connection relationship between nodes through lines, that is, a ij =1 indicates that the target node i is connected to the target node j via a line, ij =0 means there is no line connection between target node i and target node j.

[0059] In this embodiment, when the distribution network undergoes reconstruction, its nodes and connectivity may be dynamically adjusted or nodes and lines may be removed, thereby causing structural changes in the network topology. The distribution network adjacency matrix can be dynamically adjusted according to the topology changes.

[0060] Acquire the attribute information of the distribution network components, wherein the attribute information of the distribution network components includes resistance, reactance, current, voltage, etc. Determine the admittance value corresponding to each eigenvector in the distribution network adjacency matrix according to the attribute information of the distribution network components and the distribution network adjacency matrix. Based on the admittance value corresponding to each eigenvector in the distribution network adjacency matrix, obtain the admittance matrix corresponding to the topological structure of the distribution network.

[0061] In some embodiments, step 1012 specifically includes:

[0062] For each eigenvector:

[0063] The position of the eigenvector in the distribution network adjacency matrix is ​​determined, and the admittance value corresponding to the eigenvector is determined according to the position and the attribute information of the distribution network element. The admittance value is expressed by the formula:

[0064]

[0065] Among them, Y ijis the admittance value of the eigenvector in the i-th row and j-th column in the distribution network adjacency matrix, which represents the admittance value between the target node i and the target node j. When i and j are not equal, the admittance value represents the mutual admittance value between the target node i and the target node j. When i and j are equal, the admittance value represents the self-admittance value of the target node i. i0 is the parallel admittance value of the target node i, m is the number of target nodes of the branch directly connected to the target node i, k is the target node of the branch directly connected to the kth target node i, y ik is the mutual admittance value between the target node i and the target node of the kth branch directly connected to the target node i, y ij is the admittance value of the branch directly connected between target node i and target node j, a ij is the connection status between target node i and target node j, where a ij =1 indicates that the target node i is connected to the target node j via a line, ij =0 means there is no line connection between target node i and target node j.

[0066] In a specific implementation, for each eigenvector, the position of the eigenvector in the distribution network adjacency matrix is ​​determined, and the position represents the information of the row and column of the eigenvector in the distribution network adjacency matrix. The admittance value corresponding to the eigenvector is determined according to the position and the attribute information of the distribution network element. The specific calculation method of the admittance value is expressed by the formula:

[0067]

[0068] Among them, Y ij is the admittance value of the eigenvector in the i-th row and j-th column in the distribution network adjacency matrix, which represents the admittance value between the target node i and the target node j. When i and j are not equal, the admittance value represents the mutual admittance value between the target node i and the target node j. When i and j are equal, the admittance value represents the self-admittance value of the target node i. i0 is the parallel admittance value of the target node i.

[0069] Where m is the number of target nodes in the branch directly connected to the target node i, k is the target node in the branch directly connected to the kth target node i, and y ik is the mutual admittance value between the target node i and the target node of the kth branch directly connected to the target node i, y ij is the admittance value of the branch directly connected between target node i and target node j, a ij is the connection status between target node i and target node j, where a ij =1 indicates that the target node i is connected to the target node j via a line, ij=0 means there is no line connection between target node i and target node j.

[0070] In this embodiment, the eigenvector y on the diagonal ii represents the node self-admittance, which is equal to the sum of the admittances of all branches directly connected to the target node i plus the parallel admittance y at the target node i i0 The off-diagonal eigenvectors y ij represents the mutual admittance between target node i and target node j. The mutual admittance value is equal to the direct connection between target node i and target node j. ij To facilitate calculation, the real and imaginary parts of the admittance matrix are split into two eigenvalues.

[0071] Correspondingly, the admittance matrix is ​​determined according to the admittance value corresponding to each eigenvector, and the admittance matrix is ​​expressed by the formula:

[0072]

[0073] Where n represents the number of target nodes in the distribution network topology, Y nn is the admittance value of the eigenvector of the nth row and nth column in the distribution network adjacency matrix, Y is the admittance matrix, which is composed of n node eigenvectors, Y∈R n×n .

[0074] In some embodiments, step 103 specifically includes:

[0075] Step 1031, obtaining the three-phase voltage amplitude and zero-sequence voltage amplitude corresponding to the target node.

[0076] Step 1032: construct a node characteristic vector corresponding to the target node according to the three-phase voltage amplitude and the zero-sequence voltage amplitude, wherein the node characteristic vector is expressed by the formula:

[0077] h i =[U i1 ,U i2 ,U i3 ,U i0 ]

[0078] Among them, h i is the node feature vector corresponding to the target node i, U i1 ,U i2 ,U i3 is the three-phase voltage amplitude corresponding to the target node i, U i0 is the zero-sequence voltage amplitude corresponding to the target node i.

[0079] In a specific implementation, the voltage value of the target node is obtained, wherein the voltage value includes the three-phase voltage amplitude and the zero-sequence voltage amplitude corresponding to the target node. A node feature vector corresponding to the target node is constructed according to the three-phase voltage amplitude and the zero-sequence voltage amplitude, wherein the node feature vector is expressed by the formula:

[0080] h i =[U i1 ,U i2 ,U i3 ,U i0 ]

[0081] Among them, h i is the node feature vector corresponding to the target node i, U i1 ,U i2 ,U i3 is the three-phase voltage amplitude corresponding to the target node i, U i0 is the zero-sequence voltage amplitude corresponding to the target node i.

[0082] Correspondingly, the node feature matrix corresponding to the distribution network topology is determined according to the node feature vector corresponding to each target node. The node feature matrix is ​​expressed by the formula:

[0083] H=[h1,h2,h3,...,h n ]

[0084] Among them, H is the node feature matrix, which is composed of n node feature vectors, H∈R n×b , b is the number of input node features.

[0085] In some embodiments, step 103 specifically includes:

[0086] Step 103A, obtaining the three-phase current amplitudes and zero-sequence current amplitudes corresponding to the branches between the target nodes;

[0087] Step 103B, constructing edge feature vectors corresponding to branches between target nodes according to the three-phase current amplitudes and the zero-sequence current amplitudes, wherein the edge feature vectors are expressed by the formula:

[0088]

[0089] Among them, e ij is the edge feature vector corresponding to the branch between target node i and target node j, I ij1 ,I ij2 ,I ij3 is the three-phase current amplitude corresponding to the target node i flowing to the target node j, I ij0 is the zero-sequence current amplitude corresponding to the target node i.

[0090] In the specific implementation, the three-phase current amplitude and zero-sequence current amplitude corresponding to the branch between the target nodes are obtained, and the edge feature vector corresponding to the branch between the target nodes is constructed according to the three current amplitudes, the zero-sequence current amplitude and the adjacency matrix, wherein the edge feature vector is expressed by the formula:

[0091]

[0092] Among them, e ij is the edge feature vector of the branch between target node i and target node j, I ij1 ,I ij2 ,I ij3 is the three-phase current amplitude corresponding to the target node i flowing to the target node j, I ij0 is the zero-sequence current amplitude corresponding to the target node i.

[0093] Correspondingly, the edge feature matrix corresponding to the distribution network topology structure is determined according to the edge feature vector corresponding to each target node, wherein the edge feature matrix is ​​expressed by the formula:

[0094]

[0095] Among them, E is the edge feature matrix, E∈R n×n×r , that is, the edge feature matrix E is n×n dimensional, where each element e ij are r-dimensional row vectors, representing the features of the edge connecting the target node i and the target node j, and r is the number of edge features. In this embodiment, r=4. Since the current at both ends of the actual distribution network may be different due to line impedance or faults, e ij ≠e ji , E is an asymmetric matrix.

[0096] In some embodiments, the training process of the fault location model specifically includes:

[0097] Step 10A, obtaining a sample distribution network adjacency matrix corresponding to the sample distribution network topology structure, a sample admittance matrix corresponding to the sample distribution network adjacency matrix, a sample node feature matrix corresponding to the sample distribution network adjacency matrix, a sample edge feature matrix corresponding to the sample distribution network adjacency matrix, and an actual fault node corresponding to the sample distribution network adjacency matrix;

[0098] Step 10B, using the actual fault node to mark the sample distribution network adjacency matrix, the sample admittance matrix, the sample node feature matrix and the sample edge feature matrix to obtain a sample data set;

[0099] Step 10C: obtaining an initial fault location model, and training the initial fault location model using the data in the sample data set until a preset training end condition is met, thereby obtaining a fault location model.

[0100] During specific implementation, a sample distribution network topology structure is obtained to determine a sample distribution network adjacency matrix corresponding to the sample distribution network topology structure, a sample admittance matrix corresponding to the sample distribution network adjacency matrix, a sample node feature matrix corresponding to the sample distribution network adjacency matrix, a sample edge feature matrix corresponding to the sample distribution network adjacency matrix, and an actual fault node corresponding to the sample distribution network adjacency matrix.

[0101] In this embodiment, the process of determining the sample distribution network critical matrix, sample admittance matrix, sample node characteristic matrix and sample edge characteristic matrix is ​​the same as the method of determining the distribution network adjacency matrix, admittance matrix, node characteristic matrix and edge characteristic matrix in the above embodiment, and will not be repeated here.

[0102] In this embodiment, the actual fault node is the fault location situation in the collected sample converted into a sample label. The node label of the busbars at both ends of the fault line is 1, and the node label of the other busbars is 0. The location label F is generated according to the fault location of the distribution network. The actual fault node is expressed by the formula:

[0103] F=[f1,f2,…,f n ]

[0104]

[0105] Among them, F∈R 1×n , where each element f i Indicates that node i is in normal state, f i =1 indicates that node i is in a fault state. The fault section location label of the distribution network can have multiple nodes with a state of 1. Therefore, the fault section location of the distribution network can be regarded as a multi-label classification problem, that is, each node is classified into two categories, and the output node state is 0 or 1, so as to locate the fault line.

[0106] The sample distribution network adjacency matrix, the sample admittance matrix, the sample node feature matrix and the sample edge feature matrix are marked by using the actual fault node to obtain a sample data set. That is, each set of data in the sample data set is a sample distribution network adjacency matrix, a sample admittance matrix, a sample node feature matrix, a sample edge feature matrix and an actual fault node.

[0107] An initial fault location model is obtained, and the initial fault location model is trained using the data in the sample data set until a preset training end condition is met to obtain the fault location model. In this embodiment, the preset training end condition includes at least one of the following: determining that all data in the sample data set are input into the initial fault location model for training, determining that the loss function of the initial fault location model converges to a preset convergence threshold, or determining that the initial fault location model is iteratively trained to a preset number of iterations.

[0108] Exemplarily, the preset training end condition is to ensure that all data in the sample data set are input into the initial fault location model for training:

[0109] There are a total of fifty groups of data in the sample data set, each group of data includes a sample distribution network adjacency matrix, a sample admittance matrix, a sample node feature matrix, a sample edge feature matrix and an actual fault node. The preset training end condition is to determine that all data in the sample data set are input into the initial fault location model for training, that is, when the fifty groups of data are input into the initial fault location model, there is no training data in the sample data set that has not been input into the initial fault location model, and the initial fault location model training is determined to be completed, and the fault location model is obtained.

[0110] In another example, the preset training end condition is to determine that the loss function of the initial fault location model converges to a preset convergence threshold:

[0111] The training data in the sample data set is input into the initial fault location model for training, and the training result is output. A loss function is determined according to the training result and the actual wear degree. The type of the loss function includes at least one of the following: mean square error loss function, cross entropy loss function, logarithmic loss function, exponential loss function, square loss function or absolute value loss function, etc. When the loss function converges to a preset convergence threshold, it is determined that the preset training end condition is met, and a fault location model is obtained.

[0112] In another example, the preset training end condition is to determine that the initial fault location model is iteratively trained to a preset number of iterations.

[0113] The training data in the sample data set is input into the initial fault location model for iterative training, the number of iterations is recorded, and when it is determined that the number of iterations is equal to the preset number of iterations, the preset training end condition is met, and the fault location model is obtained.

[0114] Through the above scheme, the training data in the sample data set includes the sample distribution network adjacency matrix, the sample admittance matrix, the sample node feature matrix, the sample edge feature matrix and the actual fault node. The initial fault location model is trained using the training data in the sample data set until the preset training end condition is met, and the fault location model is obtained, so that the fault location model can be used to output the fault nodes corresponding to the sample distribution network adjacency matrix, the sample admittance matrix, the sample node feature matrix, and the sample edge feature matrix in the subsequent process, and the fault node is determined more accurately.

[0115] In this embodiment, the sample node feature matrix and the sample edge feature matrix in the sample data set can be normalized in advance, and the minimum-maximum normalization method is used to limit the input features to the range of [0,1]. The specific process is expressed by the formula:

[0116]

[0117]

[0118] Among them, max(H) and max(E) are the maximum values ​​of node or edge features in the sample set; min(H) and min(E) are the minimum values ​​of node or edge features in the sample set. H' is the normalized sample feature matrix, and E' is the normalized sample edge feature matrix.

[0119] In some embodiments, the initial fault location model includes an input layer, a first edge graph attention layer, a second edge graph attention layer, a third edge graph attention layer, a fully connected layer, and an output layer, and step 10C specifically includes:

[0120] Step 10C1: input the data in the sample data set into the initial fault location model via the input layer.

[0121] Step 10C2, according to the sample admittance matrix and the sample node feature matrix, using the first edge graph attention layer to determine the target attention coefficient corresponding to the initial fault location model.

[0122] Step 10C3, based on the target attention coefficient and the sample edge feature matrix, the sample node feature matrix is ​​corrected to obtain the first initial sample node feature.

[0123] Step 10C4, inputting the first initial sample node feature into the second edge graph attention layer, using the second edge graph attention layer to perform feature fusion processing on the first initial sample node feature according to the sample admittance matrix and the sample edge feature matrix, to obtain the second initial sample node feature.

[0124] Step 10C5, input the second initial sample node features into the third edge graph attention layer, and use the third edge graph attention layer to perform feature fusion processing on the second initial sample node features according to the sample admittance matrix and the sample edge feature matrix to obtain the third initial sample node features.

[0125] Step 10C6, use the fully connected layer to perform mapping conversion processing on the third initial sample node features, and output the training results.

[0126] In specific implementation, the hierarchical structure of the initial fault location model is as follows: Figure 2 As shown in the figure, the initial fault location model is composed of three improved edge graph attention layers and a fully connected layer, and then Softmax activation is performed to output the fault discrimination result. The multi-head improved edge graph attention network is used to perform the node classification task to improve the fault node location accuracy. Specifically, it includes the input layer, the first edge graph attention layer, the second edge graph attention layer, the third edge graph attention layer, the fully connected layer and the output layer.

[0127] The data in the sample data set is input into the initial fault location model via the input layer, and the first edge graph attention layer is used to perform feature fusion processing on the sample node feature matrix according to the sample admittance matrix and the sample edge feature matrix to obtain the first initial sample node feature. The specific method for determining the first initial sample node feature is:

[0128] According to the sample admittance matrix and the sample node feature matrix, the target attention coefficient corresponding to the initial fault location model is determined by using the first edge graph attention layer. Based on the target attention coefficient and the sample edge feature matrix, the sample node feature matrix is ​​corrected to obtain the first initial sample node feature.

[0129] The first initial sample node feature is input into the second edge graph attention layer, and the second edge graph attention layer is used to perform feature fusion processing on the first initial sample node feature according to the sample admittance matrix and the sample edge feature matrix to obtain the second initial sample node feature. In this embodiment, the method for determining the second initial sample node feature is the same as the method for determining the first initial sample node feature, which will not be repeated here.

[0130] The second initial sample node feature is input into the third edge graph attention layer, and the third edge graph attention layer is used to perform feature fusion processing on the second initial sample node feature according to the sample admittance matrix and the sample edge feature matrix to obtain the third initial sample node feature. In this embodiment, the method for determining the third initial sample node feature is the same as the method for determining the first initial sample node feature, which will not be repeated here.

[0131] The fully connected layer is used to map and transform the node features of the third initial sample and output the training results.

[0132] Through the above scheme, the admittance matrix Y is integrated into the node feature aggregation process, and the edge feature information (line current) is directly added to the adjacent node features. On the basis of the original attention mechanism, the inherent attribute information (admittance matrix) and edge feature information (line current) of the distribution network are fully utilized to improve the accuracy of distribution network fault location.

[0133] In some embodiments, step 10C2 specifically includes:

[0134] Step 10C21, obtaining a first learning parameter, and determining a first initial attention coefficient corresponding to the sample distribution network topology structure according to the first learning parameter and the sample edge feature matrix, wherein the first initial attention coefficient is expressed by a formula:

[0135] α i ' j ′=LeakyReLU(a T [W h h i ∥W h h j ])

[0136] Among them, α i ' j ′ is the first initial attention coefficient, which is the parameter to be learned, LeakyReLU() is the nonlinear activation function, a T is the mapping matrix, W h is the first learning parameter, h i is the sample feature vector corresponding to the sample node i in the sample distribution network topology, h j is the sample feature vector corresponding to the sample node j in the sample distribution network topology;

[0137] Step 10C22, obtaining a second learning parameter, using the second learning parameter and the sample admittance matrix, correcting the first initial attention coefficient to obtain a second initial attention coefficient, wherein the second initial attention coefficient is expressed by the formula:

[0138] α i ' j =α i ' j ′+W y Y ij

[0139] Among them, α i ' j is the second initial attention coefficient, W yis the second learning parameter, Y ij is the admittance value of the directly connected branch between sample node i and sample node j in the sample admittance matrix;

[0140] Step 10C23, normalize the second initial attention coefficient to obtain a target attention coefficient, wherein the target attention coefficient is expressed by the formula:

[0141]

[0142] Among them, α ij is the target attention coefficient, N i is the neighbor node of sample node i, Y ik is the admittance value of the directly connected branch between sample node i and neighbor node k.

[0143] When implementing it, Figure 3 As shown, Figure 3 A schematic diagram of a calculation method of the initial attention coefficient corresponding to an embodiment of the present disclosure is shown. A first learning parameter is obtained, and a first initial attention coefficient corresponding to a sample distribution network topology structure is determined according to the first learning parameter and the sample edge feature matrix, wherein the first initial attention coefficient is expressed by a formula as follows:

[0144] α i ' j ′=LeakyReLU(a T [W h h i ∥W h h j ])

[0145] Among them, α i ' j ′ is the first initial attention coefficient, LeakyReLU() is the nonlinear activation function, a T is the mapping matrix, W h is the first learning parameter, h i is the sample feature vector corresponding to the sample node i in the sample distribution network topology, W h ∈R d×b ,h j is the sample feature vector corresponding to the sample node j in the sample distribution network topology structure. The matrix symbol || represents the vector concatenation operation. b is the number of input node features, d is the number of features of each node after GAL feature transformation. In this patent, d=2, a T Map the concatenated matrix to real numbers, a∈R (2×d)×1 , preferably a∈R 4×1 .

[0146] In this embodiment, LeakyReLU(.) is a nonlinear activation function commonly used in deep learning, which can be expressed as:

[0147]

[0148] In this embodiment, λ is set to 0.2.

[0149] In this embodiment, the first initial attention coefficient α i ' j ′ is the attention coefficient between each target node. The first initial attention coefficient calculated in the above way realizes the integration of the admittance matrix into the node feature aggregation process.

[0150] An admittance matrix is ​​added to the original attention coefficient, and the admittance matrix has the inherent electrical property information of the power grid between nodes and the nodes themselves. A second learning parameter is obtained, and the first initial attention coefficient is corrected using the second learning parameter and the sample admittance matrix to obtain a second initial attention coefficient, wherein the second initial attention coefficient is expressed by the formula:

[0151] α i ' j =α i ' j ′+W y Y ij

[0152] Among them, α i ' j is the second initial attention coefficient, W y is the second learning parameter, Y ij W is the admittance value of the directly connected branch between sample node i and sample node j in the sample admittance matrix. y ∈R 1×2 , the number of eigenvalues ​​of the admittance matrix is ​​2, W y The attribute information of the admittance matrix can be mapped and aggregated into the attention coefficient.

[0153] In order to compare the attention weights between different nodes, GAL uses the Softmax function to normalize the attention coefficients of all neighbor nodes of a target node to obtain the attention weights of each neighbor node.

[0154] The second initial attention coefficient is normalized to obtain a target attention coefficient, where the target attention coefficient is expressed by the formula:

[0155]

[0156] Among them, α ijis the target attention coefficient, N i is the neighbor node of sample node i, Y ik is the admittance value of the directly connected branch between sample node i and neighbor node k.

[0157] In some embodiments, for each sample feature vector in the sample node feature matrix, step 10C3 specifically includes:

[0158] Step 10C31, obtain the multi-head attention number of the first edge graph attention layer, based on the sample edge feature matrix and the multi-head attention number, weight the sample feature vector according to the target attention coefficient to obtain a new sample feature vector, wherein the new sample feature vector is expressed by the formula:

[0159]

[0160] Among them, h′ i is the new sample feature vector, K is the number of multi-head attention in the first edge graph attention layer, is the target attention coefficient of each neighbor node of the Kth group of attention mechanism, is the linear transformation weight matrix of the Kth group of node feature vectors, Make a linear transformation weight matrix for the Kth group of edge eigenvectors, e ij is the edge feature vector corresponding to the branch between sample node i and sample node j.

[0161] Step 10C32: determine the first initial sample node feature according to each new sample feature vector.

[0162] When implementing it, Figure 4 As shown, Figure 4 A schematic diagram of the introduction of the edge feature matrix of the embodiment of the present disclosure is shown. In order to ensure that the attention mechanism can learn stable node expressions, a multi-head attention mechanism is introduced to enhance the stability of the model. A third learning parameter is obtained, and the third learning parameter introduces a multi-head attention mechanism. The sample feature vector is weighted according to the target attention coefficient using multiple groups of third learning parameters and the sample edge feature matrix to obtain a new sample feature vector, and multiple groups of new sample feature vectors are spliced ​​or averaged to obtain the final result.

[0163] Specifically, the concatenation operation of multiple sets of new sample feature vectors is expressed by the formula:

[0164]

[0165] Specifically, the average operation of multiple groups of new sample feature vectors is expressed by the formula:

[0166]

[0167] Among them, h′ i is the new sample feature vector, K is the number of multi-head attention in the first edge graph attention layer, is the target attention coefficient of each neighbor node of the Kth group of attention mechanism, is the linear transformation weight matrix of the Kth group of node feature vectors, Make a linear transformation weight matrix for the Kth group of edge eigenvectors, W e is the third learning parameter, e ij is the edge feature vector corresponding to the branch between sample node i and sample node j;

[0168] In this embodiment, in order to improve the expression ability of the attention mechanism, the three edge graph attention layers preferably adopt a splicing operation. h ∈R d×b , is the weight matrix for linear transformation of each node feature, which is a learnable parameter, b is the number of input node features, d is the number of features of each node after the first edge graph attention layer feature transformation, and d=2 in this embodiment. e ∈R g×r , is the weight matrix for linear transformation of each edge feature, is a learnable parameter, r is the number of input edge features, in this patent r = 4, g is the number of features of each node after the first edge graph attention layer feature transformation, in this embodiment, g = 2.

[0169] In this embodiment, after improving the first edge graph attention layer, the output new node feature vector is still 4-dimensional. The eLU activation function is usually used in the EGAT model, and the function expression is:

[0170]

[0171] In this embodiment, the parameter β is usually taken as 1.

[0172] Determine the first initial sample node feature according to each new sample feature vector, and the first initial sample node feature is expressed by the formula:

[0173] H′=[h1′,h2′,h3′,...,h n ′]

[0174] Among them, H′ is the first initial sample node feature.

[0175] Through the above scheme, K independently working attention mechanisms are used to calculate the attention weights and update the node features respectively, and then the results obtained by each attention mechanism are concatenated or averaged to obtain the final result.

[0176] In this embodiment, online fault location of the distribution network is performed based on the trained fault location model. The real-time measurement information provided by the measurement points on the feeder is normalized and input into the trained edge graph attention layer, so that the fault section of the distribution network can be quickly and accurately located.

[0177] Based on the same inventive concept, another embodiment of the present disclosure provides a fault location method, which specifically includes:

[0178] Step A: Generate a distribution network graph structure adjacency matrix A and a node admittance matrix Y according to the distribution network topology.

[0179] When implementing it, Figure 5 As shown, Figure 5 The schematic diagram of the IEEE 33-node system is shown. This embodiment takes the IEEE 33-node network as an example to verify the advantages of the fault location method described in the embodiment of the present disclosure in terms of speed, accuracy and robustness when locating faults in the distribution network.

[0180] The adjacency matrix and admittance matrix of the IEEE 33-node network are:

[0181]

[0182]

[0183] Step B: Collect the voltage data of each node and the current data of each branch of the distribution network, and construct the node feature matrix H and the edge feature matrix E.

[0184] In the specific implementation, a graph network is constructed according to the actual topological structure, and the three-phase voltage amplitude and zero-sequence voltage amplitude collected by the measurement unit (PMU) in the measured area are used as the node feature vector h i =[U i1 ,U i2 ,U i3 ,U i0 ]. Collect the three-phase current and zero-sequence current of the line as the branch characteristic vector e ij =[I ij1 ,I ij2 ,I ij3 ,I ij0 ].

[0185] In the IEEE 33-node distribution network system, nodes refer to loads and power sources. For ease of understanding, monitoring components are set at the power source to regard it as a measurable line, making the total measurable line 33. A fault point is set at each node of the simulated IEEE 33-node distribution network system (except the power source node), and two fault points are randomly started each time the operation is performed, which are set as a single-phase grounding fault and a phase-to-phase short circuit fault respectively.

[0186] The fault grounding resistance values ​​were set to 0.01Ω, 500Ω and 2000Ω respectively, and the single-phase grounding type faults were simulated at different locations in different situations in three phases, and 100 fault simulation experiments were conducted. This patent is set to remove the fault 0.3 seconds after the fault occurs, and sampling starts from 0.1 seconds before the fault occurs. The current and voltage amplitude data are sampled at a frequency of 500Hz, and 200 sampling points are collected for each node, resulting in a feature data dimension of 1200 for each node. 20 data samples are collected in each of the above situations, and a total of 2000 sample data are generated.

[0187] Step C: construct a training sample set based on the collected data, normalize the feature matrices H and E in the collected samples to obtain sample feature matrices H' and E', and convert the sample fault conditions into positioning labels Y.

[0188] In the specific implementation, the collected sample data is normalized, and the minimum-maximum normalization method is used for the node feature matrix and the edge feature matrix to limit the input features to the range of [0,1].

[0189]

[0190]

[0191] Where: max(H) and max(E) are the maximum values ​​of node or edge features in the sample set; min(H) and min(E) are the minimum values ​​of node or edge features in the sample set.

[0192] The fault location conditions in the collected samples are converted into sample labels. The node labels of the buses at both ends of the faulty line are 1, and the node labels of the remaining buses are 0. The location label Y is generated according to the fault location of the distribution network.

[0193] Step D: build an improved edge graph attention neural network architecture, and train and construct a fault location network model based on the improved edge graph attention network.

[0194] The processed data is input into the improved edge graph attention network for training. In the fault binary classification task, the loss function uses the predicted label and the actual label to feedback the difference between the model classification prediction and the actual situation in real time during each iteration of training. The type of task determines the range of loss function selection. The cross entropy loss function is a commonly used binary classification loss function. The model finally needs to detect only two types of nodes. For the classification of distribution network fault nodes, the following loss expression can be used

[0195]

[0196] Where class is the label value of the sample category, and y is the label predicted by the model. Finally, the Loss value is minimized through the optimizer to maximize the accuracy of classification.

[0197] Through multiple experiments, the learning rate was adjusted to 0.006, the batch size was 8, and the number of iterations was set to 50. GAT was used to establish a fault location model containing distribution network topology information. When the initial phase angle of the fault was 0°, the fault grounding resistance was 0.01Ω, and the fault location was 50% of the fault branch, the fault location result was obtained. Figure 6 The algorithm training results for fault location of a single-phase grounding fault in the distribution network are shown.

[0198] from Figure 6 It can be seen that after 20 iterations, the model can achieve 90% fault location accuracy. After 40 iterations, the accuracy can reach 98%, and the loss rate is reduced to about 0.12. This shows that the GNN-based distribution network small current grounding fault location model has the advantages of fast and accurate.

[0199] Step E: Perform online fault location of the distribution network based on the trained fault location model.

[0200] In the specific implementation, the online fault location of the distribution network is performed based on the trained fault location model. The micro-F1 score is used to evaluate the fault location model of the distribution network. The calculation formula of the micro-F1 score is as follows:

[0201]

[0202]

[0203]

[0204] TPi means that the i-th sample itself is a positive sample, and the prediction is also a positive sample, that is, the distribution network is successfully determined to be in a normal state; FPi means that the i-th sample itself is a negative sample, and the prediction is a positive sample, that is, the fault state is judged to be a normal state; FNi means that the i-th sample itself is a positive sample, and is mistakenly predicted as a negative sample, that is, the normal state is judged to be a fault state. Assume that there are c types of samples, where pc represents the overall accuracy and rc represents the overall recall rate. Micro-F1, as the harmonic mean of the total accuracy (pc) and the total recall rate (rc), takes these two indicators into account and is suitable for model verification in multi-classification with data imbalance problems.

[0205] It should be noted that the method of the embodiment of the present disclosure can be performed by a single device, such as a computer or a server. The method of the present embodiment can also be applied in a distributed scenario and completed by multiple devices cooperating with each other. In the case of such a distributed scenario, one of the multiple devices can only perform one or more steps in the method of the embodiment of the present disclosure, and the multiple devices will interact with each other to complete the described method.

[0206] It should be noted that the above describes some embodiments of the present disclosure. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the above embodiments and still achieve the desired results. In addition, the processes depicted in the accompanying drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0207] Based on the same inventive concept, corresponding to any of the above-mentioned embodiment methods, the present disclosure also provides a distribution network fault location device based on an improved edge graph attention mechanism.

[0208] refer to Figure 7 , Figure 7 The invention provides a distribution network fault location device based on an improved edge graph attention mechanism according to an embodiment, comprising:

[0209] An adjacency matrix determination module is configured to obtain a distribution network topology structure, and determine a distribution network adjacency matrix and an admittance matrix according to the distribution network topology structure;

[0210] The feature vector determination module is configured to: for each target node in the distribution network topology:

[0211] Obtaining a voltage value corresponding to a target node, and determining a node feature vector corresponding to the target node according to the voltage value;

[0212] Obtaining current values ​​corresponding to branches between target nodes, and determining edge feature vectors corresponding to branches between target nodes according to the current values;

[0213] A feature matrix determination module is configured to determine a node feature matrix corresponding to a distribution network topology structure according to a node feature vector corresponding to each target node, and to determine an edge feature matrix corresponding to a distribution network topology structure according to an edge feature vector corresponding to a branch between each target node;

[0214] The fault node determination module is configured to input the distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix into a pre-trained fault location model, and output the fault node in the distribution network via the fault location model.

[0215] In some embodiments, the adjacency matrix determination module specifically includes:

[0216] An adjacency matrix determination unit is configured to perform matrix processing on the distribution network topology structure to obtain a distribution network adjacency matrix;

[0217] An admittance value determination unit is configured to obtain attribute information of a distribution network element, and determine an admittance value corresponding to each eigenvector in the distribution network adjacency matrix according to the attribute information of the distribution network element and the distribution network adjacency matrix;

[0218] The admittance matrix determining unit is configured to determine the admittance matrix according to the admittance value corresponding to each eigenvector.

[0219] In some embodiments, the admittance value determining unit is specifically configured as follows:

[0220] For each eigenvector:

[0221] The position of the eigenvector in the distribution network adjacency matrix is ​​determined, and the admittance value corresponding to the eigenvector is determined according to the position and the attribute information of the distribution network element. The admittance value is expressed by the formula:

[0222]

[0223] Among them, Y ij is the admittance value of the eigenvector in the i-th row and j-th column in the distribution network adjacency matrix, which represents the admittance value between the target node i and the target node j. When i and j are not equal, the admittance value represents the mutual admittance value between the target node i and the target node j. When i and j are equal, the admittance value represents the self-admittance value of the target node i. i0 is the parallel admittance value of the target node i, m is the number of target nodes of the branch directly connected to the target node i, k is the target node of the branch directly connected to the kth target node i, y ikis the mutual admittance value between the target node i and the target node of the kth branch directly connected to the target node i, y ij is the admittance value of the branch directly connected between target node i and target node j, a ij is the connection status between target node i and target node j, where a ij =1 indicates that the target node i is connected to the target node j via a line, ij =0 means there is no line connection between target node i and target node j.

[0224] In some embodiments, the feature vector determination module is specifically configured to:

[0225] Obtain the three-phase voltage amplitude and zero-sequence voltage amplitude corresponding to the target node;

[0226] A node characteristic vector corresponding to the target node is constructed according to the three-phase voltage amplitude and the zero-sequence voltage amplitude, wherein the node characteristic vector is expressed by the formula:

[0227] h i =[U i1 ,U i2 ,U i3 ,U i0 ]

[0228] Among them, h i is the node feature vector corresponding to the target node i, U i1 ,U i2 ,U i3 is the three-phase voltage amplitude corresponding to the target node i, U i0 is the zero-sequence voltage amplitude corresponding to the target node i.

[0229] In some embodiments, the feature vector determination module is specifically configured to:

[0230] Obtain the three-phase current amplitude and zero-sequence current amplitude corresponding to the target node;

[0231] A node feature vector corresponding to the target node is constructed according to the three-phase current amplitude and the zero-sequence current amplitude, wherein the edge feature vector is expressed by the formula:

[0232]

[0233] Among them, e ij is the edge feature vector corresponding to the target node i, I ij1 ,I ij2 ,I ij3 is the three-phase current amplitude corresponding to the target node i flowing to the target node j, I ij0 is the zero-sequence current amplitude corresponding to the target node i.

[0234] In some embodiments, the device further includes a training module, and the training module specifically includes:

[0235] A data acquisition unit is configured to acquire a sample distribution network adjacency matrix corresponding to a sample distribution network topology structure, a sample admittance matrix corresponding to the sample distribution network adjacency matrix, a sample node feature matrix corresponding to the sample distribution network adjacency matrix, a sample edge feature matrix corresponding to the sample distribution network adjacency matrix, and an actual fault node corresponding to the sample distribution network adjacency matrix;

[0236] A sample data set determination unit is configured to use the actual fault node to mark the sample distribution network adjacency matrix, the sample admittance matrix, the sample node feature matrix and the sample edge feature matrix to obtain a sample data set;

[0237] The model training unit is configured to obtain an initial fault location model, train the initial fault location model using data in the sample data set, until a preset training end condition is met, and obtain the fault location model.

[0238] In some embodiments, the initial fault location model includes an input layer, a first edge graph attention layer, a second edge graph attention layer, a third edge graph attention layer, a fully connected layer and an output layer, and the model training unit specifically includes:

[0239] An input subunit, configured to input the data in the sample data set into an initial fault location model via an input layer;

[0240] A target attention coefficient determination subunit is configured to determine a target attention coefficient corresponding to an initial fault location model using a first edge graph attention layer according to the sample admittance matrix and the sample node feature matrix;

[0241] A first initial sample node feature determination subunit is configured to perform correction processing on the sample node feature matrix based on the target attention coefficient and the sample edge feature matrix to obtain a first initial sample node feature;

[0242] The second initial sample node feature determination subunit is configured to input the first initial sample node feature into the second edge graph attention layer, and use the second edge graph attention layer to perform feature fusion processing on the first initial sample node feature according to the sample admittance matrix and the sample edge feature matrix to obtain the second initial sample node feature;

[0243] A third initial sample node feature determination subunit is configured to input the second initial sample node feature into a third edge graph attention layer, and use the third edge graph attention layer to perform feature fusion processing on the second initial sample node feature according to the sample admittance matrix and the sample edge feature matrix to obtain a third initial sample node feature;

[0244] The mapping conversion subunit is configured to use the fully connected layer to perform mapping conversion processing on the third initial sample node feature and output the training result.

[0245] In some embodiments, the target attention coefficient determination subunit is specifically configured as:

[0246] A first learning parameter is obtained, and a first initial attention coefficient corresponding to the sample distribution network topology structure is determined according to the first learning parameter and the sample edge feature matrix, wherein the first initial attention coefficient is expressed by a formula as follows:

[0247] α″ ij =LeakyreLU(a T [W h h i ||W h h j ])

[0248] Among them, α″ ij is the first initial attention coefficient, LeakyReLU() is the nonlinear activation function, a T is the mapping matrix, W h is the first learning parameter, h i is the sample feature vector corresponding to the sample node i in the sample distribution network topology, h j is the sample feature vector corresponding to the sample node j in the sample distribution network topology;

[0249] Obtain a second learning parameter, and use the second learning parameter and the sample admittance matrix to correct the first initial attention coefficient to obtain a second initial attention coefficient, wherein the second initial attention coefficient is expressed by the formula:

[0250] α′ ij =α″ ij +W y Y ij

[0251] Among them, α′ ij is the second initial attention coefficient, W y is the second learning parameter, Y ij is the admittance value of the directly connected branch between sample node i and sample node j in the sample admittance matrix;

[0252] The second initial attention coefficient is normalized to obtain a target attention coefficient, where the target attention coefficient is expressed by the formula:

[0253]

[0254] Among them, α ij is the target attention coefficient, N i is the neighbor node of sample node i, Y ik is the admittance value of the directly connected branch between sample node i and neighbor node k.

[0255] In some embodiments, the first initial sample node feature determination subunit is specifically configured as follows:

[0256] For each sample feature vector in the sample node feature matrix:

[0257] The multi-head attention number of the first edge graph attention layer is obtained, and based on the sample edge feature matrix and the multi-head attention number, the sample feature vector is weighted according to the target attention coefficient to obtain a new sample feature vector, wherein the new sample feature vector is expressed by the formula:

[0258]

[0259] Among them, h′ i is the new sample feature vector, K is the number of multi-head attention in the first edge graph attention layer, is the target attention coefficient of each neighbor node of the Kth group of attention mechanism, is the linear transformation weight matrix of the Kth group of node feature vectors, Make a linear transformation weight matrix for the Kth group of edge eigenvectors, e ij is the edge feature vector corresponding to the branch between sample node i and sample node j;

[0260] A first initial sample node feature is determined according to each new sample feature vector.

[0261] For the convenience of description, the above device is described by dividing it into various modules according to its functions. Of course, when implementing the present disclosure, the functions of each module can be implemented in the same or multiple software and / or hardware.

[0262] The device of the above embodiment is used to implement the corresponding distribution network fault location method based on the improved edge graph attention mechanism in any of the above embodiments, and has the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0263] Based on the same inventive concept, corresponding to any of the above-mentioned embodiments and methods, the present disclosure also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the distribution network fault location method based on the improved edge graph attention mechanism described in any of the above embodiments is implemented.

[0264] Figure 8 A more specific schematic diagram of the hardware structure of an electronic device provided in this embodiment is shown, and the device may include: a processor 1010, a memory 1020, an input / output interface 1030, a communication interface 1040, and a bus 1050. The processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040 are connected to each other through the bus 1050 in the device.

[0265] The processor 1010 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification.

[0266] The memory 1020 may be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 1020 may store an operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program codes are stored in the memory 1020 and are called and executed by the processor 1010.

[0267] The input / output interface 1030 is used to connect the input / output module to realize information input and output. The input / output module can be configured in the device as a component (not shown in the figure), or it can be externally connected to the device to provide corresponding functions. The input device may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device may include a display, a speaker, a vibrator, an indicator light, etc.

[0268] The communication interface 1040 is used to connect a communication module (not shown) to realize communication interaction between the device and other devices. The communication module can realize communication through a wired mode (such as USB, network cable, etc.) or a wireless mode (such as mobile network, WIFI, Bluetooth, etc.).

[0269] The bus 1050 includes a path that transmits information between the various components of the device (eg, the processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040).

[0270] It should be noted that, although the above device only shows the processor 1010, the memory 1020, the input / output interface 1030, the communication interface 1040 and the bus 1050, in the specific implementation process, the device may also include other components necessary for normal operation. In addition, it can be understood by those skilled in the art that the above device may also only include the components necessary for implementing the embodiments of the present specification, and does not necessarily include all the components shown in the figure.

[0271] The electronic device of the above embodiment is used to implement the corresponding distribution network fault location method based on the improved edge graph attention mechanism in any of the above embodiments, and has the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0272] Based on the same inventive concept, corresponding to any of the above-mentioned embodiment methods, the present disclosure also provides a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the distribution network fault location method based on the improved edge graph attention mechanism as described in any of the above embodiments.

[0273] The computer-readable medium of this embodiment includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.

[0274] The computer instructions stored in the storage medium of the above embodiment are used to enable the computer to execute the distribution network fault location method based on the improved edge graph attention mechanism as described in any of the above embodiments, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0275] It is understandable that before using the technical solutions of each embodiment of the present disclosure, the type, scope of use, usage scenarios, etc. of the personal information involved will be informed to the user in an appropriate manner, and the user's authorization will be obtained.

[0276] For example, in response to receiving an active request from a user, a prompt message is sent to the user to clearly remind the user that the operation requested to be performed will require obtaining and using the user's personal information. Thus, the user can independently choose whether to provide personal information to software or hardware such as an electronic device, application, server, or storage medium that performs the operation of the technical solution of the present disclosure according to the prompt message.

[0277] As an optional but non-limiting implementation, in response to receiving the user's active request, the prompt information may be sent to the user in the form of a pop-up window, in which the prompt information may be presented in text form. In addition, the pop-up window may also carry a selection control for the user to choose "agree" or "disagree" to provide personal information to the electronic device.

[0278] It is understandable that the above notification and the process of obtaining user authorization are merely illustrative and do not constitute a limitation on the implementation of the present disclosure. Other methods that meet relevant laws and regulations may also be applied to the implementation of the present disclosure.

[0279] Those skilled in the art should understand that the discussion of any of the above embodiments is merely illustrative and is not intended to imply that the scope of the present disclosure (including the claims) is limited to these examples. Based on the concept of the present disclosure, the technical features in the above embodiments or different embodiments may be combined, the steps may be implemented in any order, and there are many other variations of the different aspects of the embodiments of the present disclosure as described above, which are not provided in detail for the sake of simplicity.

[0280] In addition, to simplify the description and discussion, and in order not to make the embodiments of the present disclosure difficult to understand, the known power / ground connections to the integrated circuit (IC) chips and other components may or may not be shown in the provided figures. In addition, the device can be shown in the form of a block diagram to avoid making the embodiments of the present disclosure difficult to understand, and this also takes into account the fact that the details of the implementation of these block diagram devices are highly dependent on the platform on which the embodiments of the present disclosure will be implemented (that is, these details should be fully within the scope of understanding of those skilled in the art). Where specific details (e.g., circuits) are set forth to describe exemplary embodiments of the present disclosure, it is apparent to those skilled in the art that the embodiments of the present disclosure can be implemented without these specific details or with changes in these specific details. Therefore, these descriptions should be considered illustrative rather than restrictive.

[0281] Although the present disclosure has been described in conjunction with specific embodiments of the present disclosure, many replacements, modifications and variations of these embodiments will be apparent to those skilled in the art from the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may use the embodiments discussed.

[0282] The embodiments of the present disclosure are intended to cover all such substitutions, modifications and variations that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the embodiments of the present disclosure should be included in the scope of protection of the present disclosure.

Claims

1. A distribution network fault location method based on an improved edge graph attention mechanism, characterized in that: include: Acquire a distribution network topology structure, and determine a distribution network adjacency matrix and an admittance matrix according to the distribution network topology structure; For each target node in the distribution network topology: Obtaining a voltage value corresponding to a target node, and determining a node feature vector corresponding to the target node according to the voltage value; Obtaining current values ​​corresponding to branches between target nodes, and determining edge feature vectors corresponding to branches between target nodes according to the current values; Determine the node feature matrix corresponding to the topology of the distribution network according to the node feature vector corresponding to each target node, and determine the edge feature matrix corresponding to the topology of the distribution network according to the edge feature vector corresponding to the branch between each target node; The distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix are input into a pre-trained fault location model, and the fault node in the distribution network is output through the fault location model.

2. The method according to claim 1, characterized in that: The determining of the distribution network adjacency matrix and the admittance matrix according to the distribution network topology structure includes: Matrixing the distribution network topology to obtain a distribution network adjacency matrix; Acquire attribute information of distribution network components, and determine the admittance value corresponding to each eigenvector in the distribution network adjacency matrix according to the attribute information of the distribution network components and the distribution network adjacency matrix; The admittance matrix is ​​determined according to the admittance value corresponding to each eigenvector.

3. The method according to claim 2, characterized in that The step of determining the admittance value corresponding to each eigenvector in the distribution network adjacency matrix according to the distribution network element attribute information and the distribution network adjacency matrix comprises: For each eigenvector: The position of the eigenvector in the distribution network adjacency matrix is ​​determined, and the admittance value corresponding to the eigenvector is determined according to the position and the attribute information of the distribution network element. The admittance value is expressed by the formula: Among them, Y ij is the admittance value of the eigenvector in the i-th row and j-th column in the distribution network adjacency matrix, which represents the admittance value between the target node i and the target node j. When i and j are not equal, the admittance value represents the mutual admittance value between the target node i and the target node j. When i and j are equal, the admittance value represents the self-admittance value of the target node i. i0 is the parallel admittance value of the target node i, m is the number of target nodes of the branch directly connected to the target node i, k is the target node of the branch directly connected to the kth target node i, y ik is the mutual admittance value between the target node i and the target node of the kth branch directly connected to the target node i, y ij is the admittance value of the branch directly connected between target node i and target node j, a ij is the connection status between target node i and target node j, where a ij =1 indicates that the target node i is connected to the target node j via a line, ij =0 means there is no line connection between target node i and target node j.

4. The method according to claim 1, characterized in that The obtaining of a voltage value corresponding to the target node and determining a node feature vector corresponding to the target node according to the voltage value include: Obtain the three-phase voltage amplitude and zero-sequence voltage amplitude corresponding to the target node; A node characteristic vector corresponding to the target node is constructed according to the three-phase voltage amplitude and the zero-sequence voltage amplitude, wherein the node characteristic vector is expressed by the formula: h i =[U i1 ,IN i2 ,IN i3 ,IN i0 ] Among them, h i is the node feature vector corresponding to the target node i, U i1 ,U i2 ,U i3 is the three-phase voltage amplitude corresponding to the target node i, U i0 is the zero-sequence voltage amplitude corresponding to the target node i.

5. The method according to claim 1, characterized in that The obtaining of current values ​​corresponding to the branches between the target nodes and determining edge feature vectors corresponding to the branches between the target nodes according to the current values ​​include: Obtain the three-phase current amplitude and zero-sequence current amplitude corresponding to the target node; The edge feature vector corresponding to the branch between the target nodes is constructed according to the three-phase current amplitude and the zero-sequence current amplitude, wherein the edge feature vector is expressed by the formula: Among them, e ij is the edge feature vector corresponding to the branch between target node i and target node j, I ij1 ,I ij2 ,I ij3 is the three-phase current amplitude corresponding to the target node i flowing to the target node j, I ij0 is the zero-sequence current amplitude corresponding to the target node i.

6. The method according to claim 1, characterized in that The training process of the fault location model includes: Obtaining a sample distribution network adjacency matrix corresponding to a sample distribution network topology structure, a sample admittance matrix corresponding to the sample distribution network adjacency matrix, a sample node feature matrix corresponding to the sample distribution network adjacency matrix, a sample edge feature matrix corresponding to the sample distribution network adjacency matrix, and an actual fault node corresponding to the sample distribution network adjacency matrix; Using the actual fault node to mark the sample distribution network adjacency matrix, the sample admittance matrix, the sample node feature matrix and the sample edge feature matrix, to obtain a sample data set; An initial fault location model is obtained, and the initial fault location model is trained using the data in the sample data set until a preset training end condition is met, thereby obtaining a fault location model.

7. The method according to claim 6, characterized in that The initial fault location model includes an input layer, a first edge graph attention layer, a second edge graph attention layer, a third edge graph attention layer, a fully connected layer and an output layer. The method of training the initial fault location model using the data in the sample data set includes: Inputting the data in the sample data set into the initial fault location model via the input layer; Determine a target attention coefficient corresponding to an initial fault location model using a first edge graph attention layer according to the sample admittance matrix and the sample node feature matrix; Based on the target attention coefficient and the sample edge feature matrix, the sample node feature matrix is ​​modified to obtain the first initial sample node feature; Inputting the first initial sample node feature into the second edge graph attention layer, and using the second edge graph attention layer to perform feature fusion processing on the first initial sample node feature according to the sample admittance matrix and the sample edge feature matrix to obtain the second initial sample node feature; Inputting the second initial sample node feature into the third edge graph attention layer, and using the third edge graph attention layer to perform feature fusion processing on the second initial sample node feature according to the sample admittance matrix and the sample edge feature matrix to obtain the third initial sample node feature; The fully connected layer is used to map and transform the node features of the third initial sample and output the training results.

8. The method according to claim 7, characterized in that The determining, according to the sample admittance matrix and the sample node feature matrix, a target attention coefficient corresponding to the initial fault location model using a first edge graph attention layer includes: A first learning parameter is obtained, and a first initial attention coefficient corresponding to the sample distribution network topology structure is determined according to the first learning parameter and the sample edge feature matrix, wherein the first initial attention coefficient is expressed by a formula as follows: α″ ij =LeakyReLU(a T [IN h h i ||In h h j ]) Among them, α″ ij is the first initial attention coefficient, LeakyReLU() is the nonlinear activation function, a T is the mapping matrix, W h is the first learning parameter, h i is the sample feature vector corresponding to the sample node i in the sample distribution network topology, h j is the sample feature vector corresponding to the sample node j in the sample distribution network topology; Obtain a second learning parameter, and use the second learning parameter and the sample admittance matrix to correct the first initial attention coefficient to obtain a second initial attention coefficient, wherein the second initial attention coefficient is expressed by the formula: a' ij =a″ ij +W y Y ij Among them, α′ ij is the second initial attention coefficient, W y is the second learning parameter, Y ij is the admittance value of the directly connected branch between sample node i and sample node j in the sample admittance matrix; The second initial attention coefficient is normalized to obtain a target attention coefficient, where the target attention coefficient is expressed by the formula: Among them, α ij is the target attention coefficient, N i is the neighbor node of sample node i, Y ik is the admittance value of the directly connected branch between sample node i and neighbor node k.

9. The method according to claim 7, characterized in that: The method of performing correction processing on the sample node feature matrix based on the target attention coefficient and the sample edge feature matrix to obtain the first initial sample node feature includes: For each sample feature vector in the sample node feature matrix: The multi-head attention number of the first edge graph attention layer is obtained, and based on the sample edge feature matrix and the multi-head attention number, the sample feature vector is weighted according to the target attention coefficient to obtain a new sample feature vector, wherein the new sample feature vector is expressed by the formula: Among them, h′ i is the new sample feature vector, K is the number of multi-head attention in the first edge graph attention layer, is the target attention coefficient of each neighbor node of the Kth group of attention mechanism, is the linear transformation weight matrix of the Kth group of node feature vectors, Make a linear transformation weight matrix for the Kth group of edge eigenvectors, e ij is the edge feature vector corresponding to the branch between sample node i and sample node j; A first initial sample node feature is determined according to each new sample feature vector.

10. A distribution network fault location device based on an improved edge graph attention mechanism, characterized in that: include: An adjacency matrix determination module is configured to obtain a distribution network topology structure, and determine a distribution network adjacency matrix and an admittance matrix according to the distribution network topology structure; The feature vector determination module is configured to: for each target node in the distribution network topology: Obtaining a voltage value corresponding to a target node, and determining a node feature vector corresponding to the target node according to the voltage value; Obtaining current values ​​corresponding to branches between target nodes, and determining edge feature vectors corresponding to branches between target nodes according to the current values; A feature matrix determination module is configured to determine a node feature matrix corresponding to a distribution network topology structure according to a node feature vector corresponding to each target node, and to determine an edge feature matrix corresponding to a distribution network topology structure according to an edge feature vector corresponding to a branch between each target node; The fault node determination module is configured to input the distribution network adjacency matrix, the admittance matrix, the node feature matrix and the edge feature matrix into a pre-trained fault location model, and output the fault node in the distribution network via the fault location model.

Citation Information

Cited By

  • Data processing method, device and equipment

    CN119513921A

  • Characteristic decoupling graph network-based power grid fault positioning method and system

    CN120064874A