Failed to load versions. Head to the versions page to see all versions for this model.
You're looking at a specific version of this model. Jump to the model overview.
andreasjansson /wan-1.3b-inpaint:bb93dcca
Input
Run this model in Node.js with one line of code:
npm install replicate
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import Replicate from "replicate";
import fs from "node:fs";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run andreasjansson/wan-1.3b-inpaint using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"andreasjansson/wan-1.3b-inpaint:bb93dccacce86d677ee58455ac15d559a5d9956b61c39260b5779d5bc143b55a",
{
input: {
seed: -1,
prompt: "A robot walking on the street",
strength: 0.9,
mask_video: "https://replicate.delivery/xezq/N94eQyo3WBVWXyN8Aj4kpwQ42l6prb578m9tCJWaFgREnlJKA/masked_video.mp4",
expand_mask: 10,
guide_scale: 5,
input_video: "https://replicate.delivery/xezq/UpqkYwl7hTqTJ5rfIE0eb5WpDv6quG6PeFcdtH157Y2uonloA/tmp2dc62s6m.output.mp4",
sampling_steps: 30,
negative_prompt: "",
frames_per_second: 16,
inpaint_fixup_steps: 0
}
}
);
// To access the file URL:
console.log(output.url()); //=> "http://example.com"
// To write the file to disk:
fs.writeFile("my-image.png", output);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import replicate
Run andreasjansson/wan-1.3b-inpaint using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"andreasjansson/wan-1.3b-inpaint:bb93dccacce86d677ee58455ac15d559a5d9956b61c39260b5779d5bc143b55a",
input={
"seed": -1,
"prompt": "A robot walking on the street",
"strength": 0.9,
"mask_video": "https://replicate.delivery/xezq/N94eQyo3WBVWXyN8Aj4kpwQ42l6prb578m9tCJWaFgREnlJKA/masked_video.mp4",
"expand_mask": 10,
"guide_scale": 5,
"input_video": "https://replicate.delivery/xezq/UpqkYwl7hTqTJ5rfIE0eb5WpDv6quG6PeFcdtH157Y2uonloA/tmp2dc62s6m.output.mp4",
"sampling_steps": 30,
"negative_prompt": "",
"frames_per_second": 16,
"inpaint_fixup_steps": 0
}
)
print(output)
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run andreasjansson/wan-1.3b-inpaint using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
curl -s -X POST \
-H "Authorization: Bearer $REPLICATE_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Prefer: wait" \
-d $'{
"version": "andreasjansson/wan-1.3b-inpaint:bb93dccacce86d677ee58455ac15d559a5d9956b61c39260b5779d5bc143b55a",
"input": {
"seed": -1,
"prompt": "A robot walking on the street",
"strength": 0.9,
"mask_video": "https://replicate.delivery/xezq/N94eQyo3WBVWXyN8Aj4kpwQ42l6prb578m9tCJWaFgREnlJKA/masked_video.mp4",
"expand_mask": 10,
"guide_scale": 5,
"input_video": "https://replicate.delivery/xezq/UpqkYwl7hTqTJ5rfIE0eb5WpDv6quG6PeFcdtH157Y2uonloA/tmp2dc62s6m.output.mp4",
"sampling_steps": 30,
"negative_prompt": "",
"frames_per_second": 16,
"inpaint_fixup_steps": 0
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
Add a payment method to run this model.
By signing in, you agree to our
terms of service and privacy policy
Output
{
"completed_at": "2025-03-03T18:21:44.942973Z",
"created_at": "2025-03-03T18:14:54.676000Z",
"data_removed": false,
"error": null,
"id": "y3fa9eekthrme0cnbmvsjherc0",
"input": {
"seed": -1,
"prompt": "A robot walking on the street",
"strength": 0.9,
"mask_video": "https://replicate.delivery/xezq/N94eQyo3WBVWXyN8Aj4kpwQ42l6prb578m9tCJWaFgREnlJKA/masked_video.mp4",
"expand_mask": 10,
"guide_scale": 5,
"input_video": "https://replicate.delivery/xezq/UpqkYwl7hTqTJ5rfIE0eb5WpDv6quG6PeFcdtH157Y2uonloA/tmp2dc62s6m.output.mp4",
"sampling_steps": 30,
"negative_prompt": "",
"frames_per_second": 16,
"inpaint_fixup_steps": 0
},
"logs": "Using seed: 3692929301\nLoaded 141 frames from /tmp/tmpywa_qk39tmp2dc62s6m.output.mp4\nLoaded 141 frames from /tmp/tmpthdg8haymasked_video.mp4\n 0%| | 0/27 [00:00<?, ?it/s]\n 4%|▎ | 1/27 [00:14<06:15, 14.44s/it]\n 7%|▋ | 2/27 [00:28<06:01, 14.45s/it]\n 11%|█ | 3/27 [00:43<05:47, 14.46s/it]\n 15%|█▍ | 4/27 [00:57<05:32, 14.46s/it]\n 19%|█▊ | 5/27 [01:12<05:18, 14.46s/it]\n 22%|██▏ | 6/27 [01:26<05:03, 14.47s/it]\n 26%|██▌ | 7/27 [01:41<04:49, 14.47s/it]\n 30%|██▉ | 8/27 [01:55<04:34, 14.46s/it]\n 33%|███▎ | 9/27 [02:10<04:20, 14.47s/it]\n 37%|███▋ | 10/27 [02:24<04:05, 14.47s/it]\n 41%|████ | 11/27 [02:39<03:51, 14.47s/it]\n 44%|████▍ | 12/27 [02:53<03:37, 14.47s/it]\n 48%|████▊ | 13/27 [03:08<03:22, 14.47s/it]\n 52%|█████▏ | 14/27 [03:22<03:08, 14.47s/it]\n 56%|█████▌ | 15/27 [03:36<02:53, 14.47s/it]\n 59%|█████▉ | 16/27 [03:51<02:39, 14.47s/it]\n 63%|██████▎ | 17/27 [04:05<02:24, 14.47s/it]\n 67%|██████▋ | 18/27 [04:20<02:10, 14.47s/it]\n 70%|███████ | 19/27 [04:34<01:55, 14.47s/it]\n 74%|███████▍ | 20/27 [04:49<01:41, 14.47s/it]\n 78%|███████▊ | 21/27 [05:03<01:26, 14.47s/it]\n 81%|████████▏ | 22/27 [05:18<01:12, 14.47s/it]\n 85%|████████▌ | 23/27 [05:32<00:57, 14.46s/it]\n 89%|████████▉ | 24/27 [05:47<00:43, 14.46s/it]\n 93%|█████████▎| 25/27 [06:01<00:28, 14.46s/it]\n 96%|█████████▋| 26/27 [06:16<00:14, 14.46s/it]\n100%|██████████| 27/27 [06:30<00:00, 14.46s/it]\n100%|██████████| 27/27 [06:30<00:00, 14.46s/it]\nMoviepy - Building video output.mp4.\nMoviepy - Writing video output.mp4\nt: 0%| | 0/141 [00:00<?, ?it/s, now=None]\nt: 8%|▊ | 11/141 [00:00<00:01, 105.39it/s, now=None]\nt: 16%|█▌ | 22/141 [00:00<00:01, 104.08it/s, now=None]\nt: 23%|██▎ | 33/141 [00:00<00:01, 103.61it/s, now=None]\nt: 31%|███ | 44/141 [00:00<00:00, 103.81it/s, now=None]\nt: 39%|███▉ | 55/141 [00:00<00:00, 100.08it/s, now=None]\nt: 47%|████▋ | 66/141 [00:00<00:00, 93.21it/s, now=None] \nt: 55%|█████▍ | 77/141 [00:00<00:00, 95.89it/s, now=None]\nt: 62%|██████▏ | 87/141 [00:00<00:00, 93.66it/s, now=None]\nt: 69%|██████▉ | 97/141 [00:01<00:00, 93.10it/s, now=None]\nt: 76%|███████▌ | 107/141 [00:01<00:00, 90.07it/s, now=None]\nt: 83%|████████▎ | 117/141 [00:01<00:00, 86.44it/s, now=None]\nt: 89%|████████▉ | 126/141 [00:01<00:00, 87.00it/s, now=None]\nt: 96%|█████████▌| 135/141 [00:01<00:00, 84.94it/s, now=None]\nMoviepy - Done !\nMoviepy - video ready output.mp4\nSaved video to output.mp4",
"metrics": {
"predict_time": 410.259106365,
"total_time": 410.266973
},
"output": "https://replicate.delivery/xezq/KII1QARYVCaDH1ElIipMcUEa1sXNjHC43XPtqg8le1UcKdKKA/output.mp4",
"started_at": "2025-03-03T18:14:54.683866Z",
"status": "succeeded",
"urls": {
"stream": "https://stream.replicate.com/v1/files/bcwr-nkihi3yhjuukbbwr6f4aizsklcdblz54lnt65hyhyjh6hfmloglq",
"get": "https://api.replicate.com/v1/predictions/y3fa9eekthrme0cnbmvsjherc0",
"cancel": "https://api.replicate.com/v1/predictions/y3fa9eekthrme0cnbmvsjherc0/cancel"
},
"version": "bb93dccacce86d677ee58455ac15d559a5d9956b61c39260b5779d5bc143b55a"
}
Using seed: 3692929301
Loaded 141 frames from /tmp/tmpywa_qk39tmp2dc62s6m.output.mp4
Loaded 141 frames from /tmp/tmpthdg8haymasked_video.mp4
0%| | 0/27 [00:00<?, ?it/s]
4%|▎ | 1/27 [00:14<06:15, 14.44s/it]
7%|▋ | 2/27 [00:28<06:01, 14.45s/it]
11%|█ | 3/27 [00:43<05:47, 14.46s/it]
15%|█▍ | 4/27 [00:57<05:32, 14.46s/it]
19%|█▊ | 5/27 [01:12<05:18, 14.46s/it]
22%|██▏ | 6/27 [01:26<05:03, 14.47s/it]
26%|██▌ | 7/27 [01:41<04:49, 14.47s/it]
30%|██▉ | 8/27 [01:55<04:34, 14.46s/it]
33%|███▎ | 9/27 [02:10<04:20, 14.47s/it]
37%|███▋ | 10/27 [02:24<04:05, 14.47s/it]
41%|████ | 11/27 [02:39<03:51, 14.47s/it]
44%|████▍ | 12/27 [02:53<03:37, 14.47s/it]
48%|████▊ | 13/27 [03:08<03:22, 14.47s/it]
52%|█████▏ | 14/27 [03:22<03:08, 14.47s/it]
56%|█████▌ | 15/27 [03:36<02:53, 14.47s/it]
59%|█████▉ | 16/27 [03:51<02:39, 14.47s/it]
63%|██████▎ | 17/27 [04:05<02:24, 14.47s/it]
67%|██████▋ | 18/27 [04:20<02:10, 14.47s/it]
70%|███████ | 19/27 [04:34<01:55, 14.47s/it]
74%|███████▍ | 20/27 [04:49<01:41, 14.47s/it]
78%|███████▊ | 21/27 [05:03<01:26, 14.47s/it]
81%|████████▏ | 22/27 [05:18<01:12, 14.47s/it]
85%|████████▌ | 23/27 [05:32<00:57, 14.46s/it]
89%|████████▉ | 24/27 [05:47<00:43, 14.46s/it]
93%|█████████▎| 25/27 [06:01<00:28, 14.46s/it]
96%|█████████▋| 26/27 [06:16<00:14, 14.46s/it]
100%|██████████| 27/27 [06:30<00:00, 14.46s/it]
100%|██████████| 27/27 [06:30<00:00, 14.46s/it]
Moviepy - Building video output.mp4.
Moviepy - Writing video output.mp4
t: 0%| | 0/141 [00:00<?, ?it/s, now=None]
t: 8%|▊ | 11/141 [00:00<00:01, 105.39it/s, now=None]
t: 16%|█▌ | 22/141 [00:00<00:01, 104.08it/s, now=None]
t: 23%|██▎ | 33/141 [00:00<00:01, 103.61it/s, now=None]
t: 31%|███ | 44/141 [00:00<00:00, 103.81it/s, now=None]
t: 39%|███▉ | 55/141 [00:00<00:00, 100.08it/s, now=None]
t: 47%|████▋ | 66/141 [00:00<00:00, 93.21it/s, now=None]
t: 55%|█████▍ | 77/141 [00:00<00:00, 95.89it/s, now=None]
t: 62%|██████▏ | 87/141 [00:00<00:00, 93.66it/s, now=None]
t: 69%|██████▉ | 97/141 [00:01<00:00, 93.10it/s, now=None]
t: 76%|███████▌ | 107/141 [00:01<00:00, 90.07it/s, now=None]
t: 83%|████████▎ | 117/141 [00:01<00:00, 86.44it/s, now=None]
t: 89%|████████▉ | 126/141 [00:01<00:00, 87.00it/s, now=None]
t: 96%|█████████▌| 135/141 [00:01<00:00, 84.94it/s, now=None]
Moviepy - Done !
Moviepy - video ready output.mp4
Saved video to output.mp4