A disease Chinese explanation-based cause-of-death chain detection model training and detection method

By using a cause-of-death chain detection model based on Chinese disease interpretations and leveraging ICD-encoded Chinese interpretations and character vectors, an intelligent detection model is constructed. This solves the problems of low efficiency and long-tail distribution in existing cause-of-death chain detection technologies, achieving efficient and accurate automated detection.

CN116013546BActive Publication Date: 2026-03-20CHINA UNICOM (GUANGDONG) IND INTERNET CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-22
Publication Date
2026-03-20

AI Technical Summary

Technical Problem

Existing technologies for cause-of-death chain detection have high technical barriers, low efficiency and accuracy, and the excessive number of ICD codes leads to long-tail distribution problems, resulting in poor performance of conventional detection methods.

Method used

This paper describes a method for training a cause-of-death chain detection model based on Chinese interpretations of diseases. By utilizing the Chinese interpretations and character vectors of ICD codes, an intelligent detection model is constructed. A bidirectional GRU network and a fully connected layer are used to calculate the probability of ICD codes in the cause-of-death chain. The model training is optimized through a loss function to automatically detect cause-of-death chains.

Benefits of technology

It has achieved automated cause-of-death chain detection, reduced manual intervention, improved detection efficiency and accuracy, solved the long-tail distribution problem, and can correctly detect cause-of-death chains of rare diseases.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116013546B_ABST
    Figure CN116013546B_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on disease Chinese explanation cause of death chain detection model training and detection method, training method includes: collecting all ICD coding and Chinese explanation;Obtain cause of death chain sample;Randomly initialize the character vector corresponding to each Chinese character;Chinese explanation of each ICD coding in sample is replaced by character vector, and the corresponding ICD vector is obtained;Each ICD coding in each sample is replaced by ICD vector, and the corresponding vector matrix is obtained;Randomly initialize mask vector, randomly select the row vector in the vector matrix of sample, replace row vector with mask vector, obtain the mask matrix corresponding to each sample;Cause of death chain detection model is constructed, the mask matrix corresponding to each sample is input into model, and the probability that each ICD coding is located in each order in each sample is output;According to the probability that each ICD coding is located in each order in each sample, the total loss of all samples is calculated;Based on total loss, the model is trained, when total loss converges, the training completed cause of death chain detection model is obtained.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of death cause monitoring, and more particularly, to a death cause chain detection model training and detection method based on disease Chinese interpretation. BACKGROUND

[0002] ICD-10 coding is an internationally unified disease coding method formulated by WHO, which represents a class of diseases with letters and numbers. For example, the ICD-10 code of epidemic hemorrhagic fever is "A98.5"; the ICD-10 code of acute and chronic lymphocytic leukemia is "C91.0"; and the ICD-10 code of cerebellar ataxia is "G11.3". The death cause chain is a chain of patient death causes. After the patient dies, the hospital sorts the patient's death causes. Formally, the death cause chain is a chain composed of multiple ICD-10 codes. For example, ["I25.1", "I50.9"] is a death cause chain, where "I25.1" is the ICD-10 code of coronary heart disease, and "I50.9" is the ICD-10 code of acute heart failure. Therefore, this death cause chain indicates that the patient first suffered from coronary heart disease, which led to acute heart failure, and acute heart failure ultimately caused the patient's death. For another example, ["I10", "I25.1", "I48"] is also a death cause chain, where "I10" is the ICD-10 code of hypertension, "I25.1" is the ICD-10 code of coronary heart disease, and "I48" is the ICD-10 code of atrial fibrillation. Therefore, this death cause chain means that the patient had hypertension in early years, which led to coronary heart disease, which in turn led to atrial fibrillation, and atrial fibrillation was the ultimate cause of death.

[0003] The death cause chain can effectively reflect the development process and rules of diseases, and a conclusion accurate and complete death cause chain can clearly show the cause of death of the patient, which is beneficial to the government to monitor the death causes of the population, observe the death level and death cause distribution in the population, so that the government can take intervention measures in a timely manner in response to existing problems, rationally allocate health resources, help understand the death level and death cause order of residents, master the health influencing factors of residents, and provide reliable basis for government decision-making, which has great significance.

[0004] However, in the existing statistical analysis, due to the uneven level of doctors and subjective errors of manual work, the statistical record of the death cause chain often contains errors. The erroneous statistical record of the death cause chain will directly mislead the government decision-making, cause unreasonable allocation of health resources, and further cause serious livelihood problems.

[0005] In the prior art, the correctness of the cause-of-death chain is usually detected by experienced doctors through manual correction, which makes the detection threshold high and the detection efficiency and accuracy low. In addition, due to the large number of ICD-10 codes, there are thousands of types of diseases, and it is difficult to achieve good results with conventional anomaly detection methods due to the serious long-tail distribution problem. SUMMARY

[0006] The present application aims to overcome at least one of the above-mentioned defects (shortcomings) of the prior art, and provides a cause-of-death chain detection model training and detection method based on Chinese interpretation of diseases, to solve the problems of high detection threshold, low efficiency and accuracy of manual detection of cause-of-death chain in the prior art, and the long-tail distribution of excessive ICD codes, and the poor detection effect of conventional detection methods.

[0007] The technical scheme adopted by the present application is a cause-of-death chain detection model training method based on Chinese interpretation of diseases, comprising:

[0008] Collecting ICD codes corresponding to all diseases and their Chinese interpretations;

[0009] Obtaining a plurality of cause-of-death chain samples, each of which is composed of a plurality of ICD codes connected in order;

[0010] Randomly initializing vectors of Chinese characters to obtain trainable character vectors corresponding to each Chinese character;

[0011] Replacing Chinese characters in the Chinese interpretation of each ICD code in the cause-of-death chain sample with the character vector corresponding to the Chinese character to obtain an ICD vector corresponding to each ICD code;

[0012] Replacing each ICD code in each cause-of-death chain sample with the ICD vector corresponding to the ICD code to obtain a vector matrix corresponding to each cause-of-death chain sample;

[0013] Initializing a trainable masking vector, randomly selecting a row vector in the vector matrix corresponding to each cause-of-death chain sample, replacing the selected row vector with the masking vector to obtain a masking matrix corresponding to each cause-of-death chain sample;

[0014] Building a cause-of-death chain detection model, inputting the masking matrix corresponding to each cause-of-death chain sample into the cause-of-death chain detection model, and outputting the probability of each ICD code being in each order in each cause-of-death chain sample;

[0015] According to the probability of each ICD code being in each order in each cause-of-death chain sample, calculating the total loss of all cause-of-death chain samples;

[0016] Based on the total loss, iteratively training the cause-of-death chain detection model, and when the total loss converges, obtaining a trained cause-of-death chain detection model.

[0017] In this invention, an intelligent cause-of-death chain detection model is constructed to automatically detect and analyze cause-of-death chains. This effectively uses intelligent tools to replace manual operations, reducing human intervention and thus solving the problems of high technical barriers, low efficiency, and low accuracy that occur when manually detecting cause-of-death chains.

[0018] Meanwhile, through analysis of the problems with existing conventional detection methods, this invention reveals that the reason conventional anomaly detection methods fail to achieve good results is that there are too many types of diseases, and some disease types are uncommon. These diseases rarely appear in the available complete cause-of-death chain sample data, leading to uneven sample data acquisition and a long-tail distribution problem. Consequently, conventional detection methods cannot correctly detect anomalies in cause-of-death chains containing such diseases, resulting in poor detection performance. To solve this problem, this invention introduces prior information about diseases by using the ICD codes and their Chinese interpretations for all diseases. This allows the detection model in this invention to obtain relevant information about a disease category even if it has never seen a certain disease classification or has no related cause-of-death chain sample data, thereby correctly detecting cause-of-death chains and solving the problems of long-tail distribution and poor detection performance.

[0019] Furthermore, the Chinese characters in the Chinese explanations of each ICD code in the cause-of-death chain sample are replaced with the corresponding character vectors to obtain the ICD vectors corresponding to each ICD code, specifically including:

[0020] Replace the Chinese characters in the Chinese explanation of each ICD code in the cause of death chain sample with the corresponding character vector to obtain a list of character vectors corresponding to each ICD code;

[0021] The maximum length of the preset character vector list is used to unify the length of the character vector lists corresponding to each ICD encoding, thereby obtaining the ICD encoding matrix corresponding to each ICD encoding.

[0022] A dimensionality reduction module is constructed. The ICD encoding matrix corresponding to each ICD encoding is input into the dimensionality reduction module, and the ICD vector corresponding to each ICD encoding is output.

[0023] Furthermore, a cause-of-death chain detection model is constructed. The masking matrix corresponding to each cause-of-death chain sample is input into the cause-of-death chain detection model, and the probability of each ICD code being located in each order of each cause-of-death chain sample is output. Specifically, this includes:

[0024] The masking matrix corresponding to each cause of death chain sample is input into a bidirectional GRU network for processing. Then, an affine transformation is performed on the output of the bidirectional GRU network through a fully connected layer to obtain the first matrix after processing each cause of death chain sample.

[0025] The ICD vectors corresponding to each ICD code are combined into a second matrix, and the first matrix and the second matrix are used to calculate the probability of each ICD code being in each order in each death chain sample according to the following formula:

[0026] P = softmax (O * W.T)

[0027] Wherein, P represents the probability of each ICD code being in each order in each death chain sample, O represents the first matrix after processing each death chain sample, W represents the second matrix, and T represents the matrix transposition operation.

[0028] Further, according to the probability of each ICD code being in each order in each death chain sample, the total loss of all death chain samples is calculated, which specifically includes:

[0029] According to the probability of each ICD code being in each order in each death chain sample, the loss of a single death chain sample is calculated according to the following formula:

[0030] loss = -log (P ij )

[0031] Wherein, loss represents the loss of a single death chain sample, i represents the order of the ICD code corresponding to the row vector replaced by the hidden vector in the death chain, and j represents the order of the ICD code in the second matrix.

[0032] According to the loss of the single death chain sample, the total loss of all death chain samples is calculated according to the following formula:

[0033]

[0034] Wherein, loss_ represents the total loss of all death chain samples, n represents the number of samples of the death chain sample, k represents the index of the death chain sample, and loss k represents the kth death chain sample.

[0035] Further, based on the total loss, the death chain detection model is iteratively trained, and when the total loss converges, a trained death chain detection model is obtained, which specifically includes:

[0036] Based on the total loss, the gradient descent method is used to iteratively train the death chain detection model, and when the total loss converges, a trained death chain detection model is obtained.

[0037] On the other hand, another technical solution adopted by the present application is a death chain detection method based on Chinese interpretation of diseases, which includes:

[0038] Obtaining a death chain to be detected;

[0039] Each Chinese character has a corresponding trainable character vector, and the character vector is initialized;

[0040] According to the initialized character vector, each ICD code in the order of the to-be-detected cause-of-death chain is replaced by the corresponding ICD vector, and a vector matrix of the to-be-detected cause-of-death chain is obtained;

[0041] The cover vector is initialized, and each row vector in the vector matrix of the to-be-detected cause-of-death chain is replaced by the cover vector, and a plurality of cover matrices of the to-be-detected cause-of-death chain are obtained;

[0042] The plurality of cover matrices of the to-be-detected cause-of-death chain are respectively input into the trained cause-of-death chain detection model obtained by the training method, and the probability of each ICD code being located in each order of the to-be-detected cause-of-death chain sample is output;

[0043] According to the probability of each ICD code being located in each order of the to-be-detected cause-of-death chain sample, the total loss of the to-be-detected cause-of-death chain is calculated;

[0044] It is judged whether the total loss of the to-be-detected cause-of-death chain is greater than a preset threshold, if yes, it is determined that the to-be-detected cause-of-death chain is wrong, and if not, it is determined that the to-be-detected cause-of-death chain is correct.

[0045] On the other hand, another technical solution adopted by the present application is a cause-of-death chain detection model training system based on Chinese interpretation of diseases, comprising:

[0046] The coding interpretation collection module is used to collect the ICD codes corresponding to all diseases and the Chinese interpretation thereof;

[0047] The cause-of-death chain sample acquisition module is used to acquire a plurality of cause-of-death chain samples, each of which is composed of a plurality of ICD codes connected in order;

[0048] The character vector initialization module is used to initialize the vector of Chinese characters, and obtain the character vector corresponding to each Chinese character;

[0049] The coding vectorization module is used to replace the Chinese characters in the Chinese interpretation of each ICD code in the cause-of-death chain sample with the character vector corresponding to the Chinese character, and obtain the ICD vector corresponding to each ICD code;

[0050] The cause-of-death chain sample vectorization module is used to replace each ICD code in each cause-of-death chain sample with the ICD vector corresponding to the ICD code, and obtain the vector matrix corresponding to each cause-of-death chain sample;

[0051] The cover module is used to initialize the cover vector, randomly select a row vector in the vector matrix corresponding to each cause-of-death chain sample, replace the selected row vector with the cover vector, and obtain the cover matrix corresponding to each cause-of-death chain sample;

[0052] a model construction module, configured to construct a cause-of-death chain detection model, input a cover matrix corresponding to each cause-of-death chain sample into the cause-of-death chain detection model, and output a probability of each ICD code being in each sequence in each cause-of-death chain sample;

[0053] a loss calculation module, configured to calculate a total loss of all cause-of-death chain samples according to the probability of each ICD code being in each sequence in each cause-of-death chain sample;

[0054] a training module, configured to perform iterative training on the cause-of-death chain detection model based on the total loss, and obtain a trained cause-of-death chain detection model when the total loss converges.

[0055] In another aspect, another technical solution adopted by the present application is a cause-of-death chain detection system based on Chinese disease explanation, comprising:

[0056] a to-be-detected cause-of-death chain acquisition module, configured to acquire a to-be-detected cause-of-death chain;

[0057] a to-be-detected cause-of-death chain vectorization module, configured to initialize a character vector, and replace ICD codes in each sequence in the to-be-detected cause-of-death chain with corresponding ICD vectors according to the initialized character vector, to obtain a vector matrix of the to-be-detected cause-of-death chain;

[0058] Each Chinese character has a trainable character vector corresponding thereto;

[0059] a to-be-detected cause-of-death chain cover module, configured to initialize a cover vector, and replace each row vector in the vector matrix of the to-be-detected cause-of-death chain with the cover vector, to obtain a plurality of cover matrices of the to-be-detected cause-of-death chain;

[0060] a to-be-detected cause-of-death chain probability calculation module, configured to input the plurality of cover matrices of the to-be-detected cause-of-death chain into the trained cause-of-death chain detection model obtained by the above training method, and output a probability of each ICD code being in each sequence in the to-be-detected cause-of-death chain sample;

[0061] a to-be-detected cause-of-death chain total loss calculation module, configured to calculate a total loss of the to-be-detected cause-of-death chain according to the probability of each ICD code being in each sequence in the to-be-detected cause-of-death chain sample;

[0062] a judgment module, configured to judge whether the total loss of the to-be-detected cause-of-death chain is greater than a preset threshold, and if yes, determine that the to-be-detected cause-of-death chain is incorrect, and if not, determine that the to-be-detected cause-of-death chain is correct.

[0063] In another aspect, another technical scheme adopted by the present application is an electronic device comprising a memory and a processor, the memory storing a computer program, and the processor implements the death chain detection model training method or the death chain detection method when executing the computer program.

[0064] In another aspect, another technical scheme adopted by the present application is a computer storage medium storing a computer program, and the computer program implements the death chain detection model training method or the death chain detection method when executed by a processor.

[0065] Compared with the prior art, the present application has the following beneficial effects:

[0066] 1. In the present application, an intelligent death chain detection model is constructed to automatically detect and analyze the death chain, and intelligent tools are used to replace manual operation, thereby reducing manual intervention and solving the problems of high technical threshold, low efficiency and low accuracy when manually detecting the death chain.

[0067] 2. In the present application, the prior information of diseases is introduced through ICD codes and Chinese explanations of all diseases, so that the detection model can obtain relevant information of a disease classification even if it has not seen the disease classification or has no relevant death chain sample data, thereby correctly detecting the death chain and solving the problems of long-tail distribution and poor detection effect. BRIEF DESCRIPTION OF DRAWINGS

[0068] Figure 1 It is a training method flowchart in embodiment 1 of the present application.

[0069] Figure 2 It is a local example diagram for collecting ICD codes corresponding to all diseases and Chinese explanations in embodiment 1 of the present application.

[0070] Figure 3 It is a local example diagram for obtaining a plurality of death chain samples in embodiment 1 of the present application.

[0071] Figure 4 It is a detection method flowchart in embodiment 2 of the present application.

[0072] Figure 5 It is a training system structure diagram in embodiment 3 of the present application.

[0073] Figure 6 It is a detection system structure diagram in embodiment 4 of the present application.

[0074] Explanation of reference signs: coding explanation collection module 100, cause-of-death chain sample acquisition module 200, character vector initialization module 300, coding vectorization module 400, cause-of-death chain sample vectorization module 500, masking module 600, model construction module 700, loss calculation module 800, training module 900, to-be-detected cause-of-death chain acquisition module 110, to-be-detected cause-of-death chain vectorization module 220, to-be-detected cause-of-death chain masking module 330, to-be-detected cause-of-death chain probability calculation module 440, to-be-detected cause-of-death chain total loss calculation module 550, judgment module 660. DETAILED DESCRIPTION

[0075] The drawings of the present application are only used for illustrative description and cannot be understood as a limitation of the present application. In order to better illustrate the following embodiments, some components of the drawings may be omitted, enlarged or reduced, and do not represent the size of the actual product; it can be understood by those skilled in the art that some well-known structures in the drawings and their descriptions may be omitted.

[0076] Embodiment 1

[0077] As shown in Figure 1 , the present embodiment provides a cause-of-death chain detection model training method based on Chinese explanation of diseases, comprising:

[0078] S1, collect all ICD codes corresponding to diseases and their Chinese explanations, and the local example is specifically as shown in Figure 2 In the present embodiment, the ICD code is specifically ICD-10 code;

[0079] S2, acquire a plurality of cause-of-death chain samples, each of which is composed of a plurality of ICD codes connected in order, and the local example is specifically as shown in Figure 3

[0080] S3, each Chinese character has a corresponding trainable character vector, and the character vector is randomly initialized;

[0081] Specifically, in the present embodiment, the number of Chinese characters in the Chinese explanation of the ICD-10 code in the acquired cause-of-death chain sample is v, a d-dimensional trainable vector is randomly initialized for each character as the character vector corresponding to the Chinese character; additionally, a d-dimensional trainable vector is randomly initialized, which is called to fill in the blank part; additionally, a d-dimensional trainable vector is randomly initialized, which is called as the character vector corresponding to the Chinese character other than the Chinese character in the Chinese explanation of the ICD-10 code in the acquired cause-of-death chain sample.

[0082] S4, replace the Chinese characters in the Chinese explanation of each ICD code in the cause-of-death chain sample with the character vector corresponding to the Chinese character, to obtain the ICD vector corresponding to each ICD code; ​

[0083] Furthermore, step S4 specifically includes:

[0084] Replace the Chinese characters in the Chinese explanation of each ICD code in the cause of death chain sample with the corresponding character vector to obtain a list of character vectors corresponding to each ICD code;

[0085] The maximum length of the preset character vector list is used to unify the length of the character vector lists corresponding to each ICD encoding, thereby obtaining the ICD encoding matrix corresponding to each ICD encoding.

[0086] A dimensionality reduction module is constructed. The ICD encoding matrix corresponding to each ICD encoding is input into the dimensionality reduction module, and the ICD vector corresponding to each ICD encoding is output.

[0087] Specifically, in this embodiment, the number of ICD-10 codes for the included cause-of-death chain samples is denoted as v_icd, and the maximum length of the Chinese interpretation of the ICD-10 codes is set to icd_max_length. For the Chinese interpretation of each ICD-10 code, the characters in the Chinese interpretation are replaced with their corresponding character vectors. The specific replacement scheme is as follows: if the character to be replaced has a corresponding character vector, then the character vector corresponding to that character is used for replacement; otherwise, the character vector corresponding to that character is used. The substitution process is then performed. After substitution, a corresponding character vector list is generated for each ICD-10 encoded Chinese interpretation. If the length of the resulting character vector list is greater than `icd_max_length`, only the first `icd_max_length` character vectors are retained. Otherwise, the end of the character vector list is replaced with... The padding continues until the length of the character vector list reaches `icd_max_length`. At this point, each ICD-10 encoded disease name has generated a character vector list with a uniform length of `icd_max_length`. This character vector list can be viewed as a matrix of shape `[icd_max_length, d]`, serving as the corresponding ICD-10 encoding matrix. Next, a trainable neural network dimensionality reduction module is constructed. This module takes the ICD encoding matrix as input and outputs a vector of dimension `h`, which is the ICD-10 vector. Thus, for each ICD-10 code, a corresponding ICD-10 vector of dimension `h` has been generated.

[0088] S5. Replace each ICD code in each cause-of-death chain sample with the ICD vector corresponding to that ICD code to obtain the vector matrix corresponding to each cause-of-death chain sample.

[0089] Specifically, in this embodiment, the four ICD-10 codes on each cause of death chain are replaced with their respective ICD-10 vectors. After processing, each cause of death chain corresponds to a matrix of shape [4,h], which is named M.

[0090] S6. Randomly initialize the masking vector, randomly select a row vector in the vector matrix corresponding to each cause of death chain sample, and replace the selected row vector with the masking vector to obtain the masking matrix corresponding to each cause of death chain sample.

[0091] Specifically, in this embodiment, a trainable masking vector of dimension h is randomly initialized and named... Randomly select a row vector in matrix M and replace it with The replaced matrix is ​​named M_masked.

[0092] S7. Construct a cause-of-death chain detection model, input the masking matrix corresponding to each cause-of-death chain sample into the cause-of-death chain detection model, and output the probability of each ICD code being located in each order of each cause-of-death chain sample.

[0093] Furthermore, step S7 specifically includes:

[0094] The masking matrix corresponding to each cause of death chain sample is input into a bidirectional GRU network for processing. Then, an affine transformation is performed on the output of the bidirectional GRU network through a fully connected layer to obtain the first matrix after processing each cause of death chain sample.

[0095] The ICD vectors corresponding to each ICD code are combined to form a second matrix. The probability of each ICD code being located in each order of each cause-of-death chain sample is calculated using the first matrix and the second matrix using the following formula:

[0096] P = softmax(O*WT)

[0097] Where P represents the probability that each ICD code is located in each order of each cause-of-death chain sample, O represents the first matrix after processing each cause-of-death chain sample, W represents the second matrix, and T is the matrix transpose operation.

[0098] Specifically, in this embodiment, a bidirectional GRU network with a hidden state dimension of h_gru is used to process the M_masked matrix. Since the length of the cause-of-death chain is 4, the output shape of the bidirectional GRU network is [4, h_gru*2]. Then, a trainable fully connected layer is randomly initialized to perform an affine transformation on the output matrix of the bidirectional GRU network, generating a matrix with a shape of [4, h]. The first matrix after processing each cause-of-death chain sample is obtained and named O.

[0099] Since the number of ICD-10 codes included in the modeling is v icd, and each ICD-10 code has a corresponding ICD-10 vector with a dimension of h. So these v icd ICD-10 codes can be arranged in a certain order to form an ICD-10 code list, and correspondingly, these v icd ICD-10 vectors are also arranged in the same order, and the obtained ICD-10 vector list can be regarded as a matrix, obviously the shape of this matrix is [v icd, h], that is, the second matrix, which is named as matrix W. Finally, the probability P of each ICD-10 code in each position is calculated by O and W, and the specific relationship is P = softmax (O * W.T), note that the softmax function here is applied to each row vector of the matrix O * W.T, obviously the shape of P is [4, v icd], the i-th row and the j-th column of P ij The meaning of P

[0100] S8, according to the probability of each ICD code in each order in each death chain sample, calculate the total loss of all death chain samples;

[0101] Further, step S8 specifically comprises:

[0102] According to the probability of each ICD code in each order in each death chain sample, the loss of a single death chain sample is calculated by the following formula:

[0103] loss = -log (P ij )

[0104] Wherein, loss represents the loss of a single death chain sample, i represents the order of the ICD code corresponding to the row vector replaced by the masking vector in the death chain, and j represents the order of the ICD code in the second matrix;

[0105] According to the loss of the single death chain sample, the total loss of all death chain samples is calculated by the following formula:

[0106]

[0107] Wherein, loss_ represents the total loss of all death chain samples, n represents the sample number of death chain samples, k represents the index of death chain sample, and loss k represents the k-th death chain sample.

[0108] Specifically, in the embodiment, the loss of a single death chain is calculated: before constructing the death chain detection model, there is a masking operation, a row vector in the matrix M is randomly selected and replaced with The row vector number of M is 4. The row vector number of the output P of the cause-of-death chain detection model is also 4, so the row vectors of M and P are one-to-one corresponding. We calculate the single cause-of-death chain loss only to calculate the loss corresponding to the hidden row vector. Suppose the position of the ICD-10 code corresponding to the hidden row vector in the cause-of-death chain is i, and the position of the ICD-10 code in the ICD-10 code list is j, then the single cause-of-death chain loss is loss = -log(P ij );

[0109] Calculate the total loss of the cause-of-death chain sample: suppose the sample number of the cause-of-death chain is n, and according to the previous step, a loss can be calculated for each cause-of-death chain. Let the loss of the kth cause-of-death chain be loss k , so the total loss of all cause-of-death chain samples is

[0110]

[0111] S9, based on the total loss, iteratively training the cause-of-death chain detection model, and when the total loss converges, obtaining a trained cause-of-death chain detection model.

[0112] Further, step S9 specifically includes:

[0113] Based on the total loss, using the gradient descent method, iteratively training the cause-of-death chain detection model, and when the total loss converges, obtaining a trained cause-of-death chain detection model.

[0114] In this embodiment, an intelligent cause-of-death chain detection model is constructed to automatically detect and analyze the cause-of-death chain, effectively using intelligent tools to replace manual operation and reducing manual intervention, thereby solving the problems of high technical threshold, low efficiency and low accuracy when manually detecting the cause-of-death chain.

[0115] At the same time, through the analysis of the problems existing in the existing conventional detection method, it is found that the reason why the conventional anomaly detection method cannot achieve good results is that there are too many disease categories, and some disease categories are not common, and there are few or even no complete cause-of-death chain sample data, which leads to uneven sample data obtained in the conventional detection method, and the long tail distribution problem, and thus the conventional detection method cannot correctly detect the cause-of-death chain including the disease, and the detection effect is not good. In order to solve this problem, the prior information of the disease is introduced through the ICD code and Chinese explanation of all diseases, which can make the detection model in this embodiment obtain relevant information of the disease category even if it has not seen the disease category and has no related cause-of-death chain sample data, so as to correctly detect the cause-of-death chain and solve the problems of long tail distribution and poor detection effect.

[0116] Embodiment 2

[0117] like Figure 4 As shown, this embodiment provides a method for detecting cause-of-death chains based on Chinese disease explanations, including:

[0118] S10. Obtain the cause-of-death chain to be detected;

[0119] S20. Initialize word vectors by replacing the ICD codes in each sequence of the cause-of-death chain to be detected with the corresponding ICD vectors to obtain the vector matrix of the cause-of-death chain to be detected.

[0120] Specifically, each Chinese character corresponds to a trainable character vector. In this step, the initialization process is not random; it uses pre-trained corresponding parameters for initialization.

[0121] Specifically, in this embodiment, the four ICD-10 codes on the cause of death chain to be detected are replaced with their respective ICD-10 vectors. After processing, each cause of death chain corresponds to a matrix of shape [4,h], and this matrix is ​​named M.

[0122] S30. Initialize the masking vector, and replace each row vector in the vector matrix of the cause of death chain to be detected with the masking vector to obtain several masking matrices of the cause of death chain to be detected.

[0123] In this step, the initialization process is not a random initialization process, but is initialized using the corresponding parameters that have been trained. S40, Input the several masking matrices of the cause-of-death chain to be detected into the cause-of-death chain detection model obtained in Example 1, and output the probability of each ICD code being located in each order of the cause-of-death chain samples to be detected;

[0124] S50. Calculate the total loss of the cause of death chain to be detected based on the probability that each ICD code is located in each order of the sample to be detected.

[0125] Specifically, in this embodiment, the masking and loss calculation are as follows: the 1st, 2nd, 3rd, and 4th row vectors of matrix M are masked respectively, and the trained cause-of-death chain detection model obtained in Example 1 is input to obtain the probability that each ICD code is located in each order of the cause-of-death chain samples to be detected. Then, the loss of each individual cause-of-death chain is calculated. Accordingly, the individual cause-of-death chains are denoted as l1, l2, l3, and l4 respectively, and the total loss of the cause-of-death chains to be detected is calculated. Clearly, the larger the value of 'e', ​​the more likely the cause-of-death chain is to be incorrect.

[0126] S60. Determine whether the total loss of the cause of death chain to be detected is greater than a preset threshold. If yes, determine that the cause of death chain to be detected is incorrect. If no, determine that the cause of death chain to be detected is correct.

[0127] Specifically, in this embodiment, a threshold t is preset, if e>t, it is considered that the cause chain has an error, otherwise it is considered that the cause chain is correct.

[0128] Embodiment 3

[0129] As shown in Figure 5 The embodiment provides a cause chain detection model training system based on Chinese interpretation of diseases, which comprises:

[0130] The coding interpretation collection module 100 is configured to collect ICD codes corresponding to all diseases and Chinese interpretations thereof.

[0131] The cause chain sample acquisition module 200 is configured to acquire a plurality of cause chain samples, each of which is composed of a plurality of ICD codes connected in sequence.

[0132] The word vector initialization module 300 is configured to randomly initialize the word vector.

[0133] Specifically, each Chinese character has a corresponding trainable word vector, and the process of initializing the word vector by the word vector initialization module 300 is a random initialization process.

[0134] The coding vectorization module 400 is configured to replace Chinese characters in Chinese interpretations of ICD codes in the cause chain sample with word vectors corresponding to the Chinese characters, to obtain ICD vectors corresponding to the ICD codes.

[0135] The cause chain sample vectorization module 500 is configured to replace each ICD code in each cause chain sample with an ICD vector corresponding to the ICD code, to obtain a vector matrix corresponding to each cause chain sample.

[0136] The masking module 600 is configured to randomly initialize a trainable masking vector, randomly select a row vector in the vector matrix corresponding to each cause chain sample, replace the selected row vector with the masking vector, and obtain a masking matrix corresponding to each cause chain sample.

[0137] The model construction module 700 is configured to construct a cause chain detection model, input the masking matrix corresponding to each cause chain sample into the cause chain detection model, and output probabilities of each ICD code in each sequence in each cause chain sample.

[0138] The loss calculation module 800 is configured to calculate a total loss of all cause chain samples according to the probabilities of each ICD code in each sequence in each cause chain sample.

[0139] The training module 900 is configured to iteratively train the cause chain detection model based on the total loss, and obtain a trained cause chain detection model when the total loss converges.

[0140] Embodiment 4

[0141] As Figure 6 shown, the embodiment provides a cause-of-death chain detection system based on disease Chinese interpretation, comprising:

[0142] The to-be-detected cause-of-death chain acquisition module 110 is configured to acquire a to-be-detected cause-of-death chain.

[0143] The to-be-detected cause-of-death chain vectorization module 220 is configured to initialize a word vector, replace ICD codes in the to-be-detected cause-of-death chain in sequence with corresponding ICD vectors according to the initialized word vector, and obtain a vector matrix of the to-be-detected cause-of-death chain.

[0144] Specifically, the to-be-detected cause-of-death chain vectorization module 220 is not a random initialization process, but is initialized with corresponding trained parameters.

[0145] The to-be-detected cause-of-death chain masking module 330 is configured to initialize a masking vector, replace each row vector in the vector matrix of the to-be-detected cause-of-death chain with the masking vector, and obtain a plurality of masking matrices of the to-be-detected cause-of-death chain.

[0146] Specifically, the to-be-detected cause-of-death chain masking module 330 is not a random initialization process, but is initialized with corresponding trained parameters.

[0147] The to-be-detected cause-of-death chain probability calculation module 440 is configured to input the plurality of masking matrices of the to-be-detected cause-of-death chain into the trained cause-of-death chain detection model obtained by the training method, and output probabilities of each ICD code being in each sequence in the to-be-detected cause-of-death chain sample.

[0148] The to-be-detected cause-of-death chain total loss calculation module 550 is configured to calculate a total loss of the to-be-detected cause-of-death chain according to the probabilities of each ICD code being in each sequence in the to-be-detected cause-of-death chain sample.

[0149] The judgment module 660 is configured to determine whether the total loss of the to-be-detected cause-of-death chain is greater than a preset threshold, and if so, determine that the to-be-detected cause-of-death chain is incorrect, and if not, determine that the to-be-detected cause-of-death chain is correct.

[0150] Embodiment 5

[0151] The embodiment provides an electronic device, which comprises a memory and a processor. The memory stores a computer program. When the processor executes the computer program, the training method of the cause-of-death chain detection model in the embodiment 1 is implemented, or the cause-of-death chain detection method in the embodiment 2 is implemented.

[0152] Embodiment 6

[0153] The embodiment provides a computer storage medium, which stores a computer program, and the computer program is executed by a processor to implement the cause-of-death chain detection model training method described in the embodiment 1 or implement the cause-of-death chain detection method described in the embodiment 2.

[0154] Obviously, the above embodiments of the present application are only examples for clearly illustrating the technical solutions of the present application, and are not intended to limit the specific implementation of the present application. Any modification, equivalent replacement and improvement made within the spirit and principle of the claims of the present application should be included in the protection scope of the claims of the present application.

Claims

1. A method for training a death chain detection model based on Chinese disease explanations, characterized in that, include: Collect all ICD codes and their Chinese explanations for all diseases; Obtain several death chain samples, each of which is composed of several ICD codes connected in sequence; Each Chinese character has a corresponding trainable character vector, which is randomly initialized. Replace the Chinese characters in the Chinese explanation of each ICD code in the cause-of-death chain sample with the corresponding character vector to obtain the ICD vector corresponding to each ICD code; Replace each ICD code in each cause-of-death chain sample with the ICD vector corresponding to that ICD code to obtain the vector matrix corresponding to each cause-of-death chain sample. Randomly initialize trainable masking vectors, randomly select a row vector from the vector matrix corresponding to each cause-of-death chain sample, and replace the selected row vector with the masking vector to obtain the masking matrix corresponding to each cause-of-death chain sample. Construct a cause-of-death chain detection model, input the masking matrix corresponding to each cause-of-death chain sample into the cause-of-death chain detection model, and output the probability of each ICD code being located in each order of each cause-of-death chain sample. Calculate the total loss of all cause-of-death chain samples based on the probability that each ICD code is located in each order of each cause-of-death chain sample. Based on the total loss, the cause-of-death chain detection model is iteratively trained. When the total loss converges, the trained cause-of-death chain detection model is obtained.

2. The method for training a death chain detection model based on Chinese disease explanations according to claim 1, characterized in that, The Chinese characters in the Chinese explanations of each ICD code in the cause-of-death chain sample are replaced with the corresponding character vectors to obtain the ICD vectors for each ICD code, specifically including: Replace the Chinese characters in the Chinese explanation of each ICD code in the cause of death chain sample with the corresponding character vector to obtain a list of character vectors corresponding to each ICD code; The maximum length of the preset character vector list is used to unify the length of the character vector lists corresponding to each ICD encoding, thereby obtaining the ICD encoding matrix corresponding to each ICD encoding. A dimensionality reduction module is constructed. The ICD encoding matrix corresponding to each ICD encoding is input into the dimensionality reduction module, and the ICD vector corresponding to each ICD encoding is output.

3. The method for training a death chain detection model based on Chinese disease explanations according to claim 1, characterized in that, A cause-of-death chain detection model is constructed. The masking matrix corresponding to each cause-of-death chain sample is input into the cause-of-death chain detection model, and the probability of each ICD code being located in each order of each cause-of-death chain sample is output. Specifically, this includes: The masking matrix corresponding to each cause of death chain sample is input into a bidirectional GRU network for processing. Then, an affine transformation is performed on the output of the bidirectional GRU network through a fully connected layer to obtain the first matrix after processing each cause of death chain sample. The ICD vectors corresponding to each ICD code are combined to form a second matrix. The probability of each ICD code being located in each order of each cause-of-death chain sample is calculated using the first matrix and the second matrix using the following formula: P = softmax(O*WT) Where P represents the probability that each ICD code is located in each order of each cause-of-death chain sample, O represents the first matrix after processing each cause-of-death chain sample, W represents the second matrix, and T is the matrix transpose operation.

4. The method for training a death chain detection model based on Chinese disease explanations according to claim 3, characterized in that, Based on the probability of each ICD code being located in each order of each cause-of-death chain sample, the total loss of all cause-of-death chain samples is calculated, specifically including: Based on the probability that each ICD code lies in each order within each cause-of-death chain sample, the loss for a single cause-of-death chain sample is calculated using the following formula: loss=-log(P ij ) Where loss represents the loss of a single cause-of-death chain sample, i represents the order of the ICD code corresponding to the row vector replaced by the masked vector in the cause-of-death chain, and j represents the order of the ICD code in the second matrix; Based on the loss of the individual cause-of-death chain sample, the total loss of all cause-of-death chain samples is calculated using the following formula: Where `loss_total` represents the total loss of all cause-of-death chain samples, `n` represents the number of cause-of-death chain samples, and `k` represents the index of the cause-of-death chain sample. k This represents the sample of the k-th cause-of-death chain.

5. The method for training a death chain detection model based on Chinese disease explanations according to claim 1, characterized in that, Based on the total loss, the cause-of-death chain detection model is iteratively trained. When the total loss converges, the trained cause-of-death chain detection model is obtained, specifically including: Based on the total loss, the cause-of-death chain detection model is iteratively trained using the gradient descent method. When the total loss converges, the trained cause-of-death chain detection model is obtained.

6. A method for detecting cause-of-death chains based on Chinese disease explanations, characterized in that, include: Obtain the cause-of-death chain to be detected; Each Chinese character has a corresponding trainable character vector, and the character vector is initialized. Based on the initialized word vector, the ICD codes in each sequence of the cause of death to be detected are replaced with the corresponding ICD vectors to obtain the vector matrix of the cause of death to be detected. Initialize the masking vector, and replace each row vector in the vector matrix of the cause of death chain to be detected with the masking vector to obtain several masking matrices of the cause of death chain to be detected. The masking matrices of the cause-of-death chain to be detected are respectively input into the trained cause-of-death chain detection model obtained in claim 1, and the probability of each ICD code being located in each order of the cause-of-death chain sample to be detected is output. The total loss of the cause of death chain to be detected is calculated based on the probability that each ICD code is located in each order of the sample to be detected. Determine whether the total loss of the cause of death to be detected is greater than a preset threshold. If yes, the cause of death to be detected is determined to be incorrect; otherwise, the cause of death to be detected is determined to be correct.

7. A training system for a cause-of-death chain detection model based on Chinese disease explanations, characterized in that, include: The code interpretation collection module is used to collect the ICD codes and their Chinese interpretations for all diseases; The cause-of-death chain sample acquisition module is used to acquire several cause-of-death chain samples, each of which is composed of several ICD codes connected in sequence. The word vector initialization module is used to randomly initialize word vectors; Each Chinese character has a corresponding trainable character vector; The encoding vectorization module is used to replace the Chinese characters in the Chinese explanation of each ICD code in the cause of death chain sample with the corresponding character vector, so as to obtain the ICD vector corresponding to each ICD code; The cause-of-death chain sample vectorization module is used to replace each ICD code in each cause-of-death chain sample with the ICD vector corresponding to that ICD code, so as to obtain the vector matrix corresponding to each cause-of-death chain sample. The masking module is used to initialize the masking vector, randomly select a row vector in the vector matrix corresponding to each cause of death chain sample, replace the selected row vector with the masking vector, and obtain the masking matrix corresponding to each cause of death chain sample. The model building module is used to build a cause-of-death chain detection model. The masking matrix corresponding to each cause-of-death chain sample is input into the cause-of-death chain detection model, and the probability of each ICD code being located in each order of each cause-of-death chain sample is output. The loss calculation module is used to calculate the total loss of all cause-of-death chain samples based on the probability that each ICD code is located in each order of each cause-of-death chain sample. The training module is used to iteratively train the cause-of-death chain detection model based on the total loss, and obtain the trained cause-of-death chain detection model when the total loss converges.

8. A cause-of-death chain detection system based on Chinese disease explanations, characterized in that, include: The module for obtaining the cause of death chain to be detected is used to obtain the cause of death chain to be detected. The vectorization module for the cause-of-death chain to be detected is used to initialize the word vectors and, based on the initialized word vectors, replace the ICD codes in each sequence of the cause-of-death chain to be detected with the corresponding ICD vectors to obtain the vector matrix of the cause-of-death chain to be detected. Each Chinese character has a corresponding trainable character vector; The detection cause-of-death chain masking module is used to initialize the masking vector and replace each row vector in the vector matrix of the detection cause-of-death chain with the masking vector to obtain several masking matrices of the detection cause-of-death chain. The probability calculation module for the cause of death chain to be detected is used to input several masking matrices of the cause of death chain to be detected into the trained cause of death chain detection model obtained in claim 1, and output the probability of each ICD code being located in each order of the cause of death chain samples to be detected. The total loss calculation module for the cause of death chain to be detected is used to calculate the total loss of the cause of death chain to be detected based on the probability that each ICD code is located in each order in the sample of the cause of death chain to be detected. The judgment module is used to determine whether the total loss of the cause of death chain to be detected is greater than a preset threshold. If it is, the cause of death chain to be detected is determined to be incorrect; otherwise, the cause of death chain to be detected is determined to be correct.

9. An electronic device comprising a memory and a processor, the memory storing a computer program, characterized in that, When the processor executes the computer program, it implements the death chain detection model training method as described in any one of claims 1 to 5, or the death chain detection method as described in claim 6.

10. A computer storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the death chain detection model training method as described in any one of claims 1 to 5, or the death chain detection method as described in claim 6.

Citation Information

Patent Citations

  • Disease classification code identification method and device, computer equipment and storage medium

    CN110827929A

  • Intelligent system for assisting dead cause classification coding

    CN112530582A