r/StableDiffusion • u/amarandagasi • Oct 13 '22
Question Best Local Command-Line SD (non-optimized)?
I recently built a new rig for SD. Current windows, nice beefy specs, and an ASUS GeForce RTX 3090 Ti.
Back when I was running SD on my old PC, I was using the MSI Aero GPU with 8GB of GDDR5X and running the basujindal optimized fork of SD. Took about 2 minutes for each image.
Now, with the 3090 Ti, it takes less than 10 seconds to run the standard (non-optimized) CompVis from the HuggingFace directions and the sd-v1-4-full-ema checkpoint file. Blazingly fast. Makes a fantastic under-desk heater, as well.
My question is this: I've noticed that the basujindal has a lot of QoL tweaks that I miss...a lot. I don't want the memory optimizations, because I have 24GB of GDDR6X memory, but I do want the QoL adjustments, like automatically creating output directories based on the prompt used, naming files with the seed and sequence number versus just the next number in the directory and selecting a random seed if not specified.
Is there a "best in class" fork that I can use of CompVis (which I've heard is the reference standard), that contains these features (and maybe more?) without the optimizations required for a smaller video card memory space?
Must:
- ...be command line. Not really into GUIs.
- ...use the 24GB of GDDR in my 3090 Ti.
- ...have a decent set of QoL features and options.
- ...run locally on my PC.
- ...not be heavily "packaged" or containerized, so I can't make modifications
I don't mind doing a little work. (I'm an OG Unix/Linux systems administrator, and am used to working a little to get things to work properly.)
I know that SD is relatively new, and people are just figuring things out. I'm open to suggestions.
Thoughts?
3
u/parlancex Oct 13 '22
I'd like to suggest my own G-Diffuser (interactive) CLI. It uses haffriedlander's gRPC server backend which has a unified diffusers pipeline with memory optimizations, k diffusion samplers, state of the art latent space fourier shaped noise in/out-painting, optimized performance and xformers support for gen times of < 2 seconds per image on most hardware.
The CLI is quite fully featured and can be used to do anything that can be done with any other UIs, but also presents a polished interface and can be easily extended with user scripts as well. The system is designed as an extensible base, folks have already used it to make very elaborate automated comparison grids for parameters, models, samplers, etc.
https://github.com/parlance-zz/g-diffuser-bot
https://www.stablecabal.org
3
u/seaal Oct 13 '22
There have been so many improvements from the community on top of the CompVis initial implementation.
brycedrennan/imaginAIry is completely focused on CLI and seems to fit your criteria.
7
u/KhaiNguyen Oct 13 '22
For command line, my go-to is InvokeAI. Pretty clean pipeline and everything can be done from command line.
2
u/Light_Diffuse Oct 13 '22
I'd suggest pulling apart Automatic1111's code to bypass the UI. Most of your QoL improvements are going to be there and you'll benefit from his frenetic pace of development going forward.
2
u/[deleted] Oct 13 '22
I'm hoping to find this too. I'd much rather script out a workflow with SD and other tools than fiddle with a GUI.
2
u/This_Butterscotch798 Oct 14 '22
I know you mentioned not containerized but if you want to build something for yourself and not start from scratch, I created a repo that creates serving containers from the compvis, codeformers and realesrgan repos. It runs a local fastapi server to run txt2img, img2img, face restoration and image upscaling.
All the code is there so you can fork it and modify to your liking.
https://github.com/entrpn/serving-model-cards
0
u/[deleted] Oct 13 '22
[deleted] — view deleted comment