Nodes/ComfyUI-Qwen2.5-VL-7B-OPENVINO/Qwen2_5_VL_ImageToText
ComfyUI Node

Qwen2_5_VL_ImageToText

Turning pictures into prompt-ready prose (including 'Banana Style')

By blackmeat1225·Created 5 months ago·Updated 5 months ago· 3
Qwen2_5_VL_ImageToText
  • image1
  • image2
  • raw_description
  • cleaned_description
max_new_tokens2048
max_description_length1002
model_pathhelenai/Qwen2.5-VL-7B-Instruct-ov-int4
deviceCPU
styleNone

Somewhere between "describe this image" and "generate this image" there's a missing step, and this node is a hack for it. Give it a picture and it produces two long text descriptions you can paste straight into a text-to-image prompt - which is why the author calls this whole approach "pseudo image-to-image." It's not real img2img (no latent input, no denoising from your source); it's the VLM reading your picture so a diffusion model can redraw it from the description. Crude, but it's the kind of thing that actually works on an Intel-iGPU laptop where running a real img2img pass means waiting out a 7B model anyway.

It's one of five nodes in blackmeat1225's ComfyUI-Qwen2.5-VL-7B-OPENVINO pack, all of them LLM-assisted glue around Intel OpenVINO. Same install, same model, same caveats as its siblings.

How it works

The Qwen2.5-VL-7B model (OpenVINO INT4, auto-downloaded on first use) gets one or two 512×512 images and a hardcoded prompt. Single image: "describe the appearance of the subject in detail." Two images: image 1 defines the appearance, image 2 is a pose reference, and the model is told to fuse them into one dense paragraph - appearance first, then the pose, spelled out in degree angles and clock-face positions.

The style dropdown is where it gets fun. Realistic Photo, 3D Render, Architectural Drawing, Oil Painting, Comic, "Banana Style," "EROI," None. These aren't styles - they're keyword prefixes glued onto the model's prompt. "Banana Style" prepends "yellow and vibrant pop art style," "EROI" prepends "Sexy, lewd, erotic." It's the author tuning a generation vibe into the description so the downstream T2I pass inherits it. Cute, occasionally useful, and you should not overthink the list.

You get two outputs because the raw model rambles: raw_description is everything Qwen said, and cleaned_description has been post-processed - sentences that mention "the second image" get dropped, "the subject in the first image" becomes "the subject," and the whole thing is truncated to your max_description_length (default 1002 chars). For feeding a KSampler, use the cleaned one; raw is there for when you want the unfiltered take.

Inputs that matter

  • image1 - the appearance reference. This is the one that defines what gets described.
  • image2 (optional) - a pose reference. Attach it and the output becomes "describe this character in this pose."
  • style - the keyword prefix. Default None; pick one if you want the description to carry an art direction.
  • max_new_tokens - generation budget, default 2048. Crank it down if output looks cut off mid-sentence.

Wiring it up

The classic loop: LoadImage → Qwen2.5-VL Image to Text → (cleaned_description) → a text/CLIP encoder → KSampler. The description becomes your prompt, which means the generated image inherits whatever the VLM noticed - and whatever it hallucinated. That's the honest trade-off of the pseudo-approach: the model can invent details, and with two images the author's own README admits you sometimes get twins (one face bleeding across both subjects). Output quality is only as good as the description, so read it before you sample.

Install & gotchas

Install via ComfyUI Manager (search ComfyUI-Qwen2.5-VL-7B-OPENVINO) or clone https://github.com/blackmeat1225/ComfyUI-Qwen2.5-VL-7B-OPENVINO into custom_nodes/, then pip install openvino-genai pillow. Fresh venv recommended. The README's own clone URL is stale (it points at the Z-Image turbo repo) - use the one above.

First run downloads the multi-gigabyte model into models/openvino/. If the node outputs a string starting with "❌ 模型推理失败:" that's it swallowing an exception - the model folder is wrong or the run failed; the real traceback is in the console.

CategoryQwen2.5-VL

Inputs (7)

NameTypeDefaultDescription
image1IMAGE
max_new_tokensINT20481–2048
max_description_lengthINT100250–2048
model_pathSTRINGhelenai/Qwen2.5-VL-7B-Instruct-ov-int4
deviceCOMBOCPU2 options: CPU, GPU
styleCOMBONone8 options: Realistic Photo, 3D Render, Architectural Drawing, Oil Painting, Banana Style, Comic, +2
image2optIMAGE

Outputs (2)

NameTypeDescription
raw_descriptionSTRING
cleaned_descriptionSTRING