From a60e80925f5dcfbef4ac55637d3ceee806f49f3e Mon Sep 17 00:00:00 2001 From: Morpheus Date: Wed, 28 Oct 2026 17:14:53 +0000 Subject: [PATCH] Add Qwen multi-reference image tests --- optimized/MultipleRef2I/README.md | 6 +-- optimized/MultipleRef2I/qwen/README.md | 50 +++++++++++++++++++++ optimized/MultipleRef2I/qwen/variables.json | 33 ++++++++++++++ optimized/MultipleRef2I/qwen/workflow.json | 19 ++++++++ optimized/STATUS.md | 1 + 5 files changed, 106 insertions(+), 3 deletions(-) create mode 100644 optimized/MultipleRef2I/qwen/README.md create mode 100644 optimized/MultipleRef2I/qwen/variables.json create mode 100644 optimized/MultipleRef2I/qwen/workflow.json diff --git a/optimized/MultipleRef2I/README.md b/optimized/MultipleRef2I/README.md index 2b34487..b859828 100644 --- a/optimized/MultipleRef2I/README.md +++ b/optimized/MultipleRef2I/README.md @@ -1,11 +1,11 @@ # MultipleRef2I workflows -Use [`flux/`](flux/) or [`flux3klein/`](flux3klein/) for multi-reference image composition. Both use the same person and scene fixtures for controlled comparison. +Use [`flux/`](flux/), [`qwen/`](qwen/), or [`flux3klein/`](flux3klein/) for multi-reference image composition. All use the same person and scene fixtures for controlled comparison. The fixed reference assets and static variables are recorded in [`variables.json`](variables.json), `person_reference.png`, and `scene_reference.png`. The test plan lives in the Flux README. Store each MultipleRef2I test under the selected model's `results/.png` and `results/.json` using the table ID as the label. Current comparison status: Flux.2 Klein has an untested optimization matrix; -FLUX.3 Klein has a planned matrix at fixed 1920×1080; no cross-model winner -has been declared. +Qwen Image 2.1 has a planned 18-row matrix; FLUX.3 Klein has a planned matrix +at fixed 1920×1080. No cross-model winner has been declared. diff --git a/optimized/MultipleRef2I/qwen/README.md b/optimized/MultipleRef2I/qwen/README.md new file mode 100644 index 0000000..f16aba6 --- /dev/null +++ b/optimized/MultipleRef2I/qwen/README.md @@ -0,0 +1,50 @@ +# Qwen Image 2.1 — MultipleRef2I + +This is the Qwen two-reference image-to-image plan. It combines the fixed +person and scene fixtures used by the other MultipleRef2I workflows. The +person reference supplies identity and appearance; the scene reference +supplies environment, lighting, perspective, and composition. + +## Workflow and fixed inputs + +- `workflow.json` — API-format workflow using two `TextEncodeQwenImage21` image inputs. +- Model: `qwen_image_2.1_int8_convrot.safetensors` +- Text encoder: `qwen3vl_8b_w4a8.safetensors` (`type=qwen_image`) +- VAE: `qwen_image_2.1_vae_bf16.safetensors` +- References: `../person_reference.png` and `../scene_reference.png` +- Output comparison target: **1920×1080** +- Seed: `310201` + +The live node contract supports `image_1` through `image_16`, so this is a +real two-reference graph rather than a duplicated single-reference test. + +## Focused matrix + +All 18 rows are currently **Planned**. Keep both references, the prompt, +resolution, and seed fixed; vary only the explicitly listed CFG, sampler, +scheduler, or steps. + +| ID | CFG | Steps | Sampler | Scheduler | Status | Purpose | +|---|---:|---:|---|---|---|---| +| Q-MR2I-01 | 3.5 | 50 | euler_cfg_pp | beta | Planned | Baseline | +| Q-MR2I-02 | 1.0 | 24 | euler_cfg_pp | beta | Planned | Low CFG | +| Q-MR2I-03 | 2.5 | 24 | euler_cfg_pp | beta | Planned | CFG comparison | +| Q-MR2I-04 | 3.5 | 24 | euler_cfg_pp | beta | Planned | CFG/steps comparison | +| Q-MR2I-05 | 4.0 | 24 | euler_cfg_pp | beta | Planned | Higher CFG | +| Q-MR2I-06 | 3.5 | 24 | euler | beta | Planned | Euler sampler | +| Q-MR2I-07 | 3.5 | 24 | euler_ancestral | beta | Planned | Ancestral sampler | +| Q-MR2I-08 | 3.5 | 24 | res_multistep | beta | Planned | RES sampler | +| Q-MR2I-09 | 3.5 | 24 | res_multistep_cfg_pp | beta | Planned | RES CFG++ sampler | +| Q-MR2I-10 | 2.5 | 24 | euler_cfg_pp | simple | Planned | Scheduler comparison | +| Q-MR2I-11 | 2.5 | 24 | euler_cfg_pp | sgm_uniform | Planned | Scheduler comparison | +| Q-MR2I-12 | 2.5 | 24 | euler_cfg_pp | karras | Planned | Scheduler comparison | +| Q-MR2I-13 | 2.5 | 24 | euler_cfg_pp | exponential | Planned | Scheduler comparison | +| Q-MR2I-14 | 3.5 | 30 | euler_cfg_pp | beta | Planned | Step-count comparison | +| Q-MR2I-15 | 3.5 | 40 | euler_cfg_pp | beta | Planned | Step-count comparison | +| Q-MR2I-16 | 3.5 | 60 | euler_cfg_pp | beta | Planned | Step-count comparison | +| Q-MR2I-17 | 3.5 | 75 | euler_cfg_pp | beta | Planned | Step-count comparison | +| Q-MR2I-18 | 3.5 | 50 | euler_ancestral | beta | Planned | Baseline sampler alternative | + +Record both reference hashes, runtime, output dimensions/path, exact settings, +and visual notes for every run. Do not reduce the reference count silently if +the graph or node contract rejects the pair. diff --git a/optimized/MultipleRef2I/qwen/variables.json b/optimized/MultipleRef2I/qwen/variables.json new file mode 100644 index 0000000..f9a1abb --- /dev/null +++ b/optimized/MultipleRef2I/qwen/variables.json @@ -0,0 +1,33 @@ +{ + "model": "qwen_image_2.1_int8_convrot.safetensors", + "text_encoder": "qwen3vl_8b_w4a8.safetensors (type=qwen_image)", + "vae": "qwen_image_2.1_vae_bf16.safetensors", + "fixed": { + "prompt_source": "workflow.json#7", + "reference_images": ["../person_reference.png", "../scene_reference.png"], + "width": 1920, + "height": 1080, + "seed": 310201, + "references": 2 + }, + "tests": [ + {"id":"Q-MR2I-01","cfg":3.5,"steps":50,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-02","cfg":1.0,"steps":24,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-03","cfg":2.5,"steps":24,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-04","cfg":3.5,"steps":24,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-05","cfg":4.0,"steps":24,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-06","cfg":3.5,"steps":24,"sampler":"euler","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-07","cfg":3.5,"steps":24,"sampler":"euler_ancestral","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-08","cfg":3.5,"steps":24,"sampler":"res_multistep","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-09","cfg":3.5,"steps":24,"sampler":"res_multistep_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-10","cfg":2.5,"steps":24,"sampler":"euler_cfg_pp","scheduler":"simple","status":"planned"}, + {"id":"Q-MR2I-11","cfg":2.5,"steps":24,"sampler":"euler_cfg_pp","scheduler":"sgm_uniform","status":"planned"}, + {"id":"Q-MR2I-12","cfg":2.5,"steps":24,"sampler":"euler_cfg_pp","scheduler":"karras","status":"planned"}, + {"id":"Q-MR2I-13","cfg":2.5,"steps":24,"sampler":"euler_cfg_pp","scheduler":"exponential","status":"planned"}, + {"id":"Q-MR2I-14","cfg":3.5,"steps":30,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-15","cfg":3.5,"steps":40,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-16","cfg":3.5,"steps":60,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-17","cfg":3.5,"steps":75,"sampler":"euler_cfg_pp","scheduler":"beta","status":"planned"}, + {"id":"Q-MR2I-18","cfg":3.5,"steps":50,"sampler":"euler_ancestral","scheduler":"beta","status":"planned"} + ] +} diff --git a/optimized/MultipleRef2I/qwen/workflow.json b/optimized/MultipleRef2I/qwen/workflow.json new file mode 100644 index 0000000..ba0b374 --- /dev/null +++ b/optimized/MultipleRef2I/qwen/workflow.json @@ -0,0 +1,19 @@ +{ + "1": {"class_type":"UNETLoader","inputs":{"unet_name":"qwen_image_2.1_int8_convrot.safetensors","weight_dtype":"default"}}, + "2": {"class_type":"CLIPLoader","inputs":{"clip_name":"qwen3vl_8b_w4a8.safetensors","type":"qwen_image","device":"default"}}, + "3": {"class_type":"VAELoader","inputs":{"vae_name":"qwen_image_2.1_vae_bf16.safetensors"}}, + "4": {"class_type":"LoadImage","inputs":{"image":"person_reference.png"}}, + "5": {"class_type":"ResizeAndPadImage","inputs":{"image":["4",0],"target_width":1920,"target_height":1080,"padding_color":"white","interpolation":"lanczos"}}, + "16": {"class_type":"LoadImage","inputs":{"image":"scene_reference.png"}}, + "17": {"class_type":"ResizeAndPadImage","inputs":{"image":["16",0],"target_width":1920,"target_height":1080,"padding_color":"white","interpolation":"lanczos"}}, + "6": {"class_type":"QwenImage21Cache","inputs":{"model":["1",0],"device":"auto","dtype":"int8"}}, + "7": {"class_type":"TextEncodeQwenImage21","inputs":{"clip":["2",0],"prompt":"Combine the supplied person and scene reference images into one photorealistic image. Preserve the person's identity, facial features, skin tone, hairstyle, clothing, accessories, pose, and proportions from the person reference. Preserve the environment, lighting, perspective, composition, and spatial character from the scene reference. Integrate the subject naturally into the scene with coherent scale, contact shadows, physically accurate materials, realistic anatomy, natural hands, cinematic soft light, and detailed editorial photography. Do not substitute the person, redesign the clothing, remove important objects, add extra people, mirror the composition, or add text or logos.","negative_prompt":"different person, changed identity, changed face, changed hairstyle, changed clothing, altered accessories, extra person, duplicate person, extra limbs, malformed hands, fused fingers, distorted anatomy, inconsistent scale, floating subject, bad contact shadows, cropped head, cropped feet, mirrored image, cartoon, illustration, anime, CGI, plastic skin, blurry, low detail, text, logo, watermark","resolution":0,"images":{"image_1":["5",0],"image_2":["17",0]},"vae":["3",0]}}, + "8": {"class_type":"KSamplerSelect","inputs":{"sampler_name":"euler_cfg_pp"}}, + "9": {"class_type":"BasicScheduler","inputs":{"model":["6",0],"scheduler":"beta","steps":50,"denoise":1}}, + "10": {"class_type":"RandomNoise","inputs":{"noise_seed":310201}}, + "11": {"class_type":"CFGGuider","inputs":{"model":["6",0],"positive":["7",0],"negative":["7",1],"cfg":3.5}}, + "12": {"class_type":"SamplerCustomAdvanced","inputs":{"noise":["10",0],"guider":["11",0],"sampler":["8",0],"sigmas":["9",0],"latent_image":["7",2]}}, + "13": {"class_type":"VAEDecode","inputs":{"samples":["12",0],"vae":["3",0]}}, + "14": {"class_type":"ResizeAndPadImage","inputs":{"image":["13",0],"target_width":1920,"target_height":1080,"padding_color":"white","interpolation":"lanczos"}}, + "15": {"class_type":"SaveImage","inputs":{"images":["14",0],"filename_prefix":"qwenExperiments/multipleRef2I/qwen_multi_reference"}} +} diff --git a/optimized/STATUS.md b/optimized/STATUS.md index 06322c8..3bc0672 100644 --- a/optimized/STATUS.md +++ b/optimized/STATUS.md @@ -14,6 +14,7 @@ matrix; visual review must use the same category fixtures and resolution. | I2I | Qwen Image 2.1 | `character_reference.png` + shared I2I prompt | 1080×1920 category target | 34-row matrix recorded | Existing best recorded in category README | | I2I | FLUX.3 Klein | same canonical I2I fixtures | 1080×1920 | Planned; scheduled | New candidate | | MultipleRef2I | Flux.2 Klein | `person_reference.png` + `scene_reference.png` + shared prompt | 1920×1080 | Matrix planned/untested | Candidate baseline | +| MultipleRef2I | Qwen Image 2.1 | `person_reference.png` + `scene_reference.png` + shared prompt | 1920×1080 | 18-row matrix planned | New candidate | | MultipleRef2I | FLUX.3 Klein | same canonical multi-reference fixtures | 1920×1080 | Planned; scheduled | New candidate | | R2V | MiniMax H3 Continuum | category-specific fixed prompt/references | 960×544 baseline | Mixed historical/planned matrix | Current video baseline |