{"id":24864038,"url":"https://github.com/outofai/stableface","last_synced_at":"2025-04-05T09:06:02.115Z","repository":{"id":246666424,"uuid":"821733564","full_name":"OutofAi/StableFace","owner":"OutofAi","description":"Build your own Face App with Stable Diffusion 2.1","archived":false,"fork":false,"pushed_at":"2025-01-10T00:05:21.000Z","size":1864,"stargazers_count":150,"open_issues_count":0,"forks_count":15,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-29T08:05:19.359Z","etag":null,"topics":["attention-is-all-you-need","ddim-inversion","diffusion-models","faceapp","generative-ai","generativeai","image-editing","image-editing-app","image-reconstruction","photo-editing-app","pivotal-inversion","prompt2prompt","sampling-distribution","stable-diffusion","stable-diffusion-2-1","stableface","transformers"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","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/OutofAi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"github":null,"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"lfx_crowdfunding":null,"polar":null,"buy_me_a_coffee":"outofai","custom":null}},"created_at":"2024-06-29T09:28:53.000Z","updated_at":"2025-03-12T14:35:44.000Z","dependencies_parsed_at":"2024-06-29T14:37:08.567Z","dependency_job_id":"c45757aa-8cd8-4ae5-98d5-95550f8fad41","html_url":"https://github.com/OutofAi/StableFace","commit_stats":null,"previous_names":["outofai/stableface"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OutofAi%2FStableFace","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OutofAi%2FStableFace/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OutofAi%2FStableFace/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OutofAi%2FStableFace/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OutofAi","download_url":"https://codeload.github.com/OutofAi/StableFace/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247312077,"owners_count":20918344,"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":["attention-is-all-you-need","ddim-inversion","diffusion-models","faceapp","generative-ai","generativeai","image-editing","image-editing-app","image-reconstruction","photo-editing-app","pivotal-inversion","prompt2prompt","sampling-distribution","stable-diffusion","stable-diffusion-2-1","stableface","transformers"],"created_at":"2025-01-31T23:42:25.357Z","updated_at":"2025-04-05T09:06:01.755Z","avatar_url":"https://github.com/OutofAi.png","language":"Jupyter Notebook","funding_links":["https://buymeacoffee.com/outofai","https://www.buymeacoffee.com/outofai"],"categories":[],"sub_categories":[],"readme":"\n# StableFace\n\n\u003ca href=\"https://www.buymeacoffee.com/outofai\" target=\"_blank\"\u003e\u003cimg src=\"https://img.shields.io/badge/-buy_me_a%C2%A0coffee-red?logo=buy-me-a-coffee\" alt=\"Buy Me A Coffee\"\u003e\u003c/a\u003e\n[![Twitter](https://img.shields.io/twitter/url/https/twitter.com/cloudposse.svg?style=social\u0026label=Out%20of%20AI)](https://twitter.com/OutofAi)\n[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/CH7_stable_face.ipynb)\n\n## Build your own Face App with Stable Diffusion 2.1 Base\nhttps://github.com/OutofAi/StableFace/assets/145302363/6e9e414a-f3da-47ca-9ad6-61b4bbf9e198\n\n\nA set of simple notebooks to create a clear understanding on Stable Diffusion aspects like sampling, architecture, CFG, attention layers, inverse scheduler, pivotal inversion, image reconsutrction and prompt2prompt editting which we utilise to achieve hyperreaslitic results to edit any real-world face and build a pipeline to build your own face app.\n\n(You can skip to Chapter 7 if you are already familiar with the basics of SD)\n\n|||\n|:--------|:---------------:|\n| *Chapter 1: Sampling but not Inference*\u003cbr\u003e A Simple example of how to create/sample an image with diffusers pipeline\u003cbr\u003e\u003cbr\u003e | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/CH1_sampling.ipynb) |\n| *Chapter 2: Stable Diffusion Dissected*\u003cbr\u003e Exploring the individual elements that results in image generation\u003cbr\u003e\u003cbr\u003e | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/CH2_breakdown.ipynb) |\n| *Chapter 3: Spicing it up with CFG*\u003cbr\u003e Exploring Classifier-Free Guidance to enhance image generation.\u003cbr\u003e\u003cbr\u003e | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/CH3_CFG.ipynb) |\n| *Chapter 4: Attention, Please!*\u003cbr\u003e Overriding attention layer tomanipulate image generation process\u003cbr\u003e\u003cbr\u003e | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/CH4_attention_breakdown.ipynb) |\n| *Chapter 5: Attention Switcheroo*\u003cbr\u003e Shared cross-attention layers between multiple images.\u003cbr\u003e\u003cbr\u003e | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/CH5_attention_replace.ipynb) |\n| *Chapter 6: Reality Check*\u003cbr\u003e DDIM-inversion and pivotal tuning for accurate image reconstruction.\u003cbr\u003e\u003cbr\u003e | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/CH6_reconstruction.ipynb) |\n| *Chapter 7: FaceApp, Who?*\u003cbr\u003e Synthesise learnings to create an advanced facial feature editing system.\u003cbr\u003e\u003cbr\u003e | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/CH7_stable_face.ipynb) |\n\n|||\n|:--------|:---------------:|\n| *Appendix 1: FaceApp, XL!!*\u003cbr\u003e SD XL based face editing with corrective actions.\u003cbr\u003e\u003cbr\u003e | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/OutofAi/StableFace/blob/main/APDX1_stable_face_XL.ipynb) |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foutofai%2Fstableface","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foutofai%2Fstableface","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foutofai%2Fstableface/lists"}