fastsdcpu icon indicating copy to clipboard operation
fastsdcpu copied to clipboard

Out of memory when trying to create a large number of images

Open veikk0 opened this issue 2 years ago • 1 comments

When trying to create 25 images at 768x768 resolution and 25 inference steps, I got this error:

RuntimeError: Exception from src/inference/src/core.cpp:114:
[ GENERAL_ERROR ] Failed to allocate 70201324800 bytes of memory

It seems to be trying to allocate 70 gigs of memory at once.

The "number of images" functionality seems to work in an unintuitive way. I'd expect it to fully generate and output images one-by-one until X number of images has been reached, but instead it seems like it's trying to do it all in parallel or something.

Generating images one-by-one using the same settings works fine. I have 32 gigs of RAM and memory use only goes up to 13 GiB when generating one image at a time, so lack of memory shouldn't be a problem.

I'm using the latest git on Linux Mint 21.2.

veikk0 avatar Nov 01 '23 14:11 veikk0

yes, a batch count [one by one generation] will be great

Amin456789 avatar Nov 02 '23 18:11 Amin456789