A training method, system, terminal and medium for a pulmonary nodule image classification model
By preprocessing and 3D reconstructing lung nodule CT images, generating training samples and fusing them with normal lung CT images, the problem of insufficient data was solved and the accuracy and robustness of the lung nodule image classification model were improved.
Patent Information
- Application Number
- CN202311136983.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-05
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2043-09-05
AI Technical Summary
How to improve the accuracy and robustness of lung nodule image classification models based on deep learning algorithms when the amount of medical image data is small.
By obtaining lung nodule CT images for preprocessing, three-dimensional image sequences are generated using three-dimensional reconstruction technology, the grayscale value probability is calculated, and normal lung CT images are fused to generate training samples. The deep learning model is trained using real image samples.
The accuracy and robustness of the lung nodule image classification model are improved under limited data volume, and the data volume and classification ability of the model are enhanced.
Smart Images

Figure CN117218484B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of medical technology, and in particular to a training method, system, terminal and medium for a lung nodule image classification model. Background Art
[0002] Among various high-incidence cancers, lung cancer has the highest mortality rate. Lung nodules are an early sign of lung cancer. Because computed tomography (CT) scans are high-resolution, fast, and easy to use, doctors can use a patient's CT data to understand the grayscale, texture, and density of body tissues and detect subtle differences. This allows doctors to identify and predict whether lung nodules are early-stage cancers.
[0003] Computer Aided Diagnosis (CAD) is a technology based on computer-assisted medical diagnosis and has been used to help doctors analyze CT data. After each patient's CT scan is completed, there will be hundreds of images, which is a large amount of information, which puts a burden on doctors. CAD systems can more effectively and accurately identify suspicious areas of lung nodules and assist doctors in diagnosis. Applying deep learning models to detect and classify lung nodules can improve work efficiency. Traditional lung nodule detection methods rely on the selection of manually extracted nodule features and useful feature training. With the widespread application of deep learning and its combination with the field of image processing, deep learning algorithms have gradually become a research hotspot. However, the lack of medical image data makes it difficult to apply deep learning methods in this field.
[0004] Therefore, how to train the lung nodule image classification model based on deep learning algorithm when the amount of medical image data is small, and further improve the accuracy and robustness of the lung nodule image classification model, is a technical problem that needs to be solved urgently by those skilled in the art. Summary of the Invention
[0005] To address the above technical issues, this application provides a training method for a pulmonary nodule image classification model. This method can train a pulmonary nodule image classification model based on a deep learning algorithm using a relatively small amount of medical image data, further improving the accuracy and robustness of the pulmonary nodule image classification model. This application also provides a training system, terminal, and medium for a pulmonary nodule image classification model, all with the same technical effects.
[0006] The first purpose of this application is to provide a training method for a lung nodule image classification model.
[0007] The above-mentioned application objective 1 of this application is achieved through the following technical solutions:
[0008] A training method for a pulmonary nodule image classification model, comprising:
[0009] Obtain CT images of lung nodules;
[0010] Preprocessing the pulmonary nodule CT image to obtain a preprocessed image;
[0011] Using three-dimensional reconstruction technology, the pre-processed images are processed to obtain a three-dimensional image sequence of lung nodules;
[0012] Calculating, based on the pulmonary nodule three-dimensional image sequence, a probability that the grayscale value of each three-dimensional coordinate point of each image in the pulmonary nodule three-dimensional image sequence appears in the corresponding three-dimensional coordinate;
[0013] generating a first three-dimensional image sequence according to the probability that the grayscale values of the three-dimensional coordinate points of all images in the three-dimensional image sequence of the lung nodule appear in the corresponding three-dimensional coordinates;
[0014] Acquire a normal lung CT image, and fuse the first three-dimensional image sequence with the normal lung CT image to obtain a lung nodule training sample;
[0015] Acquire real image training samples, and use the lung nodule training samples and the real image training samples to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model.
[0016] Preferably, in the training method of the pulmonary nodule image classification model, obtaining a pulmonary nodule CT image includes:
[0017] Lung nodule CT images were obtained from the LUNA16 database.
[0018] Preferably, in the training method of the pulmonary nodule image classification model, the preprocessing of the pulmonary nodule CT image to obtain the preprocessed image includes:
[0019] Generating a mask image of the lung nodule CT image according to the nodule coordinates and diameter given by the LUNA16 database;
[0020] Performing denoising on the pulmonary nodule CT image to obtain a denoised image;
[0021] performing interpolation processing on the denoised image and the mask image to obtain an interpolated image;
[0022] Performing image normalization processing on the interpolated image to obtain a preprocessed image.
[0023] Preferably, in the training method of the pulmonary nodule image classification model, calculating, based on the pulmonary nodule three-dimensional image sequence, the probability of the grayscale value of each three-dimensional coordinate point of each image in the pulmonary nodule three-dimensional image sequence appearing in the corresponding three-dimensional coordinate includes:
[0024] Obtaining, according to the three-dimensional image sequence of the lung nodules, a grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of the lung nodules;
[0025] Counting the grayscale values of the same three-dimensional coordinate points in all images in the three-dimensional image sequence of the pulmonary nodule and the number of occurrences of each grayscale value;
[0026] According to the grayscale value of the same three-dimensional coordinate point and the number of occurrences of each grayscale value, the probability of the grayscale value of each three-dimensional coordinate point in each image in the three-dimensional image sequence of the lung nodule appearing in the corresponding three-dimensional coordinate is calculated.
[0027] Preferably, in the training method of the pulmonary nodule image classification model, the pulmonary nodule training samples and the real image training samples are used to train a pre-built pulmonary nodule image classification model based on a deep learning algorithm to obtain a trained pulmonary nodule image classification model, including:
[0028] Using a pixel embedding mechanism, the lung nodule training sample and the real image training sample are processed to obtain a training sample;
[0029] The training samples are used to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model.
[0030] Preferably, in the training method of the pulmonary nodule image classification model, the pixel embedding mechanism is used to process the pulmonary nodule training samples and the real image training samples to obtain training samples, including:
[0031] Performing standardized grayscale value assignment on each image in the lung nodule training sample and the real image training sample to obtain a first processed sample;
[0032] Multiplying the grayscale value of each pixel of each image in the first processed sample by a preset integer and rounding the obtained grayscale value to obtain a second processed sample;
[0033] Each single-valued pixel in each image in the second processed sample is replaced by a vector of shape 1×M to obtain a training sample, where M is the number of pixel embedding layers and the value of the vector is a preset parameter.
[0034] Preferably, in the training method of the pulmonary nodule image classification model, the pulmonary nodule image classification model is constructed based on a 3DVGG network and a 3DVNet network.
[0035] The second purpose of this application is to provide a training system for a lung nodule image classification model.
[0036] The second object of the present application is achieved through the following technical solutions:
[0037] A training system for a pulmonary nodule image classification model, comprising:
[0038] an acquisition unit, used for acquiring a CT image of a lung nodule;
[0039] A first processing unit is configured to preprocess the pulmonary nodule CT image to obtain a preprocessed image;
[0040] a second processing unit, configured to process the preprocessed image using a three-dimensional reconstruction technique to obtain a three-dimensional image sequence of the lung nodule;
[0041] a calculation unit, configured to calculate, based on the three-dimensional image sequence of pulmonary nodules, a probability that the grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of pulmonary nodules appears in the corresponding three-dimensional coordinates;
[0042] a generating unit, configured to generate a first three-dimensional image sequence according to the probability that the grayscale values of the three-dimensional coordinate points of all images in the three-dimensional image sequence of the pulmonary nodule appear in the corresponding three-dimensional coordinates;
[0043] a fusion unit, configured to obtain a normal lung CT image and fuse the first three-dimensional image sequence with the normal lung CT image to obtain a lung nodule training sample;
[0044] The training unit is used to obtain real image training samples, and use the lung nodule training samples and the real image training samples to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model.
[0045] The third purpose of this application is to provide a training terminal for a lung nodule image classification model.
[0046] The third object of the present application is achieved through the following technical solutions:
[0047] A training terminal for a pulmonary nodule image classification model, comprising: a storage medium and a processor;
[0048] The storage medium stores computer-executable instructions;
[0049] The processor executes the computer-executable instructions stored in the storage medium to implement any of the above-mentioned training methods for the pulmonary nodule image classification model.
[0050] The fourth object of this application is to provide a computer-readable storage medium.
[0051] The fourth object of the present application is achieved through the following technical solutions:
[0052] A computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement any of the above-mentioned training methods for the pulmonary nodule image classification model.
[0053] The above technical solution obtains a CT image of a lung nodule, preprocesses the CT image of the lung nodule, and obtains a preprocessed image; uses three-dimensional reconstruction technology to process the preprocessed image to obtain a three-dimensional image sequence of a lung nodule; calculates the probability of the grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of the lung nodule appearing in the corresponding three-dimensional coordinate according to the three-dimensional image sequence of the lung nodule; generates a first three-dimensional image sequence according to the probability of the grayscale value of the three-dimensional coordinate point of all images in the three-dimensional image sequence of the lung nodule appearing in the corresponding three-dimensional coordinate; obtains a normal lung CT image, and fuses the first three-dimensional image sequence with the normal lung CT image to obtain a lung nodule training sample, thereby obtaining a lung nodule training sample based on a small sample of lung nodule CT images to increase the amount of data. Furthermore, by obtaining real image training samples, using lung nodule training samples and real image training samples, a pre-built lung nodule image classification model based on a deep learning algorithm is trained to obtain a trained lung nodule image classification model. In this way, the lung nodule training samples are used as supplementary training data to train the lung nodule image classification model, which can improve the accuracy and robustness of the lung nodule image classification model. In summary, the above technical solution can train a lung nodule image classification model based on a deep learning algorithm when the amount of medical image data is small, and further improve the accuracy and robustness of the lung nodule image classification model. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments recorded in this application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0055] Figure 1Schematic diagram of a flow chart of a training method for a lung nodule image classification model provided in an embodiment of the present application;
[0056] Figure 2 Schematic diagram of the structure of a training system for a pulmonary nodule image classification model provided in an embodiment of the present application;
[0057] Figure 3 This is a structural diagram of a training terminal for a lung nodule image classification model provided in an embodiment of the present application. DETAILED DESCRIPTION
[0058] In order to help those skilled in the art better understand the technical solutions in this application, the technical solutions in the embodiments of this application will be clearly and completely described below. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without making any creative efforts shall fall within the scope of protection of this application.
[0059] In the embodiments provided in this application, it should be understood that the disclosed methods and systems can be implemented in other ways. The system embodiments described below are merely illustrative. For example, the division of units and modules is merely a logical function division. In actual implementation, there may be other division methods, such as: multiple units or modules can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or modules, which can be electrical, mechanical or other forms.
[0060] It should be understood that the use of "system," "device," "unit," and / or "module" in this application is merely a method for distinguishing different components, elements, parts, portions, or assemblies at different levels. However, if other terms can achieve the same purpose, the terms may be replaced by other expressions.
[0061] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be understood to indicate or imply relative importance or implicitly specify the number of technical features indicated. Thus, a feature specified as "first" or "second" may explicitly or implicitly include one or more of such features. Throughout the description of this application, "plurality" or "several" means two or more, unless otherwise specifically defined.
[0062] If a flow chart is used in this application, the flow chart is used to illustrate the operations performed by the system according to the embodiments of the application. It should be understood that the previous or subsequent operations are not necessarily performed in exact order. Instead, the steps can be processed in reverse order or simultaneously. At the same time, other operations can be added to these processes, or one or more operations can be removed from these processes.
[0063] It should also be noted that, in this document, terms such as "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that an article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such article or device. In the absence of further limitations, elements defined by the phrase "comprises a ..." do not exclude the presence of other identical elements in the article or device comprising the above elements.
[0064] The embodiments of the present application are written in a progressive manner.
[0065] like Figure 1 As shown, the embodiment of the present application provides a training method for a lung nodule image classification model, comprising:
[0066] S101. Obtain a CT image of a lung nodule;
[0067] In S101, specifically, a lung nodule CT image can be obtained from an existing public lung nodule database. For example, a lung nodule CT image can be obtained from the LIDC-IDRI database, which is collected by the National Cancer Institute of the United States and includes 1,010 patient samples, including 243,958 images. The database has annotated the CT image files with the location and specific coordinates of the nodules. The LIDC-IDRI database is currently a commonly used lung nodule detection database. Among them, the lung nodule CT images are used for the subsequent training of the lung nodule image classification model. However, the amount of lung nodule CT images in the existing public lung nodule database is limited, which is difficult to meet the training requirements of the deep learning model. Therefore, it is necessary to process the lung nodule CT images through subsequent steps to increase the data volume of the training samples.
[0068] In other embodiments, one implementation of this step includes: obtaining a lung nodule CT image from the LUNA16 database.
[0069] Among them, the LUNA16 database removes CT slices with a slice thickness greater than 3mm from the LIDC-IDRI database. The LUNA16 database has 888 cases of CT data. CT images are composed of multiple two-dimensional slices to form three-dimensional data (three different dimensions of Z, X, and Y). The annotation file "annotation.csv" of the database contains the annotation information of all 1,186 nodules (including the size coordinates and diameter of the nodules), and the annotation file "candidate.csv" contains the annotation information of 551,065 candidate nodules (including the size coordinates and category labels of the nodules). It should be noted that the acquisition method of pulmonary nodule CT images can also be other, and this application is not limited to this.
[0070] S102. Preprocessing the lung nodule CT image to obtain a preprocessed image;
[0071] In S102, in order to enhance the image quality, the lung nodule CT image is further preprocessed, wherein the preprocessing process can adopt existing image preprocessing methods, such as image denoising, image feature extraction, image normalization, etc., to finally obtain a preprocessed image.
[0072] In other embodiments, one implementation method of this step includes: generating a mask image of the lung nodule CT image based on the nodule coordinates and diameter given by the LUNA16 database; denoising the lung nodule CT image to obtain a denoised image; interpolating the denoised image and the mask image to obtain an interpolated image; and normalizing the interpolated image to obtain a preprocessed image.
[0073] Among them, denoising processing can reduce the noise of lung nodule CT images and improve image quality; mask interpolation processing can reduce the interference areas in the CT image and only retain the effective size area containing the nodules; normalization processing can adjust the pixel values in the image to a reasonable range, facilitating subsequent image processing tasks, thereby improving the accuracy and efficiency of the lung nodule image classification model.
[0074] S103. Processing the preprocessed image using 3D reconstruction technology to obtain a 3D image sequence of the lung nodule;
[0075] In S103, CT scanning technology is the most effective method for detecting lung nodules. After obtaining the image volume data output by the CT medical imaging device, an appropriate 3D reconstruction algorithm can be selected based on actual needs to process the pre-processed images to obtain a 3D image sequence of the lung nodules. 3D reconstruction refers to the process of reconstructing 3D information from single-view or multi-view images. Scanned images and data are reconstructed by a computer to produce intuitive, stereoscopic, and high-quality 3D images.
[0076] In other embodiments, one of the implementation methods of this step specifically includes: (1) using a two-dimensional image center comparison algorithm for the preprocessed image, finding a center point with the same grayscale value in the selected nodule coordinate area, and then converting it into a three-dimensional matrix through a conversion function, establishing a grayscale value correspondence between the nodule and the surrounding tissue, so as to clarify the difference in grayscale values between the nodule and the surrounding normal tissue; (2) converting the original image sequence into three-dimensional matrix data to form a three-dimensional space containing the grayscale values of the nodule and normal tissue; (3) reconstructing the three-dimensional matrix data of the nodule into a three-dimensional stereogram, and fine-tuning it according to the grayscale correspondence between the three-dimensional stereogram of the nodule and the surrounding tissue, and achieving separation of the nodule from the surrounding tissue background by reducing the overall grayscale value, thereby obtaining a more accurate three-dimensional stereogram of the lung nodule, thereby obtaining a high-quality three-dimensional image sequence of the lung nodule containing grayscale values.
[0077] S104. Calculating, based on the 3D image sequence of the pulmonary nodule, the probability that the grayscale value of each 3D coordinate point of each image in the 3D image sequence of the pulmonary nodule appears in the corresponding 3D coordinate;
[0078] In S104, specifically, based on the three-dimensional image sequence of lung nodules, the grayscale value of each three-dimensional coordinate point of each image in the sequence and the number of times each grayscale value appears in the corresponding three-dimensional coordinate can be obtained. Based on the above data, statistical calculations are performed to obtain the probability of the grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of lung nodules appearing in the corresponding three-dimensional coordinate.
[0079] S105. Generate a first three-dimensional image sequence based on the probability that the grayscale values of the three-dimensional coordinate points of all images in the three-dimensional image sequence of the lung nodule appear in the corresponding three-dimensional coordinates;
[0080] In S105, specifically, based on the probability of the grayscale values of the three-dimensional coordinate points of all images in the three-dimensional image sequence of lung nodules appearing in the corresponding three-dimensional coordinates, grayscale values can be assigned according to the probability when generating a new image sequence (for example, if the grayscale value of a certain three-dimensional coordinate point in the three-dimensional image sequence of lung nodules is 100 and the probability of its appearing in the corresponding three-dimensional coordinates is 90%, then when generating the new image sequence, the grayscale value of the corresponding three-dimensional coordinate in the new image sequence is set to 100 with a probability of 90%), and finally a new first three-dimensional image sequence is obtained. The first three-dimensional image sequence is used as an artificial three-dimensional image of lung nodule lesions for subsequent training of the lung nodule image classification model.
[0081] S106. Obtain a normal lung CT image and fuse the first 3D image sequence with the normal lung CT image to obtain a lung nodule training sample;
[0082] In S106, normal lung CT images can be obtained from an existing public database. Normal lung CT images do not contain lung nodules. To increase the data volume, the first 3D image sequence generated in S105 is fused with the normal lung CT images to obtain lung nodule training samples. The lung nodule training samples serve as supplementary training data for subsequent training of the lung nodule image classification model.
[0083] In some other embodiments, one implementation method of this step specifically includes: (1) finding a three-dimensional coordinate point (x1, y1, z1) in the first three-dimensional image sequence, obtaining the grayscale value v1 corresponding to the three-dimensional coordinate point in the lung nodule, and replacing the grayscale value v2 corresponding to the same three-dimensional coordinate point (x1, y1, z1) in the normal lung CT image with v1; (2) repeating the above process (1) to replace the grayscale values corresponding to all three-dimensional coordinate points in the normal lung CT image, and finally generating new three-dimensional data of the lung nodule; (3) selecting all coordinate points in the three-dimensional data of the lung nodule, generating corresponding mask images, and obtaining lung nodule training samples.
[0084] S107. Obtain real image training samples, and use the lung nodule training samples and real image training samples to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model.
[0085] In S107, the real image training samples may include positive lung nodule three-dimensional training data and false positive lung nodule three-dimensional training data. Specifically, the real image training samples may be obtained from an existing lung nodule database (such as the LUNA16 database), and this application does not impose any restrictions on this. Using the lung nodule training samples and the real image training samples, the pre-built lung nodule image classification model based on the deep learning algorithm is trained to finally obtain a trained lung nodule image classification model; the model training process may adopt the existing model training method, and this application does not impose any restrictions on this. In this step, using the lung nodule training samples as supplementary training data to train the lung nodule image classification model can improve the accuracy and robustness of the lung nodule image classification model.
[0086] In other embodiments, the lung nodule image classification model can be constructed based on the 3DVGG network and the 3DVNet network, wherein the 3DVNet network is used as a segmentation network to extract suspected lung nodule areas, and the 3DVGG network is used to classify lung nodules and non-nodules. The specific model construction of the 3DVGG network and the 3DVNet network is an existing technology and is not described in detail in this application. It should be noted that the lung nodule image classification model can also be constructed based on other types of deep learning algorithms, and this application is not limited thereto.
[0087] Applying deep learning models to detect and classify pulmonary nodules can improve efficiency. Traditional pulmonary nodule detection methods rely on manually extracted nodule features and useful feature training. With the widespread application of deep learning and its integration with image processing, deep learning algorithms have gradually become a research hotspot. However, the lack of medical image data makes deep learning methods difficult to apply in this field.
[0088] In the above embodiment, a lung nodule CT image is obtained, and the lung nodule CT image is preprocessed to obtain a preprocessed image; the preprocessed image is processed using three-dimensional reconstruction technology to obtain a lung nodule three-dimensional image sequence; based on the lung nodule three-dimensional image sequence, the probability of the grayscale value of each three-dimensional coordinate point of each image in the lung nodule three-dimensional image sequence appearing in the corresponding three-dimensional coordinate is calculated; based on the probability of the grayscale value of the three-dimensional coordinate point of all images in the lung nodule three-dimensional image sequence appearing in the corresponding three-dimensional coordinate, a first three-dimensional image sequence is generated; a normal lung CT image is obtained, and the first three-dimensional image sequence is fused with the normal lung CT image to obtain a lung nodule training sample, thereby obtaining a lung nodule training sample based on a small sample of lung nodule CT images to increase the amount of data. Furthermore, by obtaining real image training samples, using the lung nodule training samples and the real image training samples, a pre-built lung nodule image classification model based on a deep learning algorithm is trained to obtain a trained lung nodule image classification model. In this way, the lung nodule training samples are used as supplementary training data to train the lung nodule image classification model, which can improve the accuracy and robustness of the lung nodule image classification model. In summary, the above embodiment can train the lung nodule image classification model based on a deep learning algorithm when the amount of medical image data is small, and further improve the accuracy and robustness of the lung nodule image classification model.
[0089] In other embodiments of the present application, one implementation of the step of calculating the probability of the grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of lung nodules appearing in the corresponding three-dimensional coordinates according to the three-dimensional image sequence of lung nodules includes:
[0090] S201. Obtaining the grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of the lung nodule according to the three-dimensional image sequence of the lung nodule;
[0091] In S201, specifically, a 3D image sequence of lung nodules is obtained by 3D reconstruction conversion of preprocessed images. According to the 3D image sequence of lung nodules, the grayscale value of each 3D coordinate point of each image in the image sequence can be obtained.
[0092] S202. Counting the grayscale values of the same three-dimensional coordinate points in all images of the three-dimensional image sequence of lung nodules and the number of occurrences of each grayscale value;
[0093] In S202, specifically, the grayscale values appearing in the same three-dimensional coordinate points of all images in the three-dimensional image sequence of lung nodules and the number of times each grayscale value appears are counted. Each nodule in the image corresponds to the position of a spatial pixel. During the statistical process, the center points of all images can be set to the same coordinate point for axis alignment to facilitate statistics on the probability of spatial pixel distribution of the image.
[0094] S203. Calculate the probability of the grayscale value of each 3D coordinate point in each image of the pulmonary nodule 3D image sequence appearing in the corresponding 3D coordinate based on the grayscale value of the same 3D coordinate point and the number of occurrences of each grayscale value.
[0095] In S203, specifically, the probability of the grayscale value of each three-dimensional coordinate point of each image appearing in the corresponding three-dimensional coordinate can be calculated according to the following formula:
[0096]
[0097] Where P represents the gray value v of the three-dimensional coordinate point (x, y, z) in the three-dimensional image sequence of the lung nodule i The probability of appearing in the corresponding three-dimensional coordinates (x, y, z), n i The gray value of the three-dimensional coordinate point (x, y, z) in the three-dimensional image sequence of the lung nodule is v i The number of occurrences of sum(n i ) represents the total number of occurrences of each grayscale value of the three-dimensional coordinate point (x, y, z) in the three-dimensional image sequence of the lung nodule.
[0098] In this embodiment, based on the above implementation steps, the probability of the grayscale value of each three-dimensional coordinate point in each image in the three-dimensional image sequence of lung nodules appearing in the corresponding three-dimensional coordinates can be accurately calculated, which is conducive to the subsequent generation of the first three-dimensional image sequence.
[0099] In other embodiments of the present application, one implementation of the steps of training a pre-built lung nodule image classification model based on a deep learning algorithm using lung nodule training samples and real image training samples to obtain a trained lung nodule image classification model includes:
[0100] S301. Processing the lung nodule training samples and the real image training samples using a pixel embedding mechanism to obtain training samples;
[0101] In S301, considering that the classification model is very sensitive to noise in image classification tasks, to overcome this problem, a pixel embedding mechanism is used to replace the single-valued pixels in the lung nodule training samples and the real image training samples with a vector of shape 1×M. The embedding size (i.e., the number of pixel embedding layers) is M, and the value of the vector is a preset parameter. The preset parameter is not fixed and its value needs to participate in the model training to minimize the loss function. Using the pixel embedding mechanism, the model can "understand" the meaning of the pixels and automatically learn to distinguish noise.
[0102] In some embodiments, one implementation of this step specifically includes:
[0103] S3011. Assigning a standardized grayscale value to each image in the lung nodule training sample and the real image training sample to obtain a first processed sample;
[0104] In S3011 , specifically, a normalized grayscale value is assigned to each image in the sample to obtain a first processed sample.
[0105] S3012. Multiply the grayscale value of each pixel of each image in the first processed sample by a preset integer, and round the obtained grayscale value to obtain a second processed sample;
[0106] In S3012, the grayscale value of each pixel of each image in the first processed sample is multiplied by a preset integer (for example, the preset integer can be set to 1000, and this application does not impose any restrictions on this), and the value of the integer part is taken to finally obtain the second processed sample.
[0107] S3013. Replace each single-valued pixel in each image in the second processed sample with a vector of shape 1×M to obtain a training sample, where M is the number of pixel embedding layers and the value of the vector is a preset parameter.
[0108] In S3013, a vector with a shape of 1×M is used to replace each single-valued pixel of each image in the second processing sample to complete pixel embedding, and finally obtain a training sample.
[0109] S302. Use the training samples to train the pre-built lung nodule image classification model based on the deep learning algorithm to obtain a trained lung nodule image classification model.
[0110] In S302, the training samples obtained in the above steps are used to train the pre-built lung nodule image classification model based on the deep learning algorithm to obtain a trained lung nodule image classification model; the model training process can adopt the existing model training method, and this application does not impose any restrictions on this.
[0111] It should be noted that in other embodiments, the training samples obtained in the aforementioned steps, as well as the lung nodule training samples and real image training samples that have not been processed using the pixel embedding mechanism, can also be used to jointly train a pre-built lung nodule image classification model based on a deep learning algorithm. This application does not impose any restrictions on this.
[0112] In this embodiment, the pixel embedding mechanism is used to introduce hidden variables, which can enable the lung nodule image classification model to better understand the meaning of the lung nodule sample pixels, thereby improving the accuracy and robustness of lung nodule classification.
[0113] like Figure 2 As shown, in another embodiment of the present application, a training system for a pulmonary nodule image classification model is also provided, comprising:
[0114] An acquisition unit 10 is used to acquire a CT image of a lung nodule;
[0115] A first processing unit 11 is configured to preprocess the pulmonary nodule CT image to obtain a preprocessed image;
[0116] The second processing unit 12 is configured to process the preprocessed image using a three-dimensional reconstruction technique to obtain a three-dimensional image sequence of the lung nodules;
[0117] A calculation unit 13 is used to calculate the probability of the grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of the lung nodule appearing in the corresponding three-dimensional coordinate according to the three-dimensional image sequence of the lung nodule;
[0118] A generating unit 14 is configured to generate a first three-dimensional image sequence based on the probability that the grayscale values of the three-dimensional coordinate points of all images in the three-dimensional image sequence of lung nodules appear in the corresponding three-dimensional coordinates;
[0119] a fusion unit 15, configured to obtain a normal lung CT image and fuse the first three-dimensional image sequence with the normal lung CT image to obtain a lung nodule training sample;
[0120] The training unit 16 is used to obtain real image training samples, and use the lung nodule training samples and the real image training samples to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model.
[0121] like Figure 3 As shown, in another embodiment of the present application, a training terminal for a lung nodule image classification model is also provided, comprising: a storage medium 20 and a processor 21;
[0122] The storage medium 20 stores computer-executable instructions;
[0123] The processor 21 executes the computer-executable instructions stored in the storage medium 20 to implement any of the above-mentioned training methods for the pulmonary nodule image classification model.
[0124] The processor 21 may include one or more processing cores. The processor 21 executes instructions, programs, code sets, or instruction sets stored in the storage medium 20, accesses data stored in the storage medium 20, and performs the various functions and processes data of the present application. The processor 21 may be at least one of an application-specific integrated circuit, a digital signal processor, a digital signal processing device, a programmable logic device, a field programmable gate array, a central processing unit, a controller, a microcontroller, and a microprocessor. It is understood that for different devices, the electronic components used to implement the functions of the processor 21 may also be other.
[0125] The storage medium 20 may be used to store instructions, programs, codes, code sets, or instruction sets. The storage medium 20 may include a program storage area and a data storage area. The program storage area may store instructions for implementing an operating system, instructions for at least one function, and instructions for implementing any of the aforementioned training methods for pulmonary nodule image classification models; the data storage area may store data involved in any of the aforementioned training methods for pulmonary nodule image classification models.
[0126] In another embodiment of the present application, a computer-readable storage medium is further provided, in which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, they are used to implement any of the above-mentioned training methods for the pulmonary nodule image classification model.
[0127] The computer-readable storage medium may be any medium capable of storing program codes, such as a USB flash drive, a mobile hard disk, a read-only memory, a random access memory, or an optical disk.
[0128] The above description of the disclosed embodiments is intended to enable one skilled in the art to implement or use the present application. Various modifications to these embodiments will be readily apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application is not limited to the embodiments shown herein, but is intended to conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A training method for a pulmonary nodule image classification model, characterized in that: include: Obtain CT images of lung nodules; Preprocessing the pulmonary nodule CT image to obtain a preprocessed image; Using three-dimensional reconstruction technology, the pre-processed images are processed to obtain a three-dimensional image sequence of lung nodules; Calculating, based on the pulmonary nodule three-dimensional image sequence, a probability that the grayscale value of each three-dimensional coordinate point of each image in the pulmonary nodule three-dimensional image sequence appears in the corresponding three-dimensional coordinate; generating a first three-dimensional image sequence according to the probability that the grayscale values of the three-dimensional coordinate points of all images in the three-dimensional image sequence of the lung nodule appear in the corresponding three-dimensional coordinates; Acquire a normal lung CT image, and fuse the first three-dimensional image sequence with the normal lung CT image to obtain a lung nodule training sample; Acquire real image training samples, and use the lung nodule training samples and the real image training samples to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model.
2. The method according to claim 1, wherein The obtaining of a CT image of a lung nodule comprises: Lung nodule CT images were obtained from the LUNA16 database.
3. The method according to claim 2, wherein The preprocessing of the lung nodule CT image to obtain a preprocessed image includes: Generating a mask image of the lung nodule CT image according to the nodule coordinates and diameter given by the LUNA16 database; Performing denoising on the pulmonary nodule CT image to obtain a denoised image; performing interpolation processing on the denoised image and the mask image to obtain an interpolated image; Performing image normalization processing on the interpolated image to obtain a preprocessed image.
4. The method according to claim 1, wherein Calculating the probability of the grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of the lung nodule appearing in the corresponding three-dimensional coordinate according to the three-dimensional image sequence of the lung nodule includes: Obtaining, according to the three-dimensional image sequence of the lung nodules, a grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of the lung nodules; Counting the grayscale values of the same three-dimensional coordinate points in all images in the three-dimensional image sequence of the pulmonary nodule and the number of occurrences of each grayscale value; According to the grayscale value of the same three-dimensional coordinate point and the number of occurrences of each grayscale value, the probability of the grayscale value of each three-dimensional coordinate point in each image in the three-dimensional image sequence of the lung nodule appearing in the corresponding three-dimensional coordinate is calculated.
5. The method according to claim 1, wherein The method of using the lung nodule training samples and the real image training samples to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model includes: Using a pixel embedding mechanism, the lung nodule training sample and the real image training sample are processed to obtain a training sample; The training samples are used to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model.
6. The method according to claim 5, wherein The pixel embedding mechanism is used to process the lung nodule training sample and the real image training sample to obtain the training sample, including: Performing standardized grayscale value assignment on each image in the lung nodule training sample and the real image training sample to obtain a first processed sample; Multiplying the grayscale value of each pixel of each image in the first processed sample by a preset integer and rounding the obtained grayscale value to obtain a second processed sample; Each single-valued pixel in each image in the second processed sample is replaced by a vector of shape 1×M to obtain a training sample, where M is the number of pixel embedding layers and the value of the vector is a preset parameter.
7. The method according to claim 1, wherein The pulmonary nodule image classification model is constructed based on the 3DVGG network and the 3DVNet network.
8. A training system for a pulmonary nodule image classification model, characterized in that: include: an acquisition unit, used for acquiring a CT image of a lung nodule; A first processing unit is configured to preprocess the pulmonary nodule CT image to obtain a preprocessed image; a second processing unit, configured to process the preprocessed image using a three-dimensional reconstruction technique to obtain a three-dimensional image sequence of the lung nodule; a calculation unit, configured to calculate, based on the three-dimensional image sequence of pulmonary nodules, a probability that the grayscale value of each three-dimensional coordinate point of each image in the three-dimensional image sequence of pulmonary nodules appears in the corresponding three-dimensional coordinates; a generating unit, configured to generate a first three-dimensional image sequence according to the probability that the grayscale values of the three-dimensional coordinate points of all images in the three-dimensional image sequence of the pulmonary nodule appear in the corresponding three-dimensional coordinates; a fusion unit, configured to obtain a normal lung CT image and fuse the first three-dimensional image sequence with the normal lung CT image to obtain a lung nodule training sample; The training unit is used to obtain real image training samples, and use the lung nodule training samples and the real image training samples to train a pre-built lung nodule image classification model based on a deep learning algorithm to obtain a trained lung nodule image classification model.
9. A training terminal for a pulmonary nodule image classification model, characterized in that: include: storage media and processors; The storage medium stores computer-executable instructions; The processor executes the computer-executable instructions stored in the storage medium to implement the method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer-executable instructions, which are used to implement the method according to any one of claims 1 to 7 when executed by a processor.