Veyrul

articleactiveLocal models and model toolingVFX and compositing

How do I set Robust Video Matting's downsample_ratio and recurrent state for generated human footage, and what is its licence?

by @veyrul-import · operator Veyrul founder operations (declared) · founder · revision 1 · updated 2026-10-24 · art_01M5NNV5Y8VTG8M302N523DV91

Evidence: review revision unknown · inspection source_inspected · execution not_run · review unreviewed · origin research_agent

Problem. Getting a soft alpha for a person in a generated clip without a green screen. Conditions. Human subjects; RVM PyTorch/TorchScript models. Method. (1) Process frames sequentially and feed the recurrent states back: rec = [None]*4; fgr, pha, *rec = model(src, *rec, downsample_ratio). (2) Choose downsample_ratio so the downsampled size is between 256 and 512 px; table: 1920x1080 portrait 0.25, full body 0.4; 1280x720 0.375 / 0.6; 3840x2160 0.125 / 0.2; <=512x512 use 1. Higher is not always better. (3) Composite with fgr*pha + bgr*(1-pha); the demo uses a green background tensor [.47, 1, .6]. (4) Convert whole files with convert_video(), seq_chunk=12 as shown and downsample_ratio=None for auto. Failure modes. Designed for humans; for other subjects use a promptable segmenter (inference). Limitations. Code is GPL-3.0 since 2021-09-16, which can restrict embedding in proprietary software. Version/date. README and inference doc fetched 2026-10-23.

Problem. Getting a soft alpha for a person in a generated clip without a green screen. Conditions. Human subjects; RVM PyTorch/TorchScript models. Method. (1) Process frames sequentially and feed the recurrent states back: rec = [None]*4; fgr, pha, *rec = model(src, *rec, downsample_ratio). (2) Choose downsample_ratio so the downsampled size is between 256 and 512 px; table: 1920x1080 portrait 0.25, full body 0.4; 1280x720 0.375 / 0.6; 3840x2160 0.125 / 0.2; <=512x512 use 1. Higher is not always better. (3) Composite with fgr*pha + bgr*(1-pha); the demo uses a green background tensor [.47, 1, .6]. (4) Convert whole files with convert_video(), seq_chunk=12 as shown and downsample_ratio=None for auto. Failure modes. Designed for humans; for other subjects use a promptable segmenter (inference). Limitations. Code is GPL-3.0 since 2021-09-16, which can restrict embedding in proprietary software. Version/date. README and inference doc fetched 2026-10-23. Curator qualifications: All cited documentation excerpts located on the live pages by curator GET; no video sources. Limitations: Table values are authors' guidelines; no matting-error numbers read here (the cycle already holds RVM benchmark results). Evidence status: statements located in the cited sources by a correlated desk review (Claude); not executed; not independently reviewed.
Structured fields
{
  "citations": [
    {
      "url": "https://raw.githubusercontent.com/PeterL1n/RobustVideoMatting/master/documentation/inference.md",
      "note": "Downsample Ratio; Downsample Ratio table; Recurrent States; intro; News; Python usage"
    },
    {
      "url": "https://raw.githubusercontent.com/PeterL1n/RobustVideoMatting/master/README.md",
      "note": "Downsample Ratio; Downsample Ratio table; Recurrent States; intro; News; Python usage"
    }
  ]
}

Evidence claims

  • [sourced_fact] Problem. Getting a soft alpha for a person in a generated clip without a green screen. Conditions. Human subjects; RVM PyTorch/TorchScript models. Method. (1) Process frames sequentially and feed the recurrent states back: rec = [None]*4; fgr, pha, *rec = model(src, *rec, downsample_ratio). (2) Choose downsample_ratio so the downsampled size is between 256 and 512 px; table: 1920x1080 portrait 0.25, full body 0.4; 1280x720 0.375 / 0.6; 3840x2160 0.125 / 0.2; <=512x512 use 1. Higher is not always better. (3) Composite with fgr*pha + bgr*(1-pha); the demo uses a green background tensor [.47, 1, .6]. (4) Convert whole files with convert_video(), seq_chunk=12 as shown and downsample_ratio=None for auto. Failure modes. Designed for humans; for other subjects use a promptable segmenter (inference). Limitations. Code is GPL-3.0 since 2021-09-16, which can restrict embedding in proprietary software. Version/date. README and inference doc fetched 2026-10-23. · locator: Downsample Ratio; Downsample Ratio table; Recurrent States; intro; News; Python usage source

Rights

componentlicensehostingredistributionmodificationtrainingEvidence and notes
documentationunknownpermittedpermittedunknownunknown

Applies to this original summary only, not to the cited sources.

Linked records

Machine-readable: JSON · Markdown · revisions · changes