Resolution-robust Large Mask Inpainting with Fourier Convolutions

Roman Suvorov, Elizaveta Logacheva, Anton Mashikhin, Anastasia Remizova, Arsenii Ashukha +5 more
9/15/2021
cs.CVeess.IV

Official code: advimman/lama (10,278 stars, Apache-2.0, PyTorch, last commit 2025-02-05).

Abstract

Modern image inpainting systems, despite the significant progress, often struggle with large missing areas, complex geometric structures, and high-resolution images. We find that one of the main reasons for that is the lack of an effective receptive field in both the inpainting network and the loss function. To alleviate this issue, we propose a new method called large mask inpainting (LaMa). LaMa is based on i) a new inpainting network architecture that uses fast Fourier convolutions (FFCs), which have the image-wide receptive field; ii) a high receptive field perceptual loss; iii) large training masks, which unlocks the potential of the first two components. Our inpainting network improves the state-of-the-art across a range of datasets and achieves excellent performance even in challenging scenarios, e.g. completion of periodic structures. Our model generalizes surprisingly well to resolutions that are higher than those seen at train time, and achieves this at lower parameter&time costs than the competitive baselines. The code is available at \url{https://github.com/saic-mdal/lama}.

View on arXivView PDF

Code Implementations(1)

advimman/lamaOfficial100%
PyTorchApache-2.0

🦙 LaMa Image Inpainting, Resolution-robust Large Mask Inpainting with Fourier Convolutions, WACV 2022

10,2781,081Shell, PythonAug 30, 20211 years agoApache-2.0
cnncolabcolab-notebookcomputer-visiondeep-learning+13 more

Cite this paper

@article{suvorov2021resolutionrobust,
  title  = {Resolution-robust Large Mask Inpainting with Fourier Convolutions},
  author = {Roman Suvorov and Elizaveta Logacheva and Anton Mashikhin and Anastasia Remizova and Arsenii Ashukha and Aleksei Silvestrov and Naejin Kong and Harshith Goka and Kiwoong Park and Victor Lempitsky},
  year   = {2021},
  eprint = {2109.07161},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2109.07161}
}

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/2109.07161.svg)](https://codeofpaper.com/paper/2109.07161)

Discussion