Skip to content

Instantly share code, notes, and snippets.

@woctezuma
Last active Jun 15, 2021
Embed
What would you like to do?
Google Colab: ESRGAN

Reference: https://github.com/xinntao/ESRGAN

Prepare code:

%cd /content
!git clone https://github.com/xinntao/ESRGAN.git

%cd /content/ESRGAN/models
!gdown --id 1TPrz5QKd8DHHt1k8SRtm6tMiPjz_Qene

Prepare data:

%cd /content/ESRGAN/LR

# Upload your own images to Colab, or download images from Internet
!wget https://raw.githubusercontent.com/chaofengc/PSFRGAN/master/test_dir/test_hzgg.jpg -O example.jpg
!wget https://static.boredpanda.com/blog/wp-content/uploads/2017/03/childhood-celebrities-when-they-were-young-kids-101-58bd73a65dee9__700.jpg -O Adele.jpg
!wget https://static.boredpanda.com/blog/wp-content/uploads/2017/03/childhood-celebrities-when-they-were-young-kids-4-58b80eeeefa13__700.jpg -O Julia_Roberts.jpg
!wget https://i.imgur.com/sct87xb.png - O Star_Wars_meme.png
!wget https://i.imgur.com/7gPVDg4.png -O Gabe.png

Run:

%cd /content/ESRGAN
!python test.py

Export:

!tar czvf ESRGAN.tar.gz /content/ESRGAN/results
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment