Patch-to-Global: Random Patch Diffusion for Globally Consistent Megapixel Artifact Inpainting in Whole Slide Images

Hyeseong Lee, Eunsu Kim, D M Bappy, Ho Heon Kim, Youngsuk Lee +4 more
9/21/2026
cs.CV

Official code: PathfinderLab/RestorePath (2 stars, Jupyter Notebook, MIT, last commit 2026-08-11).

Abstract

Although deep learning has advanced Whole Slide Image (WSI) Analysis, tissue artifacts like bubbles and folds often cause silent failures by concealing essential morphology. Current pathology image restoration methods are mostly restricted to small patches, struggling to maintain global structural coherence at a megapixel scale.

Show full abstract

We introduce RestorePath, a framework for globally consistent megapixel scale inpainting that reconstructs diagnostic structures in histological image to prevent incorrect high-confidence predictions and lower error rates. Our model utilizes a Latent Diffusion Model (LDM) conditioned on Pathology Foundation Model (PFM) embeddings, integrating Large Kernel Attention (LKA) to manage long-range dependencies during random patch diffusion. Enhanced by Distance-Weighted Interpolation (DWI) and an Adaptive Guidance Scale (AGS), RestorePath ensures structural consistency and fidelity by modulating information from surrounding patches. Evaluations across TCGA-BRCA, BACH, and Camelyon16 datasets for images ranging from 512 to 4608 pixels demonstrate state-of-the-art performance in maintaining histological consistency. RestorePath significantly improves downstream Computational Pathology (CP) tasks, outperforming both raw artifact images and the conventional Detect-and-Discard (D&D) approach. The code is available at https://github.com/PathfinderLab/RestorePath

View on arXivView PDF

Code Implementations(1)

MIT

Patch-to-Global: Random Patch Diffusion for Globally Consistent Megapixel Artifact Inpainting in Whole Slide Images (MICCAI 2026)

20Jupyter Notebook, PythonMar 7, 20263 months agoMIT

Similar Papers

Cite this paper

@article{lee2026patchtoglobal,
  title  = {Patch-to-Global: Random Patch Diffusion for Globally Consistent Megapixel Artifact Inpainting in Whole Slide Images},
  author = {Hyeseong Lee and Eunsu Kim and D M Bappy and Ho Heon Kim and Youngsuk Lee and Se Young Chun and Jang-Hwan Choi and Sung Hak Lee and Sangjeong Ahn},
  year   = {2026},
  eprint = {2609.24116},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2609.24116v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2609.24116.svg)](https://codeofpaper.com/paper/2609.24116)

Discussion