r/StableDiffusion • • Oct 16 '22

Discussion Proposal to re-structure AUTOMATIC1111's webui into a plugin-extendable core (one plugin per model, functionality, etc.) to unlock the full power of open-source power

https://github.com/AUTOMATIC1111/stable-diffusion-webui/discussions/2028
76 Upvotes

42 comments sorted by

View all comments

Show parent comment

1

u/Ok_Bug1610 Oct 18 '22

Testing this now but... what are your parameters, image output size, sampling steps, and method? And are you running the latest SD-WebUi build? Because I can only max things to ~3.5GB of RAM at 1024x1024 and 150 Steps. I'm using Python 3.8. And I'm rocking a moderately decent (but somewhat sad) A2000 mobile GPU (max 75W) with 8GB VRAM. But I'm on Windows (version 10.0.19044.2130). Also, what Linux distro are you on?

2

u/[deleted] Oct 18 '22

I don't think the size, steps or sampler affect it, i assume since it's the same model being loaded in, but usually i use Euler a at 40 steps. Adding in face enhancement loads in GFPGAN/Codeformer which uses up more RAM. Using img2img or inpaint uses a bit more RAM sometimes.

It automatically updates every time i run the script.

Python 3.10.6.

PopOS (which is based on debian)

It usually uses 12 gigs at startup, then drops to 7, and builds slowly from there. I actually think the latest version may have fixed a memory leak somewhere, since it's using less than it did yesterday.

Does that medvram setting run slower? It'd be interesting to generate at 1024x1024

1

u/Ok_Bug1610 Oct 18 '22 edited Oct 18 '22

I have heard that Python 3.10 and newer uses more RAM, but I don't think that's the whole picture. Also, the more I run SD, it does appear to accumulate slightly more ram usage over time (so I agree with your memory leak hypothesis, and I think it's still somewhat present but much better if that's the case).

Also, there may be other recent improvements (I update the repo automatically on each run with a 'git pull' added to the 'webui-user.bat'). There were a lot of updates in the log recently, AUTO (and other contributors) are staying busy.

And I've notice no real difference in using "mdevram" (I think it helps but performance/time for me at least stays about the same). And honestly, I think I tried a 1024x1024 image before and had an error... it just worked today (just did it for a test as I was not hitting the memory cap you seemed to be). I don't think it produces better images though (512^2 seems "better" in my limited testing, but idk).

I wonder if it also has something to do with an emulation layer or CUDA/driver compatibility on Linux (because even at the better rate of 12gb --> 7gb, your memory usage seems x2-3 that of mine).