defaulta magpie wearing a tophat
typetext
{
"canny": "https://replicate.delivery/pbxt/IrarVflkkV3TsUxP0sggxmthggyLFpUxrfOgY1CINeDbMY2J/canny_man.png",
"canny_weight": 1,
"depth": "https://replicate.delivery/pbxt/IrarW1cJkljr1M6wZgoOqf5H1ERAobcp25R3VVpTe38hukqb/empty.png",
"mlsd": "https://replicate.delivery/pbxt/IrarWDb4d9n1pWwEV3na6aZogpYW0qpwZ4FNIFxq3B21nrPU/empty.png",
"negative_prompt": "monochrome, lowres, bad anatomy, worst quality, low quality",
"pose": "https://replicate.delivery/pbxt/IrarVkMTOYSZ08KZWAMcA3ed87zelT55XdfoYaq4drAWI4G1/pose_man.png",
"pose_weight": 0.8,
"prompt": "a giant standing in a fantasy landscape, best quality",
"seg": "https://replicate.delivery/pbxt/IrarVUc6AdoRj3e5ypGIPSVHsThTOsAGZoD4xnsSJOzsVXt9/empty.png",
"softedge": "https://replicate.delivery/pbxt/IrarVcg0YvuRzjA6G0yelEeGq8IbQFIktkjga3X9zbxEJTYs/empty.png"
}npm install replicate
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_K0T**********************************
This is your API token. Keep it to yourself.
import Replicate from "replicate";
import fs from "node:fs";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run mikelyndon/controlnet-multi using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"mikelyndon/controlnet-multi:69d16083e38779cdb340f7343a6594611b6b65ffd7715f783eef53b9640268e6",
{
input: {
canny: "https://replicate.delivery/pbxt/IrarVflkkV3TsUxP0sggxmthggyLFpUxrfOgY1CINeDbMY2J/canny_man.png",
canny_weight: 1,
depth: "https://replicate.delivery/pbxt/IrarW1cJkljr1M6wZgoOqf5H1ERAobcp25R3VVpTe38hukqb/empty.png",
mlsd: "https://replicate.delivery/pbxt/IrarWDb4d9n1pWwEV3na6aZogpYW0qpwZ4FNIFxq3B21nrPU/empty.png",
negative_prompt: "monochrome, lowres, bad anatomy, worst quality, low quality",
pose: "https://replicate.delivery/pbxt/IrarVkMTOYSZ08KZWAMcA3ed87zelT55XdfoYaq4drAWI4G1/pose_man.png",
pose_weight: 0.8,
prompt: "a giant standing in a fantasy landscape, best quality",
seg: "https://replicate.delivery/pbxt/IrarVUc6AdoRj3e5ypGIPSVHsThTOsAGZoD4xnsSJOzsVXt9/empty.png",
softedge: "https://replicate.delivery/pbxt/IrarVcg0YvuRzjA6G0yelEeGq8IbQFIktkjga3X9zbxEJTYs/empty.png"
}
}
);
// 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=r8_K0T**********************************
This is your API token. Keep it to yourself.
import replicate
Run mikelyndon/controlnet-multi using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"mikelyndon/controlnet-multi:69d16083e38779cdb340f7343a6594611b6b65ffd7715f783eef53b9640268e6",
input={
"canny": "https://replicate.delivery/pbxt/IrarVflkkV3TsUxP0sggxmthggyLFpUxrfOgY1CINeDbMY2J/canny_man.png",
"canny_weight": 1,
"depth": "https://replicate.delivery/pbxt/IrarW1cJkljr1M6wZgoOqf5H1ERAobcp25R3VVpTe38hukqb/empty.png",
"mlsd": "https://replicate.delivery/pbxt/IrarWDb4d9n1pWwEV3na6aZogpYW0qpwZ4FNIFxq3B21nrPU/empty.png",
"negative_prompt": "monochrome, lowres, bad anatomy, worst quality, low quality",
"pose": "https://replicate.delivery/pbxt/IrarVkMTOYSZ08KZWAMcA3ed87zelT55XdfoYaq4drAWI4G1/pose_man.png",
"pose_weight": 0.8,
"prompt": "a giant standing in a fantasy landscape, best quality",
"seg": "https://replicate.delivery/pbxt/IrarVUc6AdoRj3e5ypGIPSVHsThTOsAGZoD4xnsSJOzsVXt9/empty.png",
"softedge": "https://replicate.delivery/pbxt/IrarVcg0YvuRzjA6G0yelEeGq8IbQFIktkjga3X9zbxEJTYs/empty.png"
}
)
# To access the file URL:
print(output.url())
#=> "http://example.com"
# To write the file to disk:
with open("my-image.png", "wb") as file:
file.write(output.read())
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_K0T**********************************
This is your API token. Keep it to yourself.
Run mikelyndon/controlnet-multi 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": "mikelyndon/controlnet-multi:69d16083e38779cdb340f7343a6594611b6b65ffd7715f783eef53b9640268e6",
"input": {
"canny": "https://replicate.delivery/pbxt/IrarVflkkV3TsUxP0sggxmthggyLFpUxrfOgY1CINeDbMY2J/canny_man.png",
"canny_weight": 1,
"depth": "https://replicate.delivery/pbxt/IrarW1cJkljr1M6wZgoOqf5H1ERAobcp25R3VVpTe38hukqb/empty.png",
"mlsd": "https://replicate.delivery/pbxt/IrarWDb4d9n1pWwEV3na6aZogpYW0qpwZ4FNIFxq3B21nrPU/empty.png",
"negative_prompt": "monochrome, lowres, bad anatomy, worst quality, low quality",
"pose": "https://replicate.delivery/pbxt/IrarVkMTOYSZ08KZWAMcA3ed87zelT55XdfoYaq4drAWI4G1/pose_man.png",
"pose_weight": 0.8,
"prompt": "a giant standing in a fantasy landscape, best quality",
"seg": "https://replicate.delivery/pbxt/IrarVUc6AdoRj3e5ypGIPSVHsThTOsAGZoD4xnsSJOzsVXt9/empty.png",
"softedge": "https://replicate.delivery/pbxt/IrarVcg0YvuRzjA6G0yelEeGq8IbQFIktkjga3X9zbxEJTYs/empty.png"
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
{
"id": "km2pxk6pbrbn5jkwbl2qg5jhkq",
"model": "mikelyndon/controlnet-multi",
"version": "69d16083e38779cdb340f7343a6594611b6b65ffd7715f783eef53b9640268e6",
"input": {
"canny": "https://replicate.delivery/pbxt/IrarVflkkV3TsUxP0sggxmthggyLFpUxrfOgY1CINeDbMY2J/canny_man.png",
"canny_weight": 1,
"depth": "https://replicate.delivery/pbxt/IrarW1cJkljr1M6wZgoOqf5H1ERAobcp25R3VVpTe38hukqb/empty.png",
"mlsd": "https://replicate.delivery/pbxt/IrarWDb4d9n1pWwEV3na6aZogpYW0qpwZ4FNIFxq3B21nrPU/empty.png",
"negative_prompt": "monochrome, lowres, bad anatomy, worst quality, low quality",
"pose": "https://replicate.delivery/pbxt/IrarVkMTOYSZ08KZWAMcA3ed87zelT55XdfoYaq4drAWI4G1/pose_man.png",
"pose_weight": 0.8,
"prompt": "a giant standing in a fantasy landscape, best quality",
"seg": "https://replicate.delivery/pbxt/IrarVUc6AdoRj3e5ypGIPSVHsThTOsAGZoD4xnsSJOzsVXt9/empty.png",
"softedge": "https://replicate.delivery/pbxt/IrarVcg0YvuRzjA6G0yelEeGq8IbQFIktkjga3X9zbxEJTYs/empty.png"
},
"logs": "0%| | 0/20 [00:00<?, ?it/s]\n 5%|▌ | 1/20 [00:05<01:42, 5.39s/it]\n 10%|█ | 2/20 [00:06<00:48, 2.67s/it]\n 15%|█▌ | 3/20 [00:08<00:46, 2.72s/it]\n 20%|██ | 4/20 [00:09<00:31, 1.98s/it]\n 25%|██▌ | 5/20 [00:10<00:23, 1.54s/it]\n 30%|███ | 6/20 [00:11<00:17, 1.27s/it]\n 35%|███▌ | 7/20 [00:12<00:14, 1.11s/it]\n 40%|████ | 8/20 [00:12<00:11, 1.00it/s]\n 45%|████▌ | 9/20 [00:13<00:10, 1.08it/s]\n 50%|█████ | 10/20 [00:14<00:08, 1.15it/s]\n 55%|█████▌ | 11/20 [00:15<00:07, 1.19it/s]\n 60%|██████ | 12/20 [00:15<00:06, 1.23it/s]\n 65%|██████▌ | 13/20 [00:16<00:05, 1.25it/s]\n 70%|███████ | 14/20 [00:17<00:04, 1.27it/s]\n 75%|███████▌ | 15/20 [00:18<00:03, 1.28it/s]\n 80%|████████ | 16/20 [00:18<00:03, 1.29it/s]\n 85%|████████▌ | 17/20 [00:19<00:02, 1.29it/s]\n 90%|█████████ | 18/20 [00:20<00:01, 1.29it/s]\n 95%|█████████▌| 19/20 [00:21<00:00, 1.30it/s]\n100%|██████████| 20/20 [00:21<00:00, 1.30it/s]\n100%|██████████| 20/20 [00:21<00:00, 1.10s/it]\nout_path /tmp/tmptvzifqnz/out.png",
"output": "https://replicate.delivery/pbxt/5Ns7TZxLyuZ6BRgrqpB2o2RuPEwvD45P6ozuJc2f2amEZAfQA/out.png",
"data_removed": false,
"error": null,
"source": "web",
"status": "succeeded",
"created_at": "2023-05-21T17:48:03.302041Z",
"started_at": "2023-05-21T17:52:40.050105Z",
"completed_at": "2023-05-21T17:53:14.803147Z",
"urls": {
"cancel": "https://api.replicate.com/v1/predictions/km2pxk6pbrbn5jkwbl2qg5jhkq/cancel",
"get": "https://api.replicate.com/v1/predictions/km2pxk6pbrbn5jkwbl2qg5jhkq"
},
"metrics": {
"predict_time": 34.753042,
"total_time": 311.501106
}
}





