p-video-animate

Animate a reference subject using motion from a source video

Overview

p-video-animate takes a source RGB video and a subject reference image, then animates the referenced subject using the motion and audio from the source video.

Rate Limit: 50 requests per minute

Category: Video Animation

Pricing:

ConfigurationPrice
720p0.03$ per second of output video
1080p0.06$ per second of output video

Quickstart

Upload your source video

curl -X POST "https://api.pruna.ai/v1/files" \
  -H "apikey: YOUR_API_KEY" \
  -F "content=@/path/to/source-video.mp4"

Upload your subject reference image

curl -X POST "https://api.pruna.ai/v1/files" \
  -H "apikey: YOUR_API_KEY" \
  -F "content=@/path/to/reference-image.png"

Create an animated video

curl -X POST 'https://api.pruna.ai/v1/predictions' \
  -H 'Content-Type: application/json' \
  -H 'apikey: YOUR_API_KEY' \
  -H 'Model: p-video-animate' \
  -d '{
    "input": {
      "video": "https://api.pruna.ai/v1/files/source-video-abc123",
      "image": "https://api.pruna.ai/v1/files/reference-image-def456",
      "resolution": "720p",
      "target_fps": "original",
      "instruction_prompt": "Animate the reference subject using the motion from the source video."
    }
  }'

Synchronous request

curl -X POST 'https://api.pruna.ai/v1/predictions' \
  -H 'Content-Type: application/json' \
  -H 'apikey: YOUR_API_KEY' \
  -H 'Model: p-video-animate' \
  -H 'Try-Sync: true' \
  -d '{
    "input": {
      "video": "https://api.pruna.ai/v1/files/source-video-abc123",
      "image": "https://api.pruna.ai/v1/files/reference-image-def456"
    }
  }'

Parameters

Required Parameters

ParameterTypeDescription
videostring (URI)Source RGB video (.mp4). Used as the motion and audio source
imagestring (URI)Reference image of the subject to animate

Optional Parameters

ParameterTypeDefaultDescription
turbobooleanfalseTurbo mode: faster generation for slightly lower quality
resolutionstring"720p"Target resolution. Options: "720p", "1080p"
save_audiobooleantrueSave the video with audio
ignore_audiobooleanfalseIgnore source audio during generation. If save_audio is true, the source audio is still saved with the final video
target_fpsstring"original"Target FPS for the working video. Options: "original", "24", "48"
instruction_promptstring""Further instruction on how the reference subject should be animated using the motion of the input video
seedintegerrandomRandom seed. Set for reproducible generation
disable_safety_checkerbooleanfalseDisable safety checker for generated videos