Deep Photo Scan: Semi-supervised learning for dealing with the real-world degradation in smartphone photo scanning
Man M. Ho and Jinjia Zhou
In ArXiv, 2021.
- Ubuntu 16.04
- Pillow
- PyTorch >= 1.3.0
- Numpy
- gdown (for fetching models)
git clone https://github.com/minhmanho/dpscan.git
cd dpscan
You can download the pre-trained model at here (148MB) or run the following script:
./models/fetch_model.sh
Run our semi-supervised Deep Photo Scan to restore smartphone-scanned photos as:
CUDA_VISIBLE_DEVICES=0 python run.py \
--in_dir ./data/in/ \
--out_dir ./data/out/ \
--ckpt ./models/dpscan_saved_weights.pth.tar \
--size 1072x720
Check our page for the results.
Training data captured using iPhone XR can be downloaded at this Google Drive.
Besides photos in the same distribution as training photos, test data also consists of out-of-distribution cases such as color-balanced and taken-by-XperiaXZ1 photos. All test cases can be downloaded at this Google Drive.
If you find this work useful, please consider citing:
@misc{ho2021deep,
title={Deep Photo Scan: Semi-supervised learning for dealing with the real-world degradation in smartphone photo scanning},
author={Man M. Ho and Jinjia Zhou},
year={2021},
eprint={2102.06120},
archivePrefix={arXiv},
primaryClass={cs.CV}
}
We would like to thank:
- digantamisra98 for the Unofficial PyTorch Implementation of EvoNorm
Liu, Hanxiao, Andrew Brock, Karen Simonyan, and Quoc V. Le. "Evolving Normalization-Activation Layers."
ArXiv (2020).
- Richard Zhang for the BlurPool
Zhang, Richard. "Making convolutional networks shift-invariant again."
ICML (2019).
- Timofte et al. for the DIV2K dataset
Timofte, Radu, Shuhang Gu, Jiqing Wu, and Luc Van Gool.
"Ntire 2018 challenge on single image super-resolution: Methods and results."
CVPR Workshops (2018).
This work, including the trained model, code, and dataset, is for non-commercial uses and research purposes only.
If you have any questions, feel free to contact me (maintainer) at manminhho.cs@gmail.com