Prediction method and system for postoperative pulmonary infection
By performing timestamp alignment and multi-scale analysis on the respiratory monitoring data of postoperative patients, combined with local anomaly factors and kernel principal component analysis, a spatial probability distribution map of lung segment infection is generated, which solves the problem of insufficient temporal and spatial resolution capabilities in postoperative lung infection risk assessment in existing technologies, and achieves accurate postoperative lung infection prediction and early warning.
Patent Information
- Application Number
- CN202510799826.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-16
- Publication Date
- 2025-09-16
AI Technical Summary
Existing technologies rely on laboratory indicators and imaging features at discrete time points in assessing the risk of postoperative lung infection, and lack continuous dynamic monitoring of respiratory physiological parameters, resulting in difficulty in timely capturing early compensatory abnormalities. Traditional methods are unable to analyze the temporal correlation characteristics and nonlinear interactions between multiple parameters. The prediction results lack spatial resolution and cannot locate the lung segment where the infection starts, leading to an expansion of the scope of preventive antibiotic use, increasing patients' risk of drug resistance and medical costs.
The time series data of tidal volume, blood oxygen saturation, and respiratory rate of postoperative patients were obtained through respiratory monitoring equipment. Timestamp alignment and completion technology was used to generate a unified time axis. Multi-scale respiratory signal analysis was performed, and the time interval between the tidal volume change and the inflection point of the blood oxygen saturation response was calculated. The degree of abnormality of the lung segment delay characteristics was evaluated using the local abnormality factor algorithm. The spatial probability distribution map of lung segment infection was generated by combining the kernel principal component analysis model. Finally, a logistic regression model was used to output a postoperative lung infection warning list.
It has achieved improvements in the timeliness and spatial positioning accuracy of postoperative lung infections, provided a time-sensitive and anatomically directed basis for clinical intervention decisions, improved the interpretability of prediction results and the accuracy of early warning, and reduced unnecessary antibiotic use and medical costs.
Smart Images

Figure CN120656724A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of medical data mining, and in particular to a prediction method and system for postoperative lung infection. Background Art
[0002] The field of medical data mining encompasses the entire process of collecting, organizing, analyzing, and mining medical and health-related data using computing technology. The core of this technology lies in the modeling of disease trends, identification of risk factors, and assessment of patient prognosis through the processing of a variety of medical data, including structured and unstructured clinical data, test results, electronic medical records, imaging data, and genomic information. The entire medical data mining technology system encompasses data collection, data cleaning, feature extraction, model building, and evaluation. It involves the fusion processing of multi-source heterogeneous data, the automatic annotation of clinical events, and the establishment of disease prediction models. It is widely used in scenarios such as early disease screening, risk identification, and personalized health management support.
[0003] Among them, a method for predicting postoperative lung infection refers to predicting whether a patient will develop a lung infection by comprehensively analyzing multiple clinical data of postoperative patients and using specific medical data processing technology. The technical matters of this topic cover the collection of clinical data of postoperative patients, the screening and identification of infection risk factors, and a comprehensive evaluation method based on multi-dimensional data such as the patient's physiological state and postoperative recovery. Specifically, by collecting the clinical manifestations, laboratory test data and imaging examination results of postoperative patients, combined with statistical methods or machine learning technology, a prediction model for lung infection is constructed, thereby achieving early warning of the patient's infection risk.
[0004] Existing technologies for assessing postoperative infection risk rely heavily on laboratory indicators and imaging features at discrete time points, lacking the ability to monitor continuous dynamic changes in respiratory physiological parameters. This makes it difficult to capture early compensatory abnormalities. Traditional methods use fixed thresholds or single-dimensional statistical models to screen risk factors, but they are unable to effectively resolve temporal correlations and nonlinear interactions between multiple parameters, leading to missed detection of key early warning signals. Clinical data fusion often overlooks the role of anatomical structures in constraining the spread of infection. Feature extraction favors global statistics while ignoring local functional abnormalities, resulting in a lack of spatial resolution in prediction results. Existing models often output probabilistic values or binary classification labels, failing to map infection risk to specific anatomical lung segments, making it difficult for clinicians to formulate precise targeted treatment plans. For example, while predictive models based on logistic regression can identify high-risk patients, they cannot pinpoint the initial lung segment of infection, leading to a wider range of prophylactic antibiotic use, increased risk of drug resistance, and increased healthcare costs. Summary of the Invention
[0005] In order to solve the problem that the existing technology for assessing the risk of postoperative infection mostly relies on laboratory indicators and imaging features at discrete time points, and lacks the ability to monitor the continuous dynamic changes of respiratory physiological parameters, resulting in the difficulty of timely capturing early compensatory abnormalities. Traditional methods use fixed thresholds or single-dimensional statistical models to screen risk factors, which cannot effectively analyze the temporal correlation characteristics and nonlinear interactions between multiple parameters, resulting in missed detection of key warning signals. In the process of clinical data fusion, the constraining effect of anatomical structure on the spread of infection is often ignored, and feature extraction tends to focus on global statistics while ignoring local functional abnormalities, resulting in a lack of spatial resolution in the prediction results. The output of existing models is mostly probabilistic values or binary classification labels, and the mapping relationship between infection risk and the anatomical position of specific lung segments has not been established. It is difficult for clinicians to formulate accurate targeted treatment plans based on this. For example, although the prediction model based on logistic regression can identify high-risk patients, it cannot locate the lung segment where the infection starts, resulting in the expansion of the scope of prophylactic antibiotic use, increasing the risk of drug resistance and medical costs for patients. The embodiment of the present invention provides a method and system for predicting postoperative lung infection. The technical solution is as follows:
[0006] In one aspect, a method for predicting postoperative pulmonary infection is provided, the method comprising: S1: Obtain daily tidal volume, blood oxygen saturation, and respiratory rate time series data of postoperative patients through respiratory monitoring equipment, establish a unified time axis, and use linear interpolation to align and complete the timestamps of the three sets of data to generate a timestamp-aligned dataset; S2: Input the timestamp aligned dataset into a sliding window mechanism, perform multi-scale respiratory signal analysis, calculate the time interval between the inflection point of tidal volume change and the inflection point of blood oxygen saturation response, and output a respiratory response delay feature set; S3: Based on the respiratory response delay feature set, a local abnormality factor algorithm is used to evaluate the abnormality of the lung segment delay feature, and lung segments whose abnormality scores exceed the lung segment delay percentile value are marked to obtain a delay abnormal lung segment set; S4: Based on the delayed abnormal lung segment set, the average tidal volume, the rate of increase of blood oxygen saturation, and the preoperative lung segment volume parameters are extracted, and the feature vectors are spliced with the intraoperative ventilation pressure parameters. The feature vectors are input into the kernel principal component analysis model, the principal component feature vectors are extracted and the coordinates are mapped in the spatial lung segment atlas to generate a spatial probability distribution map of lung segment infection.
[0007] As a further solution of the present invention, the window size and step size of the sliding window mechanism are set according to the data sampling rate, physiological delay characteristics and task requirements, with the window size being 12 seconds and the step size being 2 seconds; The number of neighbors of the local anomaly factor algorithm is empirically set based on the lung segment sample size and local density distribution characteristics; The unit of the average tidal volume is mL, the unit of the rate of increase of blood oxygen saturation is bpm, the unit of the preoperative lung segment volume parameter is mL, and the unit of the intraoperative ventilation pressure is cmH2O. Z-score standardization is performed on each of them to make them dimensionless parameters. The timestamp aligned dataset includes a unified time axis, interpolated data points, and synchronized time series data. The respiratory response delay feature set includes the tidal volume inflection point time, the blood oxygen response inflection point time, and the time interval between inflection points. The delayed abnormal lung segment set specifically includes the abnormal score lung segment number, the corresponding delay feature value, and the abnormal judgment label. The lung segment infection spatial probability distribution map includes the principal component space coordinates, the lung segment mapping position, and the infection probability value.
[0008] As a further solution of the present invention, the specific steps of S1 include: S101: Obtain daily tidal volume, blood oxygen saturation, and respiratory rate time series data of postoperative patients through respiratory monitoring equipment, call the original data acquisition timestamp, parse the sampling interval to filter out non-second-level data, establish a unified second-level time axis, fill in the missing time point null value markers, and generate a time axis construction value sequence; S102: constructing a value sequence based on the time axis, calling the previous and next sampling values and the corresponding time for the null value time points of tidal volume, blood oxygen saturation, and respiratory rate, estimating the missing values according to the linear interpolation formula, and generating a single set of data completion value sequence; S103: Completing the numerical sequence based on the single set of data, synchronizing the three sets of parameters at multiple time points second by second, pairing the tidal volume, blood oxygen saturation, and respiratory rate in timeline order, and generating a timestamp-aligned data set.
[0009] As a further solution of the present invention, the specific steps of S2 include: S201: calling the tidal volume, blood oxygen saturation and respiratory rate values per second in the timestamp alignment data set, setting the multi-scale sliding window length and step size, dividing the tidal volume sequence and sliding to extract the local increase and decrease direction and difference, marking the inflection point where the trend turns, and generating a tidal volume inflection point mark sequence; S202: calling the tidal volume inflection point mark sequence and the original blood oxygen saturation sequence, extracting the blood oxygen saturation within a specified range after each tidal volume inflection point, performing first-order difference, locating the response inflection point and matching the corresponding tidal volume inflection point, and generating a respiratory event response pairing index sequence; S203: converting the paired inflection point timestamp differences in the respiratory event response paired index sequence into a unified unit and determining whether they fall within a preset screening interval, retaining valid samples, and calculating the distribution trend of the remaining time differences to obtain a respiratory response delay feature set; The preset screening interval is [0.5s, 3s], which is set based on clinical and physiological common sense.
[0010] As a further solution of the present invention, the specific steps of S3 include: S301: Based on the respiratory response delay feature set, a delay value sequence within each lung segment is selected as input data, and input into a local outlier factor algorithm to establish a distance relationship model of the delay values, estimate the neighborhood density of the lung segment, and calculate the local outlier factor score to generate a lung segment delay outlier score; S302: Based on the lung segment delay outlier score, the score data is sorted from small to large and the numerical distribution is calculated. The percentile value of the score sequence in the high interval is extracted as a judgment benchmark. The lung segment score is then compared to see whether it exceeds the percentile value to obtain a delay score exceeding limit identification set; S303: calling the delay score excess identification set, matching the number information of the excess lung segments, extracting the corresponding data from the original feature set and classifying and integrating them to generate a delay abnormal lung segment set.
[0011] As a further solution of the present invention, the specific steps of S4 include: S401: Based on the delayed abnormal lung segment set, extract the mean tidal volume, blood oxygen saturation rise rate, preoperative lung segment volume and intraoperative ventilation pressure value, unify the numbering and perform normalization processing according to the Z-score method to generate a standardized feature parameter group; S402: Constructing a four-dimensional feature vector set based on the standardized feature parameter group, calling a kernel principal component analysis model to perform nonlinear mapping and principal component extraction, sorting and screening the first two groups of principal components based on contribution rates, and obtaining lung segment principal component vector coefficients; S403: Call the principal component vector coefficient of the lung segment, perform coordinate matching in the atlas in combination with the lung segment number, calculate the infection probability based on the principal component density value in the region, and perform probability stacking synthesis to obtain a spatial probability distribution map of lung segment infection.
[0012] As a further embodiment of the present invention, the method includes step S5: S5: For lung segments with a mapping probability within the risk zone threshold interval in the spatial probability distribution map of lung segment infection, extract the three-day coefficient of variation of respiratory rate and tidal volume, perform classification boundary calculation and risk weight regression analysis using a logistic regression model, output the confidence index and risk label corresponding to each target lung segment, and summarize and generate a postoperative lung infection warning list; The postoperative lung infection warning list specifically refers to the target lung segment number, confidence index, and risk level label.
[0013] As a further solution of the present invention, the specific steps of S5 include: S501: Based on the mapped probability data in the spatial probability distribution map of the lung segment infection, the lung segment numbers and coordinates within the infection risk area threshold interval are screened, the respiratory monitoring data are matched, and the respiratory frequency and tidal volume sequences of the corresponding lung segment within three days are extracted. The sequence fluctuation amplitude and central trend deviation are calculated to obtain the respiratory fluctuation coefficient group value; The infection risk area threshold interval is a probability value ≥ 0.7, and the interval is set based on the probability density characteristics and statistical distribution curve in the lung segment infection space probability distribution map; S502: Using the respiratory fluctuation coefficient group value as an input variable, constructing a logistic regression model and fitting weight parameters corresponding to the input items, outputting a prediction confidence level based on the training sample, and generating a risk confidence value; S503: Based on the risk confidence value, the risk level is determined by setting a classification standard according to the threshold interval, and the risk label is integrated with the lung segment number and confidence data to generate a postoperative lung segment risk warning list.
[0014] As a further embodiment of the present invention, the respiratory fluctuation coefficient group value is calculated using the formula: ; in, Representative The respiratory fluctuation coefficient group value of each lung segment is an important input parameter of the subsequent logistic regression model. represents the respiratory rate coefficient, represents the tidal volume coefficient, satisfying , Representative The lung segment Respiratory rate data at each time point, in bpm, Representative The average respiratory rate data of each lung segment within three days, in bpm, Representative The lung segment Tidal volume data at each time point, in mL, Representative The average value of tidal volume data for each lung segment within three days, in mL, Representative The maximum respiratory rate of each lung segment within three days, in bpm, is normalized to a dimensionless parameter. Representative The minimum value of tidal volume of each lung segment within three days, in mL, is normalized to a dimensionless parameter. Representative The covariance coefficient of respiratory rate and tidal volume of each lung segment within three days represents the cooperativity of parameter fluctuations. Representative The phase synchronization disturbance index of each lung segment represents the normalized value of the average delay difference between tidal rise and blood oxygen response.
[0015] In another aspect, a system for predicting postoperative pulmonary infection is provided. The system for predicting postoperative pulmonary infection is used to implement the above-mentioned method for predicting postoperative pulmonary infection. The system comprises: The data alignment module is used to obtain the time series data of tidal volume, blood oxygen saturation and respiratory rate through the respiratory monitoring equipment, align the timestamps according to the second-level time axis using linear interpolation, generate a timestamp-aligned data set, and pass it to the multi-scale analysis module; a multi-scale analysis module, configured to align the data set according to the timestamps, input the data set into a sliding window mechanism for multi-scale signal analysis, calculate the time interval between the inflection point of the tidal volume change and the inflection point of the blood oxygen saturation response, generate a respiratory response delay feature set, and transmit the feature set to the anomaly detection module; An anomaly detection module is used to input the respiratory response delay feature set into a local anomaly factor algorithm, evaluate the degree of abnormality of the delay feature, screen lung segments with abnormal scores exceeding the percentile value, obtain a set of lung segments with abnormal delays, and pass it to the infection modeling module; An infection modeling module is used to obtain the average tidal volume, blood oxygen saturation rise rate, preoperative lung segment volume and intraoperative ventilation pressure based on the delayed abnormal lung segment set, splice them into a feature vector, input it into the kernel principal component analysis model to extract the principal components and map the coordinates, generate a spatial probability distribution map of lung segment infection, and transmit it to the risk identification module; The risk identification module is used to map the lung segment numbers and coordinates whose probabilities are within the threshold range in the spatial probability distribution map of lung segment infection, calculate the fluctuation amplitude and trend deviation, input them into the logistic regression model for classification boundary calculation and weight fitting, output the risk confidence value and risk label, and generate a postoperative lung segment risk warning list.
[0016] The beneficial effects brought about by the technical solution provided by the embodiment of the present invention include at least: Timestamp alignment and completion techniques unify multidimensional respiratory monitoring data to the same time base, eliminating data gaps caused by differences in acquisition frequency and improving the reliability of temporal feature correlation analysis. A multiscale sliding window mechanism captures the dynamic coupling between tidal volume changes and blood oxygen saturation responses. By calculating respiratory response delay characteristics, it overcomes the limitations of traditional static threshold judgments and enables quantitative assessment of respiratory compensation capacity. A local abnormality factor algorithm, combined with segmental delay quantile screening, precisely locates areas of local functional abnormality, avoiding the masking of local lesion features by global abnormality detection. Multimodal feature vector splicing fuses physiological parameters and anatomical data. A kernel principal component analysis model maps high-dimensional features to a spatial lung segment atlas, establishing an explicit association between infection risk and spatial distribution and enhancing the interpretability of prediction results. This technical approach, through a three-step progressive mechanism of temporal dynamic analysis, local abnormality identification, and spatial probabilistic modeling, significantly improves the timeliness and spatial localization accuracy of postoperative lung infection prediction, providing a time-sensitive and anatomically targeted decision-making basis for clinical intervention. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 It is a schematic diagram of the workflow of the present invention; Figure 2 It is a system flow chart of the present invention. DETAILED DESCRIPTION
[0018] The technical solution of the present invention is described below in conjunction with the accompanying drawings.
[0019] In the embodiments of the present invention, words such as "exemplarily" and "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as an "exemplary" in the present invention should not be interpreted as being preferred or advantageous over other embodiments or designs. Rather, the use of the word "exemplary" is intended to present concepts in a concrete manner. Furthermore, in the embodiments of the present invention, "and / or" can mean both or either of the two.
[0020] In the embodiments of the present invention, the terms "image" and "picture" may sometimes be used interchangeably. It should be noted that, when the distinction is not emphasized, the meanings they convey are the same. The terms "of," "corresponding," and "corresponding" may sometimes be used interchangeably. It should be noted that, when the distinction is not emphasized, the meanings they convey are the same.
[0021] In the embodiments of the present invention, sometimes a subscript such as W1 may be written as a non-subscript such as W1. When the difference is not emphasized, the meanings to be expressed are the same.
[0022] In order to make the technical problems, technical solutions and advantages to be solved by the present invention clearer, a detailed description will be given below with reference to the accompanying drawings and specific embodiments.
[0023] See also Figure 1 The embodiment of the present invention provides a method for predicting postoperative lung infection. The processing flow of the method may include the following steps: S1: Obtain daily tidal volume, blood oxygen saturation, and respiratory rate time series data of postoperative patients through respiratory monitoring equipment, establish a unified time axis, and use linear interpolation to align and complete the timestamps of the three sets of data to generate a timestamp-aligned dataset; S2: Input the timestamp aligned dataset into the sliding window mechanism to perform multi-scale respiratory signal analysis, calculate the time interval between the inflection point of tidal volume change and the inflection point of blood oxygen saturation response, and output the respiratory response delay feature set; S3: Based on the respiratory response delay feature set, the local abnormality factor algorithm is used to evaluate the abnormality of the lung segment delay feature. The lung segments with abnormal scores exceeding the lung segment delay percentile value are marked to obtain the delay abnormal lung segment set. S4: Based on the delayed abnormal lung segment set, the average tidal volume, blood oxygen saturation rise rate, and preoperative lung segment volume parameters are extracted and concatenated with the intraoperative ventilation pressure parameters to form feature vectors. The feature vectors are then input into the kernel principal component analysis model, and the principal component feature vectors are extracted and mapped to the spatial lung segment atlas to generate a spatial probability distribution map of lung segment infection. S5: For lung segments with a mapping probability within the risk zone threshold interval in the spatial probability distribution map of lung segment infection, extract the three-day coefficient of variation of respiratory rate and tidal volume. Perform classification boundary calculation and risk weight regression analysis using a logistic regression model. Output the confidence index and risk label corresponding to each target lung segment, and summarize and generate a postoperative lung infection warning list. The timestamp aligned dataset includes a unified time axis, interpolated data points, and synchronized time series data. The respiratory response delay feature set includes the tidal volume inflection point time, the blood oxygen response inflection point time, and the time interval between inflection points. The delayed abnormal lung segment set specifically includes the abnormal score lung segment number, the corresponding delay feature value, and the abnormal judgment label. The lung segment infection spatial probability distribution map includes the principal component space coordinates, the lung segment mapping position, and the infection probability value. The postoperative lung infection warning list specifically refers to the target lung segment number, confidence index, and risk level label.
[0024] Specifically, the steps of S1 are: S101: Obtain daily tidal volume, blood oxygen saturation, and respiratory rate time series data of postoperative patients through respiratory monitoring equipment, call the original data acquisition timestamp, parse the sampling interval to filter out non-second-level data, establish a unified second-level time axis, fill in the missing time point null value markers, and generate a time axis construction value sequence; The respiratory monitoring equipment is used to obtain the daily tidal volume time series data, blood oxygen saturation time series data, and respiratory rate time series data of postoperative patients. The process must first determine that the equipment acquisition method is recorded in seconds, that is, each record in the original data should have a clear timestamp field, using a time format such as "05-29-08:01:12". For each type of monitoring data, the record items are exported separately, the corresponding timestamp column and data column are extracted, the difference between adjacent timestamps is calculated, and a sampling interval sequence is generated. The array form of seconds is used to determine whether there is a non-second sampling interval. For example, if a certain segment of data has an interval of 120m s, 350ms or 1500ms, that is, non-integer second interval records, are compared with the array difference and 1, and the data points corresponding to the difference records that are not equal to 1 are screened out and their corresponding timestamps are removed. Then, a continuous second-level time axis is constructed with the remaining valid timestamps, that is, a total of 86,400 time points from 00:00:00 to 23:59:59 every day. For each type of monitoring data, its original sampling timestamp is used as the benchmark and matched according to the second-level time axis. If no data is collected in the corresponding second, the null value NaN is filled in at this time point to indicate the missing data. The constructed tidal volume, blood oxygen saturation, and respiratory rate data should all be long The array index is the sequential value corresponding to the second-level time axis. For example, if the patient's tidal volume monitoring records between 10:00:00 and 10:00:05 on a certain day are: 500mL, 510mL, NaN, NaN, 530mL, 540mL, then the corresponding timestamp is 6 seconds. Among them, the 3rd and 4th seconds have no recorded data and need to be filled with null values. The final array is [500, 510, NaN, NaN, 530, 540]. The same processing logic is applicable to blood oxygen saturation and respiratory rate data; further explain the screening process of non-second-level data, by traversing the original data Timestamp difference array. If the time difference between two consecutive data points is not equal to 1 second, such as the difference between 09:12:14.120 and 09:12:15.470 is 1.35 seconds, then the data is non-second-level data and needs to be deleted from the original data without time axis mapping. When constructing a unified second-level time axis, the daily start time 00:00:00 is used as the first time point, and the time array is increased second by second to generate a time array consisting of 86,400 elements. This array is used as the index to establish a sequence framework for the three types of monitoring values. Data points that cannot be filled with original values are filled with NaN to form an initial sequence containing missing points.
[0025] Table 1: Original sampling sample table of monitoring data Timestamp Tidal volume (mL) Blood oxygen saturation (%) Respiratory rate (times / minute) 05-29-10:00:00 500 97 18 05-29-10:00:01 510 96 17 05-29-10:00:04 530 95 19 05-29-10:00:05 540 96 20
[0026] As shown in Table 1, the two time points 10:00:02 and 10:00:03 are missing in the original data and need to be filled in when constructing the timeline.
[0027] S102: Constructing a value sequence based on the time axis, for the null value time points of tidal volume, blood oxygen saturation, and respiratory rate, calling the previous and subsequent sampling values and the corresponding time, estimating the missing values using a linear interpolation formula, and generating a single set of data completion value sequences; Based on the time axis, a value sequence is constructed. For the null value time points of tidal volume, blood oxygen saturation and respiratory rate, the position of the NaN value in each sequence is determined in turn. The valid data points before and after NaN and their timestamps are extracted and calculated by linear interpolation. The specific execution process is as follows: If the first The tidal volume per second is NaN, and The second value is , The second value is , then the interpolation value is For example, in the above tidal volume sequence [500, 510, NaN, NaN, 530, 540], the 3rd and 4th seconds are NaN. , , then the value at the 3rd second is estimated to be , and then and The interpolation value at the 4th second is , that is, the missing segment is estimated by the mean of the preceding and following non-missing points; if the missing points are multiple consecutive NaNs, multiple linear interpolations need to be performed according to equal intervals, for example, if The time is 510, The time is 540, and the three NaNs in the middle are divided into three equal parts in linear increments, namely 、 、 , that is, Seconds is 520, Seconds is 530, The number of seconds is 540. After interpolation, a completed data sequence without NaN is generated. The same completion operation is performed on blood oxygen saturation and respiratory rate respectively. It should be noted that blood oxygen saturation is an integer value, and its range is generally between 90% and 100%. If the result exceeds the interval after interpolation, it should be truncated. For example, if the interpolation result is 100.4%, it should be taken as 100%. The unit of respiratory rate is beats / minute, and the normal range is 1220 beats / minute. If the interpolation result is 10 or 23, it should be adjusted to 12 or 20 respectively to ensure the rationality of the value.
[0028] S103: Completing the numerical sequence based on the single set of data, synchronizing the three sets of parameters at multiple time points second by second, pairing the tidal volume, blood oxygen saturation, and respiratory rate in timeline order, and generating a timestamp-aligned data set; According to the single set of data to complete the numerical sequence, call the three types of monitoring values corresponding to the second-level time axis index, read multiple data seconds by array index sequence, and generate a triple sequence structure respectively, that is, construct a set of The data index is mapped to the array subscript to achieve second-by-second alignment. For example, at the 300th second, the tidal volume is 520 mL, the blood oxygen saturation is 96%, and the respiratory rate is 18 breaths / minute. The second combination is [520, 96, 18]. 86,400 time points are traversed and the three types of data are filled in sequentially to form a complete timestamp-aligned data set. Each data set is a triple data point with a timestamp, such as "05-29-00:05:00: [520, 96, 18]". If a time point still has a null value, it is retained as NaN, for example, "05-29-00:10:35: [NaN, 97, 19]". The data is saved in a matrix format in the form of a list or array, where the rows are time points and the columns are the three types of parameters, forming an 86,400-row × 3-column matrix structure, which can be used for further statistical analysis or feature extraction.
[0029] Specifically, the steps of S2 are: S201: Call the timestamp alignment data set to align the tidal volume, blood oxygen saturation, and respiratory rate values per second, set the multi-scale sliding window length and step size, divide the tidal volume sequence, and slide to extract the local increase and decrease direction and difference, mark the inflection point where the trend turns, and generate a tidal volume inflection point mark sequence; The window size and step size of the sliding window mechanism are set according to the data sampling rate, physiological delay characteristics and task requirements. The window size is 12 seconds and the step size is 2 seconds. First, the timestamps are aligned with the tidal volume, blood oxygen saturation, and respiratory rate data one by one, and a complete time series is established based on the sampling frequency per second. The tidal volume, blood oxygen saturation, and respiratory rate at each time point are stored as independent vectors in the cache array by traversing the records in the data table. Then, the window size of the sliding window is set to 12 seconds, with a step size of 2 seconds. The tidal volume sequence is divided according to the sliding window parameters. For example, the tidal volume sequence from timestamps 0s to 12s is [500, 520, 510, 480, 490, 530, 500], with a total of 7 sampling points. If the sampling rate is 1Hz, each 12-second window contains 12 points. Missing data points are filled by zero padding or neighboring value interpolation to ensure the uniformity of the sliding window length. The sliding window advances in units of 2 seconds, and the tidal volume change sequence in the window is extracted starting from time points 0s, 2s, 4s... Next, the monotonicity analysis of the tidal volume sequence in each sliding window is performed, and the adjacent point difference is used. The local increase and decrease direction is extracted by this method, that is, the difference sign (ΔTV) between two adjacent points in each sequence is calculated. For example, the difference in [500, 520, 510] is [+20, -10], and the corresponding direction is [+1, -1]. Then, the turning point is detected according to the position of the direction change, and the turning point is marked at the position where the direction changes from positive to negative or negative to positive. The direction switching threshold is set to prevent misjudgment caused by small disturbances. For example, the inflection point judgment difference threshold is set to ±10mL. If the absolute value of the difference is If the value is less than the threshold, it is not recorded as an inflection point. Taking a threshold of 10 mL as an example, the value [+8, +7, -2] in the sequence [500, 508, 515, 513] is not marked as an inflection point because the change is less than the threshold. Finally, the inflection point timestamp detected in each sliding window is recorded as an element of the inflection point sequence. For example, if a trend reversal is detected at 4s and 10s in the window [0s-12s], the tidal volume inflection point mark sequence [4, 10] is generated, thus completing the inflection point extraction operation.
[0030] Table 2: Respiratory monitoring data table Timestamp(s) Tidal volume (mL) Blood oxygen saturation (%) Respiratory rate (times / min) 0 500 98 16 2 520 97 17 4 510 97 17 6 480 96 18 8 490 95 17 10 530 95 16 12 500 96 16
[0031] As shown in Table 2, monitoring data with a sampling interval of 2 seconds can be used for sliding window processing. The trend of tidal volume change is clearly reflected at 4 seconds (decline), 6 seconds (lowest point), and 10 seconds (rise again). Through the difference and direction change judgment strategy, 4 seconds and 10 seconds can be successfully marked as tidal volume inflection points.
[0032] S202: Calling the tidal volume inflection point marker sequence and the original blood oxygen saturation sequence, extracting the blood oxygen saturation within a specified range after each tidal volume inflection point, performing first-order difference, locating the response inflection point and matching the corresponding tidal volume inflection point, and generating a respiratory event response pairing index sequence; First, extract the inflection point timestamps in the generated tidal volume inflection point sequence in sequence. For example, the current inflection point timestamp set is = , set the data window according to the specified range after each inflection point. For example, if the extraction range is set to 0~5 seconds after the inflection point, then extract the blood oxygen saturation sequence within 5 seconds after each inflection point t. Combined with the data in Table 2, the corresponding interval extracted when t=4 seconds is ], the blood oxygen saturation sequence is , perform the first-order difference operation on the extracted blood oxygen saturation sequence, that is, calculate the difference ΔSpO2 between adjacent points, and the difference result is Since the continuous differences are all negative, it means that the blood oxygen level continues to decline in this interval. Therefore, the position with the largest drop in this decline segment, that is, the point with the largest absolute value of the difference, is marked as the response inflection point. If there are multiple minimum points with equal differences, the earliest one is selected. Similarly, the interval after the inflection point t=10 seconds is extracted. , blood oxygen saturation is , the first-order difference result is Because a positive difference represents an upward trend, it is not treated as a downward response inflection point. The inflection point is not successfully matched and is eliminated. Subsequently, each extracted blood oxygen saturation change inflection point is paired with its corresponding tidal volume inflection point one by one to form a paired index pair. For example, a tidal volume inflection point of 4 seconds corresponds to a blood oxygen inflection point of 6 seconds, which is recorded as (4, 6). If there is no blood oxygen inflection point response, the tidal volume inflection point is excluded. Finally, a complete index sequence of tidal volume inflection points and blood oxygen response inflection points is formed, which serves as the basic data structure for subsequent respiratory event response delay analysis.
[0033] S203: converting the paired inflection point timestamp differences in the respiratory event response paired index sequence into a unified unit and determining whether they fall within a preset screening interval, retaining valid samples, and calculating the distribution trend of the remaining time differences to obtain a respiratory response delay feature set; The preset screening interval is [0.5s, 3s], which is set based on clinical and physiological common sense; First, traverse each group of indexes in the respiratory event response paired index sequence, for example, the index pair (4, 6) extracts the tidal volume inflection point timestamps as seconds, the blood oxygen saturation response inflection point is seconds, calculate the time difference Δt= Seconds, the time difference is uniformly expressed in seconds, and an interval judgment is made for each Δt value, and it is compared with the system preset screening interval. Compare, if it falls within the range, record it as a valid delay sample, otherwise remove it, for example, the current Δt = 2 seconds, it is within the valid interval and is retained, if a pair difference is 4 seconds, then the pair is removed, the retained Δt sample set is summarized to form a complete delay time array, if there is only one sample Δt = 2 seconds, on this basis, perform statistical distribution analysis on the array, if the number of samples is sufficient, the distribution histogram can be used to count the sample frequency in the differentiated time period, otherwise list the time difference list and count the number of occurrences based on the frequency, for example, in the sample set It is divided into time periods of 0.5 seconds each, and the number of samples in multiple segments is counted. The final time difference distribution trend is the respiratory response delay feature set, which is used for subsequent physiological state analysis and timing response modeling.
[0034] Specifically, the steps of S3 are: S301: Based on the respiratory response delay feature set, a delay value sequence within each lung segment is selected as input data and input into a local outlier factor algorithm to establish a distance relationship model for the delay values, estimate the neighborhood density of the lung segment, and calculate the local outlier factor score to generate a lung segment delay outlier score. Based on the respiratory response delay feature set, it is necessary to select the delay value sequence of each lung segment as the basic data. First, for the 18 lung segments of a complete lung, the delay response data collected during the breathing process of each segment are time-series processed to ensure that the sampling frequency is 5 times per second (ie 5Hz). Assuming that each detection cycle is 60 seconds, 300 delay value data points will be obtained for each segment. For example, the sampling data of the right upper lung segment (RS1) is {0.32, 0.35, 0.34, ..., 0.41} seconds. The delay value is the time from the exhalation trigger point to the real-time start of gas exchange in the lung segment, and the value range should be controlled between [0.2, 0.6] seconds; then this sequence is input into a measurement process based on the distance relationship between adjacent data points, and the Euclidean distance between it and other lung segment delay sequences is calculated to define each data point and its k nearest neighbors The distance set is ,in Represents the length of the time series. The action needs to be performed segment by segment. Each lung segment will be used as a reference sequence in turn, and the distances between each of the other 17 segments will be compared. For example, 17 sets of distances are calculated between RS1 and LS1, LS2, RS2, etc. Next, these distance results are sorted, and the points associated with the first k shortest distances are extracted to form its neighborhood. When k=5, for example, the neighborhood distance set of RS1 is {0.014, 0.018, 0.021, 0.025, 0.030}, and its local reachability density is calculated, which is defined as the inverse of the average reachable distance from the point to each point in the neighborhood, that is, ,in is the maximum value function, take , used to avoid abnormal amplification caused by sparse edge points. Assuming that the k-distance is 0.028, the reach distance of one point is , and the final density is , further by comparing the point The density ratio of its neighboring points is used to calculate the local outlier factor score, which is defined as: ; Assume that the local densities of the five points in the RS1 neighborhood are [42.6, 38.5, 40.1, 37.8, 39.2], then the LOF of RS1 is: ; As shown in the above example, when the LOF of a lung segment exceeds 1.5, it can be determined as a delay outlier segment. The final lung segment calculation results generate the delay outlier score values shown in the following table: Table 3: Delayed Outlier Scoring Table Lung segment number Average latency (seconds) Neighborhood average distance Local density (lrd) LOF score RS1 0.35 0.0256 39.06 1.016 RS2 0.42 0.0312 32.05 1.542 LS1 0.31 0.0213 45.67 0.976 LS2 0.29 0.0221 44.21 0.902 RS3 0.47 0.0345 29.01 1.783
[0035] As shown in Table 3, by establishing a distance model for the delay value of each lung segment, calculating the neighborhood density and outlier score, the basic data for the next step of screening whether the lung segment has abnormal delay is obtained.
[0036] S302: Based on the outlier lung segment delay scores, the score data is sorted from small to large and the numerical distribution is calculated. The quantile of the score sequence in the high interval is extracted as a judgment benchmark. The lung segment score is then compared to see if it exceeds the quantile, thereby obtaining a delay score exceeding limit identification set. According to the LOF score results of the lung segments in Table 3, the LOF score values of the lung segments are first sorted in ascending order to form a continuous sorting sequence. , the sorting action depends on the one-by-one comparison process of the lung segment LOF scores. For example, RS3's 1.783 is compared with RS2's 1.542 to determine the larger value, and then compared with RS1's 1.016 and continued to sort, finally obtaining the complete sequence. Next, the sequence is subjected to numerical distribution analysis. The analysis action depends on interval division and quantile extraction. The sequence is divided into 4 equally spaced quantile intervals, corresponding to the 25th percentile, 50th percentile, 75th percentile and 100th percentile, that is, the 2nd, 3rd, 4th and last data in the sequence are extracted as quantile values, which are 0.976, 1.016, 1.542 and 1.783 respectively. The 75th percentile 1.542 is set as the delay anomaly judgment benchmark. The setting refers to the critical value selection logic of the upper quarter interval in the current sequence. The specific setting is based on ensuring that the delay outlier falls into the higher tail area to ensure the sensitivity of the abnormal point judgment. This value is determined by The fourth score value, namely the score of RS2, is directly read out; the LOF score of the lung segment is then numerically compared with this percentile value in turn to determine whether the score of a lung segment is greater than 1.542. If this condition is met, the number information and identification value 1 corresponding to the lung segment are added to the delay score exceeding limit identification set, otherwise the identification value 0 is added. For example, the score of RS3 is 1.783, which is higher than the benchmark value of 1.542. RS3 is marked as an exceeding limit segment and recorded as (RS3, 1). The score of RS2 is equal to 1.542, but because the judgment rule is "exceeding", it does not belong to the exceeding limit and is marked as (RS2, 0). The final identification set forms the following array sequence: [(RS1, 0), (RS2, 0), (LS1, 0), (LS2, 0), (RS3, 1)]. In this way, the binarization processing of whether the lung segment delay outlier value exceeds the limit is completed, ensuring that the abnormal lung segment can be extracted and the data integration can be completed according to the identification set in the future.
[0037] S303: calling the delay score exceeding limit identification set, matching the number information of the exceeding limit lung segments, extracting the corresponding data from the original feature set, classifying and integrating them, and generating a delay abnormal lung segment set; The obtained delay score over-limit identification set is called, and the number information is first extracted with the lung segment with an identification value of 1 as the screening condition. The extraction action traverses the lung segment records in the identification set one by one, and determines whether the second item in each record is equal to 1. If so, the corresponding number is extracted to the new set. For example, in the array [(RS1, 0), (RS2, 0), (LS1, 0), (LS2, 0), (RS3, 1)], only RS3 meets the condition, and the extracted number result is {RS3}; then, data is extracted from the original respiratory response delay feature set based on the number information of RS3. First, it is mapped to the original feature dictionary or array structure according to the number. For example, the delay sequence corresponding to RS3 in the original structure is {0.43, 0.44, 0.45, ..., 0.47}, and save the sequence as an independent subset after extraction; if there are multiple out-of-limit numbers, the corresponding data will be extracted separately to form multiple subsets. For example, if RS2 is subsequently identified as out of limit, the delayed sequence {0.40, 0.42, 0.43, …, 0.45} of RS2 needs to be extracted and classified at the same time; after the extraction is completed, the subset data needs to be uniformly classified and integrated, and the classification action is grouped by the lung segment number prefix or the left and right lung attributes. For example, the numbers starting with RS are uniformly classified into the right lung abnormal segment set, and the numbers starting with LS are classified into the left lung abnormal segment set. Finally, a delayed abnormal lung segment set is generated, which has a typical word data structure, such as {right lung: [RS3]}, and there is no abnormal segment in the left lung, to ensure that it can be used for abnormal annotation reference in subsequent clinical evaluation or visualization rendering stage.
[0038] Specifically, the steps of S4 are: S401: Based on the delayed abnormal lung segment set, extract the mean tidal volume, blood oxygen saturation rise rate, preoperative lung segment volume and intraoperative ventilation pressure value, unify the numbering and perform normalization processing using the Z-score method to generate a standardized feature parameter group; Based on the delayed abnormal lung segment set {right lung: [RS3]}, the four physiological parameter data corresponding to RS3 are first extracted, namely the mean tidal volume, the rate of increase of blood oxygen saturation, the preoperative lung segment volume and the intraoperative ventilation pressure value. When performing the extraction operation, the lung segment number "RS3" is used as the index and mapped to the data record of the corresponding parameter one by one. The operation of extracting the mean tidal volume is to read the tidal volume sequence in the RS3 monitoring records and take its arithmetic mean. For example, the tidal volume sequence of RS3 during intraoperative monitoring is {460, 470, 455, 465} (unit: mL), and the calculated mean is To extract the rate of increase of blood oxygen saturation, we need to first select the blood oxygen saturation sequence within 15 minutes after anesthesia induction, take the difference between the first and last values and divide it by the time difference. If the initial value is 93.2% and the final value is 97.8%, the rate of increase is The preoperative lung segment volume is obtained through chest CT imaging analysis. For example, the preoperative volume of RS3 is 650 mL. The intraoperative ventilation pressure value is obtained through the anesthesia machine data interface. If the average ventilation pressure of RS3 is 18.2 cmH2O, the four parameters are numbered X1 to X4 in the following order after extraction and Z-score normalization is performed. The Z-score normalization operation is performed according to the following general formula: ; in, For a certain original value, is the average value of the parameter in the lung segment, is the standard deviation of the parameter; for example, for tidal volume, if the mean value of all abnormal lung segments is 470 mL and the standard deviation is 10.5 mL, the RS3 tidal volume standardization result is: ; For the rate of increase of blood oxygen saturation, if the mean is 0.312% / min and the standard deviation is 0.018, then ; Similarly, the standardized values of volume and ventilation pressure can be obtained: ; The final standardized characteristic parameter group of RS3 is {Z1=-0.714, Z2=-0.294, Z3=-1.0, Z4=0.778}.
[0039] S402: Based on the standardized feature parameter group, a four-dimensional feature vector set is constructed, and a kernel principal component analysis model is used to perform nonlinear mapping and principal component extraction. The first two groups of principal components are sorted and filtered according to contribution rates to obtain the lung segment principal component vector coefficients; The standardized feature parameter group {-0.714, -0.294, -1.0, 0.778} corresponding to RS3 is used as the four-dimensional feature input to construct the standardized feature set of the current delayed abnormal lung segment. Suppose there are three lung segments RS2, RS3 and LS4, which have the following standardized feature groups: RS2 is {-0.205, 0.115, -0.525, 0.348}, RS3 is {-0.714, -0.294, -1.0, 0.778}, and LS4 is {0.335, 0.298, -0.132, -0.126}. First, the four components of the feature vector of each lung segment are calculated as the offset value of the mean value of the lung segment as the analysis input, and the values of the components in the lung segment are longitudinally averaged and varianceed. For example, if the first column value of the four components is {-0.205, -0.714, 0.335}, the mean is: ; Find the variance ; In this way, the mean and variance of the four columns are obtained, and then the four-dimensional vector of each lung segment is centered, that is, each eigenvalue is subtracted from the mean of the column to form a centered vector sequence. For example, the first dimension of RS3 is centered as follows: , repeatedly process the lung segment components, and then perform paired difference calculation on each group of lung segment vectors after centering. For example, the difference between RS3 and RS2 in the first dimension is -0.5193-(-0.0103)=-0.509. Record the paired differences of the corresponding components between the lung segments, and then calculate the sum of squares of these differences to obtain the degree of characteristic deviation of each lung segment relative to the overall sample. For example, the sum of square differences of RS3 is , in this way, a lung segment feature deviation score sequence is constructed, and the sequence size is sorted to obtain the sorting number. Finally, the feature directions with the top two deviation scores are selected as the principal component directions. For example, the first principal component is the tidal volume direction, and the second principal component is the lung segment volume direction. On this basis, the linear combination score value of RS3 in the two principal component directions is reconstructed. For example, the standardized value of RS3 in the tidal volume direction -0.714 and the volume direction -1.0 are used as weighted inputs. If the tidal volume weight is 0.65 and the volume weight is 0.35, the principal component score of RS3 is , repeating this operation to obtain the principal component scores of RS2 and LS4 in the same direction, and finally forming a principal component score set of RS2 is -0.345, RS3 is -0.8141, and LS4 is 0.312, which is used to represent the performance differences of the lung segments in the key feature directions.
[0040] S403: Calling the principal component vector coefficients of the lung segments, performing coordinate matching in the atlas in combination with the lung segment numbers, calculating the infection probability based on the principal component density values within the region, and performing probability stacking synthesis to obtain a spatial probability distribution map of lung segment infection; Based on the obtained principal component score set, the lung segment numbers are matched with their spatial positions in the CT atlas. RS2, RS3 and LS4 are defined as corresponding to the three-dimensional coordinate points in millimeters in the lung model as RS2: (52, 84, 22), RS3: (66, 89, 20), LS4: (43, 78, 24), and the linear density value of each coordinate point in the principal component score is superimposed to construct a local infection score. The score is defined as: the weighted sum of the first principal component and the second principal component, where the weight of the first principal component is 0.7 and the weight of the second principal component is 0.3. For example, if the first principal component score of RS3 is -0.8141 and the second principal component score is -0.330, then its spatial infection density score is According to the set risk interval, if the low-risk area is [-0.5, 0.5], the medium-risk area is [-1.0, -0.5)∪(0.5, 1.0], and the high-risk area is less than -1.0 or greater than 1.0, then the score of RS3 is in the medium-risk area. The density scores of the lung segments are calculated in this way. The score of RS2 is -0.345 and the score of LS4 is 0.201, which are respectively in the low-risk and high-risk intervals. Then the number, coordinates and density scores of the lung segments are combined to generate the lung segment space infection risk. Layer, in which the density value corresponds to the color level, for example, density values less than -1.0 are red, density values in [-1.0, -0.5) are orange, [-0.5, 0.5] are yellow, (0.5, 1.0] are light green, and values greater than 1.0 are green. RS3 is marked as an orange lung segment, and RS2 and LS4 are marked as yellow lung segments. These color information are superimposed in the three-dimensional spatial model to form a spatial distribution visualization result, which facilitates the observation of the principal component density clusters and infection risk levels of the lung segments through intuitive color.
[0041] Specifically, the steps of S5 are: S501: Based on the mapped probability data in the spatial probability distribution map of lung segment infection, the lung segment numbers and coordinates within the infection risk threshold are screened. The respiratory monitoring data is matched and the respiratory rate and tidal volume sequences of the corresponding lung segment over the past three days are extracted. The sequence fluctuation amplitude and central trend deviation are calculated to obtain the respiratory fluctuation coefficient group value. The infection risk area threshold interval is a probability value ≥ 0.7, and the interval is set based on the probability density characteristics and statistical distribution curve in the spatial probability distribution map of lung segment infection; Based on the mapping probability data in the spatial probability distribution map of lung segment infection, the distribution map is first traversed in rows and columns to extract the probability density value of each lung segment one by one. If the current lung segment is numbered RS1 and its probability density is 0.72, the number and the corresponding coordinate point are marked as the target lung segment. If the probability density of RS2 is 0.65, it is judged to be less than 0.7, and the number data is removed. Only the numbers and coordinates with probability values greater than or equal to 0.7 are retained. For example, the RS3 lung segment and the coordinates (66, 89, 20) are selected. Then, the target lung segment RS3 is retrieved in the three-day respiratory monitoring database to find the respiratory rate and tidal volume data for each hour in the record to form a time series array. Assume that the respiratory rate is {18, 22, 21, 19, 23, 20, 22, 21} and the tidal volume sequence is {470, 490, 480, 460, 500, 475, 495, 485}. The respiratory fluctuation coefficient group value is calculated using the formula: ; in, Representative The respiratory fluctuation coefficient group value of each lung segment is an important input parameter of the subsequent logistic regression model. represents the respiratory rate coefficient, represents the tidal volume coefficient, satisfying , Representative The lung segment Respiratory rate data at each time point, in bpm, Representative The average respiratory rate data of each lung segment within three days, in bpm, Representative The lung segment Tidal volume data at each time point, in mL, Representative The average value of tidal volume data for each lung segment within three days, in mL, Representative The maximum respiratory rate of each lung segment within three days, in bpm, is normalized to a dimensionless parameter. Representative The minimum value of tidal volume of each lung segment within three days, in mL, is normalized to a dimensionless parameter. Representative The covariance coefficient of respiratory rate and tidal volume of each lung segment within three days represents the cooperativity of parameter fluctuations. Representative The phase synchronization disturbance index of each lung segment represents the normalized value of the average delay difference between tidal rise and blood oxygen response.
[0042] During the execution, the maximum value 23 and the minimum value 18 in the respiratory frequency array are normalized to obtain The minimum tidal volume is 460, which is normalized to approximately 0 relative to the maximum value of 500. To avoid the denominator being zero, a small constant is given. In addition, the covariance coefficient between respiratory rate and tidal volume , and the phase perturbation between tidal and blood oxygen responses Then, the absolute deviation between each time point and the sequence mean is calculated in turn, and the mean respiratory rate is , the absolute deviation value sequence is {2.75, 1.25, 0.25, 1.75, 2.25, 0.75, 1.25, 0.25}, its average value is 1.3125, and the mean tidal volume is , the absolute deviation value sequence is {12.5, 7.5, 2.5, 22.5, 17.5, 7.5, 12.5, 2.5}, the average of which is 10.625, and then the known respiratory rate weight is used. Tidal volume weighting , calculate the numerator: ; Calculate the denominator: ; ; The respiratory fluctuation coefficient value of RS3 lung segment was 13.87.
[0043] S502: Using the respiratory fluctuation coefficient group value as an input variable, constructing a logistic regression model and fitting the weight parameters corresponding to the input items, outputting a prediction confidence level based on the training sample, and generating a risk confidence value; The fluctuation coefficient calculated above is This is used as an independent variable in a logistic regression model to predict risk levels. The logistic regression model maps the continuous volatility coefficient value to a probability output between 0 and 1, known as the "risk confidence level," and then uses this value to determine the risk level. Logistic regression is suitable for mapping continuous input variables to categorical labels and offers excellent interpretability and fitting capabilities.
[0044] First, refer to the risk level classification of the original samples in the training set: When θ<5.0, it corresponds to a low-risk sample (for example, the volatility coefficient is 3.0), when 5.0≤θ<10.0, it corresponds to a medium-risk sample (for example, 6.5), and when When the value is 11.2 or 14.5, it is mostly in the high-risk area (such as 11.2 or 14.5); This classification is based on large-sample lung segment data statistics and is consistent with the medical understanding that greater physiological fluctuations indicate a higher risk of infection. The RS3 lung segment has a fluctuation coefficient of 13.87, clearly placing it in the high-risk range, but this is only a rough classification. To further quantify the risk confidence level—that is, to score the model's confidence in the "high risk" judgment—we use a logistic regression function: ; in, is the risk confidence value, is the input fluctuation coefficient, The model parameters obtained by fitting the original data control the slope and offset of the curve. In this example, the empirical fitting results are selected. : Indicates the degree of impact of each unit increase in the volatility coefficient on the risk probability, Indicates no fluctuation ( )’s underlying risk offset.
[0045] Will Substituting into the formula: ; Therefore, the risk confidence level output by the logistic regression is 0.9817, which is close to 1. This indicates that the infection risk of the RS3 lung segment is judged to be high risk, and the model has extremely high confidence in this conclusion. The inference results are stable and match the existing training data samples.
[0046] S503: Based on the risk confidence value, the risk level is determined by setting a classification standard according to the threshold interval, and the risk label is integrated with the lung segment number and confidence data to generate a postoperative lung segment risk warning list; After completing the calculation of the fluctuation coefficient and logistic regression risk assessment for the RS3 lung segment, we structured and integrated the results to form a standardized risk warning list item for system presentation and clinical decision support. The list items include lung segment spatial position (66, 89, 20), respiratory rate deviation (1.3125), tidal volume deviation (10.625), weighted deviation (5.0375), covariate difference coefficient ( ), phase synchronization disturbance index ( ), final volatility coefficient ( ) and the risk confidence level (0.9817) derived from the logistic regression function, corresponding to a high risk level. This warning information not only clearly identifies the precise location of the high-risk lung segment in three-dimensional space, but also supports the scientific nature of risk assessment through multidimensional feature parameters, serving as a hotspot marker node in the intelligent lung atlas. A risk confidence level close to 1 indicates that the model has a high degree of confidence in its assessment, and the segment should be included in the priority intervention and dynamic monitoring list. In practice, this list can be connected to the lung segment risk heat map system for color-coded visualization (e.g., high-risk is marked in red) and trigger an intelligent push mechanism for physician reminders or automated intervention scheduling. It also serves as a critical data node for subsequent medical research, model optimization, and case traceability. The comprehensive evaluation recommends that clinicians strengthen the frequency of examinations and respiratory management for the RS3 lung segment. If necessary, anti-infection or oxygen therapy can be implemented preemptively. Meanwhile, the fluctuation and evolution of the RS3 segment can be continuously tracked in the data stream to ensure timely response and intervention in high-risk areas.
[0047] like Figure 2 As shown, a prediction system for postoperative lung infection, the system includes: The data alignment module is used to obtain the time series data of tidal volume, blood oxygen saturation and respiratory rate through the respiratory monitoring equipment, align the timestamps according to the second-level time axis using linear interpolation, generate a timestamp-aligned data set, and pass it to the multi-scale analysis module; The multi-scale analysis module is used to align the data set according to the timestamp, input it into the sliding window mechanism for multi-scale signal analysis, calculate the time interval between the inflection point of tidal volume change and the inflection point of blood oxygen saturation response, generate the respiratory response delay feature set, and pass it to the anomaly detection module; The anomaly detection module is used to input the respiratory response delay feature set into the local anomaly factor algorithm, evaluate the abnormality of the delay feature, screen the lung segments with abnormal scores exceeding the percentile value, obtain the delay abnormal lung segment set, and pass it to the infection modeling module; The infection modeling module is used to obtain the average tidal volume, blood oxygen saturation rise rate, preoperative lung segment volume, and intraoperative ventilation pressure based on the delayed abnormal lung segment set, and then splice them into a feature vector. The feature vector is input into the kernel principal component analysis model to extract the principal components and map the coordinates. The spatial probability distribution map of lung segment infection is generated and transmitted to the risk identification module. The risk identification module is used to map the lung segment numbers and coordinates with probabilities within the threshold range in the spatial probability distribution map of lung segment infection, calculate the fluctuation amplitude and trend deviation, input them into the logistic regression model for classification boundary calculation and weight fitting, output the risk confidence value and risk label, and generate a postoperative lung segment risk warning list.
[0048] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any modifications or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in the present invention should be included in the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be based on the scope of protection of the claims.
Claims
1. A method for predicting postoperative pulmonary infection, characterized in that: The following steps are involved: S1: Obtain daily tidal volume, blood oxygen saturation, and respiratory rate time series data of postoperative patients through respiratory monitoring equipment, establish a unified time axis, and use linear interpolation to align and complete the timestamps of the three sets of data to generate a timestamp-aligned dataset; S2: Input the timestamp aligned dataset into a sliding window mechanism, perform multi-scale respiratory signal analysis, calculate the time interval between the inflection point of tidal volume change and the inflection point of blood oxygen saturation response, and output a respiratory response delay feature set; S3: Based on the respiratory response delay feature set, a local abnormality factor algorithm is used to evaluate the abnormality of the lung segment delay feature, and lung segments whose abnormality scores exceed the lung segment delay percentile value are marked to obtain a delay abnormal lung segment set; S4: Based on the delayed abnormal lung segment set, the average tidal volume, the rate of increase of blood oxygen saturation, and the preoperative lung segment volume parameters are extracted, and the feature vectors are spliced with the intraoperative ventilation pressure parameters. The feature vectors are input into the kernel principal component analysis model, the principal component feature vectors are extracted and the coordinates are mapped in the spatial lung segment atlas to generate a spatial probability distribution map of lung segment infection.
2. The method for predicting postoperative lung infection according to claim 1, characterized in that: The window size and step size of the sliding window mechanism are set according to the data sampling rate, physiological delay characteristics and task requirements; The number of neighbors of the local anomaly factor algorithm is empirically set based on the lung segment sample size and local density distribution characteristics; The unit of the average tidal volume is mL, the unit of the rate of increase of blood oxygen saturation is bpm, the unit of the preoperative lung segment volume parameter is mL, and the unit of the intraoperative ventilation pressure is cmH2O. Z-score standardization is performed on each of them to make them dimensionless parameters. The timestamp aligned dataset includes a unified time axis, interpolated data points, and synchronized time series data. The respiratory response delay feature set includes the tidal volume inflection point time, the blood oxygen response inflection point time, and the time interval between inflection points. The delayed abnormal lung segment set specifically includes the abnormal score lung segment number, the corresponding delay feature value, and the abnormal judgment label. The lung segment infection spatial probability distribution map includes the principal component space coordinates, the lung segment mapping position, and the infection probability value.
3. The method for predicting postoperative lung infection according to claim 1, wherein: The specific steps of S1 include: S101: Obtain daily tidal volume, blood oxygen saturation, and respiratory rate time series data of postoperative patients through respiratory monitoring equipment, call the original data acquisition timestamp, parse the sampling interval to filter out non-second-level data, establish a unified second-level time axis, fill in the missing time point null value markers, and generate a time axis construction value sequence; S102: constructing a value sequence based on the time axis, calling the previous and next sampling values and the corresponding time for the null value time points of tidal volume, blood oxygen saturation, and respiratory rate, estimating the missing values according to the linear interpolation formula, and generating a single set of data completion value sequence; S103: Completing the numerical sequence based on the single set of data, synchronizing the three sets of parameters at multiple time points second by second, pairing the tidal volume, blood oxygen saturation, and respiratory rate in timeline order, and generating a timestamp-aligned data set.
4. The method for predicting postoperative lung infection according to claim 3, characterized in that: The specific steps of S2 include: S201: calling the tidal volume, blood oxygen saturation and respiratory rate values per second in the timestamp alignment data set, setting the multi-scale sliding window length and step size, dividing the tidal volume sequence and sliding to extract the local increase and decrease direction and difference, marking the inflection point where the trend turns, and generating a tidal volume inflection point mark sequence; S202: calling the tidal volume inflection point mark sequence and the original blood oxygen saturation sequence, extracting the blood oxygen saturation within a specified range after each tidal volume inflection point, performing first-order difference, locating the response inflection point and matching the corresponding tidal volume inflection point, and generating a respiratory event response pairing index sequence; S203: Convert the paired inflection point timestamp difference in the respiratory event response paired index sequence to a unified unit and determine whether it falls into a preset screening interval, retain valid samples, and calculate the distribution trend of the remaining time differences to obtain a respiratory response delay feature set.
5. The method for predicting postoperative lung infection according to claim 4, characterized in that: The specific steps of S3 include: S301: Based on the respiratory response delay feature set, a delay value sequence within each lung segment is selected as input data, and input into a local outlier factor algorithm to establish a distance relationship model of the delay values, estimate the neighborhood density of the lung segment, and calculate the local outlier factor score to generate a lung segment delay outlier score; S302: Based on the lung segment delay outlier score, the score data is sorted from small to large and the numerical distribution is calculated. The percentile value of the score sequence in the high interval is extracted as a judgment benchmark. The lung segment score is then compared to see whether it exceeds the percentile value to obtain a delay score exceeding limit identification set; S303: calling the delay score excess identification set, matching the number information of the excess lung segments, extracting the corresponding data from the original feature set and classifying and integrating them to generate a delay abnormal lung segment set.
6. The method for predicting postoperative lung infection according to claim 5, characterized in that: The specific steps of S4 include: S401: Based on the delayed abnormal lung segment set, extract the mean tidal volume, blood oxygen saturation rise rate, preoperative lung segment volume and intraoperative ventilation pressure value, unify the numbering and perform normalization processing according to the Z-score method to generate a standardized feature parameter group; S402: Constructing a four-dimensional feature vector set based on the standardized feature parameter group, calling a kernel principal component analysis model to perform nonlinear mapping and principal component extraction, sorting and screening the first two groups of principal components based on contribution rates, and obtaining lung segment principal component vector coefficients; S403: Call the principal component vector coefficient of the lung segment, perform coordinate matching in the atlas in combination with the lung segment number, calculate the infection probability based on the principal component density value in the region, and perform probability stacking synthesis to obtain a spatial probability distribution map of lung segment infection.
7. The method for predicting postoperative lung infection according to claim 1, characterized in that: The method includes step S5: S5: For lung segments with a mapping probability within the risk zone threshold interval in the spatial probability distribution map of lung segment infection, extract the three-day coefficient of variation of respiratory rate and tidal volume, perform classification boundary calculation and risk weight regression analysis using a logistic regression model, output the confidence index and risk label corresponding to each target lung segment, and summarize and generate a postoperative lung infection warning list; The postoperative lung infection warning list specifically refers to the target lung segment number, confidence index, and risk level label.
8. The method for predicting postoperative lung infection according to claim 7, characterized in that: The specific steps of S5 include: S501: Based on the mapped probability data in the spatial probability distribution map of the lung segment infection, the lung segment numbers and coordinates within the infection risk area threshold interval are screened, the respiratory monitoring data are matched, and the respiratory frequency and tidal volume sequences of the corresponding lung segment within three days are extracted. The sequence fluctuation amplitude and central trend deviation are calculated to obtain the respiratory fluctuation coefficient group value; The infection risk area threshold interval is set according to the probability density characteristics and statistical distribution curve in the lung segment infection spatial probability distribution map; S502: Using the respiratory fluctuation coefficient group value as an input variable, constructing a logistic regression model and fitting weight parameters corresponding to the input items, outputting a prediction confidence level based on the training sample, and generating a risk confidence value; S503: Based on the risk confidence value, the risk level is determined by setting a classification standard according to the threshold interval, and the risk label is integrated with the lung segment number and confidence data to generate a postoperative lung segment risk warning list.
9. The method for predicting postoperative lung infection according to claim 8, characterized in that: The respiratory fluctuation coefficient group value is calculated using the formula: ; in, Representative The respiratory fluctuation coefficient group value of each lung segment is an important input parameter of the subsequent logistic regression model. represents the respiratory rate coefficient, represents the tidal volume coefficient, satisfying , Representative The lung segment Respiratory rate data at each time point, in bpm, Representative The average respiratory rate data of each lung segment within three days, in bpm, Representative The lung segment Tidal volume data at each time point, in mL, Representative The average value of tidal volume data for each lung segment within three days, in mL, Representative The maximum respiratory rate of each lung segment within three days, in bpm, is normalized to a dimensionless parameter. Representative The minimum value of tidal volume of each lung segment within three days, in mL, is normalized to a dimensionless parameter. Representative The covariance coefficient of respiratory rate and tidal volume of each lung segment within three days represents the cooperativity of parameter fluctuations. Representative The phase synchronization disturbance index of each lung segment represents the normalized value of the average delay difference between tidal rise and blood oxygen response.
10. A prediction system for postoperative lung infection, characterized in that: The system is used to implement the method for predicting postoperative pulmonary infection according to any one of claims 1 to 9, and the system comprises: The data alignment module is used to obtain the time series data of tidal volume, blood oxygen saturation and respiratory rate through the respiratory monitoring equipment, align the timestamps according to the second-level time axis using linear interpolation, generate a timestamp-aligned data set, and pass it to the multi-scale analysis module; a multi-scale analysis module, configured to align the data set according to the timestamps, input the data set into a sliding window mechanism for multi-scale signal analysis, calculate the time interval between the inflection point of the tidal volume change and the inflection point of the blood oxygen saturation response, generate a respiratory response delay feature set, and transmit the feature set to the anomaly detection module; An anomaly detection module is used to input the respiratory response delay feature set into a local anomaly factor algorithm, evaluate the degree of abnormality of the delay feature, screen lung segments with abnormal scores exceeding the percentile value, obtain a set of lung segments with abnormal delays, and pass it to the infection modeling module; An infection modeling module is used to obtain the average tidal volume, blood oxygen saturation rise rate, preoperative lung segment volume and intraoperative ventilation pressure based on the delayed abnormal lung segment set, splice them into a feature vector, input it into the kernel principal component analysis model to extract the principal components and map the coordinates, generate a spatial probability distribution map of lung segment infection, and transmit it to the risk identification module; The risk identification module is used to map the lung segment numbers and coordinates whose probabilities are within the threshold range in the spatial probability distribution map of lung segment infection, calculate the fluctuation amplitude and trend deviation, input them into the logistic regression model for classification boundary calculation and weight fitting, output the risk confidence value and risk label, and generate a postoperative lung segment risk warning list.
Citation Information
Cited By
Laryngeal mask ventilation control method suitable for outpatient anesthesia
CN120837796A
Remote breathing health monitoring and management system and method
CN121075711A