vickyFox / Region-wise-Inpainting

Region-wise GAN, image inpainting
MIT License
53 stars 17 forks source link

Region-wise Generative Adversarial Image Inpainting for Large Missing Areas

This repository implements the training and testing code for "Region-wise Generative Adversarial Image Inpainting for Large Missing Areas". We propose an generic inpainting framework capable of handling with incomplete images on both continuous and discontinuous large missing areas, in an adversarial manner. We extend upon our prior conference publication "Coarse-to-Fine Image Inpainting via Region-wise convolutions and Non-local correlation" that mainly focuses on the discontinuous missing areas using the region-wise convolutions, suffering severe artifacts when the large missing areas are continuous. Some results are as follows.

RUN

Requirements:

The code was trained and tested with Tensorflow 1.x.0.CUDA 9.0 ,Python 3.6

Datasets

Training

Testing

python test.py --test_data_path your_data_path --mask_path your_mask_path --model_path pretrained_model

Pretrained

Download the pre-trained models and put them under the default directory \models or any other path you want.

Our main novelty of this project is the ability to handle with incomplete images on both continuous and discontinuous large missing areas.

Citing

@ARTICLE{2019arXiv190912507M,
       author = {{Ma}, Yuqing and {Liu}, Xianglong and {Bai}, Shihao and {Wang}, Lei and
         {Liu}, Aishan and {Tao}, Dacheng and {Hancock}, Edwin},
        title = "{Region-wise Generative Adversarial ImageInpainting for Large Missing Areas}",
      journal = {arXiv e-prints},
     keywords = {Computer Science - Computer Vision and Pattern Recognition},
         year = "2019",
        month = "Sep",
          eid = {arXiv:1909.12507},
        pages = {arXiv:1909.12507},
archivePrefix = {arXiv},
       eprint = {1909.12507},
 primaryClass = {cs.CV},
       adsurl = {https://ui.adsabs.harvard.edu/abs/2019arXiv190912507M},
      adsnote = {Provided by the SAO/NASA Astrophysics Data System}
}

@inproceedings{ma2019inpainting,
  title={Coarse-to-Fine Image Inpainting via Region-wise Convolutions and Non-Local Correlation.},
  author={Yuqing Ma and Xianglong Liu and Shihao Bai and Lei Wang and Dailan He and Aishan Liu},
  booktitle={IJCAI},
  year={2019}
}