SAM 3 Video RLE is a unified foundation model for prompt-based segmentation in video. Track and segment objects across frames using text, points, or boxes, returning RLE encoded masks for efficient processing. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing.
Ожидание
{
"rle_url": "https://d2p7pge43lyniu.cloudfront.net/output/2a4b36a7-77c5-4b7c-9c42-d28eef15705c-u1_b5159ba1-08a2-4e29-9dd9-66a30506fa42_rle.json",
"video_url": "https://d2p7pge43lyniu.cloudfront.net/output/2a4b36a7-77c5-4b7c-9c42-d28eef15705c-u1_f517c2b2-1e6c-4c63-b432-de43b9fb2e1f.mp4"
}$0.05за запуск·~20 / $1
the man
the product
the man
the woman
SAM3 Video Segmentation RLE is an advanced video segmentation model based on Meta's Segment Anything Model 3. It tracks and segments objects across video frames and returns masks in RLE (Run-Length Encoding) format — ideal for programmatic processing, automated pipelines, and integration with downstream workflows.
Video object tracking Segment and track objects consistently across all video frames.
RLE output format Returns compact Run-Length Encoded mask data for efficient storage and processing.
Multiple prompt types Segment objects using text prompts, point prompts, box prompts, or any combination.
Multi-object tracking Track multiple objects using comma-separated prompts (e.g., "person, cloth").
Prompt Enhancer Built-in tool to automatically improve your text prompts for better results.
Optional mask visualization Toggle apply_mask to preview segmentation on the video.
| Parameter | Required | Description |
|---|---|---|
| video | Yes | Source video to segment (upload or URL) |
| prompt | Yes | Text description of the object(s) to segment |
| point_prompts | No | Point coordinates to identify the target object |
| box_prompts | No | Bounding box coordinates to identify the target object |
| apply_mask | No | Apply mask overlay to the video output |
The model returns RLE (Run-Length Encoding) data for each frame in JSON format, enabling efficient programmatic processing.
from pycocotools import mask as mask_utils
rle_data = {"counts": "146301 3 147834 11...", "size": [height, width]}
binary_mask = mask_utils.decode(rle_data) # Returns numpy array
| Duration | Cost |
|---|---|
| Per 5 seconds | $0.05 |
| 1 minute | $0.60 |
| 5 minutes | $3.00 |
| 10 minutes | $6.00 |
Grab a WaveSpeedAI API key, then call POST https://api.wavespeed.ai/api/v3/wavespeed-ai/sam3-video-rle with your input as JSON. The endpoint returns a prediction id; poll the prediction endpoint until status flips to completed, then read the output URL from data.outputs[0]. Examples for Sam3 Video Rle below.
# Submit the prediction
curl -X POST "https://api.wavespeed.ai/api/v3/wavespeed-ai/sam3-video-rle" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $WAVESPEED_API_KEY" \
-d '{
"prompt": "A cinematic shot of a city at sunset, soft golden light",
"video": "https://example.com/your-input.mp4",
"apply_mask": true
}'
# Response includes a prediction id. Poll for the result:
curl -X GET "https://api.wavespeed.ai/api/v3/predictions/{request_id}/result" \
-H "Authorization: Bearer $WAVESPEED_API_KEY"
# When status is "completed", read the output from data.outputs[0].// npm install wavespeed
const WaveSpeed = require('wavespeed');
const client = new WaveSpeed(); // reads WAVESPEED_API_KEY from env
const result = await client.run("wavespeed-ai/sam3-video-rle", {
"prompt": "A cinematic shot of a city at sunset, soft golden light",
"video": "https://example.com/your-input.mp4",
"apply_mask": true
});
console.log(result.outputs[0]); // → URL of the generated output# pip install wavespeed
import wavespeed
output = wavespeed.run(
"wavespeed-ai/sam3-video-rle",
{
"prompt": "A cinematic shot of a city at sunset, soft golden light",
"video": "https://example.com/your-input.mp4",
"apply_mask": true
}
)
print(output["outputs"][0]) # → URL of the generated outputSam3 Video Rle is a WaveSpeedAI model for AI inference, exposed as a REST API on WaveSpeedAI. SAM 3 Video RLE is a unified foundation model for prompt-based segmentation in video. Track and segment objects across frames using text, points, or boxes, returning RLE encoded masks for efficient processing. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing. You can call it programmatically or try it from the playground above.
POST your input parameters to the model's REST endpoint (shown in the API tab of this playground) with your WaveSpeedAI API key in the Authorization header. Submission returns a prediction ID; poll the prediction endpoint until status flips to "completed", then read the output URL from the result. The playground generates a ready-to-paste code sample in Python, JavaScript, or cURL for whatever inputs you've set. Full request/response shape is documented at https://wavespeed.ai/docs/docs-api/wavespeed-ai/sam3-video-rle.
Sam3 Video Rle starts at $0.050 per run. That figure is the base price — the final charge scales with the parameters you set in the form (output size, length, count, references, or whatever knobs this model exposes), so a higher-quality or larger output costs more than a minimal one. The exact cost for your current input is shown live next to the Generate button before you submit, and the actual per-call charge is recorded on the prediction afterwards.
Key inputs: `prompt`, `video`, `apply_mask`, `box_prompts`, `point_prompts`. The full JSON schema (types, defaults, allowed values) is rendered above the Generate button and mirrored in the API reference at https://wavespeed.ai/docs/docs-api/wavespeed-ai/sam3-video-rle.
Average end-to-end generation time on WaveSpeedAI is around 198 seconds per request — measured across recent runs. Queue time scales with global demand; live status is visible in the prediction record.
Commercial usage rights depend on the model's license, set by its provider (WaveSpeedAI). The license summary appears on the model card above; see WaveSpeedAI's Terms of Service for platform-level conditions.