Air flow prediction method for engine, vehicle, storage medium, and program product

By acquiring the engine's current operating conditions and status data and using an airflow prediction model for prediction, the problem of insufficient accuracy of traditional sensors in harsh environments is solved, achieving real-time, high-precision airflow prediction and improving the accuracy and efficiency of engine control.

CN121880801APending Publication Date: 2026-04-17FAW JIEFANG AUTOMOTIVE CO +1
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
FAW JIEFANG AUTOMOTIVE CO
Filing Date
2025-12-31
Publication Date
2026-04-17

AI Technical Summary

Technical Problem

Traditional physical airflow sensors suffer from performance degradation in the high-temperature, vibration, and polluted environment inside the engine compartment, resulting in insufficient accuracy in airflow prediction.

Method used

By acquiring the engine's current operating conditions and status data, an airflow prediction model is used for prediction, including multi-layer feature extraction and linear combination. Hyperparameters are optimized by combining global and local optimization algorithms, and a lightweight neural network model is constructed for prediction.

Benefits of technology

It enables real-time, high-precision airflow prediction in complex environments, improving the accuracy of engine control parameters and operational efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121880801A_ABST
    Figure CN121880801A_ABST
Patent Text Reader

Abstract

The invention discloses an air flow prediction method of an engine, a vehicle, a storage medium and a program product. The method comprises the steps that the current working condition and operation state data of an engine are obtained, and the operation state data are used for describing the operation state of the engine at the current moment; the total air inlet flow of the engine is determined based on the current working condition, and the total air inlet flow is used for representing the theoretical maximum air inlet amount of the engine under the current working condition; the operation state data are input into an air flow prediction model, the air flow prediction model is used for predicting the air inlet flow under the current working condition, a prediction coefficient is obtained, and the prediction coefficient is used for reflecting the ratio of the actual air flow to the total air inlet flow; and determining the target air flow of the engine based on the total air inlet flow and the prediction coefficient. The technical problem that the prediction accuracy of the air flow of the engine is low in the related technology is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of vehicles, and more specifically, to a method for predicting the airflow of an engine, a vehicle, a storage medium, and a program product. Background Technology

[0002] Precise engine control relies on accurate measurement of intake air volume. However, traditional physical airflow sensors suffer significant performance degradation or even malfunction when faced with harsh environments such as high temperatures, vibrations, and pollution in the engine compartment. This makes it difficult to guarantee the accuracy of sensor readings, thus making it hard to accurately predict intake air volume and resulting in low accuracy of engine airflow prediction in related technologies.

[0003] There is currently no effective solution to the above problems. Summary of the Invention

[0004] This application provides an engine airflow prediction method, vehicle, storage medium, and program product to at least solve the technical problem of low accuracy in engine airflow prediction in related technologies.

[0005] According to one aspect of the embodiments of this application, an airflow prediction method for an engine is provided, comprising: acquiring current operating conditions and running status data of the engine, wherein the running status data is used to describe the running status of the engine at the current moment; determining the total intake airflow of the engine based on the current operating conditions, wherein the total intake airflow is used to represent the theoretical maximum intake air volume of the engine under the current operating conditions; inputting the running status data into an airflow prediction model, using the airflow prediction model to predict the intake airflow under the current operating conditions, and obtaining prediction coefficients, wherein the prediction coefficients are used to reflect the ratio of the actual airflow to the total intake airflow; and determining the target airflow of the engine based on the total intake airflow and the prediction coefficients, wherein the target airflow is used to represent the actual airflow of the engine under the current operating conditions.

[0006] Furthermore, the operating status data is input into the air flow prediction model, and the air flow prediction model is used to predict the intake air flow under the current operating conditions to obtain prediction coefficients. This includes: using multiple hidden layers in the air flow prediction model to extract features from the operating status data layer by layer to obtain target feature data; and performing linear combination of the target feature data to obtain prediction coefficients.

[0007] Furthermore, the multiple hidden layers include: a first hidden layer, a second hidden layer, and a third hidden layer; the airflow prediction model utilizes multiple hidden layers to perform layer-by-layer feature extraction on the operating status data to obtain target feature data, including: using the first hidden layer to perform preliminary feature extraction on the operating status data to obtain first feature data, wherein the first feature data is used to represent the preliminary feature representation of the operating status data; using the second hidden layer to perform deep feature extraction on the first feature data to obtain second feature data, which is used to represent the deep feature representation of the operating status data; and using the third hidden layer to perform feature extraction on the second feature data to obtain target feature data.

[0008] Furthermore, the method also includes: using an optimization algorithm to search for a target hyperparameter combination from a preset hyperparameter search space; constructing an initial airflow prediction model based on the target hyperparameter combination; and training the initial airflow prediction model using training data to determine the airflow prediction model, wherein the training data is used to represent sample operating state data of the engine under different operating conditions.

[0009] Furthermore, the optimization algorithm includes a global optimization algorithm and a local optimization algorithm; the optimization algorithm is used to determine the target hyperparameter combination from the preset hyperparameter search space, including: using the global optimization algorithm to perform global optimization in the preset hyperparameter search space to obtain the first hyperparameter space; and using the local optimization algorithm to perform local optimization in the first hyperparameter space to obtain the target hyperparameter combination.

[0010] Furthermore, a global optimization algorithm is used to perform global optimization in the preset hyperparameter search space to obtain the first hyperparameter space, including: determining the optimization objective and constraints in the preset hyperparameter search space; and performing global optimization in the preset hyperparameter search space based on the optimization objective and constraints to obtain the first hyperparameter space.

[0011] Furthermore, the initial airflow prediction model is trained using training data to determine the airflow prediction model, including: extracting features from the training data using the initial airflow prediction model to obtain sample feature data; performing linear combination of the sample feature data to obtain sample prediction coefficients; determining the loss function based on the sample prediction coefficients and the sample labels corresponding to the training data; and adjusting the initial airflow prediction model using the loss function to obtain the airflow prediction model.

[0012] Furthermore, before inputting the operational status data into the airflow prediction model, the method further includes: performing correlation analysis on the initial operational status features to determine the correlation between the initial operational status features and the prediction coefficients; performing feature selection on the initial operational status data based on the correlation and a preset correlation threshold to obtain first operational status data, wherein the correlation corresponding to the first operational status data is greater than the preset correlation threshold; and preprocessing the first operational status data to determine the operational status data.

[0013] Furthermore, the method also includes controlling the engine based on the target airflow.

[0014] According to another aspect of the embodiments of this application, a training method for an air flow prediction model is also provided, comprising: using an optimization algorithm to search a preset hyperparameter space to determine a target hyperparameter combination; constructing an initial air flow prediction model based on the target hyperparameter combination; and training the initial air flow prediction model using training data to determine an air flow prediction model, wherein the air flow prediction model is used to execute the methods in the various embodiments of this application.

[0015] According to another aspect of the embodiments of this application, an airflow prediction device for an engine is also provided, comprising: an acquisition module, configured to acquire current operating conditions and running status data of the engine, wherein the running status data is used to describe the running status of the engine at the current moment; a first determination module, configured to determine the total intake airflow of the engine based on the current operating conditions, wherein the total intake airflow is used to represent the theoretical maximum intake air volume of the engine under the current operating conditions; a prediction module, configured to input the running status data into an airflow prediction model, and use the airflow prediction model to predict the intake airflow under the current operating conditions to obtain a prediction coefficient, wherein the prediction coefficient is used to reflect the ratio of the actual airflow to the total intake airflow; and a second determination module, configured to determine the target airflow of the engine based on the total intake airflow and the prediction coefficient, wherein the target airflow is used to represent the actual airflow of the engine under the current operating conditions.

[0016] According to another aspect of the embodiments of this application, a training apparatus for an air flow prediction model is also provided, comprising: a third determining module, configured to determine a target hyperparameter combination from a preset hyperparameter search space using an optimization algorithm; a construction module, configured to construct an initial air flow prediction model based on the target hyperparameter combination; and a training module, configured to train the initial air flow prediction model using training data to determine an air flow prediction model, wherein the air flow prediction model is used to execute the methods in various embodiments of this application.

[0017] According to another aspect of the embodiments of this application, a vehicle is also provided, including: a memory storing an executable program; and a processor for running the program, wherein the program executes the methods in various embodiments of this application when it runs.

[0018] According to another aspect of the embodiments of this application, a computer-readable storage medium is also provided, the computer-readable storage medium including a stored executable program, wherein, when the executable program is running, it controls the device where the computer-readable storage medium is located to perform the methods of various embodiments of this application.

[0019] According to another aspect of the embodiments of this application, a computer program product is also provided, including a computer program that, when executed by a processor, implements the methods of various embodiments of this application.

[0020] According to another aspect of the embodiments of this application, a computer program product is also provided, including a non-volatile computer-readable storage medium storing a computer program that, when executed by a processor, implements the methods in various embodiments of this application.

[0021] According to another aspect of the embodiments of this application, a computer program is also provided, which, when executed by a processor, implements the methods of the various embodiments of this application.

[0022] This application provides a method for predicting engine airflow. First, it acquires the engine's current operating condition and running status data. Then, it determines the engine's total intake airflow based on the current operating condition. Next, it inputs the running status data into an airflow prediction model, using the model to predict the intake airflow under the current operating condition, obtaining prediction coefficients. These prediction coefficients reflect the ratio of actual airflow to total intake airflow. Finally, based on the total intake airflow and the prediction coefficients, it determines the engine's target airflow. This application first acquires the engine's current operating condition and running status data. This comprehensive dataset accurately reflects the engine's state under current environmental and operating conditions, providing a data foundation for subsequent predictions. Next, it determines the engine's total intake airflow based on the current operating condition. The acquisition of the total intake airflow provides a benchmark reference for subsequent predictions and improves the model's predictive accuracy and effectiveness. Then, it processes the running status data using a pre-trained lightweight airflow prediction model to obtain prediction coefficients. Finally, based on the prediction coefficients and the total intake airflow, the engine's target airflow, i.e., the engine's actual airflow under the current operating condition, can be accurately determined. This application achieves real-time, high-precision airflow prediction in the vehicle environment by combining dynamic operating condition determination with lightweight airflow prediction model prediction. This enables precise adjustment of engine control parameters, significantly improves the accuracy of airflow prediction and engine operating efficiency, and solves the technical problem of low airflow prediction accuracy in related technologies. Attached Figure Description

[0023] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments of this application and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:

[0024] Figure 1 This is an airflow prediction method for an engine according to an embodiment of this application;

[0025] Figure 2 This is a flowchart of a training method for an airflow prediction model according to an embodiment of this application;

[0026] Figure 3 This is a flowchart of a lightweight neural network airflow virtual sensor implementation method according to an embodiment of this application;

[0027] Figure 4 This is a schematic diagram of a lightweight neural network structure according to an embodiment of this application;

[0028] Figure 5 This is a schematic diagram of an airflow prediction device for an engine according to an embodiment of this application;

[0029] Figure 6 This is a schematic diagram of a training device for an airflow prediction model according to an embodiment of this application. Detailed Implementation

[0030] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.

[0031] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0032] According to an embodiment of this application, an embodiment of an engine airflow prediction method is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Also, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.

[0033] Figure 1 This is an engine airflow prediction method according to an embodiment of this application, such as... Figure 1 As shown, the method includes the following steps:

[0034] Step S102: Obtain the current operating condition and running status data of the engine, wherein the running status data is used to describe the running status of the engine at the current moment.

[0035] The aforementioned engine refers to a device that converts the chemical energy of fuel into kinetic energy. Engines are widely used in automobiles, ships, power generation, aviation, and other fields. In the vehicle field, the engine is responsible for power output, driving the vehicle forward. Engine performance directly affects a vehicle's driving capability, fuel efficiency, and emissions levels. In modern automotive electronic control systems, precise engine control is crucial for ensuring vehicle performance, safety, and environmental friendliness.

[0036] The aforementioned current operating condition refers to the engine's working state and operating conditions at a specific moment. Current operating conditions may include, but are not limited to, cold start, idling, acceleration, deceleration, constant speed driving, high altitude / high altitude conditions, extreme temperature conditions, and load variation conditions. The specific current operating condition needs to be determined based on actual circumstances. The current operating condition can be used to determine the engine's current operating status in order to accurately determine other operating parameters within the engine.

[0037] The aforementioned operating status data refers to a set of values ​​describing various key parameters under the current operating conditions of the engine. Operating status data may include, but is not limited to, Exhaust Gas Recirculation (EGR) opening, engine speed, throttle opening, intake manifold pressure, intake air temperature, ambient pressure, rate of change of engine speed, rate of change of fuel quantity, and rate of change of pressure. Specific operating status parameters need to be determined based on actual requirements. Operating status data serves as the basis for real-time monitoring and control of the engine's electronic control system. Through this data, the engine's operating status can be accurately determined, and control strategies can be adjusted in a timely manner to achieve optimal performance and efficiency.

[0038] In one optional embodiment, a series of operating status data are collected in real time from the engine and its surrounding sensor network, including but not limited to EGR opening, engine speed, throttle opening, intake manifold pressure, intake air temperature, ambient pressure, and the rate of change of various parameters. This data comprehensively reflects the engine's operating status at a given moment; it also determines the engine's current operating condition, such as whether it is accelerating, decelerating, or maintaining a constant speed. By determining the engine's operating status data and current operating condition, the engine's status information can be grasped in real time, providing a solid data foundation for subsequent airflow prediction and engine control strategy formulation.

[0039] For example, real-time acquisition of the engine's current operating conditions and status data can be accomplished through the collaboration of the onboard electronic control unit (ECU) and a sensor network distributed around the engine. Specifically, the ECU periodically extracts data from these sensors, including EGR (exhaust gas recirculation) opening, engine speed, throttle position, intake manifold pressure, intake air temperature, ambient pressure, and parameters reflecting dynamic characteristics such as the rate of change of engine speed and fuel quantity. These sensors continuously monitor various aspects of the engine, while the ECU acts as a data aggregation and processing center. It not only collects data but also performs preliminary processing and analysis to ensure that the data quality and format are suitable for subsequent analysis and application. Through this series of closely coordinated hardware and software components, the engine's operating status details at any given moment can be captured promptly and accurately, providing real-time and detailed data support for subsequent airflow prediction and engine control strategies. This data acquisition process is the foundation of the engine intelligent management system, ensuring the real-time nature and effectiveness of control strategies, thereby improving the engine's performance and overall efficiency under complex operating conditions.

[0040] Step S104: Determine the total intake air flow of the engine based on the current operating conditions, wherein the total intake air flow is used to represent the theoretical maximum intake air volume of the engine under the current operating conditions.

[0041] The aforementioned total intake airflow refers to the theoretically maximum mass flow of air that can enter the engine under given engine operating conditions. Total intake airflow can serve as a key parameter for determining the actual airflow under current operating conditions.

[0042] The methods for determining the total intake air volume mentioned above may include, but are not limited to, the following:

[0043] The first method is based on empirical formulas or pre-established mapping tables. These mapping tables are typically built during the engine development phase using extensive experimental data, covering various engine operating conditions such as different engine speeds, throttle openings, and environmental conditions. When the ECU receives the current operating status data, it queries the mapping table and interpolates based on the closest experimental operating condition point to obtain an estimated total intake airflow for the current operating condition.

[0044] The second method involves using a physical model to predict the total intake airflow in real time. The physical model can calculate the theoretical intake airflow based on principles of fluid dynamics and thermodynamics, combined with parameters under the current engine operating conditions.

[0045] The above methods are just examples; the specific methods should be determined based on actual needs.

[0046] In one alternative embodiment, the ECU calculates the engine's total intake airflow in real time using a pre-calibrated mapping table or a tuned physical model. This calculation is crucial for precise engine control, as it directly affects the adjustment of fuel injection quantity, air-fuel ratio setting, turbocharger regulation, and the operation of the EGR (exhaust gas recirculation) system, thereby ensuring the engine operates both efficiently and environmentally friendly. Accurate prediction of total intake airflow is fundamental to achieving precise engine control and energy conservation and emission reduction goals.

[0047] Step S106: Input the operating status data into the air flow prediction model, use the air flow prediction model to predict the intake flow under the current operating conditions, and obtain the prediction coefficient. The prediction coefficient is used to reflect the ratio of the actual air flow to the total intake flow.

[0048] The aforementioned airflow prediction model can refer to a pre-trained lightweight neural network model used to predict the actual intake airflow under current operating conditions based on real-time engine operating data. This model can accurately predict engine intake airflow, enabling the ECU to manage engine operation more precisely, improving fuel economy and reducing pollutant emissions.

[0049] Airflow prediction models can include, but are not limited to, those based on physical models, those based on machine learning, and hybrid models. Physical models, built on principles of fluid mechanics and thermodynamics, can accurately describe the physical phenomena during the intake process, but require complex parameter calibration. Machine learning models, such as neural network models, learn the nonlinear relationship between engine intake flow and operating parameters through extensive experimental data, making them suitable for complex and variable operating conditions, especially in resource-constrained automotive ECU environments. Hybrid models combine the advantages of physical and machine learning models, using the physical model to provide prior knowledge and the machine learning model for parameter correction and dynamic adaptation to improve prediction accuracy and stability. The above airflow prediction models are merely examples; specific models should be determined based on actual needs.

[0050] The aforementioned prediction coefficient can refer to the ratio of the actual airflow predicted by the model to the theoretical total intake airflow. The prediction coefficient helps the ECU adjust its control strategy to ensure optimal air-fuel ratio and minimal fuel waste under any operating conditions, while meeting emission regulations. By monitoring changes in the prediction coefficient, the ECU can adjust the injection quantity and other control parameters in a timely manner to adapt to the engine's real-time needs.

[0051] In one optional embodiment, real-time collected operating status data, such as engine speed, throttle position, intake manifold pressure, and temperature, are input into a pre-trained airflow prediction model. This model, especially a lightweight neural network model, can quickly predict the ratio between the actual airflow and the theoretical total intake airflow under current engine operating parameters—that is, the prediction coefficient. The prediction coefficient helps the ECU adjust key control parameters such as fuel injection quantity and air-fuel ratio in real time to ensure that the engine achieves optimal combustion efficiency and emission levels under various operating conditions. The entire process, from data input to model prediction and then to the output of prediction coefficients, constitutes a closed-loop intelligent control system, greatly improving the engine's adaptability and control accuracy under complex and changing operating conditions.

[0052] Step S108: Based on the total intake airflow and the prediction coefficient, determine the target airflow of the engine, wherein the target airflow is used to represent the actual airflow of the engine under the current operating conditions.

[0053] The target airflow rate mentioned above refers to the actual airflow rate of the engine under current operating conditions. The target airflow rate can be calculated by combining the total intake airflow rate with a prediction coefficient. The calculation of the target airflow rate ensures that the ECU can accurately adjust the air supply according to the engine's real-time needs to maintain optimal combustion efficiency and emission characteristics. The target airflow rate can be used for fuel injection control, ignition control, EGR control, turbocharger adjustment, etc.

[0054] In one optional embodiment, based on the product of the total intake airflow and the prediction coefficient, the ECU can accurately determine the target airflow, that is, the actual airflow required by the engine at the current moment to achieve performance improvement and emission control. This process of determining the target airflow is a crucial step in the ECU's dynamic adjustment of engine control parameters, such as fuel injection quantity and air-fuel ratio, to ensure engine operating efficiency and environmental performance, demonstrating the important application of data-driven and intelligent algorithms in modern engine control systems.

[0055] This application provides a method for predicting engine airflow. First, it acquires the engine's current operating condition and running status data. Then, it determines the engine's total intake airflow based on the current operating condition. Next, it inputs the running status data into an airflow prediction model, using the model to predict the intake airflow under the current operating condition, obtaining prediction coefficients. These prediction coefficients reflect the ratio of actual airflow to total intake airflow. Finally, based on the total intake airflow and the prediction coefficients, it determines the engine's target airflow. This application first acquires the engine's current operating condition and running status data. This comprehensive dataset accurately reflects the engine's state under current environmental and operating conditions, providing a data foundation for subsequent predictions. Next, it determines the engine's total intake airflow based on the current operating condition. The acquisition of the total intake airflow provides a benchmark reference for subsequent predictions and improves the model's predictive accuracy and effectiveness. Then, it processes the running status data using a pre-trained lightweight airflow prediction model to obtain prediction coefficients. Finally, based on the prediction coefficients and the total intake airflow, the engine's target airflow, i.e., the engine's actual airflow under the current operating condition, can be accurately determined. This application achieves real-time, high-precision airflow prediction in the vehicle environment by combining dynamic operating condition determination with lightweight airflow prediction model prediction. This enables precise adjustment of engine control parameters, significantly improves the accuracy of airflow prediction and engine operating efficiency, and solves the technical problem of low airflow prediction accuracy in related technologies.

[0056] Optionally, the operating status data is input into the air flow prediction model, and the air flow prediction model is used to predict the intake flow under the current operating conditions to obtain prediction coefficients. This includes: using multiple hidden layers in the air flow prediction model to extract features from the operating status data layer by layer to obtain target feature data; and performing linear combination of the target feature data to obtain prediction coefficients.

[0057] The aforementioned hidden layers refer to a series of intermediate layers placed between the input and output layers. These layers are responsible for performing multi-level nonlinear transformations and feature abstraction on the input data. Each hidden layer consists of multiple neurons connected by weights to form a network structure. The existence of hidden layers enables the model to capture deeper patterns and complex relationships in the data, improving prediction accuracy. In the airflow prediction model, the role of multiple hidden layers is to progressively extract and abstract implicit features from the operational status data, preparing for subsequent predictions.

[0058] The aforementioned layer-by-layer feature extraction refers to the gradual extraction of feature combinations that influence the prediction results through hierarchical computation of hidden layers. The neurons in each layer perform computations based on the weighted inputs passed from the previous layer. This process can be understood as the recombination and abstraction of features, enabling higher-level hidden layers to learn more complex and abstract feature representations. These features are closely related to the intrinsic connection between engine intake airflow and operating status data.

[0059] The aforementioned target feature data refers to a set of high-level features closely related to the prediction target, formed after processing through multiple hidden layers of the airflow prediction model. Compared to the original operational status data, the target feature data is more refined and abstract, containing the most critical information for predicting intake airflow. These features, through the network's deep learning process, have undergone multiple nonlinear transformations and combinations, better reflecting the influence of internal engine flow mechanisms and external environmental factors on intake air volume, thus providing a solid data foundation for calculating the prediction coefficients.

[0060] The linear combination described above refers to the process where, after obtaining the target feature data, the model multiplies these features with the weights of the last layer of the hidden layer, sums them, and adds a bias term to form the final prediction output. In this step, each target feature is assigned a weight, reflecting its contribution to the prediction result. The weights and bias term are parameters learned through optimization algorithms during model training, and they determine the accuracy and reliability of the model's predictions. In the airflow prediction model, the result of the linear combination is the prediction coefficient, which intuitively represents the proportion of actual airflow to total intake airflow.

[0061] In one optional embodiment, multiple hidden layers in the airflow prediction model are used to extract features layer by layer from the preprocessed operating status data. This process aims to transform the original input into a higher-level feature representation that is more meaningful for airflow prediction through the nonlinear mapping of the neural network. Based on this, a linear combination operation is performed on the extracted target feature data to obtain a prediction coefficient closely related to the actual airflow, i.e., the ratio of airflow to total intake airflow. Real-time calculation of this prediction coefficient not only significantly reduces reliance on physical sensors but also significantly improves the accuracy and response speed of the vehicle ECU in airflow prediction, playing a crucial role in improving engine performance and reducing maintenance costs.

[0062] Optionally, the multiple hidden layers include: a first hidden layer, a second hidden layer, and a third hidden layer; the airflow prediction model utilizes multiple hidden layers to perform layer-by-layer feature extraction on the operating status data to obtain target feature data, including: using the first hidden layer to perform preliminary feature extraction on the operating status data to obtain first feature data, wherein the first feature data is used to represent the preliminary feature representation of the operating status data; using the second hidden layer to perform deep feature extraction on the first feature data to obtain second feature data used to represent the deep feature representation of the operating status data; and using the third hidden layer to perform feature extraction on the second feature data to obtain target feature data.

[0063] The aforementioned first hidden layer can refer to the hidden layer closest to the input layer in the airflow prediction model, as it directly receives data from the input layer. The first hidden layer can include, but is not limited to, fully connected layers, convolutional layers, etc., and the specific first hidden layer needs to be determined based on the specific application scenario and data type. The first hidden layer can be used for preliminary feature extraction, transforming the input data into preliminary feature representations. These representations are typically the result of linear combinations and nonlinear transformations of the input data.

[0064] The aforementioned second hidden layer can refer to a hidden layer located after the first hidden layer. The second hidden layer can include, but is not limited to, fully connected layers, convolutional layers, etc., and the specific second hidden layer needs to be determined based on the specific application scenario and data type. The second hidden layer can be used to further refine the features output by the first hidden layer, learning deeper feature combinations through more weights and neurons. The second hidden layer can enhance the model's non-linear fitting ability and uncover more complex relationships in the data.

[0065] The aforementioned third hidden layer refers to the hidden layer near the output layer in an airflow prediction model. It is responsible for transforming deeper feature representations into features that can be directly used for prediction. The third hidden layer can include, but is not limited to, fully connected layers, convolutional layers, etc., and the specific third hidden layer needs to be determined based on the specific application scenario and data type. The third hidden layer can be used to process the features output by the second hidden layer in more detail, preparing for the final prediction. The third hidden layer typically needs to focus more on features directly related to the prediction target.

[0066] The aforementioned first feature data can refer to the intermediate representation obtained after preliminary processing and feature extraction of the original operating state data in the first hidden layer. It is formed by weighted summation of input data through neurons and transformation using activation functions such as the Corrected Linear Unit (ReLU), and includes preliminary refinement and pattern recognition results of the original data. The type and form of the first feature data vary depending on the characteristics of the input data and the model design. In the airflow prediction model, the first feature data can be a combination of weighted sums of parameters such as engine speed and throttle opening, as well as nonlinear variation results. Its specific form (such as numerical range, dimension, etc.) is determined by the design parameters of the first hidden layer.

[0067] The aforementioned second feature data can refer to a higher-level representation obtained after the second hidden layer performs further deep feature extraction on the first feature data. This stage of feature extraction is more in-depth, aiming to learn more complex and abstract patterns that are typically not easily observed directly from the raw operating state data. The type of second feature data depends on the specific model design and the input data. Compared to the first feature data, the second feature data usually contains more layers of abstract information and complex features obtained from deep learning, such as the combined effect of dynamic response features and static operating parameters. In airflow prediction models, these features can manifest as the combined effect of engine speed change rate and ambient pressure change, or the interaction between EGR opening and intake manifold temperature, etc.

[0068] In one optional embodiment, the airflow prediction model employs a multi-layered hidden layer structure, including a first hidden layer, a second hidden layer, and a third hidden layer. First, the first hidden layer in the airflow prediction model performs preliminary processing on the raw data (operating status data) to extract primary feature representations, i.e., the first feature data. Then, the second hidden layer delves deeper into the intrinsic relationships within the data, obtaining more abstract and profound feature representations, i.e., the second feature data. Finally, the third hidden layer synthesizes these feature information, further refining and extracting the target feature data crucial for airflow prediction. This hierarchical feature extraction design helps the model gradually understand and simulate complex airflow phenomena, improving prediction accuracy. Furthermore, by refining features layer by layer, it reduces the overall computational burden, ensuring the model can operate efficiently with the limited resources of the vehicle's ECU.

[0069] Optionally, the method further includes: using an optimization algorithm to search for a target hyperparameter combination from a preset hyperparameter search space; constructing an initial airflow prediction model based on the target hyperparameter combination; and training the initial airflow prediction model using training data to determine the airflow prediction model, wherein the training data is used to represent sample operating state data of the engine under different operating conditions.

[0070] The aforementioned optimization algorithms can refer to a class of mathematical methods used to find optimal solutions to functions. In neural network training, optimization algorithms are used to automatically adjust the model's hyperparameters to minimize or maximize certain evaluation metrics, such as prediction error or model performance, thereby achieving the goal of model adjustment. Optimization algorithms can include, but are not limited to, random search, grid search, Bayesian optimization, and genetic algorithms; the specific algorithm needs to be determined based on actual needs. Optimization algorithms can be used in the process of building airflow prediction models to find a better combination of hyperparameters from a pre-defined hyperparameter search space.

[0071] The aforementioned pre-defined hyperparameter search space refers to the range or set of hyperparameter values ​​that are manually set before the optimization algorithm begins. It defines the boundary of the optimization algorithm's exploration. Hyperparameters can be discrete or continuous, depending on the specific model and optimization requirements. The pre-defined hyperparameter search space provides a framework for the optimization algorithm. A reasonable search space setting can accelerate the algorithm's convergence speed, avoid ineffective exploration, and ensure that the found optimal solution is feasible and effective in practical applications.

[0072] The aforementioned target hyperparameter combination refers to a set of optimal hyperparameters found by an optimization algorithm within a predefined hyperparameter search space. It serves as the prerequisite and foundation for constructing the initial airflow prediction model. A reasonable target hyperparameter combination can improve the model's prediction accuracy while maintaining a lightweight model, taking into account the hardware limitations of the vehicle's ECU.

[0073] The aforementioned initial airflow prediction model refers to the first version of the prediction model built based on the target hyperparameter combination. It has not yet been trained with a large amount of data and only has a basic structure and parameter configuration. Building the initial model is the first step in the entire model development process. Based on this model, the model training process can begin, and the model parameters can be gradually adjusted to better suit the actual airflow prediction needs.

[0074] The training data mentioned above can refer to a dataset containing actual engine operating status data (input) and corresponding airflow measurements (output) under different operating conditions. It is used to train and adjust the airflow prediction model, ensuring that the model can learn the relationship between engine airflow and operating status from the data.

[0075] In one optional embodiment, an optimization algorithm is first used to determine a target hyperparameter combination from a pre-defined hyperparameter search space. The selection of hyperparameters directly affects the model's performance and resource consumption. The optimization algorithm can efficiently search in a complex hyperparameter space to find a combination that maintains high prediction accuracy while meeting the resource constraints of the vehicle's ECU. Next, based on the determined target hyperparameter combination, an initial airflow prediction model is constructed. Finally, iterative training is performed using collected training data, gradually adjusting the model parameters until the model converges, thereby determining the final airflow prediction model. The training data covers representative samples of the engine under different operating conditions, including but not limited to static features such as EGR opening, engine speed, target fuel injection quantity, throttle opening, intake manifold pressure, ambient pressure, and intake manifold temperature, as well as dynamic response features such as the rate of change of engine speed, fuel quantity, and pressure. Through this comprehensive training data, the model can learn the complex nonlinear relationship between airflow and input features under various operating conditions, thus possessing the ability to accurately predict in real-world vehicle environments.

[0076] Optionally, the optimization algorithm includes a global optimization algorithm and a local optimization algorithm; determining the target hyperparameter combination from the preset hyperparameter search space using the optimization algorithm includes: performing global optimization in the preset hyperparameter search space using the global optimization algorithm to obtain a first hyperparameter space; and performing local optimization in the first hyperparameter space using the local optimization algorithm to obtain the target hyperparameter combination.

[0077] The aforementioned global optimization algorithm refers to an optimization algorithm that finds the best combination of hyperparameters within the entire preset hyperparameter search space. Global optimization algorithms may include, but are not limited to, Bayesian optimization, genetic algorithms, and simulated annealing algorithms. The specific global optimization algorithm is determined based on the actual situation. Global optimization algorithms can be used to explore and identify key hyperparameter combinations that affect model performance, especially in complex models with a large hyperparameter space. They can effectively avoid the pitfalls of blind trial and error, improving the efficiency and quality of model optimization.

[0078] The aforementioned first hyperparameter space can refer to a subset of hyperparameter combinations containing high model performance potential, selected from the preset hyperparameter search space after the global optimization algorithm is executed. Determining the first hyperparameter space provides a more precise search range for subsequent local optimization, reducing computational costs.

[0079] The aforementioned local optimization algorithm refers to an algorithm that further refines the search within the first hyperparameter space selected by the global optimization algorithm to find the target hyperparameter combination. Local optimization algorithms may include, but are not limited to, grid search, gradient descent, and gradient ascent; the specific local optimization algorithm needs to be determined based on actual requirements. Local optimization algorithms can be used to perform more detailed and accurate parameter optimization based on the preliminary results of global optimization.

[0080] In one optional embodiment, firstly, a global optimization algorithm is used to perform a global exploration in a preset hyperparameter search space. The purpose of this stage is to quickly and efficiently select a first hyperparameter space with excellent performance in a high-dimensional space. The global optimization algorithm can avoid the problem of local optima and ensure the comprehensiveness of the search range. Subsequently, a local optimization algorithm is used to perform refined local optimization within the first hyperparameter space. The purpose of this stage is to further fine-tune the parameters within the selected excellent parameter range with low computational cost, achieving a balance between prediction accuracy and computational resource consumption, thereby obtaining the target hyperparameter combination. The combination of global optimization and local optimization can not only effectively utilize computational resources and avoid resource waste caused by blind search, but also ensure that the target hyperparameter combination has both global optimization potential and local detail improvement, ultimately achieving efficient construction and adjustment of a lightweight neural network model. Through the above two-stage optimization strategy, the model can meet the strict requirements of the vehicle ECU for computational resources and response time while maintaining high prediction accuracy, ensuring the model's adaptability and real-time performance.

[0081] Optionally, a global optimization algorithm is used to perform global optimization in a preset hyperparameter search space to obtain a first hyperparameter space, including: determining the optimization objective and constraints in the preset hyperparameter search space; and performing global optimization in the preset hyperparameter search space based on the optimization objective and constraints to obtain the first hyperparameter space.

[0082] The aforementioned optimization objectives can refer to the metrics or functions to be minimized or maximized during hyperparameter optimization. For airflow prediction models, optimization objectives can include, but are not limited to, minimizing prediction error, such as minimizing mean absolute error (MAE) and root mean squared error (RMSE); controlling model complexity, such as minimizing model size, reducing computational complexity, and controlling model training time; and improving generalization ability, such as maximizing cross-validation scores and minimizing prediction errors on the validation set, ensuring that the model performs well not only on training data but also maintains stable performance on unknown data. These optimization objectives need to be determined based on the specific circumstances. The optimization objectives determine the direction of model optimization and serve as the basis for adjusting and selecting hyperparameter combinations in the optimization algorithm. In the optimization process of airflow prediction models, optimization objectives help the algorithm identify which hyperparameter combinations can bring smaller prediction errors and better model performance, thereby improving the accuracy of the model's airflow prediction.

[0083] The constraints mentioned above can refer to conditions or limits that need to be met during the optimization process. For airflow prediction models for vehicle ECUs, constraints may include, but are not limited to, model size limitations, prediction time limitations, storage space limitations, and energy consumption limitations. Constraints are used to ensure that the final results are feasible in real-world application scenarios.

[0084] In one optional embodiment, the global optimization algorithm, based on a pre-defined hyperparameter search space, determines optimization objectives and constraints, such as minimizing the Mean Absolute Percentage Error (MAPE) and ensuring that the model size and prediction time meet the resource limitations of the vehicle ECU. The algorithm intelligently selects combinations of hyperparameters to be evaluated from a broad hyperparameter space. This process helps ensure that the model maintains high prediction accuracy even under resource-constrained conditions. The first hyperparameter space obtained through optimization not only includes key parameters of the neural network structure, such as the number of neurons and layers, but also covers adjustment terms such as regularization coefficients, enabling the model to achieve a good balance between generalization ability and complexity.

[0085] For example, the initial optimization objective in the preset hyperparameter search space is to minimize the model prediction error, with constraints set as model size less than 100KB and single prediction time less than 0.1 seconds. Based on these optimization objectives and constraints, the global optimization algorithm efficiently searches within the preset hyperparameter space. Through multiple iterations and evaluations, the search range is gradually narrowed until it converges to the first hyperparameter space that meets the conditions. By defining the optimization objective and constraints within the preset hyperparameter search space, the global optimization algorithm effectively guides the search direction, avoids blind exploration, and greatly improves optimization efficiency. The numerical values ​​in the above steps are for illustrative purposes only; specific values ​​need to be determined based on actual needs and are not limited here.

[0086] Optionally, the initial airflow prediction model is trained using training data to determine the airflow prediction model, including: extracting features from the training data using the initial airflow prediction model to obtain sample feature data; performing a linear combination of the sample feature data to obtain sample prediction coefficients; determining a loss function based on the sample prediction coefficients and the sample labels corresponding to the training data; and adjusting the initial airflow prediction model using the loss function to obtain the airflow prediction model.

[0087] The aforementioned sample feature data refers to numerical vectors extracted from training data that describe the characteristics of the samples. In building an airflow prediction model, sample feature data typically originates from the preprocessing and feature engineering of input data (such as engine speed, throttle opening, etc.), including data normalization, feature selection, extraction, and transformation. Sample feature data is the core input for model training, determining the type and magnitude of information the model can learn from the data. Good feature data helps the model more accurately capture the relationship between input variables and airflow, improving prediction performance.

[0088] The aforementioned linear combination can refer to a mathematical operation that combines several vectors (sample feature data) through a weighted summation to produce a new vector or value. Linear combinations are used in model training to transform sample feature data into the output of the predictive model.

[0089] The aforementioned sample prediction coefficients may refer to the prediction coefficients obtained based on training data during the initial airflow prediction model training phase.

[0090] The loss function mentioned above can be a function that quantifies the difference between the model's predicted result and the true label. During model training, minimizing the loss function is the main goal of model optimization, and it directly guides the direction of adjusting the model parameters.

[0091] In one optional embodiment, feature extraction is performed on the training data using an initial airflow prediction model to obtain sample feature data. This process transforms the raw input data into a feature representation that the model can understand. Subsequently, the sample feature data is linearly combined to obtain sample prediction coefficients, which reflect the contribution of each feature to the prediction result. Next, based on the sample prediction coefficients and the corresponding sample labels of the training data (i.e., the ratio of actual airflow to total intake airflow), a loss function is determined. This function quantifies the deviation between the model's predicted and actual values. Finally, the initial airflow prediction model is adjusted using the loss function to obtain the final airflow prediction model. These steps effectively improve the accuracy of the model's airflow prediction, ensuring its stable operation and precise control in the vehicle ECU environment. Furthermore, interpretability analysis verifies the rationality and credibility of the model's decision-making process, playing a crucial role in improving the overall performance and functional safety of the engine control system.

[0092] Optionally, before inputting the operating status data into the airflow prediction model, the method further includes: performing correlation analysis on the initial operating status features to determine the correlation between the initial operating status features and the prediction coefficients; performing feature selection on the initial operating status data based on the correlation and a preset correlation threshold to obtain first operating status data, wherein the correlation corresponding to the first operating status data is greater than the preset correlation threshold; and preprocessing the first operating status data to determine the operating status data.

[0093] The correlation analysis mentioned above refers to a statistical method used to study the strength and direction of the relationship between two or more variables. In the construction of airflow prediction models, it is mainly used to evaluate the degree of correlation between different engine operating state characteristics and the target prediction (such as airflow). Correlation analysis can include, but is not limited to, correlation analysis based on Pearson correlation coefficient, correlation analysis based on Spearman rank correlation coefficient, etc. The specific correlation analysis method needs to be determined according to actual needs. Correlation analysis can be used to identify which features have a significant impact on the prediction results, thereby guiding feature selection, removing redundant or irrelevant features, and improving the efficiency and predictive performance of the model.

[0094] The aforementioned correlation refers to a quantitative indicator of the results of correlation analysis, usually expressed as a correlation coefficient, such as the Pearson correlation coefficient. It measures the strength of the linear relationship between two variables, typically ranging from -1 to 1. Correlation is used to determine the degree of association between a feature and the prediction target, helping to identify which features should be retained and which should be discarded due to weak correlation.

[0095] The aforementioned preset relevance threshold refers to a pre-set threshold. This threshold can be used as a criterion in feature selection. If a feature's relevance to the prediction target exceeds this threshold, it is considered to have sufficient influence on the prediction target and should be retained.

[0096] The aforementioned first running state data can refer to a set of feature data that is highly correlated with the prediction target and is retained after feature selection has been completed.

[0097] The aforementioned preprocessing refers to a series of processes performed on feature data to improve its quality and format, making it more suitable for model training. Preprocessing may include, but is not limited to, standardization / normalization, missing value handling, outlier detection and handling, and feature encoding. The specific preprocessing method needs to be determined based on actual needs. Preprocessing can improve model training efficiency, ensure the stability of the model training process and the accuracy of prediction results, and also help the model better understand and utilize feature data.

[0098] In one optional embodiment, correlation analysis is first performed on the collected engine operating status data to determine the correlation between initial operating status features such as EGR opening, engine speed, throttle opening, intake manifold pressure, intake air temperature, ambient pressure, speed change rate, fuel quantity change rate, and pressure change rate and the target output—the prediction coefficient. Next, feature selection is performed based on the correlation and a preset correlation threshold, filtering out features with low correlation to the prediction target, resulting in the first operating status data. This data preprocessing step not only reduces the number of input features and lowers model complexity but also ensures that the features used during model training are key indicators that significantly influence the prediction results, thereby improving the model's generalization ability and prediction accuracy, while also accelerating the model's training speed and prediction response time. Finally, the first operating status data is preprocessed, including cleaning, denoising, and standardization, to ensure data quality and consistency. Standardization (Z-score) is particularly crucial. By centering and scaling the data, it ensures that the input features have zero mean and unit variance, thereby accelerating the convergence speed of the neural network and avoiding gradient vanishing or exploding phenomena caused by large differences in feature scale, thus guaranteeing the stability of the model. The preprocessed runtime data, as input to the neural network, can be efficiently propagated and computed within the model, achieving accurate prediction of airflow. This series of preprocessing operations is the foundation for subsequent model training and prediction accuracy; their absence or inappropriateness will directly affect the performance of the virtual sensor.

[0099] Optionally, the method further includes controlling the engine based on the target airflow.

[0100] In one optional embodiment, the target airflow, predicted in real time by an airflow prediction model, is used as an input feedback signal to the engine management system to adjust the engine's control strategy. Specifically, key control parameters such as engine fuel injection quantity, ignition advance angle, and EGR opening can be adjusted based on the target airflow to ensure that the actual airflow of the engine accurately matches the target demand. The introduction of this control mechanism significantly improves the accuracy and response speed of engine control, especially under complex and variable operating conditions, enabling more flexible and efficient improvement of engine performance, reduced fuel consumption, reduced emissions, and enhanced engine stability and safety.

[0101] According to another aspect of the embodiments of this application, a method for training an airflow prediction model is also provided. Figure 2 This is a flowchart of a training method for an airflow prediction model according to an embodiment of this application, including:

[0102] Step S202: Use an optimization algorithm to determine the target hyperparameter combination from the preset hyperparameter search space.

[0103] Step S204: Construct an initial airflow prediction model based on the target hyperparameter combination.

[0104] Step S206: Train the initial airflow prediction model using training data to determine the airflow prediction model, wherein the airflow prediction model is used to execute the methods in the various embodiments of this application.

[0105] In one optional embodiment, a target hyperparameter combination is first determined from a pre-defined hyperparameter search space using an optimization algorithm. An initial airflow prediction model is then constructed based on this target hyperparameter combination and trained using training data to determine the final airflow prediction model. By employing an optimization algorithm to determine the hyperparameters, the parameter space can be efficiently explored to find the optimal configuration for model performance, avoiding the low training efficiency caused by blindly adjusting parameters. The determined target hyperparameter combination is used to construct the initial model, which, through learning and adaptation with the training dataset, is transformed into an airflow prediction model with accurate prediction capabilities. This method overcomes the problems of strong dependence on hyperparameter settings and low optimization efficiency in traditional model training, significantly improving the automation level and accuracy of model training. Especially in resource-constrained environments, such as in-vehicle ECUs, it enables rapid training and deployment of lightweight models, achieving the technical effect of improving airflow prediction accuracy.

[0106] In one alternative embodiment, Figure 3 This is a flowchart of a lightweight neural network airflow virtual sensor implementation method according to an embodiment of this application, such as... Figure 3 As shown, the method includes the following steps: Step S1, acquiring target engine data and target total air intake data, and performing preprocessing such as cleaning, denoising, and normalization on the data; Step S2, designing a neural network structure suitable for ECU deployment and selecting a computationally efficient activation function; Step S3, using a two-stage hybrid optimization framework of global Bayesian optimization + full factorial grid search to obtain the final hyperparameter combination at a controllable computational cost; Step S4, using the optimal hyperparameter configuration obtained through optimization to solidify the trained model, forming the final lightweight airflow virtual sensor model; Step S5, evaluating the model's prediction accuracy, actual model size, and single prediction time on the target vehicle ECU or its simulation environment on a test dataset that was not used for training, ensuring that it meets the deployment requirements of the vehicle ECU; Step S6, compiling the validated lightweight neural network model into a format suitable for the target vehicle ECU and integrating it into the control software of the vehicle ECU; Step S7, performing interpretable analysis on the lightweight model solidified in Step S4 to verify that the model's behavior conforms to physical expectations and enhance its credibility. Figure 3 Each step is represented by a rectangle, with arrows indicating the sequence of processes and the flow of data. It intuitively shows the entire process of virtual sensors from R&D to integrated application, from raw data acquisition and preprocessing to the design, optimization, solidification, and verification of neural network models, and finally to their deployment on the vehicle ECU and the transparent analysis of model behavior.

[0107] Specifically, step S1: On-board operating condition data acquisition and feature selection: Collect data of the engine under various representative operating conditions. The input features include at least EGR opening, engine speed, throttle opening, intake manifold pressure, intake air temperature, ambient pressure, speed change rate, fuel quantity change rate, and pressure change rate. The corresponding ratio of actual airflow to total intake airflow is collected as the output. The data is preprocessed, including cleaning, noise reduction, and Z-score standardization for neural networks.

[0108] Step S2: Lightweight Neural Network Structure Design: Design a lightweight neural network structure suitable for deployment in automotive ECUs, such as a shallow network structure with fewer hidden layers and fewer neurons, and select a computationally efficient activation function, such as the ReLU function.

[0109] Step S3: Model parameter optimization for lightweight and high accuracy: A two-stage hybrid optimization framework is adopted.

[0110] The first-stage Bayesian optimization algorithm excels at efficient global exploration in a vast and high-dimensional hyperparameter space, avoiding the loss of better lightweight solutions due to local optimizations. The second-stage full-factor grid search performs refined local optimization within the excellent parameter range selected in the first stage, thus obtaining the final hyperparameter combination at a controllable computational cost. The combination of the two achieves a complementary advantage between global exploration and local fine-tuning.

[0111] Step S4: Model Training and Consolidation: Using the optimized hyperparameter configuration, train the neural network model on the preprocessed dataset until convergence; consolidate the trained model parameters to form the final lightweight airflow virtual sensor model.

[0112] Step S5: Performance Verification and Vehicle ECU Adaptability Assessment: Evaluate the prediction accuracy, actual model size, and single prediction time of the solidified model on the untrained test dataset to ensure that it meets the deployment requirements of the vehicle ECU.

[0113] Step S6: Model Deployment: Compile or convert the validated lightweight neural network model into a format suitable for the target vehicle ECU, and integrate it into the control software of the vehicle ECU to predict engine airflow in real time, thereby assisting in fuel injection, air-fuel ratio control, etc.

[0114] Step S7: Model Interpretability Analysis and Validation: Perform interpretability analysis on the lightweight model solidified in Step S4, including: extracting the model's structural parameters (such as network layer configuration, neuron connection weights, biases, etc.); constructing an analytical database or decision basis matrix that can quantify the relationship between input features and the model's internal activation and output; and using visualization techniques to reveal the model's internal decision-making logic and key influencing features, in order to verify that the model's behavior conforms to physical expectations and enhance its credibility.

[0115] The aforementioned interpretability analysis and verification can be conducted using tools / processes developed based on virtual sensors. These tools / processes can extract parameters such as network topology, weight matrices of each layer, bias vectors, and activation functions from a fixed, lightweight neural network model. Based on the extracted parameters, quantitative relationships between input features and the activation of internal neurons and the final output can be established through methods such as model reverse engineering or layer-by-layer analysis, forming an analytical database or a verifiable decision basis matrix. Finally, the analytical results are presented through various visualization methods such as weight heatmaps, feature contribution maps, and local sensitivity analysis to help understand the model's decision-making behavior and generate interpretable reports.

[0116] In one optional embodiment, a lightweight neural network airflow virtual sensor for vehicle ECUs includes an input interface module, a data preprocessing module, a neural network prediction core module, and an output interface module.

[0117] The input interface module is used to receive real-time engine operating parameters from the vehicle bus or sensors, and the parameters are the input features listed in step S1.

[0118] The data preprocessing module is used to preprocess the received operating parameters as described in step S1, especially Z-score normalization;

[0119] The neural network prediction core module stores and executes a lightweight neural network model constructed according to the above implementation methods S1-S5. This model takes preprocessed operating parameters as input and calculates and outputs the predicted ratio of airflow to total intake airflow in real time. The model's structure and parameters undergo hybrid optimization in the two stages described above to achieve high prediction accuracy while meeting the resource constraints of the vehicle's ECU.

[0120] The output interface module is used to provide the predicted airflow value to other control algorithm modules of the vehicle ECU, such as fuel injection control and emission control.

[0121] The aforementioned lightweight neural network airflow virtual sensor, or its core module, is integrated and operates within the vehicle's ECU.

[0122] In one alternative embodiment, Figure 4 This is a schematic diagram of a lightweight neural network structure according to an embodiment of this application. The lightweight neural network structure consists of an input layer, three hidden layers, and an output layer, all connected via fully connected layers. The input layer receives preprocessed engine operating parameters, such as engine speed, throttle opening, intake manifold pressure, intake air temperature, EGR opening, target fuel injection quantity, ambient pressure, speed change rate, fuel quantity change rate, and pressure change rate. The output layer provides the ratio of actual airflow to total intake airflow. The hidden layers can use the ReLU activation function to improve the model's nonlinear fitting ability and computational efficiency. The number of neurons in each hidden layer can be 50, 48, or 45, respectively, indicating the lightweight strategy of the model, i.e., reducing the model size and computational consumption by reducing the number of neurons. The above values ​​are for illustrative purposes only; specific values ​​need to be determined according to actual needs and are not limited here.

[0123] According to an embodiment of this application, an embodiment of an engine airflow prediction device is provided. It should be noted that this device can be used to execute the aforementioned engine airflow prediction method. The specific implementation method and preferred application scenarios are the same as those in the above embodiment, and will not be repeated here.

[0124] Figure 5 This is a schematic diagram of an engine airflow prediction device according to an embodiment of this application, as shown below. Figure 5 As shown, the device includes: an acquisition module 502, a first determination module 504, a prediction module 506, and a second determination module 508.

[0125] The acquisition module 502 is used to acquire the current operating condition and running status data of the engine, wherein the running status data is used to describe the running status of the engine at the current moment; the first determination module 504 is used to determine the total intake air flow of the engine based on the current operating condition, wherein the total intake air flow is used to represent the theoretical maximum intake air volume of the engine under the current operating condition; the prediction module 506 is used to input the running status data into the air flow prediction model, and use the air flow prediction model to predict the intake air flow under the current operating condition to obtain the prediction coefficient, wherein the prediction coefficient is used to reflect the ratio of the actual air flow to the total intake air flow; the second determination module 508 is used to determine the target air flow of the engine based on the total intake air flow and the prediction coefficient, wherein the target air flow is used to represent the actual air flow of the engine under the current operating condition.

[0126] Optionally, the prediction module is used to extract features from the operating status data layer by layer using multiple hidden layers in the air flow prediction model to obtain target feature data; and to perform linear combination of the target feature data to obtain prediction coefficients.

[0127] Optionally, the multiple hidden layers include: a first hidden layer, a second hidden layer, and a third hidden layer; the prediction module is further configured to use the first hidden layer to perform preliminary feature extraction on the running state data to obtain first feature data, wherein the first feature data is used to represent the preliminary feature representation of the running state data; use the second hidden layer to perform deep feature extraction on the first feature data to obtain second feature data to represent the deep feature representation of the running state data; and use the third hidden layer to perform feature extraction on the second feature data to obtain target feature data.

[0128] Optionally, the device is also used to determine the target hyperparameter combination from the preset hyperparameter search space using an optimization algorithm; to construct an initial airflow prediction model based on the target hyperparameter combination; and to train the initial airflow prediction model using training data to determine the airflow prediction model, wherein the training data is used to represent sample operating state data of the engine under different operating conditions.

[0129] Optionally, the optimization algorithm includes a global optimization algorithm and a local optimization algorithm; the device is also used to perform global optimization in a preset hyperparameter search space using the global optimization algorithm to obtain a first hyperparameter space; and to perform local optimization in the first hyperparameter space using the local optimization algorithm to obtain a target hyperparameter combination.

[0130] Optionally, the device is also used to determine the optimization objective and constraints in the preset hyperparameter search space; based on the optimization objective and constraints, global optimization is performed in the preset hyperparameter search space to obtain the first hyperparameter space.

[0131] Optionally, the device is also used to extract features from the training data using the initial airflow prediction model to obtain sample feature data; to perform a linear combination of the sample feature data to obtain sample prediction coefficients; to determine a loss function based on the sample prediction coefficients and the sample labels corresponding to the training data; and to adjust the initial airflow prediction model using the loss function to obtain an airflow prediction model.

[0132] Optionally, before inputting the operating status data into the airflow prediction model, the device is also used to perform correlation analysis on the initial operating status characteristics to determine the correlation between the initial operating status characteristics and the prediction coefficients; to perform feature selection on the initial operating status data based on the correlation and a preset correlation threshold to obtain first operating status data, wherein the correlation corresponding to the first operating status data is greater than the preset correlation threshold; and to preprocess the first operating status data to determine the operating status data.

[0133] Optionally, the device can also be used to control the engine based on a target airflow.

[0134] According to another aspect of the embodiments of this application, a training apparatus for an airflow prediction model is also provided. Figure 6 This is a schematic diagram of a training device for an airflow prediction model according to an embodiment of this application, as shown below. Figure 6 As shown, the device includes: a third determining module 602, a construction module 604, and a training module 606.

[0135] The third determining module 602 is used to determine the target hyperparameter combination from the preset hyperparameter search space using an optimization algorithm; the construction module 604 is used to construct an initial airflow prediction model based on the target hyperparameter combination; the training module 606 is used to train the initial airflow prediction model using training data to determine the airflow prediction model, wherein the airflow prediction model is used to execute the methods in the various embodiments of this application.

[0136] Embodiments of this application also provide a vehicle, including: a memory storing an executable program; and a processor for running the program, wherein the program executes the methods described in various embodiments of this application when it runs.

[0137] Embodiments of this application also provide a computer-readable storage medium including a stored executable program, wherein, when the executable program is running, it controls the device where the computer-readable storage medium is located to perform the methods of various embodiments of this application.

[0138] Embodiments of this application also provide a computer program product, including a computer program that, when executed by a processor, implements the methods of various embodiments of this application.

[0139] Embodiments of this application also provide a computer program product, including a non-volatile computer-readable storage medium for storing a computer program that, when executed by a processor, implements the methods in various embodiments of this application.

[0140] Embodiments of this application also provide a computer program that, when executed by a processor, implements the methods described in the various embodiments of this application.

[0141] In the above embodiments of this application, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0142] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units can be a logical functional division, and in actual implementation, there may be other division methods. For instance, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.

[0143] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0144] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0145] If the integrated unit is implemented as 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 contributes to the prior art, or all or part of the 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 cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard drive, magnetic disk, or optical disk.

[0146] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.

Claims

1. A method for predicting the airflow of an engine, characterized in that, include: Acquire the current operating condition and running status data of the engine, wherein the running status data is used to describe the running status of the engine at the current moment; The total intake air flow of the engine is determined based on the current operating conditions, wherein the total intake air flow is used to represent the theoretical maximum intake air volume of the engine under the current operating conditions; The operating status data is input into the air flow prediction model, and the air flow prediction model is used to predict the intake flow under the current operating conditions to obtain the prediction coefficient. The prediction coefficient is used to reflect the ratio of the actual air flow to the total intake flow. Based on the total intake airflow and the prediction coefficient, the target airflow of the engine is determined, wherein the target airflow represents the actual airflow of the engine under the current operating conditions.

2. The method according to claim 1, characterized in that, The operating status data is input into the airflow prediction model, and the airflow prediction model is used to predict the intake airflow under the current operating conditions to obtain prediction coefficients, including: The target feature data is obtained by extracting features layer by layer from the operating status data using multiple hidden layers in the air flow prediction model. The target feature data are linearly combined to obtain the prediction coefficients.

3. The method according to claim 2, characterized in that, The multiple hidden layers include: a first hidden layer, a second hidden layer, and a third hidden layer; the airflow prediction model utilizes these multiple hidden layers to perform layer-by-layer feature extraction on the operational status data, obtaining target feature data, including: The first hidden layer is used to perform preliminary feature extraction on the running status data to obtain first feature data, wherein the first feature data is used to represent the preliminary feature representation of the running status data; The second hidden layer is used to perform deep feature extraction on the first feature data to obtain the second feature data, which is used to represent the deep feature representation of the running state data. The target feature data is obtained by extracting features from the second feature data using the third hidden layer.

4. The method according to claim 1, characterized in that, The method further includes: The target hyperparameter combination is determined by using an optimization algorithm to search the preset hyperparameter space; An initial airflow prediction model is constructed based on the target hyperparameter combination; The initial airflow prediction model is trained using training data to determine the airflow prediction model, wherein the training data is used to represent sample operating state data of the engine under different operating conditions.

5. The method according to claim 4, characterized in that, The optimization algorithm includes a global optimization algorithm and a local optimization algorithm; the optimization algorithm is used to determine the target hyperparameter combination from a preset hyperparameter search space, including: The global optimization algorithm is used to perform global optimization in the preset hyperparameter search space to obtain the first hyperparameter space; The target hyperparameter combination is obtained by performing local optimization in the first hyperparameter space using the local optimization algorithm.

6. The method according to claim 5, characterized in that, The global optimization algorithm is used to perform global optimization in the preset hyperparameter search space to obtain a first hyperparameter space, including: Determine the optimization objective and constraints in the preset hyperparameter search space; Based on the optimization objective and the constraints, global optimization is performed in the preset hyperparameter search space to obtain the first hyperparameter space.

7. The method according to claim 4, characterized in that, The initial airflow prediction model is trained using training data to determine the airflow prediction model, including: The initial airflow prediction model is used to extract features from the training data to obtain sample feature data. The sample feature data are linearly combined to obtain the sample prediction coefficients; The loss function is determined based on the sample prediction coefficients and the sample labels corresponding to the training data; The initial airflow prediction model is adjusted using the loss function to obtain the airflow prediction model.

8. The method according to claim 1, characterized in that, Before inputting the operational status data into the airflow prediction model, the method further includes: A correlation analysis is performed on the initial operating state characteristics to determine the correlation between the initial operating state characteristics and the prediction coefficients; Feature selection is performed on the initial running state data based on the correlation and a preset correlation threshold to obtain first running state data, wherein the correlation corresponding to the first running state data is greater than the preset correlation threshold. The first operating status data is preprocessed to determine the operating status data.

9. The method according to claim 1, characterized in that, The method further includes: The engine is controlled based on the target airflow.

10. A training method for an airflow prediction model, characterized in that, include: The target hyperparameter combination is determined by using an optimization algorithm to search the preset hyperparameter space; An initial airflow prediction model is constructed based on the target hyperparameter combination; The initial airflow prediction model is trained using training data to determine the airflow prediction model, wherein the airflow prediction model is used to perform the method described in any one of claims 1 to 9.

11. A vehicle, characterized in that, include: Memory, which stores executable programs; A processor for running the program, wherein the program, when running, performs the method according to any one of claims 1 to 9.

12. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored executable program, wherein, when the executable program is executed, it controls the device on which the storage medium is located to perform the method according to any one of claims 1 to 9.

13. A computer program product, characterized in that, Includes a computer program that, when executed by a processor, implements the method according to any one of claims 1 to 9.