A method and system for identifying grounding faults in distribution networks based on artificial immune networks
By using an artificial immune network-based method combined with K-nearest neighbor algorithm and particle swarm optimization, the problem of low diagnostic accuracy in distribution network grounding fault detection is solved, and higher detection accuracy and more comprehensive type identification are achieved.
Patent Information
- Application Number
- CN201911048564.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-10-30
- Publication Date
- 2025-09-05
- Estimated Expiration
- 2039-10-30
AI Technical Summary
The existing distribution network grounding fault detection method has a small fault current in the neutral point ungrounded system, resulting in low diagnostic accuracy. In addition, the existing method does not fully consider the impact of various grounding faults and disturbances.
A method based on artificial immune network is adopted. By obtaining the grounding data of the distribution network, feature extraction and feature vector analysis are performed, and the K-nearest neighbor algorithm is used to identify the fault or disturbance type. The particle swarm algorithm is added in the training process to optimize the parameters of the artificial immune network model and improve the detection accuracy.
The accuracy of grounding fault detection in distribution networks and the comprehensiveness of type identification are improved, the problem of low fault diagnosis accuracy is solved, the training process is accelerated, and the distribution accuracy of memory cells in the feature space is improved.
Smart Images

Figure CN112748358B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a distribution network fault identification technology, and in particular to a distribution network grounding fault identification method and system based on an artificial immune network. Background Art
[0002] With the development of smart grids, people's demands on power grids are becoming increasingly stringent. Faults in distribution network lines directly impact power supply reliability. However, since most distribution networks have ungrounded neutral points, the fault current during ground faults is small, making reliable diagnostic accuracy low. Therefore, when a line fault occurs, quickly and accurately detecting the fault and subsequently determining its type is a crucial task.
[0003] Currently, existing methods for transmission line fault detection primarily rely on feature thresholding and artificial intelligence classifiers. While the principle of the threshold method is relatively simple, setting the threshold is a significant challenge. In recent years, artificial intelligence classification has been widely adopted in transmission line fault classification systems. However, existing methods fail to fully consider the potential impact of various ground faults and disturbances on fault detection. Overcoming these shortcomings is a pressing issue in distribution network ground fault identification. Summary of the Invention
[0004] The technical solution provided by the present invention is:
[0005] A distribution network grounding fault identification method based on an artificial immune network, comprising:
[0006] Obtain distribution network grounding data;
[0007] Extract the features of the distribution network grounding data to obtain the feature vector;
[0008] Based on a pre-built artificial immune network model, the characteristic vector of the distribution network grounding data is used to identify the distribution network grounding fault or disturbance type through a K-nearest neighbor algorithm;
[0009] The distribution network grounding data includes: line three-phase current monitoring sampling values before and after the fault, and zero-sequence voltage sampling values before and after the fault.
[0010] Preferably, the pre-built artificial immune network model includes:
[0011] Step 2.1: Divide the historical grounding data of the distribution network corresponding to the fault or disturbance information into a sample set and a test set;
[0012] Step 2.2: Extract feature vectors based on the sample set, and form different antigen sets based on the fault or disturbance type.
[0013] Step 2.3: training and learning each antigen set separately to obtain a feature vector reflecting the feature space of each antigen, and setting the feature vector as a memory cell;
[0014] Step 2.4: Gather all memory cells into one set as an artificial immune network model;
[0015] Step 2.5: Testing the artificial immune network model based on the test set to obtain the fault identification accuracy of the artificial immune network model on the test set;
[0016] Step 2.6: If the accuracy is less than the judgment threshold, use the particle swarm algorithm to optimize the artificial immune network training parameters with the goal of maximizing the test set fault identification accuracy and return to step 2.2; if the accuracy is greater than or equal to the judgment threshold, the artificial immune network model is constructed;
[0017] The fault types include: single-phase high-resistance grounding fault, single-phase low-resistance grounding fault, two-phase short-circuit grounding fault, two-phase interphase fault, three-phase short-circuit grounding fault, large motor starting, load asymmetry, and non-synchronous closing.
[0018] Preferably, the training and learning of the antigen set to obtain memory cells of the antigen feature space includes:
[0019] Step 3.1: Randomly generate antibodies and calculate the affinity between the same type of antigen and memory cells;
[0020] Step 3.2: Input an antigen in the antigen set, select the antibody with the highest clone affinity, and clone it to generate a clone set, where the antigen is a data in the antigen set;
[0021] Step 3.3: Affinity maturation is performed on each antibody in the clone set to generate a mutation set;
[0022] Step 3.4: Determine the affinity between all antigens and the mutation set; reselect antibodies with the highest affinity as a partial antibody group; and simultaneously eliminate memory antibodies with affinity less than the natural death threshold in the partial antibody group;
[0023] Step 3.5: Calculating the affinity of each antibody in the cleared partial antibodies to other antibodies, and using the cleared antibodies whose affinity to themselves and all other antibodies in the partial antibodies is higher than the inhibition threshold as memory cells;
[0024] Step 3.6: Select the next antigen and return to step 3.2 until all antigens are presented to the network;
[0025] Step 3.7: Calculate the affinity of each memory cell with every other memory cell. Eliminate any memory cell whose affinity with all other memory cells is above the inhibition threshold. Calculate the average Euclidean distance between the eliminated memory cells and the antigen to obtain the average affinity. If the specified number of iterations is reached or the difference in average affinity after two iterations is below the specified threshold, terminate the training process and obtain the memory cell set. Otherwise, proceed to step 3.8.
[0026] Step 3.8: Adaptively adjust the network itself according to the adaptive variance of the generated memory cells during training;
[0027] Step 3.9: Randomly generate d r antibodies and add them to the antibody;
[0028] Step 3.10: Calculate the affinity between the same type of antigen and memory cells and return to step 3.2.
[0029] Preferably, the method of automatically performing adaptive adjustment on the network itself according to the adaptive variance of generated memory cells is added during network training, including:
[0030] Calculate the variance of the existing memory cell set;
[0031] Calculate the difference between two iterations of the memory cell set by using the memory cell set variance;
[0032] Adaptive adjustment is accomplished by updating each memory cell based on the difference between two iterations before and after the memory cell.
[0033] Preferably, the variance of the existing memory cell set is calculated as follows:
[0034]
[0035] Where, σ is the variance of memory cell set; d mci is the average distance between the i-th memory cell and all antigens in the population; d avg is the average fitness of all memory cells in a given class of samples; n mc is the number of memory cells; d is the absolute value of the maximum difference between the average distance of j memory cells from all antigens and the average fitness of all memory cells;
[0036] Where d is calculated as follows:
[0037] d=max(|d mci -d avg |), i = 1, 2, ..., n mc ;
[0038] Preferably, the difference between the two iterations of the memory cell is calculated as follows:
[0039] Δσ=σ(i+1)-σ(i)
[0040] Where Δσ is the difference between the variances of the memory cells before and after the two iterations; σ(i+1) is the variance of the memory cells obtained at the i+1th iteration; and σ(i) is the variance of the memory cells obtained at the jth iteration.
[0041] Preferably, each memory cell is updated by the following formula:
[0042] mc ij =mc ij +rand()*|Δσ|,i=1,2,…,n mc , j = 1, 2, ..., n
[0043] where n mc is the number of memory cells; n is the number of features in each storage unit; mc ij For memory cells.
[0044] Preferably, the method of optimizing the training parameters of the artificial immune network using a particle swarm algorithm with the goal of maximizing the test set fault identification accuracy includes:
[0045] Initialize the relevant parameters of the particle swarm algorithm;
[0046] Based on the relevant parameters of the particle swarm algorithm, the artificial immune network training parameters are iteratively optimized through the particle update formula to maximize the accuracy of fault identification of the test set;
[0047] The parameters related to the initialization of the particle swarm algorithm include:
[0048] The number of random initializations is N in The position of the particles and initialize the velocity v of each particle respectively;
[0049] The position x of the particle is composed of the natural death threshold and the inhibition threshold of the artificial immune network training parameters.
[0050] Preferably, the characteristic vector of the distribution network grounding data identifies the distribution network grounding fault or disturbance type by using a K-nearest neighbor algorithm, including:
[0051] In the artificial immune network model, the K1 memory cells in the immune network with the closest Euclidean distance to the characteristic vector of the distribution network grounding data sample are calculated;
[0052] Check the fault or disturbance types corresponding to these K1 memory cells. The fault or disturbance type with the most corresponding memory cells is the fault identification result of the distribution network grounding data.
[0053] A distribution network grounding fault identification system based on artificial immune network includes: an acquisition module, an extraction module and an identification module;
[0054] The acquisition module is used to acquire grounding data of the distribution network;
[0055] The extraction module is used to extract features from the grounding data of the distribution network to obtain feature vectors;
[0056] The identification module: based on a pre-built artificial immune network model, identifies the distribution network grounding fault or disturbance type by using a K-nearest neighbor algorithm on the characteristic vector of the distribution network grounding data;
[0057] The distribution network grounding data includes: line three-phase current monitoring sampling values before and after the fault, and zero-sequence voltage sampling values before and after the fault.
[0058] Preferably, the identification module includes: a construction submodule and a calculation submodule;
[0059] The construction submodule is used to: construct an artificial immune network model by training and learning the historical grounding data of the distribution network corresponding to the fault or disturbance information;
[0060] The calculation submodule is used for:
[0061] In the artificial immune network model, the K1 memory cells in the immune network with the closest Euclidean distance to the characteristic vector of the distribution network grounding data sample are calculated;
[0062] Check the fault or disturbance types corresponding to these K1 memory cells. The fault or disturbance type with the most corresponding memory cells is the fault identification result of the distribution network grounding data.
[0063] Compared with the prior art, the present invention has the following beneficial effects:
[0064] 1. The technical solution provided by the present invention is a distribution network grounding fault identification method based on an artificial immune network model, comprising: obtaining distribution network grounding data; extracting features from the distribution network grounding data to obtain a feature vector; based on a pre-constructed artificial immune network model, identifying the distribution network grounding fault or disturbance type through the feature vector of the distribution network grounding data through a K-nearest neighbor algorithm; the distribution network grounding data includes: line three-phase current monitoring sampling values before and after the fault, and zero-sequence voltage sampling values before and after the fault, which improves the accuracy rate and makes the identification types more comprehensive, effectively solving the problem of low fault diagnosis accuracy when a grounding fault occurs.
[0065] 2. The present invention adopts an adaptive process in the process of memory cell formation to improve the classification performance of each storage unit, accelerate the training process, and improve the distribution accuracy of memory cells in the feature space. BRIEF DESCRIPTION OF THE DRAWINGS
[0066] Figure 1 This is a flow chart of a method for identifying ground faults in a distribution network based on an artificial immune network model according to the present invention;
[0067] Figure 2 Schematic diagram of an embodiment of the present invention;
[0068] Figure 3 This is a flow chart of the artificial immune model training of the present invention. DETAILED DESCRIPTION
[0069] In order to better understand the present invention, the present invention is further described below with reference to the accompanying drawings and examples.
[0070] This paper proposes a method for identifying ground faults in distribution networks based on an artificial immune network. This method utilizes a large number of electrical characteristic value samples before and after the fault as antigens. Through learning and training, a set of memory cells that characterize the characteristics of the fault is generated. These memory cells form an artificial immune network model for identification. This method has excellent memory and noise suppression capabilities, enabling accurate "self-identification."
[0071] Example 1:
[0072] The technical solution adopted by the present invention is a method for identifying ground faults in distribution network based on artificial immune network model. Figure 1 Shown, including:
[0073] S1 obtains distribution network grounding data;
[0074] S2 extracts the features of the distribution network grounding data to obtain a feature vector;
[0075] S3 identifies the distribution network grounding fault or disturbance type by using a K-nearest neighbor algorithm on the characteristic vector of the distribution network grounding data based on a pre-built artificial immune network model;
[0076] The distribution network grounding data includes: line three-phase current monitoring sampling values before and after the fault, and zero-sequence voltage sampling values before and after the fault.
[0077] Specific implementation steps include Figure 2 As shown:
[0078] S1 obtains distribution network grounding data;
[0079] Step 1: Collect the sample set and test set, including all the information used as the identification feature vector in step 2;
[0080] S2 extracts the features of the distribution network grounding data to obtain a feature vector;
[0081] Step 2: Extract feature vectors from the sample set and divide it into j antigen sets Ag according to the fault or disturbance type i ={x, y}, where x is the characteristic physical quantity value used for judgment and y is the state of the circuit;
[0082] S3 identifies the distribution network grounding fault or disturbance type by using a K-nearest neighbor algorithm on the characteristic vector of the distribution network grounding data based on a pre-built artificial immune network model;
[0083] Step 3: Train and learn each antigen set separately, and form an m for each type of antigen i memory cells that respond to the characteristic space of this type of antigen All types of memory cells are gathered into one set, and finally a memory cell set including all sample types is formed, which is the artificial immune network model used for recognition;
[0084] Step 4: Extract feature vectors from the test set and determine its type using the K-nearest neighbor algorithm. With the goal of maximizing accuracy, use the particle swarm optimization algorithm to optimize the training parameters of the artificial immune network for actual detection.
[0085] Step 5: During detection, the K-nearest neighbor algorithm is used to determine whether the detected sample is faulty and the type of fault.
[0086] In the aforementioned distribution network ground fault identification method based on an artificial immune network, the characteristic variable information described in step 1 includes the line's three-phase current monitoring sample values before and after the fault, and the zero-sequence voltage sample values before and after the fault. The collected samples include both different ground fault conditions occurring on the line and line disturbances that may cause fluctuations in the measured data.
[0087] In the above-mentioned distribution network grounding fault identification method based on artificial immune network, each antigen sample described in step 2 includes characteristic physical quantities and final category labels. Subsequent training and calculation only screen and change the characteristic physical quantities, and the final category labels always remain consistent.
[0088] In the above-mentioned distribution network ground fault identification method based on artificial immune network, the training parameters in step 3 include the initial antibody number Z, the antibody clone number Nc, the clone coefficient Kscale, the mutation coefficient α, the affinity percentage ξ, the natural death threshold δ d , suppression threshold δ s , the maximum number of iterations N e , average affinity threshold sc, newly added antibodies d. Figure 3 The process of training memory cells for each antigen set shown includes the following steps:
[0089] Step 3.1: Randomly generate Z antibodies Ab.
[0090] Step 3.2: Calculate the affinity between the same type of antigen and memory cells (this step is not performed in the first iteration).
[0091] Step 3.3: Input an antigen from the antigen set j , select clone N mo The antibodies with the highest affinity were cloned to generate clone set C. i .
[0092]
[0093] Among them, round() is an integer; Kscale is the cloning coefficient, which controls the number of clones; f ij is the affinity between the antibody and the antigen, which is the reciprocal of the Euclidean distance between the antigen and the antibody.
[0094] Step 3.4: C j Each antibody will undergo an affinity maturation process to generate a set of mutations It is important to note that the mutation does not occur in the fault type information of the antibody, but in the feature value of the antibody.
[0095]
[0096] where c m It is the cloned antibody set C j Antibodies in Antibodies based on a set of mutations generated from a clone set The concentrated antibodies; α is the coefficient controlling mutation.
[0097] Step 3.5: Identify all antigens with Affinity between. From the reselection ξ% of antibodies with the highest affinity as a group of partial antibodies M j . At the same time, clear M j All the d Antibodies to the natural death threshold.
[0098] Step 3.6: Among the antibodies left in the previous step, remove those with affinity to other antibodies above the inhibition threshold δ s antibodies and produces a group of memory cells.
[0099] Step 3.7: Select the next antigen of this type and return to step 3.1. This process continues until all antigens have been presented to the network.
[0100] Step 3.8: Eliminate those memory cells of the same fault type whose affinity with other memory cells is better than δ sMemory cells are generated, and the average Euclidean distance between the generated memory cells and the antigen is calculated to obtain the average affinity. If the specified number of iterations is reached or the difference in average affinity between two iterations falls below the specified threshold sc, the training process ends and the memory cell set is obtained. If the stopping criterion is not met, proceed to step 3.9. If it is the first iteration, proceed directly to step 3.10.
[0101] Step 3.9: In the network training, automatically adjust the network itself according to the adaptive variance of the generated memory cells.
[0102] Step 3.10: Randomly generate d r Each antibody is added to the antibody set, so the antibody set increases, and then go to step 3.2 to repeat the entire process.
[0103] In the above-mentioned distribution network ground fault identification method based on artificial immune network, the self-adaptive process steps of step 3.9 are as follows:
[0104] (1) Calculate the variance of the existing memory cell set:
[0105]
[0106] d=max(|d mci -d avx |), i = 1, 2, ..., n mc
[0107] where d mci is the average distance between the i-th memory cell and all antigens in the population, d avg is the average fitness of all memory cells in a given class of samples, n mc is the total number of storage cells,
[0108] (2) Calculate Δσ between the two iterations:
[0109] Δσ=σ(i+1)-σ(i)
[0110] (3) Update each memory cell according to the following equation:
[0111] mc ij =mc ij +rand()*|Δσ|,i=1,2,…,n mc , j = 1, 2, ..., n
[0112] where n mc represents the number of memory cells, and n represents the number of features in each storage unit.
[0113] In the above-mentioned distribution network ground fault identification method based on artificial immune network, the optimization process parameters in step 4 include: neighbor number K, evolution generation k, evolution coefficients c1 and c2, random variables r1 and r2, weighting coefficient ω, and the network parameter optimization process includes the following steps:
[0114] Step 4.1: Calculate the K memory cells in the immune network that are closest to the Euclidean distance of the feature vector of the sample to be detected;
[0115] Step 4.2: Check the category labels of these K memory cells and vote. The type with the most votes is the judgment result.
[0116] Step 4.3: The accuracy of each type of fault is considered as the optimization target. The position x of each particle in the particle swarm consists of two components, representing the natural death threshold δ d , suppression threshold δ s The value of . , the number of random initializations is N in The position of the particle and set it to have a certain initial velocity.
[0117] Step 4.4: Determine the particle's current fitness value based on its position vector, and determine the particle's current individual optimal value p and the current group optimal value g by comparing the fitness values of each generation. Update the particle's velocity v and position x:
[0118]
[0119]
[0120] Where k is the number of generations of evolution, c1 and c2 are the evolution coefficients, random variables r1 and r2 are random numbers between (0, 1), i = 1, 2, ..., N, and ω is the weighting coefficient. The particles continuously iterate, feeding new parameters into the artificial immune network for training and testing, eventually gradually reaching the global optimal solution. The optimization process ends when the accuracy reaches 90%.
[0121] In the above-mentioned distribution network grounding fault identification method based on artificial immune network, the fault type judgment process described in step 5 includes the following steps:
[0122] Step 5.1: Input the data to be detected and perform feature extraction to obtain the feature vector.
[0123] Step 5.2: In the optimized artificial immune network memory cell set, calculate the K1 memory cells in the immune network that are closest to the Euclidean distance of the feature vector of the sample to be detected.
[0124] Step 5.3: Check the category labels of these K1 memory cells and vote. The category with the most votes is the judgment result, and the fault identification result of the sample to be tested is obtained.
[0125] Example 2:
[0126] Based on the same inventive concept, the present invention also provides a distribution network grounding fault identification system based on an artificial immune network model, comprising: an acquisition module, an extraction module and an identification module;
[0127] The acquisition module is used to acquire grounding data of the distribution network;
[0128] The extraction module is used to extract features from the grounding data of the distribution network to obtain feature vectors;
[0129] The identification module: based on a pre-built artificial immune network model, identifies the distribution network grounding fault or disturbance type by using a K-nearest neighbor algorithm on the characteristic vector of the distribution network grounding data;
[0130] The distribution network grounding data includes: line three-phase current monitoring sampling values before and after the fault, and zero-sequence voltage sampling values before and after the fault.
[0131] The identification module includes: a construction submodule and a calculation submodule;
[0132] The construction submodule is used to: construct an artificial immune network model by training and learning the historical grounding data of the distribution network corresponding to the fault or disturbance information;
[0133] The calculation submodule is used for:
[0134] In the artificial immune network model, the K1 memory cells in the immune network with the closest Euclidean distance to the characteristic vector of the distribution network grounding data sample are calculated;
[0135] Check the fault or disturbance types corresponding to these K1 memory cells. The fault or disturbance type with the most corresponding memory cells is the fault identification result of the distribution network grounding data.
[0136] The construction submodule is specifically used for
[0137] Step 2.1: Divide the historical grounding data of the distribution network corresponding to the fault or disturbance information into a sample set and a test set;
[0138] Step 2.2: Extract feature vectors based on the sample set, and form different antigen sets based on the fault or disturbance type.
[0139] Step 2.3: training and learning each antigen set separately to obtain a feature vector reflecting the feature space of each antigen, and setting the feature vector as a memory cell;
[0140] Step 2.4: Gather all memory cells into one set as an artificial immune network model;
[0141] Step 2.5: Testing the artificial immune network model based on the test set to obtain the fault identification accuracy of the artificial immune network model on the test set;
[0142] Step 2.6: If the accuracy is less than the judgment threshold, use the particle swarm algorithm to optimize the artificial immune network training parameters with the goal of maximizing the test set fault identification accuracy and return to step 2.2; if the accuracy is greater than or equal to the judgment threshold, the artificial immune network model is constructed;
[0143] The fault types include: single-phase high-resistance grounding fault, single-phase low-resistance grounding fault, two-phase short-circuit grounding fault, two-phase interphase fault, three-phase short-circuit grounding fault, large motor starting, load asymmetry, and non-synchronous closing.
[0144] Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0145] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.
[0146] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0147] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0148] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 The steps for the function specified in one or more boxes.
[0149] The above are merely embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention are included in the scope of the claims of the present invention to be approved.
Claims
1. A method for identifying ground faults in distribution networks based on artificial immune networks, characterized in that: include: Obtain distribution network grounding data; Extract the features of the distribution network grounding data to obtain the feature vector; Based on a pre-built artificial immune network model, the characteristic vector of the distribution network grounding data is used to identify the distribution network grounding fault or disturbance type through a K-nearest neighbor algorithm; The distribution network grounding data includes: line three-phase current monitoring sampling values before and after the fault, and zero-sequence voltage sampling values before and after the fault; The pre-built artificial immune network model includes: Step 2.1: Divide the historical grounding data of the distribution network corresponding to the fault or disturbance information into a sample set and a test set; Step 2.2: Extract feature vectors based on the sample set, and form different antigen sets based on the fault or disturbance type. Step 2.3: training and learning each antigen set separately to obtain a feature vector reflecting the feature space of each antigen, and setting the feature vector as a memory cell; Step 2.4: Gather all memory cells into one set as an artificial immune network model; Step 2.5: Testing the artificial immune network model based on the test set to obtain the fault identification accuracy of the artificial immune network model on the test set; Step 2.6: If the accuracy is less than the judgment threshold, use the particle swarm algorithm to optimize the artificial immune network training parameters with the goal of maximizing the test set fault identification accuracy and return to step 2.2; if the accuracy is greater than or equal to the judgment threshold, the artificial immune network model is constructed; Fault types include: single-phase high-resistance ground fault, single-phase low-resistance ground fault, two-phase short-circuit ground fault, two-phase interphase fault, three-phase short-circuit ground fault, large motor starting, asymmetric load, and non-synchronous closing; The training and learning of the antigen set to obtain memory cells of the antigen feature space includes: Step 3.1: Randomly generate antibodies and calculate the affinity between the same type of antigen and memory cells; Step 3.2: Input an antigen in the antigen set, select the antibody with the highest clone affinity, and clone it to generate a clone set, where the antigen is a data in the antigen set; Step 3.3: Affinity maturation is performed on each antibody in the clone set to generate a mutation set; Step 3.4: Determine the affinity between all antigens and the mutation set; reselect antibodies with the highest affinity as a partial antibody group; and simultaneously eliminate memory antibodies with affinity less than the natural death threshold in the partial antibody group; Step 3.5: Calculate the affinity of each antibody with other antibodies in the cleared portion of antibodies, and use the cleared antibodies whose affinity with all other antibodies in the cleared portion is higher than the inhibition threshold as memory cells; Step 3.6: Select the next antigen and return to step 3.2 until all antigens are presented to the network; Step 3.7: Calculate the affinity of each memory cell with every other memory cell. Eliminate any memory cell whose affinity with all other memory cells is above the inhibition threshold. Calculate the average Euclidean distance between the eliminated memory cells and the antigen to obtain the average affinity. If the specified number of iterations is reached or the difference in average affinity after two iterations is below the specified threshold, terminate the training process and obtain the memory cell set. Otherwise, proceed to step 3.
8. Step 3.8: Adaptively adjust the network itself according to the adaptive variance of the generated memory cells during training; Step 3.9: Randomly generate d r antibodies and add them to the antibody; Step 3.10: Calculate the affinity between the same type of antigen and memory cells, and return to step 3.2; The method of automatically performing adaptive adjustment on the network itself according to the adaptive variance of generated memory cells in the network training includes: Calculate the variance of the existing memory cell set; Calculate the difference between two iterations of the memory cell set by using the memory cell set variance; Adaptive adjustment is accomplished by updating each memory cell based on the difference between two iterations before and after the memory cell.
2. The method for identifying ground faults in a distribution network based on an artificial immune network according to claim 1, wherein: The variance of the existing memory cell set is calculated as follows: Where, σ is the variance of memory cell set; d mci is the average distance between the i-th memory cell and all antigens in the population; d avg is the average fitness of all memory cells in a given class of samples; n mc is the number of memory cells; d is the absolute value of the maximum difference between the average distance of the i memory cell from all antigens and the average fitness of all memory cells; Where d is calculated as follows: d=max(|d mci -d avg |),i=1,2,…,n mc 。 3. The method for identifying ground faults in a distribution network based on an artificial immune network according to claim 1, wherein: The difference between the two iterations of the memory cell is calculated as follows: Δσ=σ(i+1)-σ(i) Where Δσ is the difference between the variances of the memory cells before and after the iteration; σ(i+1) is the variance of the memory cells obtained at the i+1th iteration; and σ(i) is the variance of the memory cells obtained at the i-th iteration.
4. The method for identifying ground faults in a distribution network based on an artificial immune network according to claim 3, wherein: Update each memory cell by: mc ij =mc ij +rand()*|Δσ|,i=1,2,…,n mc ,j=1,2,…,n where n mc is the number of memory cells; n is the number of features in each storage unit; mc ij For memory cells.
5. The method for identifying ground faults in a distribution network based on an artificial immune network according to claim 1, wherein: The method of optimizing the training parameters of the artificial immune network using the particle swarm algorithm with the goal of maximizing the accuracy of fault identification in the test set includes: Initialize the relevant parameters of the particle swarm algorithm; Based on the relevant parameters of the particle swarm algorithm, the artificial immune network training parameters are iteratively optimized through the particle update formula to maximize the accuracy of fault identification of the test set; The parameters related to the initialization of the particle swarm algorithm include: The number of random initializations is N in The position of the particles and initialize the velocity v of each particle respectively; The position x of the particle is composed of the natural death threshold and the inhibition threshold of the artificial immune network training parameters.
6. The method for identifying ground faults in a distribution network based on an artificial immune network according to claim 1, wherein: The characteristic vector of the distribution network grounding data identifies the distribution network grounding fault or disturbance type by using a K-nearest neighbor algorithm, including: In the artificial immune network model, the K1 memory cells in the immune network with the closest Euclidean distance to the characteristic vector of the distribution network grounding data sample are calculated; Check the fault or disturbance types corresponding to these K1 memory cells. The fault or disturbance type with the most corresponding memory cells is the fault identification result of the distribution network grounding data.
7. A distribution network ground fault identification system based on artificial immune network, characterized in that: include: Acquisition module, extraction module and recognition module; The acquisition module is used to acquire grounding data of the distribution network; The extraction module is used to extract features from the grounding data of the distribution network to obtain feature vectors; The identification module: based on a pre-built artificial immune network model, identifies the distribution network grounding fault or disturbance type by using a K-nearest neighbor algorithm on the characteristic vector of the distribution network grounding data; The distribution network grounding data includes: line three-phase current monitoring sampling values before and after the fault, and zero-sequence voltage sampling values before and after the fault; The identification module includes: a construction submodule and a calculation submodule; The construction submodule is used to: construct an artificial immune network model by training and learning the historical grounding data of the distribution network corresponding to the fault or disturbance information; The calculation submodule is used for: In the artificial immune network model, the K1 memory cells in the immune network with the closest Euclidean distance to the characteristic vector of the distribution network grounding data sample are calculated; Check the fault or disturbance types corresponding to these K1 memory cells. The fault or disturbance type with the most memory cells is the fault identification result of the distribution network grounding data. The construction submodule is specifically used for: Step 2.1: Divide the historical grounding data of the distribution network corresponding to the fault or disturbance information into a sample set and a test set; Step 2.2: Extract feature vectors based on the sample set, and form different antigen sets based on the fault or disturbance type. Step 2.3: training and learning each antigen set separately to obtain a feature vector reflecting the feature space of each antigen, and setting the feature vector as a memory cell; Step 2.4: Gather all memory cells into one set as an artificial immune network model; Step 2.5: Testing the artificial immune network model based on the test set to obtain the fault identification accuracy of the artificial immune network model on the test set; Step 2.6: If the accuracy is less than the judgment threshold, use the particle swarm algorithm to optimize the artificial immune network training parameters with the goal of maximizing the test set fault identification accuracy and return to step 2.2; if the accuracy is greater than or equal to the judgment threshold, the artificial immune network model is constructed; Fault types include: single-phase high-resistance ground fault, single-phase low-resistance ground fault, two-phase short-circuit ground fault, two-phase interphase fault, three-phase short-circuit ground fault, large motor starting, asymmetric load, and non-synchronous closing; The training and learning of the antigen set to obtain memory cells of the antigen feature space includes: Step 3.1: Randomly generate antibodies and calculate the affinity between the same type of antigen and memory cells; Step 3.2: Input an antigen in the antigen set, select the antibody with the highest clone affinity, and clone it to generate a clone set, where the antigen is a data in the antigen set; Step 3.3: Affinity maturation is performed on each antibody in the clone set to generate a mutation set; Step 3.4: Determine the affinity between all antigens and the mutation set; reselect antibodies with the highest affinity as a partial antibody group; and simultaneously eliminate memory antibodies with affinity less than the natural death threshold in the partial antibody group; Step 3.5: Calculate the affinity of each antibody with other antibodies in the cleared portion of antibodies, and use the cleared antibodies whose affinity with all other antibodies in the cleared portion is higher than the inhibition threshold as memory cells; Step 3.6: Select the next antigen and return to step 3.2 until all antigens are presented to the network; Step 3.7: Calculate the affinity of each memory cell with every other memory cell. Eliminate any memory cell whose affinity with all other memory cells is above the inhibition threshold. Calculate the average Euclidean distance between the eliminated memory cells and the antigen to obtain the average affinity. If the specified number of iterations is reached or the difference in average affinity after two iterations is below the specified threshold, terminate the training process and obtain the memory cell set. Otherwise, proceed to step 3.
8. Step 3.8: Adaptively adjust the network itself according to the adaptive variance of the generated memory cells during training; Step 3.9: Randomly generate d r antibodies and add them to the antibody; Step 3.10: Calculate the affinity between the same type of antigen and memory cells, and return to step 3.2; The method of automatically performing adaptive adjustment on the network itself according to the adaptive variance of generated memory cells in the network training includes: Calculate the variance of the existing memory cell set; Calculate the difference between two iterations of the memory cell set by using the memory cell set variance; Adaptive adjustment is accomplished by updating each memory cell based on the difference between two iterations before and after the memory cell.
Citation Information
Patent Citations
Oil-immersed reactor fault diagnosis method, device and system based on PSO-SVM and artificial immune algorithm
CN109490661A