{"id":16835957,"url":"https://github.com/xingangpan/deep-generative-prior","last_synced_at":"2025-04-05T08:06:35.176Z","repository":{"id":63336854,"uuid":"251384067","full_name":"XingangPan/deep-generative-prior","owner":"XingangPan","description":"Code for deep generative prior (ECCV2020 oral)","archived":false,"fork":false,"pushed_at":"2023-07-04T03:58:21.000Z","size":85769,"stargazers_count":498,"open_issues_count":4,"forks_count":70,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-03-29T07:05:23.645Z","etag":null,"topics":["deep-learning","gan","generative-adversarial-network","image-manipulation","image-prior","image-restoration"],"latest_commit_sha":null,"homepage":"https://arxiv.org/abs/2003.13659","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/XingangPan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-03-30T17:50:10.000Z","updated_at":"2025-03-27T15:08:51.000Z","dependencies_parsed_at":"2024-10-26T21:15:04.808Z","dependency_job_id":"b4ba1703-f462-4525-8ee5-2447446280e8","html_url":"https://github.com/XingangPan/deep-generative-prior","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XingangPan%2Fdeep-generative-prior","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XingangPan%2Fdeep-generative-prior/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XingangPan%2Fdeep-generative-prior/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XingangPan%2Fdeep-generative-prior/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/XingangPan","download_url":"https://codeload.github.com/XingangPan/deep-generative-prior/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247305933,"owners_count":20917208,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["deep-learning","gan","generative-adversarial-network","image-manipulation","image-prior","image-restoration"],"created_at":"2024-10-13T12:11:51.922Z","updated_at":"2025-04-05T08:06:35.151Z","avatar_url":"https://github.com/XingangPan.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Deep Generative Prior (DGP)\n\n### Paper\n\nXingang Pan, Xiaohang Zhan, Bo Dai, Dahua Lin, Chen Change Loy, Ping Luo, \"[Exploiting Deep Generative Prior for Versatile Image Restoration and Manipulation](https://arxiv.org/abs/2003.13659)\", ECCV2020 (**Oral**)  \n\nVideo: https://youtu.be/p7ToqtwfVko\u003cbr\u003e\n\n### Demos\n\nDGP exploits the image prior of an off-the-shelf GAN for various image restoration and manipulation.\n\n**Image restoration**:\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"data/restoration.gif\", width=\"900\"\u003e\n\u003c/p\u003e\n\n**Image manipulation**:\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"data/manipulation.gif\", width=\"800\"\u003e\n\u003c/p\u003e\n\nA **learned prior** helps **internal learning**:\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"data/windows.png\", width=\"900\"\u003e\n\u003c/p\u003e\n\n### Requirements\n\n* python\u003e=3.6\n* pytorch\u003e=1.0.1\n* others\n\n    ```sh\n    pip install -r requirements.txt\n    ```\n\n### Get Started\n\nBefore start, please download the pretrained BigGAN at [Google drive](https://drive.google.com/drive/folders/1buQ2BtbnUhkh4PEPXOgdPuVo2iRK7gvI?usp=sharing) or [Baidu cloud](https://pan.baidu.com/s/10GKkWt7kSClvhnEGQU4ckA) (password: uqtw), and put them to `pretrained` folder.\n\nExample1: run image colorization example:\n    \n    sh experiments/examples/run_colorization.sh   \n\nThe results will be saved in `experiments/examples/images` and `experiments/examples/image_sheet`.\n\nExample2: process images with an image list:\n    \n    sh experiments/examples/run_inpainting_list.sh   \n\nExample3: evaluate on 1k ImageNet validation images via distributed training based on [slurm](https://slurm.schedmd.com/):\n\n    # need to specifiy the root path of imagenet validate set in --root_dir\n    sh experiments/imagenet1k_128/colorization/train_slurm.sh   \n\nNote:  \n\\- BigGAN needs a class condition as input. If no class condition is provided, it would be chosen from a set of random samples.  \n\\- The hyperparameters provided may not be optimal, feel free to tune them.  \n\n### Acknowledgement\n\nThe code of BigGAN is borrowed from [https://github.com/ajbrock/BigGAN-PyTorch](https://github.com/ajbrock/BigGAN-PyTorch).\n\n### Citation\n\n```  \n@inproceedings{pan2020dgp,\n    author = {Pan, Xingang and Zhan, Xiaohang and Dai, Bo and Lin, Dahua and Loy, Chen Change and Luo, Ping},\n    title = {Exploiting Deep Generative Prior for Versatile Image Restoration and Manipulation},\n    booktitle = {European Conference on Computer Vision (ECCV)},\n    year = {2020}\n}\n\n@ARTICLE{pan2020dgp_pami,\n    author={Pan, Xingang and Zhan, Xiaohang and Dai, Bo and Lin, Dahua and Loy, Chen Change and Luo, Ping},\n    journal={IEEE Transactions on Pattern Analysis and Machine Intelligence}, \n    title={Exploiting Deep Generative Prior for Versatile Image Restoration and Manipulation}, \n    year={2021},\n    volume={},\n    number={},\n    pages={1-1},\n    doi={10.1109/TPAMI.2021.3115428}\n}\n```  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxingangpan%2Fdeep-generative-prior","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxingangpan%2Fdeep-generative-prior","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxingangpan%2Fdeep-generative-prior/lists"}