2.5D Pneumonia Medical CT Image Classification Device and Equipment
Through the 2.5D pneumonia medical CT image classification device, the ConvNeXt optimization model of the 2D convolution layer is used to process 2.5D data, which solves the problems of difficulty in identifying pneumonia lesions and model complexity in the existing technology, and achieves efficient and accurate pneumonia CT images. Classification reduces the pressure on doctors to read pictures and improves diagnostic efficiency.
Patent Information
- Application Number
- CN202310781182.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-28
- Publication Date
- 2024-09-13
- Estimated Expiration
- 2043-06-28
AI Technical Summary
Existing medical CT image classification methods are difficult to accurately identify pneumonia lesions, especially in cases of lobular pneumonia. The training complexity of the 3D image classification network is high and easy to overfit. The model parameters are large, occupy a lot of computer resources, and are difficult to Efficiently handle multi-slice data.
A 2.5D pneumonia medical CT image classification device is used to obtain multiple consecutive slices of 3D lung medical CT image data through the target image slicing module to form 2.5D data, and the ConvNeXt optimization model of the 2D convolution layer is used for classification, combined with transfer learning and data augmentation techniques to train models to reduce complexity and improve accuracy.
On the basis of reducing the complexity and time-consuming of model training, it is possible to improve the execution efficiency and accuracy of pneumonia CT image classification, reduce the doctor's reading pressure, and improve the diagnostic efficiency and accuracy.
Smart Images

Figure CN116664953B
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of medical auxiliary equipment, and in particular to a 2.5D pneumonia medical CT image classification device and equipment. Background Art
[0002] In recent years, research on deep learning has made breakthroughs in various sub-fields of computer vision. It simulates neurons in the human brain area to learn how the human visual system processes external information, automatically extracts multi-level features of images and maps images into high-level abstract feature spaces to achieve specified tasks. Due to its excellent image feature extraction capabilities, there have also been a lot of related research in the field of medical image segmentation. In essence, medical image diagnosis is a computer vision problem. Pneumonia diagnosis is a common type of clinical medical image diagnosis, and pneumonia is a common respiratory disease in clinical practice. Its imaging manifestations are diverse, and CT images mainly show single or multiple infiltrates, ground-glass shadows, and consolidation shadows. However, in clinical practice, it is difficult to distinguish viral pneumonia with similar manifestations, and high workload may also lead to missed diagnosis of early lesions.
[0003] AI-assisted radiologists can improve the efficiency of daily differential diagnosis of pneumonia to a certain extent. Deep learning is an important branch in the field of AI. As a tool for image classification, it has attracted more and more attention in the medical field.
[0004] At present, in the existing medical CT image classification methods, deep learning can be used to input the patient's 2D CT image into a neural network model such as AACN-UNet to obtain the classification results corresponding to the patient's 2D CT image. However, due to the inherent characteristics of pneumonia medical CT images, the existing medical CT image classification methods cannot accurately determine whether the image contains lesions. For example, for lobular pneumonia cases, it is impossible to determine whether the white circular hole in the image is a lesion or a vascular cavity only through a single CT image. If a 3D CT image is input into a 3D image classification network, the training of its model will be more difficult than that of a 2D convolutional network, especially for CT data with multiple slices. When training the network, the video memory usage will become very large, requiring a large amount of computer resources. In addition, the number of model parameters will become relatively large, which is more prone to overfitting for precious and small amounts of medical data.
[0005] Therefore, it is urgent to design a device that can reduce the model and training complexity while ensuring the accuracy of pneumonia CT image classification on the basis of realizing the automation of pneumonia medical CT image classification. Summary of the invention
[0006] In view of this, the embodiments of the present application provide a 2.5D pneumonia medical CT image classification device and equipment to eliminate or improve one or more defects existing in the prior art.
[0007] One aspect of the present application provides a 2.5D pneumonia medical CT image classification device, comprising:
[0008] A target image slicing module, used to obtain a plurality of continuous slices corresponding to the target 3D lung medical CT image data, so as to form target 2.5D lung medical CT image data corresponding to the target 3D lung medical CT image data;
[0009] The target image classification module is used to input the target 2.5D lung medical CT image data into a preset ConvNeXt optimization model using a 2D convolutional layer, so that the ConvNeXt optimization model outputs a pneumonia lesion type recognition result corresponding to the target 2.5D lung medical CT image data.
[0010] In some embodiments of the present application, it further includes: a model training module connected to the target image classification module;
[0011] The model training module is used to train a ConvNeXt optimization model using a 2D convolutional layer according to each labeled 2.5D lung medical CT image sample, so that the ConvNeXt optimization model is used to output a pneumonia lesion type recognition result according to the input 2.5D lung medical CT image data;
[0012] The labels include: respective marks for indicating no pneumonia symptoms, lobar pneumonia, lobular pneumonia and interstitial pneumonia.
[0013] In some embodiments of the present application, it further includes: a historical image slicing module connected to the model training module;
[0014] The historical image slicing module is used to obtain multiple continuous slices corresponding to each historical 3D lung medical CT image sample in an image enhancement manner based on a preset slice number threshold, so as to obtain 2.5D lung medical CT image samples corresponding to each of the historical 3D lung medical CT image samples.
[0015] In some embodiments of the present application, it further includes: a historical image preprocessing module connected to the historical image slicing module;
[0016] The historical image preprocessing module is used to preprocess the historical 3D lung medical CT image data obtained for historical diagnosis of pneumonia lesions to obtain corresponding historical 3D lung medical CT image samples.
[0017] In some embodiments of the present application, it further includes: a model structure optimization module connected to the model training module;
[0018] The model structure optimization module is used to adjust and optimize the network structure of the ConvNeXt model for training with 2.5D lung medical CT image samples to generate a ConvNeXt optimized model using a 2D convolutional layer.
[0019] In some embodiments of the present application, it further includes: a model generalization test module connected between the target image classification module and the model training module;
[0020] The model generalization test module is used to test the generalization ability of the trained ConvNeXt optimization model and select the ConvNeXt optimization model whose corresponding test results meet the preset generalization performance requirements.
[0021] In some embodiments of the present application, the model training module includes:
[0022] A pre-training unit, used for pre-training a ConvNeXt optimization model using a 2D convolutional layer using pre-acquired historical lung medical CT image data of the same domain, to obtain a pre-trained ConvNeXt optimization model;
[0023] The transfer learning unit is used to iteratively train the pre-trained ConvNeXt optimization model using each labeled 2.5D lung medical CT image sample, and adopt a cosine annealing learning rate method during the training process to obtain a ConvNeXt optimization model for outputting pneumonia lesion type recognition results corresponding to the input 2.5D lung medical CT image data.
[0024] In some embodiments of the present application, the historical image preprocessing module includes:
[0025] A type conversion unit, used to convert the published DICOM sequence data into NIFIT format to obtain various historical 3D medical CT image data for historical diagnosis of pneumonia lesions;
[0026] A cropping unit, used for cropping the lung region from each of the historical 3D medical CT image data to obtain corresponding historical 3D lung medical CT image data;
[0027] A resampling unit, used for resampling and linear interpolation processing of each historical 3D lung medical CT image data;
[0028] The standardization processing unit is used to standardize each historical 3D lung medical CT image data that has been resampled and linearly interpolated, and convert each historical 3D lung medical CT image data that has been standardized into npy format to obtain the historical 3D lung medical CT image samples corresponding to each historical 3D medical CT image data.
[0029] In some embodiments of the present application, the ConvNeXt optimization model includes: an input layer, a 2D convolution layer, a layer normalization unit, three ConvNeXt blocks connected in sequence, a first downsampling group, a second downsampling group, a third downsampling group, a global average pooling layer, a layer normalization unit, a linear layer and an output layer;
[0030] The first downsampling group and the third downsampling group each include a downsampling layer and three ConvNeXt blocks connected in sequence, and the second downsampling group includes a downsampling layer and nine ConvNeXt blocks connected in sequence;
[0031] The ConvNeXt block includes: a depth-separable 2D convolutional layer, a layer normalization unit, a 2D convolutional layer, a Gaussian error linear unit, a 2D convolutional layer, a layer scaling unit, and a path discarding unit connected in sequence;
[0032] The downsampling layer includes: a layer normalization unit and a 2D convolution layer connected in sequence.
[0033] A second aspect of the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor implements the functions of the 2.5D pneumonia medical CT image classification device when executing the computer program.
[0034] The third aspect of the present application provides a computer-readable storage medium having a computer program stored thereon, which implements the functions of the 2.5D pneumonia medical CT image classification device when executed by a processor.
[0035] The 2.5D pneumonia medical CT image classification device provided by the present application, the target image slicing module, is used to obtain multiple continuous slices corresponding to the target 3D lung medical CT image data to form the target 2.5D lung medical CT image data corresponding to the target 3D lung medical CT image data; the target image classification module is used to input the target 2.5D lung medical CT image data into a preset ConvNeXt optimization model using a 2D convolutional layer, so that the ConvNeXt optimization model outputs the pneumonia lesion type recognition result corresponding to the target 2.5D lung medical CT image data, which can realize the automatic classification of pneumonia medical CT images, and can effectively improve the execution efficiency and convenience of the pneumonia CT image classification process on the basis of reducing the complexity and time consumption of model training, and can improve the reliability and accuracy of the pneumonia CT image classification results. Using a deep learning classification model to assist doctors in the classification of pneumonia and provide doctors with the range of pneumonia lesions will effectively reduce the pressure of doctors reading films and improve the efficiency and accuracy of doctors' diagnosis.
[0036] Additional advantages, purposes, and features of the present application will be partially described in the following description, and will become partially apparent to those skilled in the art after studying the following, or may be learned from the practice of the present application. The purposes and other advantages of the present application can be achieved and obtained by the structures specifically pointed out in the specification and the drawings.
[0037] Those skilled in the art will understand that the purposes and advantages that can be achieved by the present application are not limited to the above specific description, and the above and other purposes that can be achieved by the present application will be more clearly understood based on the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] The drawings described herein are used to provide a further understanding of the present application, constitute a part of the present application, and do not constitute a limitation of the present application. The components in the drawings are not drawn to scale, but are only for the purpose of illustrating the principles of the present application. In order to facilitate the illustration and description of some parts of the present application, the corresponding parts in the drawings may be enlarged, that is, they may become larger relative to other components in the exemplary device actually manufactured according to the present application. In the drawings:
[0039] Figure 1 This is a first structural schematic diagram of a 2.5D pneumonia medical CT image classification device in one embodiment of the present application.
[0040] Figure 2 This is a schematic diagram of the first connection relationship between the 2.5D pneumonia medical CT image classification device and other equipment in one embodiment of the present application.
[0041] Figure 3This is a second structural schematic diagram of a 2.5D pneumonia medical CT image classification device in one embodiment of the present application.
[0042] Figure 4 This is a third structural schematic diagram of a 2.5D pneumonia medical CT image classification device in one embodiment of the present application.
[0043] Figure 5 This is a fourth structural schematic diagram of a 2.5D pneumonia medical CT image classification device in one embodiment of the present application.
[0044] Figure 6 This is a schematic diagram of a second connection relationship between a 2.5D pneumonia medical CT image classification device and other devices in one embodiment of the present application.
[0045] Figure 7 This is a schematic diagram showing an example of the overall network architecture of the ConvNeXt optimization model in one embodiment of the present application.
[0046] Figure 8 A schematic diagram showing an example of the network architecture of a ConvNeXt block in a ConvNeXt optimization model in an embodiment of the present application.
[0047] Fig. 9 This is a schematic diagram showing an example of the network architecture of the downsampling layer in the ConvNeXt optimization model in one embodiment of the present application.
[0048] Fig.10 This is a flow chart of the 2.5D pneumonia medical CT image classification method based on the ConvNeXt optimization model provided in the application example of this application.
[0049] Fig.11 This is a schematic diagram showing an example of the execution logic of the 2.5D pneumonia medical CT image classification method based on the ConvNeXt optimization model provided in the application example of this application. DETAILED DESCRIPTION
[0050] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the implementation modes and the accompanying drawings. Here, the illustrative implementation modes and descriptions of the present application are used to explain the present application, but are not intended to limit the present application.
[0051] It should also be noted here that in order to avoid obscuring the present application due to unnecessary details, only the structures and / or processing steps closely related to the scheme according to the present application are shown in the accompanying drawings, while other details that are not very relevant to the present application are omitted.
[0052] It should be emphasized that the term “include / comprises” when used herein refers to the presence of features, elements, steps or components, but does not exclude the presence or addition of one or more other features, elements, steps or components.
[0053] It should also be noted that, unless otherwise specified, the term “connection” herein may refer not only to a direct connection but also to an indirect connection involving an intermediate.
[0054] Hereinafter, embodiments of the present application will be described with reference to the accompanying drawings. In the accompanying drawings, the same reference numerals represent the same or similar components, or the same or similar steps.
[0055] The existing convolutional neural network classification model uses 2D convolution to process 2D data, or uses 3D convolution to process 3D data. This application proposes a method of using 2D convolution to realize the classification of 2.5D pneumonia CT medical image data. To this end, improvements are made on the basis of the traditional 2D image classification network ConvNeXt to adapt it to the processing of 2.5D image data. During the training process, the 3D pneumonia CT image data is first preprocessed so that different 3D data can be in the same distribution, and then the data enhancement method is used to balance the amount of data between different categories and extract the 2.5D data that the model can process. The network is trained using transfer learning, which can enable the network to obtain better results when the amount of data is insufficient.
[0056] Based on this, the present application provides a 2.5D medical CT image classification device based on the ConvNeXt optimization model. Compared with the existing CNN-based classification model, in order to introduce the contextual relationship in the 3D data, a classification network based on 3D convolution will be used. The training of its model will be more difficult than that of a 2D convolutional network, especially for CT data with multiple slices. When training the network, the video memory occupancy will become very large, requiring a large amount of computer resources. In addition, the number of parameters of the model will also become relatively large, which is easier to overfit for precious and small amounts of medical data. However, if a conventional 2D convolution classification network is used, it is generally classified for a single image, so that contextual information, that is, information of adjacent slices, cannot be introduced. Therefore, the present application processes the original data from the perspective of 2.5D data, treats the data of a specified number of slices from the perspective of feature maps, and uses 2D convolution to realize the introduction of context. Thereby achieving the goal of a relatively small model, a relatively stable training process, and not easy to overfit.
[0057] Compared with the existing technology, the present application introduces contextual relationships. The image input into the network is no longer a single slice, but multiple continuous slices. For cases of lobular pneumonia, it is impossible to determine whether the white circular hole in the image is a lesion or a vascular cavity through only a single slice. It is necessary to introduce information from adjacent upper and lower slices to determine its type. However, the existing technology uses 2D convolution to extract information on a single slice, which makes it impossible to introduce contextual relationships. For this reason, the present application starts from a 2.5D perspective and uses 2D convolution to extract the features of 2.5D image information. On the one hand, contextual relationships can be introduced, and on the other hand, the use of 3D convolution is avoided to reduce the scale of the model, further reducing the overhead of computing resources and model overfitting.
[0058] The details are described in detail through the following examples.
[0059] In order to effectively improve the execution efficiency and convenience of the pneumonia CT image classification process on the basis of reducing the complexity and time consumption of model training, the embodiment of the present application provides a 2.5D pneumonia medical CT image classification device that can be implemented by the 2.5D pneumonia medical CT image classification device, see Figure 1 The 2.5D pneumonia medical CT image classification device 1 specifically includes the following contents:
[0060] The target image slicing module 10 is used to obtain a plurality of continuous slices corresponding to the target 3D lung medical CT image data to form target 2.5D lung medical CT image data corresponding to the target 3D lung medical CT image data.
[0061] In one or more embodiments of the present application, the target 3D lung medical CT image data refers to 3D lung medical CT image data to be classified, and the target 2.5D lung medical CT image data refers to each continuous image slice of the target 3D lung medical CT image data.
[0062] It can be understood that 3D refers to three dimensions, 2D refers to two dimensions, and 2.5D refers to pseudo 3D. In the present application, a 2.5D image refers to a plurality of continuous 2D image slices in a 3D image.
[0063] In the target image slicing module 10, in order to further improve the effectiveness and accuracy of 2.5D pneumonia medical CT image classification, 3D medical CT image data can be first received, and then the 3D medical CT image data can be converted into NIFIT format, and the lung area in the 3D medical CT image data can be cropped out to obtain the corresponding 3D lung medical CT image data, and the 3D lung medical CT image data can be resampled and linearly interpolated to obtain the target 3D lung medical CT image data corresponding to the 3D medical CT image data.
[0064] In a specific example, the total number of the plurality of continuous slices may be the same as the total number of continuous slices in each sample used in the training of the ConvNeXt optimization model, for example, 30 continuous slices. It is understood that the plurality of continuous slices refers to each image slice obtained by acquiring each slice with the same interval unit.
[0065] The target image classification module 20 is used to input the target 2.5D lung medical CT image data into a preset ConvNeXt optimization model using a 2D convolutional layer, so that the ConvNeXt optimization model outputs a pneumonia lesion type recognition result corresponding to the target 2.5D lung medical CT image data.
[0066] Since conventional ConvNeXt models use three RGB channels of color images as input, or a single channel of grayscale images as input, it is necessary to adjust and optimize the channels of the network framework of the ConvNeXt model. Therefore, in the target image classification module 20, the ConvNeXt optimization model refers to the adjustment and optimization of the network structure of the ConvNeXt model for training with 2.5D lung medical CT image samples, so that the ConvNeXt optimization model can adapt to the input of multiple slices.
[0067] The part of the 2.5D pneumonia medical CT image classification device provided in this application that performs 2.5D pneumonia medical CT image classification can be executed in the server or completed in the client device. Specifically, it can be selected according to the processing power of the client device and the limitations of the user's usage scenario. This application is not limited to this. If all operations are completed in the client device, the client device may also include a processor for specific processing of 2.5D pneumonia medical CT image classification.
[0068] The client device may have a communication module (i.e., a communication unit) that can communicate with a remote server to achieve data transmission with the server. The server may include a server on the task scheduling center side, and other implementation scenarios may also include a server on an intermediate platform, such as a server on a third-party server platform that has a communication link with the task scheduling center server. The server may include a single computer device, or a server cluster consisting of multiple servers, or a server structure of a distributed device.
[0069] The server and the client device may communicate with each other using any suitable network protocol, including network protocols that have not yet been developed on the date of filing this application. The network protocols may include, for example, TCP / IP, UDP / IP, HTTP, HTTPS, etc. Of course, the network protocols may also include, for example, RPC (Remote Procedure Call Protocol) and REST (Representational State Transfer) protocols used on top of the above protocols.
[0070] On this basis, in order to further improve the automation and intelligence of 2.5D pneumonia medical CT image classification, see Figure 2 The 2.5D pneumonia medical CT image classification device 1 can be communicated with the 3D lung medical CT image acquisition device 2 and the display device 3 (display or mobile device, etc.) respectively to receive the target 3D lung medical CT image data from the 3D lung medical CT image acquisition device 2 in real time, and send the pneumonia lesion type recognition result to the display device 3 for output display.
[0071] From the above description, it can be seen that the 2.5D pneumonia medical CT image classification device provided in the embodiment of the present application can realize the automatic classification of pneumonia medical CT images, and can effectively improve the execution efficiency and convenience of the pneumonia CT image classification process on the basis of reducing the complexity and time consumption of model training, and can improve the reliability and accuracy of the pneumonia CT image classification results. Using a deep learning classification model to assist doctors in the classification of pneumonia and provide doctors with the range of pneumonia lesions will effectively reduce the pressure of doctors reading films and improve the efficiency and accuracy of doctors' diagnosis.
[0072] In order to further improve the effectiveness and accuracy of 2.5D pneumonia medical CT image classification, in a 2.5D pneumonia medical CT image classification device provided in an embodiment of the present application, see Figure 3 The 2.5D pneumonia medical CT image classification device 1 further specifically includes the following contents:
[0073] A model training module 30 connected to the target image classification module 20;
[0074] The model training module 30 is used to train a ConvNeXt optimization model using a 2D convolutional layer according to each labeled 2.5D lung medical CT image sample, so that the ConvNeXt optimization model is used to output a pneumonia lesion type recognition result according to the input 2.5D lung medical CT image data;
[0075] The labels include: individual identifiers for indicating no pneumonia symptoms, lobar pneumonia, lobular pneumonia, and interstitial pneumonia. For example, 0 represents normal and no pneumonia symptoms, 1 represents lobar pneumonia, 2 represents lobular pneumonia, and 3 represents interstitial pneumonia. The pneumonia lesion type recognition result refers to the probability values corresponding to each of the four identifiers.
[0076] In order to further improve the effectiveness and accuracy of 2.5D pneumonia medical CT image classification, in a 2.5D pneumonia medical CT image classification device provided in an embodiment of the present application, see Figure 3 The 2.5D pneumonia medical CT image classification device 1 specifically includes the following contents:
[0077] A historical image slicing module 40 connected to the model training module 30;
[0078] The historical image slicing module 40 is used to obtain multiple continuous slices corresponding to each historical 3D lung medical CT image sample in an image enhancement manner based on a preset slice number threshold, so as to obtain 2.5D lung medical CT image samples corresponding to each of the historical 3D lung medical CT image samples.
[0079] In order to further improve the effectiveness and accuracy of 2.5D pneumonia medical CT image classification, in a 2.5D pneumonia medical CT image classification device provided in an embodiment of the present application, see Figure 3 The 2.5D pneumonia medical CT image classification device specifically includes the following contents:
[0080] A historical image preprocessing module 50 connected to the historical image slicing module 40;
[0081] The historical image preprocessing module 50 is used to preprocess each historical 3D lung medical CT image data acquired for historical diagnosis of pneumonia lesions to obtain corresponding each historical 3D lung medical CT image sample.
[0082] In order to further improve the efficiency of 2.5D pneumonia medical CT image classification and reduce the computational complexity, in a 2.5D pneumonia medical CT image classification device provided in an embodiment of the present application, see Figure 3 The 2.5D pneumonia medical CT image classification device 1 further specifically includes the following contents:
[0083] A model structure optimization module 60 connected to the model training module 30;
[0084] The model structure optimization module 60 is used to adjust and optimize the network structure of the ConvNeXt model for training with 2.5D lung medical CT image samples to generate a ConvNeXt optimized model using a 2D convolutional layer.
[0085] In order to further improve the accuracy of 2.5D pneumonia medical CT image classification, in a 2.5D pneumonia medical CT image classification device provided in an embodiment of the present application, see Figure 4 The 2.5D pneumonia medical CT image classification device 1 further specifically includes the following contents:
[0086] A model generalization test module 70 connected between the target image classification module 20 and the model training module 30;
[0087] The model generalization test module 70 is used to test the generalization ability of the trained ConvNeXt optimization model and select a ConvNeXt optimization model whose corresponding test results meet the preset generalization performance requirements.
[0088] In order to further improve the efficiency of 2.5D pneumonia medical CT image classification and reduce the computational complexity, in a 2.5D pneumonia medical CT image classification device provided in an embodiment of the present application, see Figure 5 The model training module 30 in the 2.5D pneumonia medical CT image classification device 1 specifically includes the following contents:
[0089] The pre-training unit 31 is used to pre-train the ConvNeXt optimization model using the 2D convolutional layer using the pre-acquired historical lung medical CT image data in the same domain to obtain a pre-trained ConvNeXt optimization model.
[0090] The transfer learning unit 32 is used to iteratively train the pre-trained ConvNeXt optimization model using each labeled 2.5D lung medical CT image sample, and adopt a cosine annealing learning rate method during the training process to obtain a ConvNeXt optimization model for outputting a pneumonia lesion type recognition result corresponding to the input 2.5D lung medical CT image data.
[0091] In order to further improve the efficiency of 2.5D pneumonia medical CT image classification and reduce the computational complexity, in a 2.5D pneumonia medical CT image classification device provided in an embodiment of the present application, see Figure 5 The historical image preprocessing module 50 in the 2.5D pneumonia medical CT image classification device 1 specifically includes the following contents:
[0092] A type conversion unit 51 is used to convert the published DICOM sequence data into NIFIT format to obtain various historical 3D medical CT image data for historical diagnosis of pneumonia lesions;
[0093] A cropping unit 52, used for cropping the lung region in each of the historical 3D medical CT image data to obtain corresponding historical 3D lung medical CT image data;
[0094] A resampling unit 53, used for resampling and linear interpolation processing each historical 3D lung medical CT image data;
[0095] The standardization processing unit 54 is used to standardize each historical 3D lung medical CT image data that has been resampled and linearly interpolated, and convert each historical 3D lung medical CT image data that has been standardized into npy format to obtain a historical 3D lung medical CT image sample corresponding to each historical 3D medical CT image data.
[0096] On this basis, in order to further improve the automation and intelligence of 2.5D pneumonia medical CT image classification, see Figure 6 The 2.5D pneumonia medical CT image classification device 1 can also be connected to a 3D lung medical CT image database 4 for communication, so as to collect the published DICOM sequence data from the 3D lung medical CT image database 4 .
[0097] In order to further reduce the complexity and time consumption of model training and improve the execution efficiency and convenience of pneumonia CT image classification process, see Figures 7 to 9 The ConvNeXt optimization model in the 2.5D pneumonia medical CT image classification device specifically includes the following contents:
[0098] The input layer, 2D convolution layer, layer normalization unit, 3 ConvNeXt blocks connected in sequence, first downsampling group, second downsampling group, third downsampling group, global average pooling layer, layer normalization unit, linear layer and output layer are connected in sequence;
[0099] The first downsampling group and the third downsampling group each include a downsampling layer and three ConvNeXt blocks connected in sequence, and the second downsampling group includes a downsampling layer and nine ConvNeXt blocks connected in sequence;
[0100] The ConvNeXt block includes: a depth-separable 2D convolutional layer, a layer normalization unit, a 2D convolutional layer, a Gaussian error linear unit, a 2D convolutional layer, a layer scaling unit, and a path discarding unit connected in sequence;
[0101] The downsampling layer includes: a layer normalization unit and a 2D convolution layer connected in sequence.
[0102] In order to further illustrate the 2.5D pneumonia medical CT image classification device in the above embodiment, the present application also provides a specific application example of a 2.5D pneumonia medical CT image classification method implemented by the 2.5D pneumonia medical CT image classification device, see Fig.10 and Fig.11 The 2.5D pneumonia medical CT image classification method specifically includes the following contents:
[0103] 1. Step S1: 3D data preprocessing: Acquire multiple pneumonia CT medical image data, and preprocess each pneumonia CT medical image data to make different 3D data in the same distribution. This can be achieved by the historical image preprocessing module 50.
[0104] The original DICOM data needs to be preprocessed. Inconsistent machine parameters for generating CT images will cause all CT images to not be in the same data space. The actual space represented by each voxel in different CT images is inconsistent. Therefore, the data needs to be resampled. After preprocessing, training, verification and testing are performed on the ConvNeXt model.
[0105] Obtain the original DICOM sequence data of the target medical image, read the data and resample it according to its Spacing (voxel spacing) parameters to unify the distribution of the image and avoid the degradation of model performance due to inconsistent slice thickness. Then standardize the image and convert its image information into npy format files and store it for subsequent use.
[0106] The DICOM sequence data collected from a hospital can be used as 3D historical pneumonia CT images and converted into NIFIT format (suffixed with .nii). In this process, personal privacy information such as the patient's name and age will be hidden, and only data useful for the image itself will be retained. The preprocessing of the acquired nii sequence data includes the following steps:
[0107] S11: based on the statistics of HU (Houens Unit) values of the lungs, the lung regions in each 3D historical lung CT image data are cropped out to form each 3D lung CT image data.
[0108] S12: According to the Spacing parameters corresponding to each 3D lung CT image data, each 3D lung CT image data is uniformly resampled to make the actual space represented by the voxels of all 3D lung CT image data consistent. Then, each resampled 3D lung CT image data is fixed into the form of (H, C, W) by linear interpolation, where H, C and W represent the height, number of channels and width of the 3D lung CT image data, respectively, and the height H is equal to the width W. Then, a unified image distribution is achieved to avoid the degradation of model performance due to inconsistent slice thickness.
[0109] S13: performing standard normalization on each of the resampled 3D lung CT image data.
[0110] S14: extracting image information of the processed 3D lung CT image data, and converting the data into an npy format file (i.e., a binary file dedicated to NumPy) to facilitate subsequent reading of the image data. NumPy (NumericalPython) is an open source numerical computing extension of Python. This tool can be used to store and process large matrices.
[0111] That is to say, through steps S11 to S14, the 3D lung CT image data is subjected to type conversion, cropping, resampling and other operations to regenerate a data set belonging to the same distribution space, and the lung area obtained after cropping is also enhanced.
[0112] 2. Step S2: Dataset construction: Using data enhancement, obtain 2.5D data of different categories and make the data of different categories consistent in quantity, so as to construct a data set for training the network. This can be achieved by the historical image slicing module 40.
[0113] According to the characteristics of the data set, the appropriate number of continuous slices C is selected, and then the preprocessed 3D data is cut out into C continuous slices using data enhancement, so that the number of data in each category remains balanced. In the process of cutting slices, random and uniform cutting is performed according to the slice range where the lesion is located, thereby completing the construction of the training set, validation set, and test set.
[0114] The appropriate number of slices C can be selected according to the different characteristics of the data set, such as the size of different types of pneumonia areas, the degree of change between different slices, etc., which will jointly determine the composition of the samples sent to the network training.
[0115] The specific operations of sample composition are as follows:
[0116] S21: Take C consecutive slices along the axis of the 3D lung CT image data to form a sample.
[0117] In special cases, when C=1, this sample is the sample required by the 2D classification network, that is, a single slice. However, when C is very large, the amount of irrelevant information input into the network will increase, which will introduce interference, reduce the performance of the model, and also reduce the reasoning speed of the model.
[0118] Based on this, it is crucial to select the right number of slices. Through experiments, it is finally determined that selecting 30 consecutive slices as the input of the network will achieve a better effect.
[0119] During the selection process, multiple consecutive 30 slices will be evenly distributed in the 3D lung CT image data as a sample, and finally a large number of samples will be obtained through data enhancement. However, the number of samples in each category needs to be kept balanced to avoid the degradation of model performance due to sample imbalance. In addition, since the data set used in this application is relatively small, there may be slight overlap between different data when slicing and sampling the data.
[0120] 3. Step S3: Pre-train the model in the same domain data to obtain pre-trained weights, then use the pneumonia 25D data for transfer learning, and iteratively update to obtain multiple sets of weights. This can be implemented in sequence by the model structure optimization module 60 and the model training module 30.
[0121] Pre-train the improved ConvNeXt model and perform transfer learning: First, use the data from the same domain to pre-train the model, then load the pre-trained weights into the model, further train the model using the above training set, use the cross entropy function to perform reverse gradient propagation on the model and update the weights, use the accuracy of category judgment as an indicator to judge the performance of the model, and save multiple groups of model weights with better performance on the validation set based on this indicator.
[0122] S31: The ConvNeXt network is used as the basic model structure of the model. Since conventional ConvNeXt models use three channels of RGB color images as input, or a single channel of grayscale images as input, it is necessary to adjust and optimize the channels of the network framework of the ConvNeXt model so that the corresponding ConvNeXt optimized model can adapt to the input of 30 slices.
[0123] Furthermore, the model can be pre-trained using data from the same domain, and the obtained pre-trained weights can be used for transfer learning, that is, the network can be trained using the training set data obtained above, so that the network can be trained multiple times on the basis of the pre-trained weights. The Adam optimizer is selected, and the training loss function is CrossEntropyLoss, which has the following formula:
[0124]
[0125] Where N is the number of samples in a batch; i is the sample number in the batch; y is i Represents the true category label of the sample; Represents the class label predicted by the model.
[0126] During the training process, the cosine annealing learning rate method is used to ensure that the model can converge stably. Through multiple trainings, the learning rate and some hyperparameters are continuously reduced to continuously improve the performance of the model.
[0127] The accuracy of category judgment is used as an indicator to measure the quality of the model. The network is trained using the above strategy, and multiple sets of weights with good indicator effects on the validation set are saved.
[0128] 4. Step S4: Test the generalization performance of the model on the test set, select a set of weights with the best generalization performance, and obtain the final target classification model. This can be achieved by the model generalization test module 70.
[0129] Test of model generalization ability: Test the generalization performance of these multiple groups of weights on the test set, and also use the accuracy of category judgment as an indicator. The weight with the best performance on the test set is the required target. At this point, a 2.5D pneumonia medical CT image classification method based on the ConvNeXt optimization model is fully completed. This method can be used to obtain a model to assist doctors in judging the category of pneumonia.
[0130] The accuracy of category judgment is also used as an indicator to measure the generalization ability of the model, and the model with the best generalization performance is tested on the test set as the final model. In addition, a many-to-one approach is adopted in this application, and its criterion is that as long as the slice sequence contains a lesion, the output result is the type of lesion. Thus, the obtained model is used for auxiliary diagnosis of pneumonia, which can assist doctors to quickly locate the range of pneumonia lesions.
[0131] The corresponding relationship between the number of samples trained using the ConvNeXt optimization model and the corresponding number of test samples is shown in Table 1, where each sample is 30 consecutive slices.
[0132] Then, the target image slicing module 10 is used to obtain multiple continuous slices corresponding to the target 3D lung medical CT image data to form target 2.5D lung medical CT image data corresponding to the target 3D lung medical CT image data, and then the target image classification module 20 is used to input the target 2.5D lung medical CT image data into a preset ConvNeXt optimization model using a 2D convolutional layer, so that the ConvNeXt optimization model outputs the pneumonia lesion type recognition result corresponding to the target 2.5D lung medical CT image data.
[0133] Table 1
[0134]
[0135] In summary, the application examples provided in this application can realize the automatic classification of pneumonia medical CT images, and can effectively improve the execution efficiency and convenience of the pneumonia CT image classification process on the basis of reducing the complexity and time consumption of model training, and can improve the reliability and accuracy of pneumonia CT image classification results. Using a deep learning classification model to assist doctors in the classification of pneumonia and provide doctors with the range of pneumonia lesions will effectively reduce the pressure on doctors to read films and improve the efficiency and accuracy of doctors' diagnosis.
[0136] The embodiment of the present application also provides an electronic device, which may include a processor, a memory, a receiver and a transmitter, wherein the processor is used to perform the functions of the 2.5D pneumonia medical CT image classification device mentioned in the above embodiment, wherein the processor and the memory may be connected via a bus or other means, such as by bus connection. The receiver may be connected to the processor and the memory via wired or wireless means.
[0137] The processor may be a central processing unit (CPU). The processor may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or a combination of the above chips.
[0138] As a non-transient computer-readable storage medium, the memory can be used to store non-transient software programs, non-transient computer executable programs and modules, such as the program instructions / modules corresponding to the 2.5D pneumonia medical CT image classification device in the embodiment of the present application. The processor executes various functional applications and data processing of the processor by running the non-transient software programs, instructions and modules stored in the memory, that is, realizing the functions of the 2.5D pneumonia medical CT image classification device in the above method embodiment.
[0139] The memory may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created by the processor, etc. In addition, the memory may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some embodiments, the memory may optionally include a memory remotely arranged relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0140] The one or more modules are stored in the memory, and when executed by the processor, perform the functions of the 2.5D pneumonia medical CT image classification device in the embodiment.
[0141] In some embodiments of the present application, the user equipment may include a processor, a memory, and a transceiver unit, which may include a receiver and a transmitter. The processor, memory, receiver, and transmitter may be connected through a bus system. The memory is used to store computer instructions, and the processor is used to execute the computer instructions stored in the memory to control the transceiver unit to send and receive signals.
[0142] As an implementation method, the functions of the receiver and the transmitter in the present application can be considered to be implemented through a transceiver circuit or a dedicated chip for transceiver, and the processor can be considered to be implemented through a dedicated processing chip, a processing circuit or a general chip.
[0143] As another implementation method, it is possible to use a general-purpose computer to implement the server provided in the embodiment of the present application, that is, to store the program code for implementing the functions of the processor, receiver, and transmitter in a memory, and the general-purpose processor implements the functions of the processor, receiver, and transmitter by executing the code in the memory.
[0144] The present application embodiment also provides a computer-readable storage medium having a computer program stored thereon, which is executed by a processor to implement the functions of the aforementioned 2.5D pneumonia medical CT image classification device. The computer-readable storage medium may be a tangible storage medium, such as a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a floppy disk, a hard disk, a removable storage disk, a CD-ROM, or any other form of storage medium known in the technical field.
[0145] It should be understood by those skilled in the art that the exemplary components, systems and methods described in conjunction with the embodiments disclosed herein can be implemented in hardware, software or a combination of the two. Whether it is specifically performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), appropriate firmware, a plug-in, a function card, etc. When implemented in software, the elements of this application are programs or code segments used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link via a data signal carried in a carrier.
[0146] It should be clear that the present application is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present application is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present application.
[0147] In this application, the features described and / or illustrated for one embodiment may be used in the same manner or in a similar manner in one or more other embodiments, and / or combined with or replace the features of other embodiments.
[0148] The above description is only the preferred embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the embodiments of the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.
Claims
1. A 2.5D pneumonia medical CT image classification device, characterized in that: include: A target image slicing module, used to obtain a plurality of continuous slices corresponding to the target 3D lung medical CT image data, so as to form target 2.5D lung medical CT image data corresponding to the target 3D lung medical CT image data; A target image classification module, used for inputting the target 2.5D lung medical CT image data into a preset ConvNeXt optimization model using a 2D convolutional layer, so that the ConvNeXt optimization model outputs a pneumonia lesion type recognition result corresponding to the target 2.5D lung medical CT image data; The 2.5D pneumonia medical CT image classification device further includes: a model training module connected to the target image classification module; The model training module is used to train a ConvNeXt optimization model using a 2D convolutional layer according to each labeled 2.5D lung medical CT image sample, so that the ConvNeXt optimization model is used to output a pneumonia lesion type recognition result according to the input 2.5D lung medical CT image data; The labels include: individual marks for indicating no pneumonia symptoms, lobar pneumonia, lobular pneumonia, and interstitial pneumonia; A historical image slicing module connected to the model training module; The historical image slicing module is used to obtain a plurality of continuous slices corresponding to each historical 3D lung medical CT image sample in an image enhancement manner based on a preset slice number threshold, so as to obtain 2.5D lung medical CT image samples corresponding to each of the historical 3D lung medical CT image samples; A historical image preprocessing module connected to the historical image slicing module; The historical image preprocessing module is used to preprocess each historical 3D lung medical CT image data acquired for historical diagnosis of pneumonia lesions to obtain corresponding each historical 3D lung medical CT image sample; A model structure optimization module connected to the model training module; The model structure optimization module is used to adjust and optimize the network structure of the ConvNeXt model for training with 2.5D lung medical CT image samples to generate a ConvNeXt optimized model using a 2D convolutional layer; Wherein, the model training module includes: A pre-training unit, used for pre-training a ConvNeXt optimization model using a 2D convolutional layer using pre-acquired historical lung medical CT image data of the same domain, to obtain a pre-trained ConvNeXt optimization model; A transfer learning unit, for iteratively training the pre-trained ConvNeXt optimization model using each labeled 2.5D lung medical CT image sample, and using a cosine annealing learning rate in the training process to obtain a ConvNeXt optimization model for outputting a pneumonia lesion type recognition result corresponding to the input 2.5D lung medical CT image data; The historical image preprocessing module includes: A type conversion unit, used to convert the published DICOM sequence data into NIFIT format to obtain various historical 3D medical CT image data for historical diagnosis of pneumonia lesions; A cropping unit, used for cropping the lung region from each of the historical 3D medical CT image data to obtain corresponding historical 3D lung medical CT image data; A resampling unit, used for resampling and linear interpolation processing of each historical 3D lung medical CT image data; The standardization processing unit is used to standardize each historical 3D lung medical CT image data that has been resampled and linearly interpolated, and convert each historical 3D lung medical CT image data that has been standardized into npy format to obtain the historical 3D lung medical CT image samples corresponding to each historical 3D medical CT image data.
2. The 2.5D pneumonia medical CT image classification device according to claim 1, characterized in that: Also includes: A model generalization test module connected between the target image classification module and the model training module; The model generalization test module is used to test the generalization ability of the trained ConvNeXt optimization model and select the ConvNeXt optimization model whose corresponding test results meet the preset generalization performance requirements.
3. The 2.5D pneumonia medical CT image classification device according to claim 1 or 2, characterized in that: The ConvNeXt optimization model includes: an input layer connected in sequence, a 2D convolution layer, a layer normalization unit, three ConvNeXt blocks connected in sequence, a first downsampling group, a second downsampling group, a third downsampling group, a global average pooling layer, a layer normalization unit, a linear layer and an output layer; The first downsampling group and the third downsampling group each include a downsampling layer and three ConvNeXt blocks connected in sequence, and the second downsampling group includes a downsampling layer and nine ConvNeXt blocks connected in sequence; The ConvNeXt block includes: a depth-separable 2D convolutional layer, a layer normalization unit, a 2D convolutional layer, a Gaussian error linear unit, a 2D convolutional layer, a layer scaling unit, and a path discarding unit connected in sequence; The downsampling layer includes: a layer normalization unit and a 2D convolution layer connected in sequence.
4. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that: When the processor executes the computer program, the function of the 2.5D pneumonia medical CT image classification device according to any one of claims 1 to 3 is realized.
