From 2bbdcc1c841850d2f21742f910f8f47d55fbe455 Mon Sep 17 00:00:00 2001 From: Xintao Date: Tue, 15 Jun 2021 20:02:39 +0800 Subject: [PATCH] update readme --- README.md | 14 ++++++++++---- README_CN.md | 14 ++++++++++---- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 95b82ea..ea5fcfe 100644 --- a/README.md +++ b/README.md @@ -65,14 +65,20 @@ Blind face restoration usually relies on facial priors, such as facial geometry Download pre-trained models: [GFPGANv1.pth](https://github.com/TencentARC/GFPGAN/releases/download/v0.1.0/GFPGANv1.pth) -> wget https://github.com/TencentARC/GFPGAN/releases/download/v0.1.0/GFPGANv1.pth -P experiments/pretrained_models +```bash +wget https://github.com/TencentARC/GFPGAN/releases/download/v0.1.0/GFPGANv1.pth -P experiments/pretrained_models +``` -> python inference_gfpgan_full.py --model_path experiments/pretrained_models/GFPGANv1.pth --test_path inputs/whole_imgs -> python inference_gfpgan_full.py --model_path experiments/pretrained_models/GFPGANv1.pth --test_path inputs/cropped_faces --aligned +```bash +python inference_gfpgan_full.py --model_path experiments/pretrained_models/GFPGANv1.pth --test_path inputs/whole_imgs + +# for aligned images +python inference_gfpgan_full.py --model_path experiments/pretrained_models/GFPGANv1.pth --test_path inputs/cropped_faces --aligned +``` ## :computer: Training -We provide a complete training for GFPGAN.
+We provide complete training codes for GFPGAN.
You could improve it according to your own needs. > python -m torch.distributed.launch --nproc_per_node=4 --master_port=22021 train.py -opt train_gfpgan_v1.yml --launcher pytorch diff --git a/README_CN.md b/README_CN.md index 95b82ea..ea5fcfe 100644 --- a/README_CN.md +++ b/README_CN.md @@ -65,14 +65,20 @@ Blind face restoration usually relies on facial priors, such as facial geometry Download pre-trained models: [GFPGANv1.pth](https://github.com/TencentARC/GFPGAN/releases/download/v0.1.0/GFPGANv1.pth) -> wget https://github.com/TencentARC/GFPGAN/releases/download/v0.1.0/GFPGANv1.pth -P experiments/pretrained_models +```bash +wget https://github.com/TencentARC/GFPGAN/releases/download/v0.1.0/GFPGANv1.pth -P experiments/pretrained_models +``` -> python inference_gfpgan_full.py --model_path experiments/pretrained_models/GFPGANv1.pth --test_path inputs/whole_imgs -> python inference_gfpgan_full.py --model_path experiments/pretrained_models/GFPGANv1.pth --test_path inputs/cropped_faces --aligned +```bash +python inference_gfpgan_full.py --model_path experiments/pretrained_models/GFPGANv1.pth --test_path inputs/whole_imgs + +# for aligned images +python inference_gfpgan_full.py --model_path experiments/pretrained_models/GFPGANv1.pth --test_path inputs/cropped_faces --aligned +``` ## :computer: Training -We provide a complete training for GFPGAN.
+We provide complete training codes for GFPGAN.
You could improve it according to your own needs. > python -m torch.distributed.launch --nproc_per_node=4 --master_port=22021 train.py -opt train_gfpgan_v1.yml --launcher pytorch