Nodes/ComfyUI_Janus_Wrapper/Load Janus Model
ComfyUI Node

Load Janus Model

The Download-and-Forget Workhorse of the Janus Pack

By chflame163·Created 2 years ago·Updated about a year ago· 17
Load Janus Model
    • janus_model
    ◄model▾►

    Every node in this pack is downstream of this one. Load Janus Model fetches DeepSeek's Janus-Pro weights, drops them on your disk, and hands the rest of the graph the bundle it needs to do anything. If the other two nodes aren't working, nine times out of ten the problem lives here - so it's worth getting right first.

    Janus-Pro is DeepSeek's unified multimodal model, released in the same late-January 2025 burst that made everyone suddenly care about the lab's open weights. One set of parameters does both image understanding and image generation. That's genuinely unusual, and it's the whole reason this three-node pack exists. The author, chflame163, is the same person behind ComfyUI_LayerStyle - one of the most-installed layer packs in the ecosystem - so this is a smaller, quieter sibling from a known stable. The whole thing ships MIT.

    How it works

    On first run, if ComfyUI/models/Janus-Pro/<model> doesn't exist yet, the node pulls the entire repo from HuggingFace with snapshot_download. Then it builds a VLChatProcessor (tokenizer plus image processor) and loads the multimodal causal LM via AutoModelForCausalLM with trust_remote_code=True, casts to bfloat16, and moves it to CUDA. What comes out the other end is a janus_model object that both generation and understanding nodes consume.

    The one input that matters

    There's exactly one: model, with two choices.

    • Janus-Pro-7B - the big one. Roughly 14GB of bf16 weights plus the visual codebook, so plan on 16GB+ of VRAM. On 12GB cards people get OOM errors, and the autoregressive generation is slow enough that the 7B starts to feel like a punishment.
    • Janus-Pro-1B - about 2GB, dramatically faster, and for text-to-image specifically it punches far above its weight on prompt adherence. Community tests found the 1B following prompts more literally than Flux and SDXL in side-by-sides. If you're on anything under ~16GB, this is the one you actually want. Don't argue with it.

    The output is janus_model, and it plugs into both Janus Text To Image (Generation) and Janus Image To Text (Understanding). One loader, two consumers.

    Installing it

    Same story as every custom node. ComfyUI Manager, search the pack title ComfyUI_Janus_Wrapper, install, restart. Or by hand:

    cd ComfyUI/custom_nodes
    git clone https://github.com/chflame163/ComfyUI_Janus_Wrapper.git
    cd ComfyUI_Janus_Wrapper
    pip install -r requirements.txt
    

    On the Windows portable build, the README wants the embedded Python instead:

    ..\..\..\python_embeded\python.exe -s -m pip install -r requirements.txt
    

    The requirements are the usual HF stack - transformers, timm, accelerate, sentencepiece, einops, huggingface_hub - with two gotchas hiding in there. First, numpy<2.0 is pinned, which will happily fight any other node that pulled in numpy 2. Second, attrdict is abandoned and can choke on newer Python. Both are textbook ComfyUI dependency hell: if ComfyUI stops booting after install, these are the first suspects.

    Troubleshooting

    • First run downloads a lot. 7B is roughly 15GB, 1B is ~2GB. It happens automatically, but if the download dies mid-way, grab the files manually from HuggingFace and drop them in ComfyUI/models/Janus-Pro/Janus-Pro-7B (or the 1B folder).
    • OOM / "CUDA out of memory" - switch to Janus-Pro-1B. There's no CPU fallback; this node hard-requires a CUDA GPU (.cuda(), no device check).
    • ComfyUI won't start after install - look at the numpy/attrdict conflict above.

    Get this node green, and the other two finally have something to work with.

    Category😺dzNodes/Janus

    Inputs (1)

    NameTypeDefaultDescription
    modelCOMBO2 options: Janus-Pro-7B, Janus-Pro-1B

    Outputs (1)

    NameTypeDescription
    janus_modelJanusModel—