Power grid fault positioning method and system based on whale optimization, terminal and medium
By applying an improved method based on whale optimization in convolutional neural networks, the gradient instability problem in power grid data processing is solved, and more accurate fault location is achieved.
Patent Information
- Application Number
- CN202510226777.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-27
- Publication Date
- 2025-06-27
AI Technical Summary
Convolutional neural networks are difficult to converge when processing large-scale power grid data, resulting in gradient explosion or disappearance, affecting the accuracy of fault location.
The improved method based on whale optimization is adopted to train the convolutional neural network, and the data is processed through denoising and dimensionality reduction, and the dimension of the model input data is reduced, and the improved whale optimization method is used to find the optimal parameters during model training.
It effectively avoids gradient explosion and gradient disappearance problems, improves the adaptability of convolutional neural networks when processing large sample data, and realizes accurate positioning of power grid faults.
Smart Images

Figure CN120214477A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of deep learning, and particularly relates to a power grid fault location method, system, terminal and storage medium based on whale optimization. Background Art
[0002] With the continuous expansion of the scale of the power grid, there are more and more various electrical equipment on the transmission and distribution lines, various substations, distribution stations and energy storage stations in the power system. Therefore, when one or several of these devices work abnormally, due to the large number of overall devices, it is often very difficult to find the location of the faulty device within a short time and complete the corresponding location, excision and maintenance. In the initial stage of these abnormalities, the power grid can generally continue to operate for a long time. However, if not dealt with in time, it is very likely to directly evolve into a fault after a certain event, directly causing permanent damage to electrical equipment and even affecting other devices connected to it, resulting in huge economic losses.
[0003] As a powerful deep learning model, the Convolutional Neural Network (CNN) has shown great potential and application value in the field of fault prediction. However, problems such as the difficulty of convergence of the convolutional neural network due to excessive sample data volume or improper parameter settings often occur, seriously affecting the performance of the convolutional neural network training model and resulting in the inability to accurately predict hidden faulty devices.
[0004] When facing the situation of excessive sample data volume, the dimensions and complexity of the data that the convolutional neural network needs to process and learn during the training process increase sharply. When the data volume is too large, the calculation of the gradient becomes extremely complex and unstable. On the one hand, a large amount of data will cause the amplitude and direction of gradient update to fluctuate frequently, making the training process of the model oscillate and difficult to move forward stably in the direction of the optimal solution. On the other hand, too large a data volume may also cause problems such as gradient disappearance or gradient explosion, resulting in the model being unable to converge to a stable state. Summary of the Invention
[0005] Aiming at the above deficiencies of the prior art, the present invention provides a power grid fault location method, system, terminal and storage medium based on whale optimization to solve the above technical problems.
[0006] In the first aspect, the present invention provides a power grid fault location method based on whale optimization, including: Obtaining detection data of multiple electrical devices within a first time period, where the detection data includes characteristic values of detection signals of multiple sensors; Performing denoising and dimensionality reduction processing on the detection data to obtain sample data; Using an improved whale optimization method, train a pre - constructed convolutional neural network based on the sample data to obtain a fault location model; The fault location model is used to determine the power grid fault location according to the detection data of multiple power devices within a second time period; The first time period is before the second time period.
[0007] In an alternative embodiment, obtaining the detection data of multiple power devices within a first time period includes: Obtain the original detection signals generated by the sensors of the power devices within the first time period; Segment the original detection signals of the sensors of the same power device into groups with a time interval of 0.25 seconds to obtain detection signal sequences of the same length; Extract feature values from the detection signal sequences, where the feature values include maximum value, minimum value, mean value, standard deviation, root mean square, skewness, peak value, center frequency, average frequency, root mean square of frequency, maximum amplitude frequency and its corresponding amplitude, highest frequency, lowest frequency; Save the feature values corresponding to different sensors of the same power device into the same array, and denote the array as the feature array of the power device; Integrate the feature arrays of multiple power devices into a matrix.
[0008] In an alternative embodiment, integrating the feature arrays of multiple power devices into a matrix includes: Traverse all the power device information in the target power grid. During the traversal, filter out the same - type power devices, where the same - type power devices are those with the same number and type of sensors; For each group of the filtered same - type power devices, perform an alignment operation on their respective feature arrays according to the type of feature values and the type of sensors to which the feature values belong, so as to ensure that the column position of each feature value in the matrix corresponds to the same feature type and sensor type; After completing the alignment of the feature arrays, combine the feature arrays of these same - type power devices into a matrix; after traversing all the power device information, obtain multiple corresponding matrices.
[0009] In an alternative embodiment, performing denoising and dimensionality reduction processing on the detection data to obtain sample data includes: Eliminate the bad point data that does not conform to the normal distribution in each column of the matrix; Use the principal component analysis method to perform dimensionality reduction processing on the rows of the matrix.
[0010] In an alternative embodiment, using the principal component analysis method to perform dimensionality reduction processing on the rows of the matrix includes: The expression of the matrix is , where N is the number of component quantities, representing the total number of p feature quantities extracted by n sensors respectively, that is, N = n × p; M is the number of power equipment; For the element a ij , the formula for calculating its standard value is:
[0011] Among them, a ij is the element in the i-th row and j-th column, b ij is the element in the i-th row and j-th column after standardization, μ is the matrix A sj 's column mean, σ is the column standard deviation; The matrix A sj The standardized matrix is denoted as B, ; Calculate the eigenmatrix R and the element eigenvalues contained in the eigenmatrix, where the eigenmatrix R can be obtained through the following formula: R = B T B B is a matrix with M rows and N columns, B T is its transpose matrix, R is an N*N matrix, with N element eigenvalues, corresponding to the respective elements in matrix B in order, and the element eigenvalues corresponding to the respective elements are denoted as p1, p2,..., p N ; Calculate the contribution rate of each element according to the eigenmatrix:
[0012] Sort all elements in descending order of contribution rate; Starting from the element with the highest ranking, gradually calculate the cumulative contribution rate. If the latest cumulative contribution rate reaches the set contribution rate threshold, then the element currently participating in the calculation of the cumulative contribution rate is recorded as the principal component; Extract the principal component elements from matrix B according to the principal component index to obtain the dimensionality-reduced sample data.
[0013] In an alternative embodiment, using an improved whale optimization method, training a pre-constructed convolutional neural network based on the sample data includes: Initialize the parameters of the convolutional neural network model, the individual positions and fitness of the whale population, the maximum number of iterations, and the initial temperature value; Map the position of each whale individual to the parameters of the convolutional neural network model, and use the cross-entropy loss to evaluate the updated convolutional neural network model to obtain the fitness of each whale individual; In each iteration, update the positions of the whale population according to the rules of surrounding prey, bubble net hunting, and searching for prey. At the same time, incorporate the simulated annealing algorithm and adaptive weight coefficients to correct the iteration results; Update the parameters of the convolutional neural network model based on the individual positions of the updated whale population and the mapping relationship between the individual positions and the parameters; Confirm that the number of iterations reaches the maximum number of iterations or the convolutional neural network model converges, and the iteration process ends.
[0014] In an alternative embodiment, update the positions of the whale population according to the rules of surrounding prey, bubble net hunting, and searching for prey. At the same time, incorporate the simulated annealing algorithm and adaptive weight coefficients to correct the iteration results, including: Confirm that there are a total of d categories of parameters to be optimized in the convolutional neural network model. In the discrete d-dimensional space, regard the training networks with different parameters as the positions of a whale individual. If the current is the population in the i-th iteration, the best individual position in the whale group is denoted as X * (i)=[x1 * … x d * . Then, for the individual X j , under the shrinking encircling strategy, its next position under the influence of the current position X j (i) and the optimal individual position X * (i) is:
[0015]
[0016] where w is the adaptive weight; A and C are coefficient variables:
[0017]
[0018] where a is a variable with a value between 0 and 2, and r is a random number in the interval [0, 1]; In the bubble net hunting stage, reduce the value of a and update it according to the form a = 2 - 2j / MaxIter, where MaxIter is the maximum number of iterations; during this process, the value range of A is [-a, a]; when |A| > 1, it represents the global search ability of the whale, and when |A| < 1, it represents the local search ability of the whale. The individual position update formula under the spiral position update strategy is:
[0019]
[0020] Among them, b is the logarithmic spiral shape constant; l is a random number in the interval [-1, 1]; Since there are the above two predation behaviors after discovering prey, according to the random probability p, the contraction encirclement or bubble predation is selected, and the position update formula of the individual after introducing the random probability p is:
[0021] Among them, p is a random number in the interval [0, 1]; p1 is the probability correction coefficient. In the later stage of iteration, the value of p1 corresponds to the behavior type adopted by the whale individual, and the behavior type includes the shrinking encirclement strategy and the spiral position update strategy; If A exceeds the range of [-1, 1], then the distance data Dj ** (i) Random update:
[0022]
[0023] Among them, X rand (i) is the position of a random whale individual in the population at the i-th iteration; By introducing the probability P of accepting inferior solutions to get out of the misunderstanding of local optimum, the calculation formula of the probability of accepting inferior solutions is:
[0024] Among them, f(X j (i)) is the fitness of the individual X j at the i-th iteration, and t is the temperature at the i-th iteration; When f(X j (i + 1)) > f(X j (i)), accept X j (i + 1); when f(X j (i + 1)) < f(X j (i)), accept the inferior position X j (i + 1) with probability P; calculate the annealing probability P of each whale individual respectively, and accept the inferior solution based on the annealing probability of the whale individual; Introduce the adaptive weight coefficient w into the population position update method:
[0025]
[0026]
[0027] During the iteration process, the fitness values f(1)-f(d) of the whale individuals are sorted in ascending order, and then the fitness sequence is divided into the first half and the second half. The average fitness values favg1 and favg2 of the first half and the second half are calculated respectively, where favg2 > favg1; If the fitness f(j) of the individual position of any whale individual is greater than favg2, it is determined that the individual position is searching for the optimal position, and the self-adaptive weight coefficient is taken in the range of [0.9, 1.1] to search for the optimal solution within a local range; If favg1 < f(j) < favg2, it is determined that the individual position is in a neither good nor bad position in the population, and w can be taken as 1 to search for the optimal solution in the original direction; If f(j) < favg1, it is determined that the individual position is in a relatively poor position in the population, and w is randomly taken as a number in the ranges of [0.4, 0.7] and [1.3, 1.6] with a probability of 50%.
[0028] In a second aspect, the present invention provides a power grid fault location system based on whale optimization, including: An acquisition module, configured to acquire detection data of multiple power devices within a first time period, where the detection data includes characteristic values of detection signals of multiple sensors; A preprocessing module, configured to perform denoising and dimensionality reduction processing on the detection data to obtain sample data; A processing module, configured to use an improved whale optimization method to train a pre-constructed convolutional neural network based on the sample data to obtain a fault location model; The fault location model is used to determine the power grid fault location according to the detection data of multiple power devices within a second time period; The first time period is before the second time period.
[0029] In a third aspect, a terminal is provided, including: A memory, configured to store a power grid fault location program based on whale optimization; A processor, configured to implement the steps of the power grid fault location method based on whale optimization provided in the first aspect when executing the power grid fault location program based on whale optimization.
[0030] In a fourth aspect, a computer-readable storage medium is provided, on which a power grid fault location program based on whale optimization is stored. When the power grid fault location program based on whale optimization is executed by a processor, the steps of the power grid fault location method based on whale optimization provided in the first aspect are implemented.
[0031] The beneficial effects of the present invention are as follows. The power grid fault location method, system, terminal and storage medium provided by the present invention perform denoising and dimensionality reduction on the detection data to reduce the dimensionality of the input data of the convolutional neural network model. Furthermore, an improved whale optimization method is adopted to search for the optimal model parameters in the desired direction during the model training process, effectively avoiding gradient explosion and gradient disappearance, and improving the adaptability of the convolutional neural network in processing large sample data, thereby realizing the accurate location of power grid faults.
[0032] In addition, the design principle of the present invention is reliable, the structure is simple, and it has a very wide application prospect. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for the description of the embodiments or the prior art. Obviously, for those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0034] Figure 1 It is a schematic flowchart of the method according to an embodiment of the present invention.
[0035] Figure 2 It is a schematic flowchart of the data preprocessing of the method according to an embodiment of the present invention.
[0036] Figure 3 It is a schematic flowchart of updating the model parameters based on the improved whale optimization method of the method according to an embodiment of the present invention.
[0037] Figure 4 It is a schematic block diagram of the system according to an embodiment of the present invention.
[0038] Figure 5 It is a schematic structural diagram of a terminal provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0039] In order to enable those skilled in the art to better understand the technical solutions in the present invention, the following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
[0040] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the technical field to which this invention belongs. The terms used in the description of this invention herein are for the purpose of describing specific embodiments only and are not intended to limit the invention.
[0041] The following explains the key terms that appear in this invention.
[0042] The Whale Optimization Algorithm (WOA) is a new swarm intelligence optimization algorithm proposed by Mirjalili et al. from Griffith University in Australia in 2016. It simulates the foraging behavior of humpback whales in nature and solves optimization problems through a mathematical model, and has been widely applied in many fields such as function optimization, engineering design, and machine learning.
[0043] The Convolutional Neural Network (CNN) is a type of deep learning model specifically designed to process data with grid structures.
[0044] The power grid fault location method based on whale optimization provided by the embodiments of this invention is executed by a computer terminal. Correspondingly, the power grid fault location system based on whale optimization runs in the computer terminal.
[0045] Figure 1 It is a schematic flowchart of the method of an embodiment of this invention. Among them, Figure 1 The execution subject can be a power grid fault location system based on whale optimization. According to different requirements, the order of the steps in this flowchart can be changed, and some can be omitted.
[0046] As Figure 1 shown, this method includes: S1. Obtain the detection data of multiple power devices within a first time period, where the detection data includes the characteristic values of the detection signals of multiple sensors; S2. Perform denoising and dimensionality reduction processing on the detection data to obtain sample data; S3. Use the improved whale optimization method to train a pre-constructed convolutional neural network based on the sample data to obtain a fault location model; The fault location model is used to determine the power grid fault location according to the detection data of multiple power devices within a second time period; The first time period is before the second time period.
[0047] In an embodiment of this invention, based on step S1, the following will give a possible embodiment to non-restrictively elaborate on its specific implementation.
[0048] S101. Obtain the original detection signals generated by the sensors of the power equipment within the first time period.
[0049] For example, collect the power grid monitoring data of the past year, including the detection signals within 1 hour before the failure of the faulty equipment in the power grid. The detection signals include but are not limited to voltage detection signals, current detection signals, temperature detection signals, and vibration detection signals.
[0050] Specifically, when a certain equipment fails, the time series data collected by n sensors in the system. For example, when the equipment Q in the system is abnormal, the time series received by sensor 1 is recorded as data1-Q.
[0051] S102. Divide the original detection signals of the sensors of the same power equipment into groups at 0.25-second intervals to obtain detection signal sequences of the same length.
[0052] Considering that even in the same system, the sampling accuracy and sampling interval of each sensor may be different, when collecting the original data, it is divided into groups with 50 power frequency cycles, that is, 0.25 seconds as a group.
[0053] S103. Extract eigenvalue from the detection signal sequence, and the eigenvalue includes maximum value, minimum value, mean value, standard deviation, root mean square, skewness, peak value, center frequency, average frequency, root mean square of frequency, maximum amplitude frequency and its corresponding amplitude, highest frequency, lowest frequency.
[0054] Use the Python language combined with the numpy and scipy libraries to extract eigenvalue, specifically including: Time domain feature calculation: np.max(signal) and np.min(signal) calculate the maximum and minimum values of the signal respectively.
[0055] np.mean(signal) calculates the mean value of the signal.
[0056] np.std(signal) calculates the standard deviation of the signal.
[0057] np.sqrt(np.mean(np.square(signal))) calculates the root mean square of the signal.
[0058] skew(signal) calculates the skewness of the signal.
[0059] np.max(np.abs(signal)) calculates the peak value of the signal.
[0060] Frequency domain feature calculation: Use scipy.fft.fft to perform a fast Fourier transform on the signal to obtain the frequency-domain representation.
[0061] scipy.fft.fftfreq calculates the corresponding frequency axis.
[0062] The center frequency is calculated by weighted average, with the weights being the amplitudes corresponding to each frequency.
[0063] The average frequency and the root mean square of the frequency are calculated by np.mean(xf) and np.sqrt(np.mean(np.square(xf))), respectively.
[0064] The frequency with the maximum amplitude and its corresponding amplitude are determined by finding the frequency point with the largest amplitude.
[0065] The highest frequency and the lowest frequency are calculated by np.max(xf) and np.min(xf), respectively.
[0066] S104. Save the eigenvalue corresponding to different sensors of the same power device into the same array, and denote the array as the feature array of the power device.
[0067] For example, when device Q in the system is abnormal, the samples extracted after processing the sensor data can be recorded as a set of data in the form of one-dimensional row vectors: Sample = [X 11 , X 12 , …, X 1p , X 21 , X 22 , …, X 2p , …, X n1 , …, X np , Q ] where X 11 is the first eigenvalue extracted from the first sensor data, and X 1p is the p-th eigenvalue extracted from the first sensor data; X n1 is the first eigenvalue extracted from the n-th sensor data, and X np is the p-th eigenvalue extracted from the n-th sensor data, and Q represents the device with an abnormality, marking the sample.
[0068] S105. Integrate the feature arrays of multiple power devices into a matrix.
[0069] (1) Traverse all the power device information in the target power grid and screen out the same type of power devices. Divide the power devices with the same model and the same function into the same category.
[0070] (2)For each group of the same type of power equipment selected, perform the alignment operation of the feature arrays. For each group of the same type of power equipment, their respective feature arrays need to be obtained from the database or the file system. Before performing the alignment operation, it is necessary to clarify the feature value type and the sensor type. These information can be obtained through the description information in the metadata file or the database. According to the feature value type and the sensor type, perform the alignment operation on the feature arrays.
[0071] (3)Create an empty matrix, and then fill each feature value into the corresponding column position of the matrix according to its corresponding feature type and sensor type.
[0072] (4)After performing the alignment and matrix combination operations on all groups of the same type of power equipment, multiple corresponding matrices are finally obtained.
[0073] Please refer to Figure 2 , in an embodiment of the present invention, based on step S2, a possible embodiment will be given below to non - restrictively elaborate on its specific implementation.
[0074] S201. Eliminate bad - point data.
[0075] For a certain determined column j, since the corresponding elements in the sample data group are all signals collected by the same sensor when the same device has an abnormality, the numerical distribution of the corresponding elements in this column j satisfies the normal distribution. At the same time, in this application, it is default that the obtained sample quantity is large enough to meet the sampling quantity requirements of the R - rule. Therefore, the R - rule can be used to screen and eliminate the bad - point data among them.
[0076] Taking the j - th column as an example, assume there are n samples in total. First, calculate the mean x j of the n sample data in this column and the standard deviation ; then calculate the lower limit and the upper limit of the corresponding sample values according to the R - rule; traverse all the data in the j - th column, and eliminate the samples whose element values in the j - th column are not within the interval, that is, the bad - point data; except for the last column used as a marker, start the above - mentioned screening process for all other columns from the first column, and finally obtain the sample data group after eliminating the bad - points. The advantage of doing this is that it can effectively eliminate the suspicious data with extremely large deviations generated due to electromagnetic noise interference, sensor errors, and errors in the data collection, storage, and processing processes in the experimental data, improve the data quality of the sample data, and improve the effects of subsequent training, recognition, and judgment.
[0077] S202. Data dimensionality reduction.
[0078] There is information redundancy in the original data, resulting in a large amount of information redundancy in the horizontal elements of the obtained Sample. If no screening and dimensionality reduction are performed, it will not only reduce the speed and efficiency of feature extraction, but also cause the computational complexity in the subsequent recognition and positioning processes to increase geometrically with the increase of the convolution size, number of layers, and depth, making it impossible to be applied in practice. Therefore, the present invention screens and selects the above-mentioned feature quantities based on the principal component analysis method, reducing the difficulty and computational time of recognition and positioning calculations.
[0079] For the sample data set (Sample1 - Sample m ), first discard the last column of marker values and write them all in the following design matrix A sj form:
[0080] In the formula, N is the number of components, representing the total number of p feature quantities extracted by n sensors respectively, that is, N = n×p; M is the number of power equipment; First, in order to eliminate the influence of the dimension of different features and make each feature have the same scale, the matrix A sj is standardized. For the element a ij , the formula for calculating its standard value is:
[0081] where a ij is the element in the i-th row and j-th column, b ij is the element in the i-th row and j-th column after standardization, μ is the column mean of the matrix A sj , σ is the column standard deviation; The standardized matrix of the matrix A sj is denoted as B, ; Calculate the feature matrix R and the element eigenvalues included in the feature matrix. The feature matrix R can be obtained through the following formula: R = B T B B is a matrix with M rows and N columns, B T is its transpose matrix, R is an N*N matrix, with N element eigenvalues, corresponding to each element in the matrix B in order. The element eigenvalues corresponding to each element are denoted as p1, p2,..., p N ; Calculate the contribution rate of each element in the matrix B according to the feature matrix:
[0082] The level of the contribution rate indicates the importance of this component in the sample identification. The sum of the contribution rates of the top several components is called the cumulative contribution rate. Select the components with higher contribution rates as the principal components of the data, and if the cumulative contribution rate of the principal components reaches a certain level or above, it is considered that the screening of the principal components is completed.
[0083] Taking the case of N = 5 as an example, if p1 - p5 are -1, -2, 2.5, 3, 3.5 respectively, then the contribution rate corresponding to p1 is:
[0084] The calculation processes of the contribution rates of the other four components are similar, and the cumulative contribution rates and their rankings of each component can be obtained as shown in Table 1 below.
[0085] Table 1 Cumulative contribution rates and their rankings of each component
[0086] According to Table 1, the sample contribution rate of component p1 is the lowest, and the cumulative contribution rates of the other components exceed 90%. Therefore, this component can be discarded to reduce the dimension of the data sample; while the contribution rate of component p2 is the second lowest, but its contribution rate is relatively high. After discarding it, the remaining contribution rate of the components is only 75%. Therefore, it should not be discarded (in the actual application process, the contribution rate of the discarded component is generally much lower than 1 / N). That is, the sample with a final dimension of 5 becomes 4 - dimensional after dimensionality reduction by principal component analysis.
[0087] After principal component analysis, the dimension of the sample data is greatly reduced, facilitating the acquisition of sample data and subsequent calculations. However, as mentioned in the above example, when performing principal component dimensionality reduction, in the actual application process, the contribution rate of the discarded component is generally much lower than 1 / N, and the contribution rate of the discarded component in the example is relatively high, which is unreasonable. Therefore, certain strategies must be formulated to verify the results of principal component analysis and selection.
[0088] This application provides a verification method, including: Sort all elements in descending order of contribution rate; starting from the element with the highest ranking, gradually calculate the cumulative contribution rate. When it is confirmed that the latest cumulative contribution rate reaches the set contribution rate threshold, mark the element currently participating in the cumulative contribution rate calculation as the principal component; extract the principal component elements from matrix B according to the principal component index to obtain the dimensionality - reduced sample data.
[0089] Specifically, it includes the following steps: ① Re - sort the N components according to the contribution rate and denote them as p1 - p N , and calculate the cumulative contribution rate.
[0090] ② Starting from p NStart discarding the components with lower contribution rates until the cumulative contribution rate is just below 90%. Denote the amount of the last non-discarded component at this time as p k 。
[0091] ③ If the cumulative contribution rate of p1 - p k is lower than 85%, then restore component p k+1 and denote the amount of the last non-discarded component p k+1 as p l ; if the cumulative contribution rate of p1 - p k is not lower than 85%, directly denote p k as p l 。
[0092] ④ Check the contribution rates of p l+1 and the subsequent discarded components. If the contribution rate of the corresponding component is not higher than 1 / 5N (empirical value), it is considered that the selection of l principal components is completed at this time; if the contribution rate of the corresponding component is higher than 1 / 5N, then restore the corresponding component, and denote the cumulative contribution rate of the restored m components (m ≥ l + 1) as LJConm.
[0093] ⑤ If the value of LJConm is not higher than 92.5%, it is considered that the selection of m principal components is completed at this time.
[0094] ⑥ If the value of LJConm is higher than 92.5%, then check the contribution rate Conm of component pm. If Conm is greater than 2.5%, it is considered that the selection of m principal components is completed at this time; if Conm is not greater than 2.5%, discard component m, and the selection of m - 1 principal components is completed at this time.
[0095] ⑦ Sort and integrate the samples according to the selection results, and feedback them to the data collection stage, so that only the "principal component" feature quantities are extracted in the feature extraction stage of the final data samples, simplifying the feature extraction process.
[0096] Revise all samples, only retain the device marker column and the principal component column, and discard the non-principal component data. At this time, an example of the data sample when device Q fails is: NewSample = [X1, X2,..., X n , Q ] where Q is the device marker and n is the number of principal components.
[0097] In an embodiment of the present invention, based on step S3, a possible embodiment will be given below to non-restrictively elaborate on its specific implementation.
[0098] The model training process and the model parameter optimization process are combined, and a certain training speed is required. Therefore, in the present invention, different numbers of training and test sets are divided according to empirical values for different orders of magnitude of the number of training samples, as shown in Table 2.
[0099] Table 2 Division of Training and Validation Sets with Different Sample Sizes
[0100] The advantage of such a division method is that it enables the training process of the localization recognition model to have a high training speed, while ensuring a certain training quality, which facilitates the optimization of parameters.
[0101] Taking the one-dimensional convolutional neural network method as an example, the parameters that need to be set include the pooling function, padding function, number of pooling layers, size; activation function, number of convolutional layers, convolutional kernel size, stride, padding method, number of fully connected layers, number of fully connected neurons in each layer, learning rate, batch size, number of training epochs, weight decay, etc.
[0102] For these model parameters, the selection of each individual parameter itself is discrete and bounded. For example, the activation function is selected from functions such as ReLU, Leaky ReLU, Sigmoid, Tanh, etc., and the number of convolutional layers is only an integer, and generally has upper and lower limits; while the parameters for measuring the quality of the model include parameterizable mathematical quantities such as the recognition accuracy of the validation set and the recognition accuracy of the training set. Therefore, the optimization process of model parameters can also be transformed into a global optimization problem of discrete parameters.
[0103] Specifically, the model training process includes: S301. Initialize the parameters of the convolutional neural network model, the individual positions and fitness of the whale population, the maximum number of iterations, and the initial temperature value; S302. Map the position of each whale individual to the parameters of the convolutional neural network model, and use the cross-entropy loss to evaluate the updated convolutional neural network model to obtain the fitness of each whale individual; S303. In each iteration, update the position of the whale population according to the rules of surrounding prey, bubble hunting, and searching for prey, and at the same time incorporate the simulated annealing algorithm and adaptive weight coefficients to correct the iteration results; S304. Update the parameters of the convolutional neural network model according to the individual positions of the updated whale population and the mapping relationship between the individual positions and the parameters; S305. Confirm that the number of iterations reaches the maximum number of iterations or the convolutional neural network model converges, and the iteration process ends.
[0104] The whale optimization method is a new swarm intelligence optimization algorithm that mimics the foraging behavior of humpback whales in nature. Its foraging process can be mainly divided into three categories: searching for prey, surrounding prey, and foaming attack. Among them, surrounding prey and foaming attack belong to the foraging stage after discovering prey, and searching for prey aims to discover prey.
[0105] 1) Surround the prey. Assume that there are d categories of model parameters to be optimized. In this discrete d-dimensional space, the training networks with different parameters can be regarded as the "positions" of individual whales. If the current population is at the i-th iteration, the position of the best individual in the whale population is denoted as X * (i)=[x1 * … x d * . Then, for individual X j , its next position under the influence of the current position X j (i) and the optimal individual position X * (i) is:
[0106]
[0107]
[0108] where A and C are coefficient variables:
[0109]
[0110] where a is a variable with a value between 0 and 2, and r is a random number in the interval [0, 1].
[0111] 2) Bubble predation. Bubble predation simulates the predation behavior of humpback whales spitting bubbles, which mainly consists of two processes: shrinking the enclosure and spiral position update.
[0112] Shrinking the enclosure: That is, reducing the value of a, and updating it in the form of a = 2 - 2j / MaxIter, where MaxIter is the maximum number of iterations. During this process, the value range of A is [-a, a]. Once this range changes, a will also change accordingly. When |A| > 1, it represents the global search ability of the humpback whale, and when |A| < 1, it represents the local search ability of the humpback whale.
[0113] The process of spiral position update is as follows:
[0114]
[0115] where b is the logarithmic spiral shape constant; l is a random number in the interval [-1, 1].
[0116] Since there are two predation behaviors, the shrinking enclosure strategy and the spiral position update strategy, after discovering the prey, the above position update formula can be updated as follows according to the random probability p to select either the shrinking enclosure or the spiral position update:
[0117] Among them, p is a random number in the interval [0, 1]; p1 is a probability correction coefficient, which has a relatively large value in the later stage of iteration, reflecting the behavior that the humpback whale has a relatively high probability of shrinking the encirclement in the later stage; it has a relatively small value in the early stage of iteration, reflecting the process that the humpback whale has a relatively high probability of spirally encircling the prey in the early stage. For example, it can be taken as:
[0118] MaxIter is the maximum number of iterations.
[0119] 3) Search for prey In addition to the predation process, searching for prey is also a crucial process. However, the process of searching for prey in the whale optimization method has a relatively large randomness, and its global optimization ability is relatively weak, and it is easy to fall into the dilemma of local optimum. Mathematically, the update of the position of the whale population when searching for prey is based on the change of A, that is, if A exceeds the range of [-1, 1], then the distance data Dj ** (i) Random update:
[0120]
[0121] Among them, X rand (i) is the position of a randomly selected whale individual in the population at the i-th iteration.
[0122] To solve the inherent defect of the whale optimization algorithm, that is, the problem of insufficient global optimization ability, this application combines the simulated annealing algorithm with excellent global optimization ability and the knowledge acquisition and sharing algorithm to improve the traditional whale optimization method.
[0123] The core of the simulated annealing method lies in accepting inferior solutions with a certain probability during calculation, so as to jump out of the misunderstanding of local optimum to a certain extent. The core lies in the introduction of this probability P:
[0124] Among them, f(X j (i)) is the fitness of the individual X j at the i-th iteration, and t is the temperature at the i-th iteration.
[0125] The core idea of introducing simulated annealing is that when f(X j (i + 1)) > f(X j (i)), accept X j (i + 1); otherwise, accept the inferior position X j (i + 1) with probability P, so as to solve the problem that the whale optimization is easy to fall into local optimum. In this application, the annealing probability P of each whale individual is independent and needs to be calculated separately.
[0126] Meanwhile, to enhance the global and local search capabilities of the improved whale optimization algorithm, this application also introduces an adaptive weight coefficient w. The core idea is to enhance the ability of the whale optimization method to escape from local optimal solutions and quickly find the global optimal solution region by expanding the search span during global search; to avoid "jitter" by reducing the search span during local search.
[0127] The updated method of the population position after introducing the adaptive weight coefficient w is as follows:
[0128]
[0129] During the iteration process, sort the fitness values f(1)-f(d) of the whale individuals in ascending order, and then divide them into two halves to calculate their average fitness values favg1 and favg2 respectively, where favg2 > favg1.
[0130] If the fitness value f(j) of a certain individual's position > favg2, it means that this individual's position is dominant in the population. To find the optimal position, the adaptive weight coefficient can be taken from the interval [0.9, 1.1] to find the optimal solution within the local range.
[0131] If favg1 < f(j) < favg2, it means that the individual's position is neither excellent nor poor in the population. We can take w = 1 and search for the optimal solution in the original direction.
[0132] If f(j) < favg1, it means that the individual's position is relatively poor in the population. Let w be randomly taken from the intervals [0.4, 0.7] and [1.3, 1.6] with a probability of 50% each to enhance its global optimization ability.
[0133] Please refer to Figure 3 , the method for updating the model parameters using the improved whale optimization algorithm in one iteration includes: 1. Initialization of iteration parameters Initialize various parameters required during the algorithm iteration process, such as the maximum number of iterations M, the probability correction coefficient p1, the simulated annealing temperature T, etc.
[0134] 2. Initialization of the whale population position In the discrete d-dimensional space, initialize the positions of each individual in the whale population. Here, d corresponds to the number of categories of model parameters to be optimized, and the training networks of different parameters can be regarded as the "positions" of a whale individual.
[0135] 3. Calculate the population fitness and find the optimal individual For the initialized whale population, calculate the fitness value of each individual. The fitness value reflects the quality of the individual in the current problem. By comparing the fitness values of all individuals, find the best individual in the current population, and its position is denoted as X * (i)=[x1 * 、… x d * .
[0136] 4. Update process parameters a is a variable with a value ranging from 0 to 2, which is updated according to a specific rule, such as a = 2 - 2j / M (j is the current iteration number), and it affects the value range of the coefficient variable A
[0137] A and C are coefficient variables, which are calculated according to a and the random number r
[0138] w is the adaptive weight coefficient, and its value is adjusted according to the fitness of the whale individuals in the population. If the individual fitness f(j) > favg2 (the better individuals in the population), w takes values in the range of [0.9, 1.1]; if favg1 < f(j) < favg2 (the medium individuals in the population), w = 1; if f(j) < favg1 (the worse individuals in the population), w takes random numbers in the ranges of [0.4, 0.7] and [1.3, 1.6] with a probability of 50% each
[0139] p is a random number in the range of [0, 1], which is used to select the shrinking encirclement or spiral position update strategy during the bubble hunting process
[0140] p1 is the probability correction coefficient, which has a larger value in the later stage of iteration and a smaller value in the early stage of iteration. The specific value is such as p1 = 0.2 + 0.8×(j / MaxIter) 2 .
[0141] 5. Judge whether p < p1 holds If p ≤ p1, enter the next judgment whether it holds; If p > p1, the whale continues to search for prey and updates its position according to the formula Update the position
[0142] 6. Judge whether it holds If , the whale shrinks the encirclement and updates its position according to the formula Update the position; If , the whale performs a spiral encirclement of the prey and updates its position according to the formula Update the position
[0143] 7. Perform operations based on simulated annealing According to the idea of the simulated annealing algorithm, when f(X j (i + 1)) > f(X j (i)), accept X j (i + 1); when f(X j (i + 1)) < f(X j (i)), accept the inferior position X with a probability j (i + 1).
[0144] 8. Update the population fitness and sort it in ascending order Recalculate the fitness values of each individual in the whale population after the above position update operation, and sort the individuals in ascending order of fitness values for subsequent classification and analysis of the population individuals.
[0145] 9. Update the annealing temperature Reduce the temperature t of the simulated annealing according to certain rules i+1 = t i × a. As the number of iterations increases, the temperature gradually decreases, and the probability of the simulated annealing algorithm accepting inferior solutions also gradually decreases.
[0146] 10. Update the number of iterations Increment the current number of iterations by 1. If the maximum number of iterations has not been reached, return to step 4 to continue the next round of iterative calculation; if the maximum number of iterations has been reached, the algorithm ends.
[0147] In some embodiments, the whale optimization-based power grid fault location system may include multiple functional modules composed of computer program segments. The computer programs of each program segment in the whale optimization-based power grid fault location system can be stored in the memory of the computer terminal and executed by at least one processor to execute (see Figure 1 description) the functions of the whale optimization-based power grid fault location.
[0148] In this embodiment, according to the functions it performs, the whale optimization-based power grid fault location system can be divided into multiple functional modules, such as Figure 4 shown. The functional modules of the system may include: an acquisition module, a preprocessing module, and a processing module. The module referred to in the present invention means a series of computer program segments that can be executed by at least one processor and can complete fixed functions, and are stored in the memory. In this embodiment, the functions of each module will be described in detail in subsequent embodiments.
[0149] The acquisition module is used to acquire the detection data of multiple power devices within the first time period, and the detection data includes the characteristic values of the detection signals of various sensors; A preprocessing module for denoising and dimensionality reduction of the detection data to obtain sample data; A processing module for training a pre-constructed convolutional neural network based on the sample data using an improved whale optimization algorithm to obtain a fault location model; The fault location model is used to determine the power grid fault location according to the detection data of multiple power devices within a second time period; The first time period is before the second time period.
[0150] Figure 5 The power grid fault location method based on whale optimization provided by the embodiments of the present application can be applied to a terminal. Those skilled in the art can understand that the terminal structure involved in the embodiments of the present invention does not constitute a limitation on the terminal. The terminal may include more or fewer components than shown in the figure, or combine some components, or have different component arrangements. In the embodiments of the present invention, the terminal includes, but is not limited to, a laptop computer, a desktop computer, a workbench, a personal digital assistant, a server, a blade server, a mainframe computer, and other suitable computers. The terminal may also represent various forms of mobile devices, such as, a personal digital processor, a cellular phone, a smart phone, a wearable terminal, and other similar computing devices. The components shown in the figure, their connections and relationships, and their functions are only examples and are not intended to limit the implementation of the embodiments of the present application described and / or claimed herein.
[0151] Among them, the terminal 500 may include: a processor 510, a memory 520, and a communication unit 530. These components communicate through one or more buses. Those skilled in the art can understand that the structure of the server shown in the figure does not constitute a limitation on the present invention. It can be a bus structure, a star structure, and may also include more or fewer components than shown in the figure, or combine some components, or have different component arrangements.
[0152] Among them, the memory 520 can be used to store the execution instructions of the processor 510. The memory 520 can be implemented by any type of volatile or non-volatile storage terminal or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, a magnetic disk, or an optical disk. When the execution instructions in the memory 520 are executed by the processor 510, the terminal 500 can execute some or all of the steps in the above method embodiments.
[0153] The processor 510 is the control center of the storage terminal, connecting various parts of the entire electronic terminal through various interfaces and circuits. By running or executing software programs and / or modules stored in the memory 520, and invoking data stored in the memory, it performs various functions of the electronic terminal and / or processes data. The processor may be composed of an integrated circuit (IC), for example, it may be composed of a single packaged IC, or it may be composed of multiple packaged ICs with the same or different functions connected together. For example, the processor 510 may only include a central processing unit (CPU). In the embodiments of the present invention, the CPU may be a single arithmetic core or may include multiple arithmetic cores.
[0154] The communication unit 530 is used to establish a communication channel so that the storage terminal can communicate with other terminals. It receives user data sent by other terminals or sends user data to other terminals.
[0155] The present invention also provides a computer storage medium. Among them, the computer storage medium can store a program, and when the program is executed, it may include some or all of the steps in the various embodiments provided by the present invention. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM), etc.
[0156] Those skilled in the art can clearly understand that the technology in the embodiments of the present invention can be implemented by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solutions in the embodiments of the present invention, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, etc., which can store program codes, and includes several instructions to enable a computer terminal (which may be a personal computer, a server, or a second terminal, a network terminal, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention.
[0157] For the same or similar parts among the various embodiments in this specification, reference can be made to each other. In particular, for the terminal embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and for the relevant parts, reference can be made to the descriptions in the method embodiments.
[0158] In several embodiments provided by the present invention, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are merely illustrative. For example, the division of the modules is only a logical function division. In actual implementation, there may be other division methods. For example, multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections between each other can be through some interfaces. The indirect couplings or communication connections of the systems or modules can be in electrical, mechanical or other forms.
[0159] The modules described as separate components may or may not be physically separated. The components displayed as modules may or may not be physical modules, that is, they can be located in one place or distributed to multiple network modules. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0160] In addition, in each embodiment of the present invention, the functional modules can be integrated in a processing module, or each module can exist physically alone, or two or more modules can be integrated in one module.
[0161] Although the present invention has been described in detail by referring to the drawings and in combination with the preferred embodiments, the present invention is not limited thereto. Without departing from the spirit and essence of the present invention, those of ordinary skill in the art can make various equivalent modifications or substitutions to the embodiments of the present invention, and these modifications or substitutions should all be within the scope of the present invention. / Any person skilled in the art within the technical scope disclosed by the present invention can easily think of changes or substitutions, which should all be covered within the protection scope of the present invention.
Claims
1. A power grid fault location method based on whale optimization, characterized in that: include: Acquire detection data of a plurality of electric power devices within a first time period, wherein the detection data includes characteristic values of detection signals of a plurality of sensors; Performing denoising and dimensionality reduction processing on the detection data to obtain sample data; Using the improved whale optimization method, the pre-built convolutional neural network is trained based on the sample data to obtain a fault location model; The fault location model is used to determine the power grid fault location based on the detection data of multiple power devices within the second time limit; The first time limit is before the second time limit.
2. The method according to claim 1, characterized in that Acquire detection data of multiple power devices within a first time period, including: Acquire an original detection signal generated by a sensor of the electric power equipment within a first time limit; The original detection signals of the sensors of the same power equipment are divided into groups of 0.25 seconds to obtain detection signal sequences of the same length; Extracting characteristic values from the detection signal sequence, the characteristic values including maximum value, minimum value, mean value, standard deviation, root mean square, skewness, peak value, center of gravity frequency, average frequency, root mean square of frequency, maximum amplitude frequency and its corresponding amplitude, highest frequency, and lowest frequency; Saving characteristic values corresponding to different sensors of the same electric power device into the same array, and recording the array as a characteristic array of the electric power device; Combine the characteristic arrays of multiple power devices into a matrix.
3. The method according to claim 2, characterized in that Combine the characteristic arrays of multiple power devices into a matrix, including: Traversing the information of all power equipment in the target power grid, and screening out the same type of power equipment during the traversal process, wherein the same type of power equipment is power equipment with the same number of sensors and sensor types; For each group of similar power devices screened out, their respective feature arrays are aligned according to the eigenvalue type and the sensor type to which the eigenvalue belongs, so as to ensure that the column position of each eigenvalue in the matrix corresponds to the same feature type and sensor type; After the alignment of the feature arrays is completed, the feature arrays of the same type of power equipment are combined into a matrix; after traversing the information of all power equipment, a plurality of corresponding matrices are obtained.
4. The method according to claim 2, characterized in that: The detection data is subjected to denoising and dimensionality reduction processing to obtain sample data, including: Eliminate bad pixel data that does not conform to normal distribution in each column of the matrix; The principal component analysis method is used to reduce the dimension of the rows of the matrix.
5. The method according to claim 4, characterized in that The rows of the matrix are subjected to dimensionality reduction processing using principal component analysis, including: The matrix expression is , where N is the component quantity, which means the total number of p feature quantities extracted by n sensors, that is, N=n×p; M is the number of power equipment; For element a ij , the formula for calculating its standard value is: Among them, a ij is the element in row i and column j, b ij is the element in the i-th row and j-th column after standardization, μ For the matrix A sj The column mean of σ is the column standard deviation; matrix A sj The standardized matrix is denoted as B. ; Calculate the characteristic matrix R and the eigenvalues of the elements contained in the characteristic matrix, where the characteristic matrix R can be obtained by the following formula: R=B T B B is a matrix with M rows and N columns. T is its transposed matrix, R is an N*N matrix with N element eigenvalues, which correspond to each element in the matrix B in sequence, and the element eigenvalues corresponding to each element are recorded in sequence as p1, p2, ..., p N ; Calculate the contribution rate of each element according to the characteristic matrix: Sort all elements by contribution rate from high to low; The cumulative contribution rate is calculated step by step starting from the element with the highest ranking. When the latest cumulative contribution rate reaches the set contribution rate threshold, the element currently participating in the cumulative contribution rate calculation is recorded as the main component. The principal component elements are extracted from matrix B according to the principal component index to obtain the sample data after dimensionality reduction.
6. The method according to claim 1, characterized in that The pre-built convolutional neural network is trained based on the sample data using the improved whale optimization method, including: Initialize the parameters of the convolutional neural network model, the individual positions and fitness values of the whale population, the maximum number of iterations, and the initial temperature value; Map the position of each whale individual to the parameters of the convolutional neural network model, and evaluate the updated convolutional neural network model using cross-entropy loss to obtain the fitness of each whale individual; In each iteration, update the positions of the whale population according to the rules of encircling prey, bubble-net attacking, and searching for prey, and at the same time incorporate the simulated annealing algorithm and adaptive weight coefficient to correct the iteration results; Update the parameters of the convolutional neural network model based on the individual positions of the updated whale population and the mapping relationship between the individual positions and the parameters; Confirm that the number of iterations reaches the maximum number of iterations or the convolutional neural network model converges, and the iteration process ends.
7. The method according to claim 6, characterized in that Update the positions of the whale population according to the rules of encircling prey, bubble-net attacking, and searching for prey, and at the same time incorporate the simulated annealing algorithm and adaptive weight coefficient to correct the iteration results, including: Confirm that there are d types of parameters to be optimized in the convolutional neural network model. In the discrete d-dimensional space, the training network with different parameters is regarded as the position of a whale individual. If the current population is the i-th iteration, the best individual position in the whale group is recorded as X * (i)=[x1 * ,… x d * ], then for individual X j , which is at the current position X j (i) and the optimal individual position X * (i) The next position under influence is: where w is the adaptive weight; A and C are coefficient variables: where a is a variable taking values between 0 and 2, and r is a random number in the interval [0, 1]; In the bubble-net attacking stage, if the shrinking encircling strategy is adopted, the value of a is reduced and updated in the form of a = 2 - 2j / MaxIter, where MaxIter is the maximum number of iterations; the value range of A is [-a, a]; when |A| > 1, it represents the global search ability of the whale, and when |A| < 1, it represents the local search ability of the whale; If the spiral position update strategy is adopted, the individual position update formula is: where b is the logarithmic spiral shape constant; l is a random number in the interval [-1, 1]; Since there are the above two predation behaviors after discovering prey, the shrinking encircling or bubble-net attacking is selected according to the random probability p. The individual position update formula after introducing the random probability p is: where p is a random number in the interval [0, 1]; p1 is the probability correction coefficient. In the later stage of iteration, the value of p1 corresponds to the behavior type adopted by the whale individual, and the behavior type includes the shrinking encircling strategy and the spiral position update strategy; If A exceeds the range [-1,1], the distance data Dj ** (i) Random Update: Among them, X rand (i) is the random individual whale position in the i-th iteration group; By introducing the probability P of accepting inferior solutions to avoid falling into the local optimum, the calculation formula for the probability of accepting inferior solutions is: Among them, f(X j (i)) is individual X j The fitness at the i-th iteration, t is the temperature at the i-th iteration; When f(X j (i+1))>f(X j (i)) When accepting X j (i+1); when f(X j (i+1))<f(X j (i)) When the inferior position X is accepted with probability P j (i+1); Calculate the annealing probability P of each whale individual, and accept the inferior solution based on the annealing probability of the whale individual; Introduce the adaptive weight coefficient w into the population position update method: During the iteration process, sort the fitness values f(1)-f(d) of the whale individuals in ascending order, and then divide the fitness sequence into the first half and the second half, and calculate the average fitness values favg1 and favg2 of the first half and the second half respectively, where favg2 > favg1; If the fitness f(j) of any whale individual's position > favg2, it is determined that the individual position is searching for the optimal position, and the adaptive weight coefficient is taken in the interval [0.9, 1.1] to search for the optimal solution within the local range; If favg1 < f(j) < favg2, it is determined that the individual position is in a neither good nor bad position in the population, and w = 1 can be taken to search for the optimal solution in the original direction; If f(j) < favg1, it is determined that the individual is in a relatively poor position in the population, and w is randomly taken from the intervals [0.4, 0.7] and [1.3, 1.6] with a probability of 50%.
8. A power grid fault location system based on whale optimization, characterized in that: Including: An acquisition module for acquiring detection data of a plurality of power devices within a first time period, where the detection data includes eigenvalue of detection signals of multiple sensors; A preprocessing module for performing denoising and dimensionality reduction processing on the detection data to obtain sample data; A processing module for training a pre-constructed convolutional neural network based on the sample data by using an improved whale optimization method to obtain a fault location model; The fault location model is used to determine the power grid fault location according to the detection data of a plurality of power devices within a second time period; The first time period is before the second time period.
9. A terminal, characterized in that: Including: A memory for storing a power grid fault location program based on whale optimization; A processor for implementing the steps of the power grid fault location method based on whale optimization according to any one of claims 1-7 when executing the power grid fault location program based on whale optimization.
10. A computer-readable storage medium storing a computer program, characterized in that: The readable storage medium stores a power grid fault location program based on whale optimization, and when the power grid fault location program based on whale optimization is executed by a processor, the steps of the power grid fault location method based on whale optimization according to any one of claims 1-7 are implemented.
Citation Information
Cited By
Cable fault monitoring method and device and computer program product
CN121142235A