Skip to content

Conversation

stduhpf
Copy link
Contributor

@stduhpf stduhpf commented Dec 13, 2024

Forked off #454
Would also probably replace #416

  • Move the preview decoding logic from examples/cli/main.cpp to stable-diffusion.cpp
  • Image preview is disabled by default
  • Adds possibility to chose between previewing image with latent projection (as demonstrated in fast latent image preview #454), TAE, or VAE
  • Adds possibility to load TAE for preview only (decode final image with VAE)
  • Default image preview path is preview.png

Related to #354, if the user uses an image viewer that updates its render when the image file changes, then it's possible to see the progress in real time.

@stduhpf stduhpf force-pushed the image-preview branch 2 times, most recently from bab1323 to d235ded Compare December 29, 2024 21:02
@wandbrandon
Copy link

+1 for this in main, great work!

@phil2sat
Copy link

I really would like to get this on master, problem i used it a lot but it doesn't build against current master.

@stduhpf
Copy link
Contributor Author

stduhpf commented Oct 13, 2025

Thanks for the heads up, I'll try to look into resolving these conflicts this week.

@stduhpf
Copy link
Contributor Author

stduhpf commented Oct 15, 2025

@phil2sat it builds now. I have only tried with sd1.5 so far, but it seems to work fine.

@stduhpf
Copy link
Contributor Author

stduhpf commented Oct 15, 2025

Works with qwen image (looks like qwen-image's VAE is almost identical to wan2.1's, not just the architecture, but the latent space too)

@phil2sat
Copy link

Can confirm, works. Even with qwen-image.

Huge Problem is progress on master is so fast, i had to manually patch it to merge, only a couple of hours later.

@leejet, please add this feature, its so essential for testing, debugging. On new models, samplers, schedulers i always watch the generation live, so i can exactly see on what step goes something wrong.

Actually i have a problem with qwen-image-edit on ComfyUI. With step-5 something gets weird with my workflow, without preview this is impossible to track.

I know with a 5K $ GPU just wait some seconds, but if every step needs 30s, every preview shows when to abort generation to safe power and time.

@leejet
Copy link
Owner

leejet commented Oct 16, 2025

When the pending issue is resolved, I will merge this pull request.

@phil2sat
Copy link

@leejet, please...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants