LivePortraitp2p
Animate a Photo With Another Photo — No API, No Key, Just a Model
- source_image
- driving_image
- images output
The name is a small lie, in the good way. LivePortraitp2p doesn't call any API and needs no key - it runs Kuaishou's LivePortrait model entirely on your GPU. You feed it two photos: a portrait that gets animated and a second face whose expression and head pose are the target. Out comes a new image of the first face wearing the second face's expression. That's the whole job, and "p2p" is a fair acronym: it's the photo-to-photo corner of LivePortrait.
LivePortrait is the paper behind most "make this still do that expression" demos - Efficient Portrait Animation with Stitching and Retargeting Control. The version most people actually run (kijai's ComfyUI-LivePortraitKJ) animates a still into a video using a driving clip. This node strips that down to images only: both inputs are IMAGE tensors, and the output is a single still, not a clip. Think "make my portrait smile like this reference photo," or transplant a head pose from one shot onto another - quick, no video plumbing.
How it actually works
Peek under the hood and this node is refreshingly unpretentious. It takes your two image tensors, converts them back into JPGs, writes them to hardcoded paths, then hands off to the stock KwaiVGI pipeline. Internally, LivePortrait extracts 21 facial keypoints from each face, transfers the driving face's relative motion onto the source keypoints, warps the source's appearance features through a warping module, refines the result at 512×512 with a SPADE generator, then stitches the animated crop back into the original frame. Half-precision is on by default, so it's fast - a few seconds on a decent card. Because the driving signal is a still, you get one output frame: the source face, re-expressed, pasted back into its original framing.
The inputs and outputs that matter
There are exactly two inputs and one output, and all of them matter.
source_image(IMAGE) - the portrait that gets animated. A clean, front-ish face reads best.driving_image(IMAGE) - the face providing the expression and pose to copy.images output(IMAGE) - one frame of the source face doing the driving expression, back in the original image space. Wire it into a Save Image or Preview node; that's the whole point of the exercise.
That's the entire schema - no optional parameters, no retargeting sliders, no crop or stitching toggles. What you see is what you get.
Installing it
Through ComfyUI Manager, search for ComfyUI-LivePortrait_v3 and install. Or the manual way:
cd ComfyUI/custom_nodes
git clone https://github.com/VangengLab/ComfyUI-LivePortrait_v3
Then grab the pretrained weights, which are not bundled. The README wants them under ComfyUI/models/Liveportrait_v3:
cd models/
huggingface-cli download KwaiVGI/LivePortrait --local-dir Liveportrait_v3 --exclude "*.git*" "README.md" "docs"
If Hugging Face is unreachable, the README covers hf-mirror.com as a fallback.
Heavy dependency warning: the pack's requirements.txt is a frozen dump of the author's entire environment - torch==2.3.0+cu121 plus several hundred unrelated packages. Do not pip install -r requirements.txt into your main ComfyUI env. You actually need torch matching your CUDA build, insightface, tyro, yacs, and the usual OpenCV/Pillow stack.
Where people get burned
The node hardcodes the folder name custom_nodes/Comfyui_Liveportrait_v3 (underscores, mixed case) for both the JPGs it saves and its models.yaml config - but the repo itself is ComfyUI-LivePortrait_v3 (hyphens). If you clone it under its own name, the save path doesn't exist and the node errors before it ever runs. The practical fix: rename the folder to Comfyui_Liveportrait_v3 (or symlink it) so the hardcoded paths resolve. The README's own plea - "maybe there will be some problem about locating models, please use the absolute address" - tells you the author knows exactly how fragile this is.
One more thing worth knowing before you build anything commercial on it: the weights are Kuaishou's (MIT, fine), but the pack bundles InsightFace buffalo_l ONNX models for face detection, and those weights are non-commercial. Kijai's LivePortrait went InsightFace-free with MediaPipe (Apache 2.0) specifically so outputs could be sold; this port hasn't.
Honest verdict: this is a minimal, barely-maintained port - last commit in late 2024, no community footprint, and it shows. It's perfect for a quick experiment and for understanding what LivePortrait actually does. For real work, reach for ComfyUI-LivePortraitKJ, which supports video drivers and actual retargeting controls; its image-drive workflow does this node's job with far fewer landmines.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| source_image | IMAGE | — | |
| driving_image | IMAGE | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| images output | IMAGE | — |