Ulcerative colitis is one of the most unpredictable inflammatory bowel diseases, and its clinical management hinges on a question that sounds deceptively simple: how active is the inflammation right now? Gastroenterologists answer it by inspecting the colonic mucosa during endoscopy and assigning a severity grade, most commonly the Mayo endoscopic subscore ranging from 0 for normal mucosa to 3 for severe disease with spontaneous bleeding. That grade drives decisions about escalating therapy, and misreading it can mean undertreating a worsening patient or overtreating one who is already stabilizing. A team at Yunnan University in Kunming, China, now reports a deep learning architecture designed to make that judgment more reliable, and its results suggest that the hardest part of the task is not spotting inflammation but understanding how scattered evidence across an entire endoscopic field adds up.
The new model, described in the journal Medical & Biological Engineering & Computing, is called UC-DiffuMambaNet, and its name hints at an unusual marriage of ideas. It combines diffusion-inspired state propagation, Mamba-style selective sequence modeling, and window-based attention into a single pipeline for grading ulcerative colitis from endoscopy images. The work was led by Pan Ma, with Hao Zhou, Hao Wu, Yi Li, and Guowu Yuan as co-authors, and it was motivated by a specific observation about how severity manifests visually. Inflammation in ulcerative colitis does not always announce itself as one obvious lesion. It can appear as subtle vascular changes, loss of the normal mucosal pattern, erythema, friability, or bleeding, distributed unevenly across the mucosa, and the overall grade depends on how all of those local findings combine.
That observation shaped the architecture’s central component, a module the authors call two-dimensional contextual state propagation. In essence, the model treats an endoscopic image as a grid of local states, each carrying information about what is happening in a small patch of mucosa. These states are then propagated across the image in a manner inspired by how diffusion models refine noisy representations: each state is iteratively updated by aggregating evidence from its neighbors, so that local findings gradually accumulate into a global picture of severity. The propagation runs at two scales, one capturing fine-grained texture and the other capturing broader regional context, which allows the model to register both a small patch of friability and the wider distribution of vascular loss that a human grader would weigh together.
The choice of propagation mechanism is where the Mamba influence enters. Mamba models, which have recently gained attention as efficient alternatives to transformers for long sequences, rely on selective state space models that decide dynamically which parts of an input to emphasize and which to filter out. UC-DiffuMambaNet adapts that idea to two-dimensional image data, using selective state propagation to strengthen the local findings that matter for grading while suppressing irrelevant background. The authors report that this selective approach outperformed a non-selective variant in their ablation experiments, suggesting that the dynamic filtering is not just an efficiency trick but a genuine contributor to accuracy.
On top of the state propagation module, the architecture adds a second component called window attention. Attention mechanisms, familiar from transformer models, allow a network to relate distant parts of an input to each other, but full-image attention is computationally expensive. Window attention restricts those relationships to local neighborhoods, which keeps the cost manageable while still allowing the model to compare findings across different regions of the mucosa. The authors combine window attention with the state propagation module so that the two mechanisms complement each other: state propagation aggregates local evidence into regional summaries, and window attention relates those summaries across the image to form a final severity estimate.
The third component addresses a subtlety of the grading task itself. The Mayo subscore is ordinal, meaning that adjacent grades are more similar than distant ones, and a model that treats the four grades as unrelated categories throws away that structure. UC-DiffuMambaNet incorporates the ordinal nature of the task into its training objective, penalizing errors in proportion to how far apart the predicted and true grades are. The authors report that this ordinal-aware objective improved performance over a standard categorical loss, particularly for the middle grades where the boundary between mild and moderate disease is least clear.
The results are striking. The authors evaluated the model on two datasets: an institutional dataset of anonymized colonoscopy images collected under institutional data-protection requirements, and the public LIMUC dataset of ulcerative colitis endoscopy images. On the institutional dataset, UC-DiffuMambaNet achieved an accuracy of 96.28% and a quadratic weighted kappa of 0.9126, a statistic that measures agreement between predicted and true grades while accounting for the ordinal structure of the task. On the public LIMUC dataset, the model reached 91.26% accuracy and a quadratic weighted kappa of 0.7965. The authors compared the architecture against several baselines, including ResNet, ConvNeXt, Swin Transformer, and VMamba variants, and report that UC-DiffuMambaNet outperformed all of them on both datasets.
Statistical testing reinforced the comparison. The authors used the DeLong test to compare the model’s performance against baselines and found that the improvements were statistically significant. They also conducted ablation experiments to isolate the contribution of each component, removing the state propagation module, the window attention module, and the ordinal-aware objective one at a time. Each removal degraded performance, confirming that all three components contribute to the final result. The state propagation module had the largest single effect, followed by the ordinal-aware objective and then the window attention module.
The clinical implications are considerable. An automated grading system that reaches this level of agreement with expert graders could serve as a second reader in endoscopy suites, flagging cases where the automated grade differs from the clinician’s judgment and prompting a closer look. It could also help standardize grading across centers, where interobserver variability in endoscopic severity assessment is a known problem, and it could support clinical trials that rely on endoscopic severity as an endpoint. The authors note that the model’s selective state propagation is computationally efficient, which matters for deployment in settings where computing resources are limited.
Limitations remain. The institutional dataset was collected at a single center, and the authors acknowledge that performance on data from other centers with different endoscopy equipment and imaging protocols may differ. The public LIMUC dataset, while valuable for benchmarking, is also drawn from a limited range of sources. The authors call for external validation on multi-center data before clinical deployment, and they note that the model’s predictions, like those of any deep learning system, should be interpreted as decision support rather than as a replacement for expert judgment. Even so, the architecture’s central insight, that scattered local findings must be aggregated into a global severity estimate through selective state propagation, offers a template that could extend beyond ulcerative colitis to other grading tasks in medical imaging where the evidence is distributed rather than concentrated.
Subject of Research: UC-DiffuMambaNet: dual-scale state propagation and window attention for ordinal Mayo endoscopic grading
Article Title: UC-DiffuMambaNet: dual-scale state propagation and window attention for ordinal Mayo endoscopic grading
Article References: Ma, P., Zhou, H., Wu, H., Li, Y., & Yuan, G. (2026). UC-DiffuMambaNet: dual-scale state propagation and window attention for ordinal Mayo endoscopic grading. Medical & Biological Engineering & Computing. https://doi.org/10.1007/s11517-026-03694-x
Image Credits: AI Generated
DOI: 10.1007/s11517-026-03694-x
Keywords: ulcerative colitis, deep learning, endoscopy, Mayo score, Mamba, state space model, attention mechanism, ordinal classification, medical imaging, LIMUC dataset, Yunnan University, computer-aided diagnosis
News Source: Ophelia Keating. (October 17, 2026). Diffusion-Inspired AI Model Reads Ulcerative Colitis Severity from Endoscopy Images. Scienmag.



