CN116630303A - Chest CT image classification model training method, classification method, system and equipment - Google Patents

Chest CT image classification model training method, classification method, system and equipment Download PDF

Info

Publication number
CN116630303A
CN116630303A CN202310843300.5A CN202310843300A CN116630303A CN 116630303 A CN116630303 A CN 116630303A CN 202310843300 A CN202310843300 A CN 202310843300A CN 116630303 A CN116630303 A CN 116630303A
Authority
CN
China
Prior art keywords
image
classification
module
classifier
chest
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310843300.5A
Other languages
Chinese (zh)
Inventor
谷宗运
章沁怡
陈晨
晏胤荣
束建华
汪天明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Anhui University of Traditional Chinese Medicine AHUTCM
Original Assignee
Anhui University of Traditional Chinese Medicine AHUTCM
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Anhui University of Traditional Chinese Medicine AHUTCM filed Critical Anhui University of Traditional Chinese Medicine AHUTCM
Priority to CN202310843300.5A priority Critical patent/CN116630303A/en
Publication of CN116630303A publication Critical patent/CN116630303A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0012Biomedical image inspection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/0464Convolutional networks [CNN, ConvNet]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/764Arrangements for image or video recognition or understanding using pattern recognition or machine learning using classification, e.g. of video objects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/77Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
    • G06V10/774Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/82Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10072Tomographic images
    • G06T2207/10081Computed x-ray tomography [CT]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20084Artificial neural networks [ANN]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30004Biomedical image processing
    • G06T2207/30061Lung

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • Evolutionary Computation (AREA)
  • General Health & Medical Sciences (AREA)
  • Software Systems (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Medical Informatics (AREA)
  • Artificial Intelligence (AREA)
  • Computing Systems (AREA)
  • Multimedia (AREA)
  • Databases & Information Systems (AREA)
  • Quality & Reliability (AREA)
  • Radiology & Medical Imaging (AREA)
  • Nuclear Medicine, Radiotherapy & Molecular Imaging (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Molecular Biology (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Image Analysis (AREA)

Abstract

The application relates to the technical field of intelligent medical diagnosis, in particular to a chest CT image classification model training method, a classification method, a system and equipment, which comprise the following steps: acquiring an image sample set, wherein the image sample set comprises an image set and a classification tag set corresponding to the image set; extracting features of the image set by using a feature extraction unit in the RepVGG module to obtain a feature matrix; classifying the feature matrix by using a classifier to obtain a classification result; calculating a loss value according to the classification result and the classification tag set; adjusting parameters of the classifier and the RepVGG module according to the loss value; and taking the adjusted classifier and the RepVGG module as a chest CT image classification model after training. The application extracts the image characteristics by using the RepVGG module, the RepVGG training stage uses a multi-branch network structure, and the reasoning stage RepVGG only needs to combine the multi-branch structure into a single-branch structure, so that the reasoning speed can be greatly improved.

Description

Chest CT image classification model training method, classification method, system and equipment
Technical Field
The application belongs to the technical field of intelligent medical diagnosis, and particularly relates to an eye chest CT image classification model training method, a classification method, a system and equipment.
Background
Pneumonia is a common disease, different types of pneumonia have significant differences in clinical manifestations and treatment methods, so classification and diagnosis of lung images is an important task. The acquisition of lung image information and the judgment of whether the patient is the COVID-19 or not are main measures of the current lung examination through CT images.
The most prominent manifestation of covd-19 in chest CT is a frosted glass image scattered throughout the lung. This represents the alveoli filled with fluid, thus rendering a gray shade in CT imaging. CT presents a "lithotripsy sign" due to swelling of the pulmonary leaflet wall matrix. The alveolar walls thicken, splitting the blurred ground glass shadow like a white line, and accumulating in the lungs as if many irregularly shaped stones were laid on the road, thus giving the name "crushed stone road sign". The three CT changes of the frostbite, the lung solid state, and the lithotripsy can be singly or jointly occurred. The ground glass image is typically the first image representation, with the other two signs appearing either singly or simultaneously.
The presence of ground glass, speckle, and solid shadows on CT images is common to many pneumonia. For classification tasks of the COVID-19 and other pneumonia, due to certain similarity and difference among different types of viral pneumonia, deviation of diagnosis results possibly occurs, and the accuracy and effectiveness of clinical diagnosis are affected.
Defects and deficiencies of the prior art:
the current computer aided diagnosis of the COVID-19 technology, particularly the deep learning-based method, still has a certain misdiagnosis rate. This is mainly because there is some similarity between viral pneumonia, and it is sometimes difficult to distinguish between covd-19 and other viral pneumonia;
the resolution of the chest CT image is very high, the problems of gradient disappearance or explosion and the like can occur when the chest CT image is directly trained by using a neural network, in addition, the calculation cost is high, and the model training is difficult;
the techniques of computer aided diagnosis of covd-19 require high performance computing devices and stable network environment support. This can present significant difficulties and obstacles for some hospitals and places where regional conditions are relatively late.
Disclosure of Invention
In view of the above-mentioned drawbacks of the prior art, an object of the present application is to provide a chest CT image classification model training method, classification method, system and device, which are used for solving the problems of low training speed and high requirement on computing equipment of the existing classification model.
To achieve the above and other related objects, the present application provides a training method for a chest CT image classification model, comprising the steps of:
acquiring an image sample set, wherein the image sample set comprises an image set and a classification tag set corresponding to the image set;
extracting features of the image set by using a feature extraction unit in the RepVGG module to obtain a feature matrix;
classifying the feature matrix by using a classifier to obtain a classification result;
calculating a loss value according to the classification result and the classification tag set;
adjusting parameters of the classifier and the RepVGG module according to the loss value;
and taking the adjusted classifier and the RepVGG module as a chest CT image classification model after training.
In an alternative embodiment of the present application,
the RepVGG module performs feature extraction on the image set, and the step of obtaining a feature matrix comprises the following steps:
the graph is subjected toThe picture in the image set is resized to
Will be of the size ofThe pictures of the picture are sequentially subjected to five stages to obtain an output result;
taking the output result as input, and entering convolution with convolution kernel of 1 multiplied by 1 to obtain a feature matrix;
wherein the method comprises the steps ofFor image height +.>For the image width +.>Is the image latitude.
In an optional embodiment of the present application, the step of classifying the feature matrix by using a classifier includes:
respectively inputting the feature matrix into a space pooling layer and an average pooling layer;
calculating to obtain class-specific residual characteristics on the space pooling layer according to the characteristic matrix;
calculating a sampling feature vector on the average pooling layer according to the feature matrix;
calculating to obtain class-specific residual attention characteristics according to class-specific residual characteristics and sampling characteristic vectors;
the class-specific residual attention features are sent to a residual attention classifier to obtain classification results.
In an alternative embodiment of the present application, the step of calculating class-specific residual features from the feature matrix at the spatial pooling layer includes:
computing a category-specific attention score at a spatial pooling layer;
class-specific residual features are obtained from the class-specific attention scores.
In an alternative embodiment of the present application, the step of calculating the class-specific residual attention feature from the class-specific residual feature and the sampled feature vector comprises:
presetting super parameters;
the class-specific residual feature is multiplied by the super-parameters and weighted with the sampled feature vector to obtain the class-specific residual attention feature.
In an alternative embodiment of the present application, the step of calculating the loss value according to the classification result and the classification tag set includes:
and carrying the classification result and the classification label into a cross entropy function, and calculating the loss value.
In an alternative embodiment of the present application, the step of adjusting parameters of the classifier and the RepVGG module according to the loss value comprises: and adjusting the parameters of the classifier and the RepVGG module by using a random gradient descent method until the loss value is smaller than a preset threshold value, and obtaining a chest CT image classification model after training.
To achieve the above object and other related objects, the present application also provides an image classification method, including the steps of:
acquiring an image to be determined;
inputting the image to be determined into a chest CT image classification model, obtaining a predicted value of the probability of the image to be determined under each classification label, and taking the classification label corresponding to the predicted value as the category of the image to be diagnosed.
To achieve the above and other related objects, the present application further provides a training system for a chest CT image classification model, comprising:
the image processing device comprises a sample acquisition module, a processing module and a processing module, wherein the sample acquisition module is used for acquiring an image sample set, and the image sample set comprises an image set and a classification label set corresponding to the image set;
the feature extraction module is used for extracting features of the image set to obtain a feature matrix;
the classification module is used for classifying the feature matrix by using a classifier to obtain a classification result;
the loss calculation module is used for calculating a loss value according to the classification result and the classification tag set;
and controlling a training module, and adjusting parameters of the classifier and the RepVGG module according to the loss value. To achieve the above and other related objects, the present application also provides an electronic device including a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method when executing the computer program or implementing the steps of the method when executing the computer program.
The application has the technical effects that:
according to the application, the image features are extracted by the feature extraction unit in the RepVGG module, and the RepVGG model can greatly improve the reasoning speed and reduce the calculation force requirement, so that the performance requirement on the computing equipment is reduced.
Drawings
Fig. 1 is a schematic diagram of a visual structure of an improved network in a chest CT image classification model training method.
Fig. 2 is a flow chart of a chest CT image classification model training method.
Fig. 3 is a flow chart of obtaining a feature matrix provided by an embodiment of the present application.
Fig. 4 is a flow chart of obtaining classification results provided by an embodiment of the present application.
Fig. 5 is a schematic diagram of the structure of the RepVGG module according to the present application.
Fig. 6 is a diagram of a residual attention module configuration in the present application.
Fig. 7 is a schematic diagram of a training process in the training method of the CT image classification model according to the present application.
Fig. 8 is a block diagram of a training system for chest CT image classification models.
Fig. 9 is a block diagram of the electronic device in the present application.
Detailed Description
Other advantages and effects of the present application will become apparent to those skilled in the art from the following disclosure, which describes the embodiments of the present application with reference to specific examples. The application may be practiced or carried out in other embodiments that depart from the specific details, and the details of the present description may be modified or varied from the spirit and scope of the present application.
Please refer to fig. 1-4. It should be noted that, the illustrations provided in the present embodiment merely illustrate the basic concept of the present application by way of illustration, and only the components related to the present application are shown in the drawings and are not drawn according to the number, shape and size of the components in actual implementation, and the form, number and proportion of the components in actual implementation may be arbitrarily changed, and the layout of the components may be more complex.
The embodiment of the application can acquire and process the related data based on the artificial intelligence technology. Among these, artificial intelligence (Artificial Intelligence, AI) is the theory, method, technique and application system that uses a digital computer or a digital computer-controlled machine to simulate, extend and extend human intelligence, sense the environment, acquire knowledge and use knowledge to obtain optimal results.
The chest CT image classification model training method is applied to one or more electronic devices, wherein the electronic devices are devices capable of automatically performing numerical calculation and/or information processing according to preset or stored instructions, and the hardware comprises, but is not limited to, a microprocessor, an application specific integrated circuit (Application Specific Integrated Circuit, an ASIC), a programmable gate array (Field-Programmable Gate Array, an FPGA), a digital processor (Digital Signal Processor, a DSP), an embedded device and the like.
The electronic device may be any electronic product that can interact with a user, such as a personal computer, tablet computer, smart phone, etc.
The electronic device may also include a network device and/or a user device. Wherein the network device includes, but is not limited to, a single network server, a server group composed of a plurality of network servers, or a Cloud based Cloud Computing (Cloud Computing) composed of a large number of hosts or network servers.
The network in which the electronic device is located includes, but is not limited to, the internet, a wide area network, a metropolitan area network, a local area network, a virtual private network (Virtual Private Network, VPN), and the like.
The chest CT image classification model training method of the application is described in detail below with reference to the accompanying drawings, and can be applied to binary classification of pneumonia COVID-19 and other pneumonia chest CT, threshold setting for judging lesions, and multi-label classification of chest CT images.
The chest CT image classification model can be used for multi-label classification of diseases of CT image sets such as pneumonia, lung cancer, tracheitis, bronchitis and the like; screening a pneumonia image set; disease classification of the pneumonia image set, etc.
Firstly, an image set data set is acquired, and then the data set is divided into a training set, a testing set and a verification set. Training the training set, extracting features of the image set by using a feature extractor, and putting the extracted feature vectors into a classifier to predict the classification probability. And finally judging the disease category according to the classification probability. As described in more detail below, the feature extractor uses a pre-trained RepVGG module, and the classifier can use a residual attention mechanism to determine the optimal threshold for lesion threshold based on the Johnson index.
A chest CT image classification model training method comprises the following steps:
s1, acquiring an image sample set, wherein the image sample set comprises an image set and a classification label set corresponding to the image set;
s2, extracting features of the image set by using a feature extraction unit in the RepVGG module to obtain a feature matrix;
s3, classifying the feature matrix by using a classifier to obtain a classification result;
s4, calculating a loss value according to the classification result and the classification tag set;
s5, adjusting parameters of the classifier and the RepVGG module according to the loss value;
s6, taking the adjusted classifier and the RepVGG module as a chest CT image classification model after training.
RepVGG converts a multipath structure (advantage in multi-branch model training, high performance) of a training network into a single-path structure (advantage in model reasoning, high speed and memory saving) of a reasoning network through a structure re-parameterization idea, the convolution kernels of 3x3 are in the structure, meanwhile, a calculation library (such as CuDNN, intel MKL) and hardware are deeply optimized for 3x3 convolution, and finally the network can have high-efficiency reasoning rate (in fact TensorRT is used for reconstructing the model in an engineering construction stage, and the bottom layer also adopts convolution merging and multi-branch fusion idea to enable the model to finally have high-performance reasoning rate).
The training and validation data sets are partitioned. The data set was randomly partitioned into training, validation and test sets at 70%, 15% and 15% respectively. The SARS-COV-2 Ct-Scan dataset referred to herein is a large dataset of real patient CT scans from the Hospital of St.Paul, brazil published by Eduard Soares in 2020. The dataset contained 1252 images of covd-19 CT (covd) and 1229 images of non-covd-19 CT (non-covd). Covd is a sample infected with 2019 novel coronavirus, non-covd is a sample not infected with 2019 novel coronavirus, but with other pulmonary diseases.
In step S2, the step of extracting features of the image set by the RepVGG module, and the step of obtaining a feature matrix includes:
s21, adjusting the picture size in the image set to be
S22, the size is set asThe pictures of the picture are sequentially subjected to five stages to obtain an output result;
s23, taking the output result as input, and entering convolution with convolution kernel of 1 multiplied by 1 to obtain a feature matrix;
wherein the method comprises the steps ofFor image height +.>For the image width +.>Is the image latitude. Wherein->Preferably 224->It is preferably at least one of the group 224,preferably 3.
The process of sequentially passing through five stages comprises the following steps:
entering a first stage, wherein the volume number is 1, and stride= (2, 2);
entering a second stage, wherein the volume number is 4, the first layer stride= (2, 2), and the three layers stride= (1, 1) at the back;
entering a third stage, wherein the volume number is 6, the first layer stride= (2, 2), and the five layers stride= (1, 1) at the back;
entering a fourth stage, wherein the volume number is 16, the first layer stride= (2, 2), and the next fifteen layers stride= (1, 1);
entering a fifth stage, wherein the volume number is 1, and stride= (2, 2);
taking the output result of the fifth stage as input to enter convolution with convolution kernel of 1×1 to obtain a feature matrix;
the training process parameters are shown in table 1 below:
table 1 training parameter table
In an optional embodiment of the present application, the step of classifying the feature matrix with a classifier in S3 includes:
s31, respectively inputting the feature matrix into a space pooling layer and an average pooling layer;
s32, calculating out class-specific residual characteristics on the space pooling layer according to the characteristic matrix;
s33, calculating a sampling feature vector on the average pooling layer according to the feature matrix;
s34, calculating to obtain class-specific residual attention features according to the class-specific residual features and the sampling feature vectors;
and S35, transmitting the class-specific residual attention characteristics to a residual attention classifier to obtain a classification result.
The residual attention classifier may also be replaced with an MLP classifier or a softmax classifier or an FC classifier. The MLP Head structure consists of linear+tanh activation functions+linear, but only one Linear is needed when the MLP Head structure is migrated to other data sets for training. The softmax is applicable to two-class, whereas the softmax classifier is applicable to multiple classes, and although multiple classes can be achieved by cascading multiple two-class classifiers, the support vector machine classifier is still inferior to the softmax classifier as a whole. The FC classifier performs a weighted sum of features of the previous layer (the convolutional layer is mapping the data input to the hidden layer feature space) to map the feature space to the sample tag space (i.e., label) by linear transformation.
S32: the step of calculating the class-specific residual characteristics according to the characteristic matrix on the space pooling layer comprises the following steps:
computing a category-specific attention score at a spatial pooling layer;
class-specific residual features are obtained from the class-specific attention scores.
Specific:
at the space pooling layer, obtain the firstCategory and->Attention score for individual locations:
wherein, the liquid crystal display device comprises a liquid crystal display device,for inputting the height of the image +.>For the width of the input image, +.>Is a temperature control factor, < >>Is a feature matrix->Is->Classifier parameters on each class.
The step of calculating the class-specific residual attention feature according to the class-specific residual feature and the sampling feature vector comprises the following steps:
presetting super parameters;
the class-specific residual feature is multiplied by the super-parameters and weighted with the sampled feature vector to obtain the class-specific residual attention feature.
Specifically, calculating class-specific residual attention corresponding to each classification result according to the class-specific residual attention score;
and (3) control:
first, theThe attention scores of the individual categories are attention weights:
sampling feature vectors are acquired on an average pooling layer:
residual attention was obtained:
wherein the method comprises the steps ofIs super parameter, the numerical value is 0.1;
the classification result is obtained from the class-specific residual attention using the residual attention classifier.
And sending the residual attention characteristic to a residual attention classifier to obtain a classification result.
The step of calculating a loss value according to the classification result and the classification tag set comprises the following steps:
and carrying the classification result and the classification label into a cross entropy function, and calculating the loss value.
The specific cross entropy function calculates the loss value as:
wherein, the liquid crystal display device comprises a liquid crystal display device,for the total number of samples of the images in the training set, +.>Is->Image label->Predicting +.>A classification probability value for the sheet image; use of loss function back propagation for updating model parameters。
The image sample set is a pneumonia chest CT sample set, and the classification label is a pneumonia type.
The step of adjusting parameters of the chest CT image classification model comprises the following steps:
parameters of the classifier and the RepVGG module are adjusted using a random gradient descent method.
The method comprises the following steps: new classification model parameters:
wherein, the liquid crystal display device comprises a liquid crystal display device,gradient of the objective function with respect to the parameter +.>Is->Model parameters of the moment>Is the learning rate.
Wherein, the liquid crystal display device comprises a liquid crystal display device,for inputting samples, < >>For loss function->Is one randomly selected from a collection of training samples.
Although introduced hereRandomness and noise are present, but it is desirable that the correct gradient drop is still equal.
The loss function cross entropy function may be replaced by a loss function such as CCE (Categorical Cross Entropy Loss). The nature of the CCE penalty function is to measure the difference between the model prediction result and the real label, i.e. the distance between the probability distribution of the model prediction and the probability distribution of the real label. In the classification task, we usually use one-hot coding to represent the real label, i.e. convert the label into a vector, where only one element is 1 and the rest is 0.
The optimizer SDG may be replaced with an optimizer such as SGDM, adagard, etc.
In order to verify the performance of the model, tests are performed on a test set, and the accuracy, recall, specificity, F1 score, about index and accuracy are calculated as evaluation indexes to evaluate the prediction results of the model.
Accuracy rate ofReferring to the ratio of correctly predicted samples among samples whose prediction results are positive, the expression is as follows:
wherein, the liquid crystal display device comprises a liquid crystal display device,(1 Positive) is a Positive sample predicted by the model to be Positive, ++>(0 Positive) is a negative sample predicted by the model to be a Positive class.
Recall rate of recallIn the samples which are actually positive, the predicted correct sample ratio is represented by the following expression, wherein the higher the value of the ratio is the stronger the capability of the model to find abnormality:
wherein, the liquid crystal display device comprises a liquid crystal display device,(0 Negative) is a positive sample predicted by the model to be Negative.
Specificity of the sampleMeaning that in the samples which are actually negative, the correct sample ratio is predicted, the higher the value of the sample ratio is, the stronger the model is capable of recognizing the normal condition, and the expression is as follows:
wherein, the liquid crystal display device comprises a liquid crystal display device,(0 Positive) is a negative sample predicted by the model to be a Positive class.
F1 fractionAs a harmonic mean of accuracy and recall, an index used in statistics to measure accuracy of the two classification models is expressed as follows:
about sign indexThe total capacity of the positive patient and the negative patient found by the model is reflected by subtracting 1 from the sum of the recall rate and the specificity, and the expression is as follows:
accuracy rate ofRepresenting the correct proportion of model classification, the higher its value represents the more accurate the model classification, the expression:
the accuracy of the model on the test set was calculated to be 0.951, and the evaluation results of the other indexes were shown in table 2.
Table 2 calculation and summary of evaluation results of various indexes of model
To achieve the above object and other related objects, the present application also provides an image classification method, including the steps of:
acquiring an image to be determined;
inputting the image to be determined into a chest CT image classification model, obtaining a predicted value of the probability of the image to be determined under each classification label, and taking the classification label corresponding to the predicted value as the category of the image to be diagnosed.
It should be noted that, the above steps of the methods are divided, for clarity of description, and may be combined into one step or split into multiple steps when implemented, so long as they contain the same logic relationship, and they are all within the protection scope of the present patent; it is within the scope of this patent to add insignificant modifications to the algorithm or flow or introduce insignificant designs, but not to alter the core design of its algorithm and flow.
To achieve the above and other related objects, the present application further provides a training system for a chest CT image classification model, comprising:
a sample acquiring module 10, configured to acquire an image sample set, where the image sample set includes an image set and a classification tag set corresponding to the image set;
the feature extraction module 20 is configured to perform feature extraction on the image set to obtain a feature matrix;
the classification module 30 is configured to classify the feature matrix by using a classifier to obtain a classification result;
a loss calculation module 40, configured to calculate a loss value according to the classification result and the classification tag set;
the training module 50 is configured to adjust parameters of the chest CT image classification model until the loss value is less than a preset threshold value, so as to obtain a trained chest CT image classification model.
It should be noted that, the chest CT image classification model training system of the present embodiment is a device corresponding to the chest CT image classification model training method, and functional modules in the chest CT image classification model training system or corresponding to corresponding steps in the chest CT image classification model training method respectively. The chest CT image classification model training system of the present embodiment may be implemented in conjunction with the chest CT image classification model training method. Accordingly, the related technical details mentioned in the chest CT image classification model training system of the present embodiment can also be applied in the chest CT image classification model training method.
It should be noted that each of the above functional modules may be fully or partially integrated into one physical entity or may be physically separated. And these modules may all be implemented in software in the form of calls by the processing element; or can be realized in hardware; the method can also be realized in a form of calling software by a processing element, and the method can be realized in a form of hardware by a part of modules. In addition, all or part of the modules can be integrated together or can be independently implemented. The processing element described herein may be an integrated circuit having signal processing capabilities. In implementation, some or all of the steps of the above methods, or the above functional modules, may be implemented by integrated logic circuits of hardware in the processor element or instructions in the form of software.
To achieve the above and other related objects, the present application also provides an electronic device including a memory 200, a processor 100, and a computer program stored on the memory 200 and executable on the processor 100, the processor 100 implementing steps of the method when executing the computer program or the processor 100 implementing steps of the method when executing the computer program.
It should be noted that the memory 200 includes at least one type of readable storage medium, including flash memory, a mobile hard disk, a multimedia card, a card memory (e.g., SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, and so on. The memory 200 may in some embodiments be an internal storage unit of an electronic device, such as a mobile hard disk of the electronic device. The memory 200 may also be an external storage device of the electronic device in other embodiments, such as a plug-in mobile hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash Card (Flash Card) or the like, which are provided on the electronic device. Further, the memory 200 may also include both internal storage units and external storage devices of the electronic device. The memory 200 may be used to store not only application software installed in an electronic device and various data, such as codes of a chest CT image classification model training program, but also data that has been output or is to be output temporarily.
Processor 100 may in some embodiments be comprised of integrated circuits, for example, a single packaged integrated circuit, or may be comprised of multiple integrated circuits packaged with the same or different functionality, including one or more central processing units (Central Processing Unit, CPU), microprocessors, digital processing chips, graphics processors, a combination of various control chips, and the like. The processor is a Control Unit (Control Unit) of the electronic device, and connects various components of the entire electronic device using various interfaces and lines, by running or executing programs or modules stored in the memory (e.g., executing a chest CT image classification model training program, etc.), and invoking data stored in the memory to perform various functions of the electronic device and process the data.
The processor 100 executes the operating system of the electronic device and various applications installed. The processor 100 executes the application program to implement the steps of the embodiments of the chest CT image classification model training method described above, such as the steps shown in the figures.
The computer program may be divided into one or more modules, which are stored in the memory and executed by the processor to accomplish the present application, for example. The one or more modules may be a series of computer program instruction segments capable of performing the specified functions, which are used to describe the execution of the computer program in the electronic device. For example, the computer program may be partitioned into a sample acquisition module, a feature extraction module, a classification module, a loss calculation module, and a control training module.
The integrated units implemented in the form of software functional modules described above may be stored in a computer readable storage medium. The software functional module is stored in a storage medium, and includes several instructions for causing a computer device (which may be a personal computer, a computer device, or a network device, etc.) or a Processor (Processor) to perform part of the functions of the chest CT image classification model training method according to the embodiments of the present application.
The bus may be a peripheral component interconnect standard (Peripheral Component Interconnect, PCI) bus or an extended industry standard architecture (Extended Industry Standard Architecture, EISA) bus, among others. The bus may be classified as an address bus, a data bus, a control bus, etc. For ease of illustration, only one arrow is shown in FIG. 5, but only one bus or one type of bus is not shown. The bus is arranged to enable a connection communication between the memory and at least one processor or the like.
In summary, the image features are extracted by the feature extraction unit in the RepVGG module, and the RepVGG model can greatly improve the reasoning speed and reduce the calculation force requirement, so that the performance requirement on the computing equipment is reduced.
In the description herein, numerous specific details are provided, such as examples of components and/or methods, to provide a thorough understanding of embodiments of the application. One skilled in the relevant art will recognize, however, that an embodiment of the application can be practiced without one or more of the specific details, or with other apparatus, systems, components, methods, components, materials, parts, and so forth. .
It will also be appreciated that one or more of the elements shown in the figures may also be implemented in a more separated or integrated manner, or even removed because of inoperability in certain circumstances or provided because it may be useful depending on the particular application.
In addition, any labeled arrows in the drawings/figures should be considered only as exemplary, and not limiting, unless otherwise specifically indicated. Furthermore, the term "or" as used herein is generally intended to be "and/or" unless otherwise indicated. Combinations of parts or steps will also be considered as being noted where terminology is foreseen as rendering the ability to separate or combine is unclear.
The above description of illustrated embodiments of the application, including what is described in the abstract, is not intended to be exhaustive or to limit the application to the precise forms disclosed herein. Although specific embodiments of, and examples for, the application are described herein for illustrative purposes only, various equivalent modifications are possible within the spirit and scope of the present application, as those skilled in the relevant art will recognize and appreciate. As noted, these modifications can be made to the present application in light of the foregoing description of illustrated embodiments of the present application and are to be included within the spirit and scope of the present application.
The systems and methods have been described herein in general terms as being helpful in understanding the details of the present application. Furthermore, various specific details have been set forth in order to provide a thorough understanding of embodiments of the application. One skilled in the relevant art will recognize, however, that an embodiment of the application can be practiced without one or more of the specific details, or with other apparatus, systems, assemblies, methods, components, materials, parts, and/or the like. In other instances, well-known structures, materials, and/or operations are not specifically shown or described in detail to avoid obscuring aspects of embodiments of the application.
Thus, although the application has been described herein with reference to particular embodiments thereof, a latitude of modification, various changes and substitutions are intended in the foregoing disclosures, and it will be appreciated that in some instances some features of the application will be employed without a corresponding use of other features without departing from the scope and spirit of the application as set forth. Therefore, many modifications may be made to adapt a particular situation or material to the essential scope and spirit of the present application. It is intended that the application not be limited to the particular terms used in following claims and/or to the particular embodiment disclosed as the best mode contemplated for carrying out this application, but that the application will include any and all embodiments and equivalents falling within the scope of the appended claims. Accordingly, the scope of the application should be determined only by the following claims.

Claims (10)

1. A chest CT image classification model training method is characterized by comprising the following steps:
acquiring an image sample set, wherein the image sample set comprises an image set and a classification tag set corresponding to the image set;
extracting features of the image set by using a feature extraction unit in the RepVGG module to obtain a feature matrix;
classifying the feature matrix by using a classifier to obtain a classification result;
calculating a loss value according to the classification result and the classification tag set;
adjusting parameters of the classifier and the RepVGG module according to the loss value;
and taking the adjusted classifier and the RepVGG module as a chest CT image classification model after training.
2. The method of claim 1, wherein the step of obtaining a feature matrix by extracting features from the image set by the RepVGG module comprises:
concentrating the picturesIs sized to
Will be of the size ofThe pictures of the picture are sequentially subjected to five stages to obtain an output result;
taking the output result as input, and entering convolution with convolution kernel of 1 multiplied by 1 to obtain a feature matrix;
wherein the method comprises the steps ofFor image height +.>For the image width +.>Is the image latitude.
3. The method according to claim 1, wherein the classifier is a residual attention classifier, the step of classifying the feature matrix by using the classifier, and obtaining a classification result includes:
respectively inputting the feature matrix into a space pooling layer and an average pooling layer;
calculating to obtain class-specific residual characteristics on the space pooling layer according to the characteristic matrix;
calculating a sampling feature vector on the average pooling layer according to the feature matrix;
calculating to obtain class-specific residual attention characteristics according to class-specific residual characteristics and sampling characteristic vectors;
the class-specific residual attention features are sent to the residual attention classifier to obtain a classification result.
4. A chest CT image classification model training method according to claim 3, wherein the step of computing class-specific residual features from the feature matrix on the spatial pooling layer comprises:
computing a category-specific attention score at a spatial pooling layer;
class-specific residual features are obtained from the class-specific attention scores.
5. A chest CT image classification model training method according to claim 3 wherein the step of calculating class specific residual attention features from the class specific residual features and the sampled feature vectors comprises:
presetting super parameters;
class-specific residual features are multiplied by the hyper-parameters and weighted with the sampled feature vectors to obtain class-specific residual attention features.
6. The method of claim 1, wherein the step of calculating a loss value from the classification result and the classification tag set comprises:
and carrying the classification result and the classification label set into a cross entropy function, and calculating the loss value.
7. The chest CT image classification model training method of claim 1, wherein the step of adjusting parameters of the classifier and the RepVGG module according to the loss values comprises:
and adjusting parameters of the classifier and the RepVGG module by using a random gradient descent method until the loss value is smaller than a preset threshold value.
8. An image classification method, characterized by comprising the steps of:
acquiring an image to be determined;
inputting the image to be determined into the chest CT image classification model according to any one of claims 1 to 7, obtaining a predicted value of the probability of the image to be determined under each classification label, and taking the classification label corresponding to the predicted value as the classification of the image to be diagnosed.
9. A training system for a chest CT image classification model, comprising:
the image processing device comprises a sample acquisition module, a processing module and a processing module, wherein the sample acquisition module is used for acquiring an image sample set, and the image sample set comprises an image set and a classification label set corresponding to the image set;
the feature extraction module is used for extracting features of the image set to obtain a feature matrix;
the classification module is used for classifying the feature matrix by using a classifier to obtain a classification result;
the loss calculation module is used for calculating a loss value according to the classification result and the classification tag set;
and controlling a training module, and adjusting parameters of the classifier and the RepVGG module according to the loss value.
10. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method according to any one of claims 1 to 7 when the computer program is executed or the processor implementing the steps of the method according to claim 8 when the computer program is executed.
CN202310843300.5A 2023-07-11 2023-07-11 Chest CT image classification model training method, classification method, system and equipment Pending CN116630303A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310843300.5A CN116630303A (en) 2023-07-11 2023-07-11 Chest CT image classification model training method, classification method, system and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310843300.5A CN116630303A (en) 2023-07-11 2023-07-11 Chest CT image classification model training method, classification method, system and equipment

Publications (1)

Publication Number Publication Date
CN116630303A true CN116630303A (en) 2023-08-22

Family

ID=87592318

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310843300.5A Pending CN116630303A (en) 2023-07-11 2023-07-11 Chest CT image classification model training method, classification method, system and equipment

Country Status (1)

Country Link
CN (1) CN116630303A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20210319319A1 (en) * 2021-05-28 2021-10-14 Intel Corporation Methods and apparatus to implement parallel architectures for neural network classifiers
CN115311194A (en) * 2022-05-23 2022-11-08 湘潭大学 Automatic CT liver image segmentation method based on transformer and SE block
CN115375712A (en) * 2022-10-25 2022-11-22 西南科技大学 Lung lesion segmentation method for realizing practicality based on bilateral learning branch

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20210319319A1 (en) * 2021-05-28 2021-10-14 Intel Corporation Methods and apparatus to implement parallel architectures for neural network classifiers
CN115311194A (en) * 2022-05-23 2022-11-08 湘潭大学 Automatic CT liver image segmentation method based on transformer and SE block
CN115375712A (en) * 2022-10-25 2022-11-22 西南科技大学 Lung lesion segmentation method for realizing practicality based on bilateral learning branch

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
KIEN TRANG 等: "Improving RepVGG model with variational data imputation in COVID-19 classification", 《IAES INTERNATIONAL JOURNAL OF ARTIFICIAL INTELLIGENCE (IJ-AI)》, pages 1278 *
LIORA MAYATS-ALPAY 等: "Deep learning methods for automatic classi cation of medical images and disease detection based on chest X-Ray images", 《ARXIV:2211.08244V1》, pages 1 - 16 *
ZONGYUN GU 等: "Classification of Diabetic Retinopathy Severity in Fundus Images Using the Vision Transformer and Residual Attention", 《HINDAWI》, pages 1 - 12 *
刘俊明 等: "基于 RepMLP 的肺部 CT 图像分割", 《理论算法》, pages 43 - 45 *

Similar Documents

Publication Publication Date Title
US10482603B1 (en) Medical image segmentation using an integrated edge guidance module and object segmentation network
García et al. Detection of diabetic retinopathy based on a convolutional neural network using retinal fundus images
Habib et al. Ensemble of CheXNet and VGG-19 feature extractor with random forest classifier for pediatric pneumonia detection
Almadhoun et al. Detection of brain tumor using deep learning
Wang et al. FE-YOLOv5: Feature enhancement network based on YOLOv5 for small object detection
Ai et al. FN-OCT: Disease detection algorithm for retinal optical coherence tomography based on a fusion network
Srivastava et al. CoviXNet: A novel and efficient deep learning model for detection of COVID-19 using chest X-Ray images
Li et al. Benign and malignant mammographic image classification based on convolutional neural networks
Mascarenhas et al. Artificial intelligence and capsule endoscopy: unravelling the future
Hatamizadeh et al. Deep dilated convolutional nets for the automatic segmentation of retinal vessels
Hu et al. Content‐based gastric image retrieval using convolutional neural networks
Alqudah et al. Lightweight Deep Learning for Malaria Parasite Detection Using Cell-Image of Blood Smear Images.
Skouta et al. Automated binary classification of diabetic retinopathy by convolutional neural networks
CN114372564A (en) Model training method for object classification, object classification method and device
Qi et al. Hep-2 cell classification: The role of gaussian scale space theory as a pre-processing approach
Gang et al. Recognition of honeycomb lung in CT images based on improved MobileNet model
Xu et al. Improving COVID-19 CT classification of CNNs by learning parameter-efficient representation
Wibisono et al. Traditional food knowledge of Indonesia: a new high-quality food dataset and automatic recognition system
Mikhaylichenko et al. Automatic grading of knee osteoarthritis from plain radiographs using densely connected convolutional networks
Valizadeh et al. The Progress of Medical Image Semantic Segmentation Methods for Application in COVID‐19 Detection
Kibriya et al. A residual network-based framework for COVID-19 detection from CXR images
Kothala et al. Localization of mixed intracranial hemorrhages by using a ghost convolution-based YOLO network
CN110852351A (en) Image-based garbage classification method and device, terminal equipment and storage medium
Ali et al. COVID-19 pneumonia level detection using deep learning algorithm and transfer learning
CN106529455A (en) Fast human posture recognition method based on SoC FPGA

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20230822