space-nuko / a1111-stable-diffusion-webui-vram-estimator

Show estimated VRAM usage for generation configs
MIT License
109 stars 11 forks source link

Enhancement: Add pixel count along with estimated VRAM usage. #10

Open Susanoo1337 opened 1 year ago

Susanoo1337 commented 1 year ago

Hey there, if I may, I'd like to request a tiny little feature:

Alongside "Estimated VRAM usage" in the UI it would be nice to see a total pixel count of the setting. I've found that the VRAM estimate doesn't really work, especially in img2img, but from the benchmarks I know that CUDA runs out of memory at around 4milion pixels, which has held true for 90% of my generations. (i.e. VRAM estimates ~15000/12000mb, but as long as pixel count is <4.000.000, CUDA won't run out of memory.) ((to give a very specific example, a 1145x3222 img2img will show "Estimaated VRAM usage: 14754.84 MB / 12288 MB (120.08%)" but 1145x3222=3.689.190 so CUDA will not run out of memory and the generation will finish successfully.))

So it would be really helpful to estimate my memory usage based on pixel count rather than the VRAM.