Hierarchical Contrastive Learning for Pattern-Generalizable Image Corruption Detection
Xin Feng, Yifeng Xu, Guangming Lu, Wenjie Pei
Abstract
Effective image restoration with large-size corruptions, such as blind image inpainting, entails precise detection of corruption region masks which remains extremely challenging due to diverse shapes and patterns of corruptions. In this work, we present a novel method for automatic corruption detection, which allows for blind corruption restoration without known corruption masks. Specifically, we develop a hierarchical contrastive learning framework to detect corrupted regions by capturing the intrinsic semantic distinctions between corrupted and uncorrupted regions. In particular, our model detects the corrupted mask in a coarse-to-fine manner by first predicting a coarse mask by contrastive learning in low-resolution feature space and then refines the uncertain area of the mask by high-resolution contrastive learning. A specialized hierarchical interaction mechanism is designed to facilitate the knowledge propagation of contrastive learning in different scales, boosting the modeling performance substantially. The detected multi-scale corruption masks are then leveraged to guide the corruption restoration. Detecting corrupted regions by learning the contrastive distinctions rather than the semantic patterns of corruptions, our model has well generalization ability across different corruption patterns. Extensive experiments demonstrate following merits of our model: 1) the superior performance over other methods on both corruption detection and various image restoration tasks including blind inpainting and watermark removal, and 2) strong generalization across different corruption patterns such as graffiti, random noise or other image content. Codes and trained weights are available at https://github.com/xyfJASON/HCL.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext f96ab8d1-3687-47cd-997a-e89adf440b09Cited by top-tier papers2
- A Unified Framework for Microscopy Defocus Deblur with Multi-Pyramid Transformer and Contrastive LearningYuelin Zhang, Pengyu Zheng, Wanquan Yan, Chengyu Fang et al.CVPR 2024 · 19 citations
- InpDiffusion: Image Inpainting Localization via Conditional Diffusion ModelsKai Wang, Shaozhang Niu, Qixian Hao, Jiwei ZhangAAAI 2025 · 6 citations
Builds on19
- Swin Transformer: Hierarchical Vision Transformer using Shifted WindowsZe Liu, Yutong Lin, Yue Cao, Han Hu et al.ICCV 2021 · 31,683 citations
- A Simple Framework for Contrastive Learning of Visual RepresentationsTing Chen, Simon Kornblith, Mohammad Norouzi, Geoffrey E. HintonICML 2020 · 24,064 citations
- Free-Form Image Inpainting With Gated ConvolutionJiahui Yu, Zhe Lin, Jimei Yang, Xiaohui Shen et al.ICCV 2019 · 1,990 citations
- Coherent Semantic Attention for Image InpaintingHongyu Liu, Bin Jiang, Yi Xiao, Chao YangICCV 2019 · 395 citations
- MAT: Mask-Aware Transformer for Large Hole Image InpaintingWenbo Li, Zhe Lin, Kun Zhou, Lu Qi et al.CVPR 2022 · 382 citations
Related papers
- DENet: Disentangled Embedding Network for Visible Watermark RemovalRuizhou Sun, Yukun Su, Qingyao WuAAAI 2023 · 24 citations
- Unsupervised Deraining: Where Contrastive Learning Meets Self-similarityYuntong Ye, Changfeng Yu, Yi Chang, Lin Zhu et al.CVPR 2022 · 76 citations
- Generative Image Inpainting with Segmentation Confusion Adversarial Training and Contrastive LearningZhiwen Zuo, Lei Zhao, Ailin Li, Zhizhong Wang et al.AAAI 2023 · 36 citations
- All-In-One Image Restoration for Unknown CorruptionBoyun Li, Xiao Liu, Peng Hu, Zhongqin Wu et al.CVPR 2022 · 338 citations
- RGI: robust GAN-inversion for mask-free image inpainting and unsupervised pixel-wise anomaly detectionShancong Mou, Xiaoyi Gu, Meng Cao, Haoping Bai et al.ICLR 2023 · 8 citations
