Real-time data processing method and system for ultrasonic flowmeter
By collecting and processing multi-dimensional parameters of ultrasonic flow meters, calculating interference factors and performing flow regime matching correction, the accuracy and stability problems of traditional flow meters under complex working conditions are solved, and high-precision real-time flow monitoring is realized.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- XIAN INT INSTR MEASURE & CONTROL EQUIP
- Filing Date
- 2026-05-08
- Publication Date
- 2026-06-02
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Traditional ultrasonic flow meters are unable to counteract the interference from fluctuations in environmental parameters, differences in pipeline installation conditions, and changes in fluid characteristics under complex operating conditions, resulting in insufficient flow measurement accuracy and stability, and failing to meet the requirements for high-precision real-time flow monitoring.
By acquiring the raw time difference signal of the ultrasonic sensor, as well as environmental, installation status, and pipeline fluid characteristic parameters, anomaly identification processing is performed, pipeline process and fluid characteristic interference factors are calculated, and combined with flow state matching processing and composite correction, the signal processing strategy is dynamically adjusted to achieve high-precision calculation of real-time flow value.
It significantly improves the measurement accuracy and stability of ultrasonic flow meters under complex working conditions, provides reliable real-time flow data support, and is suitable for industrial fluid transportation and energy metering.
Smart Images

Figure CN122130171A_ABST
Abstract
Description
Technical Field
[0001] This application relates to a real-time data processing method and system for ultrasonic flow meters, belonging to the field of ultrasonic flow meter data processing. Background Technology
[0002] Ultrasonic flow meters are widely used in industrial production, municipal water supply, and oil and gas transportation due to their advantages such as non-contact measurement, convenient installation, and wide applicability to various media. However, under actual working conditions, their measurement process is easily affected by multiple factors such as fluctuations in environmental parameters, differences in pipeline installation status, changes in fluid characteristics, and abnormal interference in the original acquired signals. This results in deviations in the acquired time difference signals. Traditional data processing methods often use fixed corrections, which are difficult to dynamically adjust according to real-time working conditions. They cannot effectively offset the interference caused by pipeline process conditions and fluid characteristics, thus leading to reduced accuracy and insufficient stability of the flow measurement results, making it difficult to meet the actual needs of high-precision real-time flow monitoring. Summary of the Invention
[0003] According to one aspect of this application, a real-time data processing method for an ultrasonic flow meter is provided, which meets the practical needs of high-precision real-time flow monitoring.
[0004] Real-time data processing methods for ultrasonic flow meters include: The system acquires raw time-difference signal sequences and corresponding descriptive fields from ultrasonic sensors, and simultaneously obtains environmental parameters, installation status parameters, and pipeline fluid characteristic parameters. The original time difference signal sequence is subjected to anomaly identification processing to obtain a purified time difference signal sequence; Based on the installation status parameters and pipeline fluid characteristic parameters, the measurement deviation reference coefficient is determined; Specifically, based on the length of the preceding and following straight pipe sections, the pipe cross-sectional diameter, and the distance to the flow disturbance source in the installation status parameters, the pipeline process influence factor is calculated, and based on the pipeline fluid characteristic parameters, the fluid characteristic interference factor is calculated. Based on the weighted combination of the pipeline process influence factor and the fluid characteristic interference factor, the measurement deviation benchmark coefficient is generated. Adaptive flow-state matching processing is performed on the purified time difference signal sequence to obtain the first signal data; Based on the first signal data, environmental parameters, measurement deviation reference coefficient, and pipeline fluid characteristic parameters, a composite correction is performed to calculate the real-time flow value. Output the real-time traffic value and related processing status information.
[0005] Furthermore, a mapping relationship between the description field and the standard reference data is established, and the judgment threshold of the mapping relationship is dynamically adjusted based on the current installation status parameters and pipeline fluid characteristic parameters. Based on the adjusted mapping relationship, target data segments with abnormal description fields in the original time difference signal sequence are identified, the target data segments are deleted, and the remaining data segments are smoothly spliced to generate the purified time difference signal sequence.
[0006] Furthermore, adaptive flow regime matching processing is performed on the purified time difference signal sequence, including: Extract multidimensional feature parameters from the purified time difference signal sequence, the multidimensional feature parameters including time domain features and frequency domain features; The multidimensional feature parameters are input into a pre-trained flow pattern recognition model to identify the current flow pattern of the fluid. The flow pattern includes steady state, pulsating flow and turbulent flow. The flow pattern recognition model is a classification model based on random forest. Based on the identified flow pattern, a corresponding processing strategy is selected from multiple preset signal processing strategies to process the purified time difference signal sequence and obtain the first signal data. Among them, the processing strategies corresponding to different flow patterns have at least different filtering parameters.
[0007] Furthermore, based on the identified flow pattern, a corresponding processing strategy is selected from multiple preset signal processing strategies, including: The preset signal processing strategies include a first processing strategy, a second processing strategy, and a third processing strategy corresponding to steady state, pulsating flow, and turbulent flow, respectively. The second processing strategy uses a higher filtering cutoff frequency than the first processing strategy. The third processing strategy, in addition to filtering, also incorporates a multipath propagation error compensation algorithm. The multipath propagation error compensation algorithm constructs a compensation relationship based on the mapping relationship between the propagation path length difference of the ultrasonic signal and the phase difference of the received signal; At the same time, different threshold fluctuation ranges are selected according to the currently identified flow pattern. The threshold fluctuation range set for turbulent flow mode is greater than that set for steady-state mode, and secondary verification logic for the description field is triggered in turbulent flow mode.
[0008] Furthermore, the training process of the flow state recognition model includes: Collect ultrasonic time difference signal samples under different flow patterns and operating conditions, and construct a labeled sample dataset; Extract the multidimensional feature parameters from the sample dataset; Using the multidimensional feature parameters and corresponding flow labels, a random forest classification model is trained, and the model parameters are optimized through a validation set until the model classification accuracy reaches a preset standard.
[0009] Furthermore, the pipeline process influencing factors The calculations include: Based on the actual length of the upstream straight pipe section and actual straight pipe section length Corresponding straight pipe section length before benchmark and the length of the straight pipe section after the benchmark The degree of deviation, and the distance from the source of the flow disturbance. Conduct a comprehensive evaluation; Wherein, the length of the straight pipe section before the reference is and the length of the straight pipe section after the benchmark Based on pipe cross-sectional diameter And dynamically determine whether there are upstream flow disturbance sources; The reference straight pipe section length The method for determining it is as follows: When there is no upstream flow disturbance source ; When there is a source of flow disturbance upstream ; in, To set a constant; This is the first set constant; This is the second set constant; The diameter of the pipe cross-section; The distance between the flow disturbance source and the flow meter; The reference straight pipe section length , This is the third set of constants.
[0010] Furthermore, fluid property interference factor Based on the fluid characteristic parameters of the pipeline, it is used to characterize the degree of interference of fluid characteristics on the propagation of ultrasonic signals; ; in, This refers to the amount of bubble segregation per unit. This refers to the amount of segregation per unit solid particle; This is a preset reference bubble segregation amount; For reference solid particle segregation amount; exp() represents an exponential function with the natural constant e as the base.
[0011] Furthermore, a composite correction is performed based on the first signal data, environmental parameters, measurement deviation reference coefficient, and pipeline fluid characteristic parameters, including: Based on the time difference signal value in the first signal data Combined with flow coefficient Calculate the initial flow rate. ; Based on the medium temperature in environmental parameters Environmental pressure For the initial flow value Perform temperature and pressure correction to obtain the corrected flow rate value. ; in, This is the temperature correction factor. This is the pressure correction factor. Standard temperature Standard pressure; If the pipeline vibration amplitude in the environmental parameters Exceeding the preset vibration threshold Then for By superimposing vibration correction, the vibration-corrected flow rate value is obtained. ; in, This is the vibration correction factor. The reference vibration amplitude; Based on the measurement deviation benchmark coefficient ,right Perform final compensation to obtain real-time traffic values. .
[0012] Furthermore, it also includes intelligent sampling frequency control based on load and flow state coordination and multi-level fault-tolerant processing; The intelligent sampling frequency control based on load and flow state coordination includes: The real-time monitoring system processes load, signal change rate, flow stability, pipeline process influence factors, and fluid characteristic interference factors. A sampling frequency adjustment decision matrix is constructed based on the monitoring results; The signal sampling frequency of the ultrasonic sensor is dynamically adjusted according to the decision matrix. The multi-level fault-tolerant processing includes: The overall quality score of the purified time difference signal sequence is evaluated based on data integrity, signal quality, and environmental interference. Based on the different levels of the comprehensive quality score, the corresponding level of fault tolerance mechanism is activated, which includes data compensation, sensor switching, or predictive data generation.
[0013] According to another aspect of this application, a real-time data processing system for an ultrasonic flow meter is also provided, comprising: The signal acquisition module is used to acquire raw time difference signal sequences, descriptive fields, environmental parameters, installation status parameters, and pipeline fluid characteristic parameters. An anomaly detection module is used to process the original time difference signal sequence to obtain a purified time difference signal sequence; The deviation analysis module is used to determine the measurement deviation reference coefficient based on the installation status parameters and pipeline fluid characteristic parameters; An adaptive processing module is used to perform adaptive flow state matching processing on the purified time difference signal sequence to obtain the first signal data; The flow correction module is used to calculate and correct the real-time flow value based on the first signal data, environmental parameters, measurement deviation reference coefficient and pipeline fluid characteristic parameters; The output module is used to output the real-time traffic value and related information.
[0014] Furthermore, it also includes: The model training module is used to train the flow recognition model; The parameter optimization module is used to dynamically optimize filtering parameters, sampling frequency adjustment coefficients, flow correction coefficients, description field mapping thresholds, weighting coefficients of measurement deviation benchmark coefficients, and fault tolerance compensation parameters based on real-time processing results.
[0015] The beneficial effects that this application can produce include: The ultrasonic flow meter real-time data processing method and system provided in this application synchronously collects the original time-difference signal sequence along with multi-dimensional parameters such as environment, installation status, and pipeline fluid characteristics. First, it performs anomaly identification processing on the original signal to effectively filter out interference signals and obtain an accurate purified time-difference signal sequence. Then, it combines the upstream and downstream straight pipe lengths, pipe cross-sectional diameter, distance to flow disturbance sources, and pipeline fluid characteristic parameters from the installation status parameters to calculate the pipeline process influence factor and fluid characteristic interference factor, and performs weighted combination to generate a measurement deviation benchmark coefficient. Simultaneously, it performs adaptive flow matching processing on the purified signal. Finally, it calculates the real-time flow value based on composite correction using multiple parameters. This not only effectively offsets the interference of environmental changes, installation condition differences, and fluid characteristic fluctuations on the measurement results, significantly improving the measurement accuracy and stability of the ultrasonic flow meter under complex operating conditions, but also enables full monitoring of the measurement process by outputting processing status information, facilitating timely fault diagnosis and providing reliable and accurate real-time flow data support for industrial fluid transportation, energy metering, and other fields. Attached Figure Description
[0016] Figure 1 This is a flowchart of a real-time data processing method for an ultrasonic flow meter in one embodiment of this application; Figure 2 This is a block diagram of a real-time data processing system for an ultrasonic flow meter according to one embodiment of this application. Detailed Implementation
[0017] The present application is described in detail below with reference to the embodiments, but the present application is not limited to these embodiments.
[0018] See Figure 1-2 ,like Figure 1 As shown, the real-time data processing method for ultrasonic flow meters includes: The system acquires raw time-difference signal sequences and corresponding descriptive fields from ultrasonic sensors, and simultaneously obtains environmental parameters, installation status parameters, and pipeline fluid characteristic parameters. The original time difference signal sequence is subjected to anomaly identification processing to obtain a purified time difference signal sequence; Based on the installation status parameters and pipeline fluid characteristic parameters, the measurement deviation reference coefficient is determined; Specifically, based on the length of the preceding and following straight pipe sections, the pipe cross-sectional diameter, and the distance to the flow disturbance source in the installation status parameters, the pipeline process influence factor is calculated, and based on the pipeline fluid characteristic parameters, the fluid characteristic interference factor is calculated. Based on the weighted combination of the pipeline process influence factor and the fluid characteristic interference factor, the measurement deviation benchmark coefficient is generated. Adaptive flow-state matching processing is performed on the purified time difference signal sequence to obtain the first signal data; Based on the first signal data, environmental parameters, measurement deviation reference coefficient, and pipeline fluid characteristic parameters, a composite correction is performed to calculate the real-time flow value. Output the real-time traffic value and related processing status information.
[0019] Anomaly identification processing is performed on the original time difference signal sequence, including: A mapping relationship between the description field and the standard reference data is established, and the judgment threshold of the mapping relationship is dynamically adjusted based on the current installation status parameters and pipeline fluid characteristic parameters. Based on the adjusted mapping relationship, the target data segment with abnormal description field in the original time difference signal sequence is identified, the target data segment is deleted, and the remaining data segments are smoothly spliced to generate the purified time difference signal sequence.
[0020] Specifically, the original time difference signal sequence is acquired by using the signal propagation time difference between the transmitter and receiver of the ultrasonic sensor. The signal sequence must contain continuous timestamps and corresponding time difference values to ensure the temporal integrity of the data. The description field is used to characterize the acquisition status of the original time difference signal, including key information such as signal strength, signal-to-noise ratio, acquisition channel number, sensor operating voltage, and signal transmission error rate. Each original time difference data point must correspond to a unique set of description fields to achieve traceability of signal quality. Environmental parameters cover medium temperature, environmental pressure, pipeline vibration amplitude, and environmental humidity, which are synchronously acquired by a dedicated sensor integrated on the flow meter body or pipeline. The acquisition period is consistent with the original time difference signal sequence. Installation status parameters include key installation parameters such as the actual length of the upstream and downstream straight pipe sections, pipeline cross-sectional diameter, distance of the flow disturbance source, sensor installation angle, and sensor-to-pipe inner wall fit. These can be acquired through manual input in advance or automatically acquired by a dedicated installation detection module. Pipeline fluid characteristic parameters include fluid type, unit bubble segregation, unit solid particle segregation, fluid viscosity, and fluid density, which are entered through a fluid characteristic detection module or based on preset operating conditions.
[0021] Furthermore, for each descriptive field, corresponding standard value ranges are established as standard reference data based on industry standards, sensor technical manuals, and a large amount of experimental data. For example, the standard reference range for signal strength is set to 50dB-80dB, and the standard reference range for signal-to-noise ratio is set to 30dB-60dB, forming a key-value pair mapping table. Based on the degree of deviation of the upstream and downstream straight pipe lengths from the baseline value in the current installation status parameters, the distance to the flow disturbance source, and the fluid viscosity and density in the pipe fluid characteristic parameters, the judgment thresholds for each descriptive field are dynamically adjusted through a preset weighting formula. For example, when the flow disturbance source is close, the signal-to-noise ratio (SNR) threshold is adjusted downward to improve the sensitivity of identifying weak signal anomalies; when the fluid viscosity is high, the signal transmission error rate (BER) threshold is adjusted upward to adapt to the signal transmission characteristics under high-viscosity fluids; the original time difference signal sequence is traversed, and the description field corresponding to each data point is compared with the adjusted mapping relationship. If any description field of a data point exceeds the corresponding threshold, the continuous data segment containing that data point is determined to be the target abnormal data segment. After deleting all target abnormal data segments, linear interpolation or moving average methods are used to smoothly splice the breakpoints of the remaining data segments to ensure the continuity and smoothness of the purified time difference signal sequence.
[0022] Taking into account the impact of deviations in the length of preceding and following straight pipe sections, pipe cross-sectional diameter, and distance to the flow disturbance source on the measurement, a weighted summation method is used to calculate the pipeline process influence factor. The weighting coefficients are determined based on extensive simulation experiments and field test data. Specifically, the weighting of deviations in the length of preceding and following straight pipe sections is 40%, the weighting of the pipe cross-sectional diameter is 30%, and the weighting of the distance to the flow disturbance source is 30%, ensuring that the factor accurately reflects the contribution of pipeline installation technology to measurement deviation. The fluid characteristic interference factor is calculated based on pipeline fluid characteristic parameters such as unit bubble segregation and unit solid particle segregation, quantifying the degree of interference of fluid characteristics on ultrasonic signal propagation. The weights of the pipeline process influence factor and the fluid characteristic interference factor are set according to the priority of the actual application scenario, and a weighted summation formula is used to generate the measurement deviation benchmark coefficient; a larger coefficient indicates a larger measurement deviation.
[0023] The purified time-difference signal sequence is subjected to adaptive flow-state matching processing to obtain first signal data. Based on the first signal data, environmental parameters, measurement deviation reference coefficient, and pipeline fluid characteristic parameters, composite correction is performed to calculate the real-time flow value. The real-time flow value and related processing status information are output. The processing status information includes signal acquisition status, anomaly identification results, flow pattern identification results, correction execution status, sensor working status, etc. The output is in binary encoding or text format and supports multiple output methods such as 4-20mA current signal and RS485 digital signal.
[0024] Adaptive flow-state matching processing is performed on the purified time difference signal sequence, including: Extract multidimensional feature parameters from the purified time difference signal sequence, the multidimensional feature parameters including time domain features and frequency domain features; The multidimensional feature parameters are input into a pre-trained flow pattern recognition model to identify the current flow pattern of the fluid. The flow pattern includes steady state, pulsating flow and turbulent flow. The flow pattern recognition model is a classification model based on random forest. Based on the identified flow pattern, a corresponding processing strategy is selected from multiple preset signal processing strategies to process the purified time difference signal sequence and obtain the first signal data. Among them, the processing strategies corresponding to different flow patterns have at least different filtering parameters.
[0025] Specifically, multidimensional feature parameters of the purified time difference signal sequence are extracted. These multidimensional feature parameters include time-domain features and frequency-domain features. The time-domain features include the signal's mean, variance, peak value, kurtosis, skewness, rise time, and fall time. The mean reflects the overall signal level, the variance characterizes the degree of dispersion, the peak value reflects the fluid impact intensity, the kurtosis describes the sharpness of the peak value, the skewness characterizes the asymmetry of the distribution, and the rise and fall times reflect the signal's rate of change. The frequency-domain features include the signal's dominant frequency, spectral amplitude, spectral bandwidth, and harmonic component proportion. The dominant frequency is the frequency component with the largest amplitude in the spectrum, the spectral amplitude reflects the signal energy intensity, the spectral bandwidth amplitude is greater than the dominant frequency amplitude, and the harmonic component proportion is the ratio of the sum of the amplitudes of each harmonic to the dominant frequency amplitude. After extraction, the feature parameters are normalized within the range of [0,1] to eliminate the influence of dimensional differences.
[0026] The multidimensional feature parameters are input into a pre-trained flow pattern recognition model to identify the current fluid flow pattern, which includes steady-state, pulsating flow, and turbulent flow. The flow pattern recognition model is a random forest-based classification model containing 50-100 decision trees. Ensemble learning is used to improve overfitting resistance and robustness. The model input is a 15-20 dimensional normalized feature parameter vector, and the output is a flow pattern label, where steady-state is 0, pulsating flow is 1, and turbulent flow is 2. Based on the identified flow pattern, a corresponding processing strategy is selected from multiple preset signal processing strategies to process the purified time difference signal sequence to obtain the first signal data. The processing strategies corresponding to different flow patterns have at least different filtering parameters, including filter cutoff frequency, filter order, etc., implemented using digital filters to ensure targeted noise reduction and feature preservation.
[0027] Based on the identified flow pattern, a corresponding processing strategy is selected from multiple preset signal processing strategies, including: The preset signal processing strategies include a first processing strategy, a second processing strategy, and a third processing strategy corresponding to steady state, pulsating flow, and turbulent flow, respectively. The second processing strategy uses a higher filtering cutoff frequency than the first processing strategy. The third processing strategy, in addition to filtering, also incorporates a multipath propagation error compensation algorithm. The multipath propagation error compensation algorithm constructs a compensation relationship based on the mapping relationship between the propagation path length difference of the ultrasonic signal and the phase difference of the received signal; At the same time, different threshold fluctuation ranges are selected according to the currently identified flow pattern. The threshold fluctuation range set for turbulent flow mode is greater than that set for steady-state mode, and secondary verification logic for the description field is triggered in turbulent flow mode.
[0028] Specifically, the preset signal processing strategies include a first processing strategy, a second processing strategy, and a third processing strategy corresponding to steady state, pulsating flow, and turbulent flow, respectively. The second processing strategy uses a higher filter cutoff frequency than the first processing strategy. The first processing strategy, i.e., steady state, uses a 4th-order low-pass filter with a cutoff frequency of 10Hz to suppress random noise. The second processing strategy, i.e., pulsating flow, uses a 6th-order low-pass filter with a cutoff frequency of 20Hz to preserve the periodic characteristics of the pulsating flow and avoid signal phase distortion. The third processing strategy, i.e., turbulent flow, combines filtering with a multipath propagation error compensation algorithm, using an 8th-order low-pass filter with a cutoff frequency of 15Hz, and an adaptive noise suppression algorithm to filter out broadband noise.
[0029] The multipath propagation error compensation algorithm is based on the linear mapping relationship between the propagation path length difference of ultrasonic signals and the phase difference of received signals to construct a compensation relationship. The model expression is that the correction amount is equal to the proportional coefficient multiplied by the phase difference plus the offset. The proportional coefficient and the offset are obtained by fitting experimental data, and parameter calibration tables are established for different pipe diameters and fluid types.
[0030] Simultaneously, different threshold fluctuation ranges are selected based on the currently identified flow pattern. The threshold fluctuation range set for turbulent flow mode is larger than that set for steady-state mode. The threshold fluctuation range for steady-state mode is ±5%, for turbulent flow mode it is ±15%, and for pulsating flow mode it is ±10%. Furthermore, in turbulent flow mode, a secondary verification logic for the description field is triggered. For abnormal data segments identified in the first instance, their description fields are re-compared with the expanded threshold range, and a comprehensive judgment is made based on the signal characteristics of adjacent data segments. The secondary verification improves the accuracy of abnormal data identification. During the secondary verification, the signal characteristics and description fields of the five adjacent data segments are combined. If none of the adjacent data segments of the abnormal data segment are abnormal, it is determined to be a misidentification, and the data segment is restored; otherwise, the deletion result is retained.
[0031] The training process of the flow state recognition model includes: Collect ultrasonic time difference signal samples under different flow patterns and operating conditions, and construct a labeled sample dataset; Extract the multidimensional feature parameters from the sample dataset; Using the multidimensional feature parameters and corresponding flow labels, a random forest classification model is trained, and the model parameters are optimized through a validation set until the model classification accuracy reaches a preset standard.
[0032] Specifically, ultrasonic time difference signal samples under different flow patterns and operating conditions were collected. The operating conditions covered different pipe diameters, fluid types, flow velocities, and installation parameters. Each flow pattern sample accounted for no less than 30%, and the number of samples for each operating condition was ≥1000. High-precision ultrasonic sensors and standard flow calibration devices were used to collect the samples to ensure their accuracy. A sample dataset with flow pattern labels was constructed. The samples included the original time difference signal sequence, operating condition parameters, and a unique number.
[0033] The multidimensional feature parameters are extracted from the sample dataset. Time-domain and frequency-domain analysis methods are used to extract the parameters. After extraction, key features are screened through variance analysis and mutual information entropy. Redundant and strongly correlated features are eliminated, and finally the core feature parameters are retained.
[0034] Using the multidimensional feature parameters and corresponding fluid labels, a random forest classification model is trained. The number of decision trees and the maximum depth are initialized. The number of split features for each node is the square root of the total number of features. Bootstrap sampling and Gini coefficient node splitting are used for evaluation. The model's classification accuracy, precision, recall, and F1 score are evaluated using a validation set. The model parameters are adjusted using a grid search method until the model's classification accuracy, precision, recall, and F1 score on the test set meet the preset standards. After training, the model needs to be validated in the field before being solidified and deployed.
[0035] Pipeline process influencing factors The calculations include: Based on the actual length of the upstream straight pipe section and actual straight pipe section length Corresponding straight pipe section length before benchmark and the length of the straight pipe section after the benchmark The degree of deviation, and the distance from the source of the flow disturbance. Conduct a comprehensive evaluation; Wherein, the length of the straight pipe section before the reference is and the length of the straight pipe section after the benchmark Based on pipe cross-sectional diameter And dynamically determine whether there are upstream flow disturbance sources; The reference straight pipe section length The method for determining it is as follows: When there is no upstream flow disturbance source ; When there is a source of flow disturbance upstream ; in, To set a constant; This is the first set constant; This is the second set constant; The diameter of the pipe cross-section; This represents the distance between the flow disturbance source and the flow meter.
[0036] Specifically, first determine the length of the straight pipe section before and after the benchmark, then calculate the relative deviation between the actual length of the straight pipe section before and after the benchmark and the corresponding benchmark length. The relative deviation of the straight pipe section before / after the benchmark is the absolute value of the difference between the actual length and the benchmark length before / after the benchmark, divided by the benchmark length before / after the benchmark. Combined with the influence coefficient corresponding to the distance of the flow disturbance source, the influence coefficient is 1 divided by 1 plus the ratio of the distance of the flow disturbance source to the pipe cross-sectional diameter. The deviation weight of the straight pipe section before the benchmark is 0.4, the deviation weight of the straight pipe section after the benchmark is 0.3, and the influence coefficient of the disturbance source is 0.3. Through weighted summation, a comprehensive evaluation is performed to obtain the corresponding pipeline process influence factor. The larger the value, the more obvious the influence of the installation conditions on the measurement deviation.
[0037] The lengths of the straight pipe section before and after the benchmark are dynamically determined based on the pipe cross-sectional diameter and the presence of upstream flow disturbance sources. The length of the straight pipe section before the benchmark is determined as follows: when there are no flow disturbance sources such as valves, elbows, or pumps within 50 times the pipe cross-sectional diameter upstream, the length of the straight pipe section before the benchmark is equal to a set constant χ multiplied by the pipe cross-sectional diameter, where χ ranges from 10 to 20. When there are flow disturbance sources within 50 times the pipe cross-sectional diameter upstream, the length of the straight pipe section before the benchmark is equal to (the set constant χ1 plus the set constant χ2 multiplied by the distance between the flow disturbance source and the flow meter) multiplied by the pipe cross-sectional diameter, where χ1 ranges from 15 to 25 and χ2 ranges from 0.1 to 0.5. The units for the pipe cross-sectional diameter and the distance to the flow disturbance source remain consistent. The length of the straight pipe section after the benchmark is equal to a set constant y multiplied by the pipe cross-sectional diameter, where y ranges from 5 to 10 and is not affected by downstream flow disturbance sources.
[0038] The fluid property interference factor Based on the fluid characteristic parameters of the pipeline, it is used to characterize the degree of interference of fluid characteristics on the propagation of ultrasonic signals; ; in, This refers to the amount of bubble segregation per unit. This refers to the amount of segregation per unit solid particle; This is a preset reference bubble segregation amount; For reference solid particle segregation amount; exp() represents an exponential function with the natural constant e as the base.
[0039] Specifically, when calculating the fluid characteristic interference factor, the result is an exponential function with the natural constant e as the base and the sum of the unit bubble segregation amount divided by the preset reference bubble segregation amount and the unit solid particle segregation amount divided by the reference solid particle segregation amount as the exponent. It is worth noting that the unit bubble segregation amount is the volume percentage of bubbles in a unit volume of fluid, and the unit solid particle segregation amount is the mass percentage of solid particles in a unit volume of fluid. The reference bubble segregation amount and the reference solid particle segregation amount are preset content thresholds when there is no obvious interference, and the values range from 0.1% to 0.5%, which can be adjusted according to the fluid type and measurement accuracy. When the unit bubble segregation amount and the unit solid particle segregation amount are equal to the reference values, the interference factor is about 7.389, which represents no obvious interference. The larger the value, the stronger the interference.
[0040] A composite correction is performed based on the first signal data, environmental parameters, measurement deviation benchmark coefficient, and pipeline fluid characteristic parameters, including: Based on the time difference signal value in the first signal data Combined with flow coefficient Calculate the initial flow rate. ; Based on the medium temperature in environmental parameters Environmental pressure For the initial flow value Perform temperature and pressure correction to obtain the corrected flow rate value. ; in, This is the temperature correction factor. This is the pressure correction factor. Standard temperature Standard pressure; If the pipeline vibration amplitude in the environmental parameters Exceeding the preset vibration threshold Then for By superimposing vibration correction, the vibration-corrected flow rate value is obtained. ; in, This is the vibration correction factor. The reference vibration amplitude; Based on the measurement deviation benchmark coefficient ,right Perform final compensation to obtain real-time traffic values. .
[0041] Specifically, based on the time difference signal value in the first signal data and a preset flow coefficient, an initial flow value is calculated through multiplication. The flow coefficient is related to the pipe cross-sectional area, sensor installation angle, and fluid sound velocity. Data is collected at different flow rates using a standard flow calibration device, and linear regression fitting is used to determine the flow value. Based on the medium temperature and environmental pressure parameters, the initial flow value is corrected for temperature and pressure to adjust the flow value. The temperature correction factor and pressure correction factor are determined according to the fluid type; for example, the temperature correction factor for water is 0.0002℃. -1 Pressure correction factor: 0.00005 MPa -1 The gas pressure correction factor is 0.001 MPa. -1 It can be adjusted according to industry standards.
[0042] If the pipeline vibration amplitude in the environmental parameters exceeds the preset vibration threshold, then the vibration correction is added to the temperature and pressure corrected flow rate value, resulting in a vibration-corrected flow rate value. The vibration correction coefficient ranges from 0.1 to 0.5 and is obtained through experimental calibration. The default reference vibration amplitude is 1 mm.
[0043] Based on the aforementioned measurement deviation reference coefficient, the vibration-corrected flow rate value is finally compensated, and the real-time flow rate value is obtained. Ultimately, this enables high-precision flow measurement.
[0044] It also includes intelligent sampling frequency control based on load and flow state coordination and multi-level fault-tolerant processing; The intelligent sampling frequency control based on load and flow state coordination includes: The real-time monitoring system processes load, signal change rate, flow stability, pipeline process influence factors, and fluid characteristic interference factors. A sampling frequency adjustment decision matrix is constructed based on the monitoring results; The signal sampling frequency of the ultrasonic sensor is dynamically adjusted according to the decision matrix. The multi-level fault-tolerant processing includes: The overall quality score of the purified time difference signal sequence is evaluated based on data integrity, signal quality, and environmental interference. Based on the different levels of the comprehensive quality score, the corresponding level of fault tolerance mechanism is activated, which includes data compensation, sensor switching, or predictive data generation.
[0045] Specifically, in intelligent sampling frequency control based on load and flow pattern coordination, the system real-time monitoring includes the system processing load, signal change rate (i.e., the average absolute value of the difference between adjacent data points of the time difference signal after purification), flow pattern stability (i.e., the duration and fluctuation frequency of the flow pattern), pipeline process influence factors, and fluid characteristic interference factors. Based on the monitoring results, a three-dimensional decision matrix is constructed. The decision dimensions include system processing load, signal change rate, and flow pattern stability. The matrix presets sampling frequency levels corresponding to different combinations. The sampling frequency is divided into 5 levels. The rule is that when the load is low, the signal change rate is high, and the flow pattern stability is low, level 4-5 is used; when the load is high, the signal change rate is low, and the flow pattern stability is high, level 1-2 is used; and level 3 is used in other cases. According to the decision matrix, the signal sampling frequency of the ultrasonic sensor is dynamically adjusted every 1 second. The adjustment process ensures data continuity without missing points or duplicate sampling.
[0046] Meanwhile, regarding multi-level fault tolerance processing, a comprehensive quality score for the purified time difference signal sequence is calculated based on data integrity, signal quality, and the degree of environmental interference, weighted accordingly. Depending on the level of the comprehensive quality score, a corresponding level of fault tolerance processing mechanism is activated: Level 1 requires no additional processing; Level 2 activates a data compensation mechanism, using linear interpolation, moving average, or ARIMA models to fill in missing data, improving the integrity of the effective data after compensation; Level 3 activates a sensor switching mechanism, switching to a backup sensor and performing a self-check on the original sensor; if the backup sensor malfunctions, the level is downgraded; Level 4 activates a predictive data generation mechanism, generating predicted flow values based on historical data, operating condition trends, and neural network models, while simultaneously issuing an alarm signal.
[0047] like Figure 2 As shown, the ultrasonic flow meter real-time data processing system includes: The signal acquisition module is used to acquire raw time difference signal sequences, descriptive fields, environmental parameters, installation status parameters, and pipeline fluid characteristic parameters. An anomaly detection module is used to process the original time difference signal sequence to obtain a purified time difference signal sequence; The deviation analysis module is used to determine the measurement deviation reference coefficient based on the installation status parameters and pipeline fluid characteristic parameters; An adaptive processing module is used to perform adaptive flow state matching processing on the purified time difference signal sequence to obtain the first signal data; The flow correction module is used to calculate and correct the real-time flow value based on the first signal data, environmental parameters, measurement deviation reference coefficient and pipeline fluid characteristic parameters; The output module is used to output the real-time traffic value and related information.
[0048] Specifically, the signal acquisition module is used to acquire the original time difference signal sequence, descriptive fields, environmental parameters, installation status parameters, and pipeline fluid characteristic parameters. This module integrates an ultrasonic sensor unit, an environmental parameter sensor unit, an installation status acquisition unit, a fluid characteristic detection unit, and a data synchronization acquisition unit to achieve multi-parameter synchronous acquisition and supports dynamic configuration of acquisition parameters. The anomaly identification module is used to process the original time difference signal sequence, including a mapping relationship storage unit, a threshold adjustment unit, an anomaly identification unit, and a data splicing unit, and outputs the purified time difference signal sequence. The deviation analysis module is used to calculate the pipeline process influence factor based on the installation status parameters, calculate the fluid characteristic interference factor based on the pipeline fluid characteristic parameters, and then obtain the measurement deviation benchmark coefficient through weighted combination, supporting dynamic configuration of weight coefficients. The adaptive processing module is used to extract multi-dimensional feature parameters, identify flow patterns, and execute corresponding signal processing strategies for the purified time difference signal sequence, including a feature extraction unit, a flow pattern identification unit, a processing strategy invocation unit, and a signal processing unit, and outputs the first signal data. The flow correction module calculates the initial flow value based on the first signal data, performs temperature and pressure correction and vibration correction based on environmental parameters, and then performs final compensation using a measurement deviation reference coefficient. It includes an initial flow calculation unit, a temperature and pressure correction unit, a vibration correction unit, and a reference coefficient compensation unit, and supports dynamic configuration of the correction coefficient. The output module outputs the real-time flow value and related information, supporting 4-20mA current signal output, RS485 / Ethernet / HART digital signal output, LCD / LED local display, local storage, and USB export. It also features audible and visual alarms and digital alarm functions.
[0049] Also includes: The model training module is used to train the flow recognition model; The parameter optimization module is used to dynamically optimize filtering parameters, sampling frequency adjustment coefficients, flow correction coefficients, description field mapping thresholds, weighting coefficients of measurement deviation benchmark coefficients, and fault tolerance compensation parameters based on real-time processing results.
[0050] Specifically, the model training module is responsible for the offline training, validation, and updating of the flow recognition model, providing a high-performance flow recognition model for the adaptive processing module. It supports iterative optimization of the model and can be deployed on local or cloud servers, configured with high-performance CPUs, GPUs, and large-capacity storage devices. It supports the storage and processing of massive amounts of sample data, including importing, exporting, labeling, classifying, and storing sample data, and is compatible with multiple data formats. The feature extraction unit of the adaptive processing module uses the same algorithm to ensure consistency between training and application, and supports batch feature extraction. The model training unit trains a random forest classification model, supports configuration of parameters such as the number of decision trees and maximum depth, and supports parallel training to improve efficiency. The model validation and evaluation unit uses validation and test sets to evaluate the performance of the trained model, outputting metrics such as classification accuracy, precision, recall, and F1 score, and supports visualization of model performance. The model export unit exports the trained and optimized model in a format suitable for the flow meter embedded system, such as .bin or .model, and supports model encryption and signing to ensure model security and integrity. The parameter optimization module optimizes the model based on the system's real-time processing... The system's performance and operational status are dynamically optimized to achieve adaptive performance improvement and ensure long-term stability of measurement accuracy. Optimized parameter types include filter cutoff frequencies and filter orders corresponding to different flow patterns; sampling frequency adjustment coefficients include thresholds in the decision matrix and specific frequency values corresponding to sampling frequency levels; flow correction coefficients include temperature correction coefficient α, pressure correction coefficient β, and vibration correction coefficient γ; description field mapping thresholds include initial thresholds and dynamic adjustment coefficients for each description field; the weighting coefficients of the measurement deviation benchmark coefficient include weighting coefficients of pipeline process influence factors and fluid characteristic interference factors; and fault tolerance compensation parameters include the weight of the comprehensive quality score, trigger thresholds for each level of fault tolerance processing, and parameters of the data compensation algorithm.
[0051] Furthermore, system performance evaluation indicators are set, including flow measurement accuracy, signal-to-noise ratio after signal processing, system processing latency, and data integrity. When the performance evaluation indicators are continuously lower than the preset threshold, or the system running time reaches the preset cycle, the parameter optimization process is automatically triggered. Intelligent optimization algorithms such as gradient descent and genetic algorithms are used to iteratively optimize key parameters based on historical running data and performance evaluation results to find the optimal parameter combination. The optimized parameters are first run in verification mode to verify whether the performance indicators meet the requirements. If they do, the system parameters are officially updated; if they do not, the original parameters are rolled back and the optimization process is restarted.
[0052] The above description is merely a few embodiments of this application and is not intended to limit this application in any way. Although this application discloses preferred embodiments as described above, it is not intended to limit this application. Any changes or modifications made by those skilled in the art without departing from the scope of the technical solution of this application using the disclosed technical content are equivalent to equivalent implementation cases and fall within the scope of the technical solution.
Claims
1. A real-time data processing method for ultrasonic flow meters, characterized in that, include: The system acquires raw time-difference signal sequences and corresponding descriptive fields from ultrasonic sensors, and simultaneously obtains environmental parameters, installation status parameters, and pipeline fluid characteristic parameters. The original time difference signal sequence is subjected to anomaly identification processing to obtain a purified time difference signal sequence; Based on the installation status parameters and pipeline fluid characteristic parameters, the measurement deviation reference coefficient is determined; Specifically, based on the length of the preceding and following straight pipe sections, the pipe cross-sectional diameter, and the distance to the flow disturbance source in the installation status parameters, the pipeline process influence factor is calculated, and based on the pipeline fluid characteristic parameters, the fluid characteristic interference factor is calculated. Based on the weighted combination of the pipeline process influence factor and the fluid characteristic interference factor, the measurement deviation benchmark coefficient is generated. Adaptive flow-state matching processing is performed on the purified time difference signal sequence to obtain the first signal data; Based on the first signal data, environmental parameters, measurement deviation reference coefficient, and pipeline fluid characteristic parameters, a composite correction is performed to calculate the real-time flow value. Output the real-time traffic value and related processing status information.
2. The real-time data processing method for an ultrasonic flow meter according to claim 1, characterized in that, Anomaly identification processing is performed on the original time difference signal sequence, including: A mapping relationship between the description field and the standard reference data is established, and the judgment threshold of the mapping relationship is dynamically adjusted based on the current installation status parameters and pipeline fluid characteristic parameters. Based on the adjusted mapping relationship, the target data segment with abnormal description field in the original time difference signal sequence is identified, the target data segment is deleted, and the remaining data segments are smoothly spliced to generate the purified time difference signal sequence.
3. The real-time data processing method for ultrasonic flowmeters according to claim 2, characterized in that, Adaptive flow-state matching processing is performed on the purified time difference signal sequence, including: Extract multidimensional feature parameters from the purified time difference signal sequence, the multidimensional feature parameters including time domain features and frequency domain features; The multidimensional feature parameters are input into a pre-trained flow pattern recognition model to identify the current flow pattern of the fluid. The flow pattern includes steady state, pulsating flow and turbulent flow. The flow pattern recognition model is a classification model based on random forest. Based on the identified flow pattern, a corresponding processing strategy is selected from multiple preset signal processing strategies to process the purified time difference signal sequence and obtain the first signal data. Among them, the processing strategies corresponding to different flow patterns have at least different filtering parameters.
4. The real-time data processing method for an ultrasonic flow meter according to claim 3, characterized in that, Based on the identified flow pattern, a corresponding processing strategy is selected from multiple preset signal processing strategies, including: The preset signal processing strategies include a first processing strategy, a second processing strategy, and a third processing strategy corresponding to steady state, pulsating flow, and turbulent flow, respectively. The second processing strategy uses a higher filtering cutoff frequency than the first processing strategy. The third processing strategy, in addition to filtering, also incorporates a multipath propagation error compensation algorithm. The multipath propagation error compensation algorithm constructs a compensation relationship based on the mapping relationship between the propagation path length difference of the ultrasonic signal and the phase difference of the received signal; At the same time, different threshold fluctuation ranges are selected according to the currently identified flow pattern. The threshold fluctuation range set for turbulent flow mode is greater than that set for steady-state mode, and secondary verification logic for the description field is triggered in turbulent flow mode.
5. The real-time data processing method for an ultrasonic flow meter according to claim 3, characterized in that, The training process of the flow state recognition model includes: Collect ultrasonic time difference signal samples under different flow patterns and operating conditions, and construct a labeled sample dataset; Extract the multidimensional feature parameters from the sample dataset; Using the multidimensional feature parameters and corresponding flow labels, a random forest classification model is trained, and the model parameters are optimized through a validation set until the model classification accuracy reaches a preset standard.
6. The real-time data processing method for an ultrasonic flow meter according to claim 1, characterized in that, Pipeline process influencing factors The calculations include: Based on the actual length of the upstream straight pipe section and actual straight pipe section length Corresponding straight pipe section length before benchmark and the length of the straight pipe section after the benchmark The degree of deviation, and the distance from the source of the flow disturbance. Conduct a comprehensive evaluation; Wherein, the length of the straight pipe section before the reference is and the length of the straight pipe section after the benchmark Based on pipe cross-sectional diameter And dynamically determine whether there are upstream flow disturbance sources; The reference straight pipe section length The method for determining it is as follows: When there is no upstream flow disturbance source ; When there is a source of flow disturbance upstream ; in, To set a constant; This is the first set constant; This is the second set constant; The diameter of the pipe cross-section; The distance between the flow disturbance source and the flow meter; The reference straight pipe section length , This is the third set of constants.
7. The real-time data processing method for an ultrasonic flow meter according to claim 1, characterized in that, Fluid property interference factor Based on the fluid characteristic parameters of the pipeline, it is used to characterize the degree of interference of fluid characteristics on the propagation of ultrasonic signals; ; in, This refers to the amount of bubble segregation per unit. This refers to the amount of segregation per unit solid particle; This is a preset reference bubble segregation amount; For reference solid particle segregation amount; exp() represents an exponential function with the natural constant e as the base.
8. The real-time data processing method for an ultrasonic flow meter according to claim 1, characterized in that, A composite correction is performed based on the first signal data, environmental parameters, measurement deviation benchmark coefficient, and pipeline fluid characteristic parameters, including: Based on the time difference signal value in the first signal data Combined with flow coefficient Calculate the initial flow rate. ; Based on the medium temperature in environmental parameters Environmental pressure For the initial flow value Perform temperature and pressure correction to obtain the corrected flow rate value. ; in, This is the temperature correction factor. This is the pressure correction factor. Standard temperature Standard pressure; If the pipeline vibration amplitude in the environmental parameters Exceeding the preset vibration threshold Then for By superimposing vibration correction, the vibration-corrected flow rate value is obtained. ; in, This is the vibration correction factor. The reference vibration amplitude; Based on the measurement deviation benchmark coefficient ,right Perform final compensation to obtain real-time traffic values. .
9. A real-time data processing system for ultrasonic flow meters, characterized in that, include: The signal acquisition module is used to acquire raw time difference signal sequences, descriptive fields, environmental parameters, installation status parameters, and pipeline fluid characteristic parameters. An anomaly detection module is used to process the original time difference signal sequence to obtain a purified time difference signal sequence; The deviation analysis module is used to determine the measurement deviation reference coefficient based on the installation status parameters and pipeline fluid characteristic parameters; An adaptive processing module is used to perform adaptive flow state matching processing on the purified time difference signal sequence to obtain the first signal data; The flow correction module is used to calculate and correct the real-time flow value based on the first signal data, environmental parameters, measurement deviation reference coefficient and pipeline fluid characteristic parameters; The output module is used to output the real-time traffic value and related information.
10. The real-time data processing system for an ultrasonic flow meter according to claim 9, characterized in that, Also includes: The model training module is used to train the flow recognition model; The parameter optimization module is used to dynamically optimize filtering parameters, sampling frequency adjustment coefficients, flow correction coefficients, description field mapping thresholds, weighting coefficients of measurement deviation benchmark coefficients, and fault tolerance compensation parameters based on real-time processing results.