Transparent PNG editing: mask + matte workflow tested on MiniMax-H3 vs Qwen-Image 2.1 Turbo
fuzhongkai · reddit · 2026-12-03
The TensorSharp maintainer benchmarked local diffusion models on masked editing of a transparent PNG—swapping a glowing cube for a gift box while preserving the character and reflected cyan light—on an Apple M5 Pro (48GB).
Workflow
- Three inputs: source RGBA PNG, clean close-up of the replacement object, lighting reference. Inspect references first: fingers over edges contaminated outputs on both models
- Two masks: an edit mask defines where pixels may change; a foreground matte defines opacity. MiniMax's decoder outputs RGB so it needs a supplied matte; Qwen supports native RGBA
- Preview the same PNG on dark and light backgrounds—a pale rim signals the matte extends beyond what the model drew
Timings (1254×1254, seed 0/42)
- MiniMax Q4KM, 2-step pMDM: 127s / 90s; with 512px reference floor, 52s / 44s
- Qwen Turbo Q5KS, 8-step Euler: 13.3s / 9.1s; native RGBA without matte: 10.9s / 9.0s
Verdict: MiniMax with aligned matte for final assets, Qwen native RGBA for iteration. Internal sampling sizes differ hugely (2016×2080 vs 320×320), so it's a workflow comparison, not an equal-res benchmark. Full build instructions for the TensorSharp CLI (.NET 10 + CMake) included.
More from coding & agent
- Three AI Models Disagree in a Multi-Reviewer Agent Workflow at 11 PM — kevinkern · 2026-12-03
- Claude Code 2.1.335 Release Imminent — ClaudeCodeLog · 2026-12-03
- TrajectoryStore: store each agent message once — 63x less data, 10x faster queries than OTel — CShorten30 · 2026-12-03
- Open-source BIMCraft rebuilds pricey Revit in Rust, generating full house from 58 lines — anselm · 2026-12-03
- Factory expands to Japan with KDDI as customer and Sakana AI partnership — maddiehfaulkner · 2026-12-03
- Biweekly agent self-review with a full prompt turns recurring friction into standing rules — kevinkern · 2026-12-03