A medical task prediction model construction method

By constructing a medical task prediction model with a multi-channel prototype network module and a fully connected layer, the problems of interpretability and prediction accuracy of deep learning models in cardiovascular disease prediction are solved, achieving more efficient disease classification and decision-making process understanding.

CN119673470BActive Publication Date: 2025-10-17INST OF COMPUTING TECH CHINESE ACAD OF SCI
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411633653.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-15
Publication Date
2025-10-17
Estimated Expiration
2044-11-15

AI Technical Summary

Technical Problem

Existing deep learning models suffer from insufficient interpretability and fail to fully utilize the independence between multi-channel blood pressure data in cardiovascular disease prediction, resulting in low prediction accuracy.

Method used

A multi-channel prototype network module (ProtoPNet unit) is used to construct a medical task prediction model. The feature matrix of time-series blood pressure data is obtained through the feature extraction module, and the similarity matrix is ​​calculated using multiple global prototypes. The prediction is performed in combination with the fully connected layer. A two-stage objective function is introduced during the training process to improve the model performance.

Benefits of technology

It improves the interpretability and prediction accuracy of the model, enables medical staff to understand the model decision-making process, and improves the accuracy and discrimination ability of disease classification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119673470B_ABST
    Figure CN119673470B_ABST
Patent Text Reader

Abstract

The application provides a medical task prediction model construction method, which comprises the following steps: S1, acquiring a training data set, wherein the training data set comprises time series blood pressure data in multiple preset time periods; S2, constructing an initial model, wherein the initial model comprises a feature extraction module, a multi-channel prototype network module and a full connection layer; S3, taking the time series blood pressure data as input, taking the disease classification result of the time series blood pressure data as prediction output, training the initial model according to a preset training rule until convergence, and obtaining a medical task prediction model. The medical task prediction model can perform feature extraction and similarity calculation on the data in different channels of the time series blood pressure data, so as to sufficiently obtain the feature information of the data in different channels and improve the prediction accuracy of the model; and the time series blood pressure data can be matched with a global prototype, so that the decision-making process of the model can be intuitively understood.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of deep learning, in particular to a model construction technology in the field of deep learning, and more particularly to a medical task prediction model construction method. BACKGROUND

[0002] As the leading cause of death worldwide, the high incidence and mortality of cardiovascular diseases pose a serious challenge to public health. In the evaluation system of cardiovascular health, multi-channel blood pressure monitoring plays a crucial role. Blood pressure, as a comprehensive physiological indicator, usually covers multiple dimensions such as systolic pressure, diastolic pressure, and mean arterial pressure, each dimension carrying unique physiological implications and clinical value. These different channel blood pressure data play an irreplaceable role in the diagnosis, treatment and prognosis of various cardiovascular diseases. In particular, during the operation, continuous monitoring of multi-channel blood pressure is particularly important. Surgical procedures often involve dramatic changes in the patient's physiological state, and rapid fluctuations in blood pressure can directly induce serious cardiovascular events such as stroke and myocardial infarction, thereby significantly increasing the risk of postoperative complications and death. Therefore, by monitoring and analyzing the trend of changes in blood pressure data in each channel during the operation in real time, abnormal conditions can be quickly identified, and timely intervention measures can be taken to effectively prevent the disease from worsening and ensure patient safety.

[0003] In recent years, with the rapid development of artificial intelligence technology, especially the widespread application of deep learning technology, the medical field has undergone an unprecedented revolution. In the prediction of cardiovascular diseases, deep learning models, with their powerful data processing capabilities and pattern recognition capabilities, have significantly improved the accuracy of disease prediction, providing more reliable data support for clinical decision-making. However, the high complexity and non-intuitive nature of deep learning models have also brought new problems - the lack of explainability of model decisions. Because the internal structure and decision logic of deep learning models are extremely complex, their output results are often difficult for medical professionals to intuitively understand and accept, which has largely limited the in-depth application of deep learning technology in clinical practice.

[0004] In addition, in the process of processing multi-channel blood pressure data, existing deep learning models often ignore the independence that may exist between different channels. In fact, although systolic pressure, diastolic pressure and mean arterial pressure all belong to the category of blood pressure, they differ significantly in physiological mechanisms, influencing factors and clinical significance. Therefore, if these differences are not fully considered in the construction of the prediction model, it may lead to a decline in model performance.

[0005] In summary, although deep learning models have shown great potential in cardiovascular disease prediction, the deep learning models constructed by the prior art still face two challenges: one is the lack of model interpretability, as the internal structure and decision logic of deep learning models are extremely complex, which makes it difficult for medical professionals to intuitively understand the decision-making process of the model; the second is the failure to fully utilize the independence between multi-channel blood pressure data, resulting in low prediction accuracy of deep learning models. SUMMARY

[0006] Therefore, the purpose of the present application is to overcome the above-mentioned defects of the prior art, and to provide a medical task prediction model construction method.

[0007] The purpose of the present application is achieved by the following technical solutions.

[0008] According to a first aspect of the present application, a medical task prediction model construction method is provided, the method comprising: step S1, obtaining a training data set, the training data set comprising time series blood pressure data of a plurality of preset time periods, wherein each time series blood pressure data comprises data of a plurality of channels, and each time series blood pressure data is provided with a corresponding disease label; step S2, constructing an initial model, the initial model comprising a feature extraction module, a multi-channel prototype network module and a fully connected layer, wherein: the feature extraction module is used for feature extraction of the time series blood pressure data to obtain a feature matrix of the time series blood pressure data, wherein the feature matrix of the time series blood pressure data comprises a plurality of feature sub-matrices of the channels; the multi-channel prototype network module comprises a plurality of ProtoPNet units, wherein a plurality of global prototypes are configured on each ProtoPNet unit, one global prototype corresponds to a feature segment of one channel in the time series blood pressure data corresponding to one disease label, and different global prototypes correspond to different disease categories, each ProtoPNet unit is used to calculate the similarity between the feature matrix of the time series blood pressure data and each global prototype configured on the ProtoPNet unit according to a predetermined processing manner to obtain a target similarity matrix, one element in the target similarity matrix representing the similarity score between the most similar feature data in one channel of the time series blood pressure data and one global prototype; the fully connected layer is used for prediction processing of a plurality of target similarity matrices obtained by the multi-channel prototype network module to obtain a disease classification result of the time series blood pressure data; step S3, taking the time series blood pressure data as input and the disease classification result of the time series blood pressure data as prediction output, training the initial model according to a predetermined training rule until convergence to obtain a medical task prediction model.

[0009] In some embodiments of the present application, each time series blood pressure data comprises data of three channels of diastolic pressure, systolic pressure and mean arterial pressure.

[0010] In some embodiments of the present application, the feature extraction module is a gated transformer network.

[0011] In some embodiments of the present application, the preset processing manner is: calculating the similarity between each feature sub-matrix of each channel of the feature matrix of the time series blood pressure data and each global prototype configured on the ProtoPNet unit to obtain a similarity matrix corresponding to the number of global prototypes, each similarity matrix comprising a similarity sub-matrix obtained by calculating each feature sub-matrix of each channel of the time series blood pressure data and the corresponding global prototype, wherein the similarity sub-matrix is calculated in the following manner:

[0012]

[0013] wherein, represents the feature sub-matrix of the i-th channel of the time series blood pressure data and the similarity sub-matrix calculated by the global prototype represents the feature sub-matrix of the i-th channel of the time series blood pressure data; represents a feature point in the feature sub-matrix represents the i-th global prototype in the i-th ProtoPNet unit; represents a feature point in the feature sub-matrix represents a feature point in the feature sub-matrix represents the i-th global prototype in the i-th ProtoPNet unit;

[0014] In some embodiments of the present application, the preset training rule is to perform two-stage training on the initial model in the following manner: in the first stage, the time series blood pressure data is taken as the input, the disease classification result of the time series blood pressure data is taken as the predicted output, a plurality of rounds of iterative training are performed, and the initial model parameters are updated by a first target function to obtain an intermediate model; in the second stage, the time series blood pressure data is taken as the input, the disease classification result of the time series blood pressure data is taken as the predicted output, a plurality of rounds of iterative training are performed, and the intermediate model parameters are updated by a second target function until convergence to obtain the medical task prediction model; wherein in each round of iterative training, each global prototype of each ProtoPNet unit in the multi-channel prototype network module of the intermediate model is updated in a preset matching manner.

[0015] In some embodiments of the present application, the first target function is:

[0016] ​​​​​​​

[0017] in, represents the cross entropy loss function, Indicates the number of time series blood pressure data, represents the disease label of time series blood pressure data, Indicates the Disease labels for time series blood pressure data, represents the predicted output of time series blood pressure data, Indicates the Prediction output of time series blood pressure data;

[0018] The second objective function is:

[0019]

[0020] in,

[0021]

[0022] in,

[0023]

[0024]

[0025]

[0026] in, represents the second objective function, represents the multi-channel loss, represents the number of ProtoPNet units, Indicates the The weight parameters of the ProtoPNet units, Indicates the ProtoPNet units, Indicates the The first loss of the ProtoPNet unit, Indicates the The second loss of the ProtoPNet unit, Indicates the The third loss of the ProtoPNet unit, Indicates in ProtoPNet units are selected from A global prototype with consistent disease label categories for time-series blood pressure data , Represents the characteristic submatrix Belong to The feature matrix of time series blood pressure data, After feature extraction, The feature matrix of time series blood pressure data, Indicates in ProtoPNet units are selected from A global prototype for inconsistent disease label categories in time-series blood pressure data , Represents the characteristic submatrix A feature point in Representing feature points With the global prototype The square of the Euclidean distance between Global prototype With the global prototype The square of the Euclidean distance between Indicates the The first of the ProtoPNet units global prototypes, global prototypes With the global prototype Corresponding to different disease label categories.

[0027] In some embodiments of the present invention, the preset matching method is:

[0028]

[0029] in, Representing feature points The first The set of feature points in the feature matrix of the channel , After feature extraction, The first time series of blood pressure data The feature sub-matrix of the channels, Indicates the The disease label categories of the time series blood pressure data are classified as follows: , Indicates the The disease classification in ProtoPNet units is The global prototype collection of .

[0030] According to a second aspect of the present application, a medical task prediction method is provided, which comprises: step T1, obtaining time-series blood pressure data to be processed; step T2, using the medical task prediction model constructed by the method of the first aspect of the present application to perform prediction processing on the time-series blood pressure data to be processed to obtain a disease classification result, wherein, in the prediction processing, each target similarity matrix is matched with a feature matrix of the time-series blood pressure data to be processed based on the plurality of target similarity matrices obtained by the medical task prediction model, to obtain a local data segment of a channel in the time-series blood pressure data corresponding to each element in each target similarity matrix, and one or more local data segments meeting preset requirements are selected from all the obtained local data segments as prediction indicators to explain the disease classification result obtained by the prediction processing.

[0031] Compared with the prior art, the present application has the following advantages: (1) considering the independence between different channels of time-series blood pressure data, the medical task prediction model can perform feature extraction and similarity calculation on data in different channels of the time-series blood pressure data, so as to fully obtain feature information of the data in different channels, and further improve the prediction accuracy of the model; (2) matching the time-series blood pressure data with the global prototype, and using the local data segment in the matched time-series blood pressure data as a prediction indicator to explain the classification basis of the medical task prediction model, so as to intuitively understand the decision-making process of the model. BRIEF DESCRIPTION OF DRAWINGS

[0032] The embodiments of the present application will be further described below with reference to the accompanying drawings, in which:

[0033] Figure 1 FIG. 1 is a flowchart of a medical task prediction model construction method according to an embodiment of the present application;

[0034] Figure 2 FIG. 2 is a schematic diagram of an initial model according to an embodiment of the present application;

[0035] Figure 3 FIG. 3 is a schematic diagram of a plurality of test time-series blood pressure data matched with a global prototype according to an embodiment of the present application;

[0036] Figure 4 FIG. 4 is a schematic diagram of a test time-series blood pressure data matched with a global prototype according to an embodiment of the present application. DETAILED DESCRIPTION

[0037] In order to make the objects, technical solutions and advantages of the present application clearer, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application, and are not used to limit the present application.

[0038] As mentioned in the background technology section, although deep learning models have shown great potential in predicting cardiovascular diseases, deep learning models built using existing technologies still face two challenges: first, the model's interpretability is insufficient. Due to the extremely complex internal structure and decision-making logic of deep learning models, it is difficult for medical professionals to intuitively understand the model's decision-making process; second, the independence between multi-channel blood pressure data is not fully utilized, resulting in low prediction accuracy of the deep learning model.

[0039] To address the above-mentioned issues, the inventors studied existing technologies and found that ProtoPNet is commonly used to address model interpretability. In existing technologies, ProtoPNet, an interpretable method used in the field of image recognition, is introduced when building deep learning models. This method classifies images by obtaining similarity information between each region in an image sample and a learned prototype, making the model's decision-making process more transparent and interpretable. However, due to the different characteristics of image data and time series data, image data has a strong correlation in multiple directions, such as up, down, left, and right, while time series data focuses more on the information in the front and back directions of a data point. Therefore, even with the introduction of ProtoPNet, the model interpretability problem has not been effectively addressed. In particular, for multi-channel time series such as time-series blood pressure data, researchers did not consider the independence between different channels, resulting in the loss of unique feature information between channels and even affecting the interpretability. For example, in the complication prediction task based on time-series blood pressure data, because the multi-channel situation is not taken into account, the constructed deep learning model automatically uses the systolic pressure prototype to match the diastolic pressure channel data, which directly leads to a decrease in prototype similarity and affects the overall explanatory effect of the deep learning model.

[0040] Based on the above analysis, the inventors proposed a medical task model construction scheme for multi-channel time-series blood pressure data. In this scheme, multiple ProtoPNet units are set to address the model interpretability problem, wherein each ProtoPNet unit includes multiple global prototypes, which are used to perform similarity comparison with each channel in the time-series blood pressure data to obtain the target similarity matrix corresponding to each ProtoPNet unit, and each target similarity matrix is ​​used to determine the local data segments of each channel in the time-series blood pressure data with the highest similarity to each global prototype; based on multiple target similarity matrices, the disease category of the time-series blood pressure data is predicted. At the same time, the obtained local data segments are used as interpretable support for the prediction of the medical task model, so that medical staff can better understand the decision-making process of the medical task model.

[0041] In summary, if Figure 1As shown, the present application proposes a medical task prediction model construction method, which comprises the following steps: S1, acquiring a training data set, wherein the training data set comprises time series blood pressure data of a plurality of preset time periods, each time series blood pressure data comprises data of a plurality of channels, and each time series blood pressure data is provided with a corresponding disease label; S2, constructing an initial model, wherein the initial model comprises a feature extraction module, a multi-channel prototype network module and a full connection layer; the feature extraction module is used for feature extraction of the time series blood pressure data to obtain a feature matrix of the time series blood pressure data, wherein the feature matrix of the time series blood pressure data comprises a plurality of feature sub-matrices of channels; the multi-channel prototype network module comprises a plurality of ProtoPNet units, wherein each ProtoPNet unit is configured with a plurality of global prototypes, one global prototype corresponds to a feature segment of one channel in the time series blood pressure data corresponding to one disease label, and different global prototypes correspond to different disease categories, each ProtoPNet unit is used for calculating the similarity between the feature matrix of the time series blood pressure data and each global prototype configured on the ProtoPNet unit according to a preset processing mode to obtain a target similarity matrix, and one element in the target similarity matrix represents the similarity score between the most similar feature data in one channel of the time series blood pressure data and one global prototype; the full connection layer is used for prediction processing of a plurality of target similarity matrices obtained by the multi-channel prototype network module to obtain a disease classification result of the time series blood pressure data; and S3, taking the time series blood pressure data as input and the disease classification result of the time series blood pressure data as prediction output, training the initial model according to a preset training rule until convergence to obtain a medical task prediction model.

[0042] In order to better understand the present application, each step will be described in detail below in combination with specific embodiments.

[0043] I. Step S1

[0044] In the step S1, a training data set is acquired. The training data set comprises time series blood pressure data of a plurality of preset time periods, wherein each time series blood pressure data comprises data of a plurality of channels, and each time series blood pressure data is provided with a corresponding disease label. According to an embodiment of the present application, each time series blood pressure data comprises data of three channels of diastolic pressure, systolic pressure and mean arterial pressure. A specific example is given to introduce the time series blood pressure data: the time series blood pressure data comprises data of three channels of systolic pressure, diastolic pressure and mean arterial pressure, wherein the data acquisition frequency of each channel is set to be once every 0.5 minutes, and the data is collected for 350 minutes, in this case, the data length of each channel is 700 (700 time points).

[0045] II. Step S2

[0046] In step S2, an initial model is constructed. Figure 2 As shown in FIG, the initial model includes a feature extraction module, a multi-channel prototype network module and a fully connected layer. The following is a detailed description of each component of the initial model.

[0047] The feature extraction module is configured to extract features from the time-series blood pressure data to obtain a feature matrix of the time-series blood pressure data, wherein the feature matrix of the time-series blood pressure data includes feature submatrices of multiple channels, namely, a feature submatrix of diastolic pressure, a feature submatrix of systolic pressure, and a feature submatrix of mean arterial pressure. According to one embodiment of the present invention, the feature extraction module is a gated transtormer network.

[0048] It should be noted that, since the time-series blood pressure data includes data from three channels: diastolic pressure, systolic pressure, and mean arterial pressure, the feature extraction module needs to perform feature extraction on each channel of the time-series blood pressure data to obtain a feature submatrix for each channel of the time-series blood pressure data. The feature submatrix of each channel obtained by feature extraction includes multiple feature values, and each feature value represents the data of a portion of the time-series segment of its corresponding channel. Taking the time-series blood pressure data with a data length of 700 for each channel as described in the above example as an example for feature extraction, after the time-series blood pressure data is processed by the feature extraction module, the feature submatrix of each channel includes 23 feature points, which means that the 700 time points in each channel are divided into 23 regions and a feature point is extracted from each region as the representative of the region.

[0049] Depend on Figure 2 It can be seen that the multi-channel prototype network module includes multiple ProtoPNet units, wherein each ProtoPNet unit is configured with multiple global prototypes, a global prototype corresponds to a feature segment of a channel in the time series blood pressure data corresponding to a disease label, and different global prototypes correspond to different disease categories. Each ProtoPNet unit is used to calculate the similarity between the feature matrix of the time series blood pressure data and each global prototype configured on the ProtoPNet unit according to a preset processing method to obtain a target similarity matrix. An element in the target similarity matrix represents the similarity score between the feature data in a channel of the time series blood pressure data that is most similar to a global prototype and the global prototype.

[0050] According to one embodiment of the present application, the preset processing manner is: calculating the similarity between each feature sub-matrix of each channel of the feature matrix of the time series blood pressure data and each global prototype configured on the ProtoPNet unit to obtain a similarity matrix corresponding to the number of global prototypes, each similarity matrix comprising a similarity sub-matrix obtained by calculating each feature sub-matrix of each channel of the time series blood pressure data and the corresponding global prototype, wherein the similarity sub-matrix is calculated in the following manner:

[0051]

[0052] wherein, represents the feature sub-matrix of the i-th channel of the time series blood pressure data and the similarity sub-matrix calculated by the global prototype represents the feature sub-matrix of the i-th channel of the time series blood pressure data; represents one feature point in the feature sub-matrix represents the i-th global prototype in the i-th ProtoPNet unit; represents a decimal number; represents the Euclidean distance between the feature point and the global prototype ; performing maximum pooling processing on each similarity matrix, and splicing all the similarity matrices after the pooling processing to obtain a target similarity matrix.

[0053] It should be noted that each ProtoPNet unit comprises a prototype network and a maximum pooling layer. The prototype network is configured with a plurality of global prototypes, each of which calculates the similarity with the feature matrix of the time series blood pressure data to obtain a corresponding similarity matrix. The maximum pooling layer is used to perform maximum pooling processing on the similarity matrix corresponding to each global prototype in the ProtoPNet unit. Each element in the similarity matrix after the pooling processing represents the similarity score between the most similar feature data (feature point) in the corresponding channel of the time series blood pressure data and the global prototype, and all the similarity matrices after the pooling processing are spliced to obtain a target similarity matrix.

[0054] The fully connected layer is used to perform prediction processing on the plurality of target similarity matrices obtained by the multi-channel prototype network module to obtain the disease classification result of the time series blood pressure data.

[0055] III. Step S3

[0056] ​​​​​​In the step S3, the time series blood pressure data are taken as input, the disease classification result of the time series blood pressure data is taken as the prediction output, the initial model is trained according to a preset training rule until convergence is obtained, and a medical task prediction model is obtained. According to an embodiment of the present application, the preset training rule is two-stage training of the initial model. The training process of the two-stage training is introduced respectively as follows.

[0057] The first-stage training takes the time series blood pressure data as input, takes the disease classification result of the time series blood pressure data as the prediction output, performs multiple rounds of iterative training, and updates the initial model parameters with a first target function to obtain an intermediate model. The first target function is as follows:

[0058]

[0059] Wherein, represents a cross-entropy loss function, represents the number of time series blood pressure data, represents the disease label of the time series blood pressure data, represents the disease label of the i-th time series blood pressure data, represents the disease label of the i-th time series blood pressure data, represents the prediction output of the time series blood pressure data, represents the prediction output of the i-th time series blood pressure data.

[0060] It should be noted that the number of iterations of the first-stage training can be specified as 10 rounds, 15 rounds or 20 rounds, and 32 time series blood pressure data can be used for each round of iterative training. The specific number of rounds and the number of time series blood pressure data used in each round are determined by actual needs, and the present application does not make special limitations.

[0061] The second-stage training takes the time series blood pressure data as input, takes the disease classification result of the time series blood pressure data as the prediction output, performs multiple rounds of iterative training, and updates the intermediate model parameters with a second target function until convergence is obtained to obtain a medical task prediction model. In each round of iterative training, each global prototype of each ProtoPNet unit in the multi-channel prototype network module of the intermediate model is updated according to a preset matching mode. The second target function is as follows:

[0062]

[0063] Wherein,

[0064]

[0065] Wherein,

[0066]

[0067]

[0068]

[0069] wherein, represents the second objective function, represents the multi-channel loss, represents the number of ProtoPNet units, represents the weight parameter of the th ProtoPNet unit, represents the th ProtoPNet unit, represents the first loss of the th ProtoPNet unit, represents the second loss of the th ProtoPNet unit, represents the third loss of the th ProtoPNet unit, represents the global prototype selected in the th ProtoPNet unit that is consistent with the disease label category of the th time series blood pressure data, represents a feature sub-matrix belonging to the feature matrix of the th time series blood pressure data, represents the feature matrix of the th time series blood pressure data after feature extraction, represents the global prototype selected in the th ProtoPNet unit that is inconsistent with the disease label category of the th time series blood pressure data, represents a feature point in the feature sub-matrix , represents the square of the Euclidean distance between the feature point and the global prototype , the square of the Euclidean distance between the global prototype and the global prototype , represents the th global prototype in the th ProtoPNet unit, the global prototype and the global prototype ​​corresponding to different disease label categories. It should be noted that in the second stage training process, in addition to the cross-entropy loss, the second objective function also introduces a multi-channel loss, which calculates the distance between each global prototype and the time series blood pressure data of the same classification and the time series blood pressure data of different classifications in each round, as well as the distance between each global prototype on the same ProtoPNet unit and other global prototypes, so as to increase the prediction accuracy of the time series blood pressure data and the distance between the global prototypes of different disease classifications.

[0070] In the second stage training, not only the parameters of the intermediate model need to be updated according to the second objective function, but also each global prototype of each ProtoPNet unit in the multi-channel prototype network module of the intermediate model needs to be updated according to a preset matching mode. According to an embodiment of the present application, the preset matching mode is:

[0071]

[0072] wherein, represents a feature point belongs to the feature sub-matrix of the feature point set of the channel of the time series blood pressure data , represents the feature sub-matrix of the channel of the time series blood pressure data after feature extraction, represents the disease label category classification of the time series blood pressure data , represents the global prototype set of the ProtoPNet unit whose disease classification is . It should be noted that each global prototype in each ProtoPNet unit is a feature data (cluster center) obtained by iteratively calculating and clustering the feature matrices of the same channel of the time series blood pressure data of the same disease label category in units of channels, which represents the data segment with the highest similarity and the most representative in the same channel of the time series blood pressure data of the same disease label category. For example, if a global prototype corresponds to the diastolic pressure channel in disease category A, during the second stage training process, the global prototype will continuously learn the diastolic pressure channel data in the time series blood pressure data of disease category A, i.e., continuously reduce the square of the Euclidean distance between the global prototype and the same channel of the time series blood pressure data of the same disease label category, and thus obtain the cluster center of the diastolic pressure channel data in the multiple time series blood pressure data of disease category A, which represents the part with the highest similarity in the diastolic pressure channel data in the multiple time series blood pressure data of disease category A.

[0073] Based on the medical task prediction model constructed in the above embodiment, the application further provides a medical task prediction method, which comprises the following steps: T1, obtaining time-series blood pressure data to be processed; T2, using the medical task prediction model constructed by the method described in the above embodiment to perform prediction processing on the time-series blood pressure data to be processed to obtain a disease classification result, wherein, in the prediction processing, each target similarity matrix is matched with the feature matrix of the time-series blood pressure data to be processed based on the plurality of target similarity matrices obtained by the medical task prediction model, so as to obtain the local data segment of the channel in the time-series blood pressure data corresponding to each element in each target similarity matrix, and one or more local data segments meeting the preset requirements are selected from all the obtained local data segments as prediction indicators to explain the disease classification result obtained by the prediction processing.

[0074] In order to better understand the execution process of the medical task prediction, the medical task prediction method described in the above embodiment will be described in detail below. The specific execution process is as follows: first, obtaining time-series blood pressure data to be processed; then, using the medical task prediction model constructed by the method described in the above embodiment to perform prediction processing on the time-series blood pressure data to be processed to obtain a disease classification result. The specific processing process of the medical task prediction model is as follows: first, the feature extraction module performs feature extraction on the time-series blood pressure data to be processed to obtain a feature matrix; then, the multi-channel prototype network module performs similarity calculation on the feature matrix: the feature matrix is calculated with each global prototype in each ProtoPNet unit to obtain a similarity matrix corresponding to the number of global prototypes in each ProtoPNet unit, each similarity matrix in each ProtoPNet unit is subjected to maximum pooling processing, and all the similarity matrices in each ProtoPNet unit after the pooling processing are spliced to obtain a target similarity matrix corresponding to each ProtoPNet unit; finally, the fully connected layer performs prediction processing on the plurality of target similarity matrices transmitted by the multi-channel prototype network module to obtain the disease classification result of the time-series blood pressure data to be processed.

[0075] It should be noted that in order to enable medical staff to understand the decision-making process of the medical task prediction model, the plurality of target similarity matrices obtained by the medical task prediction model in the prediction processing process can be taken as the benchmark, and each target similarity matrix is matched with the feature matrix of the time series blood pressure data to be processed to obtain the local data segment of the channel in the time series blood pressure data corresponding to each element in each target similarity matrix, and one or more local data segments that meet the preset requirements are selected from all the obtained local data segments as prediction indicators to explain the disease classification result obtained by the prediction processing. For example, assuming that there is a time series blood pressure data with a channel number of 3, and the medical task prediction model is used to process the time series blood pressure data to obtain a target similarity matrix consistent with the number of ProtoPNet units; wherein each target similarity matrix contains 3 sub-matrices, each sub-matrix includes n similarity scores (n is consistent with the number of global prototypes in the ProtoPNet unit), and each similarity score represents the similarity score between the most similar feature data of the corresponding channel in the time series blood pressure data and the corresponding global prototype in the ProtoPNet unit and the global prototype, and the higher the similarity score, the more similar the local data segment matched by the feature data of the corresponding channel in the time series blood pressure data to the corresponding global prototype. Therefore, by obtaining the local data segment of the channel in the time series blood pressure data corresponding to each element (similarity score) in each target similarity matrix, and selecting one or more local data segments that meet the preset requirements (for example, the similarity score is greater than or equal to 0.8) from these local data segments as prediction indicators, the reason why the medical task prediction model makes the corresponding disease classification result can be explained.

[0076] It should also be noted that the one or more local data segments as prediction indicators are usually matched with the global prototype corresponding to the ProtoPNet unit, and the specific matching result is shown in the examples in Figure 3 and Figure 4 Figure 3 ​It can be seen that the left side is the test sample from top to bottom, and the right side is the global prototype of systolic blood pressure, the global prototype of diastolic blood pressure and the global prototype of mean arterial pressure in turn; wherein, the part selected by the red vertical line frame in the test samples 138 and 240 matches the part selected by the red vertical line frame in the right global prototype of systolic blood pressure; the part selected by the red vertical line frame in the test samples 5 and 41 matches the part selected by the red vertical line frame in the right global prototype of diastolic blood pressure; the part selected by the red vertical line frame in the test samples 1022 and 1308 matches the part selected by the red vertical line frame in the right global prototype of mean arterial pressure. Figure 4 It can be seen that the left side is the test sample, and the right side is the global prototype of systolic blood pressure, the global prototype of diastolic blood pressure and the global prototype of mean arterial pressure from top to bottom; wherein, the part selected by the red vertical line frame in each channel of the test sample matches the part selected by the red vertical line frame in each channel of the right global prototype.

[0077] In order to verify the working performance of the medical task prediction model constructed by the application, the medical task prediction model and the existing deep learning model are tested for classification on the same data set, and the experimental results shown in Table 1 are obtained. The existing deep learning models include GTN, LSTM, FCN, ResNet, TapNet, LSTMFCN and InceptionTime; wherein, GTN: a multi-channel time series classification model that captures channel-specific and step-by-step dependencies by merging two towers with a gating mechanism; LSTM: a deep learning model that aims to better handle long-term dependencies in sequential data by introducing three gates (input gate, forget gate, output gate) and cell state; FCN: a deep learning model that uses CNN to automatically discover and extract the internal structure of input time series data to generate deep features for classification; ResNet: a deep convolutional neural network that solves the performance degradation problem caused by increasing the depth of CNN by using residual modules; TapNet: a deep learning model for multi-dimensional time series classification that learns low-dimensional feature representations and interaction features through an attention prototype network and a multi-layer convolutional network; LSTMFCN: a multi-channel time series classification model realized by expanding the full convolution block into a squeeze-and-excitation block; InceptionTime: a deep learning model for time series classification inspired by the Inception network structure.

[0078] From Table 1, it can be seen that the medical task prediction model constructed by the present application has excellent performance, and the Acc, Pre, F1Score and AUC indicators are better than those of other related models. This shows that the medical task prediction model constructed by the present application has good disease classification ability, and can also maintain high efficient discrimination ability when dealing with highly unbalanced data sets. Among them, Acc (Accuracy): accuracy, used to measure the overall classification performance of the model; Pre (Presicion): precision, which can reflect the accuracy of the model in predicting positive classes; recall: reflects the identification ability of the model to positive class samples; F1 (F1 Score): F1 value, which takes into account the precision and recall of the classification model; AUC (Area Under the ROC Curve): area under the ROC curve, which is a comprehensive index used to evaluate the overall discrimination ability of the model.

[0079] Table 1

[0080]

[0081] In order to further analyze the working performance of the medical task prediction model constructed by the present application, a plurality of medical task models are trained with different loss functions and the performance of each medical task model is evaluated, and the evaluation results are shown in Table 2. Among them, indicates that the medical task model is trained only using the cross-entropy loss function; indicates that the medical task model is trained using as the loss function; C-PPT indicates that the medical task model is trained using as the loss function. From Table 2, it can be seen that the medical task model trained using as the loss function is better than other models in terms of Acc, Pre, F1Score and AUC.

[0082] Table 2

[0083]

[0084] In order to further analyze the working performance of the medical task prediction model constructed by the present application, the medical task prediction model is trained with as the loss function, and the model performance is evaluated in two cases of not adding weight and adding weight, and the evaluation results are shown in Table 3. Among them, C-PPT (no λ) indicates that no weight is added in the loss function, and C-PPT indicates that weight is added in the loss function; from Table 3, it can be seen that the performance of the medical task prediction model trained after adding weight in the loss function is better.

[0085] Table 3

[0086]

[0087] The beneficial effects of the present application are: (1) considering the independence between different channels of time series blood pressure data, enabling the medical task prediction model to extract features and calculate similarities of data in different channels of time series blood pressure data, so as to fully obtain feature information of different channel data, and further improve the prediction accuracy of the model; (2) matching the time series blood pressure data with the global prototype, and taking the local data segment in the matched time series blood pressure data as a prediction index to explain the classification basis of the medical task prediction model, and then intuitively understand the decision-making process of the model.

[0088] It should be noted that although the above describes each step in a specific order, it does not mean that each step must be performed in the above specific order, in fact, some of these steps can be executed concurrently, or even changed in order, as long as the required function can be realized.

[0089] The present application can be a system, a method, and / or a computer program product. The computer program product can include a computer readable storage medium having computer readable program instructions embodied therewith to implement various aspects of the present application.

[0090] The computer readable storage medium can be a tangible device that can retain and store instructions for use by an instruction execution device. The computer readable storage medium can be, for example, but is not limited to, an electronic storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium include the following: a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disc read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanically encoded device such as punch cards or punched tape, and any suitable combination of the foregoing. A non-transitory, computer-readable storage medium does not include a signal.

[0091] The above has described the embodiments of the present application, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes are obvious to those skilled in the art without departing from the scope and spirit of the described embodiments. The choice of terms used herein is intended to best explain the principles of the embodiments, practical applications, or improvements in technology in the market, or to enable other ordinary skilled persons in the art to understand the embodiments disclosed herein.

Claims

1. A method for constructing a medical task prediction model, characterized in that: The method comprises: Step S1: obtaining a training data set, wherein the training data set includes time-series blood pressure data of multiple preset time periods, wherein each time-series blood pressure data includes data of multiple channels, and each time-series blood pressure data is provided with a corresponding disease label; Step S2: construct an initial model, which includes a feature extraction module, a multi-channel prototype network module and a fully connected layer, wherein: The feature extraction module is used to perform feature extraction on the time series blood pressure data to obtain a feature matrix of the time series blood pressure data, wherein the feature matrix of the time series blood pressure data includes feature sub-matrices of multiple channels; The multi-channel prototype network module includes multiple ProtoPNet units, wherein each ProtoPNet unit is configured with multiple global prototypes, one global prototype corresponds to a feature segment of a channel in the time-series blood pressure data corresponding to a disease label, and different global prototypes correspond to different disease categories, each ProtoPNet unit is used to calculate the similarity between the feature matrix of the time-series blood pressure data and each global prototype configured on the ProtoPNet unit according to a preset processing method to obtain a target similarity matrix, wherein an element in the target similarity matrix represents the similarity score between the feature data in a channel of the time-series blood pressure data that is most similar to a global prototype and the global prototype; The fully connected layer is used to perform prediction processing on multiple target similarity matrices obtained by the multi-channel prototype network module to obtain disease classification results of time series blood pressure data; Step S3: Using the time series blood pressure data as input and the disease classification results of the time series blood pressure data as prediction output, the initial model is trained according to the preset training rules until convergence to obtain a medical task prediction model.

2. The method according to claim 1, characterized in that Each time series of blood pressure data includes data of three channels: diastolic pressure, systolic pressure and mean arterial pressure.

3. The method according to claim 2, characterized in that The feature extraction module is a gated Transtormer network.

4. The method according to claim 3, characterized in that The preset processing method is: Calculate the similarity between the feature submatrix of each channel in the feature matrix of the time series blood pressure data and each global prototype configured on the ProtoPNet unit to obtain a similarity matrix corresponding to the number of global prototypes. Each similarity matrix includes the feature submatrix of each channel of the time series blood pressure data and the similarity submatrix obtained after calculating the corresponding global prototype. The similarity submatrix is ​​calculated as follows: in, Indicates the first The characteristic sub-matrix of each channel and the global prototype The calculated similarity submatrix; Indicates the first The characteristic sub-matrix of each channel; Represents the characteristic submatrix A characteristic point in Indicates the The first of the ProtoPNet units A global prototype; Represents a decimal; Representing feature points With the global prototype The square of the Euclidean distance between them; Perform maximum pooling on each similarity matrix, and concatenate all similarity matrices after pooling to obtain the target similarity matrix.

5. The method according to claim 4, characterized in that The preset training rule is to perform two-stage training on the initial model in the following manner: The first stage of training uses time-series blood pressure data as input and the disease classification results of the time-series blood pressure data as prediction output. Multiple rounds of iterative training are performed and the initial model parameters are updated with the first objective function to obtain an intermediate model. The second stage of training uses time-series blood pressure data as input and the disease classification results of the time-series blood pressure data as the prediction output. Multiple rounds of iterative training are performed and the intermediate model parameters are updated using the second objective function until convergence to obtain a medical task prediction model. In each round of iterative training, each global prototype of each ProtoPNet unit in the multi-channel prototype network module of the intermediate model is updated according to a preset matching method.

6. The method according to claim 5, characterized in that The first objective function is: in, represents the cross entropy loss function, Indicates the number of time series blood pressure data, represents the disease label of time series blood pressure data, Indicates the Disease labels for time series blood pressure data, represents the predicted output of time series blood pressure data, Indicates the Prediction output of time series blood pressure data; The second objective function is: in, in, in, represents the second objective function, represents the multi-channel loss, represents the number of ProtoPNet units, Indicates the The weight parameters of the ProtoPNet units, Indicates the ProtoPNet units, Indicates the The first loss of the ProtoPNet unit, Indicates the The second loss of the ProtoPNet unit, Indicates the The third loss of the ProtoPNet unit, Indicates in ProtoPNet units are selected from A global prototype with consistent disease label categories for time-series blood pressure data , Represents the characteristic submatrix Belong to The feature matrix of time series blood pressure data, After feature extraction, The feature matrix of time series blood pressure data, Indicates in ProtoPNet units are selected from A global prototype for inconsistent disease label categories in time-series blood pressure data , Represents the characteristic submatrix A feature point in Representing feature points With the global prototype The square of the Euclidean distance between Global prototype With the global prototype The square of the Euclidean distance between Indicates the The first of the ProtoPNet units global prototypes, global prototypes With the global prototype Corresponding to different disease label categories.

7. The method according to claim 6, characterized in that The preset matching method is: in, Representing feature points The first The set of feature points in the feature matrix of the channel , After feature extraction, The first time series of blood pressure data The feature sub-matrix of the channels, Indicates the The disease label categories of the time series blood pressure data are classified as follows: , Indicates the The disease classification in ProtoPNet units is The global prototype collection of .

8. A medical task prediction method, characterized in that: The method comprises: Step T1, obtaining time series blood pressure data to be processed; Step T2, using the medical task prediction model constructed according to any one of the methods described in claims 1-7 to perform prediction processing on the time series blood pressure data to be processed to obtain a disease classification result, wherein, during the prediction processing, multiple target similarity matrices obtained by the medical task prediction model are used as a benchmark, and each target similarity matrix is ​​matched with the feature matrix of the time series blood pressure data to be processed to obtain the local data fragments of the channel in the time series blood pressure data corresponding to each element in each target similarity matrix, and one or more local data fragments that meet the preset requirements are selected from all the obtained local data fragments as prediction indicators to explain the disease classification results obtained by the prediction processing.

9. A computer-readable storage medium, characterized in that A computer program is stored thereon, and the computer program can be executed by a processor to implement the steps of any one of the methods of claims 1-8.

10. An electronic device, characterized in that: include: one or more processors, and a memory, wherein the memory is used to store executable instructions; The one or more processors are configured to implement the steps of the method according to any one of claims 1 to 8 by executing the executable instructions.