P-H3-Image Runs at 2 Steps With a pDMD LoRA in ComfyUI

ComfyUI Wikinews

A pDMD 2-step LoRA cuts P-H3-Image from 8 steps to 2 at 8 MP: one file, a ready ComfyUI workflow and no custom nodes, about 2.9 s an image.

<strong>P-H3-Image</strong> normally samples in 8 steps. akhaliq packaged the pDMD 2-NFE LoRA as a single file for it, so it can run at 2 steps and at 2912 x 2912 in about 2.9 s an image on an H200 or RTX PRO 6000. ComfyUI runs it with built-in nodes only, and a ready workflow ships with the weights.
Stock P-H3-Image at 2 stepsP-H3-Image at 2 steps with the pDMD LoRA
Stock model, 2 stepsWith the pDMD LoRA, 2 steps

Twelve prompts, 2 steps, shift 12, seed 3, rendered at 2912 x 2912 from the author's repo. Without the LoRA the model is still mid-denoise at 2 steps.

Run it

  1. Set up P-H3-Image per P-H3-Image-Comfy and update ComfyUI to the latest master.
  2. Download the LoRA into ComfyUI/models/loras/:
    hf download akhaliq/p-h3-image-pdmd-2step minimax_h3_pdmd_2nfe_comfyui.safetensors --local-dir ComfyUI/models/loras
  3. Open the workflow below. Two changes from the stock 8-step graph: Load LoRA (Bypass, Model Only) at strength 1.0 between Load Diffusion Model and the sampler, and a BasicScheduler on simple at 2 steps with flow shift 12 in place of the 8-step ManualSigmas grid. Keep euler, Basic Guider and no CFG.

There is also a browser demo for text-to-image and single-image edits at 2, 3 and 4 steps.

2, 3 or 4 steps

StepsResult
2Usable: sharp and coherent, but composition drifts from the 8-step baseline and graphic prompts can invent pseudo-text
3The safe middle setting
4Closest to the baseline, and the pick for quoted text and flat graphics

The LoRA is the pDMD 2-NFE adapter (rank 128, alpha 128 over the same 312 modules, bf16, unmodified from the upstream release). It was distilled for the H3 video model, and here it merges into P-H3-Image's image transformer instead.

Optional detail pass

A Regenerate-2K refiner on top adds real detail: render a 2 MP draft at 2 steps, upscale 2x, then regenerate at 8 MP with the refiner LoRA at sigma 0.7 for 3 Euler steps. The author measures about 7 s an image all in, roughly 1.7x faster than the bare 8-step baseline. Use 0.5 for portraits, which holds faces better while giving less detail.

2-step draft refined at sigma 0.7

2-step draft plus the Regenerate-2K pass at sigma 0.7, same twelve prompts.

VRAM does not change: the LoRA is merged at load, so the bf16 set still needs about 83 GB without the prompt upsampler, or about 76 GB with ComfyUI's component offload.

Availability

Comments

Sign in with GitHub to join the discussion.

Loading comments…
P-H3-Image Runs at 2 Steps With a pDMD LoRA in ComfyUI | ComfyUI Wiki