Restoration (Face Image)

操作系统:ubuntu 20.04
python:3.7
cuda: 11.1
pytorch: 1.10

安装过程:
1.安装anaconda+安装Nvidia驱动+安装cuda+安装cudnn
2.conda创建open-mmlab虚拟环境并进入
3.git clone mmediting并进入文件夹
4.pip install -r requirements.txt并pip install -v -e .
5.运行demo

python demo/restoration_face_demo.py configs/restorers/glean/glean_in128out1024_2x4_300k_ffhq_celebahq.py https://download.openmmlab.com/mmediting/restorers/glean/glean_in128out1024_4x2_300k_ffhq_celebahq_20210812-acbcb04f.pth tests/data/face/000001.png results/000001.png --upscale_factor 4

报错1:
不存在文件glean_in128out1024_2x4_300k_ffhq_celebahq.py
解决方法:
找到glean_in128out1024_4x2_300k_ffhq_celebahq.py(在上述命令中有),将其改为glean_in128out1024_2x4_300k_ffhq_celebahq.py 即可

报错2:
请先安装FaceXLib
解决方法:
pip install FaceXLib

demo运行结果:


face image demo.jpg
超分前.png
超分后.png

你可能感兴趣的:(Restoration (Face Image))