Multi-classification auxiliary detection and information processing method for childhood pneumonia
Through multi-classified auxiliary detection and information processing methods for children's pneumonia, a radiation-free auxiliary detection system is established using multiple machine learning algorithms and integrated learning methods, which solves the problems of delayed diagnosis of children's pneumonia and adverse physical impacts, and achieves fast, accurate and personalized diagnostic results.
Patent Information
- Application Number
- CN202410841558.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-27
- Publication Date
- 2025-04-01
- Estimated Expiration
- 2044-06-27
AI Technical Summary
In the prior art, there are delays in the diagnosis of pneumonia in children and adverse effects on the children's bodies, and children are highly sensitive to cancer induction, and the cumulative dose of CT scan is related to the risk of hematologic malignant tumors.
A multi-classified auxiliary detection and information processing method for children's pneumonia was designed. Through the use of data reading and preprocessing, feature extraction, model training and evaluation, integrated learning and visualization tools, a radiation-free auxiliary detection system was established to help clinicians quickly diagnose the pneumonia situation and identify the location and severity of the disease.
It significantly improves the rapidity and accuracy of diagnosis, reduces the adverse effects on children's bodies, and enhances the stability and predictive ability of the model through multi-model fusion and feature evaluation, providing more personalized and accurate medical services.
Smart Images

Figure CN118841157B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of multi-classification auxiliary detection of childhood pneumonia, and in particular relates to a multi-classification auxiliary detection and information processing method for childhood pneumonia. Background Art
[0002] In the existing technology, X-rays and chest CT have the following advantages in the clinical diagnosis of pneumonia in children:
[0003] 1. High-resolution imaging can not only determine whether a person is sick, but also determine the type of disease, stage of disease development and severity;
[0004] 2. Accurately locate the lesion, accurately locate the lesion area, and evaluate the size, morphology and distribution of the lesion, which helps to clarify the diagnosis and formulate a treatment plan;
[0005] 3. Effective screening and identification of most pneumonia cases, such as lobar consolidation and interstitial changes, facilitates initial diagnosis and subsequent treatment decisions;
[0006] 4. Widely used. The equipment is widely used worldwide, and the technical operation is relatively simple, which is suitable for primary medical institutions;
[0007] However, the delay in test results and the rapid deterioration of children's diseases often delay the best time for treatment of children, and traditional monitoring methods often have many effects on children's bodies during long-term hospitalization. Studies have shown that children are four times more sensitive to cancer induction than adults, and there is a significant correlation between the cumulative dose of CT scans and the risk of all hematological malignancies. For every increase of 100mGy, the additional relative risk (ERR) is 1.96. In response to the above situation, we have designed a set of auxiliary classification and auxiliary detection and processing systems for children's pneumonia to help clinicians quickly diagnose patients' pneumonia. At the same time, the system is equipped with pneumonia location recognition and severity recognition functions, without radiation, and more safely helps doctors diagnose the disease more promptly and accurately, winning more treatment time for patients. Summary of the invention
[0008] The present invention provides a multi-classification auxiliary detection and information processing method for childhood pneumonia, which solves the problem that clinicians are unable to quickly diagnose the pneumonia condition of patients.
[0009] The specific technical solutions are as follows:
[0010] The method for multi-classification auxiliary detection and information processing of pneumonia in children includes the following steps:
[0011] Step S1: data reading and preprocessing to obtain preprocessed data;
[0012] Step S2: extract features from the preprocessed data to obtain the features that are most helpful in improving the prediction performance, and establish a CSV format database of children's pneumonia;
[0013] Step S3: training the model based on the features that improve the prediction performance to obtain the best performing model and its parameters;
[0014] Step S4: Evaluate each model based on the best performing model and its parameters to obtain the most suitable model;
[0015] Step S5: Based on the most suitable model and features, multiple integrated methods are used to improve the stability of the model and the prediction accuracy, and a stable model and prediction accuracy are obtained;
[0016] Step S6: Use visualization tools to understand the working principle and decision-making process of the model, and also facilitate reporting and interpretation of model results;
[0017] Step S7: After optimization and adjustment steps, the final model is obtained.
[0018] Preferably, after completing steps S1 and S2, the following sub-steps are performed:
[0019] Sub-step S11: Use the Pandas library to read the data stored in the CSV file;
[0020] Sub-step S12: Use StandardScaler to perform data standardization.
[0021] Preferably, step S2 includes the following sub-steps:
[0022] Sub-step S21: increasing data diversity through the SMOTE algorithm;
[0023] Sub-step S22: Evaluate the importance of features using AdaBoost, decision tree, extra tree, gradient boosting and random forest algorithms;
[0024] Sub-step S23: By comparing the feature importance scores of different models, select the features that are most helpful in improving the prediction performance.
[0025] Preferably, step S3 includes the following sub-steps:
[0026] Sub-step S31: finding the optimal configuration of each algorithm for the current data set by trying various parameter combinations;
[0027] Sub-step S32: Use grid search and random search tools in the sklearn library to systematically explore the parameter space to ensure that parameter settings that maximize model performance are found;
[0028] Sub-step S33: select 10-fold cross validation to obtain a more stable estimation result;
[0029] Sub-step S34: Compare the effects of different model configurations through the results of 10-fold cross-validation, and finally select the best performing model and its parameters for final model training.
[0030] Preferably, step S4 includes the following sub-steps:
[0031] Sub-step S41: comprehensively evaluating and comparing the performance of each classification model through the performance indicators of accuracy, recall, specificity, and F1 score;
[0032] Sub-step S42: providing an intuitive view of correct and incorrect classifications for each category through the confusion matrix, so that the performance of the model in each category is clear at a glance;
[0033] Sub-step S43: plotting the ROC curve for each model and calculating the area under the curve (AUC) to evaluate the overall classification performance of the model;
[0034] Sub-step S44: Select the most appropriate model through accuracy, recall, specificity, F1 score, confusion matrix, ROC curve, and area under the curve AUC evaluation methods.
[0035] Preferably, step S5 includes the following sub-steps:
[0036] Sub-step S51: Model output integration combines the prediction results of different models through a weighted average strategy;
[0037] Sub-step S52: The feature importance of each model is weighted averaged, and the different views of each model on feature importance are integrated to form a comprehensive and more accurate feature importance measure.
[0038] Preferably, step S6 includes the following sub-steps:
[0039] Sub-step S61: Obtaining an accuracy curve and a CSV file through visualization technology;
[0040] Sub-step S62: the accuracy curve graph shows the changing trend of the accuracy of each model as the number of features increases;
[0041] Sub-step S63: The feature importance results are output to a CSV file.
[0042] Preferably, step S7 includes the following sub-steps:
[0043] Sub-step S71: After the initial model training, fine-tune the model parameters based on the performance of the model on the validation data;
[0044] Sub-step S72: Perform a five-fold cross validation on the data after slight adjustments to the model parameters to ensure the stability and generalization ability of the model.
[0045] Compared with the prior art, the present invention has the following beneficial effects:
[0046] (1) Multi-model fusion: The present invention improves prediction accuracy by utilizing multiple algorithms and integrated learning methods, thereby significantly enhancing the model's ability to handle complex medical data. Through integrated methods such as random forests, gradient boosting machines, and support vector machines, the prediction results of different models are comprehensively considered, reducing the possible deviations of any single model. In addition, the integrated model can effectively improve the utilization rate of data. By comparing and analyzing the performance of different models on the same data set, it can provide clinicians with direct guidance on how to adjust and optimize the model configuration. This flexibility is particularly important when dealing with rapidly changing clinical environments and complex pathological types, ensuring the stability and reliability of the model under changing conditions.
[0047] (2) Extensive feature evaluation: The present invention uses a variety of feature selection methods to identify biomarkers or imaging features that are most relevant to the development and type of pneumonia. This process not only enhances the predictive power of the model, but also provides insights into medical research, helping us understand why certain features are associated with diseases. For example, through feature importance assessment, the imaging features that have the greatest impact on diagnostic results can be identified, paving the way for the development of more effective diagnostic tools and treatments. This is of great significance for promoting personalized medicine and precision treatment.
[0048] (3) High customizability: The high customizability of the model allows us and clinicians to adjust the parameters of each model according to specific clinical needs and research standards. This flexibility ensures that the model can be used to its maximum effect in different medical environments and patient groups. Whether it is adjusting the complexity of the algorithm to adapt to the limitations of computing resources or modifying the data processing flow to adapt to specific clinical test data, this customizability enables the technical solution to flexibly respond to various medical data analysis needs.
[0049] (4) Interpretability of results: In the medical field, the interpretability of the model is very critical, which directly affects the clinicians' trust and acceptance of the technology. By generating confusion matrices and ROC curves, the present invention not only provides an intuitive way to evaluate the performance of the model, but also clearly shows the performance of the model in different diseases and disease courses, helping doctors understand the basis of the model's predictions. This transparency is crucial to establishing a trusting relationship between doctors and machine learning models, and helps promote the application of AI in clinical practice.
[0050] (5) Diversity in disease diagnosis: A significant advantage of the present invention is that it can further distinguish pneumonia based on the specific location of the disease after identifying it. In the diagnosis of pneumonia, identifying the specific location of the lesion is crucial for selecting an appropriate treatment strategy, because pneumonia in different locations may require different management methods and therapeutic drugs. It can help clinicians determine the location of the disease quickly, accurately and without radiation, thereby providing doctors with more powerful data support, making the treatment plan more personalized and accurate, and ultimately achieving more tailored and effective medical services for patients.
[0051] (6) Accuracy of diagnosis of severity: Another outstanding advantage of the scheme of the present invention is its ability to accurately judge the severity of pneumonia. In clinical management, timely and accurate assessment of the severity of pneumonia is very critical, which is directly related to the choice of treatment strategy and the intensity of disease monitoring. This model predicts the possible development trend of the disease by distinguishing the severity of pneumonia. This not only helps clinicians make more accurate treatment decisions in the first time, but also predicts the recovery of the disease to a certain extent, providing a scientific basis for the health management of patients. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] In order to more clearly illustrate the technical solution of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0053] Figure 1 The figure is a schematic diagram of the operation flow of the pneumonia auxiliary detection system implemented in the present invention.
[0054] Figure 2 This is a GUI interface for operating the pneumonia auxiliary detection system implemented in the present invention.
[0055] Figure 3 This is a schematic diagram of the operation flow of the multi-classification auxiliary detection system implemented in the present invention. DETAILED DESCRIPTION
[0056] The present invention is described in detail below in conjunction with specific embodiments. The following embodiments will help those skilled in the art to further understand the present invention, but are not intended to limit the present invention in any form. It should be noted that, for those of ordinary skill in the art, several variations and improvements may be made without departing from the concept of the present invention. These all belong to the present invention.
[0057] The method for multi-classification auxiliary detection and information processing of pneumonia in children includes the following steps:
[0058] Step S1: data reading and preprocessing to obtain preprocessed data;
[0059] Step S2: extract features from the preprocessed data to obtain the features that are most helpful in improving the prediction performance, and establish a CSV format database of children's pneumonia;
[0060] Step S3: training the model based on the features that improve the prediction performance to obtain the best performing model and its parameters;
[0061] Step S4: Evaluate each model based on the best performing model and its parameters to obtain the most suitable model;
[0062] Step S5: Based on the most suitable model and features, multiple integrated methods are used to improve the stability of the model and the prediction accuracy, and a stable model and prediction accuracy are obtained;
[0063] Step S6: Use visualization tools to understand the working principle and decision-making process of the model, and also facilitate reporting and interpretation of model results;
[0064] Step S7: After optimization and adjustment steps, the final model is obtained.
[0065] After completing step S2, the following sub-steps are performed in this embodiment:
[0066] Sub-step S11: Use the Pandas library to read the data stored in the CSV file;
[0067] Sub-step S12: Use StandardScaler to perform data standardization.
[0068] Step S2 of this embodiment includes the following sub-steps:
[0069] Sub-step S21: increasing data diversity through the SMOTE algorithm;
[0070] Sub-step S22: Evaluate the importance of features using AdaBoost, decision tree, extra tree, gradient boosting and random forest algorithms;
[0071] Sub-step S23: By comparing the feature importance scores of different models, select the features that are most helpful in improving the prediction performance.
[0072] Step S3 of this embodiment includes the following sub-steps:
[0073] Sub-step S31: finding the optimal configuration of each algorithm for the current data set by trying various parameter combinations;
[0074] Sub-step S32: Use grid search and random search tools in the sklearn library to systematically explore the parameter space to ensure that parameter settings that maximize model performance are found;
[0075] Sub-step S33: select 10-fold cross validation to obtain a more stable estimation result;
[0076] Sub-step S34: Compare the effects of different model configurations through the results of 10-fold cross-validation, and finally select the best performing model and its parameters for final model training.
[0077] Step S4 of this embodiment includes the following sub-steps:
[0078] Sub-step S41: comprehensively evaluating and comparing the performance of each classification model through the performance indicators of accuracy, recall, specificity, and F1 score;
[0079] Sub-step S42: providing an intuitive view of correct and incorrect classifications for each category through the confusion matrix, so that the performance of the model in each category is clear at a glance;
[0080] Sub-step S43: plotting the ROC curve for each model and calculating the area under the curve (AUC) to evaluate the overall classification performance of the model;
[0081] Sub-step S44: Select the most appropriate model through accuracy, recall, specificity, F1 score, confusion matrix, ROC curve, and area under the curve AUC evaluation methods.
[0082] Step S5 of this embodiment includes the following sub-steps:
[0083] Sub-step S51: Model output integration combines the prediction results of different models through a weighted average strategy;
[0084] Sub-step S52: The feature importance of each model is weighted averaged, and the different views of each model on feature importance are integrated to form a comprehensive and more accurate feature importance measure.
[0085] Step S6 of this embodiment includes the following sub-steps:
[0086] Sub-step S61: Obtaining an accuracy curve and a CSV file through visualization technology;
[0087] Sub-step S62: the accuracy curve graph shows the changing trend of the accuracy of each model as the number of features increases;
[0088] Sub-step S63: The feature importance results are output to a CSV file.
[0089] Step S7 of this embodiment includes the following sub-steps:
[0090] Sub-step S71: After the initial model training, fine-tune the model parameters based on the performance of the model on the validation data;
[0091] Sub-step S72: Perform a five-fold cross validation on the data after slight adjustments to the model parameters to ensure the stability and generalization ability of the model.
[0092] When this implementation plan is implemented,
[0093] (1) Data reading and preprocessing
[0094] The data reading and preprocessing stage is the starting step of the machine learning process. The key is to efficiently prepare the data for subsequent analysis. In this process, the code first uses the Pandas library to read the data stored in the CSV file. This CSV file format is widely used to store tabular data, and the Pandas library provides convenient functions to process such data. Next, in order to eliminate potential biases between different feature metrics, StandardScaler is used to standardize the data. This step ensures the equal importance of each feature when evaluating the model by removing the mean and scaling to unit variance, thereby avoiding the model from being biased against certain larger variables during training.
[0095] (2) Feature selection
[0096] Feature selection is a key step to improve model efficiency and effectiveness. First, the code increases the diversity of the data through the SMOTE algorithm, especially by oversampling minority class samples through the synthesis method to solve the problem of class imbalance. Then, the importance of features is evaluated using AdaBoost, decision tree, extra tree, gradient boosting, and random forest algorithms. These algorithms each evaluate which features are most critical to model prediction and rank them accordingly. By comparing the feature importance scores of different models, the features that are most helpful in improving prediction performance are selected, providing a solid data foundation for model training.
[0097] (3) Model training
[0098] During the model training phase, multiple classifiers such as KNN, SVM, RF, etc. are instantiated and fine-tuned. By trying various parameter combinations, such as the number of neighbors for KNN, C and gamma values for SVM, the number and depth of trees for random forests, etc., the optimal configuration of each algorithm for the current data set is found. The grid search and random search tools in the sklearn library are used to systematically explore the parameter space to ensure that the parameter settings that maximize the model performance are found. In addition, the K-fold cross-validation method is used for the training of each model, and 10-fold cross-validation is usually selected to obtain more stable estimation results. This method can effectively evaluate the generalization ability of the model, that is, the performance on new data that has not been seen, and also help reduce the risk of model overfitting. The results of the 10-fold cross-validation are used to compare the effects of different model configurations, and finally the best performing model and its parameters are selected for the final model training.
[0099] (4) Model evaluation
[0100] In the model evaluation phase, it is critical to comprehensively evaluate and compare the performance of each classification model through a variety of performance metrics. Accuracy, recall, specificity, and F1 score are commonly used evaluation metrics. Accuracy provides the proportion of correct predictions made by the model, recall (or sensitivity) measures the proportion of positive class instances identified by the model, specificity refers to the proportion of negative class instances correctly identified by the model, and F1 score is the harmonic average of precision and recall, which is often used for imbalanced class problems. In addition, the confusion matrix provides an intuitive view of correct and incorrect classifications for each class, making the performance of the model on each class clear at a glance. This stage also includes drawing operating characteristic (ROC) curves for each model and calculating the area under the curve (AUC) to evaluate the overall classification performance of the model. The ROC curve shows how the model's ability to identify the positive class is affected by false positives by depicting the true positive rate and false positive rate at different thresholds, while the AUC value provides a single quantitative indicator for this performance, and the closer it is to 1, the better the model's performance. Together, these evaluation methods provide a solid basis for ultimately selecting the most appropriate model.
[0101] (5) Ensemble Learning
[0102] In the ensemble learning phase, this solution uses a variety of ensemble methods to improve the stability and prediction accuracy of the model. First, the model output ensemble combines the prediction results of different models through a weighted average strategy. This strategy takes into account the performance of each individual model and assigns different weights to each model so that it can play a greater role in the final prediction. For example, if a model shows a high accuracy rate during the cross-validation process, it will receive a higher weight in the final prediction result. In addition, the feature importance of each model is weighted averaged, integrating the different views of each model on the feature importance to form a comprehensive and more accurate feature importance measure. This not only helps to understand which features have the greatest impact on the prediction results, but also guides future data collection and processing.
[0103] (6) Visualization and result output
[0104] In order to more intuitively display the model performance and analyze the results, data visualization technology is used extensively in this technical solution. Among them, the accuracy curve shows the changing trend of the accuracy of each model as the number of features increases, helping us identify the minimum set of features required without sacrificing too much performance. In addition, the feature importance results are output to a CSV file, which not only facilitates technical personnel to conduct detailed follow-up analysis, but also provides a basis for feature selection in practical applications. Through these visualization tools, researchers and practitioners can more easily understand the working principle and decision-making process of the model, and it is also convenient to report and explain the model results to non-technical stakeholders.
[0105] (7) Optimization and adjustment
[0106] In order to maximize the performance of the model, in-depth parameter adjustment and optimization were performed. After the initial model training, the model parameters were fine-tuned based on the model's performance on the validation data. This process may include adjusting the learning rate, changing the regularization strength, or optimizing other key parameters to improve the model's adaptability to new data and prediction accuracy. In addition, to ensure the stability and generalization of the model, a five-fold cross-validation was implemented. This approach not only reduces the possible overfitting problem of the model, but also ensures that the model maintains consistent high performance on a variety of different data partitions. Through these meticulous optimization and adjustment steps, the robustness and practicality of the final model are ensured, laying a solid foundation for practical application.
[0107] The present invention is further described in detail with reference to the accompanying drawings. Figure 1 This is a schematic diagram of the operation flow of the pneumonia auxiliary detection system. When we run the program of the present invention, we will get Figure 2In the GUI interface of the inflammation-assisted detection system, we need to open the target folder and select the target binary bin file. Next, we need to perform DCT conversion operations. The purpose is to convert the collected data, that is, the binary bin file data, and store it in a unified DCT format, ready for feature value extraction processing. Click the feature value extraction button and the program will automatically extract time-frequency domain features, where time domain features include mean, maximum, minimum, standard deviation, variance, root mean square value, etc., and frequency domain features include the mean, variance, maximum, minimum, standard deviation, skewness, kurtosis, etc. of the spectrum, a total of 79 dimensional feature values and can be saved. Next, we read the database file, extract training data and labels, use the random forest model for training and prediction, repeat the prediction 100 times, and count the prediction results each time. The purpose of this is to reduce the randomness of the results and increase the robustness of the results. Through multiple diagnostic predictions, the stability and reliability of the final results can be increased, and it can also help us better understand the performance of this model on different data subsets. The final test results will be displayed in the diagnosis box.
[0108] Figure 3 This is a schematic diagram of the operation flow of the multi-classification auxiliary detection system. Figure 1All the features in the data were extracted into an Excel spreadsheet and used as the database for our pneumonia auxiliary detection. So far, there are more than 1,500 cases in the database. Each case in the database is classified according to the hospital's professional diagnosis. (1) We converted the database into a CSV format file, which contains the original data set we need to classify. (2) We performed various data preprocessing. This step mainly extracted all 79-dimensional features and label data in the database. The feature data was normalized using standardization to ensure that the data distribution of each feature was similar. The dataset was oversampled using SMOTE (Synthetic Minority Over-sampling Technique) technology to deal with the class imbalance problem. (3) In the data segmentation stage, we split the dataset into a training set and a test set, with 30% of the data used for testing and 70% for training. (4) In the feature selection part, a variety of models were used, including AdaBoost, Decision Tree, ExtraTrees, Gradient Boosting, Random Forest, KNN and SVM, a total of seven models, to calculate the importance of each feature. Then, the features were ranked according to their importance, and the features that improved the model performance most significantly were selected. (5) In the training and evaluation part, different classifiers are used to train the training set. Then, each model is predicted and the confusion matrix, accuracy, recall, precision, F1 score and other evaluation indicators are calculated. (6) In the weight calculation part, the weight is calculated according to the error of each model, and the size of the weight is proportional to the accuracy of the model. Then the output of each model is weighted to obtain the final combined model. (7) In the ensemble learning part, the XGBoost model is used to train the weighted features in this step, and the model performance is evaluated using five-fold cross validation. The output of the final combined model is the weighted average of the prediction results of multiple base models. (8) In the final result, the feature importance, FPR and TPR of the ROC curve and other results are saved as a CSV file for subsequent analysis and display. The code as a whole has done the whole process from data loading, preprocessing, segmentation, feature selection, model training and evaluation, weight calculation, ensemble learning to final result saving. This process can effectively deal with the problem of data imbalance and improve classification accuracy and robustness through the integration of multiple machine learning models.
[0109] Table 1 and Table 2 are the results of the multi-classification auxiliary detection system for the binary classification of the position and severity of childhood pneumonia. The accuracy of this model for the binary classification of the spatial dimension of childhood pneumonia finally reached 96.92%, the sensitivity reached 100.00%, and the specificity reached 94.28%. The accuracy of the binary classification of the severity of childhood pneumonia in the time dimension reached 92.50%, the sensitivity reached 88.89%, and the specificity reached 95.45%. The overall performance reflected by the operation results is good, which is higher than the highest level of using artificial intelligence algorithms to identify childhood pneumonia imaging compared with existing technologies. It truly achieves sensitive response, rapid response, and identification response to the disease when applied.
[0110] Table 1
[0111] Pneumonia location classification accuracy 0.9692307692307692 Sensitivity of pneumonia location classification 1.0 Pneumonia location classification specificity 0.9428571428571428 Pneumonia location classification accuracy 0.9375 Pneumonia location classification F1 score 0.967741935483871
[0112] Table 2
[0113] Accuracy of pneumonia severity classification 0.925 Sensitivity of pneumonia severity classification 0.8888888888888888 Specificity of pneumonia severity classification 0.9545454545454546 Accuracy of pneumonia severity classification 0.9411764705882353 F1 score for pneumonia severity classification 0.9142857142857143
Claims
1. A multi-classification auxiliary detection and information processing method for childhood pneumonia, characterized in that: The following steps are involved: Step S1: data reading and preprocessing to obtain preprocessed data; Step S2: extract features from the preprocessed data to obtain 79-dimensional features that are most helpful in improving the prediction performance, and establish a CSV format childhood pneumonia database; Step S3: training the model based on the features that improve the prediction performance to obtain the best performing model and its parameters; Step S4: Evaluate each model based on the best performing model and its parameters to obtain the most suitable model; Step S5: Based on the most suitable model and features, multiple integrated methods are used to improve the stability of the model and the prediction accuracy, and a stable model and prediction accuracy are obtained; Step S6: Use visualization tools to understand the working principle and decision-making process of the model, and also facilitate reporting and interpretation of model results; Step S7: Obtain the final model through optimization and adjustment steps; After step S2, the following sub-steps are performed: Sub-step S11: Use the Pandas library to read the data stored in the CSV file; Sub-step S12: using StandardScaler to perform data standardization; The step S2 comprises the following sub-steps: Sub-step S21: increasing data diversity through the SMOTE algorithm; Sub-step S22: Evaluate the importance of features using AdaBoost, decision tree, extra tree, gradient boosting and random forest algorithms; Sub-step S23: selecting the features that are most helpful in improving prediction performance by comparing the feature importance scores of different models; The step S3 comprises the following sub-steps: Sub-step S31: finding the optimal configuration of each algorithm for the current data set by trying various parameter combinations; Sub-step S32: Use grid search and random search tools in the sklearn library to systematically explore the parameter space to ensure that parameter settings that maximize model performance are found; Sub-step S33: select 10-fold cross validation to obtain a more stable estimation result; Sub-step S34: comparing the effects of different model configurations through the results of 10-fold cross validation, and finally selecting the best performing model and its parameters for final model training; The step S4 comprises the following sub-steps: Sub-step S41: comprehensively evaluating and comparing the performance of each classification model through the performance indicators of accuracy, recall, specificity, and F1 score; Sub-step S42: providing an intuitive view of correct and incorrect classifications for each category through the confusion matrix, so that the performance of the model in each category is clear at a glance; Sub-step S43: plotting the ROC curve for each model and calculating the area under the curve (AUC) to evaluate the overall classification performance of the model; Sub-step S44: Select the most appropriate model through accuracy, recall, specificity, F1 score, confusion matrix, ROC curve, and area under the curve AUC evaluation method; The step S5 comprises the following sub-steps: Sub-step S51: Model output integration combines the prediction results of different models through a weighted average strategy; Sub-step S52: weighted average of the feature importance of each model is performed to integrate the different views of each model on the feature importance and form a comprehensive and more accurate feature importance measure; The step S6 comprises the following sub-steps: Sub-step S61: Obtaining an accuracy curve and a CSV file through visualization technology; Sub-step S62: the accuracy curve graph shows the changing trend of the accuracy of each model as the number of features increases; Sub-step S63: The feature importance results are output to a CSV file; The step S7 comprises the following sub-steps: Sub-step S71: After the initial model training, fine-tune the model parameters based on the performance of the model on the validation data; Sub-step S72: Perform a five-fold cross validation on the data after slight adjustments to the model parameters to ensure the stability and generalization ability of the model.
Citation Information
Patent Citations
Deep learning-based pneumonia CT image classification method and system
CN117315380A