Commit Graph
3 Commits
Author SHA1 Message Date
scraed 391ca9625f Trim the Qwen 2.1 section to a paragraph
The section explained the VAE's channel count, the autogrow mismatch and the mask-size
measurements before saying where the example was. Keep what a reader needs: the model is
supported, transparency is inpainted too, and here is how to point it at your own picture.
The workflow's own note gets the same treatment.
2026-09-28 00:31:59 +08:00
scraed e7e8166e02 List Qwen-Image 2.1 in the features and announce it, with a before/masked/after sheet
The Features model list and the Updates log both predate the Qwen 2.1 example, so the
support was only discoverable from the table of contents. Example_31 also gets a
Comparison.png showing the original, the covered region and the result side by side,
since the new sole growing past the old outline is the part worth seeing.
2026-09-28 00:25:23 +08:00
scraed f564ee886b Add the Qwen-Image 2.1 example with transparent-background inpainting
LanPaint runs on Qwen-Image 2.1 unchanged: it is a rectified-flow model, so the
existing Flux/Qwen-Image conversions apply. Example_31 uses a text-to-image render
of its own model as the before/after, generated with a transparent background, and
keeps the inpainting mask in a separate greyscale file rather than in the picture's
alpha - 2.1's alpha channel means transparency, so overloading it would make the
two indistinguishable.

The transparency is carried into the latent and edited along with the pixels: the
2.1 VAE is 4-in/4-out (encoder.conv1 takes 4 channels, the decoder head emits 4),
and LoadImage's MASK output re-attaches through Join Image With Alpha, since that
mask is already 1 - alpha. The rebuilt sole grows past the old outline, so the
alpha in that region is generated rather than copied.

LanPaint_ImageDecode now matches the decoded channels to the source image: the 2.1
VAE always emits a 4th channel, which the merge could not broadcast. It keeps the
input's channel count, so an RGBA source comes back RGBA and an RGB source still
comes back RGB.
2026-09-28 00:25:23 +08:00