A method and device for controlling tailgate driving state
By obtaining the status data of the tailgate drive system for preprocessing and analysis, and determining the drive status in real time, the problem of balancing safety and accuracy in traditional tailgate safety systems is solved, and the safety of the tailgate drive system and user experience are improved.
Patent Information
- Application Number
- CN202411314628.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-20
- Publication Date
- 2025-09-23
- Estimated Expiration
- 2044-09-20
AI Technical Summary
Traditional tailgate safety systems struggle to strike a balance between the sensitivity and false alarm rate of anti-pinch detection, resulting in the inability to improve both safety and accuracy simultaneously, impacting user experience and trust.
By obtaining the status data of the tailgate drive system, including movement speed, acceleration, motor current and anti-pinch monitoring result signals, and pre-processing them before inputting them into the drive state analysis model, the state probability of each drive state is obtained, and the drive state with the maximum state probability is used as the real-time judgment state to control the tailgate drive system.
Accurate control of the tailgate drive system is achieved, avoiding false triggering caused by high sensitivity and unsafe issues caused by low sensitivity, improving safety and user experience.
Smart Images

Figure CN119221789B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of vehicle body domain control technology, and in particular to a method and device for controlling the driving state of a tailgate. Background Art
[0002] With the continuous advancement of safety technology, tailgate safety systems have become an integral part of vehicle design. The primary purpose of a tailgate safety system is to prevent pinching injuries during tailgate operation. Traditional tailgate safety systems typically compare the real-time status of physical sensors or drive motors with preset anti-pinch thresholds to detect whether objects or human parts are in the tailgate's closing path. Once an obstacle is detected, the system triggers the anti-pinch protection mechanism, stopping or reversing the tailgate's movement to prevent injury.
[0003] However, traditional tailgate safety systems often face a trade-off between anti-pinch detection sensitivity and false alarm rate during design. While a higher sensitivity is recommended for improved safety, it also increases the likelihood of false triggering of the anti-pinch function, reducing the accuracy of anti-pinch detection. This impacts user experience and can lead to a decrease in user trust in the system. Lower sensitivity can reduce the false alarm rate and improve accuracy, but it cannot guarantee that the anti-pinch function will be effectively triggered when an obstacle is detected. This not only reduces user trust in the system but also risks the tailgate continuing to move due to the inability to effectively trigger the anti-pinch function, causing direct damage to the obstacle and compromising safety.
[0004] Therefore, how to provide a solution to the above technical problems is a problem that those skilled in the art need to solve. Summary of the Invention
[0005] In view of this, embodiments of the present application provide a method and device for controlling the driving state of a tailgate, so as to solve the problem in the prior art that the safety and accuracy of the anti-pinch function of a traditional tailgate safety system cannot be improved simultaneously.
[0006] According to a first aspect of an embodiment of the present application, a method for controlling a tailgate driving state is provided, comprising:
[0007] Acquiring status data of a tailgate drive system; the tailgate drive system includes a drive motor and a tailgate controlled by the drive motor; the status data includes a movement speed of the tailgate, an acceleration of the movement speed, a motor current of the drive motor, a current change value of the motor current, and an anti-pinch monitoring result signal; the anti-pinch monitoring result signal is used to indicate a real-time anti-pinch monitoring result determined based on at least one of the movement speed, acceleration, motor current, and current change value;
[0008] Preprocessing of status data;
[0009] The pre-processed state data is input into the driving state analysis model to obtain the state probability corresponding to each driving state output by the driving state analysis model, and the driving state corresponding to the maximum state probability is used as the real-time driving state; the driving state includes normal driving state, correctly triggered anti-pinch state, and incorrectly triggered anti-pinch state;
[0010] Based on the real-time determination of the driving status, the tailgate drive system is controlled.
[0011] A second aspect of an embodiment of the present application provides a device for controlling a tailgate driving state, comprising:
[0012] a data acquisition module for acquiring status data of a tailgate drive system; the tailgate drive system includes a drive motor and a tailgate controlled by the drive motor; the status data includes a movement speed of the tailgate, an acceleration of the movement speed, a motor current of the drive motor, a current change value of the motor current, and an anti-pinch monitoring result signal; the anti-pinch monitoring result signal is used to indicate a real-time anti-pinch monitoring result determined based on at least one of the movement speed, acceleration, motor current, and current change value;
[0013] Data preprocessing portal, used to preprocess status data;
[0014] The state analysis module is used to input the pre-processed state data into the driving state analysis model, obtain the state probability corresponding to each driving state output by the driving state analysis model, and use the driving state corresponding to the maximum state probability as the real-time driving state; the driving state includes the normal driving state, the correctly triggered anti-pinch state, and the incorrectly triggered anti-pinch state;
[0015] The control module is used to control the tailgate drive system based on real-time determination of the drive status.
[0016] According to a third aspect of an embodiment of the present application, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above method when executing the computer program.
[0017] Compared with the prior art, the beneficial effects of the embodiments of the present application include at least the following: the embodiments of the present application obtain multiple status data based on the drive motor and the tailgate, pre-process these status data and input them into the drive status analysis model to obtain the state probability of each drive state corresponding to the current state data, and use the drive state with the largest state probability as the real-time determination drive state for controlling the tailgate drive system. The drive states with state probabilities include normal drive state, correctly triggered anti-pinch state and incorrectly triggered anti-pinch state. The real-time determination of the drive state can accurately and reliably reflect whether the current tailgate drive system is normal or needs adjustment, thereby controlling the tailgate drive system while ensuring the safety and accuracy of the tailgate drive system and improving user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the embodiments or descriptions of the prior art. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0019] Figure 1 This is a schematic diagram of an application scenario of an embodiment of the present application;
[0020] Figure 2 1 is a flow chart of a method for controlling a tailgate driving state provided in an embodiment of the present application;
[0021] Figure 3 This is a schematic diagram of processing status data provided by an embodiment of the present application;
[0022] Figure 4 Schematic diagram of a tailgate driving state control device provided by an embodiment of the present application;
[0023] Figure 5 This is a structural diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0024] In the following description, specific details such as specific system structures and techniques are provided for purposes of illustration rather than limitation to facilitate a thorough understanding of the embodiments of the present application. However, it will be apparent to those skilled in the art that the present application may be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to avoid obscuring the description of the present application with unnecessary detail.
[0025] A method and device for controlling a tailgate driving state according to an embodiment of the present application will be described in detail below with reference to the accompanying drawings.
[0026] Figure 1 1 is a schematic diagram of an application scenario of an embodiment of the present application. The application scenario may include a first terminal device 101, a second terminal device 102, a third terminal device 103, a server 104, and a network 105.
[0027] The first terminal device 101, the second terminal device 102, and the third terminal device 103 can be hardware or software. When the first terminal device 101, the second terminal device 102, and the third terminal device 103 are hardware, they can be various electronic devices with a display screen and support communication with the server 104, including but not limited to vehicle systems, smart phones, tablet computers, laptop portable computers, and desktop computers; when the first terminal device 101, the second terminal device 102, and the third terminal device 103 are software, they can be installed in the above electronic devices. The first terminal device 101, the second terminal device 102, and the third terminal device 103 can be implemented as multiple software or software modules, or as a single software or software module, and this embodiment of the application is not limited to this. Furthermore, various applications can be installed on the first terminal device 101, the second terminal device 102, and the third terminal device 103, such as data processing applications, instant messaging tools, social platform software, search applications, shopping applications, etc.
[0028] Server 104 can be a server that provides various services, such as a backend server that receives requests sent by terminal devices that establish communication connections with it. The backend server can receive and analyze the requests sent by the terminal devices, and generate processing results. Server 104 can be a single server, a server cluster consisting of multiple servers, or a cloud computing service center, and the embodiments of the present application are not limited thereto.
[0029] It should be noted that the server 104 can be either hardware or software. When the server 104 is hardware, it can be various electronic devices that provide various services to the first terminal device 101, the second terminal device 102, and the third terminal device 103. When the server 104 is software, it can be multiple software or software modules that provide various services to the first terminal device 101, the second terminal device 102, and the third terminal device 103, or it can be a single software or software module that provides various services to the first terminal device 101, the second terminal device 102, and the third terminal device 103, and this embodiment of the application is not limited to this.
[0030] The network 105 can be a wired network connected by coaxial cable, twisted pair and optical fiber, or it can be a wireless network that can interconnect various communication devices without wiring, such as Bluetooth, Near Field Communication (NFC), infrared, etc., which is not limited in the embodiments of the present application.
[0031] It should be noted that the specific types, quantities and combinations of the first terminal device 101, the second terminal device 102, the third terminal device 103, the server 104 and the network 105 can be adjusted according to the actual needs of the application scenario, and the embodiments of the present application do not limit this.
[0032] Figure 2 It is a flow chart of a method for controlling a tailgate driving state provided in an embodiment of the present application. Figure 2 The control method can be Figure 1 The first terminal device, the second terminal device, the third terminal device or the server executes. Figure 2 As shown, the control method includes:
[0033] S201: Acquiring status data of a tailgate drive system; the tailgate drive system includes a drive motor and a tailgate controlled by the drive motor. The status data includes a movement speed of the tailgate, an acceleration of the movement speed, a motor current of the drive motor, a current change value of the motor current, and an anti-pinch monitoring result signal; the anti-pinch monitoring result signal is used to indicate a real-time anti-pinch monitoring result determined based on at least one of the movement speed, acceleration, motor current, and current change value;
[0034] S202: Preprocessing the status data;
[0035] S203: Inputting the pre-processed state data into a driving state analysis model to obtain the state probabilities corresponding to each driving state output by the driving state analysis model, and taking the driving state corresponding to the maximum state probability as the real-time driving state; the driving state includes a normal driving state, a correctly triggered anti-pinch state, and an incorrectly triggered anti-pinch state;
[0036] S204: Control the tailgate driving system based on the real-time determination of the driving state.
[0037] It will be appreciated that the method of this embodiment monitors the tailgate drive system by acquiring status data of the tailgate drive system, analyzing the current real-time determined driving state of the tailgate drive system, and further controlling the tailgate drive system based on the real-time determined driving state. During this process, the method of this embodiment selects reliable status data, pre-processes the status data, and then inputs the status data into a drive state analysis model. This analysis model derives the state probabilities of a normal drive state, a correctly triggered anti-pinch state, and an erroneously triggered anti-pinch state. The drive state with the highest state probability is used as the real-time determined driving state, reflecting the most likely actual state of the current tailgate drive system, namely, the current tailgate drive system is in a normal drive state, in an anti-pinch state with a correct trigger, or in an anti-pinch state with an erroneous trigger. Ultimately, the real-time determined driving state enables accurate control of the tailgate drive system, avoiding both the erroneous triggering problem caused by high sensitivity and the unsafe situation caused by low sensitivity, while simultaneously improving the safety of the tailgate and the user experience.
[0038] Specifically, this embodiment collects the necessary state data of the tailgate drive system in the anti-pinch mechanism. This state data changes over time, and the method of this embodiment continuously acquires this state data and performs subsequent operations. The state data in this embodiment includes, but is not limited to, the tailgate's movement speed and acceleration, the drive motor's motor current and current change value, and the anti-pinch monitoring result signal. To ensure the reliability and accuracy of the data, high-precision sensors such as MEMS accelerometers and Hall effect current sensors can be used. The anti-pinch monitoring result signal is used to indicate a real-time anti-pinch monitoring result determined based on at least one of the movement speed, acceleration, motor current, and current change value. The real-time anti-pinch monitoring result indicates whether an obstacle is currently trapped between the tailgate and the vehicle body. There are two real-time anti-pinch monitoring results corresponding to the presence or absence of an obstacle. The anti-pinch monitoring result signal is represented by two signals with different states. For example, if the real-time anti-pinch monitoring result at a certain moment indicates that an obstacle is currently trapped between the tailgate and the vehicle body, the anti-pinch monitoring result signal at that moment is represented by a high level. If no obstacle is currently trapped between the tailgate and the vehicle body, the anti-pinch monitoring result signal is represented by a low level. In traditional anti-pinch mechanisms, the anti-pinch monitoring result signal serves as the trigger for the anti-pinch action. The trigger condition can be set to trigger the anti-pinch action only when the anti-pinch monitoring result signal remains high for a certain window period. The length of this window in the trigger condition affects the sensitivity of the anti-pinch trigger, making it difficult to simultaneously ensure the safety and accuracy of the anti-pinch mechanism.
[0039] Therefore, the method of this embodiment pre-processes all state data and inputs it into the drive state analysis model. Based on the original trigger conditions, the state probability of the drive state corresponding to the current state data is further analyzed. Each state probability indicates the likelihood of that drive state occurring under that state data. A normal drive state indicates that the tailgate drive system is operating normally. A normal anti-pinch trigger state indicates that the tailgate drive system has triggered the anti-pinch action correctly, indicating that the tailgate does need to trigger the anti-pinch action. An erroneous anti-pinch trigger state indicates that the tailgate drive system has triggered the anti-pinch action incorrectly, indicating that the tailgate does not need to trigger the anti-pinch action. Using the most likely drive state as the basis for subsequent control of the tailgate drive system further improves the accuracy of control of the tailgate drive system.
[0040] It is understandable that before inputting the state data into the driving state analysis model, the state data needs to be preprocessed, which may include data filtering, outlier removal, data normalization, etc., to improve the quality of the state data input into the driving state analysis model. Therefore, the process of preprocessing the state data includes:
[0041] Perform noise filtering on state data;
[0042] Remove outliers from the noise-filtered state data;
[0043] Normalize the state data after removing outliers.
[0044] Specifically, noise filtering requires selecting a filtering method specifically based on the characteristics of various state data.
[0045] The tailgate's velocity data is typically continuous and contains short-term fluctuations and noise. These fluctuations can be caused by sensor accuracy, environmental changes, or mechanical vibration. Moving average filtering is a simple and effective smoothing technique that smooths data by calculating the local average of data points. It is suitable for removing short-term fluctuations and noise in velocity.
[0046] Correspondingly, the acceleration data of the motion velocity varies dramatically, especially when the tailgate is started or stopped, where large fluctuations occur. The Kalman filter is a recursive filtering algorithm suitable for processing noise in dynamic systems. It updates the state estimate at each time step and is well-suited for real-time acceleration data processing. It can continuously perform state estimation and noise suppression in the data stream.
[0047] Accordingly, motor current data contains high-frequency noise caused by electromagnetic interference (EMI) or power supply fluctuations. Current changes are generally smooth, but can fluctuate significantly during startup or load changes. Low-pass filtering allows low-frequency signals to pass while blocking high-frequency noise. It is suitable for removing high-frequency noise from motor current data while retaining the useful low-frequency signal.
[0048] Accordingly, the current variation contains spike noise, which may be caused by instantaneous current fluctuations or sensor failure. Median filtering smoothes the data by taking the median of the data within a local window, removing spike noise. It is particularly effective for removing spike noise while preserving the edge information of the data.
[0049] Accordingly, the data of the anti-pinch monitoring result signal contains noise caused by sensor delay or fluctuations in system response time. Exponential smoothing smoothes the data by assigning exponential decay weights to historical data, which can effectively deal with the noise of the anti-pinch monitoring result signal.
[0050] Therefore, the process of noise filtering the state data may include:
[0051] Perform moving average filtering on the motion speed;
[0052] Perform Kalman filtering on the acceleration;
[0053] Low-pass filtering of the motor current;
[0054] Perform median filtering on the current change value;
[0055] Perform exponential smoothing filtering on the anti-pinch monitoring result signal.
[0056] It is understandable that, in this embodiment, when noise filtering is performed on the status data, a specific filtering algorithm may be selected based on the actual performance of the status data and user needs. The above is merely an example and is not intended to be limiting.
[0057] Furthermore, the process of removing outliers from the noise-filtered state data includes:
[0058] Based on the Z-score analysis method, outliers are removed from each state data after noise filtering.
[0059] It is understood that the Z-score analysis method is used to identify and remove outliers in a data set. The specific processing steps include:
[0060] Calculate the mean and standard deviation;
[0061] For each data point in the dataset, calculate its Z score.
[0062] Data points whose absolute values of the Z scores exceed the preset threshold are removed as outliers.
[0063] The Z-score is calculated as: Z = (X - μ) / σ. Here, X is the value of the current data point, μ is the mean of the dataset, and σ is the standard deviation of the dataset. The preset threshold can be set to 3 or another value, depending on the desired concentration of the data. After removing outliers from the original state data, the remaining state data will be more concentrated and consistent, which helps improve the accuracy of subsequent analysis.
[0064] It will be appreciated that in this embodiment, the state data is normalized using a maximum-minimum normalization method to linearly scale all state data values to a range of 0 to 1, while preserving the original relationship between the values. The specific processing of each state data includes determining a maximum value (Max) and a minimum value (Min), and then, for each data point, determining the normalized value according to a normalization formula. The normalization formula is: X' = (X-Min) / (Max-Min), where X is the value before normalization and X' is the value after normalization.
[0065] It is understandable that the noise filtering, outlier removal and data normalization of the state data can be done as follows: Figure 3 The state data is then input into a driving state analysis model to obtain state probabilities corresponding to the three driving states. The driving state analysis model may adopt an MLP (Multilayer Perceptron) neural network structure. The specific structure and training process of the model may be found in the following embodiments.
[0066] Furthermore, after obtaining the real-time determination of the driving state, the real-time determination of the driving state is used as a control reference to control the tailgate drive system. It is understood that the operation of the tailgate drive system is subject to various controls and constraints, such as received user commands, monitoring of trigger conditions for anti-pinch actions, and real-time determination of the driving state based on status data of the tailgate drive system. Monitoring the trigger conditions for anti-pinch actions refers to the tailgate drive system determining, based on the anti-pinch monitoring result signal, that the trigger conditions are satisfied and preparing to execute the anti-pinch action, at which point an anti-pinch triggering event occurs. Depending on whether the triggering determination result is consistent with the facts, such events are further divided into correctly triggered anti-pinch events and incorrectly triggered anti-pinch events. Correctly triggered anti-pinch events require the tailgate drive system to execute the anti-pinch action, while incorrectly triggered anti-pinch events require the tailgate drive system to not execute the anti-pinch action. That is, in the event of an incorrectly triggered anti-pinch event, i.e., when the tailgate drive system is about to execute the anti-pinch action, if it determines that the anti-pinch action was incorrectly triggered, the anti-pinch action should not be executed. Therefore, this embodiment actually adds the real-time determination of the driving state to the control factors of the tailgate drive system and serves as an important control constraint. The tailgate drive system will be supervised by the real-time determination of the driving state during operation. Once the tailgate drive system triggers an anti-pinch event, but this event is an erroneous anti-pinch event, the real-time determination of the driving state at this moment is an erroneous anti-pinch state. The tailgate drive system should not be allowed to perform the anti-pinch action. This prohibition is usually achieved by disabling the anti-pinch function. Specifically, the process of controlling the tailgate drive system based on the real-time determination of the driving state includes:
[0067] When the driving state is determined to be a normal driving state or the anti-pinch state is correctly triggered in real time, the configuration of the tailgate driving system is set to enable the anti-pinch function;
[0068] When it is determined in real time that the driving state is an erroneously triggered anti-pinch state, the configuration of the tailgate driving system is set to prohibit enabling the anti-pinch function at the current moment.
[0069] It is understood that when the tailgate drive system is configured to enable the anti-pinch function, the anti-pinch action is permitted, and when the tailgate drive system is configured to disable the anti-pinch function, the anti-pinch action is not permitted. The method of this embodiment is continuously executed at a specific frequency, and whether the anti-pinch function is enabled will change as the real-time determination of the drive state is updated. If the real-time determination of the drive state updates from the error-triggered anti-pinch state to the normal start state or the normal trigger anti-pinch state, the configuration will change to enable the anti-pinch function, thereby allowing the anti-pinch action to be executed when the trigger condition is met.
[0070] The method of the embodiment of the present application obtains multiple status data based on the drive motor and the tailgate, pre-processes these status data, and then inputs them into the drive status analysis model to obtain the state probability of each drive state corresponding to the current state data, and uses the drive state with the largest state probability as the real-time determination drive state for controlling the tailgate drive system. The drive states with state probabilities include normal drive state, correctly triggered anti-pinch state, and incorrectly triggered anti-pinch state. The real-time determination of the drive state can accurately and reliably reflect whether the current tailgate drive system is normal or needs adjustment, thereby controlling the tailgate drive system, while ensuring the safety and accuracy of the tailgate drive system and improving user experience.
[0071] When executing the method of this embodiment, the driving state analysis model can adopt an MLP (Multilayer Perceptron) neural network structure. The number of neurons in the input layer corresponds to the type of state data, the number of neurons in the output layer corresponds to the number of driving states, and the number of hidden layers and the number of neurons in the hidden layers can be set according to actual conditions or user needs. The number of neurons in each hidden layer is generally not less than the number of neurons in the input layer and the output layer. Therefore, the neural network structure of the driving state analysis model includes an input layer, at least one hidden layer, and an output layer connected in sequence.
[0072] The input layer includes five input layer neurons, each of which is used to receive a corresponding state data;
[0073] The output layer includes three output layer neurons, and each output layer neuron is used to output the state probability of a corresponding driving state.
[0074] Furthermore, each hidden layer includes a plurality of hidden neurons;
[0075] Each hidden layer neuron and each output layer neuron includes a linear transformation unit and a nonlinear transformation unit connected in sequence.
[0076] It is understandable that due to the different positions of neurons, the activation functions of the corresponding nonlinear transformation units are also different. Specifically:
[0077] The nonlinear transformation unit of the hidden layer neurons is used to perform nonlinear transformation based on the ReLU activation function;
[0078] The nonlinear transformation unit of the output layer neurons is used to perform nonlinear transformation based on the softmax activation function.
[0079] In an exemplary embodiment, the neural network structure of the driving state analysis model includes an input layer, two hidden layers, and an output layer connected in sequence, wherein:
[0080] The input layer includes five input layer neurons, each of which is used to receive a type of state data;
[0081] The first hidden layer can contain 64 hidden neurons. A larger number of hidden neurons helps extract high-dimensional features from the state data. These high-dimensional features can better represent the complexity of the input data, thereby improving the model's ability to distinguish different events. This is especially true for false triggering of anti-pinch events, where the analysis model needs to identify subtle feature differences. High-dimensional features can provide richer information. Each of the 64 hidden neurons in the first hidden layer consists of a linear transformation unit and a nonlinear transformation unit connected in sequence.
[0082] Here, the linear transformation unit linearly transforms the data of the five input layer neurons into a 64-dimensional feature space. The calculation of the linear transformation is expressed as:
[0083]
[0084] Among them, z(j) is the result of the linear transformation of the jth hidden layer neuron, w(i,j) is the weight corresponding to the i-th input layer neuron and the j-th hidden layer neuron, x(i) is the data feature of the i-th input layer neuron, b(j) is the bias term of the j-th hidden layer neuron, the value of i is the serial number of the input layer neuron, and the value of j is the serial number of the hidden layer neuron.
[0085] Furthermore, the nonlinear transformation unit performs nonlinear transformation based on the ReLU (Rectified Linear Unit) activation function. The nonlinear transformation can introduce nonlinear features. The ReLU activation function can set all negative values to zero and keep the positive values unchanged. Its formula is: a(j) = max(0, z(j)), where a(j) is the result of the nonlinear transformation of the j-th hidden layer neuron.
[0086] Similarly, the second hidden layer can be configured with 32 hidden neurons, with the structure of each hidden neuron identical in both hidden layers. The 64-dimensional features output by the first hidden layer are passed to the second hidden layer, where each hidden neuron performs linear and nonlinear transformations on the 64-dimensional features. The nonlinear transformations also use the ReLU activation function. By reducing the number of neurons, the second hidden layer can compress and combine the high-order features extracted by the first hidden layer, helping to reduce data complexity and prevent overfitting while preserving important feature information.
[0087] Similarly, the output layer neurons receive the output data of the second hidden layer. The linear transformation unit in each output layer neuron performs a linear transformation on the output data, and then the nonlinear transformation unit performs a nonlinear transformation. Assume that the result of the linear transformation is zo(k), where k represents the sequence number of the output layer neuron, and the value range can be 1-3. The nonlinear transformation uses the softmax activation function. The output of the softmax activation function is a probability distribution, which represents the probability that the output data belongs to this category. The formula is:
[0088]
[0089] σ(k) is the output result of the kth output layer neuron, and n is the neuron index of the output layer.
[0090] It's clear that through the layer-by-layer feature extraction and combination of the first and second hidden layers, the model forms a hierarchical feature representation, enabling it to more accurately identify and distinguish different event types, particularly falsely triggered anti-pinch events. The nonlinearity introduced by the ReLU activation function and the probability distribution output provided by the Softmax activation function further enhance the model's classification capabilities and confidence. Feature compression and combination reduce model complexity and mitigate the risk of overfitting. Combined with these mechanisms, the model significantly improves the efficiency and accuracy of predicting falsely triggered anti-pinch events.
[0091] It is understandable that the activation function of the hidden layer chooses ReLU, which performs well in multi-layer neural networks and can alleviate the gradient disappearance problem, thereby improving the training efficiency and learning ability of the model. The calculation of the ReLU activation function is very simple, and only requires a threshold operation, which is especially important for large-scale data sets and complex models, and can significantly reduce training time. The ReLU activation function introduces nonlinearity, which can better capture the complex patterns and features in the input data, thereby improving the prediction accuracy of false triggering anti-pinch events. The activation function of the output layer uses Softmax, which is suitable for multi-classification problems. The Softmax activation function makes the output of each neuron represent the probability of belonging to the corresponding category, which is particularly important for the multi-classification problem of multiple driving states in this embodiment. The Softmax activation function can amplify the probability of the correct category while compressing the probabilities of other categories, thereby improving the confidence of the classification and being able to more accurately distinguish different categories, especially for the prediction of false triggering anti-pinch events.
[0092] It is understandable that the driving state analysis model needs to be trained with training samples before use until it reaches certain performance indicators before it can be applied in this embodiment. The training process includes:
[0093] Select a loss function and optimizer. Cross-Entropy Loss is a commonly used loss function for multi-classification problems. It measures the difference between predicted and true values. By minimizing cross-entropy loss, the model can more accurately predict the probability of each category, helping it better distinguish between normal tailgate operation, correct anti-trap triggering, and incorrect anti-trap triggering. The cross-entropy loss function provides a smooth and continuous gradient when calculating the gradient, which helps the optimization algorithm find the optimal solution in the parameter space. The smooth gradient makes the optimization process more stable and efficient, reduces oscillations and instability during training, and thus improves the training efficiency and convergence speed of the model. The optimizer is used to update network parameters to minimize the loss function. The optimizer uses the SGD (Stochastic Gradient Descent) optimization algorithm. It uses the gradient of each batch to update the model parameters. This is different from the traditional gradient descent algorithm that uses the entire dataset to calculate the gradient each time. Updating parameters batch by batch makes SGD more efficient when processing large-scale datasets, reducing memory requirements and computing time. For the prediction of erroneously triggered anti-pinch events, SGD can iterate and update model parameters faster, improving training efficiency.
[0094] Set hyperparameters during training. The learning rate is one of the most important hyperparameters in the optimization algorithm. If the learning rate is too high, training may not converge; if it is too low, training may progress very slowly. Setting the learning rate to 0.001 ensures model convergence while providing an appropriate update pace, improving training efficiency and stability. The batch size determines the amount of data processed before each parameter update. Smaller batches provide more frequent updates but unstable gradient estimates; larger batches provide more stable gradient estimates but less frequent updates. Setting the batch size to 64 strikes a balance between gradient estimation stability and update frequency, ensuring the model can stably update parameters while maintaining high training efficiency. The number of iterations determines the number of times the entire dataset is used to train the model. Too few iterations may lead to underfitting, while too many iterations may lead to overfitting. Setting the number of iterations to 200 ensures that the model has sufficient time to learn the data characteristics, avoiding underfitting, while also preventing overfitting by monitoring validation performance.
[0095] Train the neural network. Before training begins, split the data into a training set and a validation set. The training set is used to train the model, while the validation set is used to evaluate model performance and adjust hyperparameters. Next, set the number of epochs (epochs) the model should traverse through the training set. In this neural network, epochs is set to 100 to ensure that the model has sufficient training time to learn the data features and avoid underfitting, which can prevent the model from capturing complex patterns in the data and thus affect prediction accuracy. Finally, train the model using the training dataset. After each training session, evaluate the model's performance using the validation set. This helps monitor whether the model is learning and whether it is overfitting.
[0096] Model Validation. Evaluate the trained model on the test dataset. First, ensure that the test data has undergone the same preprocessing as the training data, load the best model saved during training, use the test dataset to make predictions for the model, and calculate the performance metrics of the model on the test data.
[0097] The method of the embodiment of the present application obtains multiple status data based on the drive motor and the tailgate, pre-processes these status data, and then inputs them into the drive status analysis model to obtain the state probability of each drive state corresponding to the current state data, and uses the drive state with the largest state probability as the real-time determination drive state for controlling the tailgate drive system. The drive states with state probabilities include normal drive state, correctly triggered anti-pinch state, and incorrectly triggered anti-pinch state. The real-time determination of the drive state can accurately and reliably reflect whether the current tailgate drive system is normal or needs adjustment, thereby controlling the tailgate drive system, while ensuring the safety and accuracy of the tailgate drive system and improving user experience.
[0098] All of the above optional technical solutions can be combined in any way to form optional embodiments of the present application, and will not be described in detail here. It should be understood that the order of the sequence numbers of the steps in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0099] The following are device embodiments of the present application, which can be used to implement the method embodiments of the present application. For details not disclosed in the device embodiments of the present application, please refer to the method embodiments of the present application.
[0100] Figure 4 Schematic diagram of a tailgate driving state control device provided by an embodiment of the present application. Figure 4 As shown, the control device includes:
[0101] A data acquisition module 401 is configured to acquire status data of a tailgate drive system. The tailgate drive system includes a drive motor and a tailgate controlled by the drive motor. The status data includes the tailgate's movement speed, its acceleration, the drive motor's motor current, a current change value of the motor current, and an anti-pinch monitoring result signal. The anti-pinch monitoring result signal is configured to indicate a real-time anti-pinch monitoring result determined based on at least one of the movement speed, acceleration, motor current, and current change value.
[0102] A data preprocessing module 402 is used to preprocess the status data;
[0103] The state analysis module 403 is used to input the normalized state data into the driving state analysis model, obtain the state probability corresponding to each driving state output by the driving state analysis model, and use the driving state corresponding to the maximum state probability as the real-time driving state; the driving state includes the normal driving state, the correctly triggered anti-pinch state, and the incorrectly triggered anti-pinch state;
[0104] The control module 404 is configured to control the tailgate driving system based on the real-time determination of the driving state.
[0105] The device of the embodiment of the present application obtains multiple status data based on the drive motor and the tailgate, pre-processes these status data, and then inputs them into the drive status analysis model to obtain the state probability of each drive state corresponding to the current state data, and uses the drive state with the largest state probability as the real-time determination drive state for controlling the tailgate drive system. The drive states with state probabilities include normal drive state, correctly triggered anti-pinch state, and incorrectly triggered anti-pinch state. The real-time determination of the drive state can accurately and reliably reflect whether the current tailgate drive system is normal or needs adjustment, thereby controlling the tailgate drive system, while ensuring the safety and accuracy of the tailgate drive system and improving user experience.
[0106] In an exemplary embodiment, the data preprocessing module includes:
[0107] A noise filtering unit, used for performing noise filtering on the state data;
[0108] An outlier removal unit is used to remove outliers from the state data after noise filtering;
[0109] The normalization unit is used to normalize the state data after removing outliers.
[0110] In an exemplary embodiment, the noise filtering unit is specifically configured to:
[0111] Perform moving average filtering on the motion speed;
[0112] Perform Kalman filtering on the acceleration;
[0113] Low-pass filtering of the motor current;
[0114] Perform median filtering on the current change value;
[0115] Perform exponential smoothing filtering on the anti-pinch monitoring result signal.
[0116] In an exemplary embodiment, the outlier removal unit is specifically configured to:
[0117] Based on the Z-score analysis method, outliers are removed from each state data after noise filtering.
[0118] In an exemplary embodiment, the neural network structure of the driving state analysis model includes an input layer, at least one hidden layer, and an output layer connected in sequence;
[0119] The input layer includes five input layer neurons, each of which is used to receive a corresponding state data;
[0120] The output layer includes three output layer neurons, and each output layer neuron is used to output the state probability of a corresponding driving state.
[0121] In an exemplary embodiment, each hidden layer includes a plurality of hidden layer neurons;
[0122] Each hidden layer neuron and each output layer neuron includes a linear transformation unit and a nonlinear transformation unit connected in sequence.
[0123] In an exemplary embodiment, the nonlinear transformation unit of the hidden layer neurons is configured to perform nonlinear transformation based on a ReLU activation function;
[0124] The nonlinear transformation unit of the output layer neurons is used to perform nonlinear transformation based on the softmax activation function.
[0125] In an exemplary embodiment, the control module is specifically configured to:
[0126] When the driving state is determined to be a normal driving state or the anti-pinch state is correctly triggered in real time, the configuration of the tailgate driving system is set to enable the anti-pinch function;
[0127] When it is determined in real time that the driving state is an erroneously triggered anti-pinch state, the configuration of the tailgate driving system is set to prohibit enabling the anti-pinch function at the current moment.
[0128] Figure 5 Schematic diagram of the electronic device 5 provided in the embodiment of the present application. Figure 5As shown, the electronic device 5 of this embodiment includes: a processor 501, a memory 502, and a computer program 503 stored in the memory 502 and executable by the processor 501. When the processor 501 executes the computer program 503, the steps of the above-mentioned method embodiments are implemented. Alternatively, when the processor 501 executes the computer program 503, the functions of the modules / units in the above-mentioned device embodiments are implemented.
[0129] The electronic device 5 may be a desktop computer, a notebook, a PDA, a cloud server, or other electronic device. The electronic device 5 may include but is not limited to a processor 501 and a memory 502. Those skilled in the art will appreciate that Figure 5 This is merely an example of the electronic device 5 and does not limit the electronic device 5 . The electronic device 5 may include more or fewer components than shown in the figure, or different components.
[0130] The processor 501 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
[0131] The memory 502 can be an internal storage unit of the electronic device 5, such as a hard disk or memory of the electronic device 5. The memory 502 can also be an external storage device of the electronic device 5, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) card, a flash memory card, etc. The memory 502 can also include both an internal storage unit of the electronic device 5 and an external storage device. The memory 502 is used to store computer programs and other programs and data required by the electronic device.
[0132] Those skilled in the art will clearly understand that for the sake of convenience and brevity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments 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 above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.
[0133] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the process in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. The computer program may include computer program code, which may be in source code form, object code form, executable file or some intermediate form. The computer-readable storage medium may include: any entity or device capable of carrying computer program code, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium, etc.
[0134] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present application, and should all be included in the scope of protection of the present application.
Claims
1. A method for controlling a tailgate driving state, characterized in that: include: Acquiring status data of a tailgate drive system; the tailgate drive system includes a drive motor and a tailgate controlled by the drive motor, the status data including a movement speed of the tailgate, an acceleration of the movement speed, a motor current of the drive motor, a current change value of the motor current, and an anti-pinch monitoring result signal, the anti-pinch monitoring result signal being used to indicate a real-time anti-pinch monitoring result determined based on at least one of the movement speed, the acceleration, the motor current, and the current change value; Preprocessing the status data; Inputting the pre-processed state data into a driving state analysis model to obtain state probabilities corresponding to each driving state output by the driving state analysis model, and using the driving state corresponding to the maximum state probability as the real-time driving state; the driving state includes a normal driving state, a correctly triggered anti-pinch state, and an incorrectly triggered anti-pinch state; controlling the tailgate driving system based on the real-time determination of the driving state; Among them, the neural network structure of the driving state analysis model includes an input layer, at least one hidden layer and an output layer connected in sequence; the input layer includes five input layer neurons, each of which is used to receive a corresponding type of state data; the output layer includes three output layer neurons, each of which is used to output the state probability of a corresponding driving state; each hidden layer includes multiple hidden layer neurons, and each hidden layer neuron and each output layer neuron includes a linear transformation unit and a nonlinear transformation unit connected in sequence.
2. The method according to claim 1, characterized in that The process of preprocessing the status data includes: performing noise filtering on the state data; removing outliers from the noise-filtered state data; The state data after removing outliers is normalized.
3. The method according to claim 2, characterized in that The process of performing noise filtering on the state data includes: Performing a moving average filter on the motion speed; performing a Kalman filter on the acceleration; performing low-pass filtering on the motor current; performing median filtering on the current change value; Perform exponential smoothing filtering on the anti-pinch monitoring result signal.
4. The method according to claim 2, characterized in that The process of removing outliers from the state data after noise filtering includes: Based on the Z-score analysis method, outliers are removed from each state data after noise filtering.
5. The method according to claim 1, wherein The nonlinear transformation unit of the hidden layer neurons is used to perform nonlinear transformation based on the ReLU activation function; The nonlinear transformation unit of the output layer neurons is used to perform nonlinear transformation based on a softmax activation function.
6. The method according to any one of claims 1 to 5, characterized in that The process of controlling the tailgate drive system based on the real-time determination of the drive state includes: When the real-time determination of the driving state is the normal driving state or the correctly triggered anti-pinch state, setting the configuration of the tailgate driving system to enable the anti-pinch function; When the real-time determination driving state is the error-triggered anti-pinch state, the configuration of the tailgate driving system is set to prohibit enabling the anti-pinch function at the current moment.
7. A tailgate driving state control device, characterized in that: include: a data acquisition module configured to acquire status data of a tailgate drive system; the tailgate drive system comprising a drive motor and a tailgate controlled by the drive motor; the status data comprising a movement speed of the tailgate, an acceleration of the movement speed, a motor current of the drive motor, a current change value of the motor current, and an anti-pinch monitoring result signal, the anti-pinch monitoring result signal being configured to indicate a real-time anti-pinch monitoring result determined based on at least one of the movement speed, the acceleration, the motor current, and the current change value; A data preprocessing module, configured to preprocess the status data; A state analysis module is configured to input the pre-processed state data into a driving state analysis model, obtain a state probability corresponding to each driving state output by the driving state analysis model, and use the driving state corresponding to the maximum state probability as a real-time driving state; the driving state includes a normal driving state, a correctly triggered anti-pinch state, and an incorrectly triggered anti-pinch state; a control module, configured to control the tailgate drive system based on the real-time determination of the drive state; Among them, the neural network structure of the driving state analysis model includes an input layer, at least one hidden layer and an output layer connected in sequence; the input layer includes five input layer neurons, each of which is used to receive a corresponding type of state data; the output layer includes three output layer neurons, each of which is used to output the state probability of a corresponding driving state; each hidden layer includes multiple hidden layer neurons, and each hidden layer neuron and each output layer neuron includes a linear transformation unit and a nonlinear transformation unit connected in sequence.
8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
Anti-pinch state judging method and system and anti-pinch method and system for electric tailgates
CN103112337A
Electric tail gate anti-pinch control system
CN113338743A