whatisgithub

What is talking-portrait.cpp?

localai-org/talking-portrait.cpp — explained in plain English

Analysis updated 2026-07-26

4C++Audience · developerComplexity · 4/5Setup · hard

In one sentence

Turns a still portrait photo and a voice recording into a talking-head video. Runs on CPU or NVIDIA GPU using C++ and the GGML library.

Mindmap

mindmap
  root((repo))
    What it does
      Animates portrait photos
      Uses voice recordings
      Outputs talking video
    Tech stack
      C++ and GGML
      CMake and Ninja
      ffmpeg for video
      WebGL gallery demo
    Pipeline
      Audio encoder
      Motion generator
      Motion decoder renders video
    Gallery demo
      3D browser gallery
      Upload portrait and audio
      Docker and Go server
    Use cases
      Create talking avatars
      Build interactive exhibits
    Audience
      Developers and tinkerers

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Generate a talking-head video from a portrait photo and a WAV voice clip.

USE CASE 2

Build an interactive 3D gallery where visitors upload portraits and hear them speak.

USE CASE 3

Experiment with CPU-based or GPU-based facial animation without Python or PyTorch.

What is it built with?

C++GGMLCMakeNinjaVulkanffmpegGoWebGL

How does it compare?

localai-org/talking-portrait.cppaerl-official/aerl-c-frameworkantoxa2584x/shar-psp
Stars444
LanguageC++C++C++
Setup difficultyhardeasyhard
Complexity4/52/55/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · hard Time to first run · 1day+

Requires building C++ from source with CMake and Ninja, plus ffmpeg, optional Vulkan/CUDA setup, and Docker for the gallery demo.

No license information is provided in the project README.

So what is it?

``json { "i": 0, "repo": "localai-org/talking-portrait.cpp", "stars": 4, "lang": "C++", "ok": true, "char_count": 1610, "text": "This project animates a still portrait photo using a voice recording. You give it one 512x512 portrait image and a 16 kHz speech audio file, and it produces a 25 frame per second talking head video. It is a C++ port of an existing research project called FLOAT, built to run on CPU or NVIDIA GPUs using the GGML tensor library.\n\nThe software pipeline works in stages. First, an audio encoder processes the speech signal. Then a motion generator uses a technique called flow matching to predict how the face should move frame by frame. Finally, a motion decoder warps and renders the portrait image according to those predictions, producing the animated video. The caller specifies the emotion as a simple label, and the system does not attempt to detect emotion from the audio itself.\n\nThe repository provides a command line tool that takes a portrait image, a WAV file, and an emotion label, and outputs a video file. It uses ffmpeg for video encoding. Build requirements include CMake, Ninja, and a C++17 compiler, with optional Vulkan support if the relevant headers and tools are installed. There are also presets for debugging, fuzzing, and CUDA builds.\n\nBeyond the core tool, the project includes a WebGL gallery demo. This demo lets users upload a portrait and either an audio file or a microphone recording, then plays the generated talking portrait video inside a virtual 3D gallery rendered in the browser. Completed portraits hang along a virtual wall, and the camera tours them in order. The demo runs locally through a Docker container with a Go server and HTTPS termination via Caddy. It has no authentication, so the documentation advises restricting network access.\n\nThe project tracks its progress through a series of milestones. It reports passing several parity gates against the original PyTorch implementation, with some limitations in half precision mode. It also claims performance above its targets and zero memory allocations per frame on the generation thread. The full README is longer than what was shown.", "error": null } ``

Copy-paste prompts

Prompt 1
How do I build and run the talking-portrait command line tool with a 512x512 portrait image, a 16 kHz WAV file, and an emotion label on an NVIDIA GPU?
Prompt 2
Set up the WebGL gallery demo with Docker, Caddy, and the Go server so I can upload a portrait and microphone recording and see the talking portrait in the 3D gallery.
Prompt 3
Explain the FLOAT flow-matching pipeline used by this project, how the audio encoder, motion generator, and motion decoder work together to produce a 25 fps talking-head video.
Prompt 4
Help me configure the CMake build with CUDA support and Vulkan enabled so I can run talking-portrait.cpp locally on my machine.

Frequently asked questions

What is talking-portrait.cpp?

Turns a still portrait photo and a voice recording into a talking-head video. Runs on CPU or NVIDIA GPU using C++ and the GGML library.

What language is talking-portrait.cpp written in?

Mainly C++. The stack also includes C++, GGML, CMake.

What license does talking-portrait.cpp use?

No license information is provided in the project README.

How hard is talking-portrait.cpp to set up?

Setup difficulty is rated hard, with roughly 1day+ to a first successful run.

Who is talking-portrait.cpp for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.