|
Download README.md from audio-cpp/TalkingHead-GGUF: direct link, hf CLI and curl.
- Browser
- Download file 6.07 kB
-
https://huggingface.co/audio-cpp/TalkingHead-GGUF/resolve/main/README.md
- Command line
-
hf download hf://audio-cpp/TalkingHead-GGUF/README.md
-
curl -L -o README.md https://huggingface.co/audio-cpp/TalkingHead-GGUF/resolve/main/README.md
6.07 kB
| license: apache-2.0 | |
| base_model: ampixa/talkinghead | |
| pipeline_tag: image-to-video | |
| tags: | |
| - gguf | |
| - audio.cpp | |
| - talking-head | |
| # TalkingHead GGUF | |
| Dedicated package repository: `audio-cpp/TalkingHead-GGUF`. | |
| <video controls playsinline poster="https://huggingface.co/audio-cpp/TalkingHead-GGUF/resolve/main/demos/preview.jpg" src="https://huggingface.co/audio-cpp/TalkingHead-GGUF/resolve/main/demos/mona-lisa-streaming.mp4"></video> | |
| **Mona Lisa, live audio input.** A real audio.cpp C++ session receives 100 ms | |
| audio packets over 90 seconds and emits video frames while input is arriving. | |
| The demo uses a fixed 4.2-second client playback buffer for synchronized audio | |
| and video. This is a demo setting, not a model option. | |
| Native audio.cpp packages for [Ampixa TalkingHead](https://github.com/Ampixa/talkinghead). | |
| The model animates a portrait from supplied speech audio; it does not generate speech. | |
| The audio encoder and one-step motion student drive a LivePortrait-style renderer. | |
| | File | Renderer | Size | | |
| |---|---|---| | |
| | `talkinghead-realtime-f16.gguf` | Pruned real-time | 186.3 MiB | | |
| | `talkinghead-realtime-f32.gguf` | Pruned real-time | 366.4 MiB | | |
| | `talkinghead-full-f16.gguf` | Full quality | 262.5 MiB | | |
| | `talkinghead-full-f32.gguf` | Full quality | 518.6 MiB | | |
| All packages embed the audio, motion, portrait frontend and renderer weights, | |
| configuration, and audio.cpp model specification. F16 packages retain | |
| normalization parameters and conditioning data in F32. Source-motion extraction | |
| preserves upstream CPU FP16 autocast arithmetic independently of package storage. | |
| Portrait landmarks run on CPU; the other neural components use the selected backend. | |
| These packages require an audio.cpp build containing the experimental | |
| `talkinghead` family. They do not work with older releases that lack the family. | |
| The real-time renderer name describes the checkpoint tier; this port currently | |
| accepts complete driving audio offline, or audio chunks with streamed video output. | |
| Add `--mode streaming` for chunked file processing; C++ live producers use the | |
| existing `process_audio_chunk` interface. The initial motion window needs about | |
| 3.9 seconds of audio, including context. Input, motion and emitted frames are not | |
| retained for the whole recording. Source-video data remains cached. Live | |
| resampling uses stateful SOXR; 16 kHz input needs no external resampler. Automatic | |
| prosody gestures require offline mode; scripted gestures support live input. | |
| ```bash | |
| audiocpp_cli --family talkinghead --task gen --backend cuda --threads 8 \ | |
| --model talkinghead-realtime-f16.gguf --audio speech.wav \ | |
| --request-option reference_image_file=portrait.jpg \ | |
| --out-dir output --log | |
| ``` | |
| CUDA automatically selects the cuDNN renderer when the build enables both | |
| `GGML_CUDA_CUDNN_CONV2D` and `GGML_CUDA_CUDNN_CONV3D`. Otherwise it uses GGML; | |
| CPU and Vulkan use GGML too. Explicit | |
| `talkinghead.exec_plan={"renderer":{"impl":"ggml"}}` overrides automatic selection. | |
| A cuDNN-enabled executable requires the corresponding runtime libraries. | |
| The CLI exports raw RGB24 frame files, not an encoded MP4, and logs their dimensions. Applications can consume the RGB payloads | |
| and associated metadata through the C++ task API and encode them using their video stack. | |
| Motion RNG differs from upstream NumPy, so the same seed does not imply identical | |
| videos. Head motion, the eight emotions, automatic prosody gestures and scripted | |
| nods/tilts/glances are available through model request options. | |
| ## Performance | |
| Saved RTX 5090 measurements using the real-time renderer, the same 8.52-second | |
| audio and source portrait (`face04.jpg`), and 213 output frames: | |
| | Implementation | Warm time | ms/frame | RTF | | |
| |---|---:|---:|---:| | |
| | audio.cpp CUDA/cuDNN | 1.737 s | 8.15 | 0.204 | | |
| | Official Python / PyTorch CUDA | 1.922 s | 9.02 | 0.226 | | |
| | Official Python / TensorRT | 1.748 s | 8.21 | 0.205 | | |
| The recorded audio.cpp call is about 10% shorter than PyTorch and effectively | |
| tied with TensorRT. audio.cpp and TensorRT figures are medians of three warm | |
| calls; the PyTorch figure is one warm call. These are earlier measurements, | |
| not timings of the Mona Lisa demo. | |
| **Timing boundaries differ:** Python includes MP4 encoding and audio muxing; | |
| audio.cpp includes inference and RGB frame preparation but excludes HTTP | |
| serialization/delivery and video encoding. These figures do not establish an | |
| equivalent encoded-video end-to-end speedup. Model loading and TensorRT engine | |
| compilation are excluded from warm timings. RTF is processing time divided by | |
| input duration; lower is better. | |
| Saved sampled **peak process VRAM**, on the same 8.52-second fixture in separate | |
| runs (not collected during the three-call timing comparison above): | |
| | Implementation | Peak VRAM | | |
| |---|---:| | |
| | audio.cpp CUDA/cuDNN | 1,348 MiB | | |
| | Official Python / PyTorch CUDA | 2,192 MiB | | |
| | Official Python / TensorRT | 1,354 MiB | | |
| TensorRT peak was measured in a fresh process with cached engines, including | |
| avatar initialization and four sequential 213-frame calls. Process VRAM was | |
| sampled with `nvidia-smi` (50 ms sleep between queries); every call confirmed | |
| the TensorRT backend. This excludes first-time engine compilation. | |
| ## License and provenance | |
| Upstream source revision: `a61c5e346dc5ac40f1149bebaefcf87ac477e2b2`. | |
| Checkpoint revision: `4b65dd2b5df7c69264302a086d09dd999f26a185` from | |
| [ampixa/talkinghead](https://huggingface.co/ampixa/talkinghead). | |
| The upstream project distributes these checkpoints under Apache-2.0. Retain | |
| [LICENSE](LICENSE) and [NOTICE](NOTICE), including the LivePortrait, MediaPipe, | |
| Ditto and other third-party notices, when redistributing these packages. | |
| ## Demo credits | |
| Portrait: Leonardo da Vinci’s *Mona Lisa*, [public-domain reproduction from | |
| Wikimedia Commons](https://commons.wikimedia.org/wiki/File:Mona_Lisa.jpg). | |
| The video is a synthetic animation of the painting, not an authentic recording. | |
| Driving speech: the repository’s generated English long-form validation audio; | |
| [demo input](demos/driving-speech.wav). [Source portrait](demos/mona-lisa.jpg). | |