10 ms·
Show HN: InvokeAI, an open source Stable Diffusion toolkit and WebUI
Hey everyone!
Excited to be able to share the release of `InvokeAI 2.0 - A Stable Diffusion Toolkit`, an open source project that aims to provide both enthusiasts and professionals a suite of robust image creation tools. Optimized for efficiency, InvokeAI needs only ~3.5GB of VRAM to generate a 512x768 image (and less for smaller images), and is compatible with Windows/Linux/Mac (M1 & M2).
InvokeAI was one of the earliest forks off of the core CompVis repo (formerly lstein/stable-diffusion), and recently evolved into a full-fledged community driven and open source stable diffusion toolkit titled InvokeAI. The new version of the tool introduces an entirely new WebUI Front-end with a Desktop mode, and an optimized back-end server that can be interacted with via CLI or extended with your own fork.
This version of the app improves in-app workflows leveraging GFPGAN and Codeformer for face restoration, and RealESRGAN upscaling - Additionally, the CLI also supports a large variety of features:
- Inpainting
- Outpainting
- Prompt Unconditioning
- Textual Inversion
- Improved Quality for Hi-Resolution Images (Embiggen, Hi-res Fixes, etc.)
- And more...
Future updates planned included UI driven outpainting/inpainting, robust Cross Attention support, and an advanced node workflow for automating and sharing your workflows with the community.
We're excited by the release, and about the future of democratizing the ability to create. Check out the repo (https://github.com/invoke-ai/InvokeAI https://github.com/invoke-ai/InvokeAI) to get started, and join us on Discord (https://discord.gg/ZmtBAhwWhy https://discord.gg/ZmtBAhwWhy)!
- swyx 4y ago[OT] its been hard for me to trace the universe of stable diffusion forks so ive been maintaining a list here: https://github.com/sw-yx/prompt-eng#sd-major-forks https://github.com/sw-yx/prompt-eng#sd-major-forks please let me know/send PRs if i missed anything, its been a couple months so i'm overdue for a round of cleanup/reorganizing
- wyldfire 4y agoIs "dreambooth" a fork? Or another feature that has been created by composing Stable Diffusion w/something else?
- swyx 4y agoyeah you're right, more the latter. i should split it out. OG dreambooth is proprietary Google code. what everyone's using is a third party replication of it using SD
- wyldfire 4y agoI wasn't intending to challenge anything of yours. I just saw a lot of "dreambooth" activity on /r/stablediffusion. I haven't kept up on activity in the last week or two and figured you'd know what it was.
- zenlikethat 4y agoAnother feature. You can "teach" SD a new concept, e.g., a new person, with a limited number of training images.
- jayd1616 4y agoHere's another one for you: https://github.com/brycedrennan/imaginAIry https://github.com/brycedrennan/imaginAIry
- stavros 4y agoImaginairy is great.
- hexomancer 4y agoShameless plug: I was frustrated with the poor UI of notebook-based frontends so I wrote a desktop version here: https://github.com/ahrm/UnstableFusion https://github.com/ahrm/UnstableFusion . Here is a video of some of its features: https://www.youtube.com/watch?v=XLOhizAnSfQ&t=1s https://www.youtube.com/watch?v=XLOhizAnSfQ&t=1s
- hleszek 4y agoI see you've got my https://github.com/leszekhanusz/diffusion-ui https://github.com/leszekhanusz/diffusion-ui gui but it seems to be linked to a completely unrelated face-swapping interface? And in communities, you can probably add https://stablehorde.net https://stablehorde.net
- swyx 4y agouhhh... copy paste brainfart sorry. thanks for correction
- capableweb 4y agoI'm personally working on a UI as well, that is using InvokeAI :) It has a bit of a different focus, namely organization of generated images and facilitating generating a lot of images quickly via randomization. Here is the current page for it: https://patreon.com/auto_sd_workflow https://patreon.com/auto_sd_workflow Currently expanding it a lot with some fun features: - multi-gpu support (first UI that would support that I think) - no-click installer (installs everything when you start it up) that works on Windows, Linux and macOS - A cloud version where you can "rent" access to the UI + very powerful GPU instances without having to run anything locally yourself. Been waiting to submitting it all to HN as a Show HN but have to wait a bit for everything to get into place first :)
- swyx 4y agosince its paid, i'd classify you as a distro :) https://github.com/sw-yx/prompt-eng/blob/main/README.md#sd-distros https://github.com/sw-yx/prompt-eng/blob/main/README.md#sd-d...
- capableweb 4y agoYes, that makes sense :)
- grosswait 4y agoMaybe I missed it but didn’t see https://github.com/divamgupta/diffusionbee-stable-diffusion-ui https://github.com/divamgupta/diffusionbee-stable-diffusion-...
- swyx 4y agoi have diffusionbee.com
- hafriedlander 4y agoSince everyone's jumping on the plug wagon, allow me to throw on my project, www.stablecabal.org. We've got a GRPC server that's backwards compatible with the official grpc.stability.ai but adds advanced features, a Flutter based infinite canvas web client in heavy development, a Discord server and a Krita & Photoshop plugin (all except the last are open source under various licenses). The outpainting the server supports is (IMHO) the best I've seen, and recently got some a tiny glimpse of attention when combined with the Photoshop plugin - https://twitter.com/NicolayMausz/status/1577767106384433156 https://twitter.com/NicolayMausz/status/1577767106384433156
- swyx 4y agogreat submission, thank you. god its so hard to keep on top of who is doing what. am reworking my readme now with all the updates
- westoncb 4y agoHere's a cross-platform desktop GUI[0] for img2img/txt2img that takes a unique angle by remaining independent of specific models/scripts, though it was originally designed to work with Stable Diffusion. [0] https://github.com/westoncb/generation-q https://github.com/westoncb/generation-q
- cmdr2 4y agohttps://github.com/cmdr2/stable-diffusion-ui https://github.com/cmdr2/stable-diffusion-ui is pretty popular, and is a 1-click installer for Win and Linux (Mac coming soon). Quite a lot of features, and well-liked by users for its easy-to-install and user-friendly GUI.
- KaoruAoiShiho 4y agoIs there anything new here that might interest an existing user of auti's gui to switch?
- sophrocyne 4y agoTo be fair- Auto has been acquiring features at an insane clip (recently getting banned from the SD discord for accusations of code theft lol) I think Invoke is competitive for now, but biggest advantage is an improved UX, and a large community with an ambitious roadmap focused more on enthusiasts/pros. I’d give it a whirl and see where you end up preferring to do your SD projects :)
- KaoruAoiShiho 4y agoOh I see that my comment might be interpreted as snarky, I was literally just asking to please list the stuff that are new or different cause that would be very helpful for everyone.
- sophrocyne 4y agoOh, no snark interpreted! Very valid question. I legitimately think the answer is - - Experimental/novel SD features, Automatic typically has them first - Better UI/UX and exploration/gallery workflows, Invoke. From a feature perspective, both have their own flavor of certain features. Goal of Invoke is to eventually have prompt/concept library, a node-based workflow UI (with the ability to share techniques), etc. It’s kind of a - switch if you want a better UX now; keep an eye on it if you want new workflow solutions long term.
- hleszek 4y agoOr you can stay on automatic1111 and use https://diffusionui.com/b/automatic1111 https://diffusionui.com/b/automatic1111 for better UX.
- nikkwong 4y agoOne thing is that invoke-ai can be run via CLI or possibly programatically. I haven't found a good way to do that with the automatic GUI. Personally, I've also found features in automatic to be buggy. For example, batching seems to always break the UI for me personally. With the invoke-ai fork, I can run the CLI and produce images all night if I want to. The bees knees would be being able to use automatic as a CLI or with some programmatic interface, because it is more feature rich. But I haven't seen anything that allows me to do that yet, so I'm stuck to its clunky UI or to use invoke-ai.
- nohat 4y agoI've been using a modified version of lsteins fork since almost the beginning. Recommended! It does lack some of the features of eg automatic1111, but it has good cli, and actually has a license, which is pretty important (as novelai has learned).
- cercatrova 4y agoSpeaking of SD, I wonder if 1.4 will be the last truly open release as Emad said 1.5 would release a while ago but it's been held up for "compliance" reasons. Maybe they got legal threats due to using artists' works and stock images. If so, that would be sad to see it. In a way it reminds me of people who make unofficial remakes of games but get cease and desists if they show gameplay while in development. The correct move is to fully develop the game and release it, then if you get C&Ds, too late, the game is already available to download.
- sophrocyne 4y agoMy take is that the “genie is out of the bottle” Single source “massive models” may be more difficult to get out, but Emad said they’re working in licensing a ton of content to train future models. Even then, anyone can train new models now - The output from Dreambooth and Textual Inversion are already impressive, and seem like just the beginning. Going to be an interesting road ahead.
- cmxch 4y agoDefinitely is out of the bottle, especially when training capable cards are getting within reach of regular people. Sort of hinted at it upthread, but would be interesting if this eventually brings competition to the GPU compute space (AMD, Intel?) .
- judge2020 4y agoJust train on the output of existing models minus any photos with watermarks - being twice removed is sure to make it even harder to claim copyright :)
- jeffparsons 4y agoQuestion from an ML-illiterate: Are there known ways the training for these models could be distributed/decomposed? E.g. SETI-style distribution of a homogenous centrally-defined task, or — much more exciting — recombination of several different models / sets of weights? (I'm just throwing words around here without really understanding them.) I'm imaging a world in which one group of enthusiasts could work together to train a model on all images on Wikipedia, another group could work on training a model that understands hands really well, and then later yet another group could combine the work of the other two without doing all that training from scratch. Is that even remotely plausible?
- cmxch 4y agoHow hard of a requirement is the NVidia graphics chip? Polaris era AMD chips do work decently at the 4gb level (although a bit finicky) and Navi/Big Navi AMD cards work reasonably well with modern ROCm.
- pja 4y agoStable Diffusion works for me with a Polaris GPU. Had to compile my own local copy of Tensorflow to use it, but everything runs.
- cmxch 4y agoWhich documentation/build environment are you using? I’m using Ubuntu(to follow what AMD has for ROCm) and building the entirety of (gfx803 patched) ROCm from source. It works with some forks but not others.
- MayeulC 4y agoI am in the same boat with a gfx03 card. What patch did you use? The ones here? https://github.com/xuhuisheng/rocm-build https://github.com/xuhuisheng/rocm-build I also tried to compile pytorch with its Vulkan backend, but ended throwing the towel as LDFLAGS are a mess to get right (I successfully compiled it, but that was only part of the build chain, and decided I had better things to spend time on). I wonder how that would perform; ncnn works pretty decently.
- pja 4y agoI did try that, but I don’t think the pytorch Vulkan backend is complete enough. I never did get a working install going down that route though, so I could be wrong.
- cmxch 4y agoYes. I went through their build instruction shell scripts with some issues but it did work as below: It works with an older fork that has img2img / txt2img separated from each other, but nothing else did. When you built it, you did at least source the env.sh to pick up the build environment that it needed?
- iFire 4y agoCan you make the ui InvokeAI as easy to install as running a Windows 11 command line script? I couldn't get it to work following https://invoke-ai.github.io/InvokeAI/installation/INSTALL_WINDOWS/ https://invoke-ai.github.io/InvokeAI/installation/INSTALL_WI... Similar to https://github.com/cmdr2/stable-diffusion-ui/releases/tag/v2.16 https://github.com/cmdr2/stable-diffusion-ui/releases/tag/v2...
- sophrocyne 4y agoOne click install is a goal, we just need a contributor who is confident taking it on as a project.
- cmdr2 4y agoHi, I'm the author of the cmdr2 UI and installer (that iFire linked to). I'd be happy to contribute the 1-click installer used by my project. It's a battle-hardened installer (over 100k installations on all kinds of PCs and networks), and I'm finishing up a rewrite in python, so that the installer code is easier to maintain for others. I'd be happy to submit a PR to your project, if you're interested in using it. I actually got it working with your project a few weeks ago, so I know it works with your repo. I've opened a github issue as well, so we can talk there if you'd like: https://github.com/invoke-ai/InvokeAI/issues/1042 https://github.com/invoke-ai/InvokeAI/issues/1042
- paulirish 4y agoPSA: You can email support@github to ask them to "detach my repo as a fork", in case the repo has matured so much it shouldn't have the "forked from …" treatment.
- suyash 4y agoThat's all good but it's nice to give credit where credit is due. I like how they do it in the README.
- lawik 4y agoOh, I used the dreeam.py script to back a Telegram bot. It later ended up in my demo for my talk Chat Bots as User Interfaces (with Elixir): https://www.youtube.com/watch?v=DFGHaER6_j4 https://www.youtube.com/watch?v=DFGHaER6_j4 I primarily used the InvokeAI release because I found it was easy to get going with on Linux and then it was simple enough to hack around with. Also the first tool I've ever used where I've rode on the ragged edge of what my 3070 is okay with. I've had graphical glitches due to occupying all the video memory (KDE doesn't like it). I've had to quit apps to make it work. Thanks for making a useful thing of all this Stable Diffusion stuff. I've enjoyed it.
- neilv 4y agoNice! lstein is the SD fork that I ended up using, and I'm delighted to see it evolve into InvokeAI and keep getting better.
- pdntspa 4y agoMin requirements say 12gb, I take it this doesn't have the optimizations that automatic1111 has for <8gb cards?
- capableweb 4y agoYou can run it with lower VRAM for sure, up until some weeks ago, I was using that repository with a 11GB card.
- pja 4y agoYeah. Stable diffusion runs fine on my 8gb Polaris card (rx580) & I've heard of forks that will let you run it in 6 or even 4gb VRAM at a small cost in render time.
- teolandon 4y agoIt says 12GB RAM, not VRAM. Right above that it says that it can work on 4GB VRAM cards.
- cmsj 4y agoYay! I built an IRC bot for SD using lstein's repo because it was the first one that I could get to work reliably on M1, so I'm really glad to see the process continue really well with InvokeAI!
- Timwi 4y agoSounds awesome! Unfortunately, it says that it requires a GPU. Please consider making it accessible to people without a GPU, for example using OpenVino like this (command line only) project does: https://github.com/bes-dev/stable_diffusion.openvino https://github.com/bes-dev/stable_diffusion.openvino Thanks!
- hleszek 4y agoThose who don't have a GPU could use the Stable Horde: https://stablehorde.net https://stablehorde.net
- geuis 4y agoWhat you're asking for isn't entirely possible for local installs. Yes, you can run SD on a cpu, but each image takes minutes at a time vs seconds via gpu. For example, it's not possible to run SD on my 2 year old 16 intel MacBook Pro. This is because PyTorch doesn't have support for the slightly older AMD gpu on board. There's a newer framework called RocM for AMD cards that allows them to work with recent versions of PyTorch. Given all that, the requirements to have a Nvidia card is entirely acceptable, and for the most part a technical requirement.
- nullc 4y agoMinutes isn't really that big a deal though, one could give it a list of prompts to round-robin through and come back in the morning to a huge collection of images to explore. It's just a different workflow. Ironically, cpu support would be faster for me (in terms of throughput, at least) because I have on the order of a thousand zen cores put only a couple CUDA compatible GPUs with enough ram to run SD.
- Timwi 4y ago> What you're asking for isn't entirely possible for local installs. The project I linked to does it, so it's clearly possible. I didn't ask for speed, I only ask to be able to run it at all.
- tehsauce 4y agoA Shameless plug, if anyone is interested in building apps using stable diffusion and wants to keep things as cheap as possible, I built a very user-friendly API that is 1/4 the cost of the official stable diffusion API. There is also a free demo. You can try it out: https://computerender.com https://computerender.com.
- capableweb 4y agoThe page at https://computerender.com/cost.html https://computerender.com/cost.html has the title "How is computerender 4x cheaper than other services hosting Stable Diffusion?" but doesn't actually explain how/why it is cheaper, just that "crowd-sourced servers are much more difficult to work" without elaborating on how what you're doing is different than that. Care to shine some light on it? Using something like runpod/vast.ai would be my guess?
- tehsauce 4y agoHi! Your guess is correct. I monitor prices on vast.ai and runpod to get the best possible GPU power per dollar. I updated the link you mentioned with some of this info!
- gernb 4y agoThis is great but it requires lots of "geek" (installing dependencies, borking your system with brew, etc...) Vs DiffusionBee which just works https://diffusionbee.com/ https://diffusionbee.com/ Maybe the two projects can merge?
- pdntspa 4y agoI am super stoked to see all these Stable Diffusion forks floating around, and I don't want to shit on the authors and their work that hard, but I swear the installation and packaging of these things is INSANE. * Every single one of these seems to be a web UI, when this is desktop software that needs a desktop computer or workstation to run. Have we all collectively forgotten how to program PyGTK? * Model files always go in the code repo. Have we forgotten how home folders work or what their purpose is? At the very least this one instructs you to make a shortcut/symlink if you don't want to copy the ckpt file yet again * On that note, everything is autodownloaded to wherever the hell the programmer wants (once again, usually in the code repo itself). I must have four or five different copies of ESRGAN, and I spent a bunch of time monkeying around with automatic1111's fork trying to get it to correctly see everything when I ripped out the models folder and symlinked one in from a different place on my hard drive. To the authors: can you all please get together and standardize some of this stuff? Models should go in user's homefolders, or at a customizable location, and NOT within the scope of stuff that can be touched by git pull. (Doing so causes git to freak out in many circumstances) The breakneck pace of innovation here is awesome, but it feels like all gas no brakes on the usability front. In the Bad Old Days(tm) you ran an install script which generates a desktop icon and you click that to run it. Meanwhile with this, on Windows, one has to open an anaconda prompt, activate the anaconda venv (or whatever it is), then manually invoke the whole thing with 'python scripts/invoke.py --web'. And if there's a one-click install script included (which invoke doesn't, but I am not knocking it for this!), half the time they seem to try and pull down the entire world all over again (a la sd-webui). Like I get this need to make it easy to use, but it's like c'mon, there's is existing convention for all these things. Folks, please follow it! If I had a wishlist, or the wherewithal to fork my own version, it would have: * an actual GUI made with an actual windowing toolkit. I don't know why the hell everyone is so afraid of GTK, but I would use that. pyGTK is pretty simple IME, you can even read the C++ docs and it all maps over really nice to python. It doesn't need to be pretty! * configurable model locations, preferably in an agreed-upon standardized hierarchy * a standardized way of embedding prompt data into the PNG, a la automatic1111 * an uncomplicated but not overly optimistic setup process. An install.py and run.py, both with sensible defaults so that you don't need any command-line switches to run it except for special circumstances, and if it wants to autodownload updates then CHECK WITH ME FIRST! And preferably one that doesn't try to move my entire world (heres looking at you, sd-webui). And it will load the venv/conda environment for me. And yes, for all the "put your money where your mouth is", I've been thinking about forking. But I don't know if I have the time or energy to keep up with all the developments in this space. But hey you never know...
- hda2 4y agoWhat about safety filters? All the safety filters in the SD interfaces/services I used so far are too false-positive happy. Can these filters be disabled or at least toned down in InvokeAI? If so, how easily?
- capableweb 4y agoIt ships without any filters.
- lucasfcosta 4y agoThis is much needed. Even for a software engineer like me, it was quite cumbersome to use Stable Diffusion locally without such an UI. I feel like there's just so much to improve though. Maybe SD is the definitive proof that one single feature can trickle down into many others just by adding good UI on top of it.
- sophrocyne 4y agoLuckily, the team has a pretty jampacked roadmap. This is v1 of the full WebUI.
- ionwake 4y agoI was unable to get this to run on the Mac M1 over the last week - has anyone here had any success?
- wokwokwok 4y agoYes. File an issue of it’s not working for you; it’s working fine for me. (See for example https://github.com/invoke-ai/InvokeAI/issues/1021 https://github.com/invoke-ai/InvokeAI/issues/1021 ; if you had a previous install, delete it entirely)
- ionwake 4y agoThank you for the reply , I already did must be my setup.
- Uke 4y agoHow good are solutions like stable diffusion at inpainting nowadays? What about the watermarks of getty et at that have been part of some of dall-e 2.0 images. Could one feasably remove such watermarks or stuff like a white grid array with these solutions? So how convincing are these solutions in the worst case is what i am asking.