Pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation
By constructing the index matrix and processing outliers and missing values, combined with the seven-branch knowledge distillation method, the data diversity and quality problems in the speed regulation system of the pumped storage power station are solved, and high accuracy prediction of the generator stator temperature is achieved.
Patent Information
- Application Number
- CN202510113897.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-24
- Publication Date
- 2025-05-09
- Estimated Expiration
- 2045-01-24
AI Technical Summary
In the prior art, in the speed regulation system of pumped storage power stations, it is difficult to effectively deal with the diversity of detection indicators and data loss or outliers, resulting in low model fit and large detection errors.
The stator temperature prediction method of pumped storage motor based on seven-branch knowledge distillation is adopted. By constructing an index matrix, outliers and missing values are identified and processed, and knowledge transfer and training is used for 7 teacher models and student models to improve prediction accuracy.
It improves data quality and model training effect, enhances the prediction accuracy of generator stator temperature, and reduces detection errors.
Smart Images

Figure CN119962629A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of fault monitoring of hydropower stations, and in particular relates to a pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation. Background Art
[0002] The speed control system of a pumped storage power station is a key part of the normal operation of the power station. It can monitor and adjust the speed of the water pump and generator in real time. The speed control system consists of a speed measuring device, a speed regulator, an actuator, etc.
[0003] Common faults include mechanical guide vane jamming, pipeline leakage and other problems that cause water flow to deviate from the expected target, which can cause the generator stator to overheat, possibly causing equipment damage and safety hazards. If the temperature change of the generator stator cannot be discovered and repaired in time, it will affect the normal production activities and quality of life of the pumped storage power station.
[0004] The speed control system of a pumped storage power station uses a speed measuring device to monitor the speed of the turbine driven by the hydraulic power to drive the generator. The speed measuring device feeds the measured speed back to the speed regulator and controls the opening of the mechanical guide vanes through the actuator to adjust the operating status of the turbine. The flow rate of water through the turbine, the equipment temperature, and the output power of the generator are all important indicators for detecting speed control system failures. During the operation of a pumped storage power station, in order to monitor the data of key equipment to pay attention to the operation of the speed control system, the current method is to train a deep learning model with a large amount of data from each detection indicator so that it can output a predicted distribution of temperature values.
[0005] Due to the large number of detection indicators and the occurrence of missing values and abnormal values in the actual data collection process, the collection and processing of target data is also difficult and the model fitting is low. Therefore, the current model has a small scope of application and large detection errors. Summary of the invention
[0006] The main purpose of the present invention is to overcome the shortcomings and deficiencies of the prior art and to provide a data monitoring and prediction method for a seven-branch pumped storage speed regulation system.
[0007] In order to achieve the above object, the present invention adopts the following technical solutions: A pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation is applied to a pumped storage speed regulation system. The pumped storage speed regulation system includes a speed regulation device, an external measuring device and a monitoring device. The speed regulation device includes a speed regulator, an actuator and a tachometer. The external measuring device includes a current sensor, a voltage sensor, a temperature sensor, a flow meter, a guide vane opening measuring instrument, a torque measuring instrument and a pressure gauge. The temperature sensor is installed on the surface of the speed regulation device to measure the stator temperature of the generator. , current sensor and voltage sensor are installed at the motor output end of the turbine to measure the motor output current and output voltage , the flow meter is placed in the water flow pipe of the turbine to measure the water flow in the pipe The speed measuring device is installed on the motor rotor to measure the motor speed. , guide vane opening measuring instrument measures the mechanical guide vane opening , The torque measuring instrument is installed on the turbine to measure the turbine torque , the pressure gauge is installed in the turbine pipeline to measure the pipeline pressure ; The temperature data prediction method comprises the following steps: S1. Obtain the time series data of the detection index of the speed control system of the pumped storage power station to form an index matrix; S2, traverse each element in the indicator matrix, use the mathematical method of limiting the standard deviation to identify outliers and assign them a value of 0; S3, traverse each element in the indicator matrix, find the missing value, fill the missing value with data, and update the indicator matrix; S4, build 7 teacher models and obtain different training sets for each teacher model; S5. Get a test set with a specified number of elements for the 7 teacher models S6, train the teacher model and output soft labels; S7. Build a student model, obtain the training set and test set of the student model, and use the seven-branch knowledge distillation method to train the student model S8. Use the trained student model to predict the generator stator temperature.
[0008] Furthermore, the process of step S1 is as follows: The time series data of the detection indicators are obtained through the external measuring device, and the detection indicators include the generator power , Pipeline water flow , Generator stator temperature , Mechanical guide vane opening , Motor speed , turbine torque , Pipeline pressure , where the generator power is determined by the turbine motor output current and output voltage Multiplying them together, ; The additional measuring device includes a current sensor, a voltage sensor, a temperature sensor, a flow meter, a guide vane opening measuring device, a torque measuring instrument and a pressure gauge; the temperature sensor is installed on the surface of the key equipment of the speed control system to measure the temperature of the speed control system , current sensor and voltage sensor are installed at the motor output end to measure the motor output current and output voltage , the flow meter is placed in the water flow pipe of the turbine to measure the water flow in the pipe The speed measuring device is installed on the motor rotor to measure the motor speed. , the guide vane opening measuring device measures the mechanical guide vane opening , The torque measuring instrument is installed on the turbine to measure the turbine torque , The pressure gauge is installed in the turbine pipeline to measure the pipeline pressure ; The measurement interval of the additional measuring device is one hour. It represents the generator power value corresponding to the i-th measurement time measured on that day, and is an integer, , It represents the pipeline water flow value, generator stator temperature value, mechanical guide vane opening value, motor speed value, turbine torque and pipeline pressure value corresponding to the i-th measurement time measured on that day; Define the indicator matrix as , and obtain the index torque.
[0009] The indicator matrix is a matrix with 7 rows and 24 columns.
[0010] Furthermore, the process of step S2 is as follows: For the indicator matrix , traverse the index matrix elements, , They represent the elements corresponding to the i-th row and j-th column of the indicator matrix and the i-th row and k-th column of the indicator matrix, respectively. , , and i, j, k are all integers; Calculate the standard deviation of the row elements in the indicator matrix. When the standard deviation is greater than the set standard deviation threshold τ, the indicator matrix is considered The element in the i-th row and k-th column of is an abnormal value and is reassigned to 0.
[0011] The indicator matrix The element in the i-th row and k-th column of is an abnormal value and is reassigned to 0, that is, .
[0012] Furthermore, the process of step S3 is as follows: Traversing the indicator matrix Matrix elements of The value of is 0, that is is a missing value, Represents the indicator matrix The element in row i and column a, If satisfied
[0013] or
[0014] Description Indicator Matrix China and Data If the element data in the same row are evenly distributed, the mean method is used to calculate the data. To assign a value: ; If satisfied
[0015] or ; Description Indicator Matrix China and Data If the distribution of element data in the same row changes linearly with time, the median method is used to calculate the data. To assign a value:
[0016] After reassigning the outliers and missing values in the indicator matrix, the updated indicator matrix is obtained, which is recorded as
[0017] .
[0018] Furthermore, the process of step S4 is as follows: Knowledge distillation is a method of transferring the knowledge of a large and complex teacher model to a small and simple student model. This technical solution uses 7 independent teacher models and constructs a seven-branch knowledge distillation method to train the student model. Construct 7 independent Transformer models as 7 teacher models, respectively denoted as , , , , Each of the above teacher models includes a training set and a test set. In the initial state, the training set and the test set are empty sets. , , , , The corresponding training sets are , , , , ; The Transformer model, i.e., the deformation model, is a deep learning model for processing sequence data. The Transformer model has a self-attention mechanism, which gives it a significant advantage in processing time-series problems. Unlike traditional recursive neural networks or long short-term memory networks, the Transformer model does not rely on the order of sequence information transmission, but processes each time step of the input data in parallel through a global self-attention mechanism. This mechanism allows the Transformer to efficiently capture long-distance dependencies and effectively model the normal operation rules of the device when faced with complex time series patterns. In addition, the Transformer's multi-head attention mechanism can learn different features of the sequence in different subspaces, thereby enhancing its ability to represent time series data. This makes the Transformer particularly suitable for processing equipment operation data with complex patterns, long time spans, and high dimensions, and can provide accurate and informative guidance for the student model in step S5.
[0019] Set the number of training set elements to at least , the number of test set elements is at least ; Delete the 1st, 2nd, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as : ; Delete the 1st, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as : ; Delete the 1st, 5th, and 7th row elements of the indicator matrix, and the resulting matrix is recorded as : ; Delete the elements of the 6th and 7th rows of the indicator matrix, and the resulting matrix is recorded as : ; Delete the 7th row element from the indicator matrix, and the resulting matrix is recorded as : ; Delete the 1st, 2nd, 4th, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as
[0020]
[0021] The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The indicator matrix Writing the Teacher Model The training set ; Get the teacher model The number of elements in the training set and For comparison, if the teacher model The number of elements in the training set is greater than or equal to , then go to step S5, if the teacher model The number of elements in the training set is less than , then return to step S1, and execute steps S1, S2, S3, and S4 in sequence.
[0022] The number of elements in the training set of the 7 teacher models is equal. When the number of elements in the training set of meets the preset requirements, the number of elements in the training sets of the seven teacher models all meet the requirements.
[0023] Furthermore, the process of step S5 is as follows: Execute steps S1, S2, and S3 in sequence, and update the indicator matrix in step S3 Write 7 test sets of 7 teacher models and get the teacher model The number of elements in the test set and For comparison, if the teacher model The number of elements in the test set is greater than or equal to , then go to step S6, if the teacher model The number of elements in the test set is less than , then return to step S5 and execute step S5; The test sets obtained for the 7 teacher models are the same.
[0024] Furthermore, the process of step S6 is as follows: The 7 teacher models are trained using their corresponding training sets and test sets. The training process is a process of adjusting model parameters with the goal of minimizing the loss function value. The Huber loss function is used as the loss function of the 7 teacher models, and the parameters of the teacher model are optimized accordingly. The Huber loss function formula is: ; in ; is the generator stator temperature data of the element in the i-th row and j-th column of any matrix in the test set, is the prediction data obtained by the teacher model based on the other elements of the matrix for the element in the i-th row and the j-th column. δ is the error hyperparameter, which is used to balance the behavior of the loss function under small prediction errors and large prediction errors. δ is set before the teacher model is used. Setting the loss function change threshold , when the loss function value is less than the loss function change threshold for 20 consecutive times , stop training; Use the 7 trained teacher models to predict the 7 corresponding training sets and generate 7 soft labels; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening and the generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow and generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque and generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power and generator stator temperature at the next moment after prediction output; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power, motor speed and generator stator temperature at the next moment after prediction; Teacher Model Soft label Is a teacher model The probability distribution of the generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power, motor speed, generator stator temperature and pipeline pressure at the next moment of the output is predicted.
[0025] Furthermore, the process of step S7 is as follows: Construct an LSTM model as a student model, and correspond to a training set and a test set. The training set of the student model includes the training sets of 7 teacher models and the corresponding output soft labels. The training set of the student model is composed of , the test set of the student model and the teacher model The test set is the same; The LSTM model, or long short-term memory network, is a recurrent network structure that solves the gradient vanishing problem of traditional RNNs through a gating mechanism. It can effectively capture the dependency relationship between the training sets of the seven teacher models and the corresponding soft labels. At the same time, its structure is relatively simple and can efficiently predict the input data.
[0026] The formula for calculating distillation loss is defined as
[0027] in, Model for teachers Predicted soft labels, and is an integer, For students, the model is based on The same array Predicted soft labels; The task loss calculation formula is defined as
[0028] in,
[0029] for The generator stator temperature data of the element in the i-th row and j-th column of any 1 matrix, and is an integer, is the predicted data obtained by the student model predicting the elements in the i-th row and j-th column based on the elements of the matrix except the elements in the i-th row and j-th column; Define the comprehensive loss function The expression is:
[0030] In the formula, is the distillation loss, For mission loss, is a weight hyperparameter used to balance the contribution of task loss and distillation loss; The student model is trained using the seven-branch knowledge distillation method. Knowledge distillation is a process of adjusting the student model parameters with the goal of minimizing the comprehensive loss function value. Seven-branch knowledge distillation refers to the process of multiple training of the student model through the training sets and soft labels of 7 teacher models, setting the comprehensive loss function threshold. When the loss function value is less than the comprehensive loss function threshold for 20 consecutive times, the training of the student model is stopped. The entire training process is as follows Figure 2 shown.
[0031] Furthermore, the process of step S8 is as follows: Apply the trained student model to Figure 1 The monitoring device is connected to the speed regulating device and the external measuring device. The speed regulating device includes a speed regulator, an actuator and a tachometer. The external measuring device includes a current sensor, a voltage sensor, a temperature sensor, a flow meter, a guide vane opening measuring instrument, a torque measuring instrument and a pressure gauge. The temperature sensor is installed on the surface of the speed regulating device to measure the stator temperature of the generator. , current sensor and voltage sensor are installed at the motor output end of the turbine to measure the motor output current and output voltage , the flow meter is placed in the water flow pipe of the turbine to measure the water flow in the pipe The speed measuring device is installed on the motor rotor to measure the motor speed. , guide vane opening measuring instrument measures the mechanical guide vane opening , The torque measuring instrument is installed on the turbine to measure the turbine torque , the pressure gauge is installed in the turbine pipeline to measure the pipeline pressure The above data are transmitted to the monitoring system through the speed control device and the external measuring device. The monitoring device inputs the above data into the trained student model, and the trained student model outputs the prediction result of the generator stator temperature.
[0032] The generator stator temperature prediction result can be used to determine the change trend of the generator stator temperature, and then to issue a timely warning before the generator stator temperature exceeds the safe range.
[0033] Compared with the prior art, the present invention has the following advantages and beneficial effects: 1. The definition of the indicator matrix and the method for processing outliers and missing values in the indicator matrix proposed in the present invention can unify multiple detection indicator variables by inputting indicator variables in matrix form, and at the same time use the method of limiting standard deviation to realize the identification of outliers in matrix elements. By assigning zero operations to outliers and filling data for missing values, effective processing of outliers and missing values is realized, thereby improving the quality of data in the training set of teacher model and student model.
[0034] 2. The present invention proposes a method for determining whether the same row elements in the indicator matrix where the missing value is located are uniform. The mean method and the median method are used to fill in the missing values according to the two different situations of uniform and uneven elements in the same row. This can more accurately process the missing values according to the characteristics of the data itself.
[0035] 3. This patent proposes a method for training student models using seven-branch knowledge distillation based on the importance and correlation of different indicators. Seven teacher models are used to train different training sets to output the joint distribution law of the motor stator temperature and other detection indicators. The seven-branch knowledge distillation method refers to further training the student model using the training results of the seven teacher models and the indicator matrix data, so that the student model can better capture the complex laws between the detection indicator data while maintaining the original simpler structure, and achieve a more accurate prediction of the stator temperature.
[0036] 4. Compared with the traditional knowledge distillation method, the seven-branch knowledge distillation method proposed in this patent can obtain the joint distribution law of different detection indicators and stator temperature by classifying the index detection data and training the seven teacher models separately. The training effect is better, and the grasp of the law of multiple detection indicator variables is more in line with reality. At the same time, compared with a single LSTM model, the student model trained by the seven-branch knowledge distillation method can imitate the prediction effect of the seven teacher models and achieve a more accurate prediction of the motor stator temperature. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0038] Figure 1 It is a simplified monitoring diagram of the pumped storage speed regulation system disclosed in the embodiment of the present invention; Figure 2is a flow chart of student model training in an embodiment of the present invention; Figure 3 is a prediction curve diagram of the student model after training by the seven-branch distillation method in an embodiment of the present invention; Figure 4 It is a flow chart of a pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation in an embodiment of the present invention. DETAILED DESCRIPTION
[0039] In order to enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without making creative work are within the scope of protection of the present application.
[0040] Reference to "embodiments" in this application means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described in this application may be combined with other embodiments.
[0041] Example 1 like Figure 4 As shown, this embodiment discloses a pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation, which is applied to a pumped storage speed regulation system, such as Figure 1 As shown in the simplified monitoring diagram of the pumped storage speed regulation system disclosed in the disclosure, the pumped storage speed regulation system includes a speed regulation device, an external measuring device and a monitoring device. The speed regulation device includes a speed regulator, an actuator and a tachometer. The external measuring device includes a current sensor, a voltage sensor, a temperature sensor, a flow meter, a guide vane opening measuring instrument, a torque measuring instrument and a pressure gauge. The temperature sensor is installed on the stator surface of the turbine generator of the speed regulation system to measure the stator temperature of the generator. , current sensor and voltage sensor are installed at the motor output end of the turbine to measure the motor output current and output voltage , the flow meter is placed in the water flow pipe of the turbine to measure the water flow in the pipe The speed measuring device is installed on the motor rotor to measure the motor speed. , guide vane opening measuring instrument measures the mechanical guide vane opening , The torque measuring instrument is installed on the turbine to measure the turbine torque , the pressure gauge is installed in the turbine pipeline to measure the pipeline pressure .
[0042] Generate the power of the i-th generator , Pipeline water flow , Generator stator temperature , Mechanical guide vane opening , Motor speed , turbine torque , Pipeline pressure As the index data measured by the measuring device in this embodiment, some data are shown in Table 1, which includes a small amount of missing values and abnormal values. The above data are used to realize the stator temperature prediction of the generator of the governor system.
[0043] Table 1. Partial values of various indicator data
[0044] S1. Get the indicator matrix: Define the indicator matrix as , convert various indicator data into the form of indicator matrix, S2. Traverse each element in the indicator matrix, use the mathematical method of limiting the standard deviation to identify outliers and assign them a value of 0: For the indicator matrix , traverse the index matrix elements, , They represent the elements corresponding to the i-th row and j-th column of the indicator matrix and the i-th row and k-th column of the indicator matrix, respectively. , , and i, j, k are all integers; Calculate the standard deviation of the row elements in the indicator matrix. When the standard deviation is greater than the set standard deviation threshold τ, the indicator matrix is considered The element in the i-th row and k-th column of is an abnormal value and is reassigned to 0.
[0045] The indicator matrix The element in the i-th row and k-th column of is an abnormal value and is reassigned to 0, that is, .
[0046] S3, traverse each element in the indicator matrix, find the missing value, fill the missing value with data, and update the indicator matrix; Traversing the indicator matrix Matrix elements of The value of is 0, that is is a missing value, Represents the indicator matrix The element in row i and column a, If satisfied
[0047] or
[0048] Description Indicator Matrix China and Data If the element data in the same row are evenly distributed, the mean method is used to calculate the data. To assign a value: ; If satisfied
[0049] or ; Description Indicator Matrix China and Data The distribution of element data in the same row changes linearly with the increase of usage time, so the median method is used to calculate the data. To assign a value:
[0050] After reassigning the outliers and missing values in the indicator matrix, the updated indicator matrix is obtained, which is recorded as
[0051] .
[0052] S4, build 7 teacher models and obtain different training sets for each teacher model; Knowledge distillation is a method of transferring the knowledge of a large and complex teacher model to a small and simple student model. Seven independent Transformer models are constructed as seven teacher models, denoted as , , , , Each of the above teacher models includes a training set and a test set. In the initial state, the training set and the test set are empty sets. , , , , The corresponding training sets are , , , , ; Set the number of training set elements to at least , the number of test sets is at least ; Delete the 1st, 2nd, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as :
[0053] Delete the 1st, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as :
[0054] Delete the 1st, 5th, and 7th row elements of the indicator matrix, and the resulting matrix is recorded as :
[0055] Delete the elements of the 6th and 7th rows of the indicator matrix, and the resulting matrix is recorded as :
[0056] Delete the 7th row element from the indicator matrix, and the resulting matrix is recorded as :
[0057] Delete the 1st, 2nd, 4th, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as :
[0058] The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The indicator matrix Writing the Teacher Model The training set ; Get the teacher model The number of elements in the training set and For comparison, if the teacher model The number of elements in the training set is greater than or equal to , then go to step S5, if the teacher model The number of elements in the training set is less than , then return to step S1, and execute steps S1, S2, S3, and S4 in sequence.
[0059] S5. Obtain a test set with a specified number of elements for the 7 teacher models; Execute steps S1, S2, and S3 in sequence, and update the indicator matrix in step S3 Write 7 test sets of 7 teacher models and get the teacher model The number of elements in the test set and For comparison, if the teacher model The number of elements in the test set is greater than or equal to , then go to step S6, if the teacher model The number of elements in the test set is less than , then return to step S5 and execute step S5.
[0060] S6, train the teacher model and output soft labels; The 7 teacher models are trained using their corresponding training sets and test sets. The training process is a process of adjusting model parameters with the goal of minimizing the loss function value. The Huber loss function is used as the loss function of the 7 teacher models, and the parameters of the teacher model are optimized accordingly. The Huber loss function formula is:
[0061] in
[0062] is the generator stator temperature data of the element in the i-th row and j-th column of any matrix in the test set, is the prediction data obtained by the teacher model based on the other elements of the matrix for the element in the i-th row and the j-th column. δ is the error hyperparameter, which is used to balance the behavior of the loss function under small prediction errors and large prediction errors. δ is set before the teacher model is used. Setting the loss function change threshold , when the loss function value is less than the loss function change threshold for 20 consecutive times , stop training; Use the 7 trained teacher models to predict the 7 corresponding training sets and generate 7 soft labels; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening and the generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow and generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque and generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power and generator stator temperature at the next moment after prediction output; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power, motor speed and generator stator temperature at the next moment after prediction; Teacher Model Soft label Is a teacher model The probability distribution of the generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power, motor speed, generator stator temperature and pipeline pressure at the next moment of the output is predicted.
[0063] S7. Build a student model, obtain the training set and test set of the student model, and use the seven-branch knowledge distillation method to train the student model Construct an LSTM model as a student model, and correspond to a training set and a test set. The training set of the student model includes the training sets of 7 teacher models and the corresponding output soft labels. The training set of the student model is composed of , the test set of the student model and the teacher model The test set is the same; The formula for calculating distillation loss is defined as
[0064] in, Model for teachers Predicted soft labels, and is an integer, For students, the model is based on The same array Predicted soft labels; The task loss calculation formula is defined as
[0065] in,
[0066] for The generator stator temperature data of the element in the i-th row and j-th column of any 1 matrix, and is an integer, is the predicted data obtained by the student model predicting the elements in the i-th row and j-th column based on the elements of the matrix except the elements in the i-th row and j-th column; Define the comprehensive loss function The expression is:
[0067] In the formula, is the distillation loss, For mission loss, is a weight hyperparameter used to balance the contribution of task loss and distillation loss; The student model is trained using the seven-branch knowledge distillation method. Knowledge distillation is a process of adjusting the parameters of the student model with the goal of minimizing the comprehensive loss function value. The seven-branch knowledge distillation refers to the process of multiple training of the student model through the training sets and soft labels of the seven teacher models, setting the comprehensive loss function threshold, and stopping the training of the student model when the loss function value is less than the comprehensive loss function threshold for 20 consecutive times. The entire training process is as follows Figure 2 shown.
[0068] S8, predicting the stator temperature of the generator using the trained student model; The stator temperature of some speed control system generators and other index data are input into the student model trained by the seven-branch distillation method to predict the stator temperature of the speed control system generator. At the same time, the stator temperature of some speed control system generators and other index data are input into a single LSTM model for prediction. The two prediction results are compared with the actual temperature curve. The prediction effect is as follows: Figure 3 shown.
[0069] Depend on Figure 3 It can be seen that compared with the prediction curve of a single LSTM model, the prediction curve of the student model trained by the seven-branch distillation method is closer to the actual stator temperature curve of the speed control system generator.
[0070] In summary, the student model trained based on the seven-branch distillation method can make more accurate predictions on the generator stator of the speed control system under the premise that the structure is the same as that of the single LSTM model.
[0071] It should be noted that, for the sake of convenience, the aforementioned method embodiments are all expressed as a series of action combinations, but those skilled in the art should know that the present invention is not limited to the described order of actions, because according to the present invention, certain steps can be performed in other orders or simultaneously.
[0072] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0073] The above embodiments are preferred implementation modes of the present invention, but the implementation modes of the present invention are not limited to the above embodiments. Any other changes, modifications, substitutions, combinations, and simplifications that do not deviate from the spirit and principles of the present invention should be equivalent replacement methods and are included in the protection scope of the present invention.
Claims
1. A pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation is applied to a pumped storage speed regulation system, which includes a speed regulation device, an external measuring device and a monitoring device. The speed regulation device includes a speed regulator, an actuator and a tachometer. The external measuring device includes a current sensor, a voltage sensor, a temperature sensor, a flow meter, a guide vane opening measuring instrument, a torque measuring instrument and a pressure gauge. The temperature sensor is installed on the stator surface of the turbine generator in the speed control system to measure the stator temperature of the generator. , current sensor and voltage sensor are installed at the motor output end of the turbine to measure the motor output current and output voltage , the flow meter is placed in the water flow pipe of the turbine to measure the water flow in the pipe The speed measuring device is installed on the motor rotor to measure the motor speed. , guide vane opening measuring instrument measures the mechanical guide vane opening , The torque measuring instrument is installed on the turbine to measure the turbine torque , the pressure gauge is installed in the turbine pipeline to measure the pipeline pressure ; Characterized in that the temperature prediction method comprises the following steps: S1. Obtain the time series data of the detection index of the speed control system of the pumped storage power station to form an index matrix; S2, traverse each element in the indicator matrix, use the mathematical method of limiting the standard deviation to identify outliers and assign them a value of 0; S3, traverse each element in the indicator matrix, find the missing value, fill the missing value with data, and update the indicator matrix; S4, build 7 teacher models and obtain different training sets for each teacher model; S5. Obtain a test set with a specified number of elements for the 7 teacher models; S6, train the teacher model and output soft labels; S7, build a student model, obtain the training set and test set of the student model, and use the seven-branch knowledge distillation method to train the student model; S8. Use the trained student model to predict the generator stator temperature.
2. The pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation according to claim 1 is characterized in that: The process of step S1 is as follows: The time series data of the detection indicators are obtained through the external measuring device, and the detection indicators include the generator power , Pipeline water flow , Generator stator temperature , Mechanical guide vane opening , Motor speed , turbine torque , Pipeline pressure , where the generator power is determined by the turbine motor output current and output voltage Multiplying them together, ; The measurement interval of the additional measuring device is one hour. It represents the generator power value corresponding to the i-th measurement time measured on that day, and is an integer, , It represents the pipeline water flow value, generator stator temperature value, mechanical guide vane opening value, motor speed value, turbine torque and pipeline pressure value corresponding to the i-th measurement time measured on that day; Define the indicator matrix as , and obtain the index torque.
3. The pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation according to claim 2 is characterized in that: The process of step S2 is as follows: For the indicator matrix , traverse the index matrix elements, , They represent the elements corresponding to the i-th row and j-th column of the indicator matrix and the i-th row and k-th column of the indicator matrix, respectively. , , and i, j, k are all integers; Calculate the standard deviation of the row elements in the indicator matrix. When the standard deviation is greater than the set standard deviation threshold τ, the indicator matrix is considered The element in the i-th row and k-th column of is an abnormal value and is reassigned to 0. The indicator matrix The element in the i-th row and k-th column of is an abnormal value and is reassigned to 0, that is, 。 4. The pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation according to claim 3 is characterized in that: The process of step S3 is as follows: Traversing the indicator matrix Matrix elements of The value of is 0, that is is a missing value, Represents the indicator matrix The element in row i and column a, If satisfied or Description Indicator Matrix China and Data If the element data in the same row are evenly distributed, the mean method is used to calculate the data. To assign a value: ; If satisfied or ; Description Indicator Matrix China and Data The distribution of element data in the same row changes linearly with the increase of usage time, so the median method is used to calculate the data. To assign a value: After reassigning the outliers and missing values in the indicator matrix, the updated indicator matrix is obtained, which is recorded as 。 5. The pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation according to claim 4 is characterized in that: The process of step S4 is as follows: Construct 7 independent Transformer models as 7 teacher models, respectively denoted as , , , , Each of the above teacher models includes a training set and a test set. In the initial state, the training set and the test set are empty sets. , , , , The corresponding training sets are , , , , ; Set the number of training set elements to at least , the number of test sets is at least ; Delete the 1st, 2nd, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as : Delete the 1st, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as : Delete the 1st, 5th, and 7th row elements of the indicator matrix, and the resulting matrix is recorded as : Delete the 6th and 7th row elements of the indicator matrix, and the resulting matrix is recorded as : Delete the 7th row element from the indicator matrix, and the resulting matrix is recorded as : Delete the 1st, 2nd, 4th, 5th, 6th, and 7th row elements from the indicator matrix, and the resulting matrix is recorded as : The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The matrix Writing the Teacher Model The training set ; The indicator matrix Writing the Teacher Model The training set ; Get the teacher model The number of elements in the training set and For comparison, if the teacher model The number of elements in the training set is greater than or equal to , then go to step S5, if the teacher model The number of elements in the training set is less than , then return to step S1, and execute steps S1, S2, S3, and S4 in sequence.
6. The pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation according to claim 5 is characterized in that: The process of step S5 is as follows: Execute steps S1, S2, and S3 in sequence, and update the indicator matrix in step S3 Write 7 test sets of 7 teacher models and get the teacher model The number of elements in the test set and For comparison, if the teacher model The number of elements in the test set is greater than or equal to , then go to step S6, if the teacher model The number of elements in the test set is less than , then return to step S5 and execute step S5.
7. The pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation according to claim 6 is characterized in that: The process of step S6 is as follows: The 7 teacher models are trained using their corresponding training sets and test sets. The training process is a process of adjusting model parameters with the goal of minimizing the loss function value. The Huber loss function is used as the loss function of the 7 teacher models, and the parameters of the teacher model are optimized accordingly. The Huber loss function formula is: in is the generator stator temperature data of the element in the i-th row and j-th column of any matrix in the test set, is the prediction data obtained by the teacher model based on the other elements of the matrix for the element in the i-th row and the j-th column. δ is the error hyperparameter, which is used to balance the behavior of the loss function under small prediction errors and large prediction errors. δ is set before the teacher model is used. Setting the loss function change threshold , when the loss function value is less than the loss function change threshold for 20 consecutive times , stop training; Use the 7 trained teacher models to predict the 7 corresponding training sets and generate 7 soft labels; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening and the generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow and generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque and generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power and generator stator temperature at the next moment after prediction output; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power, motor speed and generator stator temperature at the next moment after prediction; Teacher Model Soft label Is a teacher model The probability distribution of the generator stator temperature at the next moment output after prediction; Teacher Model Soft label Is a teacher model The joint probability distribution of the mechanical guide vane opening, pipeline water flow, turbine torque, motor output power, motor speed, generator stator temperature and pipeline pressure at the next moment of the output is predicted.
8. The pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation according to claim 7 is characterized in that: The process of step S7 is as follows: Construct an LSTM model as a student model, and correspond to a training set and a test set. The training set of the student model includes the training sets of 7 teacher models and the corresponding output soft labels. The training set of the student model is composed of , the test set of the student model and the teacher model The test set is the same; The formula for calculating distillation loss is defined as in, Model for teachers Predicted soft labels, and is an integer, For students, the model is based on The same array Predicted soft labels; The task loss calculation formula is defined as in, for The generator stator temperature data of the element in the i-th row and j-th column of any 1 matrix, and is an integer, is the predicted data obtained by the student model predicting the elements in the i-th row and j-th column based on the elements of the matrix except the elements in the i-th row and j-th column; Define the comprehensive loss function The expression is: In the formula, is the distillation loss, For mission loss, is a weight hyperparameter used to balance the contribution of task loss and distillation loss; The student model is trained using the seven-branch knowledge distillation method. Knowledge distillation is a process of adjusting the student model parameters with the goal of minimizing the comprehensive loss function value. Seven-branch knowledge distillation refers to the process of multiple training of the student model using the training sets and soft labels of seven teacher models, setting a comprehensive loss function threshold, and stopping the training of the student model when the loss function value is less than the comprehensive loss function threshold for 20 consecutive times.
9. The pumped storage motor stator temperature prediction method based on seven-branch knowledge distillation according to claim 8 is characterized in that: The process of step S8 is as follows: The trained student model is applied to the monitoring device, which is connected to the speed regulating device and the external measuring device. The speed regulating device includes a speed regulator, an actuator and a tachometer. The external measuring device includes a current sensor, a voltage sensor, a temperature sensor, a flow meter, a guide vane opening measuring instrument, a torque measuring instrument and a pressure gauge. The temperature sensor is installed on the surface of the speed regulating device to measure the stator temperature of the generator. , current sensor and voltage sensor are installed at the motor output end of the turbine to measure the motor output current and output voltage , the flow meter is placed in the water flow pipe of the turbine to measure the water flow in the pipe The speed measuring device is installed on the motor rotor to measure the motor speed. , guide vane opening measuring instrument measures the mechanical guide vane opening , The torque measuring instrument is installed on the turbine to measure the turbine torque , the pressure gauge is installed in the turbine pipeline to measure the pipeline pressure The above data are transmitted to the monitoring system through the speed control device and the external measuring device. The monitoring device inputs the above data into the trained student model, and the trained student model outputs the prediction result of the generator stator temperature.
Citation Information
Patent Citations
Fan variable pitch motor temperature fault early warning method based on collaborative expression and LightGBM algorithm
CN112598148A
Tile color difference detection method and device based on knowledge distillation
CN113554716A
Method and device for predicting temperatures of multiple areas of building and medium
CN116629133A
Industrial image anomaly detection method and system based on knowledge distillation
CN117036266A