Vehicle mileage calculation method and device, computer equipment and storage medium
By constructing a driving behavior cognitive model and combining GNSS and IMU data, personalized IMU error compensation values are dynamically output, solving the accuracy problem of vehicle mileage calculation in GNSS signal obstruction scenarios and achieving high-precision and continuous mileage calculation in complex environments.
Patent Information
- Application Number
- CN202610121043.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-28
- Publication Date
- 2026-06-09
AI Technical Summary
Traditional vehicle mileage calculations that rely on GNSS modules suffer from drifting, jumping, or signal loss of positioning points in signal-blocked scenarios such as urban canyons and tunnels, resulting in mileage calculations that deviate significantly from the actual physical mileage.
A driving behavior cognitive model is constructed. By monitoring GNSS signals and IMU data, the pre-trained driving behavior cognitive model dynamically outputs personalized IMU error compensation values when the GNSS signals do not meet the standards. The model is then combined with the current driving behavior data to perform error compensation and calculate the vehicle's driving trajectory and mileage.
When GNSS signals are lost or interfered with, personalized IMU error compensation can improve the accuracy of dead reckoning and mileage measurement, ensuring the continuity and accuracy of the driving trajectory.
Smart Images

Figure CN122170917A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of intelligent transportation technology, and in particular to a method, apparatus, computer equipment, and storage medium for calculating vehicle mileage. Background Technology
[0002] With the development of intelligent transportation technology, technologies for tracking vehicle trajectories have emerged. Especially in intelligent mobility and ride-hailing operation models, it is necessary to accurately calculate the vehicle's mileage based on the vehicle's trajectories.
[0003] However, traditional technologies rely entirely on the GNSS (Global Navigation Satellite System) module of smart terminals for positioning and mileage calculation. This technology is limited by physical laws; in scenarios with signal obstruction, such as urban canyons and tunnels, the positioning point may drift, jump, or even lose signal, causing the calculated driving mileage to deviate significantly from the actual physical mileage. Summary of the Invention
[0004] Therefore, it is necessary to provide a vehicle mileage calculation method, device, computer equipment, and storage medium that can improve the accuracy of actual mileage calculation in response to the above-mentioned technical problems.
[0005] Firstly, a method for calculating vehicle mileage is provided, the method comprising: Monitor the vehicle's GNSS signal and determine whether the GNSS signal meets the preset standard; In response to the GNSS signal not conforming to the preset standard, a pre-trained driving behavior cognitive model is invoked; the driving behavior cognitive model is a model used to characterize the relationship between the driver's driving behavior data, the vehicle's IMU data, and the compensation strategy of the IMU data. Acquire the vehicle's current IMU data and the driver's current driving behavior data, input the current IMU data and current driving behavior data into the driving behavior cognitive model, and output the error compensation value for the current IMU data; The vehicle's trajectory is calculated based on the current IMU data and error compensation value, and the total mileage of the vehicle is calculated based on the trajectory.
[0006] In some embodiments, the method further includes: In response to the GNSS signal conforming to the preset standard, the vehicle's driving trajectory is calculated based on the vehicle trajectory observation value transmitted by the GNSS signal and the current IMU data, and the total driving mileage of the vehicle is calculated based on the driving trajectory.
[0007] In some embodiments, the method further includes: In response to GNSS signals conforming to preset standards, driving behavior data is collected during vehicle operation and fed back to the driving behavior cognitive model so that the driving behavior cognitive model can be iteratively trained.
[0008] In some embodiments, the current IMU data includes the current acceleration and the current angular velocity. Calculating the vehicle's trajectory based on the current IMU data and error compensation values includes: Calculate the compensated acceleration and compensated angular velocity based on the current acceleration, current angular velocity, and error compensation value, respectively. The vehicle's velocity is updated by integrating the component of the post-compensation acceleration in the direction of vehicle motion, and the vehicle's heading angle is updated by integrating the post-compensation angular velocity. The vehicle's continuous position estimate is calculated based on the vehicle's updated speed and the integral of the heading angle over time. The vehicle's trajectory is obtained based on continuous position estimation.
[0009] In some embodiments, determining whether a GNSS signal conforms to a preset standard includes: Detect the current transmission quality of GNSS signals; Predict the transmission trend of GNSS signals within a preset time period based on the current transmission quality; In response to a discrepancy between the transmission trend and the expected trend, the GNSS signal is determined to be non-compliant with the preset standard.
[0010] In some embodiments, the training method for the driving behavior cognitive model includes: Collect historical IMU data generated by the vehicle while driving on the preset road, as well as the vehicle's actual historical GNSS trajectory data on the preset road, the driver's personnel identification information, and the driver's historical driving behavior data during the driving on the preset road; Annotate historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data; The driving behavior cognitive model is trained based on labeled historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data.
[0011] In some embodiments, the driving behavior cognitive model is trained based on labeled historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data, including: Data alignment processing is performed on the timestamps of historical IMU data and historical GNSS trajectory data; The historical GNSS trajectory data of vehicles are processed into trajectory partitions according to driving scenarios and road types, and IMU feature information is extracted from historical IMU data in each partition. The predicted trajectory is calculated based on IMU feature information and dead reckoning algorithm; The predicted trajectory is trained by bias compensation based on personnel identification information, historical driving behavior data, and historical GNSS trajectory data, thereby training the driving behavior cognitive model.
[0012] In a second aspect, a vehicle mileage calculation device is provided, the device comprising: The signal monitoring module is used to monitor the vehicle's GNSS signal and determine whether the GNSS signal meets the preset standard; The model invocation module is used to invoke a pre-trained driving behavior cognition model in response to GNSS signals not meeting preset standards. The driving behavior cognition model is a model used to represent the relationship between driver's driving behavior data, vehicle IMU data, and IMU data compensation strategies. The error compensation module is used to acquire the vehicle's current IMU data and the driver's current driving behavior data, input the current IMU data and current driving behavior data into the driving behavior cognitive model, and output the error compensation value for the current IMU data. The mileage calculation module is used to calculate the vehicle's driving trajectory based on the current IMU data and error compensation value, and to calculate the vehicle's total mileage based on the driving trajectory.
[0013] Thirdly, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the method of any one of the first aspects.
[0014] Fourthly, a computer-readable storage medium is provided having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the method of any one of the first aspects.
[0015] The aforementioned vehicle mileage calculation method, device, computer equipment, and storage medium construct a driving behavior cognitive model. This model is based on the inherent correlation between the driver's operational characteristics and the error compensation of the vehicle's IMU data. When GNSS signal lock-up is lost or interfered with, it can dynamically output personalized IMU error compensation values based on current driving behavior data and current IMU data, achieving adaptive correction of accumulated errors in the inertial navigation system. Using this solution, the accuracy and reliability of vehicle dead reckoning in complex environments such as urban canyons and tunnels can be effectively improved, ensuring the continuity of the driving trajectory and the accuracy of mileage measurement. Attached Figure Description
[0016] Figure 1 This is a flowchart illustrating the vehicle mileage calculation method in some embodiments; Figure 2 This is a flowchart illustrating the training method of the driving behavior cognitive model in some embodiments; Figure 3 This is a flowchart illustrating the vehicle mileage calculation method in some application examples; Figure 4 This is a structural block diagram of the vehicle mileage calculation device in some embodiments; Figure 5 This is a diagram showing the internal structure of a computer device in some embodiments. Detailed Implementation
[0017] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0018] The vehicle mileage calculation method provided in this application can be applied to computer equipment. This computer equipment may include, but is not limited to, various personal computers, laptops, smartphones, tablets, and in-vehicle terminal devices.
[0019] In some embodiments, such as Figure 1 As shown, a method for calculating vehicle mileage is provided. Taking the application of this method to computer equipment, such as an in-vehicle terminal, as an example, the method includes the following steps: Step S102: Monitor the vehicle's GNSS signal and determine whether the GNSS signal meets the preset standard.
[0020] In this step, GNSS signal refers to vehicle-related data such as position and speed acquired through a satellite system. For example, determining whether a vehicle's GNSS signal meets preset standards includes, but is not limited to: checking whether the number of visible satellites consistently exceeds a preset number, whether the Positioning Accuracy Factor (PDOP) is less than a preset value, whether the carrier-to-noise ratio is consistently higher than a preset threshold dB-Hz, and whether the speed calculation output is continuous and without abrupt changes. If the above conditions are met, the signal can be determined to meet high-precision positioning requirements.
[0021] Step S104: In response to the GNSS signal not conforming to the preset standard, a pre-trained driving behavior cognitive model is invoked; wherein, the driving behavior cognitive model is a model used to characterize the relationship between the driver's driving behavior data, the vehicle's IMU data, and the compensation strategy of the IMU data.
[0022] In this step, when the signal quality of the GNSS signal does not meet the preset standard, the first mileage calculation mode can be entered. The first mileage calculation mode is a mode that calculates mileage based on a pre-trained driving behavior cognitive model combined with the current IMU (Inertial Measurement Unit Data) data of the vehicle collected under the current situation.
[0023] The driving behavior cognitive model is used to characterize the relationship between driver behavior data, vehicle IMU data, and IMU data compensation strategies. This model can be trained in advance using machine learning models based on historical vehicle driving data and driver behavior data. Because different drivers have different driving habits, even on the same road segment and with the same vehicle type, different drivers' operations result in systematic differences in the IMU data generated. Traditional fixed-parameter odometer methods cannot effectively distinguish and compensate for such individualized motion deviations. Therefore, by introducing the driving behavior cognitive model, the compensation strategy for IMU data can be dynamically adjusted according to the personalized operating characteristics of different drivers, achieving a more accurate estimation of vehicle motion status, improving dead reckoning accuracy during GNSS signal failures, and thus enhancing the continuity, stability, and reliability of odometer calculation.
[0024] Step S106: Obtain the vehicle's current IMU data and the driver's current driving behavior data, input the current IMU data and current driving behavior data into the driving behavior cognitive model, and output the error compensation value for the current IMU data.
[0025] In this step, when the vehicle's GNSS signal is detected to be inconsistent with the preset standard, the vehicle's IMU data collected at this time is taken as the current IMU data, and the driver's behavior data collected at this time is taken as the current driving behavior data. Both are input into the pre-trained driving behavior cognition model. The driving behavior cognition model, based on the feature extraction and analysis logic learned in historical training, combined with the driver's current driving behavior data, outputs a compensation strategy for the IMU data that matches the driver's driving style. For example, it can directly output the error compensation value corresponding to the current IMU data.
[0026] For example, driving behavior data may include at least one of steering habit information, acceleration and deceleration style information, lane change behavior data, idling or coasting tendency information, and response delay information.
[0027] Among them, steering habit information refers to the average angular velocity of the steering wheel operation and the characteristics of steering smoothness during turning; acceleration and deceleration style information refers to the behavioral patterns reflecting the degree and force of the driver's pedal operation during acceleration and braking; lane change behavior data refers to the characteristics describing the steering amplitude, duration and lateral acceleration changes when the driver performs a lane change operation; idling or coasting tendency information refers to the frequency and coasting distance preference of the driver in releasing the pedal in advance when anticipating stopping or following another vehicle; response delay information refers to the difference in average reaction time between the driver's perception of changes in traffic conditions and the execution of the operation.
[0028] For example, the driving behavior cognition model can be centrally trained and version-managed on a cloud server. The APP (Application) loaded on the driver's terminal device can periodically download and update the model to match its own identification information. This example is applicable to terminal devices with limited storage and computing power. In other embodiments, model training can also be performed directly on the driver's terminal device. In this case, driving behavior data of the driver and corresponding vehicle IMU data can be continuously collected during vehicle operation to optimize and iterate the model. In this embodiment, the accuracy of the driving behavior cognition model's output can be improved by continuously feeding training data into the model.
[0029] Step S108: Calculate the vehicle's driving trajectory based on the current IMU data and error compensation value, and calculate the vehicle's total mileage based on the driving trajectory.
[0030] In this step, the IMU data after error compensation can be calculated based on the current IMU data and the error compensation value. The vehicle's motion state is solved by integration. The vehicle driving data is updated using the compensated IMU data. Then, the driving trajectory is formed by recursively calculating the continuous position points. Finally, the total driving distance is obtained by accumulating the length of the trajectory segments. This can effectively suppress the accumulated error of inertial navigation and improve the accuracy of the calculation.
[0031] The aforementioned vehicle mileage calculation method constructs a driving behavior cognitive model, modeling the inherent correlation between the driver's operational characteristics and the error compensation of the vehicle's IMU data. When GNSS signal lock-up is lost or interfered with, it can dynamically output personalized IMU error compensation values based on current driving behavior data and current IMU data, achieving adaptive correction of accumulated errors in the inertial navigation system. This solution effectively improves the accuracy and reliability of vehicle dead reckoning in complex environments such as urban canyons and tunnels, ensuring the continuity of the driving trajectory and the accuracy of mileage measurement.
[0032] In some embodiments, the method further includes: in response to the GNSS signal conforming to a preset standard, calculating the vehicle's driving trajectory based on the vehicle trajectory observations transmitted by the GNSS signal and the current IMU data, and calculating the total driving mileage of the vehicle based on the driving trajectory.
[0033] In this embodiment, when the GNSS signal meets the preset standard, it can enter the second mileage calculation mode, which is a fusion calculation mode of GNSS signal and IMU data.
[0034] In this embodiment, under the second mileage calculation mode, a tightly coupled algorithm can be used for GNSS signals and IMU data. Compared with the vehicle trajectory observations transmitted directly by GNSS signals, the deep fusion algorithm that uses the vehicle trajectory observations transmitted by GNSS signals and the vehicle's current IMU data to mutually corroborate each other can produce the optimal position and velocity estimates even when the number of satellites is small, ensuring the accuracy of mileage calculation.
[0035] In some embodiments, the method further includes: in response to the GNSS signal conforming to a preset standard, collecting driving behavior data during vehicle operation, and feeding the driving behavior data back to the driving behavior cognitive model so that the driving behavior cognitive model can be iteratively trained.
[0036] In this embodiment, when the GNSS signal meets the preset standard and after entering the second mileage calculation mode, while continuously calculating the mileage, the real-time collected driving behavior data can also be fed back to the driving behavior cognitive model. The driving behavior cognitive model can be optimized and iteratively trained in advance. When entering urban canyons, tunnels and other signal obstruction scenarios, the latest optimized and iterated driving behavior cognitive model can be called, thereby further improving the accuracy of mileage calculation.
[0037] In some embodiments, the current IMU data includes the current acceleration and the current angular velocity. Calculating the vehicle's trajectory based on the current IMU data and the error compensation value includes: calculating the compensated acceleration and the compensated angular velocity based on the current acceleration, the current angular velocity, and the error compensation value; updating the vehicle's velocity by integrating the component of the compensated acceleration in the vehicle's direction of motion, and updating the vehicle's heading angle by integrating the compensated angular velocity; calculating the vehicle's continuous position estimate based on the updated velocity and the integral of the heading angle over time; and obtaining the vehicle's trajectory based on the continuous position estimate.
[0038] In this embodiment, by dynamically compensating for the systematic bias of the IMU and integrating to solve the motion state, the accumulation of inertial navigation error can be effectively suppressed, and the accuracy and continuity of vehicle trajectory estimation can be improved in environments where GNSS signals are missing or limited.
[0039] In some embodiments, determining whether a GNSS signal conforms to a preset standard includes: detecting the current transmission quality of the GNSS signal; predicting the transmission trend of the GNSS signal within a preset time period based on the current transmission quality; and determining that the GNSS signal does not conform to the preset standard in response to a transmission trend that does not match the expected trend.
[0040] In this embodiment, by introducing a trend prediction mechanism based on the current transmission quality, the risk of GNSS signal degradation or interruption can be identified in advance, and a smooth and proactive switch from the second mileage calculation mode to the first mileage calculation mode can be achieved. This avoids trajectory jumps or mileage accumulation errors caused by signal mutations and improves the continuous positioning performance of the system in complex environments.
[0041] In some embodiments, reference Figure 2 As shown, Figure 2 In this context, the training method for a driving behavior cognitive model may include the following steps: Step S201: Collect historical IMU data generated by the vehicle during its journey on the preset road, as well as the vehicle's actual historical GNSS trajectory data on the preset road, the driver's identification information, and the driver's historical driving behavior data during its journey on the preset road. Step S202: Annotate historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data.
[0042] Step S203: Train the driving behavior cognition model based on the labeled historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data.
[0043] In some embodiments, continue to refer to Figure 2 As shown, step S203: Training the driving behavior cognition model based on labeled historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data, including: Step S2031: Align historical IMU data and historical GNSS trajectory data with timestamps.
[0044] Step S2032: Perform trajectory partitioning processing on the historical GNSS trajectory data of the vehicle according to the driving scenario and road type, and extract IMU feature information from the historical IMU data in a partitioned manner.
[0045] Step S2033: Calculate the predicted trajectory based on IMU feature information and dead reckoning algorithm; Step S2034: Based on personnel identification information, historical driving behavior data, and historical GNSS trajectory data, perform deviation compensation training on the predicted trajectory to train the driving behavior cognitive model.
[0046] More specifically, in a practical application scenario, for example, the specific training process of the driving behavior cognitive model can be referred to as follows: 1. Training sample data collection The data required for training the driving behavior cognitive model includes: Raw IMU time-series data (historical IMU data) can be acquired through readings from a three-axis accelerometer and a three-axis gyroscope, with a sampling frequency ≥50Hz.
[0047] High-quality GNSS trajectory ground truth (historical GNSS trajectory data): High-precision GNSS trajectory data collected in areas with good signal (such as open roads) serves as a benchmark for comparison of results extrapolated from IMU data.
[0048] Driver behavior data: including labels for driving behaviors such as rapid acceleration, rapid deceleration, smooth turning, lane changing, and U-turns, which can be automatically labeled based on IMU data and vehicle kinematics models.
[0049] Vehicle CAN bus signals (optional): such as vehicle speed, steering angle, brake pedal opening, etc., used to assist in modeling and verification.
[0050] Driver identification information: Personalized cognitive models of driving behavior used to distinguish different drivers.
[0051] 2. Processing of training sample data Data alignment processing: IMU data and GNSS trajectory are strictly synchronized in terms of timestamps.
[0052] Trajectory segmentation processing: Samples are extracted in segments according to driving scenario (such as straight, turning, U-turn) and road type (such as highway, urban area).
[0053] Feature extraction processing: Extract the following statistical and frequency domain features from the IMU data: mean, variance, peak value, zero-crossing rate; integral of angular velocity during turning; projected component of acceleration in the velocity direction; intensity and duration of braking / acceleration events, etc.
[0054] Error vector construction and processing: Calculate the position and velocity deviations between the IMU-based DR (Dead Reckoning) trajectory and the ground truth trajectory recorded by GNSS within the same time period, and use them as labels for model training.
[0055] 3. Basic Model and Training Settings Base model selection: Temporal neural networks, such as LSTM (Long Short-Term Memory), GRU (Gated Recurrent Unit), or attention mechanism models (such as Transformer), can be used to adapt to the temporal dependence of driving behavior.
[0056] Input: IMU feature sequence of length T (such as acceleration, angular velocity, and other extracted features), and driver behavior data.
[0057] Main output: System error compensation vector (Δ acc, Δ gyro) corresponding to IMU readings; Auxiliary output: Driver behavior classification (e.g., aggressive, moderate, etc.).
[0058] Model training parameters: Loss function: The mean squared error (MSE) of the location error is combined with the cross-entropy loss function for behavior classification; Optimizer: Adam is used, with an initial learning rate of 0.001 and dynamic decay. Training batch size: 32, time series length T=50 (approximately 1 second of data); Training rounds: 50-100 rounds, using an early stopping strategy to prevent overfitting.
[0059] 4. Personalized error compensation and correction mechanism In DR extrapolation, the model dynamically compensates for raw IMU readings to correct for systematic operational deviations by the driver. Forward inference: Input the current IMU sequence, and the model outputs the corresponding error compensation value.
[0060] IMU Data Cleansing: acc_corrected = acc_raw + Δacc gyro_corrected=gyro_raw+Δgyro Compensated DR estimation: Using purified IMU data for dead reckoning significantly reduces the cumulative error caused by driver habits (such as understeering and slow braking).
[0061] Below, we will refer to an application example. Figure 3 As shown, Figure 3The diagram illustrates the process flow of vehicle mileage calculation methods in several application examples. In the ride-hailing model, specifically in the application scenario of mileage-based planning management and billing mechanisms, the vehicle's terminal system can first simultaneously collect GNSS signals, IMU data, and driving behavior data as continuous input. The terminal system can have a dual-mode operation mechanism: when the GNSS signal is continuously reliable, mode two (second mileage calculation mode) is used, which directly calculates the mileage based on a tightly coupled fusion algorithm of GNSS and IMU; when the GNSS signal quality does not meet the requirements, it switches to mode one (first mileage calculation mode). In mode one, a personalized driving behavior cognitive model trained and continuously updated with historical data can be invoked to dynamically compensate the IMU data, and then dead reckoning is performed based on the compensated IMU data to obtain the mileage. The terminal system uses a GNSS signal quality perception engine to judge the signal status in real time, dynamically switching between the two working modes. The final mileage calculation result is output and transmitted to the required business system for subsequent billing and other processing. The entire process demonstrates how, in complex environments, the continuity and accuracy of mileage calculation are ensured by fusing multi-source perception and personalized models.
[0062] It should be understood that, although Figures 1 to 3 The steps in the flowchart are shown sequentially as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order in which these steps are executed, and they can be performed in other orders. Figures 1 to 3 At least some of the steps in the process may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least some of the sub-steps or stages of other steps.
[0063] In some embodiments, such as Figure 4 As shown, a vehicle mileage calculation device is provided, including: a signal monitoring module 410, a model calling module 420, an error compensation module 430, and a mileage calculation module 440, wherein: The signal monitoring module 410 is used to monitor the GNSS signal of the vehicle and determine whether the GNSS signal meets the preset standard. The model invocation module 420 is used to invoke a pre-trained driving behavior cognitive model in response to the GNSS signal not conforming to the preset standard; wherein, the driving behavior cognitive model is a model used to characterize the relationship between the driver's driving behavior data, the vehicle's IMU data, and the compensation strategy of the IMU data. The error compensation module 430 is used to acquire the current IMU data of the vehicle and the current driving behavior data of the driver, input the current IMU data and the current driving behavior data into the driving behavior cognitive model, and output the error compensation value for the current IMU data. The mileage calculation module 440 is used to calculate the vehicle's driving trajectory based on the current IMU data and error compensation value, and to calculate the vehicle's total mileage based on the driving trajectory.
[0064] In some embodiments, the mileage calculation module 440 is further configured to, in response to the GNSS signal conforming to a preset standard, calculate the vehicle's driving trajectory based on the vehicle trajectory observation value transmitted by the GNSS signal and the current IMU data, and calculate the total driving mileage of the vehicle based on the driving trajectory.
[0065] In some embodiments, the error compensation module 430 is further configured to, in response to the GNSS signal conforming to a preset standard, collect driving behavior data during the vehicle's operation and feed the driving behavior data back to the driving behavior cognitive model so that the driving behavior cognitive model can be iteratively trained.
[0066] In some embodiments, the mileage calculation module 440 is used to calculate the compensated acceleration and the compensated angular velocity based on the current acceleration, the current angular velocity, and the error compensation value, respectively; to update the vehicle speed by integrating the component of the compensated acceleration in the vehicle's motion direction, and to update the vehicle's heading angle by integrating the compensated angular velocity; to calculate the vehicle's continuous position estimate based on the vehicle's updated speed and the integral of the heading angle over time; and to obtain the vehicle's driving trajectory based on the continuous position estimate.
[0067] In some embodiments, the signal monitoring module 410 is used to detect the current transmission quality of the GNSS signal; predict the transmission trend of the GNSS signal within a preset time period based on the current transmission quality; and determine that the GNSS signal does not meet the preset standard in response to the transmission trend not matching the expected trend.
[0068] In some embodiments, the error compensation module 430 is further configured to collect historical IMU data generated by the vehicle during its journey on a preset road, as well as the vehicle's actual historical GNSS trajectory data on the preset road, the driver's identification information, and the driver's historical driving behavior data during its journey on the preset road; to annotate the historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data; and to train the driving behavior cognitive model based on the annotated historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data.
[0069] In some embodiments, the error compensation module 430 is further configured to perform data alignment processing on the timestamps of historical IMU data and historical GNSS trajectory data; perform trajectory partitioning processing on the historical GNSS trajectory data of the vehicle according to driving scenario and road type, and extract IMU feature information from the historical IMU data in a partitioned manner; calculate the predicted trajectory based on the IMU feature information and dead reckoning algorithm; and perform deviation compensation training on the predicted trajectory based on personnel identification information, historical driving behavior data, and historical GNSS trajectory data, thereby training the driving behavior cognitive model.
[0070] Specific limitations regarding the vehicle mileage calculation device can be found in the limitations on the vehicle mileage calculation method described above, and will not be repeated here. Each module in the aforementioned vehicle mileage calculation device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the corresponding operations of each module.
[0071] In some embodiments, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 5 As shown, the computer device includes a processor, memory, network interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface is used to communicate with external terminals via a network connection. When the computer program is executed by the processor, it implements a method for calculating vehicle mileage. The display screen can be an LCD screen or an e-ink screen. The input devices can be a touch layer covering the display screen, buttons, a trackball, or a touchpad on the computer device's casing, or an external keyboard, touchpad, or mouse.
[0072] Those skilled in the art will understand that Figure 5 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0073] In some embodiments, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it performs the following steps: monitoring the GNSS signal of a vehicle and determining whether the GNSS signal conforms to a preset standard; in response to the GNSS signal not conforming to the preset standard, invoking a pre-trained driving behavior cognitive model; wherein, the driving behavior cognitive model is a model used to characterize the correlation between the driver's driving behavior data, the vehicle's IMU data, and the compensation strategy for the IMU data; acquiring the vehicle's current IMU data and the driver's current driving behavior data, inputting the current IMU data and the current driving behavior data into the driving behavior cognitive model, and outputting an error compensation value for the current IMU data; calculating the vehicle's driving trajectory based on the current IMU data and the error compensation value, and calculating the vehicle's total mileage based on the driving trajectory.
[0074] In some embodiments, when the processor executes the computer program, it further performs the following steps: in response to the GNSS signal conforming to a preset standard, calculating the vehicle's driving trajectory based on the vehicle trajectory observations transmitted by the GNSS signal and the current IMU data, and calculating the total driving mileage of the vehicle based on the driving trajectory.
[0075] In some embodiments, when the processor executes the computer program, it further performs the following steps: in response to the GNSS signal conforming to a preset standard, it collects driving behavior data during the vehicle's operation and feeds the driving behavior data back to the driving behavior cognitive model so that the driving behavior cognitive model can be iteratively trained.
[0076] In some embodiments, when the processor executes the computer program, it further implements the following steps: calculating the compensated acceleration and the compensated angular velocity based on the current acceleration, the current angular velocity, and the error compensation value; updating the vehicle's speed by integrating the component of the compensated acceleration in the vehicle's motion direction, and updating the vehicle's heading angle by integrating the compensated angular velocity; calculating the vehicle's continuous position estimate based on the vehicle's updated speed and the integral of the heading angle over time; and obtaining the vehicle's trajectory based on the continuous position estimate.
[0077] In some embodiments, when the processor executes the computer program, it further performs the following steps: detecting the current transmission quality of the GNSS signal; predicting the transmission trend of the GNSS signal within a future preset time period based on the current transmission quality; and determining that the GNSS signal does not meet the preset standard in response to a transmission trend that does not match the expected trend.
[0078] In some embodiments, when the processor executes the computer program, it further performs the following steps: collecting historical IMU data generated by the vehicle while driving on a preset road, as well as the vehicle's actual historical GNSS trajectory data on the preset road, the driver's identification information, and the driver's historical driving behavior data while driving on the preset road; labeling the historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data; and training the driving behavior cognitive model based on the labeled historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data.
[0079] In some embodiments, when the processor executes the computer program, it further performs the following steps: aligning historical IMU data and historical GNSS trajectory data on timestamps; partitioning the vehicle's historical GNSS trajectory data according to driving scenarios and road types, and extracting IMU feature information from the historical IMU data in partitions; calculating the predicted trajectory based on the IMU feature information and dead reckoning algorithm; and training the predicted trajectory with deviation compensation based on personnel identification information, historical driving behavior data, and historical GNSS trajectory data, thereby training the driving behavior cognitive model.
[0080] In some embodiments, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, it performs the following steps: monitoring the GNSS signal of the vehicle and determining whether the GNSS signal conforms to a preset standard; in response to the GNSS signal not conforming to the preset standard, invoking a pre-trained driving behavior cognitive model; wherein, the driving behavior cognitive model is a model used to characterize the correlation between the driver's driving behavior data, the vehicle's IMU data, and the compensation strategy for the IMU data; acquiring the vehicle's current IMU data and the driver's current driving behavior data, inputting the current IMU data and the current driving behavior data into the driving behavior cognitive model, and outputting an error compensation value for the current IMU data; calculating the vehicle's driving trajectory based on the current IMU data and the error compensation value, and calculating the vehicle's total mileage based on the driving trajectory.
[0081] In some embodiments, when the computer program is executed by the processor, it further performs the following steps: in response to the GNSS signal conforming to a preset standard, calculating the vehicle's driving trajectory based on the vehicle trajectory observations transmitted by the GNSS signal and the current IMU data, and calculating the total driving mileage of the vehicle based on the driving trajectory.
[0082] In some embodiments, when the computer program is executed by the processor, it further performs the following steps: in response to the GNSS signal conforming to a preset standard, it collects driving behavior data during the vehicle's operation and feeds the driving behavior data back to the driving behavior cognitive model so that the driving behavior cognitive model can be iteratively trained.
[0083] In some embodiments, when the computer program is executed by the processor, it further implements the following steps: calculating the compensated acceleration and the compensated angular velocity based on the current acceleration, the current angular velocity, and the error compensation value, respectively; updating the vehicle's speed by integrating the component of the compensated acceleration in the vehicle's motion direction, and updating the vehicle's heading angle by integrating the compensated angular velocity; calculating the vehicle's continuous position estimate based on the vehicle's updated speed and the integral of the heading angle over time; and obtaining the vehicle's trajectory based on the continuous position estimate.
[0084] In some embodiments, when the computer program is executed by the processor, it further performs the following steps: detecting the current transmission quality of the GNSS signal; predicting the transmission trend of the GNSS signal within a future preset time period based on the current transmission quality; and determining that the GNSS signal does not meet the preset standard in response to a transmission trend that does not match the expected trend.
[0085] In some embodiments, when the computer program is executed by the processor, it further performs the following steps: collecting historical IMU data generated by the vehicle while driving on a preset road, as well as the vehicle's actual historical GNSS trajectory data on the preset road, the driver's identification information, and the driver's historical driving behavior data while driving on the preset road; labeling the historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data; and training the driving behavior cognitive model based on the labeled historical IMU data, historical GNSS trajectory data, personnel identification information, and historical driving behavior data.
[0086] In some embodiments, when the computer program is executed by the processor, it further performs the following steps: aligning historical IMU data and historical GNSS trajectory data on timestamps; partitioning the historical GNSS trajectory data of the vehicle according to driving scenarios and road types, and extracting IMU feature information from the historical IMU data in partitions; calculating the predicted trajectory based on the IMU feature information and dead reckoning algorithm; and training the predicted trajectory with deviation compensation based on personnel identification information, historical driving behavior data, and historical GNSS trajectory data, thereby training the driving behavior cognitive model.
[0087] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0088] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0089] Furthermore, the term "and / or" in this article is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. Additionally, the characters in this article generally indicate that the preceding and following related objects have an "or" relationship.
[0090] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the invention patent. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.
[0091] It should be noted that in the embodiments of this application, data related to user information or user data (e.g., driver's driving behavior data, vehicle IMU data, etc.) need to be obtained and processed only after user authorization and consent. When the embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.
Claims
1. A method for calculating vehicle mileage, characterized in that, The method includes: Monitor the vehicle's GNSS signal and determine whether the GNSS signal meets a preset standard; In response to the GNSS signal not conforming to the preset standard, a pre-trained driving behavior cognitive model is invoked; wherein, the driving behavior cognitive model is a model used to characterize the correlation between the driver's driving behavior data, the vehicle's IMU data, and the compensation strategy of the IMU data; Acquire the current IMU data of the vehicle and the current driving behavior data of the driver, input the current IMU data and the current driving behavior data into the driving behavior cognitive model, and output the error compensation value for the current IMU data; The vehicle's driving trajectory is calculated based on the current IMU data and the error compensation value, and the total mileage of the vehicle is calculated based on the driving trajectory.
2. The method according to claim 1, characterized in that, The method further includes: In response to the GNSS signal conforming to a preset standard, the vehicle's driving trajectory is calculated based on the vehicle trajectory observation value transmitted by the GNSS signal and the current IMU data, and the total driving mileage of the vehicle is calculated based on the driving trajectory.
3. The method according to claim 2, characterized in that, The method further includes: In response to the GNSS signal conforming to a preset standard, driving behavior data is collected during the vehicle's operation, and the driving behavior data is fed back to the driving behavior cognitive model so that the driving behavior cognitive model can be iteratively trained.
4. The method according to claim 1, characterized in that, The current IMU data includes the current acceleration and the current angular velocity. Calculating the vehicle's trajectory based on the current IMU data and the error compensation value includes: Calculate the compensated acceleration and the compensated angular velocity based on the current acceleration, the current angular velocity, and the error compensation value, respectively. The vehicle's velocity is updated by integrating the component of the compensated acceleration in the direction of the vehicle's motion, and the vehicle's heading angle is updated by integrating the compensated angular velocity. The vehicle's continuous position estimate is calculated by integrating over time based on the vehicle's updated speed and heading angle; The vehicle's trajectory is estimated based on the continuous positions.
5. The method according to claim 1, characterized in that, The step of determining whether the GNSS signal meets the preset standard includes: Detect the current transmission quality of the GNSS signal; Based on the current transmission quality, predict the transmission trend of the GNSS signal within a preset time period in the future; In response to the transmission trend not matching the expected trend, it is determined that the GNSS signal does not meet the preset standard.
6. The method according to claim 1, characterized in that, The training method for the driving behavior cognitive model includes: Collect historical IMU data generated by the vehicle while driving on the preset road, as well as the vehicle's actual historical GNSS trajectory data on the preset road, the driver's personnel identification information, and the driver's historical driving behavior data while driving on the preset road; The historical IMU data, the historical GNSS trajectory data, the personnel identification information, and the historical driving behavior data are labeled; The driving behavior cognitive model is trained based on the labeled historical IMU data, the historical GNSS trajectory data, the personnel identification information, and the historical driving behavior data.
7. The method according to claim 6, characterized in that, The step of training the driving behavior cognitive model based on the labeled historical IMU data, the historical GNSS trajectory data, the personnel identification information, and the historical driving behavior data includes: The historical IMU data and the historical GNSS trajectory data are aligned on the timestamp. The historical GNSS trajectory data of the vehicle is partitioned according to driving scenario and road type, and IMU feature information is extracted from the historical IMU data in a partitioned manner. The predicted trajectory is calculated based on the IMU feature information and the dead reckoning algorithm. The predicted trajectory is trained by bias compensation based on the personnel identification information, the historical driving behavior data, and the historical GNSS trajectory data, thereby training the driving behavior cognitive model.
8. A vehicle mileage calculation device, characterized in that, The device includes: The signal monitoring module is used to monitor the GNSS signal of the vehicle and determine whether the GNSS signal meets the preset standard; The model invocation module is used to invoke a pre-trained driving behavior cognitive model in response to the GNSS signal not conforming to the preset standard; wherein, the driving behavior cognitive model is a model used to characterize the correlation between the driver's driving behavior data, the vehicle's IMU data, and the compensation strategy of the IMU data; The error compensation module is used to acquire the current IMU data of the vehicle and the current driving behavior data of the driver, input the current IMU data and the current driving behavior data into the driving behavior cognitive model, and output the error compensation value for the current IMU data. The mileage calculation module is used to calculate the vehicle's driving trajectory based on the current IMU data and the error compensation value, and to calculate the vehicle's total mileage based on the driving trajectory.
9. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 7.
