{"id":21216729,"url":"https://github.com/mingtaoguo/singan_pytorch","last_synced_at":"2025-09-11T17:23:47.856Z","repository":{"id":168646427,"uuid":"263552632","full_name":"MingtaoGuo/SinGAN_Pytorch","owner":"MingtaoGuo","description":"Reimplementing the paper \"SinGAN: Learning a Generative Model from a Single Natural Image\"","archived":false,"fork":false,"pushed_at":"2023-05-26T04:11:05.000Z","size":17078,"stargazers_count":5,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-05T13:11:18.584Z","etag":null,"topics":["harmonization","pytorch-implementation","singan"],"latest_commit_sha":null,"homepage":null,"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/MingtaoGuo.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-05-13T07:09:02.000Z","updated_at":"2024-08-12T22:09:30.000Z","dependencies_parsed_at":"2023-07-21T16:47:22.597Z","dependency_job_id":null,"html_url":"https://github.com/MingtaoGuo/SinGAN_Pytorch","commit_stats":null,"previous_names":["mingtaoguo/singan_pytorch"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/MingtaoGuo/SinGAN_Pytorch","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MingtaoGuo%2FSinGAN_Pytorch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MingtaoGuo%2FSinGAN_Pytorch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MingtaoGuo%2FSinGAN_Pytorch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MingtaoGuo%2FSinGAN_Pytorch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MingtaoGuo","download_url":"https://codeload.github.com/MingtaoGuo/SinGAN_Pytorch/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MingtaoGuo%2FSinGAN_Pytorch/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264573169,"owners_count":23630435,"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":["harmonization","pytorch-implementation","singan"],"created_at":"2024-11-20T21:55:24.680Z","updated_at":"2025-07-10T11:32:31.338Z","avatar_url":"https://github.com/MingtaoGuo.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SinGAN_Pytorch\nReimplementing the paper \"SinGAN: Learning a Generative Model from a Single Natural Image\"\n# Requirements\n1. python3\n2. torch1.1.0\n3. pillow\n4. numpy\n5. imageio\n# Training phase what you need to do\n1. Modifying the image path in \"train.py\"\n2. Executing the file \"train.py\"\n# Testing phase what you can do\n1. Random sample from single image, \"random_sample_from_single.py\"\n2. Harmonization, \"harmonization.py\"\n3. Creating an animation, \"animation.py\"\n4. Converting painting to image, \"harmonization.py\"\n# Results\n|Raw img|random sampled|animation|\n|-|-|-|\n|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/star_raw.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/star.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/star.gif)|\n|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/huashan_raw.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/huashan.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/huashan.gif)|\n|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/lantingjixu_raw.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/lantingjixu.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/lantingjixu.gif)|\n\n### Harmonization\n|Raw img|n=1|n=2|n=3|n=4|\n|-|-|-|-|-|\n|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/star_cat.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/harmonization/1.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/harmonization/2.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/harmonization/3.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/harmonization/4.jpg)|\n\n|Raw img|n=5|n=6|n=7|n=8|\n|-|-|-|-|-|\n|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/star_cat.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/harmonization/5.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/harmonization/6.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/harmonization/7.jpg)|![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/harmonization/8.jpg)|\n# Problems\nThe results of this code still have some problems. Sometimes, it generates the distortion image. I really don't know how to fix it.\n![](https://github.com/MingtaoGuo/SinGAN_Pytorch/blob/master/IMGS/problem.jpg)\n\n# Acknowledgement\nThanks for the [source code](https://github.com/tamarott/SinGAN) of SinGAN, it's very helpful!\n# Author\nMingtao Guo\n\nXi'an University of technology\n\n# Reference\n[1]. Shaham, Tamar Rott, Tali Dekel, and Tomer Michaeli. \"Singan: Learning a generative model from a single natural image.\" Proceedings of the IEEE International Conference on Computer Vision. 2019.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmingtaoguo%2Fsingan_pytorch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmingtaoguo%2Fsingan_pytorch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmingtaoguo%2Fsingan_pytorch/lists"}