https://github.com/ahrm/UnstableFusion Skip to content Toggle navigation Sign up * Product + Actions Automate any workflow + Packages Host and manage packages + Security Find and fix vulnerabilities + Codespaces Instant dev environments + Copilot Write better code with AI + Code review Manage code changes + Issues Plan and track work + Discussions Collaborate outside of code + Explore + All features + Documentation + GitHub Skills + Changelog * Solutions + By Plan + Enterprise + Teams + Compare all + By Solution + CI/CD & Automation + DevOps + DevSecOps + Case Studies + Customer Stories + Resources * Open Source + GitHub Sponsors Fund open source developers + The ReadME Project GitHub community articles + Repositories + Topics + Trending + Collections * Pricing [ ] * # In this repository All GitHub | Jump to | * No suggested jump to results * # In this repository All GitHub | Jump to | * # In this user All GitHub | Jump to | * # In this repository All GitHub | Jump to | Sign in Sign up {{ message }} ahrm / UnstableFusion Public * Notifications * Fork 4 * Star 118 A Stable Diffusion desktop frontend with inpainting, img2img and more! 118 stars 4 forks Star Notifications * Code * Issues 4 * Pull requests 0 * Actions * Projects 0 * Security * Insights More * Code * Issues * Pull requests * Actions * Projects * Security * Insights ahrm/UnstableFusion This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. main Switch branches/tags [ ] Branches Tags Could not load branches Nothing to show {{ refName }} default View all branches Could not load tags Nothing to show {{ refName }} default View all tags 1 branch 0 tags Code * Clone HTTPS GitHub CLI [https://github.com/a] Use Git or checkout with SVN using the web URL. [gh repo clone ahrm/U] Work fast with our official CLI. Learn more. * Open with GitHub Desktop * Download ZIP Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Launching Xcode If nothing happens, download Xcode and try again. Launching Visual Studio Code Your codespace will open once ready. There was a problem preparing your codespace, please try again. Latest commit @ahrm ahrm Update README.md ... 356bc7f Sep 23, 2022 Update README.md 356bc7f Git stats * 47 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time icons .gitignore README.md UnstableFusionServer.ipynb diffusionserver.py keys.json requirements.txt unstablefusion.py View code UnstableFusion How to run locally? How to run using colab servers? How to use? README.md UnstableFusion A Stable Diffusion desktop frontend with inpainting, img2img and more! trailer.mp4 How to run locally? 1. Install the dependencies (for example using pip). The dependencies include : * PyQt5, numpy, pytorch, Pillow, opencv-python, requests, flask, diffusers, transformers, protobuf Note that if you want to run StableDiffusion locally, you have to install pytorch with cuda enabled like this: pip install torch==1.12.1+cu113 -f https://download.pytorch.org/whl/torch_stable.html 2. Clone this repository and run python unstablefusion.py How to run using colab servers? 1. Install the dependencies (see the previous section) 2. Open this notebook and run it (you need to enter your huggingface token when asked). 3. When you run the last cell, you will be given a url like this: colab_output - Copy copy this URL. 4. Run python unstablefusion.py 5. In the runtime section, select server and enter the address you copied in the server field. Like this: using_server - Copy How to use? * You can select a box by clicking on the screen. All of your operations will be limited to this box. You can resize the box using mouse wheel. * You can erase the selected box by right clicking, or paint into it by middle clicking (the paint color can be configured using Select Color button) * To generate an image, select the destination box, enter the prompt in the prompt text field and press the Generate button (inpainting and reimagining work similarly) * You can undo/redo by pressing the undo/redo button or pressing Control+Z/Control+Shift+Z on your keyboard. In fact most other functions are bound to keys as well (you can configure them in keys.json file) * Increase Size/Decrease Size buttons adjust the size of the image by adding/removing extra space in the margins (and not by scaling, this is useful when you want to add more detail around an image) * You can open a scratchpad by pressing Show Scratchpad button. This window is capable of doing everything the main window can (using keyboard shortcuts only). The selected box in scratch pad will be mirrored and scaled into the selected box in the main window. This is useful when trying to import another generated/ local image into the main image. About A Stable Diffusion desktop frontend with inpainting, img2img and more! Resources Readme Stars 118 stars Watchers 2 watching Forks 4 forks Releases No releases published Packages 0 No packages published Contributors 2 * @ahrm ahrm * @SnekCode SnekCode Mr. Snake Languages * Jupyter Notebook 87.5% * Python 12.5% Footer (c) 2022 GitHub, Inc. Footer navigation * Terms * Privacy * Security * Status * Docs * Contact GitHub * Pricing * API * Training * Blog * About You can't perform that action at this time. You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.