Liver metastasis prognosis risk prediction method and system based on pathological images
Patent Information
- Application Number
- CN202611175361.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-04
- Publication Date
- 2026-10-27
AI Technical Summary
[0003]本发明的目的在于提供一种基于病理图像的肝转移瘤预后风险预测方法及系统,旨在解决现有肝转移瘤蛋白组学分型依赖质谱技术导致的成本高、周期长、临床可及性差的问题,同时克服传统病理肉眼判读无法解码分子亚型及量化预后风险的局限
[0021]本发明通过通过构建“蛋白组金标准锚定、病理图像特征提取、Agent稀疏注意力聚合、分类与回归双任务协同输出”的完整技术链路,实现了四大效果:其一,通过获取肝转移瘤患者的H&E染色全切片图像并分割为N个图像块、经预训练病理学基础模型编码为特征向量,以常规H&E切片替代了依赖LC-MS/MS质谱的蛋白组学分型,使检测成本由数千至数万元降至传统技术的百分之一以下,检测周期由数周缩短至数小时,解决了质谱检测对新鲜样本要求苛刻、难以普及的临床痛点;其二,通过构建n个可学习Agent令牌计算交叉注意力权重以进行加权聚合,其中n远小于N,将自注意力计算复杂度由O(N²)降至O(N·n),大幅降低了全切片图像的处理时间与计算资源消耗,同时通过可微分软掩码对背景区域进行差异化抑制,解决了传统多示例学习静态注意力难以有效抑制坏死组织、正常肝实质等大量背景噪声干扰的问题;其三,通过将幻灯片级全局表示输入线性分类头输出预测亚型概率分布、以金标准标签为监督信号计算交叉熵损失并反向传播优化Agent令牌完成训练,并将待预测图像经同一特征提取网络得到的全局表示输入独立训练的生存风险回归头输出连续化风险评分,即分类头与回归头共享同一特征提取网络但在不同阶段独立训练与使用,在同一架构内实现了亚型离散分类与预后连续风险评分的双任务协同输出,避免了多模型串联带来的信息损失与计算冗余;其四,预后风险评分经外部验证队列及TCGA-COAD/READ队列验证,log-rank P=0.0003达显著生存分层,为临床病理诊断和精准治疗决策提供了兼具分型与预后评估功能的整合型智能工具。
Smart Images

Figure CN122990689A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of prognostic risk prediction technology, and in particular to a method and system for predicting the prognostic risk of liver metastases based on pathological images. Background Technology
[0002] Liver metastasis is one of the most common distant metastatic patterns in various solid tumors, including colorectal cancer, gastric cancer, and pancreatic cancer, significantly impacting patient prognosis and treatment options. In recent years, deep proteomics studies based on mass spectrometry have revealed significant molecular heterogeneity in liver metastases, defining three functionally distinct proteomic subtypes: DDR-proliferative (LMS1), mesenchymal-stromal (LMS2), and metabolically adaptive (LMS3). These subtypes exhibit fundamental differences in biological behavior, immune microenvironment characteristics, and treatment sensitivity, possessing clear clinical stratification value. However, current proteomic typing relies on liquid chromatography-tandem mass spectrometry (LC-MS / MS), which has inherent limitations such as high detection costs, long processing times, low sample throughput, and stringent requirements for fresh tissue samples, making its widespread application in routine clinical pathological diagnostic procedures difficult. On the other hand, although traditional histopathological assessment is based on clinically available formaldehyde-fixed paraffin-embedded (FFPE) specimens and hematoxylin-eosin (H&E) stained sections, pathologists cannot capture the deep morphological signals of kinesin heterogeneity by visual interpretation alone, and cannot achieve non-invasive inference of molecular subtypes and quantification of individualized prognostic risks. Summary of the Invention
[0003] The purpose of this invention is to provide a method and system for predicting the prognostic risk of liver metastases based on pathological images. This aims to solve the problems of high cost, long cycle and poor clinical accessibility caused by the reliance on mass spectrometry technology for proteomics typing of liver metastases. At the same time, it overcomes the limitations of traditional pathological visual interpretation, which cannot decode molecular subtypes and quantify prognostic risks.
[0004] In a first aspect, the present invention provides a method for predicting the prognostic risk of liver metastases based on pathological images, the method comprising:
[0005] The H&E stained whole slide images of patients with liver metastases and the gold standard label of the patient's proteomic subtype are obtained. The H&E stained whole slide images are segmented into N image blocks, and each image block is input into a pre-trained pathological basic model to encode each image block into a feature vector.
[0006] The feature vectors of all image patches are used to construct an instance feature matrix, and the instance feature matrix is mapped to the query space, key space and value space through three different learnable weights to obtain the query matrix, key matrix and value matrix.
[0007] Construct n learnable Agent tokens, calculate cross-attention weights based on the learnable Agent tokens, and use the cross-attention weights to weight and aggregate the feature vectors of each image patch to generate a slide-level global representation corresponding to the H&E stained whole slice image;
[0008] The slide-level global representation is input into the linear classification head, the predicted subtype probability distribution is output, the cross-entropy loss is calculated using the gold standard label as the supervision signal, and the learnable Agent token is optimized through backpropagation to obtain the trained model.
[0009] The H&E stained whole-slice image to be predicted is input into the trained model to obtain the target slide-level global representation. The target slide-level global representation is then input into the survival risk regression head to obtain a continuous prognostic risk score.
[0010] Secondly, the present invention provides a prognostic risk prediction system for liver metastases based on pathological images, the system comprising:
[0011] The image acquisition module is used to acquire H&E stained whole slide images of patients with liver metastases and the gold standard label of the patient's proteomic subtype. The H&E stained whole slide images are divided into N image blocks, and each image block is input into a pre-trained pathological basic model to encode each image block into a feature vector.
[0012] The mapping module is used to construct an instance feature matrix from the feature vectors of all image patches, and to map the instance feature matrix to the query space, key space and value space through three different learnable weights to obtain the query matrix, key matrix and value matrix.
[0013] The weighted aggregation module is used to construct n learnable Agent tokens, calculate cross-attention weights based on the learnable Agent tokens, and perform weighted aggregation on the feature vectors of each image block using the cross-attention weights to generate a slide-level global representation corresponding to the H&E stained whole slice image.
[0014] The model training module is used to input the slide-level global representation into the linear classification head, output the predicted subtype probability distribution, calculate the cross-entropy loss using the gold standard label as the supervision signal, and optimize the learnable Agent token through backpropagation to obtain the trained model.
[0015] The prediction module is used to input the H&E stained whole-slice image to be predicted into the trained model to obtain the target slide-level global representation. The target slide-level global representation is then input into the survival risk regression head to obtain a continuous prognostic risk score.
[0016] Thirdly, the present invention provides a storage medium that stores one or more programs that, when executed by a processor, implement the above-described method for predicting the prognostic risk of liver metastases based on pathological images.
[0017] Fourthly, the present invention provides an electronic device, the electronic device comprising a memory and a processor, wherein:
[0018] The memory is used to store computer programs;
[0019] When the processor executes the computer program stored in the memory, it implements the above-mentioned method for predicting the prognostic risk of liver metastases based on pathological images.
[0020] Compared with the prior art, the present invention has the following advantages:
[0021] This invention achieves four major effects by constructing a complete technical chain of "proteomics gold standard anchoring, pathological image feature extraction, agent sparse attention aggregation, and dual-task collaborative output of classification and regression": First, by acquiring H&E stained whole slide images of liver metastases and segmenting them into N image blocks, which are then encoded into feature vectors by a pre-trained pathological model, conventional H&E slides replace proteomics typing relying on LC-MS / MS mass spectrometry. This reduces the detection cost from thousands to tens of thousands of yuan to less than one percent of traditional technologies, and shortens the detection cycle from weeks to hours, solving the clinical pain points of mass spectrometry detection, which has stringent requirements for fresh samples and is difficult to popularize. Second, by constructing n learnable agent tokens to calculate cross-attention weights for weighted aggregation, where n is much smaller than N, the computational complexity of self-attention is reduced from O(N²) to O(N·n), significantly reducing the processing time and computational resource consumption of whole slide images. Simultaneously, by using differentiable soft masks to differentially suppress background regions, the problem of traditional multi-instance learning static attention being unable to effectively suppress a large amount of background noise interference such as necrotic tissue and normal liver parenchyma is solved. Thirdly, by inputting the slide-level global representation into the linear classification head to output the predicted subtype probability distribution, calculating the cross-entropy loss with the gold standard label as the supervision signal, and backpropagating to optimize the Agent token to complete the training, and inputting the global representation obtained by the image to be predicted through the same feature extraction network into the independently trained survival risk regression head to output a continuous risk score, that is, the classification head and regression head share the same feature extraction network but are trained and used independently at different stages, realizing the dual-task collaborative output of discrete subtype classification and continuous prognostic risk scoring within the same architecture, avoiding information loss and computational redundancy caused by multi-model concatenation. Fourthly, the prognostic risk score is validated by an external validation queue and the TCGA-COAD / READ queue, achieving significant survival stratification with log-rank P=0.0003, providing an integrated intelligent tool with both subtyping and prognostic assessment functions for clinical pathological diagnosis and precision treatment decision-making. Attached Figure Description
[0022] Figure 1 This is a flowchart of a method for predicting the prognostic risk of liver metastases based on pathological images, as proposed in an embodiment of the present invention.
[0023] Figure 2 This is a schematic diagram of the structure of a liver metastasis prognostic risk prediction system based on pathological images, as proposed in an embodiment of the present invention.
[0024] The following detailed description, in conjunction with the accompanying drawings, will further illustrate the present invention. Detailed Implementation
[0025] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention. Unless otherwise defined, the technical or scientific terms used herein should have the ordinary meaning understood by those skilled in the art. The terms "comprising" and similar expressions used herein mean that the element or object preceding the word covers the element or object listed after the word and its equivalents, but does not exclude other elements or objects.
[0026] like Figure 1 As shown, an embodiment of the present invention proposes a method for predicting the prognostic risk of liver metastases based on pathological images. The method includes steps S101 to S105, wherein:
[0027] Step S101: Obtain the H&E stained whole slide image of the patient with liver metastases and the gold standard label of the patient's proteome subtype. Divide the H&E stained whole slide image into N image blocks and input each image block into a pre-trained pathological basic model to encode each image block into a feature vector.
[0028] It should be noted that this step first acquires H&E-stained whole-slice images of patients with liver metastases, and simultaneously obtains the gold standard label of the corresponding proteomic subtype as a supervision signal for subsequent model training. Then, the whole-slice images are regularly segmented into N fixed-size image patches. Each image patch serves as an independent basic analysis unit, and is input into the pre-trained pathology model as a fixed-length feature vector. This transforms the high-dimensional, unstructured pixel image into a structured numerical vector representation, providing a quantitative basis for subsequent attention calculation and aggregation.
[0029] Specifically, the whole-section images stained with H&E were segmented into tissue regions to obtain several 256×256 pixel image patches, with an equivalent magnification of 20×(0.42μm / pixel). Each image patch was encoded into a 1536-dimensional feature vector by the pre-trained pathology model UNIv2 (ViT-Huge architecture, pre-trained based on over 350,000 diverse H&E and IHC slides). The encoding process is represented as ,in, This represents the k-th image patch. This indicates a UNIv2 encoder.
[0030] Subsequently, LC-MS / MS proteomic quantitative analysis was performed on FFPE samples of liver metastases from the same patient. Differentially expressed proteins were screened for unsupervised clustering, and three proteomic subtypes were defined. Immunohistochemical staining was performed using PRKDC, COL14A1, and FABP5 antibodies. An H-score > 50 was used as the positive threshold. A pathological gold standard labeling system for proteomic subtypes was established to determine the subtype category.
[0031] Specifically, the three proteomic subtypes include: LMS1 (DDR-proliferative type): characterized by high expression of PRKDC, FOXK1, and RAD21, enriched with DNA damage response and proliferation pathways; LMS2 (mesenchymal-matrix type): characterized by high expression of COL14A1 and PKN1, enriched with extracellular matrix remodeling and PI3K-AKT signaling; and LMS3 (metabolic adaptation type): characterized by high expression of FABP3 / 5 and RXRA, enriched with lipid metabolism reprogramming.
[0032] Step S102: Construct an instance feature matrix from the feature vectors of all image blocks, and map the instance feature matrix to the query space, key space and value space through three different learnable weights to obtain the query matrix, key matrix and value matrix;
[0033] It should be noted that the mapping is specifically based on the following formula:
[0034] ;
[0035] in, These are the query matrix, key matrix, and value matrix, respectively. All are learnable weights. For instance features.
[0036] Step S103: Construct n learnable Agent tokens, calculate cross-attention weights based on the learnable Agent tokens, and use the cross-attention weights to weight and aggregate the feature vectors of each image block to generate a slide-level global representation corresponding to the H&E stained whole slice image;
[0037] It should be noted that in this step, a learnable Agent token with n much smaller than N is first introduced. Where h is the number of attention heads, d is the single-head attention dimension, n is the number of agent tokens in the science department, h is the number of heads in the multi-head attention module, and D is the total hidden dimension of the model;
[0038] Agent tokens can be learned through residual connection updates:
[0039] ;
[0040] in, For the updated learnable Agent token, Initialized with Gaussian noise of zero mean and 0.1 standard deviation, i.e. ;
[0041] Compute Agent-Mediated Query-Key Projection:
[0042] ;
[0043] in, For query purposes, Let T be the key vector, and T be the transpose.
[0044] Calculate the cross-attention weights using the following formula:
[0045] ;
[0046] in, For cross-attention weights, for function.
[0047] In addition, in some embodiments, a soft mask denoising mechanism is introduced to suppress noise activation, as follows:
[0048] Calculate the Agent aggregation value using the following formula:
[0049] ;
[0050] in, This represents softmax normalization along the bond dimension. Aggregated value for Agent;
[0051] Construct a differentiable soft mask:
[0052] ;
[0053] in, It is a differentiable soft mask. Through the Obtained by linear projection, To control the transition sharpness, For trainable parameters, For the operation of finding the mean, An adaptive threshold;
[0054] The denoising features are calculated using the following formula:
[0055] ;
[0056] in, For application The denoised baseline generated by the lightweight multilayer perceptron. This represents element-wise multiplication. For denoising features;
[0057] The denoised features are weighted and output using the cross-attention weights, and then aggregated by global averaging to generate a slide-level global representation.
[0058] Step S104: Input the slide-level global representation into the linear classification head, output the predicted subtype probability distribution, calculate the cross-entropy loss using the gold standard label as the supervision signal, and optimize the learnable Agent token through backpropagation to obtain the trained model;
[0059] It should be noted that in this step, slide-level representations are generated through global average aggregation. The input linear prediction head is converted into class log odds, and then normalized by softmax to obtain the three-class probability distribution. The subtype corresponding to the highest posterior probability is taken as the final prediction result. Model training uses cross-entropy loss. ,in, For subtype number, The i-th element is the one-hot encoded representation of the real label. Let be the probability of the i-th class predicted by the model. The optimizer is Adam, with an initial learning rate of 2×10^-4, a weight decay coefficient of 1×10^-5, and a training period of 25 epochs. The batch size is 1 WSI. The learning rate scheduling strategy is to decay by 0.9 every 3 epochs after 2 warm-up rounds, and the early stopping criterion is that the macro average ROC-AUC of the validation set does not improve for 5 consecutive epochs.
[0060] Step S105: Input the H&E stained whole-slice image to be predicted into the trained model to obtain the target slide-level global representation. Input the target slide-level global representation into the survival risk regression head to obtain a continuous prognostic risk score.
[0061] In some embodiments, the linear classifier head is a linear classification layer that outputs a three-class probability distribution normalized by softmax; an early stopping strategy is adopted during training to verify that the set macro average ROC-AUC has not improved for 5 consecutive rounds as the termination condition.
[0062] Furthermore, in some embodiments, the parameters of the survival risk regression head are trained using survival data as a supervision signal. The survival risk regression head is a linear regression layer that directly outputs continuous values as a prognostic risk score.
[0063] Furthermore, under 10-fold cross-validation, the model achieved macro-average AUROCs of 0.926, 0.989, and 0.950 for LMS1, LMS2, and LMS3, respectively, with prediction accuracies of 83.8%, 92.9%, and 86.0%. The confusion matrix showed minimal cross-subtype misclassification. Details are as follows:
[0064] The first step involved back-projecting the attention weights of AMA-MIL onto the original WSI space to generate a heatmap of high-attention regions. Pathological review confirmed the morphological characteristics of the three subtypes: LMS1 corresponds to a high-density tumor parenchyma region with significant nuclear atypia and dense mitotic figures; LMS2 corresponds to a connective tissue proliferation region with abundant collagen deposition and a low tumor-to-stromal ratio; and LMS3 corresponds to a metabolic adaptation region with cytoplasmic vacuolation and eosinophilic changes. Heatmaps of boundary cases showed the spatial coexistence of different subtype characteristics within the same WSI, reflecting intratumoral clonal heterogeneity.
[0065] The second step involved applying the CellViT basic model to the top 20 image patches with high attention levels for nuclear segmentation and cell type classification, identifying four populations: tumor cells, inflammatory cells, connective tissue cells, and dead cells. Multidimensional morphometric features were extracted, including cell density, nuclear area, nuclear perimeter, roundness, aspect ratio, boundary irregularity, gray-level co-occurrence matrix texture features, and nuclear size variation coefficient. Statistical comparisons showed that the tumor cell abundance in LMS1 was significantly higher than that in LMS2 and LMS3 (P<0.001), with increased nuclear non-convexity (P=0.023), edge features (P=0.003), and texture complexity (P=0.004). The proportion of connective tissue cells in LMS2 showed an increasing trend (P=0.053), while the abundance of inflammatory cells in LMS3 showed no significant difference (P=0.75). Five normalized features were used to construct a radar chart, forming a subtype-specific morphometric fingerprint: LMS1 was dominated by tumor cell abundance and nuclear irregularity, LMS2 was characterized by the stroma / connective tissue axis, and LMS3 was an intermediate type without extreme polarization.
[0066] The third step involved designing three multiplex immunofluorescence antibody panels for in situ validation. Panel 1 (DDR-immunoassay) included nuclear staining for PRKDC, CD3, CD4, CD8, PD-L1, and DAPI; Panel 2 (stromal-matrix) included CD86, CD163, COL1A1, α-SMA, CD31, and DAPI; and Panel 3 (metabolic adaptation) included FABP5, CD36, FASN, and DAPI. An iterative tyramine signal amplification strategy was employed, and staining was performed on a fully automated immunohistochemical staining system (Krast 600). Whole-section scans were performed using a 20× objective lens, and tissue autofluorescence was removed using a spectral separation algorithm. Quantitative analysis confirmed that the density of PRKDC-positive tumor cells was increased in the LMS1 high attention area (P<0.05) and CD4-positive T cells were enriched (P<0.01); the LMS2 attention area had abundant extracellular matrix COL14A1 and co-localized with α-SMA-positive cancer-associated fibroblasts, accompanied by increased infiltration of CD163-positive macrophages (P<0.05); the LMS3 attention area had co-expression of lipid metabolism markers FABP5, CD36, and FASN, which precisely corresponded to cytoplasmic vacuolation morphology.
[0067] The fourth step involves extending the AMA-MIL architecture to the Siamese-AMA-MIL prognostic framework, retaining the sparse attention mechanism, and transforming the output layer into a survival risk regression head to predict continuous risk scores. Risk scores showed significant differences between LMS1 and LMS3 (Kruskal-Wallis H=8.4586, P=0.0146), with high scores concentrated in high-risk subtypes. In the external validation cohort (n=124), the AI-predicted labels for the LMS1 and non-LMS1 (LMS2+LMS3) binary groups showed a survival separation trend (log-rank P=0.0919); in the TCGA-COAD / READ cohort (n=618), the same binary group achieved significant survival stratification (log-rank P=0.0003). Interaction analysis of subtypes and treatment strategies suggests that LMS1 and LMS3 patients benefit from neoadjuvant chemotherapy alone, with no synergistic effect observed when combined with bevacizumab; while LMS2 patients tend to benefit from combination therapy, providing a hypothesis for precision treatment decisions.
[0068] In summary, this invention achieves four major effects by constructing a complete technical chain of "proteomics gold standard anchoring, pathological image feature extraction, agent sparse attention aggregation, and dual-task collaborative output of classification and regression": First, by acquiring H&E stained whole slide images of liver metastases and segmenting them into N image blocks, which are then encoded as feature vectors by a pre-trained pathological model, conventional H&E slides replace proteomics typing relying on LC-MS / MS mass spectrometry. This reduces the detection cost from thousands to tens of thousands of yuan to less than one percent of traditional technologies, and shortens the detection cycle from weeks to hours, solving the clinical pain points of mass spectrometry detection, which has stringent requirements for fresh samples and is difficult to popularize. Second, by constructing n learnable agent tokens to calculate cross-attention weights for weighted aggregation, where n is much smaller than N, the computational complexity of self-attention is reduced from O(N²) to O(N·n), significantly reducing the processing time and computational resource consumption of whole slide images. First, it addresses the issue of traditional multi-instance learning static attention's inability to effectively suppress background noise interference from necrotic tissue and normal liver parenchyma by using differentiable soft masks to differentially suppress background regions. Second, it completes training by inputting a slide-level global representation into a linear classification head to output the predicted subtype probability distribution, calculating cross-entropy loss using the gold standard label as a supervision signal, and backpropagating to optimize the Agent token. Third, it inputs the global representation obtained from the image to be predicted through the same feature extraction network into an independently trained survival risk regression head to output a continuous risk score. That is, the classification head and regression head share the same feature extraction network but are trained and used independently at different stages, achieving dual-task collaborative output of discrete subtype classification and continuous prognostic risk scoring within the same architecture, avoiding information loss and computational redundancy caused by multi-model concatenation. Fourth, the prognostic risk score has been validated by an external validation queue and the TCGA-COAD / READ queue, achieving significant survival stratification with log-rank P=0.0003, providing an integrated intelligent tool with both subtyping and prognostic assessment functions for clinical pathological diagnosis and precision treatment decision-making.
[0069] like Figure 2 As shown, one embodiment of the present invention proposes a prognostic risk prediction system for liver metastases based on pathological images, the system comprising:
[0070] Image acquisition module 10 is used to acquire H&E stained whole slide images of patients with liver metastases and the gold standard label of the patient's proteome subtype. The H&E stained whole slide images are divided into N image blocks, and each image block is input into a pre-trained pathological basic model to encode each image block into a feature vector.
[0071] Mapping module 20 is used to construct an instance feature matrix from the feature vectors of all image blocks, and to map the instance feature matrix to the query space, key space and value space through three different learnable weights to obtain the query matrix, key matrix and value matrix;
[0072] The weighted aggregation module 30 is used to construct n learnable Agent tokens, calculate cross-attention weights based on the learnable Agent tokens, and perform weighted aggregation on the feature vectors of each image block using the cross-attention weights to generate a slide-level global representation corresponding to the H&E stained whole slice image;
[0073] Model training module 40 is used to input the slide-level global representation into the linear classification head, output the predicted subtype probability distribution, calculate the cross-entropy loss with the gold standard label as the supervision signal, and optimize the learnable Agent token through backpropagation to obtain the trained model.
[0074] The prediction module 50 is used to input the H&E stained whole-slice image to be predicted into the trained model to obtain the target slide-level global representation. The target slide-level global representation is then input into the survival risk regression head to obtain a continuous prognostic risk score.
[0075] In another aspect, the present invention also proposes a storage medium on which one or more programs are stored, which, when executed by a processor, implement the above-described method for predicting the prognostic risk of liver metastases based on pathological images.
[0076] In another aspect, the present invention also proposes an electronic device, including a memory and a processor, wherein the memory is used to store a computer program, and the processor is used to execute the computer program stored in the memory to realize the above-mentioned method for predicting the prognostic risk of liver metastases based on pathological images.
[0077] Those skilled in the art will understand that the logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (such as a computer-based system, a processor-included system, or other system that can fetch and execute instructions from, an instruction execution system, apparatus, or device). For the purposes of this specification, "computer-readable medium" can mean any means that can contain stored, communicated, propagated, or transmitted programs for use by, or in conjunction with, an instruction execution system, apparatus, or device.
[0078] More specific examples of computer-readable media (a non-exhaustive list) include: electrical connections (electronic devices) having one or more wires, portable computer disk drives (magnetic devices), random access memory (RAM), read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disc read-only memory (CDROM). Furthermore, computer-readable media can even be paper or other suitable media on which the program can be printed, because the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in computer memory.
[0079] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented using software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.
[0080] While embodiments of the present invention have been described in detail above, it will be apparent to those skilled in the art that various modifications and variations can be made to these embodiments. However, it should be understood that such modifications and variations fall within the scope and spirit of the invention as set forth in the claims. Furthermore, the invention described herein may have other embodiments and can be implemented or carried out in various ways.
Claims
1. A method for predicting the prognostic risk of liver metastases based on pathological images, characterized in that, The method includes: The H&E stained whole slide images of patients with liver metastases and the gold standard label of the patient's proteomic subtype are obtained. The H&E stained whole slide images are segmented into N image blocks, and each image block is input into a pre-trained pathological basic model to encode each image block into a feature vector. The feature vectors of all image patches are used to construct an instance feature matrix, and the instance feature matrix is mapped to the query space, key space and value space through three different learnable weights to obtain the query matrix, key matrix and value matrix. Construct n learnable Agent tokens, calculate cross-attention weights based on the learnable Agent tokens, and use the cross-attention weights to weight and aggregate the feature vectors of each image patch to generate a slide-level global representation corresponding to the H&E stained whole slice image; The slide-level global representation is input into the linear classification head, the predicted subtype probability distribution is output, the cross-entropy loss is calculated using the gold standard label as the supervision signal, and the learnable Agent token is optimized through backpropagation to obtain the trained model. The H&E stained whole-slice image to be predicted is input into the trained model to obtain the target slide-level global representation. The target slide-level global representation is then input into the survival risk regression head to obtain a continuous prognostic risk score.
2. The method for predicting the prognostic risk of liver metastases based on pathological images according to claim 1, characterized in that, The steps for obtaining H&E-stained whole-section images of patients with liver metastases and the gold standard label of the patient's proteomic subtype include: LC-MS / MS proteomic quantitative analysis was performed on FFPE samples of liver metastases from the same patient. Differentially expressed proteins were screened and unsupervised clustering was performed to define three proteomic subtypes. Immunohistochemical staining was performed using PRKDC, COL14A1, and FABP5 antibodies, and the subtype category was determined by H-score.
3. The method for predicting the prognostic risk of liver metastases based on pathological images according to claim 1, characterized in that, The step of constructing an instance feature matrix from the feature vectors of all image patches, and mapping the instance feature matrix to the query space, key space, and value space through three different learnable weights to obtain the query matrix, key matrix, and value matrix includes: Mapping is performed according to the following formula: ; in, These are the query matrix, key matrix, and value matrix, respectively. All are learnable weights. For instance features.
4. The method for predicting the prognostic risk of liver metastases based on pathological images according to claim 3, characterized in that, The step of constructing n learnable Agent tokens and calculating cross-attention weights based on the learnable Agent tokens includes: Introducing learnable Agent tokens where n is much smaller than N Where h is the number of attention heads, d is the single-head attention dimension, n is the number of agent tokens in the science department, h is the number of heads in the multi-head attention module, and D is the total hidden dimension of the model; Agent tokens can be learned through residual connection updates: ; in, For the updated learnable Agent token, Initialize to zero mean; Compute Agent-Mediated Query-Key Projection: ; in, For query purposes, Let T be the key vector, and T be the transpose. Calculate the cross-attention weights using the following formula: ; in, For cross-attention weights, for function.
5. The method for predicting the prognostic risk of liver metastases based on pathological images according to claim 4, characterized in that, The step of weighted aggregation of the feature vectors of each image patch using the cross-attention weights to generate a slide-level global representation corresponding to the H&E stained whole-slice image includes: Calculate the Agent aggregation value using the following formula: ; in, This represents softmax normalization along the bond dimension. For Agent aggregation value; Construct a differentiable soft mask: ; in, It is a differentiable soft mask. Through the Obtained by linear projection, To control the transition sharpness, For trainable parameters, For the operation of finding the mean, An adaptive threshold; The denoising features are calculated using the following formula: ; in, For application The denoised baseline generated by the lightweight multilayer perceptron. This represents element-wise multiplication. For denoising features; The denoised features are weighted and output using the cross-attention weights, and then aggregated by global averaging to generate a slide-level global representation.
6. The method for predicting the prognostic risk of liver metastases based on pathological images according to claim 1, characterized in that, The linear classification head is a linear classification layer that outputs a three-class probability distribution normalized by softmax. An early stop strategy was adopted during training to verify that the average ROC-AUC of the macro dataset did not improve for 5 consecutive rounds as the termination condition.
7. The method for predicting the prognostic risk of liver metastases based on pathological images according to claim 1, characterized in that, The parameters of the survival risk regression head are trained using survival data as a supervision signal. The survival risk regression head is a linear regression layer that directly outputs continuous values as a prognostic risk score.
8. A prognostic risk prediction system for liver metastases based on pathological images, characterized in that, The system includes: The image acquisition module is used to acquire H&E stained whole slide images of patients with liver metastases and the gold standard label of the patient's proteomic subtype. The H&E stained whole slide images are divided into N image blocks, and each image block is input into a pre-trained pathological basic model to encode each image block into a feature vector. The mapping module is used to construct an instance feature matrix from the feature vectors of all image patches, and to map the instance feature matrix to the query space, key space and value space through three different learnable weights to obtain the query matrix, key matrix and value matrix. The weighted aggregation module is used to construct n learnable Agent tokens, calculate cross-attention weights based on the learnable Agent tokens, and perform weighted aggregation on the feature vectors of each image block using the cross-attention weights to generate a slide-level global representation corresponding to the H&E stained whole slice image. The model training module is used to input the slide-level global representation into the linear classification head, output the predicted subtype probability distribution, calculate the cross-entropy loss using the gold standard label as the supervision signal, and optimize the learnable Agent token through backpropagation to obtain the trained model. The prediction module is used to input the H&E stained whole-slice image to be predicted into the trained model to obtain the target slide-level global representation. The target slide-level global representation is then input into the survival risk regression head to obtain a continuous prognostic risk score.
9. A storage medium, characterized in that, The storage medium stores one or more programs that, when executed by a processor, implement the method for predicting the prognostic risk of liver metastases based on pathological images as described in any one of claims 1-7.
10. An electronic device, characterized in that, The electronic device includes a memory and a processor, wherein: The memory is used to store computer programs; When the processor executes the computer program stored in the memory, it implements the method for predicting the prognostic risk of liver metastases based on pathological images as described in any one of claims 1-7.
