A method, apparatus, electronic device, and storage medium for predicting icing conditions.
By combining incremental learning and extreme learning machine architectures and using the gray wolf optimization algorithm to adjust the kernel matrix parameters, the problems of long training time and resource waste in icing prediction models are solved, and accurate prediction of icing conditions is achieved even with a small number of new samples.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-27
- Publication Date
- 2026-04-03
AI Technical Summary
Existing technologies require a long time to collect samples and consume a lot of computing resources when training icing prediction models, resulting in insufficient model accuracy and frequent training that wastes computing resources.
The prediction model is trained using incremental learning. By utilizing historical icing data and environmental data, the kernel matrix parameters are adjusted through an extreme learning machine structure and the gray wolf optimization algorithm to fine-tune the model to adapt to new samples and reduce computational resource consumption.
With a small sample size, an accurate icing prediction model can be quickly trained, improving the accuracy of icing prediction and reducing the waste of computing resources.
Smart Images

Figure CN119312971B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of power transmission line anti-icing technology, specifically to a method, device, electronic equipment, and storage medium for predicting icing conditions. Background Technology
[0002] Icing is a widespread natural phenomenon. However, for power transmission lines, severe icing can lead to faults and even catastrophic accidents such as large-scale power outages. Currently, with more and more AC and DC ultra-high voltage transmission lines crossing icing-prone areas, icing has become one of the main factors restricting the safe and stable operation of the power system. Therefore, how to accurately predict the icing situation of transmission lines has become one of the urgent technical problems to be solved.
[0003] Generally, existing technologies typically use historical icing data to train a prediction model. After the prediction model is trained, it predicts the icing condition of transmission lines based on data such as temperature, humidity, and wind direction, and then executes corresponding de-icing strategies based on the predicted icing condition.
[0004] However, during the use of the model, the accuracy of the trained prediction model may be insufficient. The usual approach is to acquire more training samples and retrain the model to obtain a more accurate prediction model. However, in practical applications, the collection of new data may be limited by factors such as cost, time, and availability, resulting in a limited number of new samples. Furthermore, retraining the entire model consumes significant computational resources, and frequent training of the prediction model leads to a waste of these resources. Summary of the Invention
[0005] In view of this, the present invention aims to provide a method, apparatus, electronic device and storage medium for predicting icing conditions. By using a prediction model trained by incremental learning, it solves the problems in the prior art that require a long time to collect samples and a large amount of computing resources to train an accurate prediction model when training a new model.
[0006] This invention provides a method for predicting icing conditions on power transmission lines, the method comprising:
[0007] Determine the historical icing data and current environmental data of the target route as input data;
[0008] The input data is fed into a pre-trained prediction model to obtain the prediction result output by the prediction model, which is used as the icing data at the current moment; wherein, the prediction model is pre-trained using an incremental learning method based on historical icing data and historical environmental data;
[0009] Based on the icing data at the current moment, the icing status of the target line is determined.
[0010] In one embodiment, the prediction model is trained in the following manner:
[0011] The confidence level of the prediction model for the input data is determined. When the confidence level is lower than a preset confidence threshold, the input data is determined to be a target sample, and the label of the target sample is determined.
[0012] Obtain a prediction model that has been pre-trained based on training samples and their annotations, and adjust the parameters of the prediction model based on the target samples and their annotations.
[0013] In one embodiment, the prediction model pre-trained based on training samples and their annotations is trained in the following manner:
[0014] For each historical moment, based on the historical icing data of the sample line and the environmental data of the historical icing data, the environmental data and icing data of the sample line at that historical moment are determined, and the training samples and their labels are determined based on the environmental data and icing data of the sample line at that historical moment.
[0015] Based on each training sample and its label, the prediction model to be trained is trained to obtain the trained prediction model.
[0016] In one embodiment, the structure of the prediction model is an extreme learning machine structure;
[0017] Based on the training samples and their annotations, the prediction model to be trained is trained, specifically including:
[0018] Determine the kernel function corresponding to the prediction model, and the coefficients to be adjusted corresponding to the kernel function;
[0019] Based on the coefficients to be adjusted and the kernel function, determine the kernel matrix to be adjusted;
[0020] The training samples are input into the prediction model to obtain the prediction results of each sample output by the prediction model.
[0021] With the goal of minimizing the gap between the prediction results of each sample and the corresponding annotations of the training samples, the matrix parameters in the kernel matrix to be adjusted are adjusted to obtain the target matrix; the target matrix is used to predict the icing data based on the input data of the prediction model.
[0022] In one embodiment, the prediction model is trained through a multi-iterative process;
[0023] With the optimization objective of minimizing the gap between the prediction results of each sample and the corresponding annotations of the training samples, the matrix parameters in the kernel matrix to be adjusted are adjusted to obtain the target matrix, specifically including:
[0024] For each iteration, determine the matrix parameters of the kernel matrix obtained from the previous iteration and use them as the initial matrix parameters;
[0025] The initial matrix parameters are adjusted using the Grey Wolf optimization algorithm to obtain the adjusted kernel matrix;
[0026] Based on the adjusted kernel matrix, determine the sample prediction result for each training sample in this iteration process;
[0027] Based on the sample prediction results of each training sample in the iteration process, determine whether the iteration termination condition is met. If so, determine the target matrix based on the matrix parameters of the kernel matrix adjusted in the iteration process.
[0028] In one embodiment, the prediction model includes multiple classifiers, the weights of which are not identical, and the structure of the classifiers is an extreme learning machine structure.
[0029] Based on the training samples and their annotations, the prediction model to be trained is trained to obtain the trained prediction model, specifically including:
[0030] Each training sample is input into each classifier included in the prediction model to obtain the classification result output by each classifier.
[0031] Determine the weights of each classifier in the current iteration process, and determine the sample prediction results corresponding to each training sample based on the classification results output by each classifier and the weights corresponding to each classifier.
[0032] The prediction model to be trained is trained based on the prediction results corresponding to each training sample and the annotations of each training sample.
[0033] In one embodiment, the prediction model to be trained is trained based on the sample prediction results corresponding to each training sample and the annotations of each training sample, specifically including:
[0034] In each iteration, for each training sample, determine the weight of that training sample in that iteration.
[0035] Based on the weight of each training sample in the iteration process, the sample prediction results corresponding to each training sample, and the annotation of each training sample, the iteration difference of each training sample in the iteration process is determined.
[0036] The prediction model to be trained is trained with the goal of minimizing the difference between the iteration differences corresponding to each iteration process.
[0037] The method further includes:
[0038] For each training sample, the number of target classification results is determined, wherein the target classification result is the classification result whose difference from the label of the training sample is greater than a preset difference threshold;
[0039] The weight of the training sample in the next iteration is determined based on the number of target classification results.
[0040] This specification provides an icing condition prediction device, the device comprising:
[0041] The acquisition module is used to determine the icing data of the target line at historical times and the environmental data at the current time as input data;
[0042] The prediction module is used to input the input data into a pre-trained prediction model to obtain the prediction result output by the prediction model, which serves as the icing data at the current moment; wherein, the prediction model is pre-trained using an incremental learning method based on historical icing data and historical environmental data.
[0043] The determination module is used to determine the icing status of the target line based on the icing data at the current moment.
[0044] This specification provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described method for predicting icing conditions.
[0045] This specification provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the above-described icing prediction method.
[0046] The above-mentioned technical solutions adopted in this specification can achieve the following beneficial effects:
[0047] The icing prediction method provided in this specification pre-trains an accurate prediction model using incremental learning. After acquiring current environmental data and historical icing data, the prediction model generates accurate icing data for the current moment, leading to an accurate icing situation. This allows for the subsequent execution of appropriate de-icing strategies. Even with a small sample size of new samples, an accurate prediction model can still be trained, resulting in accurate icing information. Attached Figure Description
[0048] Figure 1 The diagram shown is a flowchart of the icing prediction method provided in this manual.
[0049] Figure 2 The diagram shown is a structural schematic of the icing prediction device provided in this manual.
[0050] Figure 3 The image shown corresponds to Figure 1 Electronic devices. Detailed Implementation
[0051] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0052] It should be noted that all actions involving the acquisition of signals, information, or data in this manual are performed in accordance with the relevant data protection laws and regulations of the locality and with authorization from the owner of the relevant device.
[0053] One embodiment of the present invention provides a method for predicting icing conditions on transmission lines. An accurate prediction model is pre-trained using incremental learning. After acquiring current environmental data and historical icing data, the accurate icing data for the current moment is obtained based on the prediction model. This current icing data is then output as the icing condition, allowing for the subsequent execution of appropriate de-icing strategies. Even with a small sample size of new data, an accurate prediction model can be trained, leading to accurate icing conditions.
[0054] The technical solutions provided in the various embodiments of this specification are described in detail below with reference to the accompanying drawings.
[0055] Figure 1 This is a flowchart illustrating one method for predicting icing conditions as described in this specification, which specifically includes the following steps:
[0056] S100: Determine the icing data of the target line at historical times and the environmental data at the current time.
[0057] In one or more embodiments provided in this specification, the icing prediction method can be applied to any electronic device, which can be a server or a smart terminal. For ease of description, the following description will use the execution process of the icing prediction method performed by a server as an example.
[0058] Generally, the current icing thickness of a transmission line is influenced by both historical icing thickness and current environmental data. Since there are typically multiple transmission lines, and the environmental data varies across different sections of each line, the corresponding icing data will also differ. Therefore, the server can first identify the target line and determine its environmental data and historical icing data. Based on this acquired data, it can then predict the current icing thickness of the target line.
[0059] Specifically, the server can receive the target line identifier and the corresponding environmental data sent by the data acquisition device, and parse the environmental data to obtain the specific content corresponding to the environmental data. The environmental data can be at least one of temperature, humidity, wind direction, and wind speed. The data acquisition device can be a sensor installed around the target line, or a device that obtains environmental data from sources such as weather forecasts.
[0060] Then, the server can determine the icing data of the target line at a given historical moment from the pre-stored icing data corresponding to each line, based on the line identifier of the target line. The icing data of the target line at a given historical moment may only include the icing data of the target line at the previous moment, or it may include icing data from several consecutive historical moments, including the icing data of the previous moment. The icing data may only include the icing thickness, or it may include the icing thickness and the growth rate of the icing thickness. The icing thickness can be a directly measured icing thickness or an equivalent icing thickness.
[0061] The specific data types included in the environmental data and the icing data, as well as the specific time period corresponding to the historical time, can be set as needed; this manual does not impose any restrictions on this.
[0062] Finally, the server can store the historical icing data of the target line and the current environmental data as input data.
[0063] S102: Input the input data into the pre-trained prediction model to obtain the prediction result output by the prediction model, which is used as the icing data at the current moment; wherein, the prediction model is pre-trained using an incremental learning method based on historical icing data and historical environmental data corresponding to the historical icing data.
[0064] In one or more embodiments provided in this specification, as described above, the inventive point of this icing prediction method is that it uses a prediction model pre-trained based on incremental learning to predict accurate icing data for the current moment based on environmental data at the current moment and icing data at historical moments.
[0065] Therefore, the server can use the input data as input to the pre-trained prediction model to obtain the prediction result output by the prediction model, which is used as the icing data at the current moment.
[0066] The specific input data for this prediction model can be a vector composed of the current environmental data, the historical icing thickness, and the historical icing growth rate. The specific output data of this prediction model can be either the current icing thickness or a vector composed of the current icing thickness, the current environmental data, the historical icing thickness, and the historical icing growth rate.
[0067] The prediction model can be trained in the following way:
[0068] First, the server used to train the prediction model can obtain historical icing data of the sample line and the corresponding historical environmental data. The sample line can be the target line, any transmission line, or any segment of a transmission line.
[0069] Then, for each historical moment in the historical icing data, the server can determine the environmental data corresponding to the icing data from the historical environmental data, and use it as the environmental data corresponding to that historical moment.
[0070] Then, the server can determine the training samples based on the environmental data corresponding to that historical moment, and use the icing data corresponding to that historical moment as the annotation for the training samples.
[0071] Finally, an accurate prediction model is trained based on the training samples and their annotations.
[0072] During the use of the prediction model, the server of the prediction model can monitor the prediction results. When a difference is detected between the prediction results and the actual icing situation, the target sample and its label are determined, that is, the new sample and its label.
[0073] Therefore, the server training the model can fine-tune the model parameters based on the target sample and its annotations to obtain an adjusted prediction model. In this way, an accurate prediction model can be trained even when the number of target samples is relatively small.
[0074] It should be noted that the server used to train the prediction model and the server used to use the prediction model can be the same server or different servers. The specific training and deployment of the prediction model can be configured as needed, and this manual does not impose any restrictions on this.
[0075] S104: Determine the icing status of the target line based on the icing data at the current moment.
[0076] In one or more embodiments provided in this specification, as described above, this method is an icing condition prediction method. The icing condition can be the current icing thickness of the target line, the icing growth rate from the previous moment to the current moment, or the icing distribution of each transmission line determined based on the icing thickness of each transmission line and each segment of each transmission line. Therefore, after obtaining the icing data at the current moment, the server can also determine the icing condition of the target line.
[0077] Specifically, the server can determine the current icing thickness of the target line based on the current icing data, and use this as the icing status of the target line.
[0078] Alternatively, the server can determine the icing growth rate of the target line from the previous moment to the current moment based on the current icing thickness and the previous icing thickness, and use this as the icing status of the target line.
[0079] Alternatively, the server can preset the environmental data at the current moment as the environmental data for the next moment or several consecutive moments starting from the current moment, and determine the icing data of the target line in the next moment or several consecutive moments starting from the current moment in the order of each moment, thereby predicting the icing situation of the next moment or several consecutive moments starting from the current moment.
[0080] Alternatively, the server can determine the current icing thickness and icing growth rate of the target line, store them as the current icing data, and predict the icing distribution of each transmission line based on the icing data of each transmission line stored in the server at each historical time and the current time, thus providing the icing situation for each transmission line.
[0081] In other words, the icing situation includes at least one of the following: the icing thickness at the current moment, the icing growth rate during the period from the previous moment to the current moment, the icing situation at the next moment or several consecutive moments starting from the current moment, and the icing distribution situation corresponding to each transmission line.
[0082] based on Figure 1 The described icing prediction method pre-trains an accurate prediction model using incremental learning. After acquiring current environmental data and historical icing data, the model calculates accurate icing data for the current moment and outputs this data as the icing condition. This output is then used to implement appropriate de-icing strategies. Even with a small sample size of new samples, an accurate prediction model can be trained to obtain accurate icing information.
[0083] Furthermore, the aforementioned method of pre-training an accurate prediction model and then fine-tuning it with target samples is typically seen when the prediction model is a large model. While a large prediction model does indeed have higher accuracy, it also increases the computational demands. Therefore, given the limited computational resources, this manual provides an answer to how to train an accurate prediction model even with limited computing power: by setting the prediction model's structure as an extreme learning machine.
[0084] Therefore, the training process of this prediction model can be described as follows:
[0085] Specifically, the server training the model can first determine the kernel function of the extreme learning machine corresponding to the prediction model, as well as the coefficients to be adjusted for that kernel function. The kernel function can be at least one of a linear kernel function, a polynomial kernel function, a Gaussian radial basis function kernel function, or a sigmoid kernel function.
[0086] Then, the server can determine the kernel matrix to be adjusted based on the kernel function and the coefficients to be adjusted.
[0087] The server can then use each training sample as input to the prediction model to obtain the prediction results of each sample output by the prediction model based on the kernel matrix to be adjusted.
[0088] Finally, the server optimizes the kernel matrix by minimizing the gap between the prediction results of each sample and the corresponding annotations of the training samples. This optimized kernel matrix, with the adjusted parameters, serves as the target matrix. Thus, the trained prediction model is obtained. The target matrix is used to predict icing data based on the input data of this prediction model.
[0089] The kernel function used in the Extreme Learning Machine described in this specification is the polynomial kernel function K. poly and Gaussian radial basis function kernel function K rbf For example, since the expression for a polynomial kernel function can usually be... The expression for the Gaussian radial basis function kernel function can usually be: Therefore, the coefficients to be adjusted corresponding to the kernel function of the extreme learning machine in this specification may include the polynomial kernel function K. poly The constant term coefficients q and z, the parameter g of the Gaussian radial basis function kernel, and the kernel weights w1 and w2 corresponding to the two kernel functions are given. However, since the weights are usually set using w1 + w2 = 1, it is sufficient to set the weight of one kernel function to w and the weight of the other kernel function to 1 - w. Here, x can usually be the input vector, and y can usually be the output vector; that is, the kernel function can convert the input vector into the output vector.
[0090] Based on the kernel function and the coefficients to be adjusted, the server can determine the kernel matrix.
[0091] Then, the server can input each training sample into the prediction model, and obtain the sample prediction results output by the prediction model through the kernel matrix to be adjusted set in the prediction model.
[0092] Finally, based on the difference between the prediction results of each sample and the corresponding annotations of the training samples, the matrix parameters in the kernel matrix are adjusted to obtain the adjusted kernel matrix. This process continues until the iteration termination condition is met, at which point the adjusted kernel matrix is used as the target matrix. Thus, the trained prediction model is obtained.
[0093] Of course, since there are usually errors during model training, in order to control the degree of punishment for misclassification during model training, the punishment coefficient C can also be adjusted in the above prediction model training procedure.
[0094] Based on the above approach, during model training, only the parameters that affect the model output need to be adjusted. This avoids the current situation where a large number of parameters need to be adjusted during model training, resulting in poor parameter interpretability and requiring a lot of computing resources to adjust to an accurate model. This ensures the training efficiency of the model and enables the training of an accurate prediction model even in scenarios with limited computing power.
[0095] Furthermore, during the adjustment of model parameters, evolutionary algorithms such as the gray wolf algorithm, whale algorithm, and mongoose algorithm can be used to adjust the model parameters.
[0096] Specifically, taking the gray wolf optimization algorithm as an example, the prediction model in this specification can be trained through multiple iterative processes. The training process for each iteration can be as follows:
[0097] First, the server training the model can determine the matrix parameters of the kernel matrix obtained from the previous iteration and use them as the initial matrix parameters for the current iteration.
[0098] Then, the server can adjust the parameters of the initial matrix using the Grey Wolf optimization algorithm to obtain the adjusted kernel matrix.
[0099] Then, the server can determine the sample prediction result of each training sample in the current iteration process based on the adjusted kernel matrix.
[0100] Finally, the server can determine the gap between the prediction results of each sample and the corresponding annotations of each training sample, and determine whether the iteration termination condition is met based on the gap.
[0101] If the conditions are met, the server can use the kernel matrix adjusted during the current iteration as the target matrix.
[0102] If the condition is not met, the server can continue to execute the next iteration.
[0103] Updating matrix parameters using the Grey Wolf algorithm typically involves the following steps:
[0104] (1) Initialize the gray wolf population and set parameters such as population size N, maximum number of iterations M, spatial search dimension D, and iteration coefficient a.
[0105] (2) Calculate and sort the fitness values of each gray wolf in the initial population. Name the three individuals with the best fitness values as α, β, and δ wolves, respectively, and name the remaining wolves as w wolves. The initial population includes N sets of solutions with matrix parameters. For each set of solutions, the fitness value is determined by the difference between the predicted sample output of the prediction model and the labeled training samples after the training samples are input into the prediction model whose target matrix is the kernel matrix corresponding to the set of solutions. The smaller the difference, the higher the fitness value.
[0106] (3) For each wolf w in the population, the current position of the gray wolf is updated using the following formula:
[0107]
[0108] X(t+1)=[X1(t)+X2(t)+X3(t)] / 3
[0109] Where X1, X2, and X3 are the step sizes by which the w wolf moves towards the α, β, and δ wolf directions, respectively. ( t) and X( t +1) Let X represent the wolf pack positions before and after the t-th update, A be the encirclement step size, representing the range of movement of wolf w within the search space, and C be the movement direction, describing the direction of movement of wolf w within the search space. α Let X be the position of α wolf. β The position of β wolf, X δ The position of δ wolf. D α Let D be the distance vector between wolf w and wolf α. β Let D be the distance vector between wolf w and wolf β. δ Let w be the distance vector between wolf w and wolf δ, and X be the current position of wolf w.
[0110] (4) Check if the position of wolf w is out of bounds after the update. If it is out of bounds, re-initialize the position of wolf w randomly. Calculate the fitness value of each wolf in the wolf pack and update α, β, and δ wolves.
[0111] Specifically, for each parameter that needs to be adjusted during the iteration of the prediction model, a boundary corresponding to that parameter can be pre-set, thereby determining the boundary of the solution for the gray wolf search algorithm. Therefore, after obtaining the updated position of wolf w, the server can determine whether it has crossed the boundary of the solution for the gray wolf search algorithm based on that position. If it has crossed the boundary, the server randomly generates the position of wolf w within the boundary of the solution for the gray wolf search algorithm.
[0112] (5) Finally, when the evolution termination condition is reached, the server can use the final position of the α wolf as the optimal solution for the matrix parameters.
[0113] In addition, when adjusting the matrix parameters of the kernel matrix according to the evolutionary algorithm, the server can also use an evolutionary algorithm that improves the Grey Wolf algorithm to adjust the matrix parameters.
[0114] Updating matrix parameters using an evolutionary algorithm that improves upon the Grey Wolf algorithm typically involves the following steps:
[0115] (1) Initialize the gray wolf population and set parameters such as population size N, maximum number of iterations M, spatial search dimension D, and iteration coefficient a.
[0116] (2) Calculate the fitness value of each gray wolf in the initial population and sort them. Name the three individuals with the best fitness values as α, β and δ wolves respectively, and the remaining wolves are all w wolves.
[0117] (3) Introduce the inertia weight coefficient: For each wolf w in the population, the current position of the gray wolf is updated using the following formula:
[0118]
[0119] At the same time, the Sigmoid function is introduced to adaptively update the population position:
[0120]
[0121] X i (t+1)=X i (t)·φ
[0122] Among them, f i and f ave Let X be the fitness value of the i-th individual in the wolf pack and the average fitness of the pack, respectively; θ is the exponential coefficient. (t) and X (t+1) Let represent the wolf pack positions before and after the t-th update. The specific meanings of the other characters in the formula are the same as those in the gray wolf algorithm described above.
[0123] (4) Check if the position of wolf w is out of bounds after the update. If it is out of bounds, re-initialize the position of wolf w randomly. Calculate the fitness value of each wolf in the wolf pack and update α, β, and δ wolves.
[0124] (5) Finally, when the evolution termination condition is reached, the server can use the final position of the α wolf as the optimal solution for the matrix parameters.
[0125] Furthermore, the above description only uses the extreme learning machine structure as an example of the prediction model. In reality, the prediction model may contain multiple classifiers, and each classifier has an extreme learning machine structure.
[0126] Therefore, during the training process, for each training sample, the server used for training can take the training sample as input and input it into each classifier included in the prediction model to obtain the classification result output by each classifier.
[0127] Next, the server can determine the weight of each classifier in the current iteration process, and determine the sample prediction result of the training sample based on the classification results output by each classifier and the weights corresponding to each classifier.
[0128] Finally, based on the prediction results of each sample and the annotations of the training samples corresponding to each prediction result, the server can train the prediction model to be trained.
[0129] The server can preset the weights for each classifier, or, for each iteration, determine the weight of the classifier in the next iteration based on the classifier's accuracy during that iteration. These weights can be obtained using... This formula is used to calculate α. m ε represents the weights of the classifier.m The prediction error can be specifically the sum of the differences between the classification results of each training sample output by the classifier and its corresponding label during the iteration process.
[0130] Furthermore, as the number of iterations increases, the accuracy of the prediction model continuously improves. In the later stages of iteration, most training samples may have a small gap between their prediction results and their labels, but there may still be a large gap between the prediction results and the labels of some training samples. In this case, by dissecting the gaps corresponding to the training samples with large gaps between their prediction results and their labels, the model can be optimized more specifically, thereby enabling the training of an accurate model more quickly.
[0131] Therefore, the server can also determine the weights corresponding to each training sample.
[0132] Specifically, for each training sample, the server can determine the number of target classification results. These target classification results are those whose difference from the annotation of the training sample is greater than a preset difference threshold.
[0133] Next, the server can determine the weight of the training sample in the next iteration based on the number of target classification results. The server can directly use this number as the weight, or it can calculate it using the following formula: E m (k) represents the weight of the k-th training sample in the current iteration, i.e., in the m-th iteration, E m+1 (k) represents the weight of the k-th training sample in the next iteration, i.e., the (m+1)-th iteration. m The sum of weights, ε l For error constraints, ε m This represents the prediction error. α m The weights of the classifiers can be preset values, which can be determined based on the number of classifiers.
[0134] Therefore, for each iteration, the server can determine the weight of each training sample in the current iteration, and determine the iteration difference in the current iteration based on the weight of each training sample in the current iteration, the sample prediction results corresponding to each training sample, and the annotation of each training sample.
[0135] Finally, the parameters of the prediction model are adjusted with the optimization objective of minimizing the iterative differences during a specified number of iterations. This specified number can be two or more.
[0136] Furthermore, line icing is conditional. During the process of determining training samples, the server used to train the model can also remove environmental data and icing data that do not meet the icing conditions.
[0137] Specifically, the conditions for line icing usually include an overhead line surface temperature of 0°C or below, an ambient relative humidity of 85% or above, and an ambient wind speed of no more than 1 m / s. Abnormal data in the icing dataset are removed based on the icing conditions.
[0138] Therefore, the server can determine whether the environmental data of the sample line at any given time meets the icing conditions. That is, if the environmental data meets at least one of the following conditions, it will be removed. The following conditions may specifically be: the surface temperature of the overhead line is greater than 0°C, the relative humidity of the environment is 85% or less, and the wind speed of the environment is greater than 1 m / s.
[0139] Based on this, the server can identify each training sample that meets the icing conditions.
[0140] Furthermore, for the sample line, there may be instances where environmental and icing data for a certain moment are not saved. Therefore, the server can also employ the k-nearest neighbor (kNN) fill algorithm to construct the environmental and icing data for a specific moment from data from several relatively close moments. Since the kNN fill algorithm is already a relatively mature algorithm, it will not be elaborated upon further in this specification.
[0141] Furthermore, model training demands significant computing power. If the input data has inconsistent dimensions and large discrepancies, high computing power is required to train an accurate model. To further alleviate the computing power requirements of model training, the server can normalize the data before inputting it into the prediction model. Commonly used normalization formulas are shown below:
[0142]
[0143] Where s is the standard deviation, x′ is the mean of the sample data, and x i Let be the original data value of the i-th training sample. This is the result of normalization.
[0144] Furthermore, the model training process described in this specification can be guided by a fitness function. The prediction model described in this specification can also be trained using a K-fold training set.
[0145] Furthermore, the confidence level described above for the prediction results output by the prediction model is determined by the difference between the predicted results output by the model and the actual icing situation corresponding to the input data. However, in the actual use of the model, this confidence level can also be determined based on whether the input data satisfies the KKT (Karush-Kuhn-Tucker) conditions of the prediction model.
[0146] Specifically, the server can determine whether each input data satisfies the KKT conditions. If it does, the input data is considered to have a high confidence level. If it does not, the input data is considered to have a confidence level lower than a preset confidence threshold.
[0147] Furthermore, the incremental learning of the prediction model trained based on the above structure can be carried out through the following process.
[0148] Specifically, at time t, the prediction model satisfies H(t) = K t +C ―1 The formula I, where H(t) is the output matrix, and K... t Let C be the target matrix, and I be the penalty coefficient and identity matrix, respectively. A new sample (x) is introduced at time t+1. t ,y t If ), then H(t+1) = K t+1 +C ―1 I =
[0149]
[0150] Where H(t) is the output matrix at time t, and K(t,x) t+1 K(x) is the result calculated using a kernel function, which characterizes the similarity between the target sample and the training samples used to train the prediction model. t+1 K(t,x) and K(t,x) t+1 Similarly, K(x) can also be used to characterize the similarity between the target sample and the training samples used to train the prediction model. t+1 ,x t+1 C represents the prediction result of the target sample determined by the kernel function. It can be used to characterize the self-features and self-similarity of the target sample in the kernel space. ―1 The penalty term represents the degree to which new samples affect the model.
[0151] Based on the above formula, the target matrix can be adapted to the data distribution of new samples without retraining the target matrix. In this way, a prediction model trained by incremental learning can be obtained.
[0152] It should be noted that the above process of updating the kernel matrix through incremental learning can be interpreted as updating the kernel matrix of a single Extreme Learning Machine (ELM) classifier in the case of a prediction model containing only one ELM classifier. When the prediction model contains multiple ELM classifiers, it can be interpreted as updating the kernel matrices of each classifier. The server can update the kernel matrix of each classifier individually, or it can update the kernel matrices of all classifiers simultaneously based on the sample prediction results determined by the classification results output by each classifier and the difference between the labeled target samples and the target samples.
[0153] The above describes one or more embodiments of the icing prediction method provided in this specification. Based on the same idea, this specification also provides an icing prediction device, such as... Figure 2 As shown.
[0154] Figure 2 This is a schematic diagram of a model training apparatus provided in this specification, wherein:
[0155] The acquisition module 200 is used to determine the icing data of the target line at historical times and the environmental data at the current time as input data;
[0156] The prediction module 202 is used to input the input data into a pre-trained prediction model to obtain the prediction result output by the prediction model as the icing data at the current moment; wherein, the prediction model is pre-trained based on historical icing data and historical environmental data using an incremental learning method;
[0157] The determination module 204 is used to determine the icing status of the target line based on the icing data at the current moment.
[0158] The device further includes: a training module 206;
[0159] The training module 206 trains the prediction model in the following manner: determining the confidence level of the prediction model for the input data; when the confidence level is lower than a preset confidence threshold, determining the input data as a target sample and determining the label of the target sample; obtaining the prediction model pre-trained based on the training samples and their labels; adjusting the parameters of the prediction model based on the target samples and their labels; and adjusting the parameters of the prediction model based on the target samples and their labels.
[0160] Optionally, the training module 206 pre-trains the prediction model based on the training samples and their annotations in the following manner: for each historical moment, based on the historical icing data of the sample line and the environmental data of the historical icing data, the environmental data and icing data of the sample line at that historical moment are determined, and based on the environmental data and icing data of the sample line at that historical moment, each training sample and its annotation are determined, and the prediction model to be trained is trained based on each training sample and its annotation to obtain the trained prediction model.
[0161] Optionally, the training module 206 is used to determine the kernel function corresponding to the prediction model and the coefficients to be adjusted corresponding to the kernel function; determine the kernel matrix to be adjusted based on the coefficients to be adjusted and the kernel function; input each training sample into the prediction model to obtain the prediction results of each sample output by the prediction model; and adjust the matrix parameters in the kernel matrix to be adjusted with the optimization objective of minimizing the gap between the prediction results of each sample and the labels of the corresponding training samples to obtain the target matrix; the target matrix is used to predict icing data based on the input data of the prediction model, wherein the structure of the prediction model is an extreme learning machine structure.
[0162] Optionally, the training module 206 is configured to, for each iteration, use the matrix parameters of the kernel matrix obtained from the previous iteration as initial matrix parameters, adjust the initial matrix parameters using the Grey Wolf optimization algorithm to obtain an adjusted kernel matrix, determine the sample prediction result of each training sample in the iteration based on the adjusted kernel matrix, determine whether the iteration termination condition is met based on the sample prediction result of each training sample in the iteration, and if so, determine the target matrix based on the matrix parameters of the kernel matrix adjusted in the iteration, wherein the prediction model is trained through multiple iterations.
[0163] Optionally, the training module 206 is used to input each training sample into each classifier included in the prediction model to obtain the classification results output by each classifier.
[0164] Determine the weights of each classifier in the current iteration process, and determine the sample prediction results corresponding to each training sample based on the classification results output by each classifier and the weights corresponding to each classifier.
[0165] Based on the sample prediction results corresponding to each training sample and the annotation of each training sample, the prediction model to be trained is trained. The prediction model contains multiple classifiers, and the weights of the multiple classifiers are not completely the same. The structure of the classifiers is an extreme learning machine structure.
[0166] Optionally, the training module 206 is used to determine the weight of each training sample in each iteration process, and determine the iterative difference of each training sample in the iteration process based on the weight of each training sample in the iteration process, the sample prediction results corresponding to each training sample, and the label of each training sample, and train the prediction model to be trained with the goal of minimizing the difference between the iterative differences corresponding to each iteration process.
[0167] Optionally, the training module 206 is further configured to determine the number of target classification results for each training sample, wherein the target classification result is a classification result whose difference from the label of the training sample is greater than a preset difference threshold, and determine the weight of the training sample in the next iteration process based on the number of target classification results.
[0168] The specification also provides a computer-readable storage medium storing a computer program that can be used to execute the above-described method for predicting icing conditions.
[0169] This instruction manual also provides Figure 3 The diagram shows a schematic structural representation of the electronic device. Figure 3 At the hardware level, the electronic device includes a processor, internal bus, network interface, memory, and non-volatile memory, and may also include other hardware required for the business. The processor reads the corresponding computer program from the non-volatile memory into memory and then runs it to implement the aforementioned icing prediction method. Of course, in addition to software implementation, this specification does not exclude other implementation methods, such as logic devices or a combination of hardware and software, etc. That is to say, the execution subject of the following processing flow is not limited to individual logic units, but can also be hardware or logic devices.
[0170] In the 1990s, improvements to a technology could be clearly distinguished as either hardware improvements (e.g., improvements to the circuit structure of diodes, transistors, switches, etc.) or software improvements (improvements to the methodology). However, with technological advancements, many methodological improvements today can be considered direct improvements to the hardware circuit structure. Designers almost always obtain the corresponding hardware circuit structure by programming the improved methodology into the hardware circuit. Therefore, it cannot be said that a methodological improvement cannot be implemented using hardware physical modules. For example, a Programmable Logic Device (PLD) (such as a Field Programmable Gate Array (FPGA)) is such an integrated circuit whose logic function is determined by the user programming the device. Designers can program and "integrate" a digital system onto a PLD themselves, without needing chip manufacturers to design and manufacture dedicated integrated circuit chips. Furthermore, nowadays, instead of manually manufacturing integrated circuit chips, this programming is mostly implemented using "logic compiler" software. Similar to the software compiler used in program development, the original code before compilation must be written in a specific programming language, called a Hardware Description Language (HDL). There are many HDLs, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, and RHDL (Ruby Hardware Description Language). Currently, the most commonly used are VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art should understand that by simply performing some logic programming on the method flow using one of these hardware description languages and programming it into an integrated circuit, the hardware circuit implementing the logical method flow can be easily obtained.
[0171] The controller can be implemented in any suitable manner. For example, it can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers. Examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicon Labs C8051F320. A memory controller can also be implemented as part of the control logic of the memory. Those skilled in the art will also recognize that, in addition to implementing the controller in purely computer-readable program code form, the same functionality can be achieved by logically programming the method steps to make the controller take the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers. Therefore, such a controller can be considered a hardware component, and the means included therein for implementing various functions can also be considered as structures within the hardware component. Alternatively, the means for implementing various functions can be considered as both software modules implementing the method and structures within the hardware component.
[0172] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, a computer can be, for example, a personal computer, laptop computer, cellular phone, camera phone, smartphone, personal digital assistant, media player, navigation device, email device, game console, tablet computer, wearable device, or any combination of these devices.
[0173] For ease of description, the above devices are described in terms of function, divided into various units. Of course, in implementing this specification, the functions of each unit can be implemented in one or more software and / or hardware components.
[0174] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0175] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0176] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0177] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0178] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0179] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0180] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0181] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0182] Those skilled in the art will understand that the embodiments of this specification can be provided as methods, systems, or computer program products. Therefore, this specification may take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this specification may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0183] This specification can be described in the general context of computer-executable instructions that are executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform a specific task or implement a specific abstract data type. This specification can also be practiced in distributed computing environments, where tasks are performed by remote processing nodes connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage nodes.
[0184] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to interchangeably. Each embodiment focuses on describing the differences from other embodiments. In particular, the system embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments.
[0185] The above description is merely an embodiment of this specification and is not intended to limit this specification. Various modifications and variations can be made to this specification by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of the claims of this specification.
Claims
1. A method for predicting icing conditions, characterized in that, include: Determine the historical icing data and current environmental data of the target route as input data; The input data is fed into a pre-trained prediction model to obtain the prediction result output by the prediction model, which is used as the icing data at the current moment; wherein, the prediction model is pre-trained using an incremental learning method based on historical icing data and historical environmental data; Based on the icing data at the current moment, the icing status of the target line is determined. The prediction model is trained in the following manner: The confidence level of the prediction model for the input data is determined. When the confidence level is lower than a preset confidence threshold, the input data is determined to be a target sample, and the label of the target sample is determined. A prediction model pre-trained based on training samples and their annotations is obtained, and the parameters of the prediction model are adjusted based on the target samples and their annotations to obtain a prediction model trained using incremental learning. The prediction model, which is pre-trained based on training samples and their annotations, is trained in the following manner: For each historical moment, based on the historical icing data of the sample line and the environmental data of the historical icing data, the environmental data and icing data of the sample line at that historical moment are determined, and the training samples and their labels are determined based on the environmental data and icing data of the sample line at that historical moment. Based on each training sample and its annotation, the prediction model to be trained is trained to obtain the trained prediction model. The prediction model comprises multiple classifiers, each with different weights, and the classifiers are structured as an extreme learning machine. Training the prediction model based on each training sample and its label includes: Each training sample is input into each classifier contained in the prediction model to obtain the classification result output by each classifier. Determine the weights of each classifier in the current iteration process, and determine the sample prediction results corresponding to each training sample based on the classification results output by each classifier and the weights corresponding to each classifier. The prediction model to be trained is trained based on the prediction results corresponding to each training sample and the annotations of each training sample.
2. The method for predicting icing conditions according to claim 1, characterized in that, The step of inputting each training sample into the classifiers included in the prediction model to obtain the classification results output by each classifier specifically includes: For each classifier, determine the kernel function corresponding to the classifier, and the coefficient to be adjusted corresponding to the kernel function; Based on the coefficients to be adjusted and the kernel function, determine the kernel matrix to be adjusted; Each training sample is input into the classifier to obtain the classification results output by the classifier. The step of training the prediction model to be trained based on the sample prediction results corresponding to each training sample and the annotations of each training sample includes: With the goal of minimizing the gap between the prediction results of each sample and the corresponding annotations of the training samples, the matrix parameters in the kernel matrix to be adjusted are adjusted to obtain the target matrix; the target matrix is used to predict the icing data based on the input data of the prediction model.
3. The method for predicting icing conditions according to claim 2, characterized in that, The prediction model is trained through multiple iterative processes; With the optimization objective of minimizing the gap between the prediction results of each sample and the corresponding annotations of the training samples, the matrix parameters in the kernel matrix to be adjusted are adjusted to obtain the target matrix, specifically including: For each iteration, determine the matrix parameters of the kernel matrix obtained from the previous iteration and use them as the initial matrix parameters; The initial matrix parameters are adjusted using the Grey Wolf optimization algorithm to obtain the adjusted kernel matrix; Based on the adjusted kernel matrix, determine the sample prediction result for each training sample in this iteration process; Based on the sample prediction results of each training sample in the iteration process, determine whether the iteration termination condition is met. If so, determine the target matrix based on the matrix parameters of the kernel matrix adjusted in the iteration process.
4. The method for predicting icing conditions as described in claim 1, characterized in that, Based on the prediction results corresponding to each training sample and the annotations of each training sample, the prediction model to be trained is trained, specifically including: In each iteration, for each training sample, determine the weight of that training sample in that iteration. Based on the weight of each training sample in the iteration process, the sample prediction results corresponding to each training sample, and the annotation of each training sample, the iteration difference of each training sample in the iteration process is determined. The prediction model to be trained is trained with the goal of minimizing the difference between the iteration differences corresponding to each iteration process. The method further includes: For each training sample, the number of target classification results is determined, wherein the target classification result is the classification result whose difference from the label of the training sample is greater than a preset difference threshold; The weight of the training sample in the next iteration is determined based on the number of target classification results.
5. An icing condition prediction device, characterized in that, include: The acquisition module is used to determine the icing data of the target line at historical times and the environmental data at the current time as input data; The prediction module is used to input the input data into a pre-trained prediction model to obtain the prediction result output by the prediction model, which serves as the icing data at the current moment; wherein, the prediction model is pre-trained using an incremental learning method based on historical icing data and historical environmental data. The determination module is used to determine the icing status of the target line based on the icing data at the current moment; The device further includes: a training module; The training module is used to determine the confidence level of the prediction model for the input data. When the confidence level is lower than a preset confidence threshold, the input data is determined to be a target sample, and the label of the target sample is determined. The module also obtains a prediction model that has been pre-trained based on training samples and their labels, and adjusts the parameters of the prediction model based on the target sample and its labels to obtain a prediction model trained using incremental learning. The training module is specifically used for: for each historical moment, determining the environmental data and icing data of the sample line at that historical moment based on the historical icing data of the sample line and the environmental data of the historical icing data, and determining the training samples and their labels based on the environmental data and icing data of the sample line at that historical moment; and training the prediction model to be trained based on each training sample and its label to obtain the trained prediction model. The prediction model comprises multiple classifiers, each with different weights, and the classifiers are structured as an extreme learning machine. The training module is specifically configured to: input each training sample into each classifier within the prediction model to obtain the classification results output by each classifier; determine the weights of each classifier in the current iteration, and based on the classification results output by each classifier and their respective weights, determine the sample prediction results corresponding to each training sample; and train the prediction model to be trained based on the sample prediction results corresponding to each training sample and the annotations of each training sample.
6. A computer-readable storage medium storing a computer program that, when executed by a processor, implements the method described in any one of claims 1 to 4.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the method described in any one of claims 1 to 4.