Power grid single fault positioning method and device, terminal equipment and storage medium

By constructing a graph neural network model and combining it with power grid topology information, the problem of low accuracy in locating single faults in the power grid in existing technologies has been solved, achieving higher fault location accuracy.

CN118962337AActive Publication Date: 2024-11-15GUANGDONG POWER GRID CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411114327.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-14
Publication Date
2024-11-15
Estimated Expiration
2044-08-14

AI Technical Summary

Technical Problem

Existing artificial intelligence methods fail to effectively consider the topological information between power grid nodes and branches in the localization of single faults in power grids, resulting in low accuracy in fault location.

Method used

A graph neural network model is constructed. By obtaining the node three-phase current matrix, node three-phase voltage matrix, branch power matrix, branch adjacency matrix, and node adjacency matrix of the power grid, and combining graph attention network and feature network layer, the model is optimized to output the faulty component, taking into account the topological relationship.

Benefits of technology

It improves the accuracy of the single fault location model, enabling more precise identification of fault nodes or branches in the power grid.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118962337A_ABST
    Figure CN118962337A_ABST
Patent Text Reader

Abstract

The invention discloses a power grid single fault positioning method and device, terminal equipment and a storage medium. The method comprises the following steps: acquiring a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of a to-be-detected power grid; wherein the to-be-detected power grid only has one fault; inputting the node three-phase current matrix, the node three-phase voltage matrix, the branch power matrix, the branch adjacency matrix and the node adjacency matrix of the to-be-detected power grid into a single fault positioning model, so that the single fault positioning model outputs a fault component of the to-be-detected power grid; wherein the components comprise nodes and branches. By implementing the method, the topological structure relationship between the power grid nodes and the branches can be fully considered, and the accuracy of the output result of the single fault positioning model is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of fault location, and in particular to a method, device, terminal equipment and storage medium for locating a single fault in a power grid. Background Art

[0002] In the power system, single fault location refers to a method that can accurately determine the location of the fault when a single component (for example, a transmission line or a transformer) fails. This method is crucial to ensuring the reliability of the power grid and quickly restoring power supply. The existing methods for locating single faults mainly include line longitudinal protection, transformer protection, telemetry signal analysis, fault recording analysis, and artificial intelligence methods. The existing mainstream methods are mainly artificial intelligence methods to achieve single fault location. These methods learn historical fault data and automatically extract fault features to achieve rapid fault location. However, the existing artificial intelligence methods do not take into account the topological structure information between power grid nodes and branches, which leads to the failure to consider the impact of the connection relationship between nodes and branches during fault location analysis, resulting in low accuracy in fault location. Summary of the invention

[0003] The embodiments of the present invention provide a method, an apparatus, a terminal device and a storage medium for locating a single fault in a power grid, which can fully consider the topological structure relationship between power grid nodes and branches and improve the accuracy of the output results of a single fault location model.

[0004] An embodiment of the present invention provides a method for locating a single fault in a power grid, comprising:

[0005] Obtaining a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of a power grid to be detected; wherein the power grid to be detected has only one fault;

[0006] The node three-phase current matrix, node three-phase voltage matrix, branch power matrix, branch adjacency matrix and node adjacency matrix of the power grid to be detected are input into a single fault location model so that the single fault location model outputs a fault component of the power grid to be detected; wherein the component includes nodes and branches.

[0007] Furthermore, the construction of the single fault location model includes:

[0008] Acquire historical fault data of the power grid, and determine a training sample set according to the historical fault data; wherein the training sample set includes: node three-phase current matrix samples, node three-phase voltage matrix samples, branch power matrix samples, branch adjacency matrix samples, node adjacency matrix samples and fault label matrix;

[0009] A graph neural network is constructed, and the graph neural network is trained with the training sample set, and a single fault location model is generated when the graph neural network reaches a preset convergence condition.

[0010] Further, the single fault location model includes: a first graph attention network layer, a second graph attention network layer, a first feature network layer, a second feature network layer, a third feature network layer, a fourth feature network layer, a first normalization layer, and a second normalization layer;

[0011] The step of inputting a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected into a single fault location model comprises:

[0012] Generate a node three-phase current and voltage matrix by splicing the node three-phase current matrix and the node three-phase voltage matrix;

[0013] Inputting the node three-phase current and voltage matrix and the node adjacency matrix into a first graph attention network layer, so that the first graph attention network layer aggregates adjacent node information to obtain a first aggregated output;

[0014] Inputting the branch power matrix and the branch adjacency matrix into a second graph attention network layer, so that the second graph attention network layer aggregates the branch information to obtain a second aggregated output;

[0015] The first aggregate output and the second aggregate output are input into a first feature network layer, so that the first feature network layer extracts first feature data and inputs the first feature data into a second feature network layer;

[0016] The second feature network layer optimizes the first feature data to generate second feature data, and inputs the second feature data into the third feature network layer via the first normalization layer;

[0017] The third feature network layer adjusts the second feature data to generate third feature data, and inputs the third feature data into the fourth feature network layer via the second normalization layer, so that the fourth feature network layer outputs a fault component of the power grid to be detected in combination with the Softmax function;

[0018] Among them, the first characteristic data includes: three-phase current characteristics of the first node, three-phase voltage characteristics of the first node, topological characteristics of the first node, power characteristics of the first branch and topological characteristics of the first branch; the second characteristic data includes: three-phase current characteristics of the second node, three-phase voltage characteristics of the second node, topological characteristics of the second node, power characteristics of the second branch and topological characteristics of the second branch; the third characteristic data includes: three-phase current characteristics of the third node, three-phase voltage characteristics of the third node, topological characteristics of the third node, power characteristics of the third branch and topological characteristics of the third branch.

[0019] Furthermore, the preset convergence condition includes: when a preset number of iterations is reached or the loss function is minimized;

[0020] The loss function is specifically:

[0021]

[0022] in, represents the loss function of the graph neural network; N is the total number of nodes in the power grid to be detected; M is the total number of branches in the power grid to be detected; y is the one-hot encoding vector of the fault label; is the probability distribution vector of the predicted fault label of the graph neural network.

[0023] Based on the above method embodiment, the present invention provides a corresponding device embodiment;

[0024] An embodiment of the present invention provides a single fault location device for a power grid, including: a data acquisition module and a fault location module;

[0025] The data acquisition module is used to acquire a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected;

[0026] The fault location module is used to input the node three-phase current matrix, node three-phase voltage matrix, branch power matrix, branch adjacency matrix and node adjacency matrix of the power grid to be detected into a single fault location model, so that the single fault location model outputs a fault component of the power grid to be detected; wherein the component includes nodes and branches.

[0027] Furthermore, the construction of the single fault location model includes:

[0028] Acquire historical fault data of the power grid, and determine a training sample set according to the historical fault data; wherein the training sample set includes: node three-phase current matrix samples, node three-phase voltage matrix samples, branch power matrix samples, branch adjacency matrix samples, node adjacency matrix samples and fault label matrix;

[0029] A graph neural network is constructed, and the graph neural network is trained with the training sample set, and a single fault location model is generated when the graph neural network reaches a preset convergence condition.

[0030] Further, the single fault location model includes: a first graph attention network layer, a second graph attention network layer, a first feature network layer, a second feature network layer, a third feature network layer, a fourth feature network layer, a first normalization layer, and a second normalization layer;

[0031] The step of inputting a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected into a single fault location model comprises:

[0032] Generate a node three-phase current and voltage matrix by splicing the node three-phase current matrix and the node three-phase voltage matrix;

[0033] Inputting the node three-phase current and voltage matrix and the node adjacency matrix into a first graph attention network layer, so that the first graph attention network layer aggregates adjacent node information to obtain a first aggregated output;

[0034] Inputting the branch power matrix and the branch adjacency matrix into a second graph attention network layer, so that the second graph attention network layer aggregates the branch information to obtain a second aggregated output;

[0035] The first aggregate output and the second aggregate output are input into a first feature network layer, so that the first feature network layer extracts first feature data and inputs the first feature data into a second feature network layer;

[0036] The second feature network layer optimizes the first feature data to generate second feature data, and inputs the second feature data into the third feature network layer via the first normalization layer;

[0037] The third feature network layer adjusts the second feature data to generate third feature data, and inputs the third feature data into the fourth feature network layer via the second normalization layer, so that the fourth feature network layer outputs a fault component of the power grid to be detected in combination with the Softmax function;

[0038] Among them, the first characteristic data includes: three-phase current characteristics of the first node, three-phase voltage characteristics of the first node, topological characteristics of the first node, power characteristics of the first branch and topological characteristics of the first branch; the second characteristic data includes: three-phase current characteristics of the second node, three-phase voltage characteristics of the second node, topological characteristics of the second node, power characteristics of the second branch and topological characteristics of the second branch; the third characteristic data includes: three-phase current characteristics of the third node, three-phase voltage characteristics of the third node, topological characteristics of the third node, power characteristics of the third branch and topological characteristics of the third branch.

[0039] Furthermore, the preset convergence condition includes: when a preset number of iterations is reached or the loss function is minimized;

[0040] The loss function is specifically:

[0041]

[0042] in, represents the loss function of the graph neural network; N is the total number of nodes in the power grid to be detected; M is the total number of branches in the power grid to be detected; y is the one-hot encoding vector of the fault label; is the probability distribution vector of the predicted fault label of the graph neural network.

[0043] Another embodiment of the present invention provides a terminal device, including a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, and when the processor executes the computer program, a single fault location method for a power grid described in the above-mentioned embodiment of the invention is implemented.

[0044] Another embodiment of the present invention provides a storage medium, which includes a stored computer program, wherein when the computer program is running, the device where the storage medium is located is controlled to execute the power grid single fault location method described in the above-mentioned invention embodiment.

[0045] The following beneficial effects are achieved by implementing the present invention:

[0046] The present invention provides a method, device, terminal equipment and storage medium for locating a single fault in a power grid. The method for locating a single fault in a power grid obtains a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of a power grid to be detected with only one fault, and then inputs the obtained data of the power grid to be detected into a single fault location model, so that the single fault location model outputs a faulty node or a faulty branch in the power grid to be detected; when judging the fault of the power grid to be detected, the branch adjacency matrix and the node adjacency matrix are considered when the fault is located by inputting the single fault location model, and the node topology structure and the branch topology structure in the power grid to be detected are determined based on the adjacency matrix, thereby improving the accuracy of the output result of the single fault location model. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] Figure 1 It is a flow chart of a method for locating a single fault in a power grid provided in one embodiment of the present invention.

[0048] Figure 2 It is a schematic diagram of a single fault location network structure provided by an embodiment of the present invention.

[0049] Figure 3 It is a structural schematic diagram of a power grid single fault locating device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0050] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0051] like Figure 1 As shown, a method for locating a single fault in a power grid provided by an embodiment of the present invention includes:

[0052] Step S1: obtaining a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of a power grid to be detected; wherein the power grid to be detected has only one fault;

[0053] Step S2: input the node three-phase current matrix, node three-phase voltage matrix, branch power matrix, branch adjacency matrix and node adjacency matrix of the power grid to be detected into a single fault location model, so that the single fault location model outputs a fault component of the power grid to be detected; wherein the component includes nodes and branches.

[0054] For step S1, obtain the node three-phase current matrix, node three-phase voltage matrix, branch power matrix, branch adjacency matrix and node adjacency matrix of the power grid to be detected. It should be noted that the present invention mainly performs fault location for the case where there is only one fault in the power grid, that is, there is a single node fault or a single branch fault. Preferably, before the node three-phase current matrix and the node three-phase voltage matrix are input into the single fault location model, the two can be spliced ​​into a node three-phase current and voltage matrix. Specifically, the node three-phase current and voltage matrix F1 has a dimension of (6, 39), which is spliced ​​by the node three-phase current matrix I (I1, I2, I3) and the node three-phase voltage matrix U (U1, U2, U3). The branch power matrix F2 has a dimension of (4,46), which is composed of the branch active injection power matrix Pline_f(1,46), Pline_t(1,46), reactive injection power matrix Qline_f(1,46) and Qline_t(1,46), where f represents the forward direction and t represents the reverse direction. The node adjacency matrix A1 has a dimension of (39,39). If there is a branch between node i and node j, they are adjacent. The corresponding element a of the matrix ij =1, otherwise a ij = 0. The dimension of the branch adjacency matrix A2 is (46,46). If there is a common node between branch h and branch k, they are adjacent. The corresponding element b of the matrix hk =1, otherwise b hk =0.

[0055] For step S2, the data obtained in step S1 is input into a single fault location model to determine the node or branch with fault in the power grid to be detected through the single fault location model. Specifically, according to the node three-phase current and voltage matrix F1, the branch power matrix F2, the node adjacency matrix A1 and the branch adjacency matrix A2, the single fault location model obtains a fault location probability matrix D (1, 85), which is composed of the node fault location probability matrix D1 (1, 39) and the branch fault location probability matrix D2 (1, 46). Each element value of the matrix is ​​the probability of the corresponding node / branch currently failing, and the sum of all element values ​​is 1. The node / branch with the largest probability in the fault location probability matrix D is the component determined by the network to have failed.

[0056] By inputting the branch adjacency matrix and the node adjacency matrix when detecting the faulty components in the power grid to be detected in the single fault location model, the topological relationship between nodes and the topological relationship between branches in the power grid to be detected can be combined, and the graph feature association relationship in the complex power grid system can be effectively learned, thereby improving the accuracy of the output results of the single fault location model.

[0057] In a preferred embodiment, the construction of the single fault location model includes: obtaining historical fault data of the power grid, and determining a training sample set based on the historical fault data; wherein the training sample set includes: node three-phase current matrix samples, node three-phase voltage matrix samples, branch power matrix samples, branch adjacency matrix samples, node adjacency matrix samples and fault label matrix; constructing a graph neural network, training the graph neural network with the training sample set, and generating a single fault location model when the graph neural network reaches a preset convergence condition.

[0058] Specifically, historical fault data of the power grid is obtained, and the historical fault data of the power grid is usually the historical fault data of the power grid to be detected. The historical fault data is preprocessed to obtain a training sample set including node three-phase current matrix samples, node three-phase voltage matrix samples, branch power matrix samples, branch adjacency matrix samples, node adjacency matrix samples and fault label matrix. The node three-phase current matrix samples and the node three-phase voltage matrix samples are concatenated to obtain node three-phase current and voltage matrix samples. That is, a training sample set including node three-phase current and voltage matrix samples, branch power matrix samples, branch adjacency matrix samples, node adjacency matrix samples and fault label matrix is ​​obtained. Construct a Figure 2 The graph neural network of the GFL-Net (Graph-based Fault Location Net) network structure is shown. The graph neural network is trained with the constructed training sample set, so that when the graph neural network reaches the preset convergence condition, a single fault location model is generated.

[0059] In a preferred embodiment, the preset convergence condition includes: reaching a preset number of iterations or when the loss function is minimum; the loss function is specifically:

[0060]

[0061] in, represents the loss function of the graph neural network; N is the total number of nodes in the power grid to be detected; M is the total number of branches in the power grid to be detected; y is the one-hot encoding vector of the fault label; is the probability distribution vector of the predicted fault label of the graph neural network.

[0062] Specifically, the preset convergence condition includes reaching a preset number of iterations or when the loss function is minimized. For the loss function, the cross-entropy loss function (Cross-Entropy Loss) is used for training in the present invention. The cross-entropy loss function can measure the difference between two probability distributions, which can evaluate the degree of match between the output distribution of the model and the true label distribution. The specific loss function is shown above.

[0063] When training a graph neural network, the learning rate is set to perform multiple iterations (epochs) on the training data set, and the network parameters are adjusted in each iteration to minimize the loss function. The loss on the validation set reaches the preset threshold or no longer decreases significantly. After the training is completed, the fault location probability matrix D with only a single fault is output, and then the faulty node or faulty branch is determined based on the fault location probability matrix D.

[0064] In a preferred embodiment, the single fault location model includes: a first graph attention network layer, a second graph attention network layer, a first feature network layer, a second feature network layer, a third feature network layer, a fourth feature network layer, a first normalization layer, and a second normalization layer;

[0065] The step of inputting a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected into a single fault location model comprises:

[0066] Generate a node three-phase current and voltage matrix by splicing the node three-phase current matrix and the node three-phase voltage matrix;

[0067] Inputting the node three-phase current and voltage matrix and the node adjacency matrix into a first graph attention network layer, so that the first graph attention network layer aggregates adjacent node information to obtain a first aggregated output;

[0068] Inputting the branch power matrix and the branch adjacency matrix into a second graph attention network layer, so that the second graph attention network layer aggregates the branch information to obtain a second aggregated output;

[0069] The first aggregate output and the second aggregate output are input into a first feature network layer, so that the first feature network layer extracts first feature data and inputs the first feature data into a second feature network layer;

[0070] The second feature network layer optimizes the first feature data to generate second feature data, and inputs the second feature data into the third feature network layer via the first normalization layer;

[0071] The third feature network layer adjusts the second feature data to generate third feature data, and inputs the third feature data into the fourth feature network layer via the second normalization layer, so that the fourth feature network layer outputs a fault component of the power grid to be detected in combination with the Softmax function;

[0072] Among them, the first characteristic data includes: three-phase current characteristics of the first node, three-phase voltage characteristics of the first node, topological characteristics of the first node, power characteristics of the first branch and topological characteristics of the first branch; the second characteristic data includes: three-phase current characteristics of the second node, three-phase voltage characteristics of the second node, topological characteristics of the second node, power characteristics of the second branch and topological characteristics of the second branch; the third characteristic data includes: three-phase current characteristics of the third node, three-phase voltage characteristics of the third node, topological characteristics of the third node, power characteristics of the third branch and topological characteristics of the third branch.

[0073] Specifically, Figure 2 As shown, the single fault location model includes a first graph attention network layer GAT_1, a second graph attention network layer GAT_2, a first feature network layer MLP (the MLP connected to the feature-direction MLP in the figure), a second feature network layer feature-direction MLP, a third feature network layer channel-direction MLP, a fourth feature network layer MLP (the MLP connected to LayerNorm3() in the figure), a first normalization layer LayerNorm1() and a second normalization layer LayerNorm3().

[0074] Before inputting data into the single fault location model, the feature direction (feature-direction) of the feature input matrix is ​​first defined as 39 dimensions (or 46 dimensions) and the channel direction (channel-direction) is divided into 6 dimensions (or 4 dimensions).

[0075] The node three-phase current matrix and the node three-phase voltage matrix are spliced ​​to obtain the node three-phase current and voltage matrix F1 = {I1, I2, I3, V1, V2, V3}, F1∈R 6*N ; The node three-phase current and voltage matrix F1 and the node adjacency matrix A1∈{1,0} N*NInput to the first graph attention network layer GAT_1 to get the first aggregate output; transform the branch power matrix F2 = {Pline_f, Pline_t, Qline_f, Qline_t}, F2∈R 4*N and the branch adjacency matrix A2∈{1,0} M*M Input the second graph attention network layer GAT_2 to obtain the second aggregate output. It should be noted that GAT_1 is a graph attention network, which is used to assign different attention weights to each node and aggregate the information of neighboring nodes to obtain the implicit representation of each node. Similarly, the role of GAT_2 is to assign different attention weights to each branch and aggregate the information of neighboring branches to obtain the implicit representation of each branch. The first aggregate output and the second aggregate output are input into the first feature network layer MLP. The MLP of the first feature network layer is a fully connected neural network, which performs preliminary processing on the features of nodes and edges, extracts useful high-dimensional features, and inputs the extracted high-dimensional features (i.e., the first feature data) into the second feature network layer feature-direction MLP, so that the second feature network layer feature-direction MLP further processes the high-dimensional features to obtain the second feature data, and the second feature data is input into the third feature network layer channel-direction MLP through the first normalization layer LayerNorm1(), so that the third feature network layer channel-direction MLP processes and adjusts the input feature vector to obtain the third feature data, and the third feature data is input into the fourth feature network layer MLP after the nonlinear activation function ReLU(), regularization Dropout (0.2) and the second normalization layer LayerNorm3(), and then combined with the Softmax function to determine the fault location probability matrix D∈{0,1} 1*(N+M) , where the fault location probability matrix D is composed of the node fault location probability matrix D1∈{0,1} 1*N And the branch fault location probability matrix D2∈{0,1} 1*M The node / branch corresponding to the element with the largest probability value in the fault location probability matrix D is determined as the current faulty component.

[0076] pred=max(Di)

[0077] Where D i is the element value (probability value) in the D matrix, and pred is the predicted faulty component.

[0078] Based on the above method embodiment, the present invention provides a corresponding device embodiment.

[0079] like Figure 3As shown, an embodiment of the present invention provides a single fault location device for a power grid, comprising: a data acquisition module and a fault location module;

[0080] The data acquisition module is used to acquire a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected;

[0081] The fault location module is used to input the node three-phase current matrix, node three-phase voltage matrix, branch power matrix, branch adjacency matrix and node adjacency matrix of the power grid to be detected into a single fault location model, so that the single fault location model outputs a fault component of the power grid to be detected; wherein the component includes nodes and branches.

[0082] In a preferred embodiment, the construction of the single fault location model includes:

[0083] Acquire historical fault data of the power grid, and determine a training sample set according to the historical fault data; wherein the training sample set includes: node three-phase current matrix samples, node three-phase voltage matrix samples, branch power matrix samples, branch adjacency matrix samples, node adjacency matrix samples and fault label matrix;

[0084] A graph neural network is constructed, and the graph neural network is trained with the training sample set, and a single fault location model is generated when the graph neural network reaches a preset convergence condition.

[0085] In a preferred embodiment, the single fault location model includes: a first graph attention network layer, a second graph attention network layer, a first feature network layer, a second feature network layer, a third feature network layer, a fourth feature network layer, a first normalization layer, and a second normalization layer;

[0086] The step of inputting a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected into a single fault location model comprises:

[0087] Generate a node three-phase current and voltage matrix by splicing the node three-phase current matrix and the node three-phase voltage matrix;

[0088] Inputting the node three-phase current and voltage matrix and the node adjacency matrix into a first graph attention network layer, so that the first graph attention network layer aggregates adjacent node information to obtain a first aggregated output;

[0089] Inputting the branch power matrix and the branch adjacency matrix into a second graph attention network layer, so that the second graph attention network layer aggregates the branch information to obtain a second aggregated output;

[0090] The first aggregate output and the second aggregate output are input into a first feature network layer, so that the first feature network layer extracts first feature data and inputs the first feature data into a second feature network layer;

[0091] The second feature network layer optimizes the first feature data to generate second feature data, and inputs the second feature data into the third feature network layer via the first normalization layer;

[0092] The third feature network layer adjusts the second feature data to generate third feature data, and inputs the third feature data into the fourth feature network layer via the second normalization layer, so that the fourth feature network layer outputs a fault component of the power grid to be detected in combination with the Softmax function;

[0093] Among them, the first characteristic data includes: three-phase current characteristics of the first node, three-phase voltage characteristics of the first node, topological characteristics of the first node, power characteristics of the first branch and topological characteristics of the first branch; the second characteristic data includes: three-phase current characteristics of the second node, three-phase voltage characteristics of the second node, topological characteristics of the second node, power characteristics of the second branch and topological characteristics of the second branch; the third characteristic data includes: three-phase current characteristics of the third node, three-phase voltage characteristics of the third node, topological characteristics of the third node, power characteristics of the third branch and topological characteristics of the third branch.

[0094] In a preferred embodiment, the preset convergence condition includes: when a preset number of iterations is reached or the loss function is minimized;

[0095] The loss function is specifically:

[0096]

[0097] in, represents the loss function of the graph neural network; N is the total number of nodes in the power grid to be detected; M is the total number of branches in the power grid to be detected; y is the one-hot encoding vector of the fault label; is the probability distribution vector of the predicted fault label of the graph neural network.

[0098] It should be noted that the device embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. In addition, in the accompanying drawings of the device embodiments provided by the present invention, the connection relationship between the modules indicates that there is a communication connection between them, which may be specifically implemented as one or more communication buses or signal lines. A person of ordinary skill in the art may understand and implement it without paying any creative effort.

[0099] Those skilled in the art can clearly understand that for the sake of convenience and brevity, the specific working process of the device described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.

[0100] Based on the above method item embodiments, the present invention provides corresponding terminal device item embodiments.

[0101] An embodiment of the present invention provides a terminal device, including a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, a single fault location method for a power grid as described in any one of the present invention is implemented.

[0102] The terminal device may be a computing device such as a desktop computer, a notebook, a PDA, a cloud server, etc. The terminal device may include, but is not limited to, a processor and a memory.

[0103] The processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc. The processor is the control center of the terminal device, and uses various interfaces and lines to connect various parts of the entire terminal device.

[0104] The memory can be used to store the computer program, and the processor realizes various functions of the terminal device by running or executing the computer program stored in the memory and calling the data stored in the memory. The memory can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, at least one application required for a function, etc.; the data storage area can store data created according to the use of the mobile phone, etc. In addition, the memory can include a high-speed random access memory, and can also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0105] Based on the above method item embodiments, the present invention provides a corresponding storage medium item embodiment.

[0106] An embodiment of the present invention provides a storage medium, which includes a stored computer program, wherein when the computer program is running, the device where the storage medium is located is controlled to execute a power grid single fault locating method as described in any one of the present inventions.

[0107] The storage medium is a computer-readable storage medium, and the computer program is stored in the computer-readable storage medium. When the computer program is executed by the processor, the steps of each of the above-mentioned method embodiments can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium.

[0108] The above is a preferred embodiment of the present invention. It should be pointed out that a person skilled in the art can make several improvements and modifications without departing from the principle of the present invention. These improvements and modifications are also considered to be within the scope of protection of the present invention.

Claims

1. A method for locating a single fault in a power grid, characterized in that: include: Obtaining a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of a power grid to be detected; wherein the power grid to be detected has only one fault; The node three-phase current matrix, node three-phase voltage matrix, branch power matrix, branch adjacency matrix and node adjacency matrix of the power grid to be detected are input into a single fault location model so that the single fault location model outputs a fault component of the power grid to be detected; wherein the component includes nodes and branches.

2. A method for locating a single fault in a power grid according to claim 1, characterized in that: The construction of the single fault location model includes: Acquire historical fault data of the power grid, and determine a training sample set according to the historical fault data; wherein the training sample set includes: node three-phase current matrix samples, node three-phase voltage matrix samples, branch power matrix samples, branch adjacency matrix samples, node adjacency matrix samples and fault label matrix; A graph neural network is constructed, and the graph neural network is trained with the training sample set, and a single fault location model is generated when the graph neural network reaches a preset convergence condition.

3. A method for locating a single fault in a power grid as claimed in claim 2, characterized in that: The single fault location model includes: a first graph attention network layer, a second graph attention network layer, a first feature network layer, a second feature network layer, a third feature network layer, a fourth feature network layer, a first normalization layer and a second normalization layer; The step of inputting a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected into a single fault location model comprises: Generate a node three-phase current and voltage matrix by splicing the node three-phase current matrix and the node three-phase voltage matrix; Inputting the node three-phase current and voltage matrix and the node adjacency matrix into a first graph attention network layer, so that the first graph attention network layer aggregates adjacent node information to obtain a first aggregated output; Inputting the branch power matrix and the branch adjacency matrix into a second graph attention network layer, so that the second graph attention network layer aggregates the branch information to obtain a second aggregated output; The first aggregate output and the second aggregate output are input into a first feature network layer, so that the first feature network layer extracts first feature data and inputs the first feature data into a second feature network layer; The second feature network layer optimizes the first feature data to generate second feature data, and inputs the second feature data into the third feature network layer via the first normalization layer; The third feature network layer adjusts the second feature data to generate third feature data, and inputs the third feature data into the fourth feature network layer via the second normalization layer, so that the fourth feature network layer outputs a fault component of the power grid to be detected in combination with the Softmax function; Among them, the first characteristic data includes: three-phase current characteristics of the first node, three-phase voltage characteristics of the first node, topological characteristics of the first node, power characteristics of the first branch and topological characteristics of the first branch; the second characteristic data includes: three-phase current characteristics of the second node, three-phase voltage characteristics of the second node, topological characteristics of the second node, power characteristics of the second branch and topological characteristics of the second branch; the third characteristic data includes: three-phase current characteristics of the third node, three-phase voltage characteristics of the third node, topological characteristics of the third node, power characteristics of the third branch and topological characteristics of the third branch.

4. A method for locating a single fault in a power grid as claimed in claim 3, characterized in that: The preset convergence conditions include: reaching a preset number of iterations or when the loss function is minimum; The loss function is specifically: in, represents the loss function of the graph neural network; N is the total number of nodes in the power grid to be detected; M is the total number of branches in the power grid to be detected; y is the one-hot encoding vector of the fault label; is the probability distribution vector of the predicted fault label of the graph neural network.

5. A single fault location device for a power grid, characterized in that: include: Data acquisition module and fault location module; The data acquisition module is used to acquire a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected; The fault location module is used to input the node three-phase current matrix, node three-phase voltage matrix, branch power matrix, branch adjacency matrix and node adjacency matrix of the power grid to be detected into a single fault location model, so that the single fault location model outputs a fault component of the power grid to be detected; wherein the component includes nodes and branches.

6. A power grid single fault location device as claimed in claim 5, characterized in that: The construction of the single fault location model includes: Acquire historical fault data of the power grid, and determine a training sample set according to the historical fault data; wherein the training sample set includes: node three-phase current matrix samples, node three-phase voltage matrix samples, branch power matrix samples, branch adjacency matrix samples, node adjacency matrix samples and fault label matrix; A graph neural network is constructed, and the graph neural network is trained with the training sample set, and a single fault location model is generated when the graph neural network reaches a preset convergence condition.

7. A power grid single fault location device as claimed in claim 6, characterized in that: The single fault location model includes: a first graph attention network layer, a second graph attention network layer, a first feature network layer, a second feature network layer, a third feature network layer, a fourth feature network layer, a first normalization layer and a second normalization layer; The step of inputting a node three-phase current matrix, a node three-phase voltage matrix, a branch power matrix, a branch adjacency matrix and a node adjacency matrix of the power grid to be detected into a single fault location model comprises: Generate a node three-phase current and voltage matrix by splicing the node three-phase current matrix and the node three-phase voltage matrix; Inputting the node three-phase current and voltage matrix and the node adjacency matrix into a first graph attention network layer, so that the first graph attention network layer aggregates adjacent node information to obtain a first aggregated output; Inputting the branch power matrix and the branch adjacency matrix into a second graph attention network layer, so that the second graph attention network layer aggregates the branch information to obtain a second aggregated output; The first aggregate output and the second aggregate output are input into a first feature network layer, so that the first feature network layer extracts first feature data and inputs the first feature data into a second feature network layer; The second feature network layer optimizes the first feature data to generate second feature data, and inputs the second feature data into the third feature network layer via the first normalization layer; The third feature network layer adjusts the second feature data to generate third feature data, and inputs the third feature data into the fourth feature network layer via the second normalization layer, so that the fourth feature network layer outputs a fault component of the power grid to be detected in combination with the Softmax function; Among them, the first characteristic data includes: three-phase current characteristics of the first node, three-phase voltage characteristics of the first node, topological characteristics of the first node, power characteristics of the first branch and topological characteristics of the first branch; the second characteristic data includes: three-phase current characteristics of the second node, three-phase voltage characteristics of the second node, topological characteristics of the second node, power characteristics of the second branch and topological characteristics of the second branch; the third characteristic data includes: three-phase current characteristics of the third node, three-phase voltage characteristics of the third node, topological characteristics of the third node, power characteristics of the third branch and topological characteristics of the third branch.

8. A power grid single fault location device as claimed in claim 7, characterized in that: The preset convergence conditions include: reaching a preset number of iterations or when the loss function is minimum; The loss function is specifically: in, represents the loss function of the graph neural network; N is the total number of nodes in the power grid to be detected; M is the total number of branches in the power grid to be detected; y is the one-hot encoding vector of the fault label; is the probability distribution vector of the predicted fault label of the graph neural network.

9. A terminal device, characterized in that: The invention comprises a processor, a memory and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, a method for locating a single fault in a power grid as claimed in any one of claims 1 to 4 is implemented.

10. A storage medium, characterized in that: The storage medium includes a stored computer program, wherein when the computer program is executed, the device where the storage medium is located is controlled to execute a power grid single fault location method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Grid fault detection method and device based on graph neural network

    CN115733730A

  • Power distribution network fault positioning model construction method and device and fault positioning method

    CN118294754A