You're looking at a specific version of this model. Jump to the model overview.
stphtan94117 /easy-remove-background:e91dc6be
Input
Run this model in Node.js with one line of code:
npm install replicate
REPLICATE_API_TOKEN
environment variableexport REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import Replicate from "replicate";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run stphtan94117/easy-remove-background using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"stphtan94117/easy-remove-background:e91dc6be6a0d4b0df921fb86b5cc6023e958db8919558711d0d04318a31a5af2",
{
input: {
file: "https://replicate.delivery/pbxt/JTqcmEtVYh05vSVxApUKWuRtCuUZsTkzvrlTgvUVg7jEy1Jr/peta135.jpg"
}
}
);
console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
REPLICATE_API_TOKEN
environment variableexport REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import replicate
Run stphtan94117/easy-remove-background using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"stphtan94117/easy-remove-background:e91dc6be6a0d4b0df921fb86b5cc6023e958db8919558711d0d04318a31a5af2",
input={
"file": "https://replicate.delivery/pbxt/JTqcmEtVYh05vSVxApUKWuRtCuUZsTkzvrlTgvUVg7jEy1Jr/peta135.jpg"
}
)
print(output)
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN
environment variableexport REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run stphtan94117/easy-remove-background 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": "e91dc6be6a0d4b0df921fb86b5cc6023e958db8919558711d0d04318a31a5af2",
"input": {
"file": "https://replicate.delivery/pbxt/JTqcmEtVYh05vSVxApUKWuRtCuUZsTkzvrlTgvUVg7jEy1Jr/peta135.jpg"
}
}' \
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": "2023-09-06T12:20:43.389694Z",
"created_at": "2023-09-06T12:19:14.720778Z",
"data_removed": false,
"error": null,
"id": "qjbpa4zb62xsasif3nnqbuupci",
"input": {
"file": "https://replicate.delivery/pbxt/JTqcmEtVYh05vSVxApUKWuRtCuUZsTkzvrlTgvUVg7jEy1Jr/peta135.jpg"
},
"logs": "Downloading data from 'https://github.com/danielgatis/rembg/releases/download/v0.0.0/u2net.onnx' to file '/root/.u2net/u2net.onnx'.\n 0%| | 0.00/176M [00:00<?, ?B/s]\n 0%|▏ | 839k/176M [00:00<00:20, 8.37MB/s]\n 1%|▌ | 2.61M/176M [00:00<00:12, 13.8MB/s]\n 3%|█ | 5.15M/176M [00:00<00:08, 19.1MB/s]\n 5%|█▋ | 8.09M/176M [00:00<00:07, 23.2MB/s]\n 6%|██▎ | 10.6M/176M [00:00<00:06, 24.0MB/s]\n 8%|██▉ | 13.7M/176M [00:00<00:06, 26.2MB/s]\n 9%|███▌ | 16.7M/176M [00:00<00:05, 27.4MB/s]\n 11%|████▎ | 19.8M/176M [00:00<00:05, 28.5MB/s]\n 13%|████▉ | 22.7M/176M [00:00<00:05, 28.7MB/s]\n 15%|█████▌ | 26.0M/176M [00:01<00:04, 30.1MB/s]\n 16%|██████▎ | 29.0M/176M [00:01<00:04, 29.9MB/s]\n 18%|██████▉ | 32.0M/176M [00:01<00:04, 29.4MB/s]\n 20%|███████▌ | 35.0M/176M [00:01<00:04, 29.5MB/s]\n 22%|████████▎ | 38.4M/176M [00:01<00:04, 31.1MB/s]\n 24%|█████████ | 41.8M/176M [00:01<00:04, 31.8MB/s]\n 26%|█████████▋ | 45.0M/176M [00:01<00:04, 30.6MB/s]\n 27%|██████████▎ | 48.0M/176M [00:01<00:04, 29.5MB/s]\n 29%|███████████ | 51.0M/176M [00:01<00:04, 29.3MB/s]\n 31%|███████████▋ | 53.9M/176M [00:01<00:04, 28.8MB/s]\n 32%|████████████▎ | 56.8M/176M [00:02<00:04, 28.9MB/s]\n 34%|████████████▉ | 59.7M/176M [00:02<00:04, 28.3MB/s]\n 36%|█████████████▌ | 62.5M/176M [00:02<00:04, 27.7MB/s]\n 37%|██████████████ | 65.3M/176M [00:02<00:04, 27.5MB/s]\n 39%|██████████████▋ | 68.2M/176M [00:02<00:03, 28.0MB/s]\n 41%|███████████████▍ | 71.4M/176M [00:02<00:03, 29.2MB/s]\n 42%|████████████████ | 74.6M/176M [00:02<00:03, 30.0MB/s]\n 44%|████████████████▊ | 77.6M/176M [00:02<00:03, 29.7MB/s]\n 46%|█████████████████▍ | 80.6M/176M [00:02<00:03, 29.7MB/s]\n 48%|██████████████████ | 83.8M/176M [00:02<00:03, 30.4MB/s]\n 50%|██████████████████▉ | 87.5M/176M [00:03<00:02, 32.3MB/s]\n 52%|███████████████████▋ | 91.3M/176M [00:03<00:02, 34.0MB/s]\n 54%|████████████████████▍ | 94.8M/176M [00:03<00:02, 34.4MB/s]\n 56%|█████████████████████▎ | 98.6M/176M [00:03<00:02, 35.3MB/s]\n 58%|██████████████████████▌ | 102M/176M [00:03<00:02, 33.4MB/s]\n 60%|███████████████████████▍ | 106M/176M [00:03<00:02, 34.3MB/s]\n 62%|████████████████████████▎ | 110M/176M [00:03<00:01, 36.4MB/s]\n 65%|█████████████████████████▏ | 114M/176M [00:03<00:01, 33.3MB/s]\n 66%|█████████████████████████▉ | 117M/176M [00:03<00:01, 31.1MB/s]\n 68%|██████████████████████████▌ | 120M/176M [00:04<00:01, 30.4MB/s]\n 70%|███████████████████████████▎ | 123M/176M [00:04<00:01, 30.2MB/s]\n 72%|████████████████████████████ | 127M/176M [00:04<00:01, 31.7MB/s]\n 74%|████████████████████████████▊ | 130M/176M [00:04<00:01, 32.6MB/s]\n 76%|█████████████████████████████▋ | 134M/176M [00:04<00:01, 33.4MB/s]\n 78%|██████████████████████████████▍ | 137M/176M [00:04<00:01, 32.6MB/s]\n 80%|███████████████████████████████ | 140M/176M [00:04<00:01, 32.0MB/s]\n 82%|███████████████████████████████▊ | 144M/176M [00:04<00:01, 32.2MB/s]\n 83%|████████████████████████████████▌ | 147M/176M [00:04<00:00, 31.3MB/s]\n 86%|█████████████████████████████████▌ | 151M/176M [00:04<00:00, 35.0MB/s]\n 88%|██████████████████████████████████▍ | 155M/176M [00:05<00:00, 36.2MB/s]\n 90%|███████████████████████████████████▏ | 159M/176M [00:05<00:00, 36.7MB/s]\n 92%|████████████████████████████████████ | 163M/176M [00:05<00:00, 34.2MB/s]\n 94%|████████████████████████████████████▊ | 166M/176M [00:05<00:00, 33.0MB/s]\n 97%|█████████████████████████████████████▋ | 170M/176M [00:05<00:00, 34.8MB/s]\n 99%|██████████████████████████████████████▌| 174M/176M [00:05<00:00, 36.3MB/s]\n0%| | 0.00/176M [00:00<?, ?B/s]\n100%|████████████████████████████████████████| 176M/176M [00:00<00:00, 838GB/s]",
"metrics": {
"predict_time": 44.76745,
"total_time": 88.668916
},
"output": "https://replicate.delivery/pbxt/EJBwfAo1WrRIQim1DrLz8pD87NEUElaj2fO4gKFe54G1EEDjA/output.png",
"started_at": "2023-09-06T12:19:58.622244Z",
"status": "succeeded",
"urls": {
"get": "https://api.replicate.com/v1/predictions/qjbpa4zb62xsasif3nnqbuupci",
"cancel": "https://api.replicate.com/v1/predictions/qjbpa4zb62xsasif3nnqbuupci/cancel"
},
"version": "e91dc6be6a0d4b0df921fb86b5cc6023e958db8919558711d0d04318a31a5af2"
}
Downloading data from 'https://github.com/danielgatis/rembg/releases/download/v0.0.0/u2net.onnx' to file '/root/.u2net/u2net.onnx'.
0%| | 0.00/176M [00:00<?, ?B/s]
0%|▏ | 839k/176M [00:00<00:20, 8.37MB/s]
1%|▌ | 2.61M/176M [00:00<00:12, 13.8MB/s]
3%|█ | 5.15M/176M [00:00<00:08, 19.1MB/s]
5%|█▋ | 8.09M/176M [00:00<00:07, 23.2MB/s]
6%|██▎ | 10.6M/176M [00:00<00:06, 24.0MB/s]
8%|██▉ | 13.7M/176M [00:00<00:06, 26.2MB/s]
9%|███▌ | 16.7M/176M [00:00<00:05, 27.4MB/s]
11%|████▎ | 19.8M/176M [00:00<00:05, 28.5MB/s]
13%|████▉ | 22.7M/176M [00:00<00:05, 28.7MB/s]
15%|█████▌ | 26.0M/176M [00:01<00:04, 30.1MB/s]
16%|██████▎ | 29.0M/176M [00:01<00:04, 29.9MB/s]
18%|██████▉ | 32.0M/176M [00:01<00:04, 29.4MB/s]
20%|███████▌ | 35.0M/176M [00:01<00:04, 29.5MB/s]
22%|████████▎ | 38.4M/176M [00:01<00:04, 31.1MB/s]
24%|█████████ | 41.8M/176M [00:01<00:04, 31.8MB/s]
26%|█████████▋ | 45.0M/176M [00:01<00:04, 30.6MB/s]
27%|██████████▎ | 48.0M/176M [00:01<00:04, 29.5MB/s]
29%|███████████ | 51.0M/176M [00:01<00:04, 29.3MB/s]
31%|███████████▋ | 53.9M/176M [00:01<00:04, 28.8MB/s]
32%|████████████▎ | 56.8M/176M [00:02<00:04, 28.9MB/s]
34%|████████████▉ | 59.7M/176M [00:02<00:04, 28.3MB/s]
36%|█████████████▌ | 62.5M/176M [00:02<00:04, 27.7MB/s]
37%|██████████████ | 65.3M/176M [00:02<00:04, 27.5MB/s]
39%|██████████████▋ | 68.2M/176M [00:02<00:03, 28.0MB/s]
41%|███████████████▍ | 71.4M/176M [00:02<00:03, 29.2MB/s]
42%|████████████████ | 74.6M/176M [00:02<00:03, 30.0MB/s]
44%|████████████████▊ | 77.6M/176M [00:02<00:03, 29.7MB/s]
46%|█████████████████▍ | 80.6M/176M [00:02<00:03, 29.7MB/s]
48%|██████████████████ | 83.8M/176M [00:02<00:03, 30.4MB/s]
50%|██████████████████▉ | 87.5M/176M [00:03<00:02, 32.3MB/s]
52%|███████████████████▋ | 91.3M/176M [00:03<00:02, 34.0MB/s]
54%|████████████████████▍ | 94.8M/176M [00:03<00:02, 34.4MB/s]
56%|█████████████████████▎ | 98.6M/176M [00:03<00:02, 35.3MB/s]
58%|██████████████████████▌ | 102M/176M [00:03<00:02, 33.4MB/s]
60%|███████████████████████▍ | 106M/176M [00:03<00:02, 34.3MB/s]
62%|████████████████████████▎ | 110M/176M [00:03<00:01, 36.4MB/s]
65%|█████████████████████████▏ | 114M/176M [00:03<00:01, 33.3MB/s]
66%|█████████████████████████▉ | 117M/176M [00:03<00:01, 31.1MB/s]
68%|██████████████████████████▌ | 120M/176M [00:04<00:01, 30.4MB/s]
70%|███████████████████████████▎ | 123M/176M [00:04<00:01, 30.2MB/s]
72%|████████████████████████████ | 127M/176M [00:04<00:01, 31.7MB/s]
74%|████████████████████████████▊ | 130M/176M [00:04<00:01, 32.6MB/s]
76%|█████████████████████████████▋ | 134M/176M [00:04<00:01, 33.4MB/s]
78%|██████████████████████████████▍ | 137M/176M [00:04<00:01, 32.6MB/s]
80%|███████████████████████████████ | 140M/176M [00:04<00:01, 32.0MB/s]
82%|███████████████████████████████▊ | 144M/176M [00:04<00:01, 32.2MB/s]
83%|████████████████████████████████▌ | 147M/176M [00:04<00:00, 31.3MB/s]
86%|█████████████████████████████████▌ | 151M/176M [00:04<00:00, 35.0MB/s]
88%|██████████████████████████████████▍ | 155M/176M [00:05<00:00, 36.2MB/s]
90%|███████████████████████████████████▏ | 159M/176M [00:05<00:00, 36.7MB/s]
92%|████████████████████████████████████ | 163M/176M [00:05<00:00, 34.2MB/s]
94%|████████████████████████████████████▊ | 166M/176M [00:05<00:00, 33.0MB/s]
97%|█████████████████████████████████████▋ | 170M/176M [00:05<00:00, 34.8MB/s]
99%|██████████████████████████████████████▌| 174M/176M [00:05<00:00, 36.3MB/s]
0%| | 0.00/176M [00:00<?, ?B/s]
100%|████████████████████████████████████████| 176M/176M [00:00<00:00, 838GB/s]