Industrial power distribution safety early warning method and system based on artificial intelligence
By introducing technical means such as comprehensive measurement values, nearest neighbor division and support vector machines into the industrial distribution safety warning method, the problem of data quality and category imbalance is solved, and the reliability and credibility of safety warning is improved.
Patent Information
- Application Number
- CN202411809334.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-10
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2044-12-10
AI Technical Summary
The existing industrial power distribution safety warning methods have poor data quality, susceptibility to noise data interference, and imbalance in data categories, resulting in insufficient recognition capabilities and reducing the reliability and credibility of safety warnings.
Introduce comprehensive measurement values to design noise data boundaries to remove noise data; divide data categories through nearest neighbors to perform synthetic data balance; use support vector machines and group intelligence algorithms to perform adaptive bidirectional mutations to build an industrial distribution safety detection model.
It improves the quality and reliability of industrial distribution data, enhances the processing capacity of different categories of data, improves the reliability and credibility of safety warnings, and ensures timely and accurate safety inspections.
Smart Images

Figure CN119624250A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of safety early warning, and specifically refers to an industrial power distribution safety early warning method and system based on artificial intelligence. Background Art
[0002] The industrial power distribution safety early warning method uses advanced artificial intelligence technology to process and analyze various data in the industrial power distribution process in real time, detect the safety status of industrial power distribution, issue safety early warning signals, and remind relevant personnel to take timely measures, which greatly improves the safety and reliability of industrial power distribution. However, the existing industrial power distribution safety early warning methods have the problems of poor quality of industrial power distribution data and susceptibility to interference from noise data, as well as unbalanced categories of industrial power distribution data, resulting in insufficient attention to a few categories and insufficient recognition ability, which reduces the reliability and credibility of industrial power distribution safety early warning; the existing industrial power distribution safety early warning methods have the problem that industrial power distribution situations are complex and diverse, and industrial power distribution data has complex nonlinear relationships, making it difficult to conduct comprehensive and accurate safety detection, resulting in the problem of failure to timely and accurately discover industrial power distribution safety hazards. Summary of the invention
[0003] In view of the above situation, in order to overcome the defects of the prior art, the present invention provides an industrial power distribution safety early warning method and system based on artificial intelligence. In view of the problems in the existing industrial power distribution safety early warning method, such as the poor quality of industrial power distribution data and susceptibility to interference from noise data, as well as the imbalance of industrial power distribution data categories, which lead to insufficient attention to minority categories and insufficient recognition ability, and reduce the reliability and credibility of industrial power distribution safety early warning, this scheme introduces a comprehensive metric value, designs the upper and lower bounds of the noise data boundary, screens and removes noise data, improves the quality and reliability of data, and eliminates the adverse effects of noise on data analysis and early warning; divides minority class boundary data, minority class safety data and majority class boundary data based on the nearest neighbor, and classifies and defines different categories of data; synthesizes data twice based on the number of required synthesis and the selection probability, and verifies the synthesized data after the first synthesis to balance the data categories. , which can more comprehensively learn and process different categories of industrial power distribution data, and improve the reliability and credibility of industrial power distribution safety warning; in view of the existing industrial power distribution safety warning methods, the industrial power distribution conditions are complex and diverse, and the industrial power distribution data has complex nonlinear relationships, which makes it difficult to conduct comprehensive and accurate safety detection, resulting in the failure to timely and accurately discover the safety hazards of industrial power distribution. This scheme designs random slope adjustment factors and dynamic reversal adjustment factors to perform adaptive bidirectional mutations to adapt to the complex and diverse industrial power distribution conditions; designs adaptive boundaries to adapt to the search needs of different stages; and combines progressive adjustment factors and convergence control coefficients to update the position, find the optimal parameters, and complete the construction of the industrial power distribution safety detection model to ensure that the obtained parameters can meet the accuracy requirements of industrial power distribution safety detection, accurately and timely perform industrial power distribution safety detection, and improve the effect and reliability of safety warnings.
[0004] The technical solution adopted by the present invention is as follows: The industrial power distribution safety early warning method based on artificial intelligence provided by the present invention comprises the following steps:
[0005] Step S1: data collection;
[0006] Step S2: industrial power distribution data processing;
[0007] Step S3: construct an industrial power distribution safety detection model;
[0008] Step S4: Real-time warning.
[0009] Furthermore, in step S1, the data collection is to collect historical industrial power distribution data; the historical industrial power distribution data includes power parameter data, equipment operation data, environmental data and safety status; the power parameter data includes voltage, current, power and frequency; the equipment operation data includes switch status, load status, maintenance records and operating time data; the environmental data includes temperature, humidity and air quality; the safety status includes normal, mild abnormality, moderate abnormality and severe abnormality, and the safety status is used as a data label.
[0010] Furthermore, in step S2, the industrial power distribution data processing specifically includes the following steps:
[0011] Step S21: preprocessing, data cleaning, data conversion and data normalization processing are performed on the collected industrial power distribution data; data cleaning includes processing abnormal values, duplicate values and missing values; data conversion is to convert the data into vector form; data normalization is to unify the data range based on the maximum and minimum normalization method;
[0012] Step S22: Remove noise data, construct an industrial power distribution data set based on the preprocessed data, and divide the industrial power distribution data set into a minority class data set and a majority class data set, and calculate the average value of all industrial power distribution data in the minority class data set , and then calculate the average value of each industrial power distribution data in the minority class data set The Euclidean distance and kernel density estimation between them are used, and the product of the Euclidean distance and the kernel density estimation is used as the comprehensive metric value of each industrial power distribution data. The comprehensive metric values are sorted in ascending order and selected. and The comprehensive metric value at is used as the first reference metric c 1 and the second reference metric c 2 , the upper bound ub and lower bound 1b of the noise data boundary are set based on the reference metric, the industrial power distribution data with comprehensive metric values greater than the upper bound ub or less than the lower bound lb in the minority class data set are taken as noise data, and the noise data is deleted from the minority class data set. The formula used is as follows:
[0013] ;
[0014] ;
[0015] Where r is the control factor;
[0016] Step S23: partition, calculate the k nearest neighbors of each industrial power distribution data in the minority class data set in the industrial power distribution data set; if the k nearest neighbors are not all data in the minority class data set, then mark the corresponding industrial power distribution data in the minority class data set as minority class boundary data; otherwise, mark the corresponding industrial power distribution data in the minority class data set as minority class safety data; then calculate the Euclidean distance between each industrial power distribution data in the minority class data set and its k nearest neighbors, and the one with the smallest Euclidean distance d min The nearest neighbor belonging to the majority class data set is marked as the majority class boundary data, and d min as a specific measurement value of the majority class boundary data; constructing a first reference data set, a second reference data set and a detection data set based on the minority class boundary data, the minority class safety data and the majority class boundary data respectively;
[0017] Step S24: synthesizing data for the first time, including the following steps:
[0018] Step S241: Calculate the first required synthesis quantity, the formula used is as follows:
[0019] ;
[0020] In the formula, H 1 is the number of synthesized items required for the first time, N min and N max are the number of industrial power distribution data in the minority class dataset and the majority class dataset, respectively;
[0021] Step S242: Calculate the selection probability using the following formula:
[0022] ;
[0023] In the formula, x v is the vth minority class boundary data in the first reference dataset, g v is x v The selection probability of is, v is the industrial power distribution data index, a 1 and a 2 are the first adjustment factor and the second adjustment factor, d v is x v With the average The Euclidean distance between is x v Kernel density estimation of ;
[0024] Step S243: Synthesize data by randomly extracting data from the first reference data set based on the selection probability, and then Perform the first synthesis of data until the number of synthesized data is equal to H 1, and construct a synthetic dataset based on the first synthetic data and the industrial power distribution dataset. The formula used is as follows:
[0025] ;
[0026] In the formula, is the wth data synthesized for the first time, rand(0,1) generates a random number between (0,1), x abs is the extracted data, w is the synthetic data index;
[0027] Step S244: Synthetic data verification, calculate the k nearest neighbors of each majority class boundary data in the detection data set in the synthetic data set, if the k nearest neighbors contain synthetic data , then calculate the majority class boundary data and synthetic data The Euclidean distance between ,like , then the synthetic data Delete from the synthetic data set to obtain a qualified data set, and obtain the number of data in the qualified data set A;
[0028] Step S25: synthesize data for the second time and calculate the number of synthesized data H required for the second time 2 =H 1 -A, and calculate the selection probability of each minority class safety data in the second reference dataset, based on the selection probability, randomly extract data from the second reference dataset, based on the extracted data and the average value Perform the second synthesis of data until the number of synthesized data is equal to H 2 , and construct training and testing datasets based on the second synthetic data and qualified datasets.
[0029] Further, in step S3, the construction of the industrial power distribution safety detection model is to construct a support vector machine, and perform optimal parameter search for the penalty parameters and kernel function parameters of the support vector machine based on a swarm intelligence algorithm, specifically including the following steps:
[0030] Step S31: Initialization, establish a parameter search space for the penalty parameter and the kernel function parameter, randomly initialize the individual position in the parameter search space, use the individual position as the representative of the model parameter, use Python to import the sklearn library to call the SVM function based on the model parameters, train the industrial power distribution safety detection model based on the training data set, and use the hinge loss function of the industrial power distribution safety detection model established based on the model parameters for the test data set as the fitness value of the corresponding individual position;
[0031] Step S32: Adaptive bidirectional mutation, including the following steps:
[0032] Step S321: designing a random slope adjustment factor and a dynamic reversal adjustment factor, the formula used is as follows:
[0033] ;
[0034] ;
[0035] In the formula, and are the random slope adjustment factor and dynamic reversal adjustment factor during the t-th search, is the dynamic inversion adjustment factor at the t-1th search, tan(·) is the tangent function, Q is the number of individuals, t is the search index, and ε is a random number;
[0036] Step S322: mutation, the formula used is as follows:
[0037] ;
[0038] In the formula, and are the original position and the position after mutation of the qth individual in the tth search, is the fitness value of the position of the qth individual in the tth search, is the average fitness value of all individual positions during the t-th search, and q is the individual index;
[0039] Step S33: Design an adaptive boundary, the formula used is as follows:
[0040] ;
[0041] ;
[0042] In the formula, and are the lower and upper bounds of the parameter search space for the t-th search, max{·} and min{·} are the maximum and minimum functions, respectively. max is the maximum number of searches, is the best individual position after mutation in the t-th search, and are the lower and upper initial values of the parameter search space respectively;
[0043] Step S34: Position update. Before the update, a random number (0, 1) is randomly generated for each individual, based on the adaptive boundary and random number, combined with the gradual adjustment factor and convergence control coefficient To update the individual position, the formula used is as follows:
[0044] ;
[0045] In the formula, is the position of the qth individual in the t+1th search, is the random number of the qth individual in the tth search, and are the asymptotic adjustment factor and convergence control coefficient during the t-th search, and are the position correction factor and the attenuation exponent respectively;
[0046] Step S35: Determine the optimal parameters, pre-set the fitness threshold, update the fitness value of the individual position, when the fitness value of the best individual position is less than the fitness threshold, the parameters corresponding to the best individual position are the optimal parameters, and the SVM function is called based on the optimal parameters to build an industrial power distribution safety detection model; otherwise, if the maximum number of searches is reached, go to step S31 to reinitialize; otherwise, add 1 to the number of searches and return to step S32 to continue searching.
[0047] Furthermore, in step S4, the real-time warning is to collect real-time industrial power distribution data, which includes power parameter data, equipment operation data and environmental data. After pre-processing, the data is input into the industrial power distribution safety detection model constructed based on the optimal parameters for processing. Based on the output data label, the real-time safety status of the industrial power distribution is obtained, and a safety warning signal is issued.
[0048] The artificial intelligence-based industrial power distribution safety early warning system provided by the present invention includes a data acquisition module, an industrial power distribution data processing module, an industrial power distribution safety detection model building module and a real-time early warning module;
[0049] The data acquisition module collects historical industrial power distribution data and sends the data to the industrial power distribution data processing module;
[0050] The industrial power distribution data processing module introduces a comprehensive metric value, designs the upper and lower bounds of the noise data boundary, screens and removes noise data, divides minority class boundary data, minority class safety data and majority class boundary data based on the nearest neighbor, synthesizes data twice based on the required number of synthesized and the selection probability, verifies the synthesized data after the first synthesis, and sends the data to the module for building an industrial power distribution safety detection model;
[0051] The module for constructing the industrial power distribution safety detection model designs a random slope adjustment factor and a dynamic reversal adjustment factor, performs adaptive bidirectional mutation, designs an adaptive boundary, and combines the progressive adjustment factor and the convergence control coefficient to perform position update, find the optimal parameters, complete the construction of the industrial power distribution safety detection model, and send the data to the real-time warning module;
[0052] The real-time warning module inputs real-time industrial power distribution data into an industrial power distribution safety detection model constructed based on optimal parameters for processing, obtains the real-time safety status of industrial power distribution, and issues a safety warning signal.
[0053] The beneficial effects achieved by the present invention using the above scheme are as follows:
[0054] (1) In view of the problems in the existing industrial power distribution safety early warning methods, such as poor quality of industrial power distribution data and susceptibility to interference from noise data, as well as imbalanced categories of industrial power distribution data, which lead to insufficient attention to minority categories and insufficient recognition ability, and reduce the reliability and credibility of industrial power distribution safety early warning, this scheme introduces a comprehensive metric value, designs the upper and lower bounds of the noise data boundary, screens and removes noise data, comprehensively evaluates the characteristics and quality of industrial power distribution data, clarifies the scope of noise data, cleans up interfering data, improves the quality and reliability of industrial power distribution data, and eliminates the adverse effects of noise on industrial power distribution data analysis and early warning; based on the nearest neighbor, the minority class boundary data, minority class safety data and majority class boundary data are divided, and different categories of data are classified and defined; based on the number of required synthesis and the selection probability, the data is synthesized twice, and the synthetic data is verified after the first synthesis, the number of minority class data is increased, the data categories are balanced, and the quality and effectiveness of the synthesized data are ensured. This scheme can more comprehensively learn and process different categories of industrial power distribution data, and improve the reliability and credibility of industrial power distribution safety early warning.
[0055] (2) In view of the fact that the existing industrial power distribution safety early warning methods have complex and diverse industrial power distribution conditions and complex nonlinear relationships in the data, it is difficult to conduct comprehensive and accurate safety detection, which leads to the problem that the safety hazards of industrial power distribution cannot be discovered in a timely and accurate manner. This scheme adopts support vector machines for detection, uses individual positions as representatives of model parameters, designs random slope adjustment factors and dynamic reversal adjustment factors, and performs adaptive bidirectional mutations. It can explore different parameter areas more flexibly to adapt to the complex and diverse industrial power distribution conditions; designs adaptive boundaries to adapt to the search needs at different stages to avoid the search range being too broad or narrow; and combines the progressive adjustment factor and the convergence control coefficient to update the position, find the optimal parameters, and complete the construction of the industrial power distribution safety detection model. It can move more effectively in the search space, ensure that the obtained parameters can meet the accuracy requirements of industrial power distribution safety detection, and accurately and timely perform industrial power distribution safety detection, thereby improving the effect and reliability of safety early warning. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] Figure 1 A schematic diagram of the process of the artificial intelligence-based industrial power distribution safety early warning method provided by the present invention;
[0057] Figure 2A schematic diagram of an industrial power distribution safety early warning system based on artificial intelligence provided by the present invention;
[0058] Figure 3 is a schematic flow chart of step S2;
[0059] Figure 4 It is a schematic diagram of the process of step S3.
[0060] The accompanying drawings are used to provide further understanding of the present invention and constitute a part of the specification. They are used to explain the present invention together with the embodiments of the present invention and do not constitute a limitation of the present invention. DETAILED DESCRIPTION
[0061] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the 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.
[0062] In the description of the present invention, it should be understood that terms such as “upper”, “lower”, “front”, “back”, “left”, “right”, “top”, “bottom”, “inside” and “outside” indicating directions or positional relationships are based on the directions or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific direction, be constructed and operated in a specific direction, and therefore should not be understood as limiting the present invention.
[0063] Example 1, see Figure 1 The present invention provides an artificial intelligence-based industrial power distribution safety early warning method, which includes the following steps:
[0064] Step S1: data collection, collecting historical industrial power distribution data;
[0065] Step S2: Processing industrial power distribution data, introducing comprehensive metrics, designing the upper and lower bounds of noise data boundaries, screening and removing noise data, dividing minority class boundary data, minority class safety data, and majority class boundary data based on the nearest neighbor, synthesizing data twice based on the number of required synthesis and the selection probability, and verifying the synthesized data after the first synthesis;
[0066] Step S3: construct an industrial power distribution safety detection model, design a random slope adjustment factor and a dynamic reversal adjustment factor, perform adaptive bidirectional mutation, design an adaptive boundary, and combine the progressive adjustment factor and the convergence control coefficient to perform position update, find the optimal parameters, and complete the construction of the industrial power distribution safety detection model;
[0067] Step S4: Real-time warning: input the real-time industrial power distribution data into the industrial power distribution safety detection model constructed based on the optimal parameters for processing, obtain the real-time safety status of the industrial power distribution, and issue a safety warning signal.
[0068] Example 2, see Figure 1 This embodiment is based on the above embodiment. In step S1, the historical industrial power distribution data includes power parameter data, equipment operation data, environmental data and safety status; the power parameter data includes voltage, current, power and frequency; the equipment operation data includes switch status, load status, maintenance records and operating time data; the environmental data includes temperature, humidity and air quality; the safety status includes normal, slight abnormality, moderate abnormality and severe abnormality, and the safety status is used as a data label.
[0069] Example 3, see Figure 1 and Figure 3 This embodiment is based on the above embodiment. In step S2, the industrial power distribution data processing specifically includes the following steps:
[0070] Step S21: preprocessing, data cleaning, data conversion and data normalization processing are performed on the collected industrial power distribution data; data cleaning includes processing abnormal values, duplicate values and missing values; data conversion is to convert the data into vector form; data normalization is to unify the data range based on the maximum and minimum normalization method;
[0071] Step S22: Remove noise data, construct an industrial power distribution data set based on the preprocessed data, and divide the industrial power distribution data set into a minority class data set and a majority class data set, and calculate the average value of all industrial power distribution data in the minority class data set , and then calculate the average value of each industrial power distribution data in the minority class data set Euclidean distance between and kernel density estimation , the product of Euclidean distance and kernel density estimation is used as the comprehensive metric value of each industrial power distribution data, the comprehensive metric values are sorted in ascending order, and the selection and The comprehensive metric value at is used as the first reference metric c 1 and the second reference metric c 2 , the upper bound ub and lower bound 1b of the noise data boundary are set based on the reference metric, the industrial power distribution data with comprehensive metric values greater than the upper bound ub or less than the lower bound lb in the minority class data set are taken as noise data, and the noise data is deleted from the minority class data set. The formula used is as follows:
[0072] ;
[0073] ;
[0074] Where r is the control factor in the range of (1, 3), x i and x j is the i-th and j-th industrial power distribution data in the minority class dataset, is x i Kernel density estimation of , i and j are the industrial power distribution data indexes, K(·) is the kernel function, h is the bandwidth, N min is the number of industrial power distribution data in the minority class dataset;
[0075] Step S23: partition, calculate the k nearest neighbors of each industrial power distribution data in the minority class data set in the industrial power distribution data set; if the k nearest neighbors are not all data in the minority class data set, then mark the corresponding industrial power distribution data in the minority class data set as minority class boundary data; otherwise, mark the corresponding industrial power distribution data in the minority class data set as minority class safety data; then calculate the Euclidean distance between each industrial power distribution data in the minority class data set and its k nearest neighbors, and the one with the smallest Euclidean distance d min The nearest neighbor belonging to the majority class data set is marked as the majority class boundary data, and d min as a specific measurement value of the majority class boundary data; constructing a first reference data set, a second reference data set and a detection data set based on the minority class boundary data, the minority class safety data and the majority class boundary data respectively;
[0076] Step S24: synthesizing data for the first time, including the following steps:
[0077] Step S241: Calculate the first required synthesis quantity, the formula used is as follows:
[0078] ;
[0079] In the formula, H 1 is the number of synthesized items required for the first time, N min and N max are the number of industrial power distribution data in the minority class dataset and the majority class dataset, respectively;
[0080] Step S242: Calculate the selection probability using the following formula:
[0081] ;
[0082] In the formula, x v is the vth minority class boundary data in the first reference dataset, g v is x v The selection probability of is, v is the industrial power distribution data index, a 1 and a 2 are the first adjustment factor and the second adjustment factor, d v is xv With the average The Euclidean distance between is x v Kernel density estimation of ;
[0083] Step S243: Synthesize data by randomly extracting data from the first reference data set based on the selection probability, and then Perform the first synthesis of data until the number of synthesized data is equal to H 1 , and construct a synthetic dataset based on the first synthetic data and the industrial power distribution dataset. The formula used is as follows:
[0084] ;
[0085] In the formula, is the wth data synthesized for the first time, rand(0,1) generates a random number between (0,1), x abs is the extracted data, w is the synthetic data index;
[0086] Step S244: Synthetic data verification, calculate the k nearest neighbors of each majority class boundary data in the detection data set in the synthetic data set, if the k nearest neighbors contain synthetic data , then calculate the majority class boundary data and synthetic data The Euclidean distance between ,like , then the synthetic data Delete from the synthetic data set to obtain a qualified data set, and obtain the number of data in the qualified data set A;
[0087] Step S25: synthesize data for the second time and calculate the number of synthesized data H required for the second time 2 =H 1 -A, and calculate the selection probability of each minority class safety data in the second reference dataset, based on the selection probability, randomly extract data from the second reference dataset, based on the extracted data and the average value Perform the second synthesis of data until the number of synthesized data is equal to H 2 , and construct training and testing datasets based on the second synthetic data and qualified datasets.
[0088] By performing the above operations, in view of the problems in the existing industrial power distribution safety early warning methods, such as poor quality of industrial power distribution data and susceptibility to interference from noise data, as well as imbalanced categories of industrial power distribution data, which lead to insufficient attention to minority categories, insufficient recognition ability, and reduced reliability and credibility of industrial power distribution safety early warning, this scheme introduces a comprehensive metric value, designs the upper and lower bounds of the noise data boundary, screens and removes noise data, comprehensively evaluates the characteristics and quality of industrial power distribution data, clarifies the scope of noise data, cleans up interfering data, improves the quality and reliability of industrial power distribution data, and eliminates the adverse effects of noise on industrial power distribution data analysis and early warning; divides minority class boundary data, minority class safety data, and majority class boundary data based on the nearest neighbor, and classifies and defines different categories of data; synthesizes data twice based on the number of required synthesis and the selection probability, and verifies the synthesized data after the first synthesis, increases the number of minority class data, balances data categories, ensures the quality and effectiveness of synthesized data, and can more comprehensively learn and process different categories of industrial power distribution data, and improve the reliability and credibility of industrial power distribution safety early warning.
[0089] Example 4, see Figure 1 and Figure 4 This embodiment is based on the above embodiment. In step S3, the construction of the industrial power distribution safety detection model is to construct a support vector machine, and perform optimal parameter search for the penalty parameters and kernel function parameters of the support vector machine based on the swarm intelligence algorithm, which specifically includes the following steps:
[0090] Step S31: Initialization, establish a parameter search space for the penalty parameter and the kernel function parameter, randomly initialize the individual position in the parameter search space, use the individual position as the representative of the model parameter, use Python to import the sklearn library to call the SVM function based on the model parameters, train the industrial power distribution safety detection model based on the training data set, and use the hinge loss function of the industrial power distribution safety detection model established based on the model parameters for the test data set as the fitness value of the corresponding individual position;
[0091] Step S32: Adaptive bidirectional mutation, including the following steps:
[0092] Step S321: designing a random slope adjustment factor and a dynamic reversal adjustment factor, the formula used is as follows:
[0093] ;
[0094] ;
[0095] In the formula, and are the random slope adjustment factor and dynamic reversal adjustment factor during the t-th search, is the dynamic inversion adjustment factor at the t-1th search, tan(·) is the tangent function, Q is the number of individuals, t is the search index, and ε is a random number in the range [0, 1];
[0096] Step S322: mutation. If the fitness of the individual position is lower than the average fitness value, a random slope adjustment factor is used for forward mutation; if the fitness of the individual position is greater than or equal to the average fitness value, a dynamic inversion adjustment factor is used for reverse mutation. The formula used is as follows:
[0097] ;
[0098] In the formula, and are the original position and the position after mutation of the qth individual in the tth search, is the fitness value of the position of the qth individual in the tth search, is the average fitness value of all individual positions during the t-th search, and q is the individual index;
[0099] Step S33: Design an adaptive boundary, the formula used is as follows:
[0100] ;
[0101] ;
[0102] In the formula, and are the lower and upper bounds of the parameter search space for the t-th search, max{·} and min{·} are the maximum and minimum functions, respectively. max is the maximum number of searches, is the best individual position after mutation in the t-th search. The best individual position is the individual position with the smallest fitness value. and are the lower and upper initial values of the parameter search space respectively;
[0103] Step S34: Position update. Before the update, a random number (0, 1) is randomly generated for each individual, based on the adaptive boundary and random number, combined with the gradual adjustment factor and convergence control coefficient To update the individual position, the formula used is as follows:
[0104] ;
[0105] In the formula, is the position of the qth individual in the t+1th search, is the random number of the qth individual in the tth search, and are the asymptotic adjustment factor and convergence control coefficient during the t-th search, and are the position correction factor and attenuation exponent in the range of (0, 1) respectively;
[0106] Step S35: Determine the optimal parameters, pre-set the fitness threshold, update the fitness value of the individual position, when the fitness value of the best individual position is less than the fitness threshold, the parameters corresponding to the best individual position are the optimal parameters, and the SVM function is called based on the optimal parameters to build an industrial power distribution safety detection model; otherwise, if the maximum number of searches is reached, go to step S31 to reinitialize; otherwise, add 1 to the number of searches and return to step S32 to continue searching.
[0107] By performing the above operations, the existing industrial power distribution safety early warning methods have the problem that the industrial power distribution conditions are complex and diverse, the data has complex nonlinear relationships, and it is difficult to conduct comprehensive and accurate safety detection, resulting in the problem that the safety hazards of industrial power distribution cannot be discovered in a timely and accurate manner. This scheme adopts support vector machines for detection, uses individual positions as representatives of model parameters, designs random slope adjustment factors and dynamic reversal adjustment factors, and performs adaptive bidirectional mutations. It can explore different parameter areas more flexibly to adapt to the complex and diverse industrial power distribution conditions; designs adaptive boundaries to adapt to the search needs of different stages to avoid the search range being too broad or narrow; and combines the progressive adjustment factor and the convergence control coefficient to update the position, find the optimal parameters, and complete the construction of the industrial power distribution safety detection model. It can move more effectively in the search space, ensure that the obtained parameters can meet the accuracy requirements of industrial power distribution safety detection, accurately and timely perform industrial power distribution safety detection, and improve the effect and reliability of safety early warning.
[0108] Example 5, see Figure 1 This embodiment is based on the above embodiment. In step S4, the real-time warning is to collect real-time industrial power distribution data, which includes power parameter data, equipment operation data and environmental data. After preprocessing, the data is input into the industrial power distribution safety detection model constructed based on the optimal parameters for processing. Based on the output data label, the real-time safety status of the industrial power distribution is obtained, and a safety warning signal is issued.
[0109] Example 6, see Figure 2 , this embodiment is based on the above embodiment, the artificial intelligence-based industrial power distribution safety early warning system provided by the present invention includes a data acquisition module, an industrial power distribution data processing module, an industrial power distribution safety detection model building module and a real-time early warning module;
[0110] The data acquisition module collects historical industrial power distribution data and sends the data to the industrial power distribution data processing module;
[0111] The industrial power distribution data processing module introduces a comprehensive metric value, designs the upper and lower bounds of the noise data boundary, screens and removes noise data, divides minority class boundary data, minority class safety data and majority class boundary data based on the nearest neighbor, synthesizes data twice based on the required number of synthesized and the selection probability, verifies the synthesized data after the first synthesis, and sends the data to the module for building an industrial power distribution safety detection model;
[0112] The module for constructing the industrial power distribution safety detection model designs a random slope adjustment factor and a dynamic reversal adjustment factor, performs adaptive bidirectional mutation, designs an adaptive boundary, and combines the progressive adjustment factor and the convergence control coefficient to perform position update, find the optimal parameters, complete the construction of the industrial power distribution safety detection model, and send the data to the real-time warning module;
[0113] The real-time warning module inputs real-time industrial power distribution data into an industrial power distribution safety detection model constructed based on optimal parameters for processing, obtains the real-time safety status of industrial power distribution, and issues a safety warning signal.
[0114] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device.
[0115] While the embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that many changes, modifications, substitutions and variations can be made to the embodiments without departing from the principles and spirit of the invention.
[0116] The present invention and its embodiments are described above, and such description is not restrictive. The drawings show only one embodiment of the present invention, and the actual structure is not limited thereto. In short, if ordinary technicians in the field are inspired by it, without departing from the purpose of the invention, they can design a structure and embodiment similar to the technical solution without creativity, which should belong to the protection scope of the present invention.
Claims
1. An industrial power distribution safety early warning method based on artificial intelligence, characterized by: The method comprises the following steps: Step S1: data collection, collecting historical industrial power distribution data; Step S2: industrial power distribution data processing; Step S3: construct an industrial power distribution safety detection model; Step S4: real-time warning, inputting the real-time industrial power distribution data into the industrial power distribution safety detection model constructed based on the optimal parameters for processing, obtaining the real-time safety status of the industrial power distribution, and issuing a safety warning signal; Step S2 includes step S22: removing noise data, constructing an industrial power distribution data set based on the preprocessed data, and dividing the industrial power distribution data set into a minority class data set and a majority class data set, and calculating the average value of all industrial power distribution data in the minority class data set. , and then calculate the average value of each industrial power distribution data in the minority class data set The Euclidean distance and kernel density estimation between them are used, and the product of the Euclidean distance and the kernel density estimation is used as the comprehensive metric value of each industrial power distribution data. The comprehensive metric values are sorted in ascending order and selected. and The comprehensive metric value at the position is used as the first reference metric c1 and the second reference metric c2. The upper bound ub and the lower bound 1b of the noise data boundary are set based on the reference metric. The industrial power distribution data with a comprehensive metric value greater than the upper bound ub or less than the lower bound lb in the minority class data set is used as noise data, and the noise data is deleted from the minority class data set. The formula used is as follows: ; ; Where r is the control factor.
2. The industrial power distribution safety early warning method based on artificial intelligence according to claim 1 is characterized in that: In step S3, the construction of the industrial power distribution safety detection model is to construct a support vector machine, and perform optimal parameter search for the penalty parameters and kernel function parameters of the support vector machine based on a swarm intelligence algorithm, specifically including the following steps: Step S31: Initialization, establish a parameter search space for the penalty parameter and the kernel function parameter, randomly initialize the individual position in the parameter search space, use the individual position as the representative of the model parameter, use Python to import the sklearn library to call the SVM function based on the model parameters, train the industrial power distribution safety detection model based on the training data set, and use the hinge loss function of the industrial power distribution safety detection model established based on the model parameters for the test data set as the fitness value of the corresponding individual position; Step S32: Adaptive bidirectional mutation; Step S33: Design an adaptive boundary, the formula used is as follows: ; ; In the formula, and are the lower and upper bounds of the parameter search space for the t-th search, max{·} and min{·} are the maximum and minimum functions, respectively. max is the maximum number of searches, is the best individual position after mutation in the t-th search, and are the lower and upper bound initial values of the parameter search space, respectively, and t is the search count index; Step S34: Position update. Before the update, a random number (0, 1) is randomly generated for each individual, based on the adaptive boundary and random number, combined with the gradual adjustment factor and convergence control coefficient To update the individual position, the formula used is as follows: ; In the formula, is the position of the qth individual in the t+1th search, is the random number of the qth individual in the tth search, and are the asymptotic adjustment factor and convergence control coefficient during the t-th search, and are the position correction factor and the attenuation exponent, respectively. is the position of the qth individual after mutation in the tth search; Step S35: Determine the optimal parameters, pre-set the fitness threshold, update the fitness value of the individual position, when the fitness value of the best individual position is less than the fitness threshold, the parameters corresponding to the best individual position are the optimal parameters, and the SVM function is called based on the optimal parameters to build an industrial power distribution safety detection model; otherwise, if the maximum number of searches is reached, go to step S31 to reinitialize; otherwise, add 1 to the number of searches and return to step S32 to continue searching.
3. The industrial power distribution safety early warning method based on artificial intelligence according to claim 2 is characterized in that: In step S32, the adaptive bidirectional mutation specifically includes the following steps: Step S321: designing a random slope adjustment factor and a dynamic reversal adjustment factor, the formula used is as follows: ; ; In the formula, and are the random slope adjustment factor and dynamic reversal adjustment factor during the t-th search, is the dynamic inversion adjustment factor at the t-1th search, tan(·) is the tangent function, Q is the number of individuals, t is the search index, and ε is a random number; Step S322: mutation, the formula used is as follows: ; In the formula, and are the original position and the position after mutation of the qth individual in the tth search, is the fitness value of the position of the qth individual in the tth search, is the average fitness value of all individual positions during the t-th search, and q is the individual index.
4. The industrial power distribution safety early warning method based on artificial intelligence according to claim 1 is characterized in that: In step S2, the industrial power distribution data processing specifically includes the following steps: Step S21: preprocessing, data cleaning, data conversion and data normalization processing are performed on the collected industrial power distribution data; data cleaning includes processing abnormal values, duplicate values and missing values; data conversion is to convert the data into vector form; data normalization is to unify the data range based on the maximum and minimum normalization method; Step S22: removing noise data; Step S23: partition, calculate the k nearest neighbors of each industrial power distribution data in the minority class data set in the industrial power distribution data set; if the k nearest neighbors are not all data in the minority class data set, then mark the corresponding industrial power distribution data in the minority class data set as minority class boundary data; otherwise, mark the corresponding industrial power distribution data in the minority class data set as minority class safety data; then calculate the Euclidean distance between each industrial power distribution data in the minority class data set and its k nearest neighbors, and the one with the smallest Euclidean distance d min The nearest neighbor belonging to the majority class data set is marked as the majority class boundary data, and d min as a specific measurement value of the majority class boundary data; constructing a first reference data set, a second reference data set and a detection data set based on the minority class boundary data, the minority class safety data and the majority class boundary data respectively; Step S24: synthesizing data for the first time; Step S25: synthesize data for the second time, calculate the number of synthesized data H2 = H1-A, and calculate the selection probability of each minority class safety data in the second reference data set. Based on the selection probability, randomly extract data from the second reference data set, and based on the extracted data and the average value Perform the second synthesis of data until the amount of synthesized data is equal to H2, and build the training data set and the test data set based on the second synthesis data and the qualified data set; where H1 is the amount of data to be synthesized for the first time, and A is the amount of data in the qualified data set.
5. The artificial intelligence-based industrial power distribution safety early warning method according to claim 4 is characterized in that: In step S24, the first synthesis of data specifically includes the following steps: Step S241: Calculate the first required synthesis quantity, the formula used is as follows: ; In the formula, H1 is the number of synthesized items required for the first time, N min and N max are the number of industrial power distribution data in the minority class dataset and the majority class dataset, respectively; Step S242: Calculate the selection probability, using the following formula: ; In the formula, x v is the vth minority class boundary data in the first reference dataset, g v is x v The selection probability of , v is the industrial power distribution data index, a1 and a2 are the first adjustment factor and the second adjustment factor, respectively, d v is x v With the average The Euclidean distance between is x v Kernel density estimation of ; Step S243: Synthesize data by randomly extracting data from the first reference data set based on the selection probability, and then The first synthetic data is performed until the number of synthetic data is equal to H1, and a synthetic data set is constructed based on the first synthetic data and the industrial power distribution data set. The formula used is as follows: ; In the formula, is the wth data synthesized for the first time, rand(0,1) generates a random number between (0,1), x abs is the extracted data, w is the synthetic data index; Step S244: Synthetic data verification, calculate the k nearest neighbors of each majority class boundary data in the detection data set in the synthetic data set, if the k nearest neighbors contain synthetic data , then calculate the majority class boundary data and synthetic data The Euclidean distance between ,like , then the synthetic data Delete from the synthetic data set to obtain a qualified data set, and obtain the number of data A in the qualified data set.
6. The industrial power distribution safety early warning method based on artificial intelligence according to claim 1 is characterized in that: In step S1, the data collection is to collect historical industrial power distribution data; the historical industrial power distribution data includes power parameter data, equipment operation data, environmental data and safety status; the power parameter data includes voltage, current, power and frequency; the equipment operation data includes switch status, load status, maintenance records and operating time data; the environmental data includes temperature, humidity and air quality; the safety status includes normal, slight abnormality, moderate abnormality and severe abnormality, and the safety status is used as a data label.
7. The artificial intelligence-based industrial power distribution safety early warning method according to claim 1 is characterized in that: In step S4, the real-time warning is to collect real-time industrial power distribution data, which includes power parameter data, equipment operation data and environmental data. After pre-processing, the data is input into the industrial power distribution safety detection model constructed based on the optimal parameters for processing. Based on the output data label, the real-time safety status of the industrial power distribution is obtained, and a safety warning signal is issued.
8. An artificial intelligence-based industrial power distribution safety early warning system, used to implement the artificial intelligence-based industrial power distribution safety early warning method as described in any one of claims 1 to 7, characterized in that: It includes data acquisition module, industrial power distribution data processing module, industrial power distribution safety detection model building module and real-time warning module; The data acquisition module collects historical industrial power distribution data and sends the data to the industrial power distribution data processing module; The industrial power distribution data processing module introduces a comprehensive metric value, designs the upper and lower bounds of the noise data boundary, screens and removes noise data, divides minority class boundary data, minority class safety data and majority class boundary data based on the nearest neighbor, synthesizes data twice based on the required number of synthesized and the selection probability, verifies the synthesized data after the first synthesis, and sends the data to the module for building an industrial power distribution safety detection model; The module for constructing the industrial power distribution safety detection model designs a random slope adjustment factor and a dynamic reversal adjustment factor, performs adaptive bidirectional mutation, designs an adaptive boundary, and combines the progressive adjustment factor and the convergence control coefficient to perform position update, find the optimal parameters, complete the construction of the industrial power distribution safety detection model, and send the data to the real-time warning module; The real-time warning module inputs real-time industrial power distribution data into an industrial power distribution safety detection model constructed based on optimal parameters for processing, obtains the real-time safety status of industrial power distribution, and issues a safety warning signal.
Citation Information
Patent Citations
PLC adaptive control method and system based on artificial intelligence
CN117348419A
Circuit fault monitoring method and system based on artificial intelligence
CN117491850A
Customer service risk assessment method and system based on bidirectional feedback mechanism
CN118114985A
Electric power construction safety early warning method based on heterogeneous data
CN118469303A
Flood disaster early warning method and system based on machine learning
CN118643957A