MuseTalk 1.5

MUSETALK_1_5

Makes a face in a video say new words. Send a clip of one talking face and an audio file; the mouth and jaw move to the audio and the result carries it as its sound. Learns your presenter from your own clips.

Video Editinglip-syncvideo-dubbingtalking-faceaudio-to-videomitFine-tunable
MuseTalk 1.5: Video Editing model on Kainguru

About MuseTalk 1.5

Capabilities

  • New speech, same face — the mouth and jaw of the face in your clip follow an audio file you send; the rest of the picture stays as it was
  • As long as the speech — one frame for every 1/fps of speech, up to 20 seconds and 600 frames; the clip is played forward and back to last
  • Sound included — the result is an H.264 MP4 whose audio track is your speech
  • Any language — the sound of the speech drives the mouth, not its words (it learned from mostly English footage; other languages are untested)
  • Fine-tuning — adapt the whole model to your presenter or your footage from talking-face clips with their own sound

Good to know

  • Use it only on footage of people who have agreed to it and with speech you have the right to use: giving a person words they did not say can mislead.
  • The clip is MP4, MOV, WebM or MKV with one face looking at the camera, up to 200 MB, 300 frames, 3840 pixels a side and 10 to 60 frames per second (25 is best). It is worked at up to 1280 pixels on the longer side and the result comes back at that size.
  • The audio is WAV, MP3, FLAC, OGG, M4A, AAC or WebM, up to 20 seconds and 30 MB. The result has one frame for every 1/fps of speech (at most 600, so a clip above 30 frames per second takes shorter speech).
  • Frames where no face of at least 48 pixels is found keep their picture, and a clip with no face at all is refused. The mouth is made inside a 256 x 256 picture of the face and pasted back, so close-ups of one face work best; other expressions are not changed.
  • The extra margin (0 to 40 pixels, 10 by default) is how far below the chin the model also makes, so that the jaw can open without a seam.
  • You pay for the frames of the result.
  • Fine-tuning takes one ZIP (at most 4 GB, no password) with 1 to 100 talking-face clips of 25 to 450 frames, at most 30 seconds, 10 to 60 frames per second and with their own sound, and manifest.jsonl, one {"video": ...} line per clip, paths relative to it.
  • Training shows the model a frame's face with its lower half hidden, a reference frame of the same clip and the frame's sound, and compares what it makes with the real face (L1 and a VGG19 perceptual loss, the authors' first training stage: their sync and GAN stage is not repeated, so a fine-tune keeps the model's lip sync only as far as your clips teach it). It stops after 2000 steps or 9 hours, whichever comes first, and keeps what it has learned.

Attribution

MuseTalk by Yue Zhang, Zhizhou Zhong, Minhao Liu, Zhaokang Chen, Bin Wu, Yubin Zeng, Chao Zhan, Junxin Huang, Yingjie He and Wenjiang Zhou (Lyra Lab, Tencent Music Entertainment), released under the MIT License, Copyright (c) 2024 Tencent Music Entertainment Group. Built with the Stable Diffusion VAE sd-vae-ft-mse (MIT License), Whisper tiny by OpenAI (Apache License 2.0) and DWPose by IDEA Research (Apache License 2.0); training also uses torchvision's VGG19 (BSD-3-Clause).

MuseTalk 1.5 inputs and output

NameTypeRequiredDefaultDetails
audiofileYes—The speech the mouth should say: WAV, MP3, FLAC, OGG, M4A, AAC or WebM, at most 20 seconds and 30 MB. The result is as long as it is.
1–2048 characters · audio/wav, mpeg, flac, ogg, mp4, aac, webm
videofileYes—A clip of one face talking to the camera: MP4, MOV, WebM or MKV, at most 200 MB, 300 frames, 10 to 60 frames per second (25 is best). It is played forward and back to last as long as the speech.
1–2048 characters · video/mp4, quicktime, webm, x-matroska
extra_marginintegerNo10Pixels below the chin that are generated too, so the jaw can open without leaving a seam.
0–40

Output. Returns MP4 video: The talking-face clip with its mouth moving to the speech: H.264 MP4 at the clip's frame rate (at most 1280 pixels on the longer side), with the speech as its sound.

Run MuseTalk 1.5 with the API

Send your API key in the X-API-Key header. The run is asynchronous: submit it, then poll it until it finishes. Create an API key.

cURL
curl -X POST "https://api.kainguru.com/api/v1/executions?mlFlowId=MUSETALK_1_5" \
  -H "X-API-Key: kg_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "input": {
    "audio": "https://example.com/input.png",
    "video": "https://example.com/input.png",
    "extra_margin": 10
  },
  "outputFormat": "json"
}'

# Poll until the execution reaches a terminal state
curl "https://api.kainguru.com/api/v1/executions/{executionId}" \
  -H "X-API-Key: kg_your_api_key"
Python
from kainguru import KainguruClient

with KainguruClient(api_key="kg_your_api_key", base_url="https://api.kainguru.com/api") as client:
    submitted = client.executions.execute(
        "MUSETALK_1_5",
        {
          "audio": "https://example.com/input.png",
          "video": "https://example.com/input.png",
          "extra_margin": 10
        },
        output_format="json",
    )
    result = client.executions.await_completion(submitted.id)
    print(result.execution.output)

Fine-tune MuseTalk 1.5

You can fine-tune MuseTalk 1.5 on your own data and run the tuned model through the same API. Dataset: One ZIP (at most 4 GB, no password) with 1 to 100 talking-face clips with their sound and manifest.jsonl: a {"video"} line per clip. More in Good to know, in the README.

The steps are in the docs.

MuseTalk 1.5 pricing

Price per frame: 0.06612 credits ($0.0006612). The price is shown again before every run; all prices are on the pricing page.

Licence and source

Background Matting v2: Video Editing model on Kainguru
Video Editing

Background Matting v2

Cuts a person out of video precisely, hair included, when you also give a picture of the empty background from the…

Fine-tunable
DeOldify Video: Video Editing model on Kainguru
Video Editing

DeOldify Video

Colourises black-and-white video with DeOldify's video model: plausible colour for every frame, laid over the original…

Fine-tunable
RIFE 4.26: Video Editing model on Kainguru
Video Editing

RIFE 4.26

Raises a video's frame rate 2, 3, 4 or 8 times by predicting the frames in between, fast enough for long clips (RIFE…

Fine-tunable
STTN Subtitle Remover: Video Editing model on Kainguru
Video Editing

STTN Subtitle Remover

Removes burned-in subtitles and captions from a video: finds the text on every frame and fills it in from the rest of…

Fine-tunable
Face Anonymizer Video: Video Editing model on Kainguru
Video Editing

Face Anonymizer Video

Finds every face in a short video and covers it on each frame with a blur, pixelation or a solid box.

Smart Crop Vertical: Video Editing model on Kainguru
Video Editing

Smart Crop Vertical

Turns a landscape clip into a 9:16 vertical clip whose window follows the largest face.