A lung nodule traditional Chinese medicine intervention effect prediction model training method, prediction method and device

CN122597920APending Publication Date: 2026-08-18CHINA JAPAN FRIENDSHIP HOSPITAL
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610990454.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2025-09-05
Filing Date
2026-07-03
Publication Date
2026-08-18

AI Technical Summary

Technical Problem

[0006]鉴于此,本发明实施例提供了一种肺结节中医干预效果预判模型训练方法、预判方法及装置,以消除或改善现有技术中存在的一个或更多个缺陷,解决现有技术无法在治疗前对肺结节的中医药治疗疗效进行精准预判的问题

Benefits of technology

[0017]本发明所述肺结节中医干预效果预判模型训练方法、预判方法及装置,首先构建包含肺结节CT图像、结节性状质量参数及中医干预预后效果标签的第一训练样本集;通过预训练的肺结节目标分割模型处理CT图像,输出结节轮廓坐标并确定结节中心坐标,基于中心坐标周边设定范围的像素灰度值进行聚类,计算中心坐标到各聚类中心的距离,生成灰度密度分布特征;进而搭建三分支初始识别模型,第一分支由主干网络提取图像初步特征,嵌入结节中心坐标后经注意力机制层输出位置增强特征图像,第二分支通过全连接层与激活函数对结节质量参数编码,第三分支导入灰度密度分布特征,三类特征经维度统一后加权融合,由分类头输出预后效果预测值;最后基于预测值与标签的偏差构建损失,迭代更新模型参数完成训练。本发明通过多分支架构实现多源特征的互补融合,借助显式坐标嵌入的注意力机制强化结节区域特征表达,有效抑制背景噪声干扰,适配中医药疗效预测场景小样本、高异质性的数据特点,可显著提升模型的分类判别精度;训练所得模型能够在治疗前预判中药干预的有效性,为临床个体化治疗方案制定提供量化支撑,避免无效干预延误后续治疗时机。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122597920A_ABST
    Figure CN122597920A_ABST
Patent Text Reader

Abstract

The application provides a lung nodule traditional Chinese medicine intervention effect prediction model training method, a prediction method and a device, constructs a training sample set containing a lung nodule CT image, a nodule property quality parameter and a traditional Chinese medicine intervention post-treatment effect label; a nodule contour and a center coordinate are obtained through a pre-trained lung nodule segmentation model, and a gray density distribution feature is calculated based on local pixel clustering. Subsequently, a three-branch initial model is built: the first branch outputs a position enhanced image feature through a backbone network and a coordinate attention mechanism, the second branch encodes a nodule quality parameter feature through a full connection layer, and the third branch imports a gray density feature; after the three types of features are uniformly dimensioned, they are weighted and fused, a prediction value of a prognosis effect is output by a classification head, and the training is completed by iteratively updating parameters based on the deviation of the prediction value and the label. The application is suitable for the characteristics of a small sample and high heterogeneity of a traditional Chinese medicine efficacy prediction scene, realizes the prediction of the effectiveness of traditional Chinese medicine intervention before treatment, provides quantitative support for clinical medical treatment, and avoids the delay of diagnosis and treatment opportunities caused by invalid intervention.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of medical image processing technology, and in particular to a training method, prediction method and device for a model to predict the effect of traditional Chinese medicine intervention on pulmonary nodules. Background Technology

[0002] The widespread use of low-dose spiral CT and high-resolution CT screening has resulted in a lung nodule detection rate of 30%–50% in the general population undergoing physical examinations, with approximately 5%–10% of these nodules carrying a risk of malignancy. As the most prominent imaging finding in early-stage lung cancer, early and precise intervention for lung nodules is crucial for reducing lung cancer mortality. However, clinical practice faces a dual dilemma: overtreatment and lack of effective treatment options. High-risk nodules rely excessively on surgery or ablation, leading to a high risk of recurrence post-surgery. Meanwhile, many non-surgical patients lack effective Western medicine intervention during follow-up observation periods, bearing a significant psychological and economic burden.

[0003] Traditional Chinese medicine (TCM), based on its holistic view, syndrome differentiation and treatment, and preventive medicine theories, demonstrates unique advantages in the prevention and treatment of pulmonary nodules. Clinical practice shows that TCM compound prescriptions, through multiple components, multiple targets, and multiple pathways, can reduce nodule volume, improve TCM syndrome scores, and lower malignancy risk scores. Documents such as the "Expert Consensus on TCM Diagnosis and Management of Pulmonary Nodules Based on Screening of High-Risk Groups for Lung Cancer" also affirm the value of TCM in the whole-process management. However, current TCM efficacy evaluation still heavily relies on traditional imaging indicators such as maximum CT diameter and CT value, requiring a follow-up CT scan after the patient completes the entire treatment course to determine the effect—a typical post-treatment evaluation model. This lag not only delays timely adjustments to ineffective treatments but also wastes medical resources. More importantly, pulmonary nodule patients exhibit significant individual differences; different constitutions, syndrome types, and imaging characteristics respond drastically to the same TCM intervention. Clinical practice urgently needs to predict efficacy before treatment to screen for advantageous populations, but effective tools are currently lacking. Meanwhile, there is no unified standard for evaluating CT images of pulmonary nodules. Quantitative indicators such as diameter, volume, and area are greatly affected by scanning equipment and reconstruction parameters, resulting in poor repeatability. There is also a lack of universally accepted thresholds for nodule shrinkage and standards for classifying treatment efficacy, which seriously restricts the objective evaluation of treatment efficacy.

[0004] In recent years, deep learning-based AI technology has made rapid progress in the analysis of pulmonary nodules using CT images. However, existing research has largely focused on nodule segmentation and benign / malignant differentiation, relying on large-scale public datasets such as LIDC-IDRI and LUNA16. These tasks are completely different from the prediction of TCM efficacy, and existing models and features cannot be directly transferred. Furthermore, TCM efficacy prediction has strict limitations on the data used for inclusion; effective samples meeting criteria such as disease course stability, density uniformity, size window, and lesion uniformity are scarce, representing a typical small-sample, highly heterogeneous scenario. Existing general classification networks designed for large-scale datasets cannot be directly adapted to this scenario. At the feature extraction and fusion level, existing pulmonary nodule classification models mostly rely on single CT image features for analysis, making it difficult to comprehensively characterize nodule characteristics related to TCM efficacy.

[0005] In conclusion, there is an urgent need to develop a model training method, prediction method, and device that can stably and accurately predict the effects of TCM intervention on pulmonary nodules before treatment. This would help identify the advantageous population that can truly benefit from TCM treatment, guide individualized clinical decision-making, reduce unnecessary treatment costs and the risk of cancer, and thus improve the scientific rigor and precision of TCM in the prevention and treatment of pulmonary nodules. Summary of the Invention

[0006] In view of this, embodiments of the present invention provide a training method, prediction method and device for predicting the effect of TCM intervention on pulmonary nodules, so as to eliminate or improve one or more defects in the prior art and solve the problem that the prior art cannot accurately predict the efficacy of TCM treatment for pulmonary nodules before treatment.

[0007] On the one hand, this invention provides a method for training a model to predict the effect of traditional Chinese medicine intervention on pulmonary nodules, the method comprising the following steps: A first training sample set containing multiple samples is obtained. Each sample contains a lung nodule CT image and lung nodule phenotypic parameters of a patient sample. The prognostic effect after adopting the target TCM intervention program is marked as the first label, and the prognostic effect includes effective or ineffective. A pre-trained lung nodule target segmentation model is used to process the CT images of lung nodules in the sample to output the contour coordinates of the lung nodules and to label the center coordinates of the lung nodules; the mean gray value of pixels within a set range around the center coordinates of each lung nodule is extracted, the mean gray value of each pixel is clustered, and the distance from the center coordinates of each lung nodule to each cluster center is calculated and recorded as gray density distribution features. An initial TCM intervention effect recognition model with three branches is obtained. The first branch includes a continuous backbone network and an attention mechanism layer. The backbone network takes the CT image of the lung nodules in the sample as input and outputs a preliminary feature image. The preliminary feature image is embedded with the center coordinates of each lung nodule and then input into the attention mechanism layer to output an enhanced feature image. The second branch consists of a fully connected layer and an activation function layer. It takes the lung nodule trait quality parameter corresponding to the sample as input and outputs nodule quality parameter features. The third branch is used to import the gray-level density distribution features corresponding to the sample. The three branches are connected to a feature fusion prediction module, which includes a convolutional projection module set for each of the three branches, as well as a global pooling layer, a fusion layer, and a classification head. This module is used to unify the size of the enhanced feature image, the nodule quality parameter features, and the gray-level density distribution features, then weighted and fused them, and outputs the predicted prognostic effect value of the target TCM intervention program through the classification head. The initial TCM intervention effect recognition model is trained using the first training sample set. The loss is constructed and the model parameters are updated based on the deviation between the predicted prognostic value and the first label to obtain the TCM intervention effect prediction model for pulmonary nodules.

[0008] In some embodiments, the method further includes: unifying the format and coordinate system of the lung nodule CT image, performing contrast-limited adaptive histogram averaging and denoising, performing resampling to unify pixel spacing and intensity normalization; and performing data augmentation based on data cropping, random rotation, scaling, translation and flipping. The pulmonary nodule morphological quality parameters include: geometric and morphological parameters used to label the size, volume, surface area, shape, and edge morphology of pulmonary nodules; CT image parameters used to label the mean CT value, CT value distribution, CT histogram parameters, and density classification of pulmonary nodules; and internal structural layers used to label the internal features, calcification state, and solid components of pulmonary nodules.

[0009] In some embodiments, the pre-training step of the lung nodule target segmentation model includes: Obtain a second training sample set containing multiple samples, each sample containing a CT image of a lung nodule from a patient sample, and label the contour coordinates of the lung nodules as a second label; The initial 3D U-Net network is trained using the second training sample set, with the lung nodule CT image as input and the predicted lung nodule contour coordinates as output. Based on the deviation between the predicted lung nodule contour coordinates and the second label, Sorenson-Dies loss and focus loss are constructed to update the parameters of the initial 3D U-Net network to obtain the lung nodule target segmentation model.

[0010] In some embodiments, the initial 3D U-Net network includes a first convolutional module, an encoding module, a decoding module, a second convolutional module, and an output layer. The encoding module includes N encoding layers, each of which includes a cascaded localization feature extraction layer and a residual module. The decoding module includes M decoding layers, each of which includes a deconvolutional layer, a transposed convolutional layer, a combination module, and a residual module. When the localization features of the CT image of lung nodules are output by the first convolution module and the encoding module, they are combined with the localization features by the deconvolution layer and the transposed convolution layer by the combination module to obtain the combined features. The combined features are then subjected to residual fusion by the residual module to obtain the output of the current decoding layer. The encoding module further includes a spatial dropout layer, which generates a random mask with a set probability according to the output feature channel dimension of the first convolutional layer. The output features of the first convolutional layer are then randomly masked using the random mask and imported into the subsequent encoding layers.

[0011] In some embodiments, the method employs the K-means algorithm to cluster the mean gray values ​​of each pixel, and uses Euclidean distance to calculate the distance from the center coordinates of each lung nodule to each cluster center.

[0012] In some embodiments, the backbone network adopts a ResNet50 network; In the method, the way of embedding the preliminary feature image into the corresponding center coordinates of each lung nodule includes: normalizing the center coordinates of each lung nodule in the sample to the [0,1] interval, and incorporating them into the preliminary feature image in the form of feature bias so that they directly carry the prior information of the lung nodule location, thereby obtaining a single-dimensional feature. The attention mechanism layer transforms the single-dimensional feature height feature B×C×H×1 into B×C×1×H, and concatenates it one-dimensionally with the width feature B×C×1×W to output a fused feature with a dimension of B×C×1×(H+W). A 1×1 convolution is used to compress the fused feature into channels, and batch normalization and ReLU activation function are used to enhance the non-linear expression. The dimensionality-reduced fused feature is split into height sub-features and width sub-features, and the values ​​are normalized to the [0,1] interval using a 1×1 convolution and the Sigmoid function to obtain the height dimension attention weight and the width dimension attention weight. The height dimension attention weight and the width dimension attention weight are then multiplied element-wise with the original single-dimensional feature row.

[0013] In some embodiments, the second branch includes two fully connected layers and a ReLU activation function; The fusion layer performs weighted fusion of the enhanced feature image, the nodule quality parameter feature, and the gray-scale density distribution feature with a weight ratio of 0.6:0.1:0.3; the classification head uses a multilayer perceptron.

[0014] On the other hand, the present invention also provides a method for predicting the prognostic effect of pulmonary nodules based on a targeted traditional Chinese medicine intervention program, the method comprising the following steps: Obtain CT images of lung nodules from the cases to be analyzed, and obtain the corresponding lung nodule phenotypic quality parameters; The lung nodule CT image is processed using a pre-trained lung nodule target segmentation model to output the lung nodule contour coordinates and label the lung nodule center coordinates; the mean gray value of pixels within a set range around the center coordinates of each lung nodule is extracted, the mean gray value of each pixel is clustered, and the distance from the center coordinates of each lung nodule to each cluster center is calculated and recorded as gray density distribution features. The lung nodule CT image, the lung nodule morphological quality parameters, and the gray-scale density distribution features are input into the lung nodule TCM intervention effect prediction model obtained by the above-mentioned lung nodule TCM intervention effect prediction model training method, and the prognostic effect identification result of the case to be analyzed with respect to the target TCM intervention plan is output.

[0015] On the other hand, the present invention also provides a device for identifying the effect of traditional Chinese medicine intervention on pulmonary nodules, including a processor, a memory, and a computer program or instructions stored in the memory. The processor is used to execute the computer program or instructions, and when the computer program / instructions are executed, the device implements the steps of the above method.

[0016] On the other hand, the present invention also provides a computer-readable storage medium having a computer program or instructions stored thereon, characterized in that the computer program or instructions, when executed by a processor, implement the steps of the above-described method.

[0017] The present invention describes a training method, prediction method, and device for predicting the effect of TCM intervention on pulmonary nodules. First, a first training sample set is constructed, including CT images of pulmonary nodules, nodule morphological quality parameters, and TCM intervention prognostic effect labels. The CT images are then processed by a pre-trained pulmonary nodule target segmentation model, outputting nodule contour coordinates and determining the nodule center coordinates. Clustering is performed based on pixel grayscale values ​​within a defined range around the center coordinates, calculating the distance from the center coordinates to each cluster center, and generating grayscale density distribution features. Next, a three-branch initial recognition model is built. The first branch extracts preliminary image features from the backbone network, embeds the nodule center coordinates, and outputs a position enhancement feature image through an attention mechanism layer. The second branch encodes the nodule quality parameters through a fully connected layer and activation function. The third branch imports grayscale density distribution features. The three types of features are weighted and fused after dimensional unification, and the predicted prognostic effect value is output by the classification head. Finally, a loss is constructed based on the deviation between the predicted value and the label, and the model parameters are iteratively updated to complete the training. This invention achieves complementary fusion of multi-source features through a multi-branch architecture, strengthens the expression of nodule region features by using an attention mechanism with explicit coordinate embedding, effectively suppresses background noise interference, and is adapted to the characteristics of small sample and highly heterogeneous data in the scenario of predicting the efficacy of traditional Chinese medicine, which can significantly improve the classification accuracy of the model. The trained model can predict the effectiveness of traditional Chinese medicine intervention before treatment, provide quantitative support for the formulation of individualized clinical treatment plans, and avoid ineffective intervention that delays subsequent treatment.

[0018] Additional advantages, objects, and features of the invention will be set forth in part in the description which follows, and will also become apparent in part to those skilled in the art upon studying the description, or may be learned by practice of the invention. The objects and other advantages of the invention can be realized and obtained by means of the structures specifically pointed out in the description and drawings.

[0019] Those skilled in the art will understand that the objectives and advantages achievable with the present invention are not limited to those specifically described above, and that the above and other objectives achievable with the present invention will become clearer from the following detailed description. Attached Figure Description

[0020] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this application, are not intended to limit the scope of the invention. In the drawings: Figure 1 This is a flowchart illustrating the training method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to an embodiment of the present invention.

[0021] Figure 2 This is a comparison chart of the treatment group data and the control group data regarding volume, CT value, mass, volume change, CT value change, and mass change in the method for predicting the effect of TCM intervention on pulmonary nodules according to another embodiment of the present invention.

[0022] Figure 3 This is a logical diagram illustrating the method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to another embodiment of the present invention.

[0023] Figure 4 This is a schematic diagram of the results of lung nodule contour recognition in CT images using a pre-trained 3D U-Net network according to an embodiment of the present invention.

[0024] Figure 5 This is a schematic diagram illustrating the extraction of gray-scale density distribution features in a method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to an embodiment of the present invention. Detailed Implementation

[0025] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the embodiments and accompanying drawings. Here, the illustrative embodiments and descriptions of this invention are used to explain the invention, but are not intended to limit the invention.

[0026] It should also be noted that, in order to avoid obscuring the invention with unnecessary details, only the structures and / or processing steps closely related to the solution according to the invention are shown in the accompanying drawings, while other details that are not closely related to the invention are omitted.

[0027] It should be emphasized that the term "including / comprises" as used herein refers to the presence of a feature, element, step, or component, but does not exclude the presence or addition of one or more other features, elements, steps, or components.

[0028] In order to accurately predict the effectiveness of TCM treatment on target nodules before patients receive TCM intervention, provide objective and quantitative scientific basis for the formulation of individualized clinical treatment plans, avoid delays in subsequent diagnosis and treatment due to ineffective TCM treatment, and provide evidence-based technical support for early non-surgical intervention of pulmonary nodules, this aims to fill the current technical gap in the field of pre-evaluation of TCM efficacy in pulmonary nodules.

[0029] This invention addresses the clinical diagnostic needs of moderate-risk pure pulmonary nodules with a diameter of 5–10 mm. Based on chest CT images and nodule quantification parameters, it constructs a predictive model for the efficacy of traditional Chinese medicine (TCM) treatment. Specifically, a 3D U-Net network is first used to perform preliminary nodule segmentation on CT images, combined with manual fine-grained annotation to obtain the nodule contour coordinates and center coordinates. On this basis, image features enhanced by coordinate attention mechanism, gray-level density distribution features based on contour local pixel clustering, and nodule quality parameter features encoded by a fully connected network are extracted. These three types of multi-source features are integrated through dimensionality standardization and weighted fusion strategies, ultimately training a binary classification predictive model for the prognostic effect of pulmonary nodules under specified TCM treatment plans.

[0030] On the one hand, the present invention provides a method for training a model to predict the effect of traditional Chinese medicine intervention on pulmonary nodules, the method comprising the following steps S101~S104: Step S101: Obtain a first training sample set containing multiple samples. Each sample contains a lung nodule CT image and lung nodule phenotypic parameters of a patient sample, and label the prognostic effect after adopting the target TCM intervention program as the first label. The prognostic effect includes effective or ineffective.

[0031] Step S102: Use a pre-trained lung nodule target segmentation model to process the lung nodule CT images in the sample and output the lung nodule contour coordinates, and label the lung nodule center coordinates; extract the pixel gray-level mean within a set range around the center coordinates of each lung nodule, cluster the pixel gray-level mean, calculate the distance from the center coordinates of each lung nodule to each cluster center, and record it as gray-level density distribution features.

[0032] Step S103: Obtain an initial TCM intervention effect recognition model containing three branches. The first branch includes a continuous backbone network and an attention mechanism layer. The backbone network takes the CT image of the lung nodules in the sample as input and outputs a preliminary feature image. The preliminary feature image is embedded with the corresponding center coordinates of each lung nodule and then input into the attention mechanism layer to output an enhanced feature image. The second branch consists of a fully connected layer and an activation function layer. It takes the lung nodule trait quality parameters corresponding to the sample as input and outputs nodule quality parameter features. The third branch is used to import the gray-level density distribution features corresponding to the sample. The three branches are connected to a feature fusion prediction module, which includes convolutional projection modules set for the three branches respectively, as well as a global pooling layer, a fusion layer and a classification head. This module is used to unify the size of the enhanced feature image, nodule quality parameter features and gray-level density distribution features, then weightedly fuses them and outputs the predicted prognostic effect value of the target TCM intervention program through the classification head.

[0033] Step S104: The initial TCM intervention effect recognition model is trained using the first training sample set. The loss is constructed and the model parameters are updated based on the deviation between the predicted prognostic effect value and the first label to obtain the TCM intervention effect prediction model for pulmonary nodules.

[0034] In step S101, retrospective clinical case data was used as the original data source, and samples were screened strictly according to four inclusion criteria: First, the disease course stability criterion required nodules to persist for at least 3 months, excluding acute reversible changes such as short-term inflammatory lesions; second, the density homogeneity criterion limited nodules to pure ground-glass opacities, excluding characteristic heterogeneity interference from mixed-density nodules; third, the size window criterion controlled nodule diameter within the 5-10 mm range, focusing on early intervention scenarios for moderate-risk nodules; and fourth, the lesion singularity criterion selected cases with a single nodule or a clearly defined main nodule to avoid confusion in efficacy assessment caused by multifocal lesions. Each sample corresponds to one patient who meets the criteria and includes two types of core data: first, the patient's lung nodule CT image data, i.e., the key slice CT image or complete thin-slice CT sequence showing the clearest nodule; second, lung nodule morphological quality parameters, covering quantitative indicators such as nodule volume, mean CT value, and nodule mass, among which nodule mass is a comprehensive measure of volume and density, which can more comprehensively reflect the biological behavior of nodules. For example, lung nodule morphological quality parameters include: geometric and morphological parameters for labeling lung nodule size, volume, surface area, shape, and edge morphology; CT image parameters for labeling lung nodule mean CT value, CT value distribution, CT histogram parameters, and density classification; and internal structural layers for labeling lung nodule internal features, calcification status, and solid components.

[0035] In the first training sample set, sample labels were created by senior clinicians based on follow-up imaging results of patients before and after receiving the target TCM intervention program. These labels comprehensively considered the dynamic changes in nodule size, density, and quality, as well as the improvement in clinical symptoms, and were assigned binary labels: valid and invalid. All samples underwent anonymization, data consistency verification, and missing value cleaning before inclusion in the dataset to ensure data standardization and privacy compliance. The sample set can be further divided into training and validation subsets according to a preset ratio for monitoring model performance during training.

[0036] In some embodiments, the method further includes: unifying the format and coordinate system of the CT images of lung nodules, performing contrast-limited adaptive histogram averaging and denoising, performing resampling to unify pixel spacing and intensity normalization; and performing data augmentation based on data cropping, random rotation, scaling, translation and flipping.

[0037] Specifically, the process begins by converting DICOM and other formats exported from CT equipment from different manufacturers into a standard medical image format. Simultaneously, the spatial coordinate systems of all images are aligned and corrected, using a standardized axial pixel coordinate system or world coordinate system to correct spatial orientation shifts caused by differences in patient positioning and equipment parameters. This operation is a fundamental prerequisite for subsequent nodule contour annotation and coordinate attention mechanisms, preventing nodule coordinate misalignment due to inconsistent coordinate system benchmarks and ensuring accurate correspondence between positional information and image pixels. Addressing the characteristics of lung nodules—small differences in grayscale compared to normal lung tissue and blurred boundaries—the CT images are divided into multiple local sub-regions. Histogram equalization is performed within each sub-region, and a contrast upper limit threshold is set to prune excessively enhanced grayscale, preventing amplification of local noise. The processing is limited to the CT value range corresponding to the lung window, specifically enhancing the contrast between lung tissue and nodule areas. This operation can improve the recognition of the heterogeneity of the edge and internal density of ground glass nodules, which not only improves the accuracy of subsequent 3D U-Net segmentation and manual annotation, but also provides better input for the backbone network to extract subtle visual features of nodules, solving the problem of low contrast and easy obscuring of features by the background in pure ground glass nodules.

[0038] Furthermore, since this scheme requires K-means clustering based on local pixel grayscale to extract grayscale density distribution features, noise can interfere with the accuracy of cluster centers and distort the quantization results of density heterogeneity. Therefore, denoising can effectively improve the reliability of grayscale density features and reduce feature errors caused by noise. This invention employs denoising algorithms adapted to medical CT images, such as nonlocal mean filtering and adaptive median filtering, to suppress quantum noise and reconstruction artifacts generated by CT scans while preserving nodule edges and density details.

[0039] Furthermore, by employing resampling algorithms such as cubic linear interpolation, CT images with different scan slice thicknesses and pixel resolutions are unified to a fixed pixel spacing and slice thickness, ensuring that the actual physical size corresponding to each pixel in the image remains consistent. This invention focuses on nodules with diameters of 5-10 mm, and grayscale density feature extraction requires cropping local blocks of fixed pixel sizes. Unifying the pixel spacing ensures that the actual physical scale corresponding to the same pixel range in different samples is consistent, avoiding feature scale mismatch caused by differences in scan resolution, and guaranteeing the comparability of features between different samples and the stability of model training.

[0040] During data augmentation, the image is cropped to a fixed size required for model input, using the nodule center as a reference. Simultaneously, a small-amplitude random offset cropping is introduced to ensure the nodule remains within the effective image area while preserving an appropriate amount of surrounding lung tissue background. This operation satisfies the model's requirement for a fixed input size and increases spatial diversity of samples through positional offset, preventing the model from over-relying on the absolute position of the nodule in the image. Within clinically reasonable limits, the image undergoes random angle rotation, small-scale scaling, and random horizontal / vertical translation. All transformations ensure the nodule remains intact within the image area, and the transformation amplitude conforms to the reasonable variation range of clinical images. These three types of transformations increase sample diversity in terms of orientation, scale, and location, enabling the model to adapt to individual differences in nodule morphology, location, and size in clinical practice, thus improving the model's generalization ability. A horizontal mirror flipping method is used to generate new training samples using the bilateral symmetry of the lungs, avoiding the introduction of invalid data that violates physiological structure. This method can expand the number of samples at low cost without changing the core features of nodule density, morphology, etc.

[0041] Step S102 includes precise nodule segmentation and gray-scale density distribution feature extraction, which is divided into two execution stages: nodule coordinate generation and feature calculation. The first stage is nodule contour and coordinate acquisition: the pre-trained 3D U-Net lung nodule segmentation model is called, the chest CT sequence corresponding to the sample is input into the model, multi-scale image features are extracted layer by layer by the encoder's downsampling convolution, and then the feature map is restored to the original image resolution by the decoder's upsampling operation, outputting the lung nodule segmentation mask, annotating all contour coordinate points of the nodule edge one by one and storing them, and at the same time, by calculating the geometric centroid of all contour coordinate points, the unique lung nodule center coordinates (x, y) are obtained. The second stage is the calculation of gray-scale density distribution features: For each nodule contour coordinate point, a local pixel block of a preset size, such as 9×9 or 7×7 pixels, is extracted with that coordinate point as the center. This size is suitable for the scale range of 5~10mm nodules and can take into account both the representativeness of local features and the noise suppression effect. K-means clustering is performed on the gray-scale values ​​of all pixels in the local pixel block. The number of clusters can be set to 10, dividing the local gray-scale into 10 density levels. Then, the Euclidean distance between the center pixel of the current coordinate point and the center of each cluster is calculated to form the gray-scale density feature vector of the coordinate point. The feature vectors corresponding to all contour coordinate points of the nodule are aggregated to finally obtain the complete gray-scale density distribution features of the nodule, which can quantify the tissue density heterogeneity inside and at the edge of the nodule and reflect the differences in the pathological attributes of the nodule.

[0042] In some embodiments, the pre-training steps of the lung nodule target segmentation model include steps S1021 and S1022: Step S1021: Obtain a second training sample set containing multiple samples, each sample containing a CT image of a lung nodule from a patient sample, and label the contour coordinates of the lung nodules as a second label.

[0043] Step S1022: Train the initial 3D U-Net network using the second training sample set, take the lung nodule CT image as input and output the predicted value of the lung nodule contour coordinates; construct the Sorenson-Dies loss and focus loss based on the deviation between the predicted value of the lung nodule contour coordinates and the second label to update the parameters of the initial 3D U-Net network and obtain the lung nodule target segmentation model.

[0044] Steps S1021 and S1022 jointly complete the pre-training of the lung nodule target segmentation model. Step S1021 is used to construct a second training sample set specifically for the segmentation task. During implementation, clinically acquired lung nodule CT images and adapted publicly available medical image samples are included. Each sample corresponds to a complete thin-slice CT sequence image of the lung. Professional radiologists meticulously annotate the contour boundaries of the lung nodules layer by layer, generating a set of contour coordinate points and corresponding pixel-level segmentation masks as the second label. Simultaneously, image format unification, spatial resampling, grayscale normalization, and other preprocessing are performed to ensure data consistency. Step S1022 uses this sample set to perform initial 3D segmentation. The U-Net network undergoes supervised training. The network extracts deep semantic features of nodules through multi-scale downsampling of the encoder, and then upsampling of shallow detail features by the decoder combined with skip connections. Finally, it outputs lung nodule segmentation prediction results and contour coordinate prediction values. The training adopts a combined loss function consisting of Sorenson-Dies loss and focal loss. The former optimizes the overlap of segmentation regions to address the characteristics of ground-glass nodules, which have a small target proportion and class imbalance. The latter focuses on difficult-to-segment regions such as nodule boundaries by suppressing the weight of easily classified background pixels. After calculating the combined loss based on the deviation between the predicted value and the second label, the network parameters are iteratively updated through backpropagation. After the model converges, a pre-trained lung nodule target segmentation model that can automatically perform preliminary segmentation of nodules is obtained.

[0045] In some embodiments, the initial 3D U-Net network includes a first convolutional module, an encoding module, a decoding module, a second convolutional module, and an output layer. The encoding module includes N encoding layers, each of which includes a cascaded localization feature extraction layer and a residual module. The decoding module includes M decoding layers, each of which includes a deconvolutional layer, a transposed convolutional layer, a combination module, and a residual module.

[0046] When the localization features of the CT image of lung nodules are output by the first convolution module and the encoding module, the output features of the deconvolution layer and the transposed convolution layer are combined with the localization features by the combination module to obtain the combined features. The combined features are then subjected to residual fusion by the residual module to obtain the output of the current decoding layer.

[0047] Optionally, when the dimension of the localization feature is the same as the dimension of the output feature of the transposed convolution, the combined feature is obtained by combining them through the combination module; when the dimension of the localization feature is different from the dimension of the output feature of the transposed convolution, the output feature of the transposed convolution is directly input to the second convolutional layer and then output through the output layer.

[0048] Optionally, the combined features also include multi-scale features. The image data is extracted to obtain multi-scale features through the multi-scale feature extraction module. The dimension of the multi-scale features is compared with the dimension of the output features of the transposed convolution. When the multi-scale features, the output features of the transposed convolution, and the localization features are combined through the combination module, a second combined feature is obtained. The second combined feature is then subjected to residual fusion through the residual module to obtain the output of the current decoding layer.

[0049] The encoding module also includes a spatial dropout layer, which generates a random mask with a set probability according to the output feature channel dimension of the first convolutional layer. The output features of the first convolutional layer are then randomly masked using the random mask and imported into the subsequent encoding layers.

[0050] Step S103 is the architecture building step for the multi-branch TCM intervention effect recognition model, which adopts a topology structure of three-branch feature extraction and terminal fusion prediction.

[0051] The first branch is the coordinate attention-enhanced image feature extraction branch, which consists of a backbone network and a coordinate attention mechanism layer connected in series. The backbone network uses a ResNet50 convolutional neural network. The input is a CT image cropped to a fixed size with the nodule as the center. After multi-layer residual convolution operation, a high-dimensional preliminary feature image is output. The coordinate attention mechanism layer receives the preliminary feature image and the coordinates of the nodule center at the same time. First, the center coordinates are normalized to the [0,1] interval to adapt to feature maps of different sizes. Then, adaptive average pooling is performed on the preliminary feature map along the height and width dimensions to obtain single-dimensional global features in two directions. Subsequently, the normalized coordinates are used as feature biases and superimposed on the pooled features of the corresponding dimensions, so that the features directly carry the prior information of the nodule location. After coordinate embedding, the pooled features of the two dimensions are adapted and concatenated. Then, a 1×1 convolutional layer is used to perform channel dimensionality reduction, batch normalization, and ReLU activation to enhance the nonlinear expression. The original feature map is then split into two sub-branches according to its height and width. These sub-branches are then processed by convolution and Sigmoid activation to generate attention weights for the height and width dimensions, respectively. Finally, the two sets of attention weights are multiplied element-wise with the original preliminary feature map to output an enhanced feature image that enhances the feature response of the nodule region and suppresses the background tissue features.

[0052] The second branch is the nodule quality parameter feature encoding branch, which consists of two fully connected layers and ReLU activation functions alternately connected. The input is nodule quality parameters such as nodule quality, volume, and average CT value. The high-dimensional encoding of quantitative indicators is completed through nonlinear transformation of the fully connected layers, and the output is nodule quality parameter features with fixed dimensions, thus exploring the potential correlation between physical quantitative indicators and the efficacy of traditional Chinese medicine.

[0053] The third branch is the gray-scale density feature import branch, which directly imports the gray-scale density distribution features extracted in step S102 without requiring additional network computation.

[0054] The outputs of the three branches are jointly fed into the feature fusion prediction module: First, a convolutional projection module and a global pooling layer are configured for each branch to uniformly map the three types of features with different dimensions into feature vectors of the same dimension; then, weighted fusion is performed in the fusion layer, with weight coefficients set according to the ratio of image enhancement features having the highest weight, gray-level density features second, and quality parameter features having the lowest weight, and the three types of features are weighted and summed to obtain the final fused feature; the fused feature is fed into a classification head composed of a fully connected layer and a sigmoid activation function, and outputs a predicted prognostic value in the range of 0 to 1, corresponding to the probability of the effectiveness of the TCM intervention plan.

[0055] In some embodiments, the method of embedding the preliminary feature image into the corresponding lung nodule center coordinates includes: normalizing the lung nodule center coordinates in the sample to the [0,1] interval, incorporating them into the preliminary feature image in the form of feature bias so that they directly carry the prior information of the lung nodule location, thereby obtaining a single-dimensional feature.

[0056] The attention mechanism layer transforms the single-dimensional feature height B×C×H×1 into B×C×1×H, and concatenates it one-dimensionally with the width feature B×C×1×W, outputting a fused feature with a dimension of B×C×1×(H+W). A 1×1 convolution is used to compress the fused feature channels, and batch normalization and ReLU activation function are used to enhance the non-linear expression. The dimensionality-reduced fused feature is split into height sub-features and width sub-features, and the values ​​are normalized to the [0,1] interval using a 1×1 convolution and the Sigmoid function to obtain the height dimension attention weights and width dimension attention weights. The height dimension attention weights and width dimension attention weights are then multiplied element-wise with the original single-dimensional feature.

[0057] In some embodiments, the fusion layer performs weighted fusion of the enhanced feature image, nodule quality parameter features, and gray-scale density distribution features with weights of 0.6:0.1:0.3; the classification head uses a multilayer perceptron.

[0058] In step S104, the pre-training configuration is first completed: the first training sample set is divided into a training set and a validation set in a preset ratio of 4:1. The training set is used for network parameter updates, and the validation set is used for real-time monitoring of the model's generalization performance. A binary cross-entropy function is selected as the loss function to quantify the deviation between the predicted prognostic value and the true label. The Adam optimizer is selected as the parameter update optimizer, and hyperparameters such as the initial learning rate, batch size, and maximum training epochs are set. During the training iteration, the CT images, phenotypic quality parameters, and gray-scale density features of the batch samples are input into the initial recognition model. After three-branch feature extraction and fusion prediction, the predicted prognostic value of each sample is output. The loss value is calculated based on the predicted value and the corresponding true first label. The loss is backpropagated layer by layer to each layer of the model network through the backpropagation algorithm, and the weight parameters of each layer are iteratively adjusted according to the optimizer's update rules.

[0059] During training, at fixed intervals, the model's performance metrics, such as AUC and F1 score, are evaluated using a validation set. If the validation set performance shows no improvement for several consecutive rounds, an early stopping mechanism is triggered to prevent overfitting. To reduce the interference of random initialization and other factors on model performance, multiple independent repeated training sessions to obtain the optimal parameters or five-fold cross-validation can be used to ensure model stability. After the training reaches convergence, the final network weight parameters are saved, resulting in a completed model that can be used to predict the efficacy of TCM intervention for pulmonary nodules.

[0060] On the other hand, the present invention also provides a method for predicting the prognostic effect of pulmonary nodules based on a target TCM intervention program, the method comprising the following steps S201~S203: Step S201: Obtain CT images of lung nodules from the case to be analyzed, and obtain the corresponding lung nodule phenotypic quality parameters.

[0061] Step S202: The lung nodule CT image is processed using a pre-trained lung nodule target segmentation model to output the lung nodule contour coordinates and label the lung nodule center coordinates; the mean gray value of pixels within a set range around the center coordinates of each lung nodule is extracted, the mean gray value of each pixel is clustered, and the distance from the center coordinates of each lung nodule to each cluster center is calculated and recorded as gray density distribution features.

[0062] Step S203: Input the CT image of the lung nodule, the quality parameters of the lung nodule characteristics, and the gray density distribution features into the lung nodule TCM intervention effect prediction model obtained by the training method of the lung nodule TCM intervention effect prediction model described in steps S101~S104 above, and output the prognostic effect identification result of the case to be analyzed with respect to the target TCM intervention plan.

[0063] Specifically, the operation methods of steps S201 to S203 can be referred to the content of steps S101 to S104 above.

[0064] On the other hand, the present invention also provides a device for identifying the effect of traditional Chinese medicine intervention on pulmonary nodules, including a processor, a memory, and a computer program or instructions stored in the memory. The processor is used to execute the computer program or instructions, and when the computer program / instructions are executed, the device implements the steps of the above method.

[0065] On the other hand, the present invention also provides a computer-readable storage medium having a computer program or instructions stored thereon, characterized in that the computer program or instructions, when executed by a processor, implement the steps of the above-described method.

[0066] The present invention will now be described with reference to a specific embodiment: This embodiment provides a method for predicting the efficacy of traditional Chinese medicine (TCM) intervention in pulmonary nodules. Compared with image processing tasks in existing technologies, nodule type classification answers the question "What does it look like?", which is a morphological description, while benign / malignant classification answers the question "Is it dangerous?", which is a judgment of pathological nature. In this embodiment, TCM efficacy classification answers the question "Can the TCM treatment plan produce an effect?", which is a prediction of the drug's response to the nodule by comprehensively considering morphological factors, pathological nature, and other physical parameters. Therefore, the current solution combines morphological image features, pathological nature, and physical parameters to comprehensively predict the drug's response to the nodule.

[0067] Numerous public datasets exist for nodule classification and benign / malignant classification, with broad data selection criteria and relatively easy sample acquisition, forming large-scale public datasets such as LIDC-IDRI and LUNA16. However, the data inclusion requirements for the medical efficacy prediction task in this embodiment are stringent. Data collection in this embodiment is strictly limited to patients who underwent CT examinations at multiple medical institutions, were found to have pulmonary ground-glass nodules, and received standardized traditional Chinese medicine treatment and regular imaging follow-up. Based on this, the following four screening criteria were set: ① Disease stability condition: nodules persist for ≥3 months, excluding acute reversible changes such as short-term inflammatory lesions; ② Density homogeneity condition: limited to pure ground-glass opacities (pGGN), excluding characteristic heterogeneity interference from mixed-density nodules; ③ Size window condition: diameter limited to 5~10mm, focusing on nodules within the early intervention window; ④ Lesion singularity condition: cases with a single nodule or a clearly defined main nodule, avoiding confusion of multifocal lesions with efficacy assessment. The stringent screening criteria mentioned above result in an extremely scarce number of qualified data samples. This data characteristic means that existing large-scale classification networks cannot be directly applied to the implementation examples. Instead, a special method design must be developed to address the characteristics of small samples, high heterogeneity, and strong prior constraints.

[0068] like Figure 2As shown, the collected data were divided into a treatment group receiving traditional Chinese medicine intervention and a control group with nodules growing naturally. The mass, volume, and CT value of the nodules obtained from two follow-up visits were analyzed in both groups, resulting in nine subplots showing the distribution characteristics of each indicator, including the upper margin, lower margin, median, and two quartiles. The p-value for each group was also calculated to determine if there were any significant differences.

[0069] The TCM intervention effect identification scheme for pulmonary nodules described in this embodiment faces the challenge of fully extracting image features near the nodules using only a single image input model in predicting the effectiveness of TCM classification for ground-glass opacities. Since the coordinate position of a pulmonary nodule on a CT image can pinpoint its location and provides effective contextual information, and the efficacy of TCM treatment for ground-glass opacities is closely related to the nodule's benign or malignant state, this study incorporates image features enhanced by coordinate attention mechanisms, nodule gray-scale density distribution features, and nodule quality parameter features to predict the effectiveness of TCM treatment for ground-glass opacities. Figure 3 As shown, it specifically includes the following parts: 1. Nodule Segmentation: Accurate segmentation of lung nodules is a crucial foundation of this embodiment. Currently, 3D U-Net and its variants perform well in the field of medical image segmentation. The 3D U-Net network consists of two parts: an encoder and a decoder. The encoder is responsible for extracting image features, and the decoder is responsible for restoring the size of the feature map extracted by the encoder to the original image size. This invention uses the 3D U-Net network to perform preliminary identification of CT images of lung ground-glass nodules. Subsequently, the contour of each nodule is annotated, and the coordinate points of the nodule contour are recorded. The annotation results are as follows: Figure 4 As shown, connecting the blue coordinate points outlines the nodule, while the red coordinate point is the center point of the nodule.

[0070] 2. Contextual Feature Extraction and Fusion: In the task of predicting the effectiveness of TCM classification of ground-glass nodules, relying solely on a single image input model is insufficient to fully extract image features near the nodules. Since the coordinate position of a lung nodule on a CT image can pinpoint its location and provides effective contextual information, and the efficacy of TCM treatment for ground-glass nodules is closely related to the nodule's benign or malignant state, this embodiment incorporates image features enhanced by a coordinate attention mechanism, nodule gray-scale density distribution features, and nodule quality parameter features to predict the effectiveness of TCM treatment for ground-glass nodules.

[0071] 3. Gray-scale density distribution characteristics: Existing research shows that using the gray-scale density distribution characteristics of lung nodules can significantly improve the classification performance of benign and malignant lung nodules. The gray-scale density distribution of an image refers to the relationship between pixel values ​​and surrounding neighboring points, representing the intensity and amplitude of gray-scale values ​​appearing in any local area of ​​the image. Areas with densely occurring high gray-scale values ​​in an image are high-density areas, while areas with sparsely distributed high gray-scale value pixels are low-density areas. Given that the efficacy of traditional Chinese medicine in treating pulmonary ground-glass nodules is closely related to the benign or malignant status of the nodules, and that gray-scale density distribution characteristics can effectively characterize the pathological attributes of nodules, this embodiment incorporates the gray-scale density distribution characteristics of pulmonary ground-glass nodules into the feature set for efficacy prediction. Based on the already labeled nodule contour coordinate points, a 7×7 local pixel block is extracted centered on each pulmonary ground-glass nodule contour coordinate point. The size of the lung nodules in the dataset constructed in this embodiment is 5~10mm, so the image unit cannot be too large or too small. If the value is too small, the processed result will be closer to the point processing result, thus introducing noise; if it is too large, it will introduce large errors for smaller lung nodules. K-means clustering (k=10) is performed on the gray values ​​of all pixels within this local region. Then, the Euclidean distance between the pixel at this coordinate point and the centers of each cluster is calculated to generate a gray-level density distribution feature. This feature includes both the local gray-level pattern of the coordinate point and quantifies the tissue heterogeneity of the location region. For example... Figure 5 As shown, there are three examples of nodule gray-density feature extraction. The first image on the left is the original image, with the coordinates of the nodule contour to be calculated marked. The second image on the left is a 9*9 local block of the coordinate point. The third image on the left is a schematic diagram of K-means clustering of the gray values ​​of all pixels in the local area. The fourth image on the left is the Euclidean distance between the pixel at the coordinate point and each cluster center.

[0072] 3. Image Features Enhanced by Coordinate Attention Mechanism: In the image feature extraction stage, considering that lung nodules in CT images often appear as small areas with gray-level distributions highly similar to surrounding normal tissues such as blood vessels, bronchi, and lung parenchyma, nodule features are easily submerged by background noise. This can lead to the model extracting redundant non-target features, reducing the accuracy of subsequent classification tasks. Furthermore, significant individual differences exist in lung tissue morphology and nodule location among different patients, and some nodules may be accompanied by blurred edges and uneven density, further increasing the difficulty of feature differentiation.

[0073] To address the aforementioned issues, a coordinate attention mechanism is incorporated into image feature extraction, explicitly utilizing nodule location information to enhance the feature representation of the target region. This mechanism does not rely on the network autonomously learning location correlations; instead, it directly embeds the extracted and normalized nodule center coordinates (x, y) from the labeled data into the feature extraction process. For image feature extraction, ResNet50 is used. During adaptive pooling in the height and width directions of the high-dimensional feature map output by ResNet50, the normalized coordinate information is fused with the pooled features, enabling the attention module to accurately locate the spatial position of the nodules.

[0074] The module's input consists of two parts: the image feature map output by the ResNet50 network and the center coordinates (x, y) of the lung nodule. First, adaptive average pooling is performed on the input feature map, extracting global features along the width and height dimensions respectively. Then, to eliminate the influence of feature maps of different sizes on the coordinates, the nodule coordinates are normalized to the [0, 1] interval and then incorporated into the single-dimensional pooling feature as a feature bias. Based on the width and height of the feature map, the original coordinates (x, y) are adjusted to values ​​within the [0, 1] range. The normalized coordinates are used as a global bias and superimposed on the corresponding single-dimensional pooling feature, allowing the feature to directly carry prior information about the nodule's location.

[0075] Subsequently, the single-dimensional features with biased embedding positions are subjected to dimension adaptation, concatenation, and lightweight dimensionality reduction. First, the pooling features in the height direction B×C×H×1 are converted to B×C×1×H to ensure concatenation compatibility with the features in the width direction B×C×1×W. Then, the adjusted height and width features are concatenated along the last dimension to output a fused feature with a dimension of B×C×1×(H+W). Next, a 1×1 convolutional layer is used to compress the channels of the fused feature with a default dimensionality reduction coefficient of 32. Batch normalization and ReLU activation function are used to enhance the nonlinear expression, which significantly reduces the computational complexity while retaining the core information.

[0076] Next, the single-dimensional features with embedded position bias are adapted, concatenated, and subjected to lightweight dimensionality reduction. First, the height direction features are transposed and concatenated with the width direction features to achieve concatenation compatibility. Then, the fused features are concatenated along the last dimension. After compression by 1×1 convolution channels, batch normalization and ReLU activation are combined to enhance the nonlinear expression, which significantly reduces the computational complexity while retaining the core information.

[0077] After feature dimensionality reduction, the fused feature is split into two branches, height and width, to generate attention weights for the corresponding dimensions. Based on the original height H and width W, the fused feature B×C×1×(H+W) is split into height sub-features (B×C×1×H) and width sub-features B×C×1×W. For each sub-feature, it is first restored to the original number of channels C through a 1×1 convolutional layer, and then the value is normalized to the [0,1] interval by the Sigmoid function. Finally, the dimensions are adjusted to obtain the height dimension attention weight B×C×H×1 and the width dimension attention weight B×C×1×W.

[0078] Finally, the generated height and width attention weights are multiplied element-wise with the original input feature map. The attention weight value corresponding to the nodule region approaches 1, and the feature response is significantly enhanced. The weight value of the background region approaches 0, and the feature response is effectively suppressed. The final output is a position-enhanced feature map with the same dimensions B×C×H×W as the original input feature map. This feature map significantly improves the representation ability of the lung nodule region.

[0079] In this way, the coordinate attention mechanism can generate spatial attention weights for the nodule region, which can be used to enhance the feature map region corresponding to the nodule while suppressing the feature responses of background tissue and irrelevant structures.

[0080] 4. Nodule Quality Parameter Characteristics: Based on the pre- and post-treatment data of nodule quality, volume, and CT value in the constructed lung ground-glass nodule dataset, statistical difference analysis was performed. The results showed that the p-values ​​for the changes in quality, volume, and CT value between the treatment group with traditional Chinese medicine intervention and the control group with nodule natural growth were all less than 0.05, indicating that medication may affect the dynamic changes in the volume, density, and quality of lung nodules. Considering that nodule quality is essentially a comprehensive measure of volume and density (CT value), and can more comprehensively reflect the overall biological behavior of nodules, nodule quality was included in the efficacy prediction. During feature extraction, the quality parameter was first encoded through an independent feature processing network consisting of two fully connected layers and a ReLU activation function, and then the encoded quality features were fused with other features.

[0081] Feature fusion prediction: To avoid the information limitations of a single feature, this invention adopts a simple and efficient fusion strategy based on three types of features that have been extracted: gray-scale density distribution features, nodule spatial location enhancement features, and quality features. While highlighting the dominant role of image features, it achieves multi-source information complementarity.

[0082] To address the dimensional differences among the three feature classes, standardization is achieved through convolution and global pooling: all three feature classes are unified into 256-dimensional vectors. Considering that image features directly carry the visual pathological information of nodules and contribute more to efficacy prediction, this invention constructs a lightweight attention module. The standardized gray-level density distribution feature, nodule spatial location enhancement feature, and quality quantification feature are assigned weight coefficients of 0.3, 0.6, and 0.1 respectively. Finally, the feature F_final = 0.3 × F_gray-level + 0.6 × F_location + 0.1 × F_quality is fused for subsequent efficacy prediction. Specifically, classification can be performed using a classifier. The classifier includes one or more of the following: SVM, AdaBoost, XGBoost, Random Forest, Extreme Learning Machine, and Decision Tree.

[0083] Corresponding to the above method, the present invention also provides an apparatus / system including a computer device, the computer device including a processor and a memory, the memory storing computer instructions, the processor executing the computer instructions stored in the memory, and when the computer instructions are executed by the processor, the apparatus / system performs the steps of the method as described above.

[0084] This invention also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the aforementioned edge computing server deployment method. The computer-readable storage medium can be a tangible storage medium, such as random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, floppy disks, hard disks, removable storage disks, CD-ROMs, or any other form of storage medium known in the art.

[0085] In summary, the training method, prediction method, and device for predicting the efficacy of TCM intervention in pulmonary nodules described in this invention are designed to address the TCM diagnostic and treatment needs of moderate-risk pure pulmonary nodules with a diameter of 5-10 mm, aiming to fill the technological gap in accurate prediction of efficacy before TCM treatment. In the model training phase, a first training sample set containing multiple clinical cases is first constructed. Samples are strictly selected based on inclusion criteria of stable disease course, uniform density, size matching, and single lesion. Each sample includes the patient's pulmonary nodule CT image and nodule morphological quality parameters. Senior clinicians, combining the dynamic changes of nodules in follow-up images, label the prognostic effect of the target TCM intervention plan as the first label for binary classification. All samples undergo anonymization and data quality verification to ensure data compliance and consistency.

[0086] Secondly, the CT image is automatically segmented using the pre-trained 3D U-Net lung nodule target segmentation model, which outputs the contour coordinate point set of the lung nodule and calculates the center coordinate of the nodule based on the contour coordinate. On this basis, local pixel blocks that fit the size of the nodule are extracted with each contour coordinate point as the center. Through K-means clustering and Euclidean distance calculation, gray-scale density distribution features that can quantify the heterogeneity of tissue density inside and at the edge of the nodule are generated. Subsequently, a three-branch architecture was constructed for the initial TCM intervention effect recognition model: The first branch uses ResNet50 as the backbone network to extract preliminary high-dimensional features from CT images, and explicitly embeds the normalized nodule center coordinates into the coordinate attention mechanism layer in the form of feature bias to enhance the feature response of the nodule region, suppress interference from background-irrelevant tissues, and output a position-enhanced feature image; the second branch uses an independent encoding network composed of fully connected layers and ReLU activation functions to perform nonlinear mapping on nodule quality and other trait parameters to obtain high-dimensional encoded nodule quality parameter features; the third branch directly imports pre-extracted gray-level density distribution features; after the three types of features are unified to the same dimension through convolutional projection and global pooling, feature fusion is completed according to a weighted strategy that highlights the dominant role of image features while taking into account the complementarity of multi-source information, and finally, the predicted probability value of the TCM intervention prognosis effect is output through the classification head. Finally, the initial model is trained in a supervised manner using the first training sample set, and a classification loss function is constructed based on the deviation between the predicted prognosis value and the true label. The network parameters of each layer of the model are iteratively updated through the backpropagation algorithm until the model converges to obtain the final TCM intervention effect prediction model for lung nodules.

[0087] This invention achieves multi-source information complementarity for three types of features—spatial localization, density statistics, and morphological quantification—through a multi-branch architecture. It effectively addresses the problem of features being easily submerged by the background due to the small size and similar grayscale of ground-glass nodules compared to surrounding tissues. This makes it suitable for small-sample, highly heterogeneous clinical data in TCM efficacy prediction scenarios, significantly improving the model's classification accuracy and generalization stability. The trained model can predict efficacy before patients receive TCM intervention, providing objective and quantitative scientific evidence for individualized clinical treatment plans. This helps avoid delays in subsequent diagnosis and treatment due to ineffective TCM intervention, providing reliable technical support for early non-surgical intervention of pulmonary nodules.

[0088] Those skilled in the art will understand that the exemplary components, systems, and methods described in conjunction with the embodiments disclosed herein can be implemented in hardware, software, or a combination of both. Whether implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this invention. When implemented in hardware, it can be, for example, electronic circuits, application-specific integrated circuits (ASICs), appropriate firmware, plug-ins, function cards, etc. When implemented in software, the elements of this invention are programs or code segments used to perform the desired tasks. The programs or code segments can be stored in a machine-readable medium or transmitted over a transmission medium or communication link via data signals carried in a carrier wave.

[0089] It should be clarified that the present invention is not limited to the specific configurations and processes described above and shown in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present invention is not limited to the specific steps described and shown. Those skilled in the art can make various changes, modifications, and additions, or change the order of steps, after understanding the spirit of the present invention.

[0090] In this invention, features described and / or illustrated for one embodiment may be used in the same or similar manner in one or more other embodiments, and / or combined with or in place of features of other embodiments.

[0091] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, various modifications and variations of the embodiments of the present invention are possible. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A training method for a predictive model of the effect of traditional Chinese medicine intervention on pulmonary nodules, characterized in that, The method includes the following steps: A first training sample set containing multiple samples is obtained. Each sample contains a lung nodule CT image and lung nodule phenotypic parameters of a patient sample. The prognostic effect after adopting the target TCM intervention program is marked as the first label, and the prognostic effect includes effective or ineffective. A pre-trained lung nodule target segmentation model is used to process the CT images of lung nodules in the sample to output the contour coordinates of the lung nodules and to label the center coordinates of the lung nodules; the mean gray value of pixels within a set range around the center coordinates of each lung nodule is extracted, the mean gray value of each pixel is clustered, and the distance from the center coordinates of each lung nodule to each cluster center is calculated and recorded as gray density distribution features. An initial TCM intervention effect recognition model with three branches is obtained. The first branch includes a continuous backbone network and an attention mechanism layer. The backbone network takes the CT image of the lung nodules in the sample as input and outputs a preliminary feature image. The preliminary feature image is embedded with the center coordinates of each lung nodule and then input into the attention mechanism layer to output an enhanced feature image. The second branch consists of a fully connected layer and an activation function layer. It takes the lung nodule trait quality parameter corresponding to the sample as input and outputs nodule quality parameter features. The third branch is used to import the gray-level density distribution features corresponding to the sample. The three branches are connected to a feature fusion prediction module, which includes a convolutional projection module set for each of the three branches, as well as a global pooling layer, a fusion layer, and a classification head. This module is used to unify the size of the enhanced feature image, the nodule quality parameter features, and the gray-level density distribution features, then weighted and fused them, and outputs the predicted prognostic effect value of the target TCM intervention program through the classification head. The initial TCM intervention effect recognition model is trained using the first training sample set. The loss is constructed and the model parameters are updated based on the deviation between the predicted prognostic value and the first label to obtain the TCM intervention effect prediction model for pulmonary nodules.

2. The training method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to claim 1, characterized in that, The method further includes: unifying the format and coordinate system of the lung nodule CT image, performing contrast-limited adaptive histogram averaging and denoising, performing resampling to unify pixel spacing and intensity normalization; and performing data augmentation based on data cropping, random rotation, scaling, translation and flipping. The pulmonary nodule morphological quality parameters include: geometric and morphological parameters used to label the size, volume, surface area, shape, and edge morphology of pulmonary nodules; CT image parameters used to label the mean CT value, CT value distribution, CT histogram parameters, and density classification of pulmonary nodules; and internal structural layers used to label the internal features, calcification state, and solid components of pulmonary nodules.

3. The training method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to claim 1, characterized in that, The pre-training steps of the lung nodule target segmentation model include: Obtain a second training sample set containing multiple samples, each sample containing a CT image of a lung nodule from a patient sample, and label the contour coordinates of the lung nodules as a second label; The initial 3D U-Net network is trained using the second training sample set, with the lung nodule CT image as input and the predicted lung nodule contour coordinates as output. Based on the deviation between the predicted lung nodule contour coordinates and the second label, Sorenson-Dies loss and focus loss are constructed to update the parameters of the initial 3D U-Net network to obtain the lung nodule target segmentation model.

4. The training method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to claim 3, characterized in that, The initial 3D U-Net network includes a first convolutional module, an encoding module, a decoding module, a second convolutional module, and an output layer. The encoding module includes N encoding layers, each of which includes a cascaded localization feature extraction layer and a residual module. The decoding module includes M decoding layers, each of which includes a deconvolutional layer, a transposed convolutional layer, a combination module, and a residual module. When the localization features of the CT image of lung nodules are output by the first convolution module and the encoding module, they are combined with the localization features by the deconvolution layer and the transposed convolution layer by the combination module to obtain the combined features. The combined features are then subjected to residual fusion by the residual module to obtain the output of the current decoding layer. The encoding module further includes a spatial dropout layer, which generates a random mask with a set probability according to the output feature channel dimension of the first convolutional layer. The output features of the first convolutional layer are then randomly masked using the random mask and imported into the subsequent encoding layers.

5. The training method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to claim 1, characterized in that, The method uses the K-means algorithm to cluster the mean gray values ​​of each pixel, and uses Euclidean distance to calculate the distance from the center coordinates of each lung nodule to each cluster center.

6. The training method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to claim 1, characterized in that, The backbone network adopts the ResNet50 network; In the method, the way of embedding the preliminary feature image into the corresponding center coordinates of each lung nodule includes: normalizing the center coordinates of each lung nodule in the sample to the [0,1] interval, and incorporating them into the preliminary feature image in the form of feature bias so that they directly carry the prior information of the lung nodule location, thereby obtaining a single-dimensional feature. The attention mechanism layer transforms the single-dimensional feature height feature B×C×H×1 into B×C×1×H, and concatenates it one-dimensionally with the width feature B×C×1×W to output a fused feature with a dimension of B×C×1×(H+W). A 1×1 convolution is used to compress the fused feature into channels, and batch normalization and ReLU activation function are used to enhance the non-linear expression. The dimensionality-reduced fused feature is split into height sub-features and width sub-features, and the values ​​are normalized to the [0,1] interval using a 1×1 convolution and the Sigmoid function to obtain the height dimension attention weight and the width dimension attention weight. The height dimension attention weight and the width dimension attention weight are then multiplied element-wise with the original single-dimensional feature row.

7. The training method for predicting the effect of traditional Chinese medicine intervention on pulmonary nodules according to claim 6, characterized in that, The second branch contains two fully connected layers and a ReLU activation function; The fusion layer performs weighted fusion of the enhanced feature image, the nodule quality parameter feature, and the gray-scale density distribution feature with a weight ratio of 0.6:0.1:0.3; the classification head uses a multilayer perceptron.

8. A method for predicting the prognostic effect of pulmonary nodules based on a targeted TCM intervention program, characterized in that, The method includes the following steps: Obtain CT images of lung nodules from the cases to be analyzed, and obtain the corresponding lung nodule phenotypic quality parameters; The lung nodule CT image is processed using a pre-trained lung nodule target segmentation model to output the lung nodule contour coordinates and label the lung nodule center coordinates; the mean gray value of pixels within a set range around the center coordinates of each lung nodule is extracted, the mean gray value of each pixel is clustered, and the distance from the center coordinates of each lung nodule to each cluster center is calculated and recorded as gray density distribution features. The CT image of the lung nodule, the morphological quality parameters of the lung nodule, and the gray density distribution features are input into the lung nodule TCM intervention effect prediction model obtained by the training method of the lung nodule TCM intervention effect prediction model according to any one of claims 1 to 7, and the prognostic effect identification result of the case to be analyzed with respect to the target TCM intervention plan is output.

9. A device for identifying the effect of traditional Chinese medicine intervention on pulmonary nodules, comprising a processor, a memory, and a computer program or instructions stored in the memory, characterized in that, The processor is configured to execute the computer program or instructions, and when the computer program / instructions are executed, the device implements the steps of the method as described in any one of claims 1 to 8.

10. A computer-readable storage medium having a computer program or instructions stored thereon, characterized in that, When the computer program or instructions are executed by a processor, they implement the steps of the method as described in any one of claims 1 to 8.