After some quick tests compress_level=4 seems to give the best compression performance ratio for stable diffusion images. It's 10x faster than max compression for an image size increase of only 2.5%.
35 KiB
35 KiB