A machine learning based vehicle failure prediction method
By combining physical constraints with deep learning, virtual samples are generated and the loss function is optimized, which solves the problems of data scarcity and insufficient adaptability in existing vehicle fault prediction methods. This achieves high-precision and robust vehicle fault prediction that can adapt to complex operating environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- YUNCHE ZHIXIANG (BEIJING) TECHNOLOGY CO LTD
- Filing Date
- 2025-01-16
- Publication Date
- 2026-04-14
AI Technical Summary
Existing machine learning-based vehicle fault prediction methods suffer from problems such as data scarcity, insufficient physical interpretability, poor scenario adaptability, and weak dynamic adjustment capabilities, resulting in poor application performance in complex vehicle operation scenarios.
By combining physical constraints with deep learning, a physical model based on vehicle dynamics is constructed to generate virtual samples. Physical consistency constraints are embedded in the model training. A multi-objective optimized loss function and adversarial training strategy are adopted to improve the model's fault prediction accuracy, physical consistency and robustness.
It achieves efficient prediction of rare fault categories, improves the model's generalization ability and prediction accuracy, ensures long-term adaptability and accuracy in diverse scenarios, solves the model failure problem caused by data scarcity and environmental changes in existing technologies, and achieves efficient operation and low-cost deployment.
Smart Images

Figure CN119916780B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent vehicle operation and maintenance technology, specifically to a vehicle fault prediction method based on machine learning. Background Technology
[0002] With the continuous development of intelligent and networked technologies, vehicle fault prediction has become an important technical means to ensure vehicle safety and reduce operation and maintenance costs. Currently, widely used technologies are mainly based on machine learning, which analyzes vehicle sensor data and historical fault records to build models that predict the probability of faults. These methods learn the characteristic patterns of vehicle operating states through large-scale data, thereby identifying potential fault hazards in advance. Supported by vehicle-to-everything (V2X) and sensor technologies, these technologies have shown certain effectiveness in practical applications and are gradually becoming an important component of intelligent vehicle operation and maintenance systems.
[0003] However, existing machine learning-based fault prediction schemes still have significant problems. First, data scarcity is a prominent issue; insufficient data on rare fault categories makes it difficult for models to effectively identify and predict them. Second, existing methods often rely entirely on data-driven approaches, ignoring the physical laws of vehicle dynamics and lacking physical interpretability, leading to reduced model reliability and safety. Third, existing models are insufficiently adaptable to the diversity of real-world operating environments; for example, model performance can easily degrade significantly under different road conditions, climates, and load conditions. Finally, fixed prediction models lack dynamic adjustment capabilities and struggle to adapt to the effects of sensor aging or environmental changes during long-term operation. These problems severely limit the effectiveness of existing technologies in complex vehicle operating scenarios. Summary of the Invention
[0004] To address the shortcomings of existing technologies, this invention provides a vehicle fault prediction method based on machine learning, which solves the problems of data scarcity, insufficient physical interpretability, poor scenario adaptability, and weak dynamic adjustment capability of existing technologies.
[0005] To achieve the above objectives, the present invention provides the following technical solution: a vehicle fault prediction method based on machine learning, comprising the following steps:
[0006] S1. Data acquisition and preprocessing: Acquire sensor data, environmental data, and historical fault record data of vehicle operating status, and clean, normalize, and slice the above data into time series.
[0007] S2. Introduce physical constraints, construct a physical model based on vehicle dynamics, generate virtual samples to expand training data, and embed physical constraints into the loss function during model training.
[0008] S3. Construct a time-series-based deep learning model to extract the temporal features of sensor data and predict vehicle fault categories;
[0009] S4. The model is trained using a loss function optimized by multiple objectives, which jointly optimizes the fault prediction accuracy, physical consistency and model robustness.
[0010] S5. Verify model performance by testing the model's fault prediction capability and generalization performance in real-world scenarios.
[0011] Preferably, the sensor data includes speed, acceleration, engine speed, torque, fuel consumption rate, and coolant temperature; the environmental data includes air temperature, humidity, road gradient, and vehicle load; and the fault record data includes fault type and fault occurrence time.
[0012] Preferably, the physical constraints are constructed through the following vehicle dynamics relationships: the engine output force is equal to the sum of air resistance, ground friction, and vehicle inertial force, wherein the air resistance is determined by the square of the vehicle speed, air density, drag coefficient, and frontal area, and the inertial force is determined by the vehicle acceleration and mass.
[0013] Preferably, after the generated virtual sample calculates the unobserved physical variables based on the physical model, it is combined with the real collected data to form an extended sample, and the data distribution of the virtual sample is adjusted by a distribution alignment method.
[0014] Preferably, the deep learning model employs a combination of a long short-term memory network and a Transformer structure, utilizing LSTM to extract short-term dependency features of the time series, and leveraging the self-attention mechanism of the Transformer to extract long-term dependency features and global features.
[0015] Preferably, the loss function of the multi-objective optimization includes fault prediction loss, physical consistency loss and robustness loss, wherein the fault prediction loss is calculated by the error between the actual fault label and the predicted value, the physical consistency loss is calculated by the degree of deviation between the predicted value and the physical model, and the robustness loss is calculated by the stability of the model output change after the simulated input data is disturbed.
[0016] Preferably, in step S1, to enhance the robustness of the model, an adversarial training strategy is introduced during the training process. This involves adding perturbations to the input data to simulate sensor anomalies, thereby improving the stability and accuracy of the model in complex and noisy environments.
[0017] Preferably, the loss function is optimized by using a Bayesian optimization method to dynamically adjust the weight coefficients in order to balance the objectives of fault prediction accuracy, physical consistency, and robustness.
[0018] Preferably, the validation of the model includes performance index testing and scenario testing, wherein the performance indexes include the accuracy, recall and F1 score of fault prediction, and the scenario testing includes the evaluation of generalization performance under different loads, road conditions and climate environments.
[0019] Preferably, the scenario testing also includes testing under extreme conditions, specifically for scenarios where multiple sensor failures occur simultaneously, to verify the reliability and predictive ability of the model in complex scenarios.
[0020] This invention provides a vehicle fault prediction method based on machine learning. It has the following beneficial effects:
[0021] 1. This invention adopts a technical solution that combines physical constraints and deep learning. By introducing a vehicle dynamics model to generate virtual samples and embedding physical consistency constraints in the model training, it achieves efficient prediction of rare fault categories. Compared with the existing prediction methods that rely entirely on data-driven methods, it solves the problem of poor training effect caused by data scarcity and significantly improves the generalization ability and prediction accuracy of the model.
[0022] 2. This invention uses a multi-objective optimized loss function to take fault prediction accuracy, physical consistency and robustness as joint training objectives, and achieves balance by dynamically adjusting the weights. Compared with the existing model training methods that only optimize a single objective, this invention solves the problem that it is difficult to balance physical constraints and prediction accuracy, and achieves the effect of improving model reliability and practical applicability.
[0023] 3. By deploying the model collaboratively in vehicle hardware and the cloud, this invention enables the fault prediction module to achieve a balance between real-time performance and in-depth analysis capabilities. Compared with existing technologies that rely solely on vehicle computing or cloud analysis, this invention solves the problems of insufficient real-time performance or excessive consumption of computing resources, ensuring efficient model operation and low-cost deployment.
[0024] 4. This invention ensures the long-term stability of the model by continuously monitoring its performance and performing incremental learning based on actual operating data. Compared with the fixed model prediction method in the prior art, it solves the problem of the model gradually failing due to changes in the vehicle operating environment, and achieves long-term adaptability and accuracy in diverse scenarios. Attached Figure Description
[0025] Figure 1 This is a schematic diagram of the method flow of the present invention. Detailed Implementation
[0026] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0027] Please see the appendix Figure 1 This invention provides a vehicle fault prediction method based on machine learning, comprising the following steps:
[0028] S1. Data acquisition and preprocessing: Acquire sensor data, environmental data, and historical fault record data of vehicle operating status, and clean, normalize, and slice the above data into time series.
[0029] In this embodiment, the data collection sources include the following:
[0030] The multidimensional data on vehicle operating status mainly comes from sensor data, environmental data, and historical fault record data.
[0031] Generally, vehicle sensor data is the core data source for fault prediction, directly reflecting the vehicle's operating status. Specifically, sensor data includes, but is not limited to, the following:
[0032] Speed, usually measured in kilometers per hour (km / h), is used to reflect the vehicle's movement.
[0033] Acceleration, in meters per second squared (m / s²) 2 The unit is ) to reflect the dynamic changes of vehicles;
[0034] Engine speed, measured in revolutions per minute (RPM), describes the engine's operating status;
[0035] Torque, measured in Newton-meters (Nm), reflects the power output of an engine;
[0036] Fuel consumption rate, expressed in liters per 100 kilometers (L / 100km), reflects the vehicle's energy efficiency.
[0037] Coolant temperature, expressed in degrees Celsius (°C), is used to assess the health of the engine's thermal management system.
[0038] As an alternative, environmental data can also be included in the data collection to supplement and interpret the external conditions of vehicle operation. Specifically, environmental data includes temperature, humidity, road gradient, and vehicle load. Among these, temperature and humidity reflect external weather conditions, road gradient is closely related to the load on the vehicle's powertrain, and load data can directly affect vehicle acceleration and energy consumption.
[0039] Furthermore, this embodiment also incorporates fault label data from the vehicle's historical maintenance records. Specifically, the fault label data should include the time of the fault occurrence, the fault type, and the scope of its impact. This data is used to label the collected operational status data, forming a complete training sample.
[0040] In this embodiment, to ensure data quality, the collected raw data underwent the following preprocessing:
[0041] In general, vehicle operation data may contain outliers or missing values, which need to be cleaned to remove or repair problematic data.
[0042] Specifically, handling outliers can combine statistical analysis methods with physical constraints. For example, in speed sensor data, samples with negative velocities or sudden speed changes exceeding the vehicle's physical limits are considered outliers and removed. In acceleration data, values exceeding the vehicle's design acceleration limits (e.g., ±15 m / s²) are also considered outliers. 2 The value of ) is also judged as abnormal.
[0043] In one possible implementation, missing data can be filled using interpolation methods or time series models. For example, when a few time periods are missing from the coolant temperature record, linear interpolation can be performed based on the temperature trend of adjacent time points. If the missing time periods are long, prediction and completion can be performed using a time series regression model based on the dynamic characteristics of the sensor.
[0044] In this embodiment, to ensure the standardization of the model input data, the cleaned data was normalized:
[0045] As an alternative, the Min-Max normalization method is used to map the numerical features to the [0,1] interval. Specifically, the normalization process is performed according to the following formula:
[0046]
[0047] Where x is the original data, x min and x max Let x and x' represent the minimum and maximum values of the data feature, respectively, and x′ be the normalized value.
[0048] In another implementation, Z-Score standardization can be used to adjust the data to a distribution with a mean of zero and a standard deviation of one. The calculation formula is as follows:
[0049]
[0050] Where μ is the sample mean, σ is the sample standard deviation, and z is the standardized value.
[0051] This normalization process can avoid the unbalanced impact of different features on model training due to differences in their dimensions, such as the bias of velocity and acceleration features on model weights.
[0052] In this embodiment, to capture the dynamic characteristics in the time series, the preprocessed data was divided into time windows:
[0053] In general, vehicle malfunctions are dynamic processes, and data from a single point in time may not be sufficient to reflect the complete malfunction pattern. Therefore, a fixed time window approach is used to slice continuous time series into samples of fixed length.
[0054] Specifically, in one possible implementation, a 10-second time window is used. Assuming 10 data points are collected per second, one sample contains 10 × 10 = 100 data points. This approach allows for the capture of dynamic changes in sensor features within a short timeframe, providing input support for subsequent temporal feature extraction in the model.
[0055] As an extension, the length of the time window can be adjusted according to the specific dynamic characteristics of the vehicle fault. For example, for situations where engine speed changes rapidly, the window time can be shortened to 5 seconds to improve the accuracy of dynamic response; while for characteristics such as fuel consumption rate that change slowly, the window time can be appropriately extended to 30 seconds to capture long-term trends.
[0056] The processing in this embodiment generates a complete and high-quality input dataset. This data covers core information about vehicle operating status, and the standardization of the data is improved through cleaning, normalization, and time-series slicing, providing a solid foundation for subsequent model training and optimization. Furthermore, through various selective implementations in specific embodiments, the method of this invention has good adaptability and can be adjusted according to different vehicles or application scenarios to meet diverse needs.
[0057] S2. Introduce physical constraints, construct a physical model based on vehicle dynamics, generate virtual samples to expand training data, and embed physical constraints into the loss function during model training.
[0058] In this embodiment, a physical constraint model is constructed based on vehicle dynamics theory:
[0059] Generally, a vehicle's operating state is determined by the balance of various forces. Specifically, during vehicle operation, the engine's output force needs to overcome air resistance, ground friction, and the vehicle's inertia. This dynamic relationship can be described as follows:
[0060] F engine =F drag +F friction +F inertia
[0061] in,
[0062] F engine This is the engine's output force;
[0063] F drag Air resistance can be calculated using the following formula:
[0064]
[0065] Where ρ is the air density, C d Here, A is the air resistance coefficient, A is the vehicle's frontal area, and v is the vehicle's speed.
[0066] F friction The formula for calculating the ground friction force is:
[0067] F friction =μmg
[0068] Where μ is the ground friction coefficient, m is the vehicle mass, and g is the gravitational acceleration;
[0069] F inertia As an inertial force, it can be expressed as:
[0070] F inertia =m·a
[0071] Where 'a' represents the vehicle's acceleration.
[0072] As an alternative, under different road conditions, the coefficient of friction μ and the coefficient of air resistance C d It can be adjusted according to vehicle type and road conditions. For example, on wet and slippery roads, the μ value may be significantly reduced, while for vehicles traveling at high speeds, C... d The impact is more significant.
[0073] In this embodiment, virtual samples were generated using a physical model:
[0074] In practical applications, data collection for certain vehicle states or fault categories is difficult, leading to imbalanced training data. To alleviate this problem, virtual samples are generated based on the aforementioned dynamic model to supplement the lack of real data.
[0075] Generally, the process of generating virtual samples includes the following steps:
[0076] Using the velocity v and acceleration a data collected by the sensor, the air resistance F is calculated by substituting them into the dynamic formula. drag Ground friction force F friction and inertial force F inertia .
[0077] In one possible implementation, the physical quantities calculated above are combined with other state variables collected by the sensors (such as engine speed, fuel consumption rate, etc.) to form a complete virtual sample.
[0078] The distribution of the generated virtual samples is adjusted. Specifically, the distribution differences between real and virtual data are statistically analyzed, and distribution alignment techniques are used to correct the virtual data so that it more closely approximates the distribution range of the real data.
[0079] As an extension, the generation of virtual samples can also be adjusted according to specific fault scenarios. For example, for engine overheating faults under high load conditions, virtual data that more closely resembles actual operating conditions can be generated by increasing the range of mmm values.
[0080] In this embodiment, physical constraints are introduced to guide the training of the model:
[0081] During model training, to ensure that the prediction results are consistent with physical laws, a physical constraint regularization term is introduced into the loss function. Specifically, this constraint term measures the degree of deviation between the model output and the physical model. For example, when the model predicts vehicle acceleration... When the predicted value is inconsistent with the theoretical value calculated by the dynamic formula, a penalty will be imposed on the prediction result.
[0082] As one implementation method, the embedding of physical constraints can be based on the following rules:
[0083] For the predicted vehicle state variables (such as acceleration, fuel consumption rate, etc.), calculate the deviation between them and the values derived from the physical model;
[0084] The greater the deviation, the stronger the penalty of the regularization term, thus guiding the prediction results to be closer to the physical laws during model training.
[0085] In general, the introduction of this physical constraint does not significantly increase the complexity of model training, because the physical quantities required to calculate the bias (such as air resistance and inertial force) can be quickly solved using simple formulas.
[0086] In some embodiments, extensions to this embodiment may include the following:
[0087] As one possibility, virtual sample generation can incorporate boundary conditions from actual collected data. For example, in mountainous road conditions, since slope significantly affects vehicle operation, slope parameters can be incorporated into the physical model to generate virtual data with regional characteristics.
[0088] Furthermore, the design of physical constraints can be extended to multi-objective optimization. For example, in addition to ensuring that the acceleration and dynamics models are consistent, the output of the model can be further optimized by combining fuel consumption and energy efficiency models.
[0089] This embodiment successfully combines vehicle dynamics with machine learning methods. The generation of virtual samples expands the data coverage, while the introduction of physical constraints enhances the model's physical interpretability and robustness. This combination enables the model to maintain good fault prediction capabilities even with scarce data, while also providing more realistic predictions of operational states.
[0090] S3. Construct a time-series-based deep learning model to extract the temporal features of sensor data and predict vehicle fault categories;
[0091] In this embodiment, the input to the deep learning model is the processed time series feature matrix:
[0092] Typically, sensor data is collected continuously in the form of a time series and converted into standardized samples through time window division in step 1. Specifically, each sample is a fixed-length two-dimensional feature matrix, where rows represent time steps and columns represent data features from different sensors.
[0093] As one implementation approach, for a sample with a 10-second window length, assuming 10 samples are collected per second, each sample contains 10 time steps, and each step has n feature values (such as velocity, acceleration, fuel consumption rate, etc.). This ultimately forms a 10×n feature matrix. In this matrix, each column reflects the temporal trend of a certain feature, and the rows demonstrate the temporal correlation of multi-sensor data.
[0094] In this embodiment, the feature extraction module of the deep learning model adopts an architecture combining LSTM and Transformer:
[0095] Generally, Long Short-Term Memory (LSTM) networks are suitable for extracting short-term dependencies in time series, especially for modeling dynamically changing vehicle operating states. Specifically, LSTM captures local features in the sequence through memory units and forget gate mechanisms, avoiding the gradient vanishing problem of traditional recurrent neural networks (RNNs).
[0096] In one possible implementation, the model's input matrix is progressively fed into an LSTM layer. The features at each time step are extracted into hidden states by the LSTM unit. These hidden states carry the temporal dependency information of the sequence, ultimately forming a new time-series feature vector.
[0097] To further extract long-term dependencies and global features, this embodiment introduces the self-attention mechanism from the Transformer architecture. Specifically, the self-attention mechanism captures dependencies over a global time scale by calculating the relative importance of features. Compared to LSTM, Transformer can process long-term sequences more efficiently and identify complex interactions between features.
[0098] As an extension, the Transformer architecture can use a multi-head attention mechanism to enhance feature capture capabilities. Each attention head calculates the correlation across different feature dimensions, and finally, by merging the outputs of different heads, a multi-angle modeling of the features is achieved.
[0099] In this embodiment, the output module of the deep learning model is designed for fault prediction in a multi-class classification problem:
[0100] Generally, the output module is used to transform the feature representation generated by the feature extraction module into a specific prediction result. Specifically, the global features extracted by LSTM and Transformer are passed to the fully connected layer to map the high-dimensional features to the fault category space.
[0101] As one implementation approach, assume there are k types of fault categories, such as engine failure, braking system malfunction, and sensor failure, and the output layer has k neurons. The Softmax activation function is used to calculate the predicted probability for each category, and the category with the highest probability is taken as the final prediction.
[0102] In another possible implementation, for vehicle health status assessment scenarios, the output layer can be designed as a scalar to quantify the vehicle's current health status. For example, the output health score can be between 0 and 100, with lower values indicating a higher risk of failure.
[0103] In this embodiment, the model training data includes a combination of real data and virtual data:
[0104] Generally, to improve the model's generalization ability, the training data should cover as many fault categories and operating scenarios as possible. The virtual samples generated in step 2 expand the scope of the training dataset, especially by supplementing the number of samples with rare faults.
[0105] As an alternative, real and virtual data can be mixed in a certain proportion in the training data. For example, for scenarios where some categories are scarce, the proportion of virtual samples can be appropriately increased to improve the model's predictive performance on that category.
[0106] In this embodiment, an adversarial training method is used to improve the robustness of the model:
[0107] Specifically, adversarial training simulates real-world sensor noise or anomalous inputs by adding perturbations to the input data. For example, in vehicle speed features, random noise within a certain range can be added to generate samples with a degree of uncertainty.
[0108] In one possible implementation, the adversarial perturbation is generated by the following formula:
[0109]
[0110] in,
[0111] x is the original sample.
[0112] ∈ represents the disturbance intensity.
[0113] This represents the gradient of the loss function with respect to the input data. (Generated adversarial examples)
[0114] x adv It can be used for model training, thereby improving the model's adaptability in abnormal scenarios.
[0115] Through the model design and training in this embodiment, high-precision prediction of vehicle faults was successfully achieved. The model captures short-term changes in time series using LSTM and extracts long-term dependency features using a Transformer structure. The addition of dummy data expands the coverage of training samples, while adversarial training improves the model's robustness to noise and abnormal inputs. This combination of deep learning architecture and optimization methods provides an efficient solution for vehicle operational health monitoring and fault prediction.
[0116] S4. The model is trained using a loss function optimized by multiple objectives, which jointly optimizes the fault prediction accuracy, physical consistency and model robustness.
[0117] In this embodiment, the design of the loss function for multi-objective optimization includes the following core components:
[0118] Generally, the loss function of a model needs to comprehensively consider multiple optimization objectives. Specifically, the loss function in this invention consists of fault prediction loss, physical consistency loss, and robustness loss.
[0119] Fault prediction loss is the primary optimization objective of the model, used to evaluate its ability to classify fault categories. Alternatively, the cross-entropy loss function can be used to quantify the error between the model's predictions and the true labels. Cross-entropy loss is suitable for multi-class classification problems; the smaller the value, the closer the model's predicted class distribution is to the true distribution.
[0120] Physical consistency loss is one of the innovative designs of this invention, used to ensure that the model output conforms to the laws of vehicle dynamics. Specifically, this loss measures the degree of deviation between the model's predicted state variables (such as acceleration and energy consumption) and the theoretical values calculated by the dynamic model. As one implementation method, the physical consistency of acceleration can be constrained, that is, based on the relationship between the vehicle's air resistance, friction, and inertial forces, the deviation between the model's predicted value and the theoretical value is calculated, and this deviation is added to the loss function.
[0121] Robustness loss is designed to enhance the adaptability of a model, improving its stability under noisy data or anomalous input conditions. Typically, adversarial training generates perturbation data to assess the model's sensitivity to small changes in the input data. Optimizing robustness loss can effectively reduce the dependence of predictions on noise, thereby improving the model's reliability.
[0122] In this embodiment, the combination of loss functions is achieved through weighted summation:
[0123] In one possible implementation, the loss function is defined as:
[0124]
[0125] in,
[0126] Indicates the predicted loss due to failure;
[0127] This represents the loss of physical consistency.
[0128] Indicates robustness loss;
[0129] λ1, λ2, and λ3 are weighting coefficients used to adjust the degree of influence of each objective on the total loss.
[0130] As an alternative, the initial values of the weighting coefficients can be set based on experience or experimental results. For example, in scenarios where enhanced physical interpretability is required, the value of λ2 can be appropriately increased to make physical consistency account for a higher proportion of the total loss.
[0131] In another possible implementation, the weight coefficients can be dynamically adjusted through an optimization algorithm. Specifically, a Bayesian optimization method is used to search for the optimal weight combination based on the model's performance on the validation set, thereby achieving a dynamic balance among the optimization objectives.
[0132] In this embodiment, model training combines multi-objective optimization and adversarial training strategies:
[0133] Generally, model training needs to optimize the multi-objective loss function while ensuring the stability of the training process. Specifically, the training process includes the following steps:
[0134] First, real data is mixed with the virtual samples generated in step 2 in a certain proportion to form a complete training dataset. As one approach, classes with fewer virtual samples can be prioritized for data augmentation to alleviate class imbalance.
[0135] Secondly, adversarial examples are added to the training data to improve the model's robustness. These adversarial examples can be generated by perturbing the original input data; for example, adding small amounts of random noise to the velocity features to simulate real-world sensor anomalies. The proportion of adversarial examples can be dynamically adjusted according to actual needs to ensure the model's adaptability under complex conditions.
[0136] Finally, the model parameters are optimized using gradient descent. As an extension, the AdamW optimizer can be used, which can dynamically adjust the learning rate while providing more precise control over weight decay, thereby improving training convergence efficiency.
[0137] The optimization method in this embodiment also includes a distribution adaptive strategy:
[0138] In one possible implementation, the distribution of training data may vary depending on the operating scenario; for example, the characteristics of sensor data may change significantly under different vehicle types or road conditions. To accommodate such distributional differences, a distribution adaptive regularization strategy can be introduced during model training to encourage the model to maintain consistent predictive ability across multiple scenarios.
[0139] Specifically, by statistically analyzing the feature distribution of data from different scenarios, the prediction bias of the model under distribution drift can be calculated, and this bias can be added as a regularization term to the loss function. For example, the distribution characteristics of speed and acceleration may differ on incline roads and highways; by optimizing the distribution adaptive regularization term, the generalization performance of the model can be improved.
[0140] Through the multi-objective optimization design and model training in this embodiment, a balance between fault prediction accuracy, physical consistency, and robustness was successfully achieved. In particular, by employing dynamic weight adjustment and adaptive distribution strategies, the model can be flexibly optimized according to the needs of different application scenarios, improving its applicability and reliability in practical applications. The above methods provide a complete solution for comprehensive performance optimization of vehicle fault prediction systems.
[0141] S5. Verify model performance by testing the model's fault prediction capability and generalization performance in real-world scenarios.
[0142] In this embodiment, model performance verification includes multiple dimensions:
[0143] Generally, model performance is validated through both static data testing and dynamic scenario simulation to comprehensively evaluate the model's accuracy and stability.
[0144] Specifically, in static data testing, the model's predictive ability is evaluated through its classification performance of fault categories. As one implementation method, metrics such as accuracy, recall, and F1-Score are used to quantify the model's classification performance. Accuracy reflects the overall correctness of the model's predictions, recall assesses the ability to identify fault samples, and the F1-Score balances accuracy and recall.
[0145] In dynamic scenario testing, to verify the physical consistency of the model, the predicted results are compared with the laws of vehicle dynamics. For example, the predicted vehicle acceleration data can be substituted into the dynamic model in step 2 to calculate the corresponding air resistance, friction, and other variables. By comparing the changing trends of these physical variables, the model's compliance with physical constraints can be evaluated.
[0146] Alternatively, specific performance deviation metrics can be designed to quantify the model's physical consistency. For example, whether the model correctly captures the trend of air resistance increasing with the square of speed when the vehicle is traveling at high speeds.
[0147] In this embodiment, scenario testing primarily verifies the model's generalization ability through diverse runtime environments:
[0148] Typically, vehicle operating environments include varying road conditions, weather conditions, and vehicle load conditions. To verify the model's performance under these conditions, diverse test scenarios were constructed.
[0149] In one possible implementation, the test scenarios include the following categories:
[0150] Road conditions: flat roads, slopes, highway sections and low-speed congestion sections.
[0151] Climate conditions: high temperature environment, low temperature environment and wet and slippery road surface.
[0152] Vehicle load: three states: unloaded, half-loaded, and fully loaded.
[0153] In each scenario, sensor data from the vehicle is collected and input into the model for prediction. By comparing classification performance metrics under different scenarios, the model's ability to adapt to data inputs with significantly different distributions is evaluated.
[0154] As an extension, extreme scenarios can be simulated to verify the robustness of the model. For example, assuming multiple sensors fail simultaneously (such as simultaneous anomalies in speed and acceleration sensor data), adversarial examples can be added to test the model's ability to predict failures under complex conditions.
[0155] In this embodiment, the running efficiency of the model was also evaluated:
[0156] Specifically, operational efficiency evaluation mainly targets the model's inference speed and computational resource consumption. In a real-time vehicle operating environment, the model needs to complete data processing and fault prediction within a limited time to meet real-time requirements.
[0157] One approach is to quantify the model's real-time performance by recording its inference time under different hardware conditions. For example, in in-vehicle computing devices, the model's single inference time is required to be no more than 100 milliseconds. Simultaneously, the model's memory footprint is evaluated to ensure its suitability for embedded devices.
[0158] In another possible implementation, a lightweight version of the model can be optimized to reduce the number of parameters and computational complexity, thereby improving runtime efficiency. By employing knowledge distillation, a high-performance teacher model can guide the training of the lightweight student model, ensuring a balance between runtime efficiency and predictive performance.
[0159] In this embodiment, the verification process also incorporates interpretive analysis of the model output results:
[0160] In general, the black-box nature of deep learning models can make their output difficult to interpret. Therefore, this invention improves the interpretability of the model's output by combining a physical model with feature importance analysis.
[0161] Specifically, after predicting the fault category, feature importance assessment can be used to identify the input features that contribute most to fault prediction. For example, the SHAP (Shapley Additive Explanations) method can be used to calculate the contribution of each feature to the model's decision. This analysis can visually demonstrate how the model identifies faults based on features such as speed, acceleration, or fuel consumption rate.
[0162] Alternatively, causal reasoning can be applied to the prediction results based on physical laws. For example, if the prediction results indicate abnormal fuel consumption, the vehicle dynamics model can be used to infer that the possible causes are insufficient engine output power or abnormal air resistance.
[0163] In some embodiments, the extended testing in this example includes monitoring the long-term performance of the model:
[0164] In general, the vehicle's operating environment and usage conditions may change over time. To ensure the long-term applicability of the model, it can be updated through incremental training or online learning mechanisms.
[0165] Specifically, new operational data can be continuously collected after model deployment, and this data can be used to fine-tune the model. Through online learning, the model can adapt to changes in data distribution, such as seasonal climate changes or long-term vehicle performance degradation.
[0166] Through model validation and scenario testing in this embodiment, the adaptability and predictive performance of the model under different operating conditions were comprehensively evaluated. In particular, the reliability and real-time performance of the model in practical applications were ensured through diverse test scenarios and evaluation of operational efficiency. The above validation process provides a solid technical guarantee for the practical implementation of this invention.
[0167] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.
Claims
1. A vehicle fault prediction method based on machine learning, characterized in that, Includes the following steps: S1. Data acquisition and preprocessing: Acquire sensor data, environmental data, and historical fault record data of vehicle operating status, and clean, normalize, and slice the above data into time series. S2. Introduce physical constraints, construct a physical model based on vehicle dynamics, generate virtual samples for expanding training data, and embed physical constraints into the loss function during model training. The physical constraints are constructed through the following vehicle dynamics relationships: the engine output force is equal to the sum of air resistance, ground friction, and vehicle inertial force. The air resistance is determined by the square of the vehicle speed, air density, drag coefficient, and frontal area. The inertial force is determined by the vehicle acceleration and mass. S3. Construct a time-series-based deep learning model to extract the temporal features of sensor data and output the predicted values of vehicle physical state and vehicle fault categories. S4. The deep learning model is trained using a multi-objective optimized loss function to jointly optimize fault prediction accuracy, physical consistency, and model robustness. The multi-objective optimized loss function includes fault prediction loss, physical consistency loss, and robustness loss. The fault prediction loss is calculated by the error between the real fault label and the predicted vehicle fault category. The physical consistency loss is calculated by the deviation between the predicted vehicle physical state value and the physical model. The robustness loss is calculated by the stability of the deep learning model output change after simulated input data perturbation. S5. Verify the performance of the trained deep learning model by evaluating its fault prediction capability and generalization performance through real-world scenario testing.
2. The vehicle fault prediction method based on machine learning according to claim 1, characterized in that, The sensor data includes speed, acceleration, engine speed, torque, fuel consumption rate, and coolant temperature; the environmental data includes air temperature, humidity, road gradient, and vehicle load; and the fault record data includes fault type and fault occurrence time.
3. The vehicle fault prediction method based on machine learning according to claim 1, characterized in that, The virtual sample is calculated based on the physical model to obtain the unobserved physical variables, and then combined with the real collected data to form an extended sample. The data distribution of the virtual sample is adjusted by the distribution alignment method.
4. The vehicle fault prediction method based on machine learning according to claim 1, characterized in that, The deep learning model combines a long short-term memory network and a Transformer structure. It uses LSTM to extract short-term dependency features of time series and the self-attention mechanism of Transformer to extract long-term dependency features and global features.
5. The vehicle fault prediction method based on machine learning according to claim 4, characterized in that, In step S1, to enhance the robustness of the model, an adversarial training strategy is introduced during the training process. By adding perturbations to the input data to simulate sensor anomalies, the stability and accuracy of the model in complex and noisy environments are improved.
6. The vehicle fault prediction method based on machine learning according to claim 1, characterized in that, The loss function is optimized using a Bayesian optimization method to dynamically adjust the weight coefficients in order to balance the objectives of fault prediction accuracy, physical consistency, and robustness.
7. The vehicle fault prediction method based on machine learning according to claim 1, characterized in that, The validation of the deep learning model includes performance metric testing and scenario testing. The performance metrics include the accuracy, recall, and F1 score of fault prediction, while the scenario testing includes generalization performance evaluation under different loads, road conditions, and climate environments.
8. The vehicle fault prediction method based on machine learning according to claim 7, characterized in that, The scenario testing also includes testing under extreme conditions, targeting scenarios where multiple sensor failures occur simultaneously, to verify the model's reliability and predictive ability in complex scenarios.
Citation Information
Patent Citations
Automobile sensor fault classification method based on BN-LSTM network
CN111497868A
Turnout fault detection method based on LSTM and attention mechanism
CN113139601A
Fault rolling bearing digital twin model construction method based on inverse physical information neural network
CN117892621A
Systems and methods for machine classification and learning that is robust to unknown inputs
US20200394557A1