mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #3792] [Images] HIP backend: Qwen-Image-2.1-Turbo VAE decode runs out of memory from 1536x1024 upwards (--vae-tiling fixes it) #1598
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#1598
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @lbbit on GitHub (Oct 23, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/3792
Area
Engine (image generation)
Desktop app, Terminal or source?
Source build. Strata 0.1.45,
serve/server.py, Linux. The image job runsengine-image/sd-cli(stable-diffusion.cpp) with Qwen-Image-2.1-Turbo.What happened
POST /v1/images/generationswithsize=1536x1024fails;1024x1024works.The service reports:
Running
sd-clidirectly with the same arguments shows the real error above the backtrace:So the crash is not in the sampling step: sampling completes, and the abort happens in the VAE decode, when the latent is expanded into pixels and a large contiguous allocation fails.
The failure is not caused by the text model holding VRAM: it reproduces with the engine unloaded and both cards completely free (VRAM 0%).
Why 1024x1024 works and 1536x1024 does not
The VAE decode peak allocation grows with the pixel count. On one 24 GB card, with the three model files (7.6 GB Q8_0 denoiser + 5.1 GB Qwen3-VL-8B conditioner + 0.7 GB VAE) resident in VRAM, the decode has roughly 10 GB left, which is enough for 1024x1024 but not for 1536x1024.
Measured with the same model on one card (engine unloaded, both cards idle):
--vae-tiling--vae-tiling--vae-tiling(256x256 tiles) fixes every size; the images have no visible seams.Suggested fix
Add
--vae-tilingto the sd-cli arguments thattools/image/install.pywrites, the same way the Vulkan setup already does it.docs/IMAGES.mdsays:The HIP backend gets no such automatic flag, so on a 24 GB RDNA3 card the Qwen-Image-2.1-Turbo VAE decode runs out of memory from 1536x1024 upwards. It looks like the tiling (and the tile overlap) should be added for the HIP backend as well, or at least that the setup should warn when the planned resolution does not fit.
Note that
need_mibinserve/images.py(models + 2 GiB + 4 GiB per megapixel) underestimates the VAE decode peak, so 1536x1024 passes the planning check and then fails in the job. The formula or the check may want the decode peak too.Smallest steps or command that reproduce it
Exit code 134 (SIGABRT) with the out-of-memory error above. Adding
--vae-tilingmakes it succeed.Environment
backend: hip2988060a4338a5dcd94721c964a8e87003c1ac8b, ggmld25b121ce1d6ae0c7e62ad080460d9fc1e46dd93@github-actions[bot] commented on GitHub (Oct 23, 2026):
Thanks for the issue. To keep the tracker readable, every item needs an area prefix in the title and the parts of the issue form filled in. This one is missing:
Edit the issue (title and description) and this note goes away on its own. If it is still missing parts in 5 days it will be closed, which is not a rejection: fix it and comment
/reopen.Details: CONTRIBUTING.md
@github-actions[bot] commented on GitHub (Oct 28, 2026):
Closing this issue because it still did not follow the format after 5 days. That is housekeeping, not a rejection.
To bring it back: fix the title (area prefix) and the missing parts, then comment
/reopen. A check runs and reopens it, or tells you what is still missing. See CONTRIBUTING.md.--aux-cpus: helper threads on spare CPUs, +10% decode on a layer split (Linux, opt-in) #3555--adapt-async 1beside slots) #3576