Ultrasonic sensor environment compensation method and system based on multi-modal feature fusion
By using multimodal feature fusion and dynamic compensation models, the problem of insufficient measurement accuracy of ultrasonic sensors in complex environments is solved, achieving high-precision environmental adaptability and stability, which is applicable to fields such as intelligent manufacturing, autonomous driving, intelligent transportation, and public sensing.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-09
- Publication Date
- 2026-03-31
AI Technical Summary
Ultrasonic sensors suffer from insufficient measurement accuracy due to the combined interference of multi-dimensional environmental factors in complex environments. Existing technologies are unable to fully capture multi-dimensional environmental characteristics and dynamically adapt to environmental changes, resulting in limited compensation accuracy.
By using a multimodal feature fusion method, ultrasonic signal features and multi-dimensional environmental features are acquired simultaneously, feature weights are dynamically adjusted, and input into a pre-trained error compensation model to generate propagation speed correction parameters. The model's baseline parameters are then updated during range calibration to achieve continuous dynamic compensation.
It improves the measurement stability and accuracy of ultrasonic sensors in complex environments, adapts to different working conditions and measurement range changes, and meets the needs of high-precision detection.
Smart Images

Figure CN121763267A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of ultrasonic sensor measurement and environmental interference compensation technology, and more specifically, relates to an ultrasonic sensor environmental compensation method and system based on multimodal feature fusion. Background Technology
[0002] Ultrasonic sensors are widely used in distance detection and obstacle recognition due to their advantages such as low cost, fast response speed, and non-contact measurement. Their core measurement principle is based on calculating the detection distance by multiplying the ultrasonic wave's propagation time by its speed; therefore, the stability of the ultrasonic wave's propagation characteristics directly determines the measurement accuracy. However, in practical applications, multi-dimensional changes in the sensor's operating environment can significantly interfere with the ultrasonic wave's propagation characteristics, leading to increased measurement errors and becoming a key bottleneck restricting the improvement of its accuracy.
[0003] Temperature changes directly alter the propagation speed of ultrasonic waves. Propagation speed parameters under standard conditions will deviate significantly in high or low temperature environments, leading to errors in distance calculation results. Increased humidity and dust concentration enhance the attenuation effect of ultrasonic waves, reducing the amplitude of reflected signals and making the propagation path unstable, affecting the accurate detection of the transmission and reception time difference. Fluctuations in air pressure and airflow velocity change the direction and speed of ultrasonic wave propagation, further exacerbating the dispersion of measurement values. The combined effect of these environmental factors makes it difficult for ultrasonic sensors to meet practical requirements in complex scenarios such as industrial workshops and outdoor environments.
[0004] In existing technologies, some environmental compensation schemes only correct for a single parameter like temperature, failing to cope with the combined interference of multiple environmental factors. Other schemes use fixed compensation coefficients to correct for environmental impacts, but these are difficult to adapt to dynamic changes in different environmental parameters, resulting in limited compensation accuracy. As the requirements for sensor measurement accuracy continue to increase in fields such as intelligent manufacturing and autonomous driving, there is an urgent need for a compensation technology that can comprehensively capture multi-dimensional environmental characteristics and dynamically adapt to environmental changes. This would address the problem of insufficient measurement accuracy of ultrasonic sensors in complex environments, expand their application scope in high-precision detection scenarios, and has significant practical value. Summary of the Invention
[0005] This invention aims to solve the problem of insufficient measurement accuracy of ultrasonic sensors caused by the combined interference of multi-dimensional environmental factors in complex environments. By synchronously acquiring multi-modal features, dynamically fusing and adaptively updating the compensation model, it can accurately correct environmental interference, while adapting to range adjustment scenarios, improving the measurement stability and accuracy of the sensor under various working conditions, and meeting the requirements of high-precision detection.
[0006] To address the aforementioned deficiencies or improvement needs of existing technologies, as a first aspect of this invention, the present invention provides an ultrasonic sensor environmental compensation method based on multimodal feature fusion, comprising: S1. Activate the target ultrasonic sensor and collect ultrasonic signal characteristics through the sensor's ultrasonic detection unit; simultaneously, through the environmental perception module integrated with the sensor, collect multi-dimensional environmental characteristics of the sensor's working environment; all collected features are stored after being aligned with preset timestamps. S2. Invoke the weighting mechanism to determine the environmental feature weight benchmark based on the current working parameters of the sensor; dynamically adjust the weight of each feature in combination with real-time environmental feature values; fuse the weighted environmental features with ultrasonic signal features to generate a fused feature set; S3. Input the fused feature set into the pre-trained error compensation model; the model predicts the ultrasonic propagation characteristic offset through the fused feature set and outputs the propagation speed correction parameter that adapts to the core measurement formula of the sensor; S4. The sensor calculates the measured value after real-time compensation based on the correction parameters; the feature acquisition, fusion and correction parameter generation process is repeated according to the preset cycle to realize the dynamic update of multimodal feature acquisition, fusion and correction parameters, and complete continuous dynamic compensation; when the sensor triggers range calibration, the initial reference parameters of the compensation model are updated synchronously to adapt to the range adjustment scenario.
[0007] Furthermore, the ultrasonic signal characteristics in S1 include at least one of the following: the time difference between ultrasonic emission and reception, the amplitude of the reflected signal, and the phase.
[0008] Furthermore, the environmental perception module in S1 includes at least two types of environmental parameter detection elements.
[0009] Furthermore, the process of determining the environmental feature weight benchmark based on the current operating parameters of the sensor in S2 is as follows: Based on the current transducer frequency of the sensor and measurement range As a core parameter, a weighted benchmark correlation is constructed, in which the transducer frequency is used. With ultrasonic wavelength satisfy , The ultrasonic propagation speed under standard conditions is taken as a constant value for ultrasonic propagation speed at standard atmospheric pressure and 25°C. This is the upper limit of the measurement range currently set for the sensor, i.e., the maximum distance that the sensor can detect; For each environmental feature to be collected, calculate the corresponding environmental impact factor. and will As a weighting benchmark for this environmental characteristic, The calculation satisfies , The environmental characteristic correlation coefficient was obtained through sensor calibration experiments. The value represents the degree to which the corresponding environmental characteristics affect the ultrasonic wave propagation characteristics under the current sensor operating state. The larger the value, the more significant the impact.
[0010] Furthermore, the method for generating the fused feature set in S2 is as follows: First, normalization processing is performed on the ultrasonic signal characteristics and various environmental characteristics to eliminate dimensional differences between different feature dimensions. The normalization processing uses the formula... Implementation, in which These are the original values of the features to be processed. This represents the minimum value of this feature across all sensor operating scenarios. This represents the maximum value of this feature across all sensor operating scenarios. and We obtain data through statistical analysis of historical calibration data and full-condition test data of the sensors to ensure coverage of all possible working states of the sensors. Based on the established environmental characteristic weighting benchmark, i.e., environmental impact factors The incremental influence of environmental features is calculated by combining real-time collected environmental feature values. , ,in These are real-time collected values of environmental characteristics. This is the baseline value for this environmental characteristic under standard conditions; when At that time, take This is the correction amount for the impact of this environmental characteristic, when At that time, take ,in, The preset environmental deviation threshold was determined through sensor calibration experiments. Calculate the fusion coefficient of each environmental feature. , ,Will Corresponding normalized environmental characteristics Multiply, we get All environmental characteristics A weighted environmental feature vector is constructed; the normalized ultrasonic signal features are used as the core feature vector, and the core feature vector and the weighted environmental feature vector are concatenated sequentially in the order after being aligned with the timestamps to form the initial fused feature vector. Redundancy removal is performed on the initial fused feature vector, and the variance of each feature dimension in the initial fused feature vector is calculated. , ,in The number of samples for this feature dimension. For the first dimension Each sample value The sample mean for this dimension; variance removed. Feature dimensions, The pre-set variance threshold is determined based on feature discrimination tests under standard conditions, and the remaining feature dimensions constitute the final fused feature set.
[0011] Furthermore, the error compensation model in S3 is trained based on full-range calibration data and multiple environmental error samples under standard sensor conditions.
[0012] Furthermore, the process of constructing the propagation velocity correction parameter for the core measurement formula of the adaptive sensor in S3 is as follows: The process of constructing the propagation velocity correction parameters is centered on the mapping relationship between the fusion feature set and the ultrasonic propagation velocity offset. First, the correction benchmark is initialized. Based on the full-range calibration data of the sensor under standard conditions, the standard ultrasonic propagation velocity corresponding to different detection distances is obtained. And record the baseline feature vector under standard conditions. ,in ; This is the normalized value of the time difference between ultrasonic wave transmission and reception under standard conditions. This is the normalized value of the reflected signal amplitude under standard conditions. As a standard weighting benchmark for temperature characteristics, This is the normalized value of temperature under standard environmental conditions. As a standard weighting benchmark for humidity characteristics, The value is the normalized value of humidity under standard conditions, and the remaining items correspond to the standard weight benchmark and normalized value of other environmental characteristics; Construct a propagation velocity offset prediction model to fuse feature vectors in real time. With reference eigenvectors The difference is used as the core input to calculate the feature deviation vector. and to Perform standardized processing: ;in It is the mean of the historical feature deviation vector. It is the standard deviation of the historical characteristic deviation vector, both of which are obtained through statistical analysis of multi-environment calibration samples of the sensor; Input a pre-trained prediction model and output the ultrasonic wave propagation velocity offset. ; Based on propagation speed offset Constructing correction parameters: First, calculate the predicted real-time propagation speed. Then, through comparative experiments in standard and multi-interference environments, correction coefficients were established. and The connection: ;in It is the standard deviation of the propagation speed under standard conditions. It is the standard deviation of the propagation speed prediction in real-time environment, and both are calculated from historical calibration data; For correction coefficients Perform validity verification: Substitute the sensor's core measurement formula to calculate the corrected detection distance. , The time difference between ultrasonic wave transmission and reception is collected in real time; comparison If the error from the standard distance value is less than a preset threshold, then The parameters are adjusted to determine the final propagation speed; if the error exceeds the threshold, the parameters are fine-tuned in reverse based on the error value. Standardized parameters, recalculated Until the requirements are met.
[0013] Furthermore, the process of adapting to the range adjustment scenario in S4 is as follows: The process of adapting to range adjustment scenarios is based on the dynamic coupling mapping of "range-feature-model". When the sensor triggers range calibration, the upper and lower limit parameters of the new range are first obtained. , and the nearest point during calibration. Far point Real-time detection data, combined with sensor transducer frequency Calculate the effective wavelength of ultrasound corresponding to the new range. ;in The speed of ultrasonic wave propagation under standard conditions. , These are the original upper and lower limits of the measurement range; Based on the new range parameters, the influence correlation benchmark of environmental characteristics is reconstructed, and the influence benchmark value under the new range is calculated for each environmental characteristic. ;in The correlation coefficient for environmental characteristics is consistent with the calibration experimental data from the weighting benchmark determination process; To construct a reference feature matrix for the new measurement range, under standard conditions, select at least five calibration points within the new range, including near point, far point, and three equally divided intermediate points. Collect the ultrasonic signal characteristics and environmental characteristics of each calibration point, and generate the reference feature matrix for the new range after normalization processing. Replace the original single-vector benchmark; To perform a new measurement range accuracy closed-loop verification, firstly, under standard conditions, real-time fused features of the new measurement range calibration points are obtained through feature acquisition and fusion processes. These features are then input into the updated compensation model to obtain correction parameters, and the compensated measurement values are calculated. ;in To correct the propagation speed parameters, This is a predicted value for real-time propagation speed. The transmit-receive time difference at the calibration point; If the measurement error at all calibration points does not exceed the preset threshold, the adaptation is complete; if there are calibration points with measurement errors exceeding the threshold, calculate the correlation between the environmental characteristic deviation and the measurement error for these calibration points, and adjust accordingly. The calculation relationship is then cross-validated under at least three typical interference environments until the measurement accuracy meets the requirements under all environments.
[0014] As a second aspect of the present invention, an ultrasonic sensor environmental compensation system based on multimodal feature fusion is also provided, comprising: The multimodal feature synchronous acquisition unit is used to activate the target ultrasonic sensor and acquire ultrasonic signal features through the sensor's ultrasonic detection unit; at the same time, through the environmental perception module integrated with the sensor, it synchronously acquires multi-dimensional environmental features of the sensor's working environment; all acquired features are stored after being aligned with preset timestamps. The feature dynamic weighted fusion unit is used to invoke the weight allocation mechanism, determine the environmental feature weight benchmark based on the current working parameters of the sensor, dynamically adjust the weight of each feature in combination with real-time environmental feature values, and fuse the weighted environmental features with ultrasonic signal features to generate a fused feature set. The correction parameter output unit is used to input the fused feature set into the pre-trained error compensation model; the model predicts the ultrasonic propagation characteristic offset through the fused feature set and outputs the propagation speed correction parameter adapted to the core measurement formula of the sensor. The dynamic update unit is used by the sensor to calculate the measured value after real-time compensation based on the correction parameters; it repeats the feature acquisition, fusion and correction parameter generation process according to a preset cycle to realize the dynamic update of multimodal feature acquisition, fusion and correction parameters, and complete continuous dynamic compensation; when the sensor triggers range calibration, it synchronously updates the initial reference parameters of the compensation model to adapt to the range adjustment scenario.
[0015] As a third aspect of the invention, a computer-readable storage medium is also provided, on which a computer program is stored, which is executed by a processor as described in any one of the claims: an ultrasonic sensor environmental compensation method based on multimodal feature fusion.
[0016] In summary, compared with the prior art, the above-described technical solutions conceived by this invention can achieve the following beneficial effects: 1. The ultrasonic sensor environmental compensation method based on multimodal feature fusion of the present invention simultaneously acquires two types of core features after the ultrasonic sensor is activated: ultrasonic signal features acquired by the ultrasonic detection unit and multi-dimensional environmental features acquired by the integrated environmental sensing module, and then stores them aligned according to a preset timestamp. This technical feature ensures that the acquired data simultaneously covers both core detection information and environmental interference information, solving the problem of single signal features not considering environmental impact, ensuring comprehensive data support for subsequent compensation analysis, avoiding compensation bias caused by missing environmental features, and laying a data foundation for improving compensation accuracy.
[0017] 2. The ultrasonic sensor environmental compensation method based on multimodal feature fusion of the present invention determines the environmental feature weight benchmark by invoking a weight allocation mechanism and combining it with the current operating parameters of the sensor. Then, the weights are dynamically adjusted based on real-time environmental feature values. Subsequently, the weighted environmental features are fused with ultrasonic signal features to generate a fused feature set. This technique achieves targeted integration of multi-source features. Through dynamic weight adjustment, the fused feature set highlights key influencing factors under the current operating conditions, solving the problem of insufficient adaptability of fixed-weight fusion. This makes the data input to the compensation model more effective and directly improves the model's ability to identify and adapt to environmental interference.
[0018] 3. The ultrasonic sensor environmental compensation method based on multimodal feature fusion of the present invention inputs the fused feature set into a pre-trained error compensation model to predict the offset of ultrasonic propagation characteristics and output propagation velocity correction parameters. The sensor then calculates the compensated measurement value based on the parameters, and dynamically updates the model's reference parameters at a preset period and synchronously during range calibration. This technology forms a complete compensation chain of "feature fusion - model inference - calibration execution - dynamic update," solving the problem that static compensation cannot adapt to real-time environmental changes and range adjustments, ensuring accurate measurement values are output under different operating conditions and ranges, and achieving a continuous and stable environmental compensation effect. Attached Figure Description
[0019] Figure 1 This is a flowchart of the ultrasonic sensor environmental compensation method based on multimodal feature fusion according to an embodiment of the present invention; Figure 2 This is a schematic diagram of an ultrasonic sensor according to an embodiment of the present invention; Figure 3 This is a schematic diagram of the system units in an embodiment of the present invention. Detailed Implementation
[0020] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention. Furthermore, the technical features involved in the various embodiments of this invention described below can be combined with each other as long as they do not conflict with each other.
[0021] Example 1 Please refer to Figure 1 This embodiment 1 provides an ultrasonic sensor environment compensation method based on multimodal feature fusion, including: S1. Activate the target ultrasonic sensor and collect ultrasonic signal characteristics through the sensor's ultrasonic detection unit; simultaneously, through the environmental perception module integrated with the sensor, collect multi-dimensional environmental characteristics of the sensor's working environment; all collected features are stored after being aligned with preset timestamps. S2. Invoke the weighting mechanism to determine the environmental feature weight benchmark based on the current working parameters of the sensor; dynamically adjust the weight of each feature in combination with real-time environmental feature values; fuse the weighted environmental features with ultrasonic signal features to generate a fused feature set; S3. Input the fused feature set into the pre-trained error compensation model; the model predicts the ultrasonic propagation characteristic offset through the fused feature set and outputs the propagation speed correction parameter that adapts to the core measurement formula of the sensor; S4. The sensor calculates the measured value after real-time compensation based on the correction parameters; the feature acquisition, fusion and correction parameter generation process is repeated according to the preset cycle to realize the dynamic update of multimodal feature acquisition, fusion and correction parameters, and complete continuous dynamic compensation; when the sensor triggers range calibration, the initial reference parameters of the compensation model are updated synchronously to adapt to the range adjustment scenario.
[0022] like Figure 2 The ultrasonic sensor shown is the hardware carrier of the environmental compensation method in this embodiment: its main body integrates an ultrasonic detection unit and an environmental sensing module (corresponding to the functional modules of the sensor main body in the figure), which can simultaneously complete the acquisition of ultrasonic signal characteristics and multi-dimensional environmental characteristics; the aviation plug, waterproof cable connector and other cable outlet methods shown in the figure provide hardware support for the stable transmission of the acquired feature data by the sensor in different scenarios. At the same time, the sensor's range adjustment function (adapted to hardware calibration operation) can also be used to synchronously update the compensation model reference parameters through the method of this embodiment, ultimately achieving accurate measurement in complex environments, which is the hardware foundation for the practical application of the method in this embodiment.
[0023] Therefore, this embodiment 1 will further elaborate on the above steps.
[0024] (1) Synchronous acquisition of multimodal features In practical applications such as industrial measurement and intelligent sensing, ultrasonic sensors often face comprehensive interference from multiple environmental factors, including temperature, humidity, and dust. These interferences directly alter the propagation speed, attenuation, and propagation path of ultrasonic waves, leading to distortion of the sensor's core measurement data and consequently affecting the final detection accuracy. To address this issue at its source, it is necessary to comprehensively capture the detection signal and environmental interference information at the initial stage of the compensation process, providing complete data support for subsequent accurate compensation.
[0025] Once the target ultrasonic sensor is activated, its built-in ultrasonic detection unit quickly enters working mode, focusing on acquiring ultrasonic signal characteristics directly related to distance detection. These signal characteristics are core indicators reflecting the ultrasonic propagation state, covering at least one of the following: the time difference between ultrasonic transmission and reception, the amplitude of the reflected signal, and the phase. The time difference is directly related to the calculation of propagation distance, the amplitude of the reflected signal reflects the attenuation of ultrasonic energy, and the phase helps to determine the stability of the propagation path. Together, these three provide key signal dimensions for the subsequent compensation model.
[0026] Simultaneously, an environmental sensing module deeply integrated with the sensor is activated. This module is equipped with at least two types of environmental parameter detection elements, which can selectively collect multi-dimensional environmental characteristics in the sensor's working environment to ensure comprehensive coverage of major interference factors. Through the coordinated work of different detection elements, it can accurately capture environmental parameter data such as temperature, humidity, and dust concentration that may affect the propagation characteristics of ultrasonic waves, avoiding the one-sidedness of compensation caused by monitoring a single environmental parameter.
[0027] To ensure the accuracy of subsequent feature fusion and compensation calculations, all acquired ultrasonic signal features and environmental features are strictly aligned according to preset timestamps. This ensures a one-to-one correspondence between signal data and environmental data at the same time point, eliminating the impact of timing deviations on the compensation logic. The aligned feature data will be stored uniformly to form a complete and time-consistent original dataset, providing a reliable data foundation for subsequent processes such as weight allocation, feature fusion, and compensation model inference.
[0028] (2) Feature dynamic weighted fusion In complex environments, different environmental factors interfere with the propagation of ultrasound to varying degrees, and the environmental conditions change in real time. If fixed-weight fusion features are used, it is difficult to accurately reflect the dynamic correlation between environmental interference and detection signals. Therefore, it is necessary to construct an effective dataset that can accurately characterize the correlation between core information and interference through scientific weight allocation and feature fusion.
[0029] When invoking the weight allocation mechanism, the current transducer frequency and measurement range of the sensor are used as core parameters to construct the association logic for the environmental feature weight benchmark. The specific process is as follows: using the current transducer frequency of the sensor... and measurement range As a core parameter, a weighted benchmark correlation is constructed, in which the transducer frequency is used. With ultrasonic wavelength satisfy , The ultrasonic propagation speed under standard conditions is taken as a constant value for ultrasonic propagation speed at standard atmospheric pressure and 25°C. This is the upper limit of the measurement range currently set for the sensor, i.e., the maximum distance that the sensor can detect; For each environmental feature to be collected, calculate the corresponding environmental impact factor. and will As a weighting benchmark for this environmental characteristic, The calculation satisfies , The environmental characteristic correlation coefficient was obtained through sensor calibration experiments. Specifically, the sensor was calibrated across its entire range under standard environmental conditions (25°C, 50%RH, dust-free), and the standard measurement values at each range point were recorded. Keeping other environmental conditions constant, only the target environmental characteristic value was changed, and the measurement error at the corresponding range point under each scenario was recorded. The ratio of the change in the single environmental characteristic to the change in the corresponding measurement error was used as the value of that environmental characteristic. value.
[0030] The value represents the degree to which the corresponding environmental characteristics affect the ultrasonic wave propagation characteristics under the current sensor operating state. The larger the value, the more significant the impact, providing a benchmark for subsequent dynamic adjustments based on real-time environmental characteristics; among which... and The correlation is directly related to the propagation characteristics of ultrasonic signal features in the ultrasonic signal feature acquisition step. It is directly adapted to the range calibration scenario in the measurement calibration and dynamic update steps, ensuring the correlation between the weight benchmark determination process and other steps of the method.
[0031] Furthermore, during the dynamic weight adjustment phase, based on the determined environmental impact factors, targeted adjustments are made in conjunction with real-time collected environmental characteristic values. The specific method for generating the fused feature set is as follows: First, normalization processing is performed on the ultrasonic signal characteristics and various environmental characteristics to eliminate dimensional differences between different feature dimensions. The normalization processing uses the formula... Implementation, in which These are the original values of the features to be processed. This represents the minimum value of this feature across all sensor operating scenarios. This represents the maximum value of this feature across all sensor operating scenarios. and We obtain data through statistical analysis of historical calibration data and full-condition test data of the sensors to ensure coverage of all possible working states of the sensors. Based on the established environmental characteristic weighting benchmark, i.e., environmental impact factors The incremental influence of environmental features is calculated by combining real-time collected environmental feature values. , ,in These are real-time collected values of environmental characteristics. This is the baseline value for this environmental characteristic under standard conditions (temperature). 25°C, humidity 50% RH, dust concentration (0 mg / m³); when At that time, take This is the correction amount for the impact of this environmental characteristic, when At that time, take ,in, The preset environmental deviation threshold was determined through sensor calibration experiments. Calculate the fusion coefficient of each environmental feature. , ,Will Corresponding normalized environmental characteristics Multiply, we get All environmental characteristics A weighted environmental feature vector is constructed; the normalized ultrasonic signal features are used as the core feature vector, and the core feature vector and the weighted environmental feature vector are concatenated sequentially in the order after being aligned with the timestamps to form the initial fused feature vector. Redundancy removal is performed on the initial fused feature vector, and the variance of each feature dimension in the initial fused feature vector is calculated. , ,in The number of samples for this feature dimension. For the first dimension Each sample value The sample mean for this dimension; variance removed. Feature dimensions, The pre-set variance threshold is determined based on feature discrimination tests under standard conditions, and the remaining feature dimensions constitute the final fused feature set.
[0032] (3) Correct parameter output The core measurement accuracy of ultrasonic sensors depends on the accuracy of ultrasonic wave propagation speed. However, environmental interference can cause the propagation speed to deviate from the standard value. Error correction cannot be achieved directly through feature fusion alone. It is necessary to use a pre-trained error compensation model to establish the correlation between features and propagation characteristic deviations, and then generate correction parameters that are adapted to the core measurement formula, thereby fundamentally offsetting the measurement deviations caused by environmental interference.
[0033] The error compensation model to be put into use needs to be fully trained. The training data includes full-range calibration data of the sensor under standard environment, as well as error samples under different interference environments, to ensure that the model can accurately learn the mapping law between different combinations of environmental features and the deviation of ultrasonic propagation characteristics, and provide a reliable foundation for subsequent real-time inference.
[0034] After inputting the fused feature set into the pre-trained error compensation model, the model first initializes the correction benchmark, which is determined based on the full-range calibration data of the sensor under standard conditions. The standard environment is set to 25°C, 50%RH, and dust-free conditions. Under this environment, the standard ultrasonic wave propagation speed corresponding to different detection distances is obtained, and the benchmark feature vector under the standard environment is recorded. The benchmark feature vector includes the normalized value of the ultrasonic wave transmission and reception time difference, the reflected signal amplitude, and the standard weight benchmark and corresponding normalized value of each environmental feature under the standard environment, forming a benchmark reference for subsequent comparisons.
[0035] The model inference phase uses the difference between the real-time fused feature vector and the baseline feature vector as the core input. First, the feature deviation vector between the two is calculated. Then, this deviation vector is standardized to eliminate the impact of differences in feature deviation ranges on model inference. The historical feature deviation vector mean and standard deviation required for standardization are obtained through statistical analysis of calibration samples from sensors under various environments, ensuring that the processing logic closely matches actual working conditions. The standardized feature deviation vector is then input into the model, which outputs the ultrasonic propagation velocity offset. This offset directly reflects the degree of deviation between the ultrasonic propagation velocity and the standard value under the current environment.
[0036] Specifically, the process of constructing the propagation velocity correction parameters for the core measurement formula of the adaptive sensor is as follows: The process of constructing the propagation velocity correction parameters is centered on the mapping relationship between the fusion feature set and the ultrasonic propagation velocity offset. First, the correction benchmark is initialized. Based on the full-range calibration data of the sensor under standard environment (25°C, 50%RH, dust-free), the standard ultrasonic propagation velocity corresponding to different detection distances is obtained. And record the baseline feature vector under standard conditions. ,in ; This is the normalized value of the time difference between ultrasonic wave transmission and reception under standard conditions. This is the normalized value of the reflected signal amplitude under standard conditions. As a standard weighting benchmark for temperature characteristics, This is the normalized value of temperature under standard environmental conditions. As a standard weighting benchmark for humidity characteristics, The value is the normalized value of humidity under standard conditions, and the remaining items correspond to the standard weight benchmark and normalized value of other environmental characteristics; Construct a propagation velocity offset prediction model to fuse feature vectors in real time. With reference eigenvectors The difference is used as the core input to calculate the feature deviation vector. and to Perform standardized processing: ;in It is the mean of the historical feature deviation vector. It is the standard deviation of the historical characteristic deviation vector, both of which are obtained through statistical analysis of multi-environment calibration samples of the sensor; Input a pre-trained prediction model and output the ultrasonic wave propagation velocity offset. ; Based on propagation speed offset Constructing correction parameters: First, calculate the predicted real-time propagation speed. Then, through comparative experiments in standard and multi-interference environments, correction coefficients were established. and The connection: ;in It is the standard deviation of the propagation speed under standard conditions. It is the standard deviation of the propagation speed prediction in real-time environment, and both are calculated from historical calibration data; To ensure the effectiveness of the correction parameters, the correction coefficients need to be adjusted. Perform validity verification: Substitute the sensor's core measurement formula to calculate the corrected detection distance. , The time difference between ultrasonic wave transmission and reception is collected in real time; comparison If the error from the standard distance value is less than a preset threshold, then The parameters are adjusted to determine the final propagation speed; if the error exceeds the threshold, the parameters are fine-tuned in reverse based on the error value. Standardized parameters, recalculated Until the requirements are met.
[0037] (4) Dynamic updates Real-time fluctuations in environmental conditions and adjustments to the sensor range can affect the adaptability of ultrasonic propagation characteristics and compensation models. Relying solely on single-time compensation cannot guarantee long-term measurement accuracy. Therefore, a dynamic update mechanism is needed to achieve continuous compensation, and the model baseline should be optimized synchronously for range adjustment scenarios to ensure the effectiveness of compensation under different operating conditions.
[0038] After the sensor acquires the propagation velocity correction parameters, these parameters are substituted into the core measurement formula. Combined with the real-time acquisition of the ultrasonic wave transmission and reception time difference, the real-time compensated measurement value is calculated. This value has already offset the deviation caused by the current environmental interference. To cope with dynamic changes in environmental conditions, the system repeats the complete process of feature acquisition, fusion, and correction parameter generation according to a preset cycle. By periodically updating multimodal feature data and correction parameters, continuous dynamic compensation is achieved, ensuring that the measurement accuracy always matches the current environmental conditions.
[0039] When a sensor triggers range calibration, it needs to simultaneously adapt to the new detection range. This process is centered on the dynamic coupling mapping of "range-feature-model". The process of adapting to the range adjustment scenario is as follows: The process of adapting to range adjustment scenarios is based on the dynamic coupling mapping of "range-feature-model". When the sensor triggers range calibration, the upper and lower limit parameters of the new range are first obtained. , and the nearest point during calibration. Far point Real-time detection data, combined with sensor transducer frequency Calculate the effective wavelength of ultrasound corresponding to the new range. ;in The speed of ultrasonic wave propagation under standard conditions. , The wavelength is dynamically corrected by comparing the range of the original range with that of the new range, which is the upper and lower limits of the original range, so that the wavelength is adapted to the detection range depth of the new range. This calculation logic is related to the wavelength-range correlation when the weight benchmark is determined. Based on the new range parameters, the influence correlation benchmark of environmental characteristics is reconstructed, and the influence benchmark value under the new range is calculated for each environmental characteristic. ;in The correlation coefficient for environmental characteristics is consistent with the calibration experimental data from the weighting benchmark determination process; [Additional information is needed]. The proportion of the near and far point calibration intervals in relation to the total range of the new measurement range is adjusted so that the environmental characteristics affecting the benchmark can be adapted to both the overall range of the new measurement range and the key areas of actual testing, thereby improving the targeting of environmental interference correction. Construct a reference feature matrix for the new measurement range. Under standard conditions, select at least 5 calibration points within the new range, including the near point, the far point, and 3 equally divided midpoints. Collect the ultrasonic signal characteristics (transmission-reception time difference) at each calibration point. Reflection amplitude ) and environmental characteristics (temperature) ,humidity (etc.), after normalization, a new range reference characteristic matrix is generated. Replace the original single-vector benchmark; To perform a new measurement range accuracy closed-loop verification, firstly, under standard conditions, real-time fused features of the new measurement range calibration points are obtained through feature acquisition and fusion processes. These features are then input into the updated compensation model to obtain correction parameters, and the compensated measurement values are calculated. ;in To correct the propagation speed parameters, This is a predicted value for real-time propagation speed. The transmit-receive time difference at the calibration point; If the measurement error at all calibration points does not exceed the preset threshold, the adaptation is complete; if there are calibration points with measurement errors exceeding the threshold, calculate the correlation between the environmental characteristic deviation and the measurement error for these calibration points, and adjust accordingly. The calculation relationship was then cross-validated under three typical interference environments: high temperature, high humidity, and high dust, until the measurement accuracy met the requirements under all environments.
[0040] The ultrasonic sensor environmental compensation method described in this embodiment has significant application value in the field of industrial automation. In industrial workshops, complex environments such as temperature fluctuations, dust accumulation, and humidity changes often lead to a decrease in the measurement accuracy of ultrasonic sensors, affecting the stability of key processes such as material positioning and assembly dimension detection on the production line. This method, by simultaneously acquiring multi-dimensional environmental characteristics and ultrasonic signal characteristics, dynamically generates appropriate propagation speed correction parameters, which can effectively counteract environmental interference and ensure that the sensor maintains high-precision measurement even under harsh conditions such as high temperature and high dust. This provides reliable technical support for accurate detection in intelligent manufacturing and helps improve the automation level of production lines and the efficiency of product quality control.
[0041] This embodiment also has broad application prospects in the fields of intelligent transportation and public sensing. Scenarios such as parking space detection in intelligent parking lots and near-range obstacle recognition in autonomous driving place stringent requirements on the environmental adaptability and measurement stability of ultrasonic sensors. Sudden changes in outdoor temperature and weather conditions such as rain and snow can easily interfere with sensor performance. The dynamic compensation mechanism and range adaptability of this method enable the sensor to accurately output data under different environments and detection ranges, ensuring the accuracy of parking space detection and the reliability of environmental perception in autonomous driving. Simultaneously, in public scenarios such as distance monitoring in smart homes and intrusion detection in security systems, its stable compensation effect can improve equipment operating accuracy, enhance user experience, and promote the widespread adoption of ultrasonic sensing technology in public sectors.
[0042] Example 2 Please refer to Figure 3 This embodiment 2 provides an ultrasonic sensor environmental compensation system based on multimodal feature fusion, comprising: The multimodal feature synchronous acquisition unit is used to activate the target ultrasonic sensor and acquire ultrasonic signal features through the sensor's ultrasonic detection unit; at the same time, through the environmental perception module integrated with the sensor, it synchronously acquires multi-dimensional environmental features of the sensor's working environment; all acquired features are stored after being aligned with preset timestamps. The feature dynamic weighted fusion unit is used to invoke the weight allocation mechanism, determine the environmental feature weight benchmark based on the current working parameters of the sensor, dynamically adjust the weight of each feature in combination with real-time environmental feature values, and fuse the weighted environmental features with ultrasonic signal features to generate a fused feature set. The correction parameter output unit is used to input the fused feature set into the pre-trained error compensation model; the model predicts the ultrasonic propagation characteristic offset through the fused feature set and outputs the propagation speed correction parameter adapted to the core measurement formula of the sensor. The dynamic update unit is used by the sensor to calculate the measured value after real-time compensation based on the correction parameters; it repeats the feature acquisition, fusion and correction parameter generation process according to a preset cycle to realize the dynamic update of multimodal feature acquisition, fusion and correction parameters, and complete continuous dynamic compensation; when the sensor triggers range calibration, it synchronously updates the initial reference parameters of the compensation model to adapt to the range adjustment scenario.
[0043] Example 3 This embodiment 3 also provides a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, it can implement any step of an ultrasonic sensor environmental compensation method based on multimodal feature fusion.
[0044] The computer-readable storage medium may include 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.
[0045] For a description of the computer-readable storage medium provided in this application, please refer to the above method embodiments; further details will not be repeated here.
[0046] Those skilled in the art will readily understand that the above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for environmental compensation of ultrasonic sensors based on multimodal feature fusion, characterized in that, include: S1. Activate the target ultrasonic sensor and collect ultrasonic signal characteristics through the sensor's ultrasonic detection unit; simultaneously, through the environmental perception module integrated with the sensor, collect multi-dimensional environmental characteristics of the sensor's working environment; all collected features are stored after being aligned with preset timestamps. S2. Invoke the weighting mechanism to determine the environmental feature weight benchmark based on the current working parameters of the sensor; dynamically adjust the weight of each feature in combination with real-time environmental feature values; fuse the weighted environmental features with ultrasonic signal features to generate a fused feature set; S3. Input the fused feature set into the pre-trained error compensation model; the model predicts the ultrasonic propagation characteristic offset through the fused feature set and outputs the propagation speed correction parameter that adapts to the core measurement formula of the sensor; S4. The sensor calculates the measured value after real-time compensation based on the correction parameters; the feature acquisition, fusion and correction parameter generation process is repeated according to the preset cycle to realize the dynamic update of multimodal feature acquisition, fusion and correction parameters, and complete continuous dynamic compensation; when the sensor triggers range calibration, the initial reference parameters of the compensation model are updated synchronously to adapt to the range adjustment scenario.
2. The ultrasonic sensor environmental compensation method based on multimodal feature fusion according to claim 1, characterized in that, The ultrasonic signal characteristics in S1 include at least one of the following: the time difference between ultrasonic transmission and reception, the amplitude of the reflected signal, and the phase.
3. The ultrasonic sensor environmental compensation method based on multimodal feature fusion according to claim 1, characterized in that, The environmental sensing module in S1 includes at least two types of environmental parameter detection elements.
4. The ultrasonic sensor environmental compensation method based on multimodal feature fusion according to claim 1, characterized in that, The process of determining the environmental feature weighting benchmark based on the current operating parameters of the sensor in S2 is as follows: Based on the current transducer frequency of the sensor and measurement range As a core parameter, a weighted benchmark correlation is constructed, in which the transducer frequency is used. With ultrasonic wavelength satisfy , The ultrasonic propagation speed under standard conditions is taken as the ultrasonic propagation speed constant under standard atmospheric pressure at 25°C. This is the upper limit of the measurement range currently set for the sensor, i.e., the maximum distance that the sensor can detect; For each environmental feature to be collected, calculate the corresponding environmental impact factor. and will As a weighting benchmark for this environmental characteristic, The calculation satisfies , The environmental characteristic correlation coefficient was obtained through sensor calibration experiments. The value represents the degree to which the corresponding environmental characteristics affect the ultrasonic wave propagation characteristics under the current sensor operating state. The larger the value, the more significant the impact.
5. The ultrasonic sensor environmental compensation method based on multimodal feature fusion according to claim 1, characterized in that, The method for generating the fused feature set in S2 is as follows: First, normalization processing is performed on the ultrasonic signal characteristics and various environmental characteristics to eliminate dimensional differences between different feature dimensions. The normalization processing uses the formula... Implementation, in which These are the original values of the features to be processed. This represents the minimum value of this feature across all sensor operating scenarios. This represents the maximum value of this feature across all sensor operating scenarios. and We obtain data through statistical analysis of historical calibration data and full-condition test data of the sensors to ensure coverage of all possible working states of the sensors. Based on the established environmental characteristic weighting benchmark, i.e., environmental impact factors The incremental influence of environmental features is calculated by combining real-time collected environmental feature values. , ,in These are real-time collected values of environmental characteristics. This is the baseline value for this environmental characteristic under standard conditions; when At that time, take This is the correction amount for the impact of this environmental characteristic, when At that time, take ,in, The preset environmental deviation threshold was determined through sensor calibration experiments. Calculate the fusion coefficient of each environmental feature. , ,Will Corresponding normalized environmental characteristics Multiply, we get All environmental characteristics A weighted environmental feature vector is constructed; the normalized ultrasonic signal features are used as the core feature vector, and the core feature vector and the weighted environmental feature vector are concatenated sequentially in the order after being aligned with the timestamps to form the initial fused feature vector. Redundancy removal is performed on the initial fused feature vector, and the variance of each feature dimension in the initial fused feature vector is calculated. , ,in The number of samples for this feature dimension. For the first dimension Each sample value The sample mean for this dimension; variance removed. Feature dimensions, The pre-set variance threshold is determined based on feature discrimination tests under standard conditions, and the remaining feature dimensions constitute the final fused feature set.
6. The ultrasonic sensor environmental compensation method based on multimodal feature fusion according to claim 1, characterized in that, The error compensation model in S3 is trained based on full-range calibration data and multiple environmental error samples under standard sensor conditions.
7. The ultrasonic sensor environmental compensation method based on multimodal feature fusion according to claim 1, characterized in that, The process of constructing the propagation velocity correction parameter in the core measurement formula of the adaptive sensor in S3 is as follows: The process of constructing the propagation velocity correction parameters is centered on the mapping relationship between the fusion feature set and the ultrasonic propagation velocity offset. First, the correction benchmark is initialized. Based on the full-range calibration data of the sensor under standard conditions, the standard ultrasonic propagation velocity corresponding to different detection distances is obtained. And record the baseline feature vector under standard conditions. ,in ; This is the normalized value of the time difference between ultrasonic wave transmission and reception under standard conditions. This is the normalized value of the reflected signal amplitude under standard conditions. As a standard weighting benchmark for temperature characteristics, This is the normalized value of temperature under standard environmental conditions. As a standard weighting benchmark for humidity characteristics, The value is the normalized value of humidity under standard conditions, and the remaining items correspond to the standard weight benchmark and normalized value of other environmental characteristics; Construct a propagation velocity offset prediction model to fuse feature vectors in real time. With reference eigenvectors The difference is used as the core input to calculate the feature deviation vector. and to Perform standardized processing: ;in It is the mean of the historical feature deviation vector. It is the standard deviation of the historical characteristic deviation vector, both of which are obtained through statistical analysis of multi-environment calibration samples of the sensor; Input a pre-trained prediction model and output the ultrasonic wave propagation velocity offset. ; Based on propagation speed offset Constructing correction parameters: First, calculate the predicted real-time propagation speed. Then, through comparative experiments in standard and multi-interference environments, correction coefficients were established. and Relationship: ;in It is the standard deviation of the propagation speed under standard conditions. It is the standard deviation of the propagation speed prediction in real-time environment, and both are calculated from historical calibration data; For correction coefficients Perform validity verification: Substitute the sensor's core measurement formula to calculate the corrected detection distance. , The time difference between ultrasonic wave transmission and reception is collected in real time; comparison If the error from the standard distance value is less than a preset threshold, then Adjust parameters for final propagation speed; If the error exceeds the threshold, fine-tune the adjustment based on the error value. Standardized parameters, recalculated Until the requirements are met.
8. The ultrasonic sensor environmental compensation method based on multimodal feature fusion according to claim 1, characterized in that, The process of adapting to the range adjustment scenario in S4 is as follows: The process of adapting to range adjustment scenarios is based on the dynamic coupling mapping of "range-feature-model". When the sensor triggers range calibration, the upper and lower limit parameters of the new range are first obtained. , and the nearest point during calibration. Far point Real-time detection data, combined with sensor transducer frequency Calculate the effective wavelength of ultrasound corresponding to the new range. ;in The speed of ultrasonic wave propagation under standard conditions. , These are the original upper and lower limits of the measurement range; Based on the new range parameters, the influence correlation benchmark of environmental characteristics is reconstructed, and the influence benchmark value under the new range is calculated for each environmental characteristic. ;in The correlation coefficient for environmental characteristics is consistent with the calibration experimental data from the weighting benchmark determination process; To construct a reference feature matrix for the new measurement range, under standard conditions, select at least five calibration points within the new range, including near point, far point, and three equally divided intermediate points. Collect the ultrasonic signal characteristics and environmental characteristics of each calibration point, and generate the reference feature matrix for the new range after normalization processing. Replace the original single-vector benchmark; To perform a new measurement range accuracy closed-loop verification, firstly, under standard conditions, real-time fused features of the new measurement range calibration points are obtained through feature acquisition and fusion processes. These features are then input into the updated compensation model to obtain correction parameters, and the compensated measurement values are calculated. ;in To correct the propagation speed parameters, This is a predicted value for real-time propagation speed. The transmit-receive time difference at the calibration point; If the measurement error at all calibration points does not exceed the preset threshold, the adaptation is complete; if there are calibration points with measurement errors exceeding the threshold, calculate the correlation between the environmental characteristic deviation and the measurement error for these calibration points, and adjust accordingly. The calculation relationship is then cross-validated under at least three typical interference environments until the measurement accuracy meets the requirements under all environments.
9. An environmental compensation system for an ultrasonic sensor based on multimodal feature fusion, characterized in that, include: The multimodal feature synchronous acquisition unit is used to activate the target ultrasonic sensor and acquire ultrasonic signal features through the sensor's ultrasonic detection unit; at the same time, through the environmental perception module integrated with the sensor, it synchronously acquires multi-dimensional environmental features of the sensor's working environment; all acquired features are stored after being aligned with preset timestamps. The feature dynamic weighted fusion unit is used to invoke the weight allocation mechanism, determine the environmental feature weight benchmark based on the current working parameters of the sensor, dynamically adjust the weight of each feature in combination with real-time environmental feature values, and fuse the weighted environmental features with ultrasonic signal features to generate a fused feature set. The correction parameter output unit is used to input the fused feature set into the pre-trained error compensation model; the model predicts the ultrasonic propagation characteristic offset through the fused feature set and outputs the propagation speed correction parameter adapted to the core measurement formula of the sensor. The dynamic update unit is used by the sensor to calculate the measured value after real-time compensation based on the correction parameters; it repeats the feature acquisition, fusion and correction parameter generation process according to a preset cycle to realize the dynamic update of multimodal feature acquisition, fusion and correction parameters, and complete continuous dynamic compensation; when the sensor triggers range calibration, it synchronously updates the initial reference parameters of the compensation model to adapt to the range adjustment scenario.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, The computer program is executed by a processor as described in any one of claims 1-8: an ultrasonic sensor environmental compensation method based on multimodal feature fusion.
Citation Information
Patent Citations
Vehicle environment sensing method and device, terminal and storage medium
CN118823716A
Environment detection method and system based on multi-modal data fusion and deep learning
CN120655996A
Gas ultrasonic transducer rapid matching method, device and equipment, and storage medium
CN121071503A
Power system fire precursor detection system
KR102847316B1