Multi-parameter fusion blood glucose prediction method and system
Through the multi-parameter fusion method, combined with time series prediction model and Fourier transform technology, a multi-layer feature fusion structure is constructed, which solves the problem of low accuracy of existing blood glucose prediction methods and achieves higher blood glucose prediction accuracy and model Adaptability.
Patent Information
- Application Number
- CN202510026038.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-08
- Publication Date
- 2025-02-14
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing blood sugar prediction methods rely solely on continuous blood sugar monitoring data, and cannot fully capture multiple factors affecting blood sugar levels, resulting in low prediction accuracy.
The multi-parameter fusion method is used to collect and fuse the continuous blood glucose monitoring data, physiological characteristic data and behavioral data of the person to be tested. The time series prediction model and Fourier transform technology are used to construct a multi-layer feature fusion structure to output blood glucose prediction values.
By fusing multiple parameters, the accuracy of blood sugar prediction results is improved, the robustness of the time series prediction model is enhanced, and the model is adapted to physiological and behavioral differences in different individuals.
Smart Images

Figure CN119423704A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of blood sugar data change prediction, and in particular to a multi-parameter fusion blood sugar prediction method and system. Background Art
[0002] Diabetes is a chronic metabolic disease characterized by high blood sugar levels, which may lead to a variety of complications, such as cardiovascular disease, nephropathy, retinopathy, etc. Therefore, effective blood sugar prediction is crucial for diabetic patients. Blood sugar prediction refers to the estimation of blood sugar changes in the future based on current and historical blood sugar values, and is an indispensable part of diabetes management. By predicting blood sugar and taking certain measures based on the prediction results, diabetic patients can prevent the occurrence of adverse blood sugar events such as hypoglycemia and hyperglycemia in daily life and improve their quality of life. In addition, blood sugar prediction is an indispensable part of the closed-loop artificial pancreas system, and the predicted value of blood sugar determines the dose of insulin infusion, etc.
[0003] In the prior art, blood sugar prediction methods are mainly implemented based on algorithms such as autoregressive models, jump neural networks, recursive neural networks, and long short-term memory networks. For example, the blood sugar prediction method based on the autoregressive model mainly includes: collecting continuous blood sugar monitoring data of the subject to be tested; preprocessing the collected blood sugar data; establishing an autoregressive model, taking the blood sugar value as the dependent variable and its past value as the independent variable; using historical blood sugar data to train the model and estimate the model parameters; and using the trained model to predict blood sugar.
[0004] The above blood glucose prediction method based on the autoregressive model only collects the continuous blood glucose monitoring data of the subject to be tested for blood glucose prediction. However, the changes in human blood glucose are affected by multiple factors such as diet and exercise. Blood glucose changes are time-varying, nonlinear and personalized. Therefore, the above existing technology has a low accuracy rate in blood glucose prediction. Summary of the invention
[0005] The present invention provides a multi-parameter fusion blood glucose prediction method and system, which not only collects the continuous blood glucose monitoring data of the subject to be tested, but also collects the physiological characteristic data and behavioral data of the subject to be tested, and integrates multiple parameters, which can more comprehensively capture the factors affecting the blood glucose level, thereby improving the accuracy of the prediction result; multi-parameter fusion reduces the dependence on a single data source and enhances the robustness of the time series prediction model; using the time series prediction model and Fourier transform technology, it can accurately capture the trend and periodicity of blood glucose changes, further improving the accuracy of the prediction result; the design of the multi-layer feature fusion structure enables the time series prediction model to adapt to the physiological and behavioral differences of different individuals, thereby enhancing the adaptability and generalization ability of the time series prediction model.
[0006] In order to achieve the above object, the present invention adopts the following technical scheme: The present invention provides a multi-parameter fusion blood sugar prediction method, comprising: Obtain the continuous blood glucose monitoring data, physiological characteristic data and behavioral data of the subject.
[0007] The continuous blood glucose monitoring data, the physiological characteristic data and the behavioral data are input into a trained time series prediction model to obtain blood glucose time series data.
[0008] Perform Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector.
[0009] A multi-layer feature fusion structure is constructed according to the multi-dimensional feature vector.
[0010] Based on the multi-layer feature fusion structure, the blood glucose time series data is fused to output a blood glucose prediction value.
[0011] Furthermore, the multi-parameter fusion blood glucose prediction method, before inputting the continuous blood glucose monitoring data, the physiological characteristic data and the behavior data into the trained time series prediction model to obtain the blood glucose time series data, further includes: A time series graph of the continuous blood glucose monitoring data, the physiological characteristic data and the behavioral data is plotted to obtain data characteristics.
[0012] The time series prediction model is selected according to the data characteristics; the time series prediction model is at least one of ARIMA, SARIMA and Prophet.
[0013] Based on the time series prediction model, model parameters are determined; the model parameters include difference order, autoregression order and moving average order.
[0014] The time series prediction model is trained to obtain the trained time series prediction model.
[0015] Furthermore, the multi-parameter fusion blood glucose prediction method performs Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector, including: Perform Fourier transform on the blood glucose time series data: ; in, represents the complex value of the kth frequency point in the spectrum, represents the nth sample value in the blood glucose time series, represents the total number of samples of the blood glucose time series, k represents the kth frequency component in the spectrum, and i represents an imaginary unit.
[0016] Calculate the power spectral density, extract the frequency components, and output the power spectrum: ; in, represents the value of the power spectrum at frequency k, Representation spectrum The model, Representation spectrum The real part of Representation spectrum The imaginary part of .
[0017] The actual frequency value, the segmented power spectrum and the average power spectrum are obtained according to the power spectrum.
[0018] A multi-dimensional feature vector is constructed based on the actual frequency value, the segmented power spectrum and the average power spectrum.
[0019] Furthermore, the multi-parameter fusion blood glucose prediction method obtains the actual frequency value, the segmented power spectrum and the average power spectrum according to the power spectrum, including: The power spectrum is segmented and the step size of each segment is calculated: ; in, Indicates the length of each segment, Indicates the number of overlapping samples.
[0020] Calculate the number of segments: ; in, Indicates the number of segments, Indicates the number of elements, represents the number of overlapping samples, Indicates the step length of each segment.
[0021] Calculate the actual frequency value: ; in, represents the frequency index, represents the sampling frequency, Indicates the length of each segment.
[0022] Calculate the power spectrum after segmentation: ; in, represents the power spectrum of the kth segment, represents the normalization factor of the window function, Represents the fast Fourier transform result of the power spectrum described in the kth segment.
[0023] Compute the average power spectrum: ; in, Indicates the number of segments, Indicates The power spectrum of the segment.
[0024] Furthermore, the multi-parameter fusion blood glucose prediction method constructs a multi-layer feature fusion structure according to the multi-dimensional feature vector, including: The multi-dimensional feature vector is preprocessed; the preprocessing includes normalization, missing value processing and feature encoding.
[0025] Construct a time alignment matrix to synchronize the output features of each of the time series prediction models: ; in, , , …, represents the time point after alignment, , …, Represents the first time series forecasting model at time point , , …, The output features of , …, Indicates that the second time series forecasting model is at time point , , …, The output features of .
[0026] Feature screening is performed on the output features of each of the time series prediction models.
[0027] The filtered output features are weighted fused: ; in, represents the output features after screening by the first time series prediction model, represents the output feature after the second time series prediction model is filtered, represents the weight of the output feature after screening by the first time series prediction model, Represents the weight of the output feature after screening by the second time series prediction model.
[0028] Adjust the fusion weights: ; in, represents the adjusted fusion weight, represents the fusion weight before adjustment, Represents the time decay factor.
[0029] Adopt sliding window strategy to update fusion parameters: ; in, Indicates at a point in time The fusion weight of represents the size of the sliding window, Indicates Model at time point Output.
[0030] Furthermore, the multi-parameter fusion blood glucose prediction method performs feature screening on the output features of each of the time series prediction models, including: The LASSO algorithm is used to perform feature screening on the output features of each of the time series prediction models: ; in, represents the response variable, represents the feature matrix, represents the coefficient vector, represents the regularization parameter.
[0031] Furthermore, the multi-parameter fusion blood glucose prediction method, after obtaining the continuous blood glucose monitoring data, physiological characteristic data and behavioral data of the subject, further includes: The continuous blood glucose monitoring data, the physiological characteristic data and the behavior data are preprocessed respectively.
[0032] Furthermore, the multi-parameter fusion blood glucose prediction method, after fusing the blood glucose time series data based on the multi-layer feature fusion structure and outputting the blood glucose prediction value, further includes: The blood glucose prediction value is post-processed; the post-processing includes calculating the confidence interval, outlier detection, accuracy assessment and real-time calibration of the blood glucose prediction value.
[0033] Furthermore, in the multi-parameter fusion blood sugar prediction method, the physiological characteristic data includes: The physiological characteristic data include age, gender, weight, body temperature, heart rate, blood pressure and blood parameters.
[0034] Furthermore, in the multi-parameter fusion blood sugar prediction method, the behavior data includes: The behavior data includes eating behavior data and exercise behavior data.
[0035] The present invention provides a multi-parameter fusion blood sugar prediction system, which is used to execute a computer program to implement the above-mentioned multi-parameter fusion blood sugar prediction method.
[0036] The present invention provides a multi-parameter fusion blood glucose prediction method, comprising: obtaining continuous blood glucose monitoring data, physiological characteristic data and behavioral data of a subject; inputting the data into a trained time series prediction model to obtain blood glucose time series data; performing Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector; constructing a multi-layer feature fusion structure according to the multi-dimensional feature vector; based on the multi-layer feature fusion structure, fusing the blood glucose time series data and outputting a blood glucose prediction value. Compared with the prior art, the present invention not only collects the continuous blood glucose monitoring data of the subject, but also collects the physiological characteristic data and behavioral data of the subject, and fuses multiple parameters, so as to more comprehensively capture the factors affecting the blood glucose level, thereby improving The accuracy of the prediction results; multi-parameter fusion reduces the dependence on a single data source and enhances the robustness of the time series prediction model; researchers have found that blood glucose monitoring data is a clinical data index that changes over time and is greatly affected by other factors. For this, the technical solution adopted by the embodiment of the present invention utilizes a time series prediction model and Fourier transform technology to accurately capture the trend and periodicity of blood glucose changes, further improving the accuracy of the prediction results; implement Fourier transform on blood glucose time series data to obtain a multi-dimensional feature vector; then construct a multi-layer feature fusion structure based on the multi-dimensional feature vector; based on the multi-layer feature fusion structure, fuse the blood glucose time series data and output the blood glucose prediction value. In the process of implementing Fourier transform on blood glucose time series data to obtain a multi-dimensional feature vector, it is necessary to refer to the first feature vector in the blood glucose time series. sample values, frequency components, etc. At the same time, the design of the above multi-layer feature fusion structure enables the time series prediction model to adapt to the physiological and behavioral differences of different individuals, enhancing the adaptability and generalization ability of the time series prediction model. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for describing the embodiments. The drawings are only used to illustrate the implementation methods and are not to be considered as limitations of the present invention.
[0038] Figure 1 This is a schematic diagram of a multi-parameter fusion blood glucose prediction method according to an embodiment of the present invention; Figure 2 This is a flow chart of another multi-parameter fusion blood glucose prediction method according to an embodiment of the present invention; Figure 3A schematic flow chart of a method for obtaining an actual frequency value, a segmented power spectrum and an average power spectrum in an embodiment of the present invention; Figure 4 Schematic diagram of the composition of the confusion matrix in an embodiment of the present invention. DETAILED DESCRIPTION
[0039] The technical scheme in the embodiment of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiment of the present invention. Obviously, the described embodiment is only a part of the embodiment of the present invention, not all of the embodiments. Based on the embodiment of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0040] Unless otherwise defined, all technical and scientific terms used in the present invention have the same meaning as those commonly understood by technicians in the field of the present invention; the terms used in the present invention are only for the purpose of describing specific embodiments, and are not intended to limit the terms "including" and "having" and any variations thereof in the specification and claims of the present invention and the above-mentioned drawings, and are intended to cover non-exclusive inclusions.
[0041] In the description of the embodiments of the present invention, the technical terms "first", "second", etc. are only used to distinguish different objects, and cannot be understood as indicating or implying relative importance or implicitly indicating the number, specific order or primary and secondary relationship of the indicated technical features. In the description of the embodiments of the present invention, the meaning of "multiple" is more than two, unless otherwise clearly and specifically defined.
[0042] In the description of the embodiments of the present invention, the term "and / or" is only a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B may represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0043] In the description of the embodiments of the present invention, the term "multiple" refers to more than two (including two). Similarly, "multiple groups" refers to more than two groups (including two groups), and "multiple pieces" refers to more than two pieces (including two pieces).
[0044] In the description of the embodiments of the present invention, the technical terms "center", "longitudinal", "lateral", "length", "width", "thickness", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", "clockwise", "counterclockwise", "axial", "radial", "circumferential", etc. indicate orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the embodiments of the present invention and simplifying the description, and do not indicate or imply that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the embodiments of the present invention.
[0045] In the description of the embodiments of the present invention, unless otherwise clearly specified and limited, technical terms such as "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the embodiments of the present invention can be understood according to the specific circumstances.
[0046] Embodiment 1: The embodiment of the present invention provides a multi-parameter fusion blood glucose prediction method, such as Figure 1 As shown, including: S101, obtaining continuous blood glucose monitoring data, physiological characteristic data and behavioral data of the subject.
[0047] The subject to be tested refers to an individual who needs to be tested in a medical examination, usually a patient. Of course, in some cases, the subject to be tested can also be a healthy individual.
[0048] Continuous blood glucose monitoring data refers to blood glucose level data collected by continuous blood glucose monitoring equipment, which is continuous in time. Continuous blood glucose monitoring data is usually obtained in real time by implanting a micro sensor under the skin of the subject or wearing a non-invasive blood glucose sensor.
[0049] It should be noted here that the interval of continuous blood glucose monitoring data is synchronized with the monitoring frequency of the continuous blood glucose monitoring device (such as a micro sensor or a wearable non-invasive blood glucose sensor). For example, if the micro sensor automatically records the blood glucose value every 10 minutes, the interval of continuous blood glucose monitoring data is 10 minutes. Therefore, the continuous blood glucose monitoring data of different intervals can be obtained in real time by setting the monitoring frequency of the continuous blood glucose monitoring device.
[0050] Physiological characteristic data refers to a series of biological indicators and parameters that reflect an individual's physiological state and characteristics. Common physiological characteristic data include age, gender, weight, body temperature, heart rate, blood pressure, and blood parameters. Physiological characteristic data can be obtained through questionnaires, physical examinations, or wearable devices.
[0051] Behavioral data refers to the daily behavior records of the subjects. Common behavioral data include: dietary behavior data and exercise behavior data, etc. Behavioral data can be obtained through verbal inquiries or questionnaires, testing equipment, application interaction, and related equipment testing data archives.
[0052] S102, inputting the continuous blood glucose monitoring data, physiological characteristic data and behavioral data into the trained time series prediction model to obtain blood glucose time series data.
[0053] A time series prediction model is a statistical model used to analyze and predict data points arranged in chronological order. It can capture the trend of data over time (such as the trend of data changes in the morning, noon, and at night during sleep, and even seasonal trends), and predict future data points accordingly. Time series prediction models include the autoregressive integrated moving average model, the seasonal autoregressive integrated moving average model, and the Prophet model. The following is a brief introduction to each time series prediction model: Autoregressive Integrated Moving Average Model (ARIMA) is a statistical model used to analyze and predict time series data. It combines the characteristics of three models: autoregressive (AR), difference (I) and moving average (MA), and is particularly suitable for analyzing and predicting univariate time series data.
[0054] Seasonal Autoregressive Integrated Moving Average Model: SARIMA is an extension of the ARIMA model, specifically designed to analyze and forecast time series data with seasonal patterns. The SARIMA model is able to handle both non-seasonal and seasonal effects.
[0055] Prophet model: is a forecasting tool based on time series decomposition and parameter fitting. It decomposes the time series into components such as trend, seasonality and holiday effects, and uses Bayesian statistical methods for modeling and forecasting.
[0056] Blood glucose time series data refers to a blood glucose level dataset that changes over time by analyzing and processing a series of data related to blood glucose levels (such as continuous blood glucose monitoring data, physiological characteristic data, and behavioral data).
[0057] S103, performing Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector.
[0058] Fourier transform is a mathematical tool used to convert signals from the time domain or space domain to the frequency domain. This conversion reveals the frequency components of the signal and is very useful for analyzing and processing various types of signals, especially in the fields of signal processing, image analysis, communication systems, etc. The basic idea of Fourier transform is that any complex periodic signal can be represented as a superposition of sine waves and cosine waves of different frequencies. Through Fourier transform, the amplitude and phase of these basic frequency components that make up the signal can be determined. The Fourier transform of this embodiment converts the time domain signal into a frequency domain signal. This process can help us identify periodic patterns and trends in blood sugar changes, thereby providing valuable information for blood sugar prediction. In this embodiment, the blood sugar time series data is Fourier transformed, and the specific steps for obtaining a multi-dimensional feature vector are as follows: Data preprocessing: remove noise, fill missing values, standardize, etc. for blood glucose time series data.
[0059] Fourier transform: Perform Fourier transform on the preprocessed blood glucose time series data to convert it from the time domain to the frequency domain.
[0060] Feature extraction: Extract multi-dimensional features from the results of Fourier transform, including the amplitude of frequency components, the phase of frequency components, and the power spectral density.
[0061] Construct feature vector: Organize the extracted features into a feature vector.
[0062] Feature standardization: Standardize the feature vectors to make them have the same scale to facilitate subsequent analysis.
[0063] S104. Construct a multi-layer feature fusion structure based on the multi-dimensional feature vector.
[0064] Multi-layer Feature Fusion Structure is an integrated learning method that integrates features from different sources or different levels. In practical applications, such as medical diagnosis, financial risk assessment, and recommendation systems, the multi-layer feature fusion structure has been proven to be an effective method that can make full use of multi-dimensional information in the data to achieve more accurate predictions.
[0065] S105. Based on the multi-layer feature fusion structure, the blood glucose time series data is fused to output the blood glucose prediction value.
[0066] Specifically, the blood glucose time series data is fused, that is, features from different sources and different levels are integrated. The fusion method includes weighted summation, splicing, attention mechanism or other advanced fusion techniques. The fused feature vector is used to output the final blood glucose prediction value.
[0067] The embodiment of the present invention provides a multi-parameter fusion blood glucose prediction method, including: obtaining continuous blood glucose monitoring data, physiological characteristic data and behavioral data of a subject; inputting the data into a trained time series prediction model to obtain blood glucose time series data; performing Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector; constructing a multi-layer feature fusion structure according to the multi-dimensional feature vector; based on the multi-layer feature fusion structure, fusing the blood glucose time series data and outputting a blood glucose prediction value. Compared with the prior art, the embodiment of the present invention not only collects the continuous blood glucose monitoring data of the subject, but also collects the physiological characteristic data and behavioral data of the subject, and fuses multiple parameters, which can more comprehensively capture the factors affecting the blood glucose level, thereby improving the accuracy of the prediction result; multi-parameter fusion reduces the dependence on a single data source and enhances the robustness of the time series prediction model; using the time series prediction model and Fourier transform technology, the trend and periodicity of blood glucose changes can be accurately captured, further improving the accuracy of the prediction result; the design of the multi-layer feature fusion structure enables the time series prediction model to adapt to the physiological and behavioral differences of different individuals, thereby enhancing the adaptability and generalization ability of the time series prediction model.
[0068] Embodiment 2: The embodiment of the present invention provides a multi-parameter fusion blood glucose prediction method, such as Figure 2 As shown, including: S201, obtaining continuous blood glucose monitoring data, physiological characteristic data and behavioral data of the subject.
[0069] S202: Pre-process the continuous blood glucose monitoring data, physiological characteristic data and behavioral data respectively.
[0070] Among them, physiological characteristic data include age, gender, weight, body temperature, heart rate, blood pressure and blood parameters, and behavioral data include eating behavior and exercise behavior.
[0071] Specifically, the preprocessing of continuous blood glucose monitoring data includes: using piecewise cubic spline interpolation to supplement the missing values in the continuous blood glucose monitoring data; using Savitzky-Golay filtering to smooth the supplemented continuous blood glucose monitoring data; performing 3σ outlier detection on the smoothed continuous blood glucose monitoring data; and correcting the detected outliers using the local weighted regression method.
[0072] Preprocessing of physiological characteristic data includes: identifying missing values and taking appropriate measures, such as deleting, interpolating, or using models to predict missing values; using statistical methods (such as Z-score, IQR) to identify abnormal values and process them. Among them, the variability analysis of heart rate data is carried out to extract SDNN and RMSSD indicators; the blood pressure data is segmented and statistically analyzed to calculate the coefficient of variation of systolic and diastolic pressure; the SDNN, RMSSD indicators and coefficient of variation are used to reconstruct the blood sugar time series; and the reconstructed blood sugar time series is subjected to wavelet denoising.
[0073] The preprocessing of behavioral data includes: quantifying the nutritional components of dietary behavior and establishing a carbohydrate intake time series; grading the intensity of exercise behavior and constructing an exercise intensity-duration characteristic matrix; and establishing a behavioral characteristic time window based on the carbohydrate intake time series and the exercise intensity-duration characteristic matrix.
[0074] S203: Draw a time series graph of the continuous blood glucose monitoring data, physiological characteristic data, and behavioral data to obtain data characteristics.
[0075] Specifically, Python's matplotlib library can be used to draw a time series graph, and the time series graph can be observed and analyzed to obtain data characteristics.
[0076] S204. Select a time series prediction model based on data characteristics; the time series prediction model is at least one of ARIMA, SARIMA and Prophet.
[0077] The following is a detailed introduction to ARIMA, SARIMA and Prophet for your selection: ARIMA, the full name of which is Autoregressive Integrated Moving Average model, is a statistical model widely used in time series forecasting. It combines three methods, autoregression (AR), difference (I) and moving average (MA), and is particularly suitable for analyzing and forecasting univariate time series data. The expression of ARIMA is: ; in, represents the backoff factor, represents the autoregressive coefficient, represents the moving average coefficient, represents the error term, represents the value of the time series at time t, represents the difference order, represents the autoregressive order, Represents the moving average order.
[0078] SARIMA, the full name of which is Seasonal Autoregressive Integrated Moving Average Model, is a statistical model for time series forecasting. It is an extension of the ARIMA model and is specifically used to process time series data with seasonal patterns. The expression of SARIMA is: ; in, represents the backoff factor, represents nonseasonal autoregressive and moving average polynomials, represents seasonal autoregressive and moving average polynomials, represents the autoregressive mean polynomial of seasonality, represents the moving average polynomial of seasonality, represents the difference order, represents the seasonal difference order, Represents the seasonal cycle, represents the error term.
[0079] Prophet is a time series forecasting tool open sourced by Facebook. It is particularly suitable for processing time series data with strong seasonal characteristics, and has good processing capabilities for holidays and emergencies. The expression of Prophet is: ; in, Indicates time The observed value at It is a trend function. Represents periodic changes, Represents the effect of holidays that occur on a potentially irregular schedule, represents the error term.
[0080] S205. Determine model parameters based on the time series prediction model; the model parameters include difference order, autoregression order and moving average order.
[0081] For example: Select ARIMA as the time series prediction model, and the difference order can be obtained through its expression , autoregressive order and the moving average order .
[0082] ; in, represents the backoff factor, represents the autoregressive coefficient, represents the moving average coefficient, represents the error term, represents the value of the time series at time t, represents the difference order, represents the autoregressive order, Represents the moving average order.
[0083] S206: Train the time series prediction model to obtain a trained time series prediction model.
[0084] Specifically, the selected time series prediction model (such as ARIMA) is trained using historical continuous blood glucose monitoring data, physiological characteristic data, and behavioral data as training sets.
[0085] S207, inputting the continuous blood glucose monitoring data, physiological characteristic data and behavioral data into the trained time series prediction model to obtain blood glucose time series data.
[0086] S208. Perform Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector.
[0087] S2081. Perform Fourier transform on blood glucose time series data: ; in, Indicates the frequency spectrum The complex value of the frequency point, Indicates the first Sample values, represents the total number of samples in the blood glucose time series, Indicates the first frequency components, Represents an imaginary unit.
[0088] S2082. Calculate power spectrum density, extract frequency components, and output power spectrum: ; in, The power spectrum at frequency The value at Representing spectrum The model, Representing spectrum The real part of Representing spectrum The imaginary part of .
[0089] S2083, according to the power spectrum, obtain the actual frequency value, the segmented power spectrum and the average power spectrum, such as Figure 3 As shown, including: S20831. Divide the power spectrum into segments and calculate the step length of each segment: ; in, Indicates the length of each segment, Indicates the number of overlapping samples.
[0090] S20832. Calculate the number of segments: ; in, Indicates the number of segments, Indicates the number of elements, represents the number of overlapping samples, Indicates the step length of each segment.
[0091] S20833. Calculate the actual frequency value: ; in, represents the frequency index, represents the sampling frequency, Indicates the length of each segment.
[0092] S20834. Calculate the power spectrum after segmentation: ; in, Indicates The power spectrum of the segment, represents the normalization factor of the window function, Indicates The fast Fourier transform result of the power spectrum described in the paragraph.
[0093] S20835. Calculate the average power spectrum: ; in, Indicates the number of segments, Indicates The power spectrum of the segment.
[0094] S2084. Construct a multi-dimensional feature vector based on the actual frequency value, the segmented power spectrum and the average power spectrum.
[0095] The process of constructing a multidimensional feature vector based on actual frequency values, segmented power spectra, and average power spectra involves extracting statistical and frequency domain features from blood glucose time series data. The following are the detailed steps to construct such a feature vector: The feature extraction of the actual frequency value includes: extracting the peak frequency, that is, finding the frequency point with the maximum power in the power spectrum. Extracting the significant frequency components, that is, identifying all the frequency components exceeding a certain threshold in the power spectrum.
[0096] The feature extraction of the segmented power spectrum includes: extracting the statistical features of each segment of the power spectrum, which include mean, variance, skewness and kurtosis.
[0097] The feature extraction of the average power spectrum includes: extracting the total average power, root mean square frequency (RMSF), mean square frequency (MSF) and frequency variance (VF).
[0098] In summary, the above extracted features are combined into a feature vector, which can be: ; S209. Construct a multi-layer feature fusion structure based on the multi-dimensional feature vector.
[0099] S2091. Preprocess the multi-dimensional feature vector; the preprocessing includes normalization, missing value processing and feature encoding.
[0100] Among them, normalization is to scale the features to a specific range, usually 0 to 1, or -1 to 1.
[0101] Missing values can be handled in many ways, including deleting records with missing values, filling missing values, etc. Feature encoding is the process of converting non-numeric features in the original data into numerical features that the model can handle. In machine learning, most algorithms require numerical data as input, so feature encoding is an important step in processing categorical data.
[0102] S2092. Construct a time alignment matrix to synchronize the output features of each time series prediction model: ; in, , , …, represents the time point after alignment, , …, Represents the first time series forecasting model at time point , , …, The output features of , …, Represents the second time series forecasting model at time point , , …, The output features of .
[0103] S2093. Perform feature screening on the output features of each time series prediction model.
[0104] The LASSO algorithm is used to perform feature screening on the output features of each of the time series prediction models: ; in, represents the response variable, represents the feature matrix, represents the coefficient vector, represents the regularization parameter.
[0105] S2094. Perform weighted fusion on the filtered output features: ; in, represents the output features after screening by the first time series prediction model, represents the output feature after the second time series prediction model is filtered, represents the weight of the output feature after screening by the first time series prediction model, Represents the weight of the output feature after screening by the second time series prediction model.
[0106] S2095. Adjust the fusion weight: ; in, represents the adjusted fusion weight, represents the fusion weight before adjustment, Represents the time decay factor.
[0107] S2096. Update fusion parameters using a sliding window strategy: ; in, Indicates at a point in time The fusion weight of represents the size of the sliding window, Indicates Model at time point Output.
[0108] S210: Based on the multi-layer feature fusion structure, the blood glucose time series data is fused to output the blood glucose prediction value.
[0109] S211, post-processing the blood glucose prediction value; the post-processing includes calculating the confidence interval of the blood glucose prediction value, outlier detection, accuracy evaluation and real-time calibration.
[0110] Specifically, the confidence interval for calculating the blood glucose prediction value can be obtained by using the Monte Carlo simulation method or the intermediate layer feature perturbation method; wherein, the Monte Carlo simulation simulates the state change of the perturbation of the model input, obtains the upper and lower bounds of the model's blood glucose prediction value under different disturbances, and thus obtains the confidence interval; the intermediate layer feature perturbation method is to select the intermediate layer features of the neural network, rebuild the network from this layer to the blood glucose prediction value output layer, and copy the trained network parameters to the new network; extract the features of the input data in the intermediate layer, and apply quantitative infinite norm interference to it to construct the feature fluctuation range, and propagate the feature fluctuation range from the intermediate layer to the output layer to obtain the output confidence interval.
[0111] Outlier detection is used to identify abnormal points in blood glucose prediction values. Commonly used outlier detection methods include statistical methods and machine learning methods. Among them, statistical methods, such as the IQR (interquartile range) method, determine the range of outliers by calculating the quartiles of blood glucose prediction values; machine learning methods, such as Isolation Forest, can identify abnormal points that do not conform to most data patterns.
[0112] Accuracy evaluation is used to measure the performance of multi-layer feature fusion structures. Common evaluation indicators include: Pearson correlation coefficient, mean absolute error, root mean square error and confusion matrix. Among them, the Pearson correlation coefficient is used to measure the correlation between the predicted value and the actual value, the mean absolute error is used to measure the average size of the difference between the predicted value and the actual value, the root mean square error is used to measure the square root of the average size of the square of the difference between the predicted value and the actual value, and the confusion matrix is used to evaluate classification problems and show the relationship between the actual category and the predicted category.
[0113] Real-time calibration refers to adjusting model parameters in real time according to new data to improve prediction accuracy. This can be achieved through the following methods: (1) Fingertip blood glucose calibration: input 4 to 8 fingertip blood glucose values for calibration every day, and calculate the matching rate between the input finger blood values and the real-time continuous blood glucose monitoring (RT-CGM) probe values. (2) Multiple linear regression analysis: analyze the relationship between the matching rate and indicators such as the average daily blood glucose fluctuation range (MAGE), standard deviation of blood glucose (SDBG), and 24-hour mean blood glucose (MBG).
[0114] The following is a detailed description of step S211, i.e., post-processing the predicted blood glucose value; the post-processing includes calculating the confidence interval of the predicted blood glucose value, detecting abnormal values, and evaluating the accuracy: The technical purpose of calculating the confidence interval for the blood glucose prediction value is to better achieve the technical purpose of the embodiment of the present invention, to provide a credible range for the blood glucose prediction value, and to quantify the uncertainty of the prediction.
[0115] There are two main methods for calculating the confidence interval of the blood glucose prediction value in the embodiment of the present invention, including using the Monte Carlo simulation method (preferred in the present invention) or using the intermediate layer feature perturbation method; 1.1 Monte Carlo simulation method steps: S2111. Input perturbations: Random perturbations are applied to the model’s input data to simulate different actual state changes. These perturbations are usually based on the statistical properties of the input data (such as mean and variance).
[0116] Let the original input vector be , the perturbed input is: ; in, is the standard deviation of the disturbance, is the identity matrix.
[0117] The original input vector is ; Where R represents the real number set, which is used to represent the set of all real numbers. Meaning: In vector X, each element is a real number. This means that each feature of the input data is a continuous value, which can be any real value, such as blood sugar concentration, timestamp, sensor reading, etc.
[0118] n represents the dimension (dimension or number of features) of the vector, that is, the number of features contained in the input vector X. The input vector X contains all the features required to predict blood glucose values. For example, if the model uses 5 different sensor readings as input, then n=5. In practical applications, n may include: time-related features (such as current time, time interval of the last measurement); physiological data (such as body temperature, heart rate); historical blood glucose values; diet and exercise related data; other environmental or individual characteristics; S2112. Multiple predictions: The perturbed input , Enter the model multiple times to get a series of predictions: ;in, is the number of simulations. S2113. Confidence interval calculation: Then, based on the predicted value sequence, calculate the upper and lower bounds of the confidence interval. Take the confidence interval as an example: ; in, and They are the 2.5th and 97.5th percentiles of the series of predicted values, respectively.
[0119] S2114 implements outlier detection; the technical purpose of outlier detection is to identify and eliminate outliers in blood glucose prediction values and improve the overall prediction quality. The following statistical methods are used: Interquartile range (IQR) method steps: S21141. Calculate quartiles: percentile; S21142. Calculate IQR: ; S21143. Determine the range of outliers: lower bound ; S21144. Identifying Outliers: Predicting Values Values beyond [lower bound, upper bound] are outliers.
[0120] S2115. Implement accuracy assessment processing operations; The technical purpose of accuracy assessment is to measure the performance of multi-layer feature fusion structures (such as neural networks) in blood glucose prediction tasks and verify the effectiveness of the model.
[0121] Evaluation Metrics: Pearson Correlation Coefficient (PCC) Mean Absolute Error (MAE) Root Mean Square Error (RMSE) Confusion matrix (only for classification problems) S21151. Calculate the Pearson correlation coefficient; Measuring Predicted Value With actual value The linear correlation between .
[0122] formula: ;in, is the covariance, and They are and The standard deviation of .
[0123] S21152. Calculate the mean absolute error; measure the average absolute difference between the predicted value and the actual value, reflecting the average size of the error. Formula: ;in, is the total number of samples.
[0124] S21153. Calculate the root mean square error Definition: The square root of the average of the squares of the differences between the predicted and actual values, emphasizing larger errors. Formula: ; S21154. Calculate the confusion matrix definition: used for classification problems to show the correspondence between actual categories and predicted categories. The composition of the confusion matrix can be found in Figure 4 : Among them, TP, FN, FP, and TN represent true positives, false negatives, false positives, and true negatives, respectively.
[0125] It should be noted that the accuracy evaluation relies on the outlier detection results. By removing outliers, we can ensure that the evaluation indicators more accurately reflect the actual performance of the model. At the same time, these evaluation indicators provide a basis for model optimization and real-time calibration.
[0126] S2115. Implement real-time calibration processing operations: After the model is deployed, dynamically adjust the model parameters or prediction results to cope with environmental changes and data distribution drift to ensure the long-term stable prediction performance of the model. For example (1) Fingertip blood glucose value calibration: input 4 to 8 fingertip blood glucose values for calibration every day, and calculate the matching rate between the input finger blood value and the real-time continuous blood glucose monitoring (RT-CGM) probe value. (2) Multiple linear regression analysis: analyze the relationship between the matching rate and indicators such as the average daily blood glucose fluctuation range (MAGE), standard deviation of blood glucose (SDBG), and 24-hour average blood glucose (MBG). This will not be repeated. After calibration, re-evaluate the accuracy indicators of the model to ensure that the calibration measures are effective. This will not be repeated.
[0127] Embodiment 3 The present invention provides a multi-parameter fusion blood sugar prediction system, which is used to execute a computer program to implement the above-mentioned multi-parameter fusion blood sugar prediction method.
[0128] The embodiment of the present invention provides a multi-parameter fusion blood glucose prediction method, including: obtaining continuous blood glucose monitoring data, physiological characteristic data and behavioral data of a subject; inputting the data into a trained time series prediction model to obtain blood glucose time series data; performing Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector; constructing a multi-layer feature fusion structure according to the multi-dimensional feature vector; based on the multi-layer feature fusion structure, fusing the blood glucose time series data and outputting a blood glucose prediction value. Compared with the prior art, the embodiment of the present invention not only collects the continuous blood glucose monitoring data of the subject, but also collects the physiological characteristic data and behavioral data of the subject, and fuses multiple parameters, which can more comprehensively capture the factors affecting the blood glucose level, thereby improving the accuracy of the prediction result; multi-parameter fusion reduces the dependence on a single data source and enhances the robustness of the time series prediction model; using the time series prediction model and Fourier transform technology, the trend and periodicity of blood glucose changes can be accurately captured, further improving the accuracy of the prediction result; the design of the multi-layer feature fusion structure enables the time series prediction model to adapt to the physiological and behavioral differences of different individuals, thereby enhancing the adaptability and generalization ability of the time series prediction model.
[0129] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, not to limit them; although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the above embodiments, or replace some or all of the technical features therein by equivalents; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present invention, and they should all be included in the scope of the claims and specification of the present invention. In particular, as long as there is no structural conflict, the various technical features mentioned in each embodiment can be combined in any way. The present invention is not limited to the specific embodiments disclosed herein, but includes all technical solutions that fall within the scope of the claims.
Claims
1. A multi-parameter fusion blood sugar prediction method, characterized in that: include: Obtaining continuous blood glucose monitoring data, physiological characteristic data and behavioral data of the subject; Inputting the continuous blood glucose monitoring data, the physiological characteristic data and the behavior data into a trained time series prediction model to obtain blood glucose time series data; Performing Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector; Constructing a multi-layer feature fusion structure according to the multi-dimensional feature vector; Based on the multi-layer feature fusion structure, the blood glucose time series data is fused to output a blood glucose prediction value.
2. The multi-parameter fusion blood sugar prediction method according to claim 1, characterized in that: Before inputting the continuous blood glucose monitoring data, the physiological characteristic data and the behavior data into the trained time series prediction model to obtain the blood glucose time series data, the method further includes: Draw a time series graph of the continuous blood glucose monitoring data, the physiological characteristic data, and the behavior data to obtain data characteristics; According to the data characteristics, the time series prediction model is selected; the time series prediction model is at least one of ARIMA, SARIMA and Prophet; Based on the time series prediction model, model parameters are determined; the model parameters include difference order, autoregression order and moving average order; The time series prediction model is trained to obtain the trained time series prediction model.
3. The multi-parameter fusion blood sugar prediction method according to claim 1, characterized in that: Perform Fourier transform on the blood glucose time series data to obtain a multi-dimensional feature vector, including: Perform Fourier transform on the blood glucose time series data: ; in, represents the complex value of the kth frequency point in the spectrum, represents the nth sample value in the blood glucose time series, represents the total number of samples of the blood glucose time series, k represents the kth frequency component in the spectrum, represents an imaginary unit; Calculate the power spectral density, extract the frequency components, and output the power spectrum: ; in, represents the value of the power spectrum at frequency k, Representation spectrum The model, Representation spectrum The real part of Representation spectrum The imaginary part of Acquire the actual frequency value, the segmented power spectrum and the average power spectrum according to the power spectrum; A multi-dimensional feature vector is constructed based on the actual frequency value, the segmented power spectrum and the average power spectrum.
4. The multi-parameter fusion blood sugar prediction method according to claim 3, characterized in that: Acquiring an actual frequency value, a segmented power spectrum, and an average power spectrum according to the power spectrum, including: The power spectrum is segmented and the step size of each segment is calculated: ; in, Indicates the length of each segment, Indicates the number of overlapping samples; Calculate the number of segments: ; in, Indicates the number of segments, Indicates the number of elements, represents the number of overlapping samples, Indicates the step length of each segment; Calculate the actual frequency value: ; in, represents the frequency index, represents the sampling frequency, Indicates the length of each segment; Calculate the power spectrum after segmentation: ; in, represents the power spectrum of the kth segment, represents the normalization factor of the window function, represents the fast Fourier transform result of the power spectrum of the kth segment; Compute the average power spectrum: ; in, Indicates the number of segments, represents the power spectrum of the kth segment.
5. The multi-parameter fusion blood sugar prediction method according to claim 1, characterized in that: Constructing a multi-layer feature fusion structure according to the multi-dimensional feature vector, including: Preprocessing the multi-dimensional feature vector; the preprocessing includes normalization, missing value processing and feature encoding; Construct a time alignment matrix to synchronize the output features of each of the time series prediction models: ; in, , , …, represents the time point after alignment, , …, Represents the first time series forecasting model at time point , , …, The output features of , …, Represents the second time series forecasting model at time point , , …, Output features of Performing feature screening on the output features of each of the time series prediction models; The filtered output features are weighted fused: ; in, represents the output features after screening by the first time series prediction model, represents the output feature after the second time series prediction model is filtered, represents the weight of the output feature after screening by the first time series prediction model, represents the weight of the output feature after screening by the second time series prediction model; Adjust the fusion weights: ; in, represents the adjusted fusion weight, represents the fusion weight before adjustment, represents the time decay factor; Adopt sliding window strategy to update fusion parameters: ; in, Indicates at a point in time The fusion weight of represents the size of the sliding window, Indicates Model at time point Output.
6. The multi-parameter fusion blood sugar prediction method according to claim 5, characterized in that: The output features of each of the time series prediction models are screened, including: The LASSO algorithm is used to perform feature screening on the output features of each of the time series prediction models: ; in, represents the response variable, represents the feature matrix, represents the coefficient vector, represents the regularization parameter.
7. The multi-parameter fusion blood sugar prediction method according to claim 1, characterized in that: After obtaining the continuous blood glucose monitoring data, physiological characteristics data and behavioral data of the subject, it also includes: The continuous blood glucose monitoring data, the physiological characteristic data and the behavior data are preprocessed respectively.
8. The multi-parameter fusion blood sugar prediction method according to claim 1, characterized in that: After fusing the blood glucose time series data based on the multi-layer feature fusion structure and outputting the blood glucose prediction value, the method further includes: The blood glucose prediction value is post-processed; the post-processing includes calculating the confidence interval, outlier detection, accuracy assessment and real-time calibration of the blood glucose prediction value.
9. The multi-parameter fusion blood sugar prediction method according to claim 1, characterized in that: The physiological characteristic data includes: The physiological characteristic data include age, gender, weight, body temperature, heart rate, blood pressure and blood parameters.
10. A multi-parameter fusion blood sugar prediction system, characterized in that: The multi-parameter fusion blood glucose prediction system is used to execute a computer program to implement a multi-parameter fusion blood glucose prediction method as described in any one of claims 1 to 9 above.
Citation Information
Patent Citations
Online dynamic blood sugar predicting method based on VMD-LSSVM model
CN110164553A
Blood glucose prediction method and device, electronic device, and storage medium
CN111329491A
Optical non-invasive blood glucose concentration detection method based on time-spectrum-space multi-parameter fusion
CN117357105A
Non-invasive blood glucose prediction method and system for smart watch
CN118197629A
Method and device for predicting residual life of equipment and electronic equipment
CN119129826A
Cited By
Pet health monitoring method and system based on prediction model
CN119650074A
Blood glucose dynamic prediction method and system fusing physiological data and behavior data
CN120959733A
Diabetes cardiovascular disease risk assessment feature acquisition method based on multi-modal data fusion
CN120977567A
Noninvasive blood glucose monitoring method and system fusing multi-modal physiological parameters
CN121370155A
Miniaturized blood glucose intelligent monitoring and analysis method integrating edge calculation
CN121370158A