talkinghead: Real-Time Lip Sync From 169 MB of Weights

ComfyUI Wikinews

talkinghead distils Ant Group's Ditto into 169 MB that runs at 25 fps on a laptop, and ComfyUI nodes turn one photo plus an audio clip into a talking video.

talkinghead takes one photo and a speech clip and returns a lip-synced video. The distilled weights are 169 MB, it renders at 36.5 ms per frame on an M4 Pro and about 40 ms per frame on an RTX 3050 Ti laptop, and third-party nodes run it inside ComfyUI.
Four talkinghead outputs: the Mona Lisa, Napoleon, Girl with a Pearl Earring and a photographed face

Four demo clips from the project. Top left to bottom right: Mona Lisa, Napoleon, Girl with a Pearl Earring, and a photographed face speaking English. Source: Ampixa/talkinghead

The 11-second Mona Lisa demo, rendered with the real-time model.

What it is

It is a distillation of Ditto, Ant Group's talking-head model. The audio encoder drops from 315M to 18M parameters, the motion model from 48M to 19M and the warp from 46M to 13M, with a pruned decoder behind them. Ditto's appearance extractor, motion extractor and stitching weights are kept as they are.

Lip sync is close to the teacher rather than equal: 4.91 SyncNet LSE-C against 5.12 for original Ditto on one small-face case, and the author says a full comparison is still pending.

Two limits matter in practice. Speech is supported for English and Nepali only, and the photo has to be frontal with a closed mouth, or the mouth will not close in the output. Dubbing an existing video is marked experimental.

Run it in ComfyUI

The node pack lives in a separate repo, voidash/ComfyUI-talkinghead, and installs this package as a dependency:

  1. git clone https://github.com/voidash/ComfyUI-talkinghead.git into ComfyUI/custom_nodes/.
  2. Run pip install -r requirements.txt with ComfyUI's own Python environment.
  3. Restart ComfyUI, then load example_workflows/talkinghead.json from the pack.

The two nodes are talkinghead Load Avatar (image in) and talkinghead Speak (avatar plus audio, with emotion, head motion and gesture options). Weights download from Hugging Face on first run. The pack does not touch ComfyUI's PyTorch, so it does not disturb an existing install.

The author's test on ComfyUI 0.46.0 rendered a 10-second clip in about 9 seconds on an M4 Pro.

Speed

WhereRender loopNotes
M4 Pro, Core ML36.5 ms/frame25 fps video, real-time weights
M3 Pro, Core ML39.9 ms/framesame clip
RTX 3050 Ti laptop, TensorRT~40 ms/framefirst run builds engines, about 3 minutes
Browser, WebGPU~245 ms/framenot real time, nothing to install

The download is 172.9 MB for Apple's Core ML set or 168 MB for the TensorRT set, and 248 MB for the full-quality renderer.

Availability

Comments

Sign in with GitHub to join the discussion.

Loading comments…
talkinghead: Real-Time Lip Sync From 169 MB of Weights | ComfyUI Wiki