Method, device, equipment and storage medium for grading gastric mucosa intestinal epithelial metaplasia

By integrating local and global features through a pre-defined dual-branch classification model, the interpretability problem of AI models in the grading of gastric mucosal intestinal metaplasia was solved, achieving high-precision glandular region identification and quantitative grading, thus improving the objectivity and reliability of diagnosis.

CN120823601BActive Publication Date: 2025-11-18SHENZHEN SHENGQIANG TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511326419.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-09-17
Publication Date
2025-11-18
Estimated Expiration
2045-09-17

AI Technical Summary

Technical Problem

Existing AI models lack interpretability when assisting pathologists in grading gastric mucosal intestinal metaplasia. They struggle to simultaneously extract detailed local features and accurately grasp global information, resulting in an inability to provide intuitive and interpretable quantitative results of pathological changes.

Method used

A pre-defined dual-branch classification model is adopted, including a first branch based on a residual network and a second branch based on a Transformer network. Combined with a fusion module and a decoder, local and global features are extracted and fused to output gland category probabilities. The probabilities are then quantified and classified using the Sydney system classification threshold.

Benefits of technology

It improves the accuracy of glandular region identification, enhances the model's adaptability to complex pathological images, achieves objective and quantitative grading of intestinal metaplasia, reduces subjective differences in manual assessment, and improves the consistency and reliability of diagnosis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120823601B_ABST
    Figure CN120823601B_ABST
Patent Text Reader

Abstract

The application discloses a gastric mucosa intestinal epithelial metaplasia grading method, device, equipment and storage medium, and the method comprises the steps of acquiring a current full slice image, pre-processing, and obtaining a slice image block; inputting the slice image block into a preset double-branch classification model to obtain an adenoid classification result, wherein the preset double-branch classification model comprises a first branch constructed based on a residual network, a second branch constructed based on a Transformer network, a fusion module and a decoder; determining a current intestinal metaplasia adenoid proportion value based on the adenoid classification result; comparing the current intestinal metaplasia adenoid proportion value with a preset Sydney system grading threshold value to determine a Sydney system grading result. The application extracts and fuses local features and global features, improves the recognition accuracy of the adenoid region, makes the classification of intestinal metaplasia adenoids and normal adenoids more accurate, and combines the intestinal metaplasia adenoid proportion with the Sydney system grading standard, so that objective and quantitative intestinal epithelial metaplasia grading is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of medical image analysis technology, and in particular to a method, apparatus, device and storage medium for grading gastric mucosal intestinal metaplasia. Background Technology

[0002] Intestinal metaplasia (IM), often shortened to "intestinal metaplasia," is an abnormal change in the gastric mucosa characterized by the gradual replacement of gastric mucosal epithelial cells with intestinal-like epithelial cells. As a key precancerous lesion, IM plays a significant role in the development of gastric cancer. Currently, the detection of IM primarily relies on the analysis of whole-slice images (WSI) from gastric mucosal biopsies. Pathologists visually assess the proportion of normal glands and metaplastic glands to determine the Sigmund system grade, providing a basis for patient diagnosis and clinical trials.

[0003] With the continuous advancement of artificial intelligence (AI) technology, AI models have demonstrated great potential in assisting pathologists in grading intramyopathic lesions (IMs). However, existing AI models (such as GasMIL) still have many limitations in application: on the one hand, most of these models can only classify IMs and fail to effectively establish a mapping relationship between pathological morphology and quantitative standards; on the other hand, when segmenting glandular structures, existing AI models struggle to simultaneously achieve both precise extraction of local features and accurate grasp of global information, resulting in their inability to provide sufficiently intuitive and interpretable quantitative results of pathological changes, thus limiting their application value and scope of promotion in clinical practice. Summary of the Invention

[0004] The main objective of this application is to provide a method, apparatus, device, and storage medium for classifying gastric mucosal intestinal metaplasia, aiming to solve the technical problem that existing AI-model-assisted manual IM classification methods lack interpretability.

[0005] To achieve the above objectives, this application proposes a method for grading gastric mucosal intestinal metaplasia, the method comprising:

[0006] Obtain the current full slice image and preprocess the current full slice image to obtain slice image blocks;

[0007] The sliced ​​image patch is input into a preset dual-branch classification model to obtain gland classification results. The preset dual-branch classification model includes: a first branch constructed based on a residual network, a second branch constructed based on a Transformer network, a fusion module, and a decoder. The first branch is used to extract local features from the sliced ​​image patch, the second branch is used to extract global features from the sliced ​​image patch, the fusion module is used to perform feature fusion, and the decoder is used to output gland category probabilities based on the fused features.

[0008] Based on the gland classification results, determine the corresponding pixel values ​​of the intestinal metaplastic gland region and the normal gland region in the current whole slice image, and determine the current proportion of intestinal metaplastic glands based on the pixel values;

[0009] The current percentage of intestinal metaplastic glands is compared with a preset Sydney system grading threshold to determine the Sydney system grading result corresponding to the current whole slice image.

[0010] In one embodiment, the step of acquiring the current full-slice image and preprocessing the current full-slice image to obtain slice image blocks includes:

[0011] The current full-slice image is obtained, and the current full-slice image is downsampled to obtain a low-resolution overview image;

[0012] The low-resolution overview image is segmented using an automatic threshold segmentation algorithm to obtain an overview image containing the tissue segmentation mask.

[0013] Based on the staining of the current full-slice image, channel enhancement is performed on the overview image containing the tissue segmentation mask, and a preset morphological algorithm is used to mark the glandular region in the channel-enhanced overview image to obtain an overview image containing the glandular region segmentation mask.

[0014] Align the overview image containing the gland region segmentation mask with the current full slice image, and cut the current full slice image based on the gland region segmentation mask to obtain slice image blocks.

[0015] In one embodiment, the step of using a preset morphological algorithm to label glandular regions in the channel-enhanced overview image to obtain an overview image containing a glandular region segmentation mask includes:

[0016] Select a preset structural element and perform a top-hat transformation operation on the overview map of the channel enhancement to obtain an overview map of glandular cavity enhancement.

[0017] The automatic threshold segmentation algorithm is used to segment the overview map of the enhanced glandular cavities to determine candidate regions of the glandular cavities;

[0018] Using the candidate regions of the glandular cavities as markers, the watershed algorithm is used to segment the enhanced overview map of the glandular cavities to obtain an overview map with glandular region markers.

[0019] The overview image with gland region markers is segmented using morphological post-processing to obtain an overview image containing a gland region segmentation mask.

[0020] In one embodiment, the step of inputting the sliced ​​image patch into a preset two-branch classification model to obtain gland classification results includes:

[0021] Local features are extracted from the sliced ​​image block by the first branch to obtain local features, which include: gland edge features, cell texture features and glandular duct structure features;

[0022] The second branch performs global feature extraction on the sliced ​​image block to obtain global features, which include: horizontal gland distribution features and vertical gland topological features;

[0023] The fusion module determines the current spatial weights and performs weighted fusion of the local features and the global features based on the current spatial weights to obtain fused features.

[0024] The decoder maps the fused features to determine the gland category probability corresponding to the sliced ​​image block;

[0025] Based on the gland category probability corresponding to the sliced ​​image block, a mask corresponding to different gland categories is generated in the current full slice image.

[0026] In one embodiment, the step of determining the current spatial weights and performing weighted fusion of the local features and the global features based on the current spatial weights to obtain fused features includes:

[0027] The local features and the global features are concatenated to generate a joint feature vector;

[0028] The joint feature vector is nonlinearly transformed using a unit convolutional layer to obtain scalar weight values, and the scalar weight values ​​are normalized using a Sigmoid activation function to obtain the current spatial weights, which include local feature weights and global feature weights.

[0029] The local features and the global features are weighted and fused according to the local feature weights and the global feature weights to obtain fused features.

[0030] In one embodiment, the step of comparing the current proportion of intestinal metaplasia glands with a preset Sydney system grading threshold to determine the Sydney system grading result corresponding to the current whole-slice image includes:

[0031] Based on the Sydney system classification, several Sydney levels are determined, and the corresponding threshold for the proportion of intestinal metaplasia area is determined according to each Sydney level.

[0032] The current percentage of intestinal metaplastic glands is compared with the threshold values ​​for the percentage of each intestinal metaplastic area to obtain the comparison results;

[0033] The Sydney system level corresponding to the current full-slice image is determined based on the comparison results.

[0034] In one embodiment, the step of determining the Sydney system level corresponding to the current full-slice image based on the comparison result includes:

[0035] Determine the threshold difference between the current percentage of intestinal metaplastic glands and the threshold values ​​for the percentage of each intestinal metaplastic area;

[0036] When the threshold difference meets the preset critical value range, the current full slice image is determined to be a critical sample, and a manual review prompt is triggered based on the critical sample so that a professional physician can determine the Sydney system level corresponding to the current full slice image.

[0037] When the threshold difference does not meet the preset critical value range, the Sydney system level corresponding to the current full slice image is determined based on the comparison result.

[0038] Furthermore, to achieve the above objectives, this application also proposes a grading device for gastric mucosal intestinal metaplasia, the device comprising:

[0039] The image preprocessing module is used to acquire the current full-slice image and preprocess the current full-slice image to obtain slice image blocks;

[0040] The model classification module is used to input the sliced ​​image patch into a preset dual-branch classification model to obtain gland classification results. The preset dual-branch classification model includes: a first branch constructed based on a residual network, a second branch constructed based on a Transformer network, a fusion module, and a decoder. The first branch is used to extract local features from the sliced ​​image patch, the second branch is used to extract global features from the sliced ​​image patch, the fusion module is used to perform feature fusion, and the decoder is used to output gland category probabilities based on the fused features.

[0041] The hierarchical mapping module is used to determine the corresponding pixel values ​​of the intestinal metaplastic gland region and the normal gland region in the current whole slice image based on the gland classification results, and to determine the current proportion of intestinal metaplastic glands based on the pixel values.

[0042] The hierarchical mapping module is also used to compare the current proportion of intestinal metaplastic glands with a preset Sydney system hierarchical threshold to determine the Sydney system hierarchical result corresponding to the current whole slice image.

[0043] In addition, to achieve the above objectives, this application also proposes a gastric mucosal intestinal metaplasia grading device, the device comprising: a memory, a processor, and a gastric mucosal intestinal metaplasia grading program stored in the memory and executable on the processor, the gastric mucosal intestinal metaplasia grading program being configured to implement the steps of the gastric mucosal intestinal metaplasia grading method as described above.

[0044] In addition, to achieve the above objectives, this application also proposes a storage medium, which is a computer-readable storage medium, storing a gastric mucosa intestinal metaplasia grading program, wherein when the gastric mucosa intestinal metaplasia grading program is executed by a processor, it implements the steps of the gastric mucosa intestinal metaplasia grading method as described above.

[0045] This application discloses a method for grading intestinal metaplasia of gastric mucosa, comprising: acquiring a current full-slice image and preprocessing the current full-slice image to obtain slice image blocks; inputting the slice image blocks into a preset two-branch classification model to obtain gland classification results, wherein the preset two-branch classification model includes: a first branch constructed based on a residual network, a second branch constructed based on a Transformer network, a fusion module, and a decoder, wherein the first branch is used to extract local features from the slice image blocks, the second branch is used to extract global features from the slice image blocks, the fusion module is used to perform feature fusion, and the decoder is used to output gland category probabilities based on the fused features; determining the corresponding pixel values ​​of intestinal metaplastic gland regions and normal gland regions in the current full-slice image based on the gland classification results, and determining the current proportion of intestinal metaplastic glands based on the pixel values; comparing the current proportion of intestinal metaplastic glands with a preset Sydney system grading threshold to determine the Sydney system grading result corresponding to the current full-slice image.

[0046] This application improves the accuracy of glandular region identification by fusing local and global features, thus enabling more accurate classification of intestinal metaplastic glands and normal glands. The collaboration of the dual-branch model not only enhances the comprehensiveness of feature extraction but also strengthens the model's adaptability to complex pathological images. Furthermore, this application directly combines the proportion of intestinal metaplastic glands with the Sydney grading system, achieving objective and quantitative grading of intestinal metaplasia. This effectively reduces subjective differences in manual assessment, improves diagnostic consistency and reliability, and provides a more precise basis for clinical decision-making. Attached Figure Description

[0047] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0048] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0049] Figure 1 This is a flowchart illustrating the first embodiment of the grading method for gastric mucosal intestinal metaplasia of this application;

[0050] Figure 2 A schematic diagram of the model architecture for the pre-defined dual-branch classification model in this application;

[0051] Figure 3 This is a flowchart illustrating the second embodiment of the grading method for gastric mucosal intestinal metaplasia of this application;

[0052] Figure 4 This is a flowchart illustrating the third embodiment of the grading method for gastric mucosal intestinal metaplasia of this application;

[0053] Figure 5 This is a schematic diagram of the module structure of the first embodiment of the gastric mucosal intestinal metaplasia grading device of this application;

[0054] Figure 6 This is a schematic diagram of the gastric mucosal intestinal metaplasia grading device of this application.

[0055] The purpose, features, and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0056] It should be understood that the specific embodiments described herein are merely illustrative of the technical solutions of this application and are not intended to limit this application.

[0057] To better understand the technical solution of this application, a detailed description will be provided below in conjunction with the accompanying drawings and specific implementation methods.

[0058] This application provides a method for grading gastric mucosal intestinal metaplasia, referencing... Figure 1 , Figure 1 This is a flowchart illustrating the first embodiment of the gastric mucosal intestinal metaplasia grading method of this application. In this embodiment, the method includes steps S10~S40:

[0059] Step S10: Obtain the current full slice image and preprocess the current full slice image to obtain slice image blocks.

[0060] It should be noted that the executing entity of the method in this embodiment can be a computing service device with data processing, network communication, and program execution functions, such as a tablet computer, personal computer, mobile phone, system server, etc. It can also be other terminal devices that can be connected to the gastric mucosal intestinal metaplasia grading system. This embodiment does not limit this. The following uses the gastric mucosal intestinal metaplasia grading device (hereinafter referred to as "device") as an example to describe the various embodiments of this application.

[0061] It should be understood that the current whole-slice images are whole-slice images (WSI) obtained from the original gastric mucosal biopsy, and the resolution of this image can be 0.25. m / pixel means that a single WSI image can reach billions of pixels. Furthermore, due to the complex background (containing mucus, red blood cells, necrotic tissue, and other interference) and diverse glandular structures of gastric mucosa WSI, the current whole-slice image can be preprocessed: the glandular regions are separated from the complex background to generate standardized input (Patch) for model adaptation, i.e., slice image patches.

[0062] In the specific implementation, the device can acquire the current full slice image, and then perform coarse segmentation of the tissue region and fine segmentation of the gland region in sequence to obtain the WSI marked with the gland region. Finally, the WSI marked with the gland region is cut into several patches with an input size (e.g., 1024*1024 pixels) that are adapted to the model, thus obtaining slice image blocks.

[0063] Step S20: Input the sliced ​​image patch into a preset dual-branch classification model to obtain gland classification results. The preset dual-branch classification model includes: a first branch constructed based on a residual network, a second branch constructed based on a Transformer network, a fusion module, and a decoder. The first branch is used to extract local features from the sliced ​​image patch, the second branch is used to extract global features from the sliced ​​image patch, the fusion module is used to perform feature fusion, and the decoder is used to output gland category probabilities based on the fused features.

[0064] It should be noted that this can be used as a reference. Figure 2 The model architecture of the pre-defined two-branch classification model in this application is described in detail. Figure 2 This is a schematic diagram of the model architecture of the pre-defined dual-branch classification model in this application.

[0065] Depend on Figure 2 It can be seen that the preset dual-branch classification model can be built based on the encoder-decoder architecture, wherein the encoder part can include: the first branch, the second branch, and the fusion module.

[0066] The first branch is a neural network (CNN) branch, which can use a residual network (ResNet) to extract local features (local texture, gland edges); the second branch is a Transformer branch, which can model the long-range spatial dependence of glands based on axial attention (such as the global distribution pattern of intestinalized glands in WSI, and their adjacency relationship with normal glands).

[0067] The fusion module can dynamically fuse global and local features using gating weights to obtain fused features.

[0068] The encoder can map the fused features, converting them into pixel-level classification results (normal / intestinal / background) to obtain gland category probabilities.

[0069] In its implementation, this pre-defined dual-branch classification model can receive and process several slice image patches: through a process of "local feature extraction - global feature extraction - feature fusion - classification output," it classifies the gland type (normal gland / intestinal metaplastic gland / background) for each pixel within a patch. This yields the gland type probability for each patch, and subsequently generates masks corresponding to different gland types in the current full-slice image.

[0070] It should also be noted that the training process of this pre-defined two-branch classification model can be as follows: First, the classification model is initialized based on an encoder-decoder architecture. The encoder part can include a first branch built based on a residual network and a second branch built based on a Transformer network. The decoder can be a multi-level decoder. Next, a certain number of WSIs are obtained from the open-source WSI dataset and pixel-level labeled: normal glands are labeled green, intestinal metaplastic glands are labeled yellow, and the background is not labeled, thus obtaining a training dataset (e.g., 320 WSIs, containing 5212 intestinal metaplastic glands). Finally, the initial classification model is trained using this training dataset, optimized using the Dice Loss loss function to solve the class imbalance problem, and the robustness of the model is improved through five-fold cross-validation, ultimately obtaining the pre-defined two-branch classification model.

[0071] Furthermore, to specifically illustrate the role of each branch in the preset dual-branch model, step S20 specifically includes: steps S201~S205:

[0072] Step S201: Extract local features from the sliced ​​image block through the first branch to obtain local features, including gland edge features, cell texture features, and glandular structure features.

[0073] It should be noted that the first branch can be constructed based on a lightweight residual network (ResNet), such as using ResNet-50 with the fully connected layers removed as the backbone for feature extraction. The shallow convolutional layers (C2-C3) in this ResNet can extract low-level features such as edges and textures (e.g., gland boundaries, cell texture), while the deep convolutional layers (C4-C5) can extract structural features (e.g., glandular branches, cell density distribution).

[0074] In its implementation, ResNet can receive 1024*1024*3 slice image patches as input. It extracts multi-level local features from shallow (edge) to deep (structure) layers through shallow and deep convolutional layers, ultimately outputting multi-scale local feature maps (e.g., 768*768*2048, containing multi-level details from edges to structure). This directly reflects the microscopic morphology of the glands, serving as a crucial basis for subsequent segmentation boundaries.

[0075] Step S202: Perform global feature extraction on the sliced ​​image block through the second branch to obtain global features, which include: horizontal gland distribution features and vertical gland topological features.

[0076] It should be noted that the second branch can be constructed based on an axial attention Transformer network, which can divide the input slice image block into sub-blocks, such as 16*16, and calculate the attention in the row direction and column direction respectively.

[0077] Row attention can capture the global associations of gland extensions in the horizontal direction (such as the lateral distribution of continuous intestinalized regions), i.e., the horizontal gland distribution features; while column attention can capture the global associations of gland topology in the vertical direction (such as the vertical aggregation of intestinalized regions), i.e., the vertical gland topology features, to obtain a low-resolution global feature map (e.g., 768*768*512).

[0078] Because global features can be used to capture the “aggregation” (such as continuous intestinal metaplasia regions) or “discretion” (such as isolated intestinal metaplasia foci) of intestinal metaplasia glands, misjudgment of local features due to field limitations can be avoided.

[0079] Step S203: Determine the current spatial weight through the fusion module, and perform weighted fusion of the local features and the global features based on the current spatial weight to obtain fused features.

[0080] It should be noted that spatial weights can be a dynamic weight value assigned to each spatial location (pixel or sub-block), representing the relative importance of local features and global features at that location. To illustrate specifically how spatial weights are calculated for feature extraction, step S203 includes: steps S2031~S2033:

[0081] Step S2031: Concatenate the local features and the global features to generate a joint feature vector.

[0082] In the specific implementation, the local and global features can first be adjusted to the same resolution (e.g., 768*768*512), and then their information can be concatenated to generate a joint feature vector as shown below:

[0083]

[0084] Where (i,j) are spatial coordinates, f local For local features, f global This is a global feature.

[0085] Step S2032: Perform a nonlinear transformation on the joint feature vector using a unit convolutional layer to obtain scalar weight values, and normalize the scalar weight values ​​using a Sigmoid activation function to obtain the current spatial weights, which include local feature weights and global feature weights.

[0086] In a practical implementation, a 1x1 convolutional layer (conv) can be used to apply this to the joint feature vector z. i,j A nonlinear transformation is performed to output scalar weight values. Then, the weight values ​​are normalized to the [0,1] interval by the Sigmoid activation function to obtain the current spatial weights, thereby ensuring that the fusion coefficients of local and global features are reasonable.

[0087] Step S2033: Perform weighted fusion of the local features and the global features according to the local feature weights and the global feature weights to obtain fused features.

[0088] After determining the current spatial weights, the fusion module can fuse local and global features with the same resolution using a weighted summation method, outputting a fused feature map (768*768*512). The fusion formula is as follows:

[0089]

[0090] Where (i,j) are spatial coordinates, w i,j The local feature weights at this location are (1-w) i,j ) represents the global feature weight at that location. and are the feature values ​​of the local feature and the global feature at (i,j), respectively.

[0091] Step S204: Map the fused features using the decoder to determine the gland category probability corresponding to the sliced ​​image block.

[0092] Step S205: Generate masks corresponding to different gland categories in the current full slice image based on the gland category probabilities corresponding to the slice image blocks.

[0093] It should be noted that the decoder can compress the number of channels of the fused features to 3 (corresponding to three probabilities: normal glands / intestinal glands / background) through a unit convolutional layer, and then normalize it through the Softmax function to obtain the gland category probability of each pixel.

[0094] First, a classification threshold is set for each gland category (e.g., intestinal metaplasia glands, normal glands, background, etc.). The classification threshold determines the minimum probability that a pixel belongs to a certain category. For example, the classification threshold can be set to 0.5, meaning that if the probability of a pixel belonging to a certain category is greater than or equal to 0.5, then the pixel is considered to belong to that category.

[0095] Next, the probability of each pixel in the current slice image block belonging to different gland categories is extracted; based on the classification threshold, each pixel is classified into the corresponding gland category to obtain a preliminary segmentation mask.

[0096] Finally, morphological post-processing, such as closing, opening, and connected component analysis, is performed on the initial segmentation mask to obtain masks corresponding to different gland types: intestinal gland mask and normal gland mask.

[0097] Step S30: Based on the gland classification results, determine the corresponding pixel values ​​of the intestinal metaplastic gland region and the normal gland region in the current whole slice image, and determine the current proportion of intestinal metaplastic glands based on the pixel values.

[0098] It should be noted that, firstly, all slice image blocks of the current full slice image can be traversed, and the number of pixels corresponding to the intestinal metaplasia gland mask (the pixel area N of the intestinal metaplasia gland region) can be accumulated. IM ) and the number of pixels corresponding to the normal gland mask (the pixel area N of the normal gland region) NORM ).

[0099] Then, the pixel area N of the intestinal gland region can be used as a reference. IM The pixel area N of the normal gland region NORM The sum of the total effective pixels N is calculated. TOTAL This eliminates the influence of background pixel areas.

[0100] Finally, the intestinal metaplasia gland ratio (IMRatio) can be calculated using the following formula:

[0101]

[0102] Step S40: Compare the current percentage of intestinal metaplastic glands with the preset Sydney system grading threshold to determine the Sydney system grading result corresponding to the current whole slice image.

[0103] It should be noted that the Sydney system is an internationally recognized pathological assessment standard for chronic gastritis, which classifies intestinal metaplasia (IM) into three levels: mild, moderate, and severe. The preset Sydney system grading threshold is a threshold set in advance based on the number of the above-mentioned levels, thus mapping the qualitative description of the Sydney system to a fixed mathematical threshold.

[0104] In practice, the current proportion of intestinal metaplastic glands is compared with the threshold values ​​for each level to determine the Sydney grade range to which the current proportion of intestinal metaplastic glands belongs. This allows for the determination of the Sydney grading result corresponding to the current whole-slice image, thus achieving a closed-loop quantization chain of pixel-level segmentation, area proportion, and Sydney grading. Compared to the existing method of visual grading by pathologists, this eliminates the subjectivity of the Sydney grading results.

[0105] This embodiment integrates local and global features for gland category segmentation, improving the accuracy of gland region identification and thus making the classification of intestinal metaplastic glands and normal glands more accurate. Through the collaboration of a dual-branch model, not only is the comprehensiveness of feature extraction improved, but the model's adaptability to complex pathological images is also enhanced. Furthermore, this application directly combines the proportion of intestinal metaplastic glands with the Sydney grading system, achieving objective and quantitative grading of intestinal metaplasia, effectively reducing subjective differences in manual assessment, improving diagnostic consistency and reliability, and providing a more precise basis for clinical decision-making.

[0106] Based on the first embodiment of this application, in the second embodiment of this application, the content that is the same as or similar to that in the first embodiment described above can be referred to the above description, and will not be repeated hereafter. Based on this, please refer to... Figure 3 , Figure 3 This is a flowchart illustrating the second embodiment of the grading method for gastric mucosal intestinal metaplasia of this application.

[0107] In this embodiment, to specifically illustrate the process of preprocessing the current full-slice image to obtain slice image blocks, step S10 specifically includes: steps S101~S104:

[0108] Step S101: Obtain the current full-slice image and perform downsampling processing on the current full-slice image to obtain a low-resolution overview image.

[0109] It should be understood that because WSI has extremely high resolution, directly processing the entire image would result in an excessive computational burden on the device (e.g., a single image of 100,000×100,000 pixels contains 10 billion pixels). Downsampling, on the other hand, can quickly obtain the global structure by reducing the resolution (sacrificing some details) while preserving the contour information of tissue regions (such as the position and shape of tissue blocks).

[0110] Therefore, the current full-slice image can first be downsampled at a fixed ratio (e.g., 1:4 or 1:8) to generate a low-resolution overview image.

[0111] Step S102: The low-resolution overview image is segmented using an automatic threshold segmentation algorithm to obtain an overview image containing the tissue segmentation mask.

[0112] It should be understood that, firstly, the aforementioned low-resolution overview image can be converted to grayscale. Then, an automatic thresholding segmentation algorithm (such as the Otsu algorithm) can be used to automatically calculate the optimal threshold to segment the image into "tissue regions" (high grayscale values) and "background regions" (low grayscale values).

[0113] It should be noted that the Otsu algorithm can find a threshold based on the statistical characteristics of the image's gray-level histogram to maximize the inter-class variance between the segmented foreground (tissue) and background (i.e., to maximize the distinction between the two classes of pixels). Since the gray-level values ​​of gastric mucosal tissue (including cells and glands) are significantly higher than those of the background (slides, mucus), the Otsu algorithm can effectively separate the tissue region from the background region in the image.

[0114] Next, based on the Otsu threshold segmentation results, the overview image can be binarized (tissue regions are marked as 1, and background as 0), and small holes and broken pieces in the tissue region can be filled by morphological operations (such as closing operations) to finally generate an initial tissue mask (containing only the general outline of the tissue). This can eliminate large areas of background such as slide edges and mucus lakes, and limit the subsequent processing range to the tissue region (such as the mucosal tissue of the gastric antrum and gastric body), greatly reducing the amount of computation.

[0115] Step S103: Based on the staining of the current full-slice image, perform channel enhancement on the overview image containing the tissue segmentation mask, and use a preset morphological algorithm to mark the glandular region in the channel-enhanced overview image to obtain an overview image containing the glandular region segmentation mask.

[0116] It should be understood that since WSI typically uses H&E staining (hematoxylin-eosin), where hematoxylin stains the cell nucleus blue and eosin stains the cytoplasm / extracellular matrix red, channel enhancement can be performed on the tissue area to obtain an overview image after channel enhancement.

[0117] For example, CLAHE (contrast-limited adaptive histogram equalization) can be applied to the hematoxylin channel (blue) to enhance the edge contrast of the cell nucleus; Gaussian filtering can be applied to the eosin channel (red) to suppress background noise and highlight the weak red signal in the glandular cavities.

[0118] It should be noted that the preset morphological algorithm can be a morphological top-hat algorithm. Using the channel-enhanced overview image as the input of this morphological top-hat algorithm, a preset structuring element (such as a disk kernel with a radius of 5 pixels) can be selected first, and a top-hat transformation operation (top-hat transformation = original image - opening operation result) can be performed on the channel-enhanced overview image to obtain the glandular cavity enhancement overview image.

[0119] Top-hat transformation can be used to extract bright details (areas brighter than the background) in an image. Since the cavities of glands (low-density areas stained with eosin) appear brighter than the surrounding glandular epithelium after enhancement, the top-hat transformation algorithm can "highlight" the glandular cavities from the background.

[0120] Next, based on the top-hat transformation results, an automatic threshold segmentation algorithm (such as an adaptive threshold segmentation algorithm or the aforementioned Otsu algorithm) can be used to segment the overview map of enhanced glandular cavities to determine candidate regions of glandular cavities. Then, using the candidate regions of glandular cavities as markers, the watershed algorithm is used to segment them, dividing the adhered glandular regions into independent glands, and obtaining an overview map with glandular region markers.

[0121] Because gastric mucosal glands often adhere due to inflammation or hyperplasia (multiple glands are tightly connected), traditional threshold segmentation cannot separate them. However, the watershed algorithm can effectively solve the problem of segmenting adhered glands by simulating the process of liquid flooding and using the weak boundaries between glands (such as the interstitial region) as natural boundaries, thereby obtaining finely identified gland regions (an overview map with gland region labels).

[0122] Finally, based on the output of the watershed algorithm (an overview map with gland region labels), the segmentation results can be optimized through morphological post-processing (such as removing small regions with an area of ​​less than 50 pixels and filling in tiny holes inside the glands) to finally generate a gland / background binary mask (the gland region is labeled as 1 and the background as 0), thereby ensuring that the gland region segmentation mask only contains the real gland structure (normal or intestinalized).

[0123] Step S104: Align the overview image containing the gland region segmentation mask with the current full slice image, and cut the current full slice image based on the gland region segmentation mask to obtain slice image blocks.

[0124] It should be understood that, since the aforementioned downsampling process and morphological operations may cause slight image shifts, the coordinates of the gland region segmentation mask can be aligned with the coordinates of the current full-slice image. Then, with the gland region as the core, a 1024*1024 pixel patch (containing the gland and a small amount of background around it) is cut on the current full-slice image by sliding a window, thereby ensuring that each patch contains sufficient contextual information (such as the boundary between the gland and the stroma).

[0125] In this embodiment, the preprocessing process follows a three-stage progressive strategy of "coarse localization - fine recognition - patch cutting": coarse localization quickly eliminates large areas of background, narrowing the processing range; fine recognition accurately separates adhered glands through staining enhancement, morphological transformation, and watershed algorithms; patch cutting generates standardized input while preserving the spatial location information of the glands (through masking and pairing with the original image), thus solving the preprocessing difficulties of WSI's "high resolution, complex background, and adhered glands," and providing high-quality input for high-precision segmentation of subsequent models.

[0126] Based on the first and second embodiments of this application, in the third embodiment of this application, the content that is the same as or similar to that in embodiments one and two above can be referred to the above description, and will not be repeated hereafter. Based on this, please refer to... Figure 4 , Figure 4 This is a flowchart illustrating the third embodiment of the grading method for gastric mucosal intestinal metaplasia of this application.

[0127] In this embodiment, to specifically illustrate how to achieve the area percentage-Sydney grade mapping, step S40 includes: steps S401~S403:

[0128] Step S401: Determine several Sydney levels based on the Sydney system classification, and determine the corresponding threshold for the proportion of intestinal metaplasia area according to each Sydney level.

[0129] It should be understood that the Sydney grading system classifies intestinal metaplasia (IM) into mild, moderate, and severe. The corresponding percentage of intestinal metaplasia area for each Sydney grade can then be determined as follows:

[0130] Grade 0 (Negative): IMRatio=0;

[0131] Grade 1 (mild intestinal metaplasia): 0 ≤ IMRatio < 33.3%;

[0132] Grade 2 (Moderate intestinal metaplasia): 33.3 ≤ IMRatio ≤ 66.7%;

[0133] Grade 3 (severe intestinal metaplasia): IMRatio > 66.7%.

[0134] Among them, 0, 33.3%, and 66.7% are the thresholds for the proportion of intestinal metaplasia area corresponding to different Sydney grades (grading thresholds).

[0135] Step S402: Compare the current percentage of intestinal metaplastic glands with the threshold values ​​for the percentage of each intestinal metaplastic area to obtain the comparison results.

[0136] Step S403: Determine the Sydney system level corresponding to the current full-slice image based on the comparison results.

[0137] It should be understood that by comparing the current percentage of intestinal metaplastic glands with the aforementioned grading thresholds, it is possible to determine which Sydney grade range the current percentage of intestinal metaplastic glands falls into, thereby determining the Sydney system grade corresponding to the current whole-slice image.

[0138] Furthermore, considering that the current proportion of intestinal metaplastic glands may be close to the aforementioned threshold for the proportion of intestinal metaplastic area, in order to prevent the influence of boundary conditions, step S403 further includes: steps S4031~S4033:

[0139] Step S4031: Determine the threshold difference between the current intestinal metaplastic gland percentage value and each of the intestinal metaplastic area percentage threshold values.

[0140] It should be understood that, firstly, the grading threshold closest to the current proportion of intestinal metaplastic glands can be determined, and then the difference between the current proportion of intestinal metaplastic glands and that closest grading threshold can be calculated.

[0141] For example, if the current percentage of intestinal metaplasia glands is 32.3% or 34.3%, the closest threshold for the percentage of intestinal metaplasia area is 33.3%, and the corresponding threshold differences are respectively... 1%.

[0142] Step S4032: When the threshold difference meets the preset critical value range, the current full slice image is determined to be a critical sample, and a manual review prompt is triggered based on the critical sample so that a professional physician can determine the Sydney system level corresponding to the current full slice image.

[0143] It should be understood that, as shown in the aforementioned examples, the proportions of intestinal metaplasia glands are close, at 32.3% and 34.3%. However, since the grading threshold is 33.3%, they will be classified into two different Sydney system grades: mild and moderate intestinal metaplasia. This may lead to misjudgment in clinical applications.

[0144] Therefore, a threshold range can be preset, for example, set to [-3%, +3%]. Then, the current whole slice image with the corresponding threshold difference within this threshold range can be regarded as a critical sample and handed over to a professional physician for manual review. Experienced pathologists can then make the final judgment on the critical sample by combining the morphological characteristics of the current whole slice image (such as glandular structure and cellular atypia), which balances efficiency and accuracy and conforms to the principle of "rigor first" in pathological diagnosis.

[0145] Step S4033: When the threshold difference does not meet the preset critical value range, determine the Sydney system level corresponding to the current full slice image based on the comparison result.

[0146] Accordingly, when the threshold difference is not within the preset critical value range, the current full slice image is not a critical sample. Therefore, the Sydney level range to which it belongs can be directly determined based on the current proportion of intestinal glands, and thus the Sydney system level corresponding to the current full slice image can be determined.

[0147] Furthermore, in another implementation, to achieve critical sample optimization, the aforementioned pre-defined two-branch classification model can be improved: the model task is changed from classification to prediction; the output layer of the decoder in the pre-defined two-branch classification model is changed to a regression layer, thereby directly predicting the IMRatio value of the input slice image patch; and when labeling training data, the labeling is changed from gland type labeling to true IMRatio value labeling, and the loss function is changed to mean squared error (MSE) or a smoothing loss function that optimizes the model's ability to fit continuous values. This results in an improved pre-defined two-branch classification model, i.e., a prediction model.

[0148] By inputting the segmented image patch into the prediction model, the model can output a prediction result such as IMRatio=32.5%.

[0149] Next, considering that the prediction results of the predictive model may still be uncertain due to input noise (such as uneven H&E staining) or model generalization error (such as the training set not covering certain pathological subtypes), Monte Carlo Dropout (MCDropout) can be used to perform multiple forward propagations of the predictive model, obtaining multiple prediction results. The mean (as the best estimate of IMRatio) and standard deviation (as a measure of uncertainty) are then calculated to obtain the confidence interval. The smaller the standard deviation, the higher the confidence level of the prediction model; the larger the standard deviation, the higher the uncertainty.

[0150] For example, after 20 MCDropout inferences on the same input, the predicted results could be [31.8%, 32.5%, 33.2%, ..., 34.1%], with a mean of 33.1% and a standard deviation of 1.2%. Therefore, the confidence interval is 33.1%. 1.2%.

[0151] Since the confidence interval of IMRatio=33.1% exceeds the grading threshold (33.3%), it is determined to be a critical sample, triggering manual review, thereby compensating for the insufficient predictive reliability of the model in complex or rare cases.

[0152] For example, if the confidence interval is 28.5%~29.8% (mean 29.1%, standard deviation 0.6%), that is, the confidence interval is completely lower than the classification threshold of 33.3%, then no manual review is required, and the corresponding Sydney level can be directly determined as Level 1;

[0153] For example, if the confidence interval is 34.5%~36.2% (mean 35.3%, standard deviation 0.8%), meaning the confidence interval is completely higher than the grading threshold of 33.3%, then no manual review is required, and the corresponding Sydney grade can be directly determined as Level 2.

[0154] The aforementioned prediction model can transform discrete classification into a refined assessment based on "continuous numerical values ​​+ confidence levels." It preserves the specific numerical information of the IMRatio through regression modeling, quantifies prediction uncertainty using MCDropout, and triggers manual review only for high-risk borderline samples. This balances efficiency and accuracy, adhering to the principle of "rigor first" in pathological diagnosis.

[0155] In this embodiment, when determining the Sydney grade based on the current proportion of intestinal metaplastic glands and the grading threshold, it is considered that critical samples with current intestinal metaplastic gland proportions close to the grading threshold may be affected by model input noise and model generalization error. Therefore, manual review is introduced when judging critical samples. Experienced pathologists combine the morphological characteristics of WSI (such as glandular structure and cellular atypia) to make the final judgment on the critical samples, which significantly improves the accuracy of intestinal metaplasia grading diagnosis and provides more reliable grading results for clinical decision-making.

[0156] This application also proposes a grading device for gastric mucosal intestinal metaplasia, referencing... Figure 5 , Figure 5 This is a schematic diagram of the modular structure of the gastric mucosal intestinal metaplasia grading device of this application.

[0157] Depend on Figure 5 It is known that the gastric mucosal intestinal metaplasia grading device includes:

[0158] Image preprocessing module 501 is used to acquire the current full slice image and preprocess the current full slice image to obtain slice image blocks;

[0159] The model classification module 502 is used to input the sliced ​​image patch into a preset dual-branch classification model to obtain gland classification results. The preset dual-branch classification model includes: a first branch constructed based on a residual network, a second branch constructed based on a Transformer network, a fusion module, and a decoder. The first branch is used to extract local features from the sliced ​​image patch, the second branch is used to extract global features from the sliced ​​image patch, the fusion module is used to perform feature fusion, and the decoder is used to output gland category probabilities based on the fused features.

[0160] The hierarchical mapping module 503 is used to determine the corresponding pixel values ​​of the intestinal metaplastic gland region and the normal gland region in the current whole slice image based on the gland classification result, and to determine the current proportion of intestinal metaplastic glands based on the pixel values.

[0161] The hierarchical mapping module 503 is further configured to compare the current proportion of intestinal metaplastic glands with a preset Sydney system hierarchical threshold to determine the Sydney system hierarchical result corresponding to the current whole slice image.

[0162] This embodiment integrates local and global features for gland category segmentation, improving the accuracy of gland region identification and thus making the classification of intestinal metaplastic glands and normal glands more accurate. Through the collaboration of a dual-branch model, not only is the comprehensiveness of feature extraction improved, but the model's adaptability to complex pathological images is also enhanced. Furthermore, this application directly combines the proportion of intestinal metaplastic glands with the Sydney grading system, achieving objective and quantitative grading of intestinal metaplasia, effectively reducing subjective differences in manual assessment, improving diagnostic consistency and reliability, and providing a more precise basis for clinical decision-making.

[0163] This application also provides a gastric mucosal intestinal metaplasia grading device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the gastric mucosal intestinal metaplasia grading method in the above embodiment 1.

[0164] The following is for reference. Figure 6 , Figure 6This is a schematic diagram of the gastric mucosal intestinal metaplasia grading device of this application. The gastric mucosal intestinal metaplasia grading device in the embodiments of this application may include, but is not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Description), PMPs (Portable Media Players), etc., as well as fixed terminals such as digital TVs, desktop computers, etc. Figure 6 The gastric mucosal intestinal metaplasia grading device shown is merely an example and should not impose any limitations on the functionality and scope of use of the embodiments of this application.

[0165] like Figure 6 As shown, the gastric mucosal intestinal metaplasia grading device may include a processing unit 1001 (e.g., a central processing unit, a graphics processing unit, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1002 or a program loaded from a storage device 1003 into a random access memory (RAM) 1004. The RAM 1004 also stores various programs and data required for the operation of the gastric mucosal intestinal metaplasia grading device. The processing unit 1001, ROM 1002, and RAM 1004 are interconnected via a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Typically, the following systems can be connected to I / O interface 1006: input devices 1007 including, for example, touchscreens, touchpads, keyboards, mice, image sensors, microphones, accelerometers, gyroscopes, etc.; output devices 1008 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 1003 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1009. Communication device 1009 allows the gastric mucosal intestinal metaplasia grading device to communicate wirelessly or wiredly with other devices to exchange data. Although the figure shows a gastric mucosal intestinal metaplasia grading device with various systems, it should be understood that it is not required to implement or possess all the systems shown. More or fewer systems may be implemented alternatively.

[0166] The gastric mucosal intestinal metaplasia grading device provided in this application, employing the gastric mucosal intestinal metaplasia grading method described in the above embodiments, can solve the technical problem of gastric mucosal intestinal metaplasia grading. Compared with existing methods, the beneficial effects of the gastric mucosal intestinal metaplasia grading device provided in this application are the same as those of the gastric mucosal intestinal metaplasia grading method provided in the above embodiments, and other technical features of this gastric mucosal intestinal metaplasia grading device are the same as those disclosed in the previous embodiment method, and will not be repeated here.

[0167] This application also provides a computer-readable storage medium having computer-readable program instructions (i.e., a computer program) stored thereon, the computer-readable program instructions being used to perform the gastric mucosal intestinal metaplasia grading method in the above embodiments.

[0168] The computer-readable storage medium provided in this application may be, for example, a USB flash drive, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, system, or device. The program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination thereof.

[0169] The readable storage medium provided in this application is a computer-readable storage medium that stores computer-readable program instructions (i.e., a computer program) for executing the above-described method for grading gastric mucosal intestinal metaplasia, thereby solving the technical problems of the method for grading gastric mucosal intestinal metaplasia. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as those of the gastric mucosal intestinal metaplasia grading method provided in the above embodiments, and will not be repeated here.

[0170] The above description is only a part of the embodiments of this application and does not limit the scope of this application. All equivalent structural transformations made under the technical concept of this application and using the content of this application specification and drawings, or direct / indirect applications in other related technical fields, are included within the protection scope of this application.

Claims

1. A method for grading gastric mucosal intestinal metaplasia, characterized by, The method comprises: acquiring a current full slice image, and preprocessing the current full slice image to obtain a slice image block, comprising: acquiring the current full slice image, and performing down-sampling processing on the current full slice image to obtain a low-resolution overview image; segmenting the low-resolution overview image by using an automatic threshold segmentation algorithm to obtain an overview image containing a tissue segmentation mask; enhancing the channel of the overview image containing the tissue segmentation mask according to the staining condition of the current full slice image, and marking the gland region of the channel-enhanced overview image by using a preset morphological algorithm to obtain an overview image containing a gland region segmentation mask, comprising: selecting a preset structural element, performing a top-hat transformation operation on the channel-enhanced overview image to obtain an overview image with enhanced gland lumen; segmenting the overview image with enhanced gland lumen by using the automatic threshold segmentation algorithm to determine the candidate region of the gland lumen; using the candidate region of the gland lumen as a marker, segmenting the overview image with enhanced gland lumen by using a watershed algorithm to obtain an overview image with gland region marking; optimizing the segmentation result of the overview image with gland region marking by using a morphological post-processing method to obtain an overview image containing a gland region segmentation mask; aligning the overview image containing the gland region segmentation mask with the current full slice image, and cutting the current full slice image based on the gland region segmentation mask to obtain a slice image block; inputting the slice image block into a preset double-branch classification model to obtain a gland classification result, the preset double-branch classification model comprising: a first branch based on a residual network, a second branch based on a Transformer network, a fusion module, and a decoder, the first branch being used for local feature extraction of the slice image block, the second branch being used for global feature extraction of the slice image block, the fusion module being used for feature fusion, and the decoder being used for outputting gland category probability according to fused features; determining the corresponding pixel values of intestinal metaplasia gland regions and normal gland regions in the current full slice image based on the gland classification result, and determining the current intestinal metaplasia gland proportion value according to the pixel values; comparing the current intestinal metaplasia gland proportion value with a preset Sydney system grading threshold to determine the corresponding Sydney system grading result of the current full slice image, comprising: determining a plurality of Sydney grades based on the Sydney system grading condition, and determining corresponding intestinal metaplasia area proportion threshold values according to the Sydney grades; comparing the current intestinal metaplasia gland proportion value with each intestinal metaplasia area proportion threshold value to obtain a comparison result; determining the Sydney system grade corresponding to the current full slice image according to the comparison result.

2. The method of claim 1, wherein, The step of inputting the slice image block into a preset double-branch classification model to obtain a gland classification result comprises: performing local feature extraction on the slice image block by using the first branch to obtain local features, the local features comprising: gland edge features, cell texture features, and gland duct structure features; The second branch is used for performing global feature extraction on the slice image block to obtain global features, wherein the global features include horizontal gland distribution features and vertical gland topological features; The fusion module is used for determining a current spatial weight, and performing weighted fusion on the local features and the global features based on the current spatial weight to obtain fused features; The decoder is used for mapping the fused features to determine a gland category probability corresponding to the slice image block; A mask corresponding to different gland categories is generated in the current whole slice image according to the gland category probability corresponding to the slice image block.

3. The method of claim 2, wherein, The step of determining the current spatial weight and performing weighted fusion on the local features and the global features based on the current spatial weight to obtain fused features includes: The local features and the global features are spliced to generate a joint feature vector; A unit convolution layer is used to perform nonlinear transformation on the joint feature vector to obtain a scalar weight value, and a Sigmoid activation function is used to normalize the scalar weight value to obtain a current spatial weight, wherein the current spatial weight includes a local feature weight and a global feature weight; The local features and the global features are weighted fused according to the local feature weight and the global feature weight to obtain fused features.

4. The method of claim 1, wherein, The step of determining the Sydney system grade corresponding to the current whole slice image according to the comparison result includes: A threshold difference value between the current intestinalized gland proportion value and each intestinal area proportion threshold value is determined; When the threshold difference value meets a preset critical value range, it is determined that the current whole slice image is a critical sample, and an artificial review prompt is triggered based on the critical sample to enable a professional physician to determine the Sydney system grade corresponding to the current whole slice image; When the threshold difference value does not meet the preset critical value range, the Sydney system grade corresponding to the current whole slice image is determined according to the comparison result.

5. A device for grading gastric mucosal intestinal metaplasia, characterized by, The device includes: An image preprocessing module is configured to obtain a current whole slice image, and pre-process the current whole slice image to obtain a slice image block; The image preprocessing module is further configured to obtain the current whole slice image, and perform down-sampling processing on the current whole slice image to obtain a low-resolution overview image; an automatic threshold segmentation algorithm is used to segment the low-resolution overview image to obtain an overview image containing a tissue segmentation mask; a channel enhancement is performed on the overview image containing the tissue segmentation mask according to the staining condition of the current whole slice image, and a preset morphological algorithm is used to mark the gland region of the channel-enhanced overview image to obtain an overview image containing a gland region segmentation mask; the overview image containing the gland region segmentation mask is aligned with the current whole slice image, and the current whole slice image is cut based on the gland region segmentation mask to obtain a slice image block; The image preprocessing module is further configured to select a preset structural element, perform a top-hat transformation operation on the overview image of the enhanced channel to obtain an overview image of enhanced glandular lacunae, segment the overview image of the enhanced glandular lacunae by using the automatic threshold segmentation algorithm to determine a candidate region of the glandular lacunae, segment the overview image of the enhanced glandular lacunae by using a watershed algorithm with the candidate region of the glandular lacunae as a marker to obtain an overview image with a glandular region marker, and perform segmentation result optimization on the overview image with the glandular region marker by using a morphological post-processing method to obtain an overview image containing a glandular region segmentation mask. The model classification module is configured to input the slice image block into a preset double-branch classification model to obtain a gland classification result, the preset double-branch classification model including a first branch constructed based on a residual network, a second branch constructed based on a Transformer network, a fusion module, and a decoder, the first branch being configured to extract local features of the slice image block, the second branch being configured to extract global features of the slice image block, and the fusion module being configured to perform feature fusion, and the decoder being configured to output a gland category probability according to the fused features. The hierarchical mapping module is configured to determine pixel values of intestinal metaplasia gland regions and normal gland regions in the current whole slice image based on the gland classification result, and determine a current intestinal metaplasia gland proportion value according to the pixel values. The hierarchical mapping module is further configured to compare the current intestinal metaplasia gland proportion value with preset Sydney system grading thresholds to determine a Sydney system grading result corresponding to the current whole slice image. The hierarchical mapping module is further configured to determine a plurality of Sydney grades based on the Sydney system grading, determine corresponding intestinal metaplasia area proportion threshold values according to the Sydney grades, compare the current intestinal metaplasia gland proportion value with the intestinal metaplasia area proportion threshold values to obtain a comparison result, and determine a Sydney system grade corresponding to the current whole slice image according to the comparison result.

6. A gastric mucosal intestinal epithelial metaplasia grading apparatus characterized by comprising: The gastric mucosa intestinal epithelial metaplasia grading device includes a memory, a processor, and a gastric mucosa intestinal epithelial metaplasia grading program stored on the memory and executable on the processor, and the gastric mucosa intestinal epithelial metaplasia grading program, when executed by the processor, implements the steps of the gastric mucosa intestinal epithelial metaplasia grading method according to any one of claims 1 to 4.

7. A storage medium, characterized by The storage medium stores a gastric mucosa intestinal epithelial metaplasia grading program, and the gastric mucosa intestinal epithelial metaplasia grading program, when executed by the processor, implements the steps of the gastric mucosa intestinal epithelial metaplasia grading method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Intestinal metaplasia severity classification system

    CN115690518A

  • Polyp segmentation method and system based on double-branch feature fusion network

    CN117237641A