An IMU adaptive zero speed detection method based on observation dispersion histogram
Patent Information
- Application Number
- CN202611108352.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-24
- Publication Date
- 2026-10-09
AI Technical Summary
[0013]本发明提供一种基于观测离散度直方图的IMU自适应零速检测方法,用以解决现有技术中固定阈值缺乏自适应性,自适应方法依赖概率建模且计算复杂,而数据驱动方法则受限于标注成本和泛化能力的缺陷
[0024]本发明提供的基于观测离散度直方图的IMU自适应零速检测方法,通过对 IMU 六轴传感数据构建专属观测离散度模型,依托数据天然形成的双峰几何分布特征自动完成自适应阈值求解,全程无需人工手动标定参数。该方案适配各类运动场景,有效提升复杂工况下静止 / 运动判别的稳定性,大幅降低算法落地调试成本,显著增强工程实际部署的便捷程度。
Smart Images

Figure CN122881704A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of integrated navigation technology, and in particular to an IMU adaptive zero-velocity detection method based on observation dispersion histogram. Background Technology
[0002] With the continuous maturation of Micro-Electro-Mechanical Systems (MEMS) technology, Inertial Measurement Units (IMUs) have been widely used in motion perception fields such as pedestrian navigation, autonomous driving, robot localization, and vehicle attitude estimation due to their advantages of small size, low cost, and low power consumption. In inertial navigation systems, integral drift is the core problem restricting positioning accuracy—even with high-precision sensors, after double integration of acceleration and angular velocity, the position error will still accumulate rapidly over time on the order of the cube, which can completely invalidate the navigation results in a short period of time.
[0003] To suppress integral drift, Zero-velocity Update (ZUPT) technology is widely recognized as one of the most effective and economical engineering methods. The core idea of this technology is that during the time the vehicle (pedestrian, vehicle, or robot) is stationary, the system can apply velocity observation constraints to the navigation solution based on the precise prior information that "the velocity should be zero when stationary," thereby effectively resetting the accumulated integral error. Therefore, the effectiveness of ZUPT technology depends on the system's ability to accurately identify the stationary and moving periods of the vehicle from continuously acquired IMU data; this identification process is called Zero-velocity Detection. The accuracy of Zero-velocity Detection directly determines the correction effect of ZUPT and ultimately dominates the long-term positioning accuracy of the entire navigation system.
[0004] Extensive research has been conducted by scholars both domestically and internationally on the zero-velocity detection problem, resulting in a variety of detection methods. Based on the technical approaches employed, these methods can be categorized as follows: detection methods based on fixed thresholds, detection methods based on adaptive thresholds, and data-driven machine learning methods. While all of these methods can achieve a certain degree of static / dynamic state discrimination under specific conditions, they face challenges in practical deployment, including insufficient adaptability, implementation complexity, or poor generalization ability. The following sections analyze the technical solutions and inherent limitations of each existing technology.
[0005] The first category is detection methods based on fixed thresholds. These methods first define a statistic that reflects the intensity of signal fluctuations—commonly used statistics include accelerometer window variance, gyroscope window energy, and the Generalized Likelihood Ratio Test (GLRT) statistic—and then compare this statistic with a pre-set fixed threshold. When the statistic is below the threshold, the carrier is determined to be stationary; otherwise, it is determined to be in motion. This type of method was widely used in early zero-velocity detection systems due to its intuitive principle and simple calculation. Typical implementations include comparing the weighted sum of the three-axis variances of the accelerometer with a fixed threshold, or determining zero velocity when the gyroscope magnitude is below a certain fixed threshold.
[0006] The second category is adaptive thresholding methods based on the generalized likelihood ratio (GLR). These methods statistically model sensor noise, construct a GLR test statistic, and dynamically adjust the discrimination threshold based on the statistical characteristics of the current data. Compared to fixed threshold methods, the GLRT method theoretically possesses a constant false alarm rate (CFAR) characteristic, enabling it to adapt to changes in sensor noise levels to some extent. However, its detection statistic involves estimating the probability density function and calculating the GLR, resulting in a relatively complex algorithm structure. Furthermore, the threshold adjustment process still relies on prior assumptions about the noise distribution model.
[0007] The third category comprises data-driven machine learning methods. In recent years, with the popularization of deep learning technology, some research has begun to introduce classification models such as Support Vector Machines (SVM), Multilayer Perceptrons, or Convolutional Neural Networks into zero-speed detection tasks. These methods transform zero-speed detection into a binary classification problem, training a classifier to automatically distinguish between stationary and moving states through supervised learning on labeled IMU training data. These methods exhibit high classification accuracy in multi-motion mode scenarios, but their performance is highly dependent on the quality and coverage of the training data.
[0008] While the aforementioned existing technologies each have their own characteristics, they all have significant limitations in practical engineering applications.
[0009] The core drawback of fixed-threshold detection methods is that the threshold cannot be adaptively adjusted once set. In practical applications, different IMU devices have varying noise levels, and the noise characteristics of the same device will drift under different temperature conditions and supply voltages. Furthermore, the signal fluctuation amplitude can vary by more than an order of magnitude under different motion modes (such as constant speed driving, acceleration / deceleration, and bumpy roads). Fixed thresholds are prone to serious misjudgments when faced with any of these variations—a threshold that is too high will miss low-speed or small-amplitude movements, while a threshold that is too low will misjudge stationary periods as motion, directly causing ZUPT to fail. Therefore, such methods require extensive manual parameter tuning before practical deployment and are difficult to adapt to changing operating environments.
[0010] While adaptive thresholding methods based on generalized likelihood ratios achieve a certain degree of threshold adaptation, they still fundamentally rely on statistical modeling assumptions about sensor noise and motion signals. When actual noise characteristics deviate from these model assumptions (e.g., noise exhibits non-Gaussian characteristics under vibration), detection performance significantly degrades. Furthermore, these methods involve likelihood function calculations and iterative parameter estimation, resulting in high computational complexity and making real-time operation on embedded platforms difficult, hindering engineering deployment in resource-constrained scenarios.
[0011] For machine learning-based detection methods, the core drawback lies in their heavy reliance on large amounts of high-quality labeled data for model training. However, data labeling is costly, and the data distribution varies greatly across different carriers, motion modes, and sensors, making it difficult to transfer trained models across different scenarios. Furthermore, the inference process of neural networks requires significant computational resources, creating a bottleneck in deployment within embedded systems with strict real-time and power consumption requirements. More importantly, the decision-making process of such methods lacks clear physical interpretability, making it difficult to pinpoint the cause and implement targeted improvements when misjudgments occur.
[0012] In summary, existing technologies generally suffer from the following drawbacks: fixed thresholds lack adaptability, adaptive methods rely on probabilistic modeling and are computationally complex, while data-driven methods are limited by annotation costs and generalization capabilities. This makes it difficult to meet the needs of practical applications. Summary of the Invention
[0013] This invention provides an IMU adaptive zero-rate detection method based on the observation dispersion histogram, which solves the problems of existing technologies where fixed thresholds lack adaptability, adaptive methods rely on probability modeling and are computationally complex, and data-driven methods are limited by labeling costs and generalization ability.
[0014] In a first aspect, the present invention provides an IMU adaptive zero-rate detection method based on an observation dispersion histogram, comprising: Based on the normalized variance weighted sum of the six-axis data of the inertial measurement unit within the sliding window, the observation dispersion is defined. The dispersion data of the stationary period and the motion period are expanded into a bimodal distribution on the histogram through logarithmic transformation, where the left peak corresponds to the stationary state and the right peak corresponds to the motion state. A histogram is constructed for the logarithmic domain discreteness and smoothed. Local maxima are detected in the smoothed histogram, and the two peaks with the largest ordinates are extracted as the stationary peak and the moving peak. The average of the horizontal coordinates of the stationary peak and the moving peak is taken as an adaptive threshold. The logarithmic domain dispersion of each frame is compared with the adaptive threshold to determine the stationary or moving state.
[0015] According to the present invention, an IMU adaptive zero-velocity detection method based on observation dispersion histogram is provided, wherein the observation dispersion is the weighted sum of the normalized variances of the six-axis data of the inertial measurement unit within a sliding window; The normalized variance of each axis is the sample variance of that axis within the window multiplied by the square of the sampling rate, and the weights of each axis are configured according to the actual application scenario.
[0016] According to the present invention, an IMU adaptive zero-velocity detection method based on the observation discreteness histogram is provided. The method of expanding the discreteness data of the stationary period and the motion period into a bimodal distribution on the histogram by logarithmic transformation includes: utilizing the nonlinear characteristics of the logarithmic function with a large stretching factor in the near-zero region to fully expand the discreteness data of the stationary period located near the zero point on the horizontal axis, so that the stationary peak is separated from the indistinguishable region. The physical basis of the bimodal distribution is that the dispersion during the stationary period is dominated by the sensor's background noise variance and is stable in magnitude, while the dispersion during the moving period is dominated by the time-varying variance of the motion signal and is much larger in magnitude than the noise variance.
[0017] According to the present invention, an IMU adaptive zero-rate detection method based on the histogram of observation dispersion is provided, wherein the histogram smoothing process adopts Gaussian smoothing to eliminate local statistical spikes caused by the limited amount of data; The peak detection traverses all local maxima points on the smoothed histogram.
[0018] According to the present invention, an IMU adaptive zero-velocity detection method based on an observation dispersion histogram is provided, wherein taking the mean of the two peak abscissas as the adaptive threshold includes: In the logarithmic domain, the midpoint between two peaks is taken as the threshold. This threshold falls near the valley between the two peaks, thus achieving automatic segmentation between static and dynamic states. The threshold is entirely determined by the distribution characteristics of the current data itself. When the sensor noise characteristics or motion signal intensity change, the positions of the two peaks are synchronously and adaptively adjusted.
[0019] The IMU adaptive zero-rate detection method based on the histogram of observation dispersion provided by the present invention further includes a threshold dynamic update mechanism for long-term operation: At preset time intervals, the discreteness calculation, logarithmic transformation, histogram construction, peak detection, and threshold calculation are re-executed to track the slow drift of sensor characteristics and changes in the motion environment.
[0020] According to the present invention, an IMU adaptive zero-velocity detection method based on observation discreteness histogram is provided, wherein the six-axis data of the inertial measurement unit includes the output of a three-axis gyroscope and the output of a three-axis accelerometer; The sliding window has a length of 1 second.
[0021] Secondly, the present invention also provides an IMU adaptive zero-rate detection system based on an observation dispersion histogram, comprising: The discreteness modeling module is used to define the observation discreteness based on the normalized variance weighted sum of the six-axis data of the inertial measurement unit within the sliding window. Through logarithmic transformation, the discreteness data of the stationary period and the motion period are expanded into a bimodal distribution on the histogram, where the left peak corresponds to the stationary state and the right peak corresponds to the motion state. The histogram processing and peak extraction module is used to construct a histogram for the logarithmic domain discreteness and perform smoothing processing, detect local maxima in the smoothed histogram, and extract the two peaks with the largest ordinates as the stationary peak and the moving peak. The adaptive threshold and state discrimination module is used to take the average of the horizontal coordinates of the stationary peak and the motion peak as the adaptive threshold, and compare the logarithmic domain dispersion of each frame with the adaptive threshold to determine the stationary or motion state.
[0022] Thirdly, the present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the IMU adaptive zero-rate detection method based on the observation discreteness histogram as described above.
[0023] Fourthly, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the IMU adaptive zero-rate detection method based on the observation discreteness histogram as described above.
[0024] The IMU adaptive zero-velocity detection method based on observation dispersion histogram provided by this invention constructs a dedicated observation dispersion model for the IMU's six-axis sensing data. It automatically completes adaptive threshold calculation based on the naturally formed bimodal geometric distribution characteristics of the data, eliminating the need for manual parameter calibration throughout the process. This solution is adaptable to various motion scenarios, effectively improving the stability of static / motion discrimination under complex conditions, significantly reducing the cost of algorithm deployment and debugging, and greatly enhancing the convenience of practical engineering deployment. Attached Figure Description
[0025] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0026] Figure 1 This is a flowchart illustrating the IMU adaptive zero-rate detection method based on the observation dispersion histogram provided by the present invention. Figure 2 This is a schematic diagram of the main interferences in zero-speed detection of the vehicle-mounted IMU provided by the present invention; Figure 3 This is a schematic diagram of the core module of the adaptive zero-velocity detection based on the observation dispersion histogram provided by the present invention; Figure 4 This is a schematic diagram of the core sub-process of Gaussian smoothing and peak extraction of logarithmic domain histogram provided by the present invention; Figure 5 This is a schematic diagram of the structure of the IMU adaptive zero-velocity detection system based on the observation discreteness histogram provided by the present invention; Figure 6 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation
[0027] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0028] Figure 1 This is a flowchart illustrating the IMU adaptive zero-rate detection method based on the histogram of observation discreteness provided in this embodiment of the invention. Figure 1 As shown, it includes: Step 100: Based on the normalized variance weighted sum of the six-axis data of the inertial measurement unit within the sliding window, define the observation dispersion. Through logarithmic transformation, expand the dispersion data of the stationary period and the motion period into a bimodal distribution on the histogram, where the left peak corresponds to the stationary state and the right peak corresponds to the motion state. Step 200: Construct a histogram for the logarithmic domain discreteness and perform smoothing processing; detect local maxima in the smoothed histogram and extract the two peaks with the largest ordinates as the stationary peak and the moving peak. Step 300: Take the average of the horizontal coordinates of the stationary peak and the moving peak as an adaptive threshold, and compare the logarithmic domain dispersion of each frame with the adaptive threshold to determine the stationary or moving state.
[0029] Specifically, Figure 2 This is a schematic diagram of the main interferences in zero-speed detection of an onboard IMU provided in this embodiment of the invention. In the figure, engine idling vibration and IMU measurement noise are marked at the top, and both affect the time series curve below. When the vehicle is stationary, the theoretically constant IMU measurement value is affected by the two types of interference, exhibiting continuous small fluctuations, which can easily lead to misjudgment of zero-speed detection and is an important cause of errors in onboard inertial navigation.
[0030] Figure 3 This diagram illustrates the core module of the adaptive zero-velocity detection based on the histogram of observation dispersion provided in this invention, encompassing the complete algorithm's operational chain and corresponding to the core steps of the patent. This module takes raw IMU data as input, calculates the six-axis signal dispersion in real time using a sliding window, and sequentially completes observation dispersion modeling, logarithmic domain histogram bimodal extraction, adaptive threshold calculation, frame state discrimination, and periodic threshold updates. This algorithm amplifies the distribution differences between static and moving data through logarithmic transformation, automatically generating discrimination thresholds based on inherent data characteristics, eliminating the need for manual parameter presets. Simultaneously, the dynamic threshold update mechanism effectively adapts to sensor temperature drift, road environment, and motion mode changes, ensuring long-term operational stability and stable output of zero-velocity determination results. This provides support for zero-velocity correction in integrated navigation, achieving fully automatic, parameter-free IMU zero-velocity detection.
[0031] This invention first establishes an observation dispersion model for IMU six-axis data, defining dispersion by weighting the normalized variance of each axis within a sliding window. Starting from the essential differences in signal source composition under static and dynamic states, it derives the theoretical basis for the stable bimodal distribution of logarithmic domain dispersion. Then, it constructs a histogram of the logarithmic domain dispersion for all frames, eliminates statistical spikes through Gaussian smoothing, detects all local maxima in the smoothed histogram, and extracts the two peaks with the largest ordinates as the static peak and the dynamic peak. Finally, it takes the mean of the two peaks' abscissas as an adaptive threshold, compares the logarithmic dispersion with the threshold frame by frame to determine the static or dynamic state, and provides a dynamic threshold update mechanism for long-term operation.
[0032] Based on the above embodiments, step 100 includes: establishing an observation dispersion model for IMU six-axis data, defining dispersion by weighting the normalized variance of each axis within a sliding window, and deriving the theoretical basis for the stable bimodal distribution of logarithmic domain dispersion based on the essential differences in signal source composition under static and dynamic states.
[0033] 1. Calculation of observation dispersion and bimodal distribution characteristics 1.1 Definition and Calculation Formula of Observation Dispersion Assume the IMU at time... The output six-axis data is as follows:
[0034] in For a moment A six-axis data vector; These are outputs from a three-axis gyroscope; These are the outputs of the three-axis accelerometer.
[0035] With a fixed duration (Preferred version of the present invention) (seconds) is used as a sliding window for each moment. , take window within Frame data ( , (For sampling rate). Define the first [number] within the window. The sample variance of the axis data is:
[0036] in For a moment The first in the window The sample variance of the axis data; For the first axis at time The reading; For the first in the window The mean of the axis data; The summation index variable represents the sum of each frame within the window relative to the current time. The offset; The number of data frames within the window; The axis index takes values from 1 to 6, corresponding to... .
[0037] Considering that the number of samples within a window varies under different sampling rates, and that the variance itself is related to the sampling rate, a dispersion measure independent of the sampling rate is obtained by normalizing the variance by multiplying it by the square of the sampling rate. Define the... The normalized variance of the axis is:
[0038] in For the first Normalized variance of the axis; The sampling rate.
[0039] Define observation dispersion The weighted sum of the normalized variances across the six axes:
[0040] in For a moment The observation dispersion; For the first The weighting coefficient of the axis; For the first Normalized variance of the axis.
[0041] Weight vector For the six-axis data, each weight takes an arbitrary real number between 0 and 1, representing the degree to which the data of that axis contributes to the observation dispersion: 0 means the axis is completely ignored, 1 means it is fully included, and a value in between represents a partial contribution. The weight vector can be flexibly configured according to the actual application scenario—for example, in a vibrating environment, the weight of the sensitive axis can be appropriately reduced, or the weight of certain axes can be selectively increased under specific motion modes.
[0042] Observation Dispersion The physical meaning is clear: it measures the overall fluctuation of the IMU's six-axis readings within a unit time window. The more stable the readings within the window, the smaller the variance of each axis. The lower the value, the greater the fluctuation in the reading within the window. The higher.
[0043] In actual implementation, the data stream is first initialized: the sliding window length is set. Maintain a length of The circular buffer stores the most recent The frame contains six axes of data. For each new frame, after updating the circular buffer, the sample variance, normalized variance, and observation dispersion of each axis within the window are calculated sequentially using the formulas described above. And store it for use in subsequent steps.
[0044] 1.2 Theoretical Explanation of the Log(Dispersion) Bimodal Distribution A key finding of this invention is the observation dispersion across all frames throughout the entire time period. After taking the natural logarithm, its histogram exhibits a stable bimodal distribution—the left peak corresponds to the stationary period, and the right peak corresponds to the moving period, with a clear trough interval between the two peaks. This phenomenon can be rigorously explained by the signal composition characteristics of the IMU.
[0045] 1.2.1 Quiet Period: Sensor Noise Dominates When the IMU is stationary, its gyroscope and accelerometer theoretical outputs should be constant (the gyroscope theoretical output is zero, and the accelerometer theoretical output is the constant gravitational acceleration). Actual measurements can be modeled as follows:
[0046] in For the first time in a static state axis at time The measured value; For the first The theoretical constant value of the axis (0 for gyroscope, gravitational acceleration component for accelerometer). For the first axis at time The sensor's own noise is usually modeled as zero-mean Gaussian white noise or a Gaussian-Markov process.
[0047] The noise sources of MEMS inertial sensors mainly include quantization noise, angle random walk, velocity random walk, and zero-bias instability. These noises can typically be modeled as zero-mean Gaussian white noise or a Gaussian-Markov process, with variance... Due to the inherent characteristics of the sensor, it remains stable for a short period of time.
[0048] Therefore, the sample variance of the data for each axis within the static time window Mainly due to sensor noise variance The decision is:
[0049] in For the static period The sample variance of the axis data; For the first Variance of shaft sensor noise; The small error term estimated for finite samples varies with the window length. It increases and approaches zero. Correspondingly, the observation dispersion during the stationary period... It stabilizes at a low level determined by the sensor's intrinsic noise floor, its logarithm They cluster on the left side of the histogram, forming a narrow and sharp stationary peak.
[0050] 1.2.2 Motion Period: Dominated by Real Motion Signals When the IMU is in motion, the outputs of the gyroscope and accelerometer, in addition to sensor noise, also include the actual angular and linear motion signals of the carrier:
[0051] in For the first state of motion axis at time The measured value; For the first axis at time The true motion signal components; This is the sensor's own noise. Unlike pure noise during a stationary period, motion signals... It exhibits significant time-varying characteristics—changes in the carrier's attitude and acceleration cause continuous fluctuations in the six-axis readings.
[0052] Within a 1-second timescale, the angular velocity and acceleration of typical carrier motion (such as vehicle movement) exhibit significant time-varying characteristics. The sample variance of the data for each axis within the window is also shown. It will be dominated by the time-varying variance of the motion signal:
[0053] in For the first exercise period The sample variance of the axis data; For real motion signals The time-varying variance; This represents the sensor noise variance.
[0054] Because the amplitude and rate of change of motion signals are typically several orders of magnitude higher than sensor noise, the observation dispersion during motion periods is... Much larger than the static period, its logarithm They are distributed on the right side of the histogram, forming motion peaks.
[0055] 1.2.3 The Inevitability of Two-Peak Separation In summary, the difference in observation dispersion between static and dynamic states stems from the different sources of the signals: When at rest, The magnitude of the noise variance is stable and relatively small, determined by the inherent noise variance of the sensor. During exercise, Determined by the time-varying variance of the motion signal, its magnitude is much larger than that of the noise variance.
[0056] The magnitude difference between the two typically spans more than an order of magnitude, which is reflected in the logarithmic domain as two fully separated peaks on the horizontal axis. More importantly, since the statistical characteristics of sensor noise remain stable in the short term, while the statistical characteristics of motion signals, although varying with the motion mode, always have a variance much larger than the noise variance, this bimodal structure has a natural robustness to different motion modes (e.g., different vehicle speeds, different road surfaces)—regardless of changes in motion intensity, the position of the motion peak may shift to the right or left, but it always maintains a sufficient distance from the stationary peak.
[0057] 1.3 The necessity of logarithmic transformation: to make the stationary peak appear in the neighborhood of zero. This invention assesses the observation dispersion before constructing the histogram. Taking the natural logarithm is a core operation aimed at making the static peaks, which were originally close to zero and difficult to distinguish, fully expand and become clearly visible in the logarithmic domain.
[0058] 1.3.1 The static peak in the original domain is "squeezed" to near zero. Observation dispersion during static periods Determined by the sensor's noise floor variance, it is a very small positive quantity, close to zero. In the original domain histogram, The value range extends from 0 to the larger values corresponding to the motion signal, differing by several orders of magnitude. If a linearly spaced interval is used to divide the histogram, the interval width must be sufficiently large to cover the entire value range, leading to... Within this extremely small interval, only a very small number of intervals can be allocated, and even the entire static peak may be compressed into the first interval, making it impossible to form a recognizable independent peak shape.
[0059] 1.3.2 Logarithmic Transform for Nonlinear Expansion of the Zero Neighborhood logarithmic function exist The time derivative is This means that in The closer the region is to zero, the greater the stretching factor of the logarithmic transformation. This nonlinear property fully expands the static peak data that was originally squeezed near the zero point on the logarithmic axis, allowing the static peak to be separated from the "indistinguishable region close to the zero point" and form independent peaks with clear shape and sufficient width.
[0060] 1.3.3 The logarithmic transformation does not change the existence of bimodal peaks, but only their distinguishability. It is important to emphasize that the stationary peak objectively exists in the original domain, but it is difficult for the histogram to effectively capture it due to insufficient resolution near the zero point under linear coordinates. The logarithmic transformation does not create a new distribution structure, but rather explicitly reveals the bimodal structure that was originally obscured by the coordinate scale. After the logarithmic transformation, the stationary peak and the moving peak are located within reasonable numerical ranges on the horizontal axis, both having sufficient interval width and peak height, which facilitates subsequent peak detection and threshold calculation.
[0061] In summary, taking the logarithm is to perform fine-scale segmentation of the near-zero numerical region in histogram statistics, so that the stationary peak can stand out independently from the neighborhood of the origin, thus forming a clearly distinguishable bimodal structure together with the moving peak.
[0062] Based on the above embodiments, step 200 includes: constructing a histogram of the logarithmic domain dispersion of all frames, eliminating statistical spikes by Gaussian smoothing, detecting all local maxima in the smoothed histogram, and extracting the two peaks with the largest ordinates as the stationary peak and the moving peak.
[0063] 2. Histogram statistics, smoothing, and bimodal detection Based on the aforementioned bimodal distribution characteristics, this step automatically locates the positions of the two peaks by constructing and processing the logarithmic domain histogram.
[0064] 2.1 Logarithmic Transformation and Histogram Statistics After accumulating a sufficient number of frames (preferably no less than 500 frames to ensure the statistical significance of the histogram statistics), all stored frames are then processed. Taking the natural logarithm, we get .for In extreme cases (which theoretically shouldn't occur because the sensor noise variance is always positive), we can set... ,in It is a very small positive number.
[0065] Will The range of values is divided into Divide the data into several equally spaced intervals (bins), count the number of frames falling into each interval, and obtain a histogram. Interval number The optimal value can be determined adaptively based on the total amount of data. Pick The integer part, or the Sturges formula.
[0066] in Discreteness in the logarithmic field; To process The smallest positive number introduced in extreme cases; This represents the number of intervals in the histogram. This represents the total number of data frames included in the statistics.
[0067] 2.2 Histogram Smoothing and Peak Detection histogram Gaussian smoothing is applied to eliminate local spikes caused by limited data or noise, making the bimodal structure clearer and more discernible. The standard deviation of the Gaussian kernel is then calculated. Ideally, the width should be set to 1-3 bins. The smoothed histogram is denoted as... .
[0068] in This is the original histogram; The standard deviation of the Gaussian smoothing kernel; This is the smoothed histogram.
[0069] In smooth histogram Detect all local maxima (i.e., peak values) and select the two peak values with the largest ordinates, denoted as and respectively. (The smaller x-axis) and (The larger of the x-axis). Based on the aforementioned theoretical analysis, Corresponding to the stationary peak, Corresponding motion peak.
[0070] in This represents the x-coordinate position of the left peak (stationary peak); This represents the x-coordinate position of the right peak (movement peak).
[0071] Based on the above embodiments, step 300 includes: The average of the two peak abscissas is taken as the adaptive threshold. The logarithmic dispersion is compared with the threshold frame by frame to determine the static or dynamic state, and a dynamic threshold update mechanism is provided for long-term operation.
[0072] 3. Adaptive threshold determination and state discrimination After obtaining two peaks and This step then completes the adaptive calculation of the threshold, state discrimination, and dynamic updating of the threshold.
[0073] 3.1 Peak-to-average value as adaptive threshold This invention uses the average of the abscissas of the two peaks as the adaptive threshold for zero-velocity detection:
[0074] in This is an adaptive threshold.
[0075] In the logarithmic domain, the threshold is taken as the midpoint between the two peaks; equivalently, in the original domain, the threshold is taken as the geometric mean of the discrete values corresponding to the two peaks.
[0076] The rationality of this threshold selection strategy can be demonstrated from the following three aspects: First, geometric optimality. Within the framework of a bimodal distribution of a histogram, the valley between the two peaks is the optimal dividing point. After logarithmic transformation, the shapes of the two peaks are clear, and the valley bottoms are well-defined; the midpoint between the two peaks must fall near the valley bottom. Unlike traditional methods that require complex valley-finding algorithms, the peak-average method does not require iterative valley-finding, resulting in minimal computational cost.
[0077] Second, adaptability and robustness. Threshold It is entirely determined by the distribution characteristics of the current data itself. It reflects the current noise level of the sensor (affected by environmental factors such as temperature and power supply). It reflects the intensity level of the current motion signal. When sensor characteristics change (such as increased noise due to temperature drift) or the motion pattern changes, the positions of the two peaks will be synchronously and adaptively adjusted, and the threshold will be adjusted accordingly. It also changes dynamically, without any human intervention or prior parameters.
[0078] Third, its physical meaning is clear. Threshold The logarithmic discrete space is divided into two regions: The frames were judged to be static (the dispersion was at the sensor's noise floor level). The frames are determined to be motion (the discreteness contains significant motion signal components). This determination criterion is completely consistent with the physical generation mechanism of IMU signals and has good interpretability.
[0079] 3.2 State Judgment Rules For each frame Based on its logarithmic dispersion and threshold Determine the relationship: like It is determined to be stationary; like It is determined to be a sport.
[0080] This discrimination rule can be executed frame by frame on the data throughout the entire time period, outputting the static / motion state label at each moment, providing a basis for subsequent zero-speed correction.
[0081] 3.3 Dynamic updating of threshold For systems operating for extended periods, sensor characteristics may slowly drift due to factors such as temperature changes and power supply fluctuations, and motion patterns may also change over time. To address this, the present invention provides an optional dynamic update mechanism: at regular time intervals, the logarithmic transformation, histogram statistics, smoothing, and peak detection in step 2 are re-executed, and the threshold is recalculated. This allows for the tracking of slow changes in sensor characteristics and the motion environment, ensuring that the threshold remains adaptively optimal at all times.
[0082] Figure 4 The schematic diagram of the core sub-process of Gaussian smoothing and peak extraction in the logarithmic domain histogram provided in this embodiment of the invention is a key innovative step in achieving accurate adaptive threshold calculation. Addressing the industry pain points of zero-point noise aggregation and difficulty in distinguishing between static and dynamic states in the original discrete data, this sub-process first performs logarithmic nonlinear stretching on the discrete data to optimize the data distribution structure. Then, Gaussian smoothing is used to filter out random spikes introduced by sampling, ensuring a smooth and continuous histogram curve. Finally, the curve is traversed to filter for dual-feature peaks, utilizing the natural bimodal difference between static noise and moving signals to automatically and accurately distinguish between the two types of data. This process requires no complex iterative calculations, operates fully automatically, has low computational overhead, and is adaptable to real-time computing scenarios of embedded low-computing-power navigation devices, providing reliable pre-processing data support for the entire adaptive zero-speed detection algorithm.
[0083] The IMU adaptive zero-rate detection system based on the observation discreteness histogram provided by the present invention will be described below. The IMU adaptive zero-rate detection system based on the observation discreteness histogram described below can be referred to in correspondence with the IMU adaptive zero-rate detection method based on the observation discreteness histogram described above.
[0084] Figure 5 This is a schematic diagram of the structure of the IMU adaptive zero-rate detection system based on the observation dispersion histogram provided in this embodiment of the invention, as shown below. Figure 5 As shown, it includes: a discreteness modeling module 51, a histogram processing and peak extraction module 52, and an adaptive threshold and state discrimination module 53, wherein: The discreteness modeling module 51 defines the observation discreteness based on the normalized variance weighted sum of the six-axis data of the inertial measurement unit within a sliding window. It then expands the discreteness data of the stationary and motion periods into a bimodal distribution on a histogram through logarithmic transformation, where the left peak corresponds to the stationary state and the right peak corresponds to the motion state. The histogram processing and peak extraction module 52 constructs a histogram for the logarithmic domain discreteness and performs smoothing processing. It detects local maxima in the smoothed histogram and extracts the two peaks with the largest ordinates as the stationary peak and the motion peak. The adaptive threshold and state discrimination module 53 takes the mean of the abscissas of the stationary peak and the motion peak as an adaptive threshold and compares the logarithmic domain discreteness of each frame with the adaptive threshold to determine the stationary or motion state.
[0085] Figure 6 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 6As shown, the electronic device may include: a processor 610, a communication interface 620, a memory 630, and a communication bus 640, wherein the processor 610, the communication interface 620, and the memory 630 communicate with each other through the communication bus 640. The processor 610 can call logic instructions in the memory 630 to execute an IMU adaptive zero-velocity detection method based on an observation dispersion histogram. This method includes: defining observation dispersion based on the normalized variance weighted sum of the six-axis data of the inertial measurement unit within a sliding window; expanding the dispersion data of the stationary and motion periods into a bimodal distribution on a histogram through logarithmic transformation, where the left peak corresponds to the stationary state and the right peak corresponds to the motion state; constructing a histogram for the logarithmic dispersion and smoothing it; detecting local maxima in the smoothed histogram; extracting the two peaks with the largest ordinates as the stationary peak and the motion peak; taking the mean of the abscissas of the stationary peak and the motion peak as an adaptive threshold; and comparing the logarithmic dispersion of each frame with the adaptive threshold to determine the stationary or motion state.
[0086] Furthermore, the logical instructions in the aforementioned memory 630 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0087] On the other hand, the present invention also provides a non-transitory computer-readable storage medium storing a computer program thereon. When executed by a processor, the computer program implements the IMU adaptive zero-velocity detection method based on the observation dispersion histogram provided by the above methods. The method includes: defining the observation dispersion based on the normalized variance weighted sum of the six-axis data of the inertial measurement unit within a sliding window; expanding the dispersion data of the stationary and motion periods into a bimodal distribution on the histogram through logarithmic transformation, wherein the left peak corresponds to the stationary state and the right peak corresponds to the motion state; constructing a histogram for the logarithmic dispersion and smoothing it; detecting local maxima in the smoothed histogram; extracting the two peaks with the largest ordinates as the stationary peak and the motion peak; taking the mean of the abscissas of the stationary peak and the motion peak as an adaptive threshold; and comparing the logarithmic dispersion of each frame with the adaptive threshold to determine the stationary or motion state.
[0088] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0089] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0090] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. An IMU adaptive zero-rate detection method based on observation dispersion histogram, characterized in that, include: Based on the normalized variance weighted sum of the six-axis data of the inertial measurement unit within the sliding window, the observation dispersion is defined. The dispersion data of the stationary period and the motion period are expanded into a bimodal distribution on the histogram through logarithmic transformation, where the left peak corresponds to the stationary state and the right peak corresponds to the motion state. A histogram is constructed for the logarithmic domain discreteness and smoothed. Local maxima are detected in the smoothed histogram, and the two peaks with the largest ordinates are extracted as the stationary peak and the moving peak. The average of the horizontal coordinates of the stationary peak and the moving peak is taken as an adaptive threshold. The logarithmic domain dispersion of each frame is compared with the adaptive threshold to determine the stationary or moving state.
2. The IMU adaptive zero-rate detection method based on the observation discreteness histogram according to claim 1, characterized in that, The observation dispersion is the weighted sum of the normalized variances of the six-axis data of the inertial measurement unit within the sliding window; The normalized variance of each axis is the sample variance of that axis within the window multiplied by the square of the sampling rate, and the weights of each axis are configured according to the actual application scenario.
3. The IMU adaptive zero-rate detection method based on the observation discreteness histogram according to claim 1, characterized in that, The method of expanding the discrete data of the stationary period and the motion period into a bimodal distribution on the histogram by logarithmic transformation includes: utilizing the nonlinear characteristic of the logarithmic function that has a large stretching factor in the near-zero region to fully expand the discrete data of the stationary period located near the zero point on the horizontal axis, so that the stationary peak is separated from the indistinguishable region. The physical basis of the bimodal distribution is that the dispersion during the stationary period is dominated by the sensor's background noise variance and is stable in magnitude, while the dispersion during the moving period is dominated by the time-varying variance of the motion signal and is much larger in magnitude than the noise variance.
4. The IMU adaptive zero-rate detection method based on the histogram of observation discreteness according to claim 1, characterized in that, The histogram smoothing process uses Gaussian smoothing to eliminate local statistical spikes caused by the limited amount of data. The peak detection traverses all local maxima points on the smoothed histogram.
5. The IMU adaptive zero-rate detection method based on the histogram of observation discreteness according to claim 1, characterized in that, The step of taking the average of the two peak abscissas as the adaptive threshold includes: In the logarithmic domain, the midpoint between two peaks is taken as the threshold. This threshold falls near the valley between the two peaks, thus achieving automatic segmentation between static and dynamic states. The threshold is entirely determined by the distribution characteristics of the current data itself. When the sensor noise characteristics or motion signal intensity change, the positions of the two peaks are synchronously and adaptively adjusted.
6. The IMU adaptive zero-rate detection method based on the observation discreteness histogram according to claim 1, characterized in that, It also includes a dynamic threshold update mechanism for long-term operation: At preset time intervals, the discreteness calculation, logarithmic transformation, histogram construction, peak detection, and threshold calculation are re-executed to track the slow drift of sensor characteristics and changes in the motion environment.
7. The IMU adaptive zero-rate detection method based on the histogram of observation discreteness according to any one of claims 1 to 6, characterized in that, The six-axis data of the inertial measurement unit includes the output of a three-axis gyroscope and the output of a three-axis accelerometer; The sliding window has a length of 1 second.
8. An IMU adaptive zero-rate detection system based on observation discreteness histogram, characterized in that, include: The discreteness modeling module is used to define the observation discreteness based on the normalized variance weighted sum of the six-axis data of the inertial measurement unit within the sliding window. Through logarithmic transformation, the discreteness data of the stationary period and the motion period are expanded into a bimodal distribution on the histogram, where the left peak corresponds to the stationary state and the right peak corresponds to the motion state. The histogram processing and peak extraction module is used to construct a histogram for the logarithmic domain discreteness and perform smoothing processing, detect local maxima in the smoothed histogram, and extract the two peaks with the largest ordinates as the stationary peak and the moving peak. The adaptive threshold and state discrimination module is used to take the average of the horizontal coordinates of the stationary peak and the motion peak as the adaptive threshold, and compare the logarithmic domain dispersion of each frame with the adaptive threshold to determine the stationary or motion state.
9. An electronic 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 program, it implements the IMU adaptive zero-rate detection method based on the observation discreteness histogram as described in any one of claims 1 to 7.
10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the IMU adaptive zero-rate detection method based on the observation discreteness histogram as described in any one of claims 1 to 7.