Nodes/Face Restorer for ComfyUI/🤩 Face Restorer Loader
ComfyUI Node

🤩 Face Restorer Loader

RestoreFormer or RestoreFormer++? The one knob this pack has

By tungdop2·Created 2 years ago·Updated 2 years ago· 1
🤩 Face Restorer Loader
    • FACE_RESTORE_MODEL
    â—„archRestoreFormer++â–º

    This is the whole pack's personality in one node: a dropdown with two choices and nothing else. FaceRestorerLoader doesn't touch your image. It picks which restoration model the FaceRestorer node will use, downloads the weights if needed, and hands back a FACE_RESTORE_MODEL handle. It's not a "loader" in the checkpoint sense - no prompt, no CLIP, no sampler involved anywhere in this pack. It's the quiet supply line for the face surgery happening two nodes over.

    So the one decision you actually make is which architecture to run. The default is RestoreFormer++, and you should mostly leave it there. Both options are the same VQ-GAN + multi-head transformer family from the RestoreFormerPlusPlus paper; the difference is the plus-plus. The original RestoreFormer runs 8 transformer heads over a single-scale codebook; the ++ variant drops to 4 heads but adds extra multi-scale blocks that let it recover detail across resolutions. That's the improvement the paper is named for, and it's the reason the author defaults to it. The plain RestoreFormer still exists for the people who find ++ a little too aggressive in how much it "repaints" a face - it's a subtler, older look. Both are a "distant second" in the community's power rankings behind GPEN and the heavyweight SUPIR, so don't expect miracles on a 40px face - expect a clean 512px crop.

    Wiring it in

    Two cables, total:

    • arch - the dropdown: RestoreFormer or RestoreFormer++ (default ++).
    • output FACE_RESTORE_MODEL → into the FaceRestorer node's face_restore_model input.

    One loader can feed however many FaceRestorer nodes you want, so don't add more loaders than models. It's a one-per-workflow kind of node.

    How the loading actually works

    Worth knowing, because it explains the first-run behavior: the loader builds the VQVAEGANMultiHeadTransformer architecture, downloads the matching .ckpt from huggingface.co/tungdop2/FaceRestorer into ComfyUI/models/facerestorer, then loads it with ComfyUI's own load_torch_file after stripping the vqvae. prefix from the upstream checkpoint's keys. It also registers models/facerestorer as a known model folder - which means you can skip the auto-download entirely and just drop the RestoreFormer.ckpt or RestoreFormer++.ckpt file there yourself. That's the standard escape hatch if the download stalls or HuggingFace is blocked on your network; the URLs in the code are the ground truth for what filenames it expects.

    Install

    No separate install - it ships in the same pack as FaceRestorer. Manager, search "Face Restorer" (pack title "Face Restorer for ComfyUI"), or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/tungdop2/Comfyui_face_restorer
    # restart ComfyUI
    

    One dependency caveat carries over from the whole pack: the pinned requirements.txt lists ancient versions of basicsr and pytorch-lightning that the runtime code never actually imports (the pack vendors its own basicsr). The only dependency the loader's sibling node genuinely needs at runtime is facexlib. If Manager's install starts downgrading packages and other nodes break, that stale requirements list is the culprit.

    It's a tiny node, but it's the honest part of an honest pack - a model picker that tells you exactly what it's picking. Set the dropdown to ++, wire the handle into FaceRestorer, and go fix some background faces.

    Categoryface_restorer

    Inputs (1)

    NameTypeDefaultDescription
    archCOMBORestoreFormer++2 options: RestoreFormer, RestoreFormer++

    Outputs (1)

    NameTypeDescription
    FACE_RESTORE_MODELFACE_RESTORE_MODEL—