Motor fault detection method and device and storage medium

By comprehensively using the predicted branch model and the reconstruction branch model to process the target status data of the motor, the problem of inaccurate motor fault detection in the prior art is solved, the accuracy of fault detection is improved, and the timely maintenance and driving safety of the motor are ensured.

CN120067927APending Publication Date: 2025-05-30ZHEJIANG LEAPPOWER TECH CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411979067.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-30
Publication Date
2025-05-30

AI Technical Summary

Technical Problem

The existing technology is difficult to accurately detect the failure of new energy vehicle motors, which affects the normal driving of the car and may endanger life safety.

Method used

The motor fault detection method is adopted, by obtaining the target state data of the motor, using the predicted branch model and the reconstruction branch model to process the data, obtain the first and second detection results, and combine these results to determine whether there is a real fault in the motor.

Benefits of technology

It improves the accuracy of motor fault detection, avoids fault detection errors caused by errors in single output results, and ensures timely maintenance and driving safety of the motor.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120067927A_ABST
    Figure CN120067927A_ABST
Patent Text Reader

Abstract

The invention discloses a motor fault detection method and device, and a storage medium. The method comprises the steps of obtaining target state data of a motor in a current operation time period; processing the target state data by using a motor fault detection model to obtain a first detection result and a second detection result of the motor; the first detection result and the second detection result are obtained by processing different task branch models of the motor fault detection model; determining a target detection result of the motor based on the first detection result and the second detection result; the target judgment result is used for representing whether the motor has a real fault. In this way, the accuracy of fault detection can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of intelligent detection technology, and in particular, to a method, device, and storage medium for motor fault detection. Background Art

[0002] As one of the core components of new energy vehicles, the performance of the motor directly affects the overall performance of new energy vehicles. During the operation of the motor, due to various factors such as overload, overheat, and demagnetization, various faults are likely to occur. Once a motor fails, it will not only affect the normal driving of new energy vehicles, but may even endanger the lives of drivers and passengers. Therefore, it is particularly important to perform timely and accurate fault warning and diagnosis on the motors of new energy vehicles. Summary of the Invention

[0003] The main technical problem to be solved by this application is to provide a method, device, and storage medium for motor fault detection, which can improve the accuracy of fault detection.

[0004] To solve the above technical problem, a technical solution adopted by this application is: to provide a method for motor fault detection, the method includes: obtaining target state data of the motor in the current operation time period; using a motor fault detection model to process the target state data to obtain a first detection result and a second detection result of the motor; the first detection result and the second detection result are obtained by processing using different task branch models of the motor fault detection model; based on the first detection result and the second detection result, determining the target detection result of the motor; the target judgment result is used to represent whether there is a real fault in the motor.

[0005] Among them, the motor fault detection model includes a prediction branch model and a reconstruction branch model, and the target state data includes first state data at a plurality of first time points and second state data at at least one second time point; using the motor fault detection model to process the target state data to obtain a first detection result and a second detection result of the motor includes: using the prediction branch model to predict based on the first state data at a plurality of first time points to obtain predicted state data of the motor at at least one second time point, and using the reconstruction branch model to perform state reconstruction based on the target state data to obtain reconstructed state data of the motor in the current operation time period; determining the first detection result based on a first difference between the predicted state data and the second state data, and determining the second detection result based on a second difference between the reconstructed state data and the target state data.

[0006] Among them, both the first detection result and the second detection result are used to characterize whether the target state data of the motor is abnormal; determining the first detection result based on the first difference between the predicted state data and the second state data includes: in response to the first difference being not less than the first preset difference, determining that the target state data of the motor is abnormal; determining the second detection result based on the second difference between the reconstructed state data and the target state data includes: in response to the second difference being not less than the second preset difference, determining that the target state data of the motor is abnormal.

[0007] Among them, determining the target detection result of the motor based on the first detection result and the second detection result includes: in response to both the first detection result and the second detection result characterizing that the target state data of the motor is abnormal, determining that the motor has a real fault.

[0008] Among them, the motor fault detection model further includes an encoder, and the encoder is used to extract features from the target state data to obtain corresponding target state features; the predicted state data is obtained by prediction using the prediction branch model based on the state features corresponding to the first state data in the target state features; the reconstructed state data is obtained by data reconstruction using the reconstruction branch model based on the target state features.

[0009] Among them, the target state data includes state data of at least two of the following dimensions: motor D-axis current, motor D-axis voltage, motor Q-axis current, motor Q-axis voltage, motor speed, motor feedback torque, motor controller temperature, and motor inlet temperature; the encoder includes an attention layer and a feedforward network layer, and the attention layer is used to perform attention processing on the target state features to obtain attention data regarding the state data of different dimensions; the feedforward network layer includes a first convolutional layer and a second convolutional layer.

[0010] Among them, obtaining the target state data of the motor during the current operation period includes: respectively using the operation data of each sub-period in the preset period of the motor as the target state data of the motor during the current operation period; determining the target detection result of the motor based on the first detection result and the second detection result further includes: determining the fault detection result of the motor during the current operation period based on the first detection result and the second detection result; comprehensively determining the target detection result of the motor based on the fault detection results of each sub-period in the preset period.

[0011] Among them, both the first detection result and the second detection result are used to characterize whether the target state data of the motor is abnormal; based on the first detection result and the second detection result, determining the fault detection result of the motor in the current operation time period includes: in response to at least one of the first detection result and the second detection result characterizing that the target state data of the motor is abnormal, determining that there is a candidate fault in the motor in the current operation time period; comprehensively determining the target detection result of the motor based on the fault detection results of each sub-time period in a preset time period, including: based on the fault detection results of the motor in each sub-time period, counting the number of sub-time periods that are candidate faults in the preset time period; determining the ratio between the number of sub-time periods that are candidate faults and the total number of sub-time periods in the preset time period; in response to the ratio being not less than a preset ratio, determining that there is a real fault in the motor in the preset time period.

[0012] Among them, the motor fault detection model includes a prediction branch model and a reconstruction branch model; the method further includes: using the normal state data corresponding to the motor in a plurality of historical operation time periods as sample data; the sample data includes the first sample states at a plurality of first sample time points and the second sample states at at least one second sample time point; for the sample data of each historical operation time period, using the prediction branch model to make a prediction based on the first sample states at a plurality of first sample time points to obtain the sample prediction states of the motor at at least one second sample time point, and using the reconstruction branch model to perform data reconstruction based on the sample data to obtain sample reconstructed data; obtaining a comprehensive difference by combining the first difference and the second difference; the first difference is the difference between the sample prediction state and the second sample state, and the second difference is the difference between the sample reconstructed data and the sample data; adjusting the network parameters of the motor fault detection model based on the comprehensive difference.

[0013] To solve the above technical problems, another technical solution adopted by this application is: providing an electronic device, including a memory and a processor that are mutually coupled, the memory stores program instructions; the processor is used to execute the program instructions stored in the memory to implement the above method.

[0014] To solve the above technical problems, another technical solution adopted by this application is: providing a computer-readable storage medium for storing program instructions, and the program instructions can be executed to implement the above method.

[0015] In the above solution, by using the motor fault detection model to process the target state data of the motor in the current operation period, the detection results obtained by different task branch models can be obtained. Then, based on the detection results obtained by different task branch models, the target detection result of the motor is determined. Compared with the method of only performing fault detection according to the result output by a single-task model, the method of comprehensively performing fault detection based on the results output by different task branch models in this application can avoid the situation where the fault detection is incorrect due to an incorrect single output result, and can improve the accuracy of fault detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] Figure 1 is a schematic flowchart of an embodiment of the motor fault detection method provided by this application;

[0017] Figure 2 is Figure 1 a schematic flowchart of an embodiment of step S12 shown;

[0018] Figure 3 is Figure 1 a schematic flowchart of an embodiment of step S13 shown;

[0019] Figure 4 is a schematic flowchart of an embodiment of training the motor fault detection model provided by this application;

[0020] Figure 5 is a schematic framework diagram of an embodiment of the motor fault detection device provided by this application;

[0021] Figure 6 is a schematic framework diagram of an embodiment of the electronic device provided by this application;

[0022] Figure 7 is a schematic framework diagram of the computer-readable storage medium provided by this application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0023] To make the objectives, technical solutions, and effects of this application clearer and more definite, the following further describes this application in detail with reference to the accompanying drawings and by way of examples.

[0024] In addition, if there are descriptions involving "first", "second", etc. in the embodiments of this application, the descriptions of "first", "second", etc. are only for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the quantity of the indicated technical features. Thus, the features defined with "first" and "second" may explicitly or implicitly include at least one such feature. In addition, the technical solutions between various embodiments can be combined with each other, but it must be based on the fact that those skilled in the art can implement them. When the combination of technical solutions results in contradictions or cannot be implemented, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection required by this application.

[0025] Please refer to Figure 1 , Figure 1 which is a schematic flowchart of an embodiment of the motor fault detection method provided by this application. It should be noted that if there are substantially the same results, this embodiment is not limited to Figure 1 the process sequence shown. As Figure 1 shown, this embodiment includes:

[0026] S11: Obtain the target state data of the motor in the current operating period.

[0027] The motor in this embodiment can be any type of motor, and can be, but is not limited to, a permanent magnet synchronous motor. The target state data of the motor includes state data of at least the following two dimensions: motor D-axis current, motor D-axis voltage, motor Q-axis current, motor Q-axis voltage, motor speed, motor feedback torque, motor controller temperature, and motor inlet temperature. Among them, the state data of each dimension can be detected by relevant sensors.

[0028] In an implementation scenario, the state data of the motor in the current operating period obtained in real time can be used as the target state data of the motor in the current operating period to perform real-time motor fault detection.

[0029] In another implementation scenario, in order to count the abnormal conditions of the operation state data corresponding to each sub-period decomposition of the motor in a preset period (such as 1 day, or half a day, or two days, etc.), the operation state data of the motor in each sub-period in the preset period can be used as the target state data of the current operating period respectively. Exemplarily, the operation data of the motor in each sub-period in the preset period can be sequentially used as the target state data of the current operating period of the motor according to the time sequence; of course, regardless of the order of each sub-period, the operation data of each sub-period can be used as the target state data of the current operating period respectively. This implementation scenario is used for fault detection using the operation state data of the motor in multiple sub-periods in the preset period.

[0030] S12: Process the target state data using the motor fault detection model to obtain the first detection result and the second detection result of the motor; the first detection result and the second detection result are obtained by processing using different task branch models of the motor fault detection model.

[0031] In this embodiment, the motor fault detection model includes a prediction branch model and a reconstruction branch model. The target state data is processed by the prediction branch model and the reconstruction branch model respectively to obtain the first detection result and the second detection result of the motor. Among them, the current operation time period includes a plurality of time points arranged in sequence, specifically including a plurality of first time points located in front of the current operation time period and at least one second time point behind the first time point. For the convenience of distinction, the state data of the motor at each first time point is called the first state data, and the state data of the motor at each second time point is called the second state data. For example, if the current operation time period is 64 seconds, the state data from the 1st to the 63rd second is called the first state data at each first time point, and the state data at the 64th second is called the second state data at the second time point.

[0032] Among them, the prediction branch model is used to predict the state data under normal conditions at the second time point by using the first state data at a plurality of first time points. For the convenience of distinction, the predicted state data is called the prediction state data. The reconstruction branch model is used to reconstruct the state data under normal conditions by using the entire target state data in the current operation time period. For the convenience of distinction, the reconstructed state data is called the reconstruction state data.

[0033] Specifically, please refer to Figure 2 , Figure 2 is Figure 1 a schematic flowchart of an embodiment of step S12 shown. In this embodiment, step S12 further includes:

[0034] S21: Use the prediction branch model to predict based on the first state data at a plurality of first time points to obtain the prediction state data of the motor at at least one second time point, and use the reconstruction branch model to perform state reconstruction based on the target state data to obtain the reconstruction state data of the motor in the current operation time period.

[0035] S22: Determine the first detection result based on the first difference between the prediction state data and the second state data, and determine the second detection result based on the second difference between the reconstruction state data and the target state data.

[0036] In this embodiment, the target state data may be abnormal state data of the motor in the case of a fault, or may be normal state data of the motor in the normal operation state; the motor fault detection model is trained by using the normal state data of the motor in a plurality of historical operation time periods, and the output data of the prediction branch model and the reconstruction branch model in the motor fault detection model are both state data corresponding to the normal operation of the motor. Therefore, in this embodiment, the first detection result can be determined according to the first difference between the prediction state data and the second state data, and the second detection result can be determined based on the second difference between the reconstruction state data and the target state data.

[0037] Among them, if the first difference between the predicted state data and the second state data is not less than the first preset difference, it indicates that the difference between the second state data and the normal predicted state data is large, and it can be determined that the target state data of the motor is abnormal. Similarly, if the second difference between the target state data and the normal reconstructed state data is not less than the second preset difference, it indicates that the difference between the target state data and the normal reconstructed state data is large, and it can be determined that the target state data of the motor is abnormal.

[0038] In some embodiments, the motor fault detection model further includes an encoder, which is used to extract features from the target state data to obtain corresponding target state features. In this embodiment, the predicted state data is predicted by using a prediction branch model based on the state features corresponding to the first state data in the target state features; the reconstructed state data is obtained by using a reconstruction branch model to reconstruct the data based on the target state features.

[0039] In some embodiments, the motor fault detection model is a network model with a Transformer architecture, and the encoding layer includes an attention layer and a feed-forward network layer.

[0040] Among them, the attention layer is used to automatically learn the weights and correlations between different-dimensional data collected by different sensors by using the attention mechanism, and to capture long-distance dependencies through the self-attention mechanism. Exemplarily, the attention layer is used to perform attention processing on the target state features to obtain attention data regarding the state data of different dimensions.

[0041] In this embodiment, the feed-forward network layer uses lightweight one-dimensional convolution to replace the traditional fully connected layer to reduce the overall number of parameters of the model. Among them, the feed-forward network layer includes a first convolutional layer and a second convolutional layer. The first convolutional layer is used to increase the number of channels of the features output by the attention layer from n to 2n, and the second convolutional layer is used to reduce the number of channels from 2n back to n to maintain channel consistency.

[0042] S13: Based on the first detection result and the second detection result, determine the target detection result of the motor; the target judgment result is used to represent whether the motor has a real fault.

[0043] Among them, both the first detection result and the second detection result are used to represent whether the target state data of the motor is abnormal.

[0044] In one embodiment, if both the first detection result and the second detection result in the current operating time period represent that the target state data of the motor is abnormal, it is determined that the motor has a real fault. That is, in this embodiment, only when both the first detection result and the second detection result represent that the target state data of the motor is abnormal can it be determined that the motor really has a fault.

[0045] If only one of the first detection result and the second detection result indicates that the target state data of the motor is abnormal, it is possible that the motor actually has a fault, or it is also possible that the motor is normal, but only one of the detection results is incorrect. That is, in this case, it is impossible to accurately determine whether the motor actually has a fault. To improve the accuracy of fault detection, further, the target state data corresponding to the motor in multiple operation time periods can be combined to determine whether the motor actually has a fault.

[0046] Of course, in other embodiments, to further improve the accuracy of fault detection, when both the first detection result and the second detection result in the current operation time period indicate that the target state data of the motor is abnormal, it is confirmed that the target state data in the current operation time period is a segment where the motor may have a fault, and then the number of fault segments in a preset time period (for example, within 1 day) is counted. According to the statistical number of fault segments in the preset time period, it is determined whether the motor has a real fault.

[0047] Specifically, please refer to Figure 3 , Figure 3 Yes Figure 1 is a schematic flowchart of an embodiment of step S13 shown in. In this embodiment, step S13 further includes:

[0048] S31: Based on the first detection result and the second detection result, determine the fault detection result of the motor in the current operation time period.

[0049] In this embodiment, both the first detection result and the second detection result are used to indicate whether the target state data of the motor is abnormal. If at least one of the first detection result and the second detection result indicates that the target state data of the motor is abnormal, first determine that there is a candidate fault in the current operation time period of the motor, and then further determine whether the motor actually has a fault through step S32.

[0050] S32: Synthesize the fault detection results of each sub - time period of the motor in the preset time period to determine the target detection result of the motor.

[0051] In this embodiment, first, based on the fault detection results of the motor in each sub - time period, count the number of sub - time periods that are candidate faults in the preset time period; then determine the ratio between the number of sub - time periods that are candidate faults and the total number of sub - time periods in the preset time period; if the ratio is not less than the preset ratio, it is determined that there is a real fault in the preset time period of the motor. The specific preset ratio can be preset according to experience.

[0052] In the above solution, by using the motor fault detection model to process the target state data of the motor in the current operating time period, the detection results obtained by different task branch models can be obtained. Then, based on the detection results obtained by different task branch models, the target detection result of the motor is determined. Compared with the method of performing fault detection only according to the results output by a single-task model, the method of performing fault detection by integrating the results output by different task branch models in this application can avoid the situation where the fault detection is incorrect due to an incorrect single output result, and can improve the accuracy of fault detection.

[0053] In some embodiments, before using the motor fault detection model to perform motor fault detection, the motor fault detection model needs to be trained. Among them, the motor fault detection model is obtained by training the motor fault detection model with the normal state data corresponding to several historical operating time periods as sample data.

[0054] Specifically, please refer to Figure 4 , Figure 4 which is a schematic flowchart of an embodiment for training the motor fault detection model provided by this application. This embodiment includes:

[0055] S41: Use the normal state data corresponding to the motor in several historical operating time periods as sample data; the sample data includes the first sample states at several first sample time points and the second sample states at at least one second sample time point.

[0056] S42: For the sample data of each historical operating time period, use the prediction branch model to predict based on the first sample states at several first sample time points to obtain the sample prediction states of the motor at at least one second sample time point, and use the reconstruction branch model to perform data reconstruction based on the sample data to obtain the sample reconstruction data.

[0057] S43: Obtain the comprehensive difference by integrating the first difference and the second difference; the first difference is the difference between the sample prediction state and the second sample state, and the second difference is the difference between the sample reconstruction data and the sample data.

[0058] S44: Adjust the network parameters of the motor fault detection model based on the comprehensive difference.

[0059] Exemplarily, the operating state data of the motor during normal operation, that is, the normal state data, can be extracted from the database. Among them, each piece of extracted normal state data includes the state data of at least the following two dimensions: motor D-axis current, motor D-axis voltage, motor Q-axis current, motor Q-axis voltage, motor speed, motor feedback torque, motor controller temperature, and motor inlet temperature. The data of each dimension are key parameters inside the motor.

[0060] Deduplicate the extracted normal - state data, clean the missing values and / or outliers, and then standardize the data. After data standardization, the processed normal - state data is obtained.

[0061]

[0062] Among them, \(x\) represents the processed normal - state data, \(u\) represents the mean of the normal - state data, and \(\sigma\) represents the standard deviation of the normal - state data.

[0063] Subsequently, use a preset time window to divide the processed normal - state data into continuous driving segments, and use the state data of the driving segments corresponding to each time window as sample data.

[0064] In a specific embodiment, each preset time window contains 63 time points, and the state data of each time point includes 8 different - dimensional state data: motor D - axis current, motor D - axis voltage, motor Q - axis current, motor Q - axis voltage, motor speed, motor feedback torque, motor controller temperature, and motor inlet temperature. And the data of each time window is a sample data; that is, each sample data includes the above - mentioned 8 - dimensional data of 63 time points, for example, a matrix of \((63,8)\) or \((8,63)\).

[0065] In an embodiment, the motor fault - detection model includes a prediction - branch model and a reconstruction - branch model. In this embodiment, each sample data includes the first - sample state of several first - sample time points and the second - sample state of at least one second - sample time point. For the sample data of each historical operation time period, use the prediction - branch model to make a prediction based on the first - sample state of several first - sample time points to obtain the sample - predicted state of the motor regarding at least one second - sample time point, and use the reconstruction - branch model to perform data reconstruction based on the sample data to obtain the sample - reconstructed data.

[0066] Exemplarily, taking the above - mentioned each sample data including the 8 - dimensional data corresponding to 63 time points as an example, use the prediction - branch model to predict the data of at least one dimension corresponding to the 63rd time point based on the 8 - dimensional data corresponding to the first 62 time points. For example, predict the motor inlet temperature at the 63rd time point, or predict the data of each dimension at the 63rd time point; in addition, use the reconstruction - branch model to perform data reconstruction based on the 8 - dimensional data corresponding to 63 time points to obtain the sample - reconstructed data.

[0067] Among them, for the prediction branch model, among the data of 8 dimensions corresponding to 63 time points respectively, the data of 8 dimensions corresponding to the first 62 time points are used as input data, and the data of at least one dimension corresponding to the 63rd time point are used as labels; for the reconstruction branch model, the data of 8 dimensions corresponding to 63 time points are used as input data and labels respectively.

[0068] Therefore, in this embodiment, after obtaining the sample prediction state output by the prediction branch model and the sample reconstruction data output by the reconstruction branch model, the first difference between the sample prediction state and the second sample state is obtained, and the second difference between the sample reconstruction data and the sample data is obtained. Then, the first difference and the second difference are combined to obtain a comprehensive difference, and based on the comprehensive difference, the network parameters of the motor fault detection model are adjusted until the model converges.

[0069] Among them, the combination of the first difference and the second difference to obtain the comprehensive difference is expressed as follows:

[0070] loss = α * loss pred + β * loss recon

[0071] Among them, loss is the comprehensive difference, loss pred is the first difference, loss recon is the second difference, and α and β are the weights corresponding to the first difference and the second difference respectively.

[0072] In one embodiment, β > α. In a specific embodiment, α = 0.3 and β = 0.7.

[0073] Among them, the first difference and the second difference can be but are not limited to mean square error, and can also be mean absolute error, or Huber loss, etc. In this embodiment, by adjusting the network parameters of the motor fault detection model through the losses (differences) of the two task branches, the motor fault detection model can learn more general feature representations and further reduce the risk of overfitting.

[0074] In a specific embodiment, training hyperparameters also need to be set. Among them, the optimizer can use the adaptive matrix estimation optimizer with weight decay (AdamW), and adaptively adjust the learning rate of model training. The initial learning rate is set to lr = 0.001. The batch size loaded each iteration is batchsize = 256. The total number of training epochs is set to epochs = 300. To prevent overfitting, an early stopping strategy is used, and training is stopped when the training set loss no longer decreases within 10 epochs, and the optimal model is saved.

[0075] The above - set hyperparameters are only for illustration and should not limit the protection scope of this application.

[0076] In a specific embodiment, the motor fault detection model includes an encoder. The encoder includes a feature mapping layer, an attention layer, a normalization layer, and a feed-forward network layer. To facilitate the attention layer in capturing the correlation between data in multiple dimensions and learning non-linear representations, the above-mentioned matrix of (8, 63) can be used as sample data and input into the encoder. First, the input matrix is transformed by the feature mapping layer to obtain corresponding feature vectors. Then, the attention layer performs attention processing on the feature vectors to obtain attention data of state data in different dimensions. Next, the normalization layer normalizes the attention data to obtain normalized attention data. Finally, the feed-forward network layer processes the data to obtain sample features.

[0077] Among them, the obtained attention data is expressed as follows:

[0078]

[0079] Among them, the query matrix (Q), the key matrix (K), and the value matrix (V) are obtained by mapping the feature vectors, and Attention(Q, K, V) represents the attention data.

[0080] Furthermore, the prediction branch model predicts the sample prediction state based on the sample features, and the reconstruction branch model reconstructs the sample reconstruction data based on the sample features.

[0081] Among them, the applicant of this application found in the fault detection experiment using the normal operation data of 2000 normal motors and the abnormal operation data of 81 faulty motors that the accuracy rates of only training the prediction branch model and only using the output results of the prediction branch model for fault detection are as follows: the accuracy rate for normal motor data is 85.3%, and the accuracy rate for faulty motor data is 86.4%; the accuracy rates of only training the reconstruction branch model and only using the output results of the reconstruction branch model for fault detection are as follows: the accuracy rate for normal motor data is 87.5%, and the accuracy rate for faulty motor data is 80.2%; the accuracy rates of jointly training the prediction branch model and the reconstruction branch model and using the output results of the prediction branch model and the reconstruction branch model for fault detection are as follows: the accuracy rate for normal motor data is 99.6%, and the accuracy rate for faulty motor data is 98.7%. It can be seen that the accuracy rate of jointly training the prediction branch model and the reconstruction branch model and using the output results of the prediction branch model and the reconstruction branch model for fault detection is significantly improved.

[0082] Please refer to Figure 5 , Figure 5It is a schematic framework diagram of an embodiment of the motor fault detection device provided by this application. In this embodiment, the motor fault detection device 50 includes an acquisition module 51, a processing module 52, and a determination module 53. Among them, the acquisition module 51 is used to acquire the target state data of the motor during the current operation period; the processing module 52 processes the target state data by using the motor fault detection model to obtain the first detection result and the second detection result of the motor; the first detection result and the second detection result are obtained by processing with different task branch models of the motor fault detection model; the determination module 53 determines the target detection result of the motor based on the first detection result and the second detection result; the target judgment result is used to characterize whether there is a real fault in the motor.

[0083] Among them, the motor fault detection model includes a prediction branch model and a reconstruction branch model, and the target state data includes the first state data at a plurality of first time points and the second state data at at least one second time point; the processing module 52 processes the target state data by using the motor fault detection model to obtain the first detection result and the second detection result of the motor, including: using the prediction branch model to predict based on the first state data at a plurality of first time points to obtain the predicted state data of the motor about at least one second time point, and using the reconstruction branch model to perform state reconstruction based on the target state data to obtain the reconstructed state data of the motor during the current operation period; determining the first detection result based on the first difference between the predicted state data and the second state data, and determining the second detection result based on the second difference between the reconstructed state data and the target state data.

[0084] Among them, both the first detection result and the second detection result are used to characterize whether the target state data of the motor is abnormal; determining the first detection result based on the first difference between the predicted state data and the second state data includes: in response to the first difference being not less than the first preset difference, determining that the target state data of the motor is abnormal; determining the second detection result based on the second difference between the reconstructed state data and the target state data includes: in response to the second difference being not less than the second preset difference, determining that the target state data of the motor is abnormal.

[0085] Among them, the determination module 53 determines the target detection result of the motor based on the first detection result and the second detection result, including: in response to both the first detection result and the second detection result indicating that the target state data of the motor is abnormal, determining that the motor has a real fault.

[0086] Among them, the motor fault detection model further includes an encoder, and the encoder is used to extract features from the target state data to obtain the corresponding target state features; the predicted state data is obtained by using the prediction branch model to predict based on the state features corresponding to the first state data in the target state features; the reconstructed state data is obtained by using the reconstruction branch model to perform data reconstruction based on the target state features.

[0087] Among them, the target status data obtained by the acquisition module 51 includes status data of at least the following two dimensions: motor D-axis current, motor D-axis voltage, motor Q-axis current, motor Q-axis voltage, motor speed, motor feedback torque, motor controller temperature, and motor inlet temperature; the encoder includes an attention layer and a feed-forward network layer. The attention layer is used to perform attention processing on the target status features to obtain attention data regarding the status data of different dimensions; the feed-forward network layer includes a first convolutional layer and a second convolutional layer.

[0088] Among them, the acquisition module 51 obtains the target status data of the current operation period of the motor, including: respectively taking the operation data of each sub-period in the preset period of the motor as the target status data of the current operation period of the motor; the determination module 53 determines the target detection result of the motor based on the first detection result and the second detection result, and further includes: determining the fault detection result of the motor in the current operation period based on the first detection result and the second detection result; comprehensively determining the target detection result of the motor based on the fault detection results of each sub-period in the preset period.

[0089] Among them, both the first detection result and the second detection result are used to characterize whether the target status data of the motor is abnormal; determining the fault detection result of the motor in the current operation period based on the first detection result and the second detection result includes: in response to at least one of the first detection result and the second detection result characterizing that the target status data of the motor is abnormal, determining that there is a candidate fault in the current operation period of the motor; comprehensively determining the target detection result of the motor based on the fault detection results of each sub-period in the preset period includes: based on the fault detection results of the motor in each sub-period, counting the number of sub-periods that are candidate faults in the preset period; determining the ratio between the number of sub-periods that are candidate faults and the total number of sub-periods in the preset period; in response to the ratio being not less than the preset ratio, determining that there is a real fault in the preset period of the motor.

[0090] Among them, the motor fault detection model includes a prediction branch model and a reconstruction branch model; the method further includes: using the normal state data corresponding to the motor in several historical operation time periods as sample data; the sample data includes the first sample states at several first sample time points and the second sample states at at least one second sample time point; for the sample data of each historical operation time period, using the prediction branch model to make a prediction based on the first sample states at several first sample time points to obtain the sample prediction states of the motor at at least one second sample time point, and using the reconstruction branch model to perform data reconstruction based on the sample data to obtain sample reconstructed data; obtaining a comprehensive difference by synthesizing the first difference and the second difference; the first difference is the difference between the sample prediction state and the second sample state, and the second difference is the difference between the sample reconstructed data and the sample data; adjusting the network parameters of the motor fault detection model based on the comprehensive difference.

[0091] Please refer to Figure 6 , Figure 6 which is a schematic framework diagram of an embodiment of the electronic device provided by the present application. In this embodiment, the electronic device 60 includes a memory 61 and a processor 62 that are coupled to each other.

[0092] The memory 61 stores program instructions, and the processor 62 is configured to execute the program instructions stored in the memory 61 to implement the steps of any of the above method embodiments. In a specific implementation scenario, the electronic device 60 may include, but is not limited to: a microcomputer, a server. In addition, the electronic device 60 may also include mobile devices such as a laptop computer, a tablet computer, etc., which are not limited herein.

[0093] Specifically, the processor 62 is configured to control itself and the memory 61 to implement the steps of any of the above embodiments. The processor 62 may also be referred to as a CPU (Central Processing Unit). The processor 62 may be an integrated circuit chip with signal processing capabilities. The processor 62 may also be a general-purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. Additionally, the processor 62 may be implemented jointly by integrated circuit chips.

[0094] Please refer to Figure 7 , Figure 7It is a schematic framework diagram of the computer-readable storage medium provided by this application. The computer-readable storage medium 70 of the embodiments of this application stores program instructions 71, and when the program instructions 71 are executed, they implement the methods provided by any one of the above embodiments and any non-conflicting combinations. Among them, the program instructions 71 can form a program file and be stored in the above computer-readable storage medium 70 in the form of a software product, so that a computer device (which can be a personal computer, a server, or a network device, etc.) can execute all or part of the steps of the methods of various embodiments of this application. The aforementioned computer-readable storage medium 70 includes: various media that can store program codes such as USB flash drives, mobile hard disks, read-only memories (ROM, Read-Only Memory), random access memories (RAM, Random Access Memory), magnetic disks, or optical discs, or terminal devices such as computers, servers, mobile phones, and tablets.

[0095] In the above solution, by using the motor fault detection model to process the target state data of the motor in the current operating period, the detection results obtained by different task branch models can be obtained. Then, based on the detection results obtained by different task branch models, the target detection result of the motor is determined. Compared with the method of only performing fault detection according to the results output by a single-task model, the method of comprehensively performing fault detection based on the results output by different task branch models in this application can avoid the situation where the fault detection is incorrect due to an incorrect single output result, and can improve the accuracy of fault detection.

[0096] In some embodiments, the functions or modules included in the device provided by the embodiments of the present disclosure can be used to execute the methods described in the above method embodiments. The specific implementation can refer to the description of the above method embodiments. For the sake of brevity, it will not be repeated here.

[0097] The descriptions of the above embodiments tend to emphasize the differences between the embodiments. Their similarities or similarities can be referred to each other. For the sake of brevity, they will not be repeated in this article.

[0098] In several embodiments provided by this application, it should be understood that the disclosed methods and devices can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of modules or units is only a logical function division. In actual implementation, there can be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection to each other can be through some interfaces. The indirect coupling or communication connection of the device or unit can be in an electrical, mechanical or other form.

[0099] The unit described as a separation component may or may not be physically separated. The component shown as a unit may or may not be a physical unit, that is, it may be located in one place or distributed across multiple network units. Some or all of these units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0100] In addition, in each embodiment of this application, each functional unit can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of a software functional unit.

[0101] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that makes a contribution to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) or a processor to execute all or part of the steps of the methods in each embodiment of this application. The aforementioned storage medium includes: USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs and other various media that can store program codes.

[0102] The above description is only for the embodiments of this application and does not limit the patent scope of this application. Any equivalent structural or equivalent process transformation made by using the content of the specification and drawings of this application, or directly or indirectly applied in other related technical fields, shall be equally included in the patent protection scope of this application.

Claims

1. A motor fault detection method, characterized in that: The method comprises: Obtain the target state data of the motor in the current running time period; The target state data is processed using a motor fault detection model to obtain a first detection result and a second detection result of the motor; the first detection result and the second detection result are obtained by processing using different task branch models of the motor fault detection model; Based on the first detection result and the second detection result, a target detection result of the motor is determined; the target judgment result is used to characterize whether the motor has a real fault.

2. The method according to claim 1, characterized in that The motor fault detection model includes a prediction branch model and a reconstruction branch model, and the target state data includes first state data at a plurality of first time points and second state data at at least one second time point; The method of processing the target state data by using the motor fault detection model to obtain a first detection result and a second detection result of the motor includes: Using the prediction branch model to perform prediction based on the first state data at a plurality of first time points, to obtain the predicted state data of the motor with respect to the at least one second time point, and using the reconstruction branch model to perform state reconstruction based on the target state data, to obtain the reconstructed state data of the motor in the current operation time period; The first detection result is determined based on a first difference between the predicted state data and the second state data, and the second detection result is determined based on a second difference between the reconstructed state data and the target state data.

3. The method according to claim 2, characterized in that The first detection result and the second detection result are both used to indicate whether the target state data of the motor is abnormal; The determining the first detection result based on a first difference between the predicted state data and the second state data includes: in response to the first difference being not less than a first preset difference, determining that the target state data of the motor is abnormal; Determining the second detection result based on a second difference between the reconstructed state data and the target state data includes: in response to the second difference being not less than a second preset difference, determining that the target state data of the motor is abnormal.

4. The method according to claim 1 or 3, characterized in that: The step of determining a target detection result of the motor based on the first detection result and the second detection result includes: In response to the first detection result and the second detection result both indicating that the target state data of the motor is abnormal, it is determined that a real fault exists in the motor.

5. The method according to claim 2, characterized in that: The motor fault detection model also includes an encoder, which is used to extract features from the target state data to obtain corresponding target state features; The predicted state data is obtained by predicting the state feature corresponding to the first state data in the target state feature using the prediction branch model; The reconstructed state data is obtained by reconstructing data based on the target state characteristics using the reconstruction branch model.

6. The method according to claim 5, characterized in that The target state data includes state data of at least two dimensions: motor D-axis current, motor D-axis voltage, motor Q-axis current, motor Q-axis voltage, motor speed, motor feedback torque, motor controller temperature, and motor water inlet temperature; The encoder includes an attention layer and a feedforward network layer. The attention layer is used to perform attention processing on the target state features to obtain attention data about state data of different dimensions; the feedforward network layer includes a first convolutional layer and a second convolutional layer.

7. The method according to claim 1, characterized in that The step of obtaining target state data of the motor in the current operation time period includes: The operation data of the motor in each sub-time period in the preset time period are respectively used as the target state data of the motor in the current operation time period; The determining a target detection result of the motor based on the first detection result and the second detection result further includes: Determining a fault detection result of the motor in a current running time period based on the first detection result and the second detection result; The target detection result of the motor is determined by integrating the fault detection results of the motor in each sub-time period in the preset time period.

8. The method according to claim 7, characterized in that The first detection result and the second detection result are both used to indicate whether the target state data of the motor is abnormal; The determining, based on the first detection result and the second detection result, a fault detection result of the motor in the current running time period includes: In response to at least one of the first detection result and the second detection result indicating that target state data of the motor is abnormal, determining that the motor has a candidate fault in a current operating time period; The integrated fault detection results of the motor in each sub-time period in the preset time period to determine the target detection result of the motor includes: Based on the fault detection results of the motor in each sub-time period, counting the number of sub-time periods that are candidate faults in the preset time period; Determine a ratio between the number of sub-time periods that are candidate faults and the total number of sub-time periods in the preset time period; In response to the ratio being not less than a preset ratio, it is determined that a real fault exists in the motor during the preset time period.

9. The method according to claim 1, characterized in that: The motor fault detection model includes a prediction branch model and a reconstruction branch model; The method further comprises: The normal state data corresponding to the motor in several historical operation time periods are used as sample data; the sample data includes first sample states at several first sample time points and second sample states at at least one second sample time point; For the sample data of each historical operation time period, the prediction branch model is used to predict the first sample state based on a plurality of first sample time points to obtain the sample prediction state of the motor about at least one second sample time point, and, Reconstructing data based on the sample data using the reconstruction branch model to obtain sample reconstructed data; The first difference and the second difference are combined to obtain a comprehensive difference; the first difference is the difference between the sample prediction state and the second sample state, and the second difference is the difference between the sample reconstruction data and the sample data; Network parameters of the motor fault detection model are adjusted based on the comprehensive difference.

10. An electronic device, characterized in that: comprising a memory and a processor coupled to each other, The memory stores program instructions; The processor is used to execute the program instructions stored in the memory to implement the method according to any one of claims 1 to 9.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores program instructions that can be run by a processor, and the program instructions can be executed by the processor to implement the method according to any one of claims 1 to 9.