You're looking at a specific version of this model. Jump to the model overview.
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";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run fofr/illusions using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"fofr/illusions:7f0be5988e9838359a66b7481bb9b18290eb11a3ae76ccedd9c9bafd14f5bf7b",
{
input: {
seed: -1,
image: "https://replicate.delivery/pbxt/JouANiZNiW2mwouIgIk1VySvjL9MBmaPD6Ib8HyfW81CJzRR/out-0-44.png",
width: 768,
height: 768,
prompt: "a oil painting of a 19th century town, detailed textures, masterpiece",
num_outputs: 1,
control_image: "https://replicate.delivery/pbxt/JpU8SBPAZv0avvZ03CNqkiRBZlexOgeYEDjXg2UcBqF7tmeh/checkers_mid.jpg",
guidance_scale: 7.5,
negative_prompt: "ugly, disfigured, low quality, blurry, nsfw",
prompt_strength: 0.85,
sizing_strategy: "width/height",
num_inference_steps: 40,
controlnet_conditioning_scale: 1.8
}
}
);
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 variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import replicate
Run fofr/illusions using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"fofr/illusions:7f0be5988e9838359a66b7481bb9b18290eb11a3ae76ccedd9c9bafd14f5bf7b",
input={
"seed": -1,
"image": "https://replicate.delivery/pbxt/JouANiZNiW2mwouIgIk1VySvjL9MBmaPD6Ib8HyfW81CJzRR/out-0-44.png",
"width": 768,
"height": 768,
"prompt": "a oil painting of a 19th century town, detailed textures, masterpiece",
"num_outputs": 1,
"control_image": "https://replicate.delivery/pbxt/JpU8SBPAZv0avvZ03CNqkiRBZlexOgeYEDjXg2UcBqF7tmeh/checkers_mid.jpg",
"guidance_scale": 7.5,
"negative_prompt": "ugly, disfigured, low quality, blurry, nsfw",
"prompt_strength": 0.85,
"sizing_strategy": "width/height",
"num_inference_steps": 40,
"controlnet_conditioning_scale": 1.8
}
)
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 fofr/illusions 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": "7f0be5988e9838359a66b7481bb9b18290eb11a3ae76ccedd9c9bafd14f5bf7b",
"input": {
"seed": -1,
"image": "https://replicate.delivery/pbxt/JouANiZNiW2mwouIgIk1VySvjL9MBmaPD6Ib8HyfW81CJzRR/out-0-44.png",
"width": 768,
"height": 768,
"prompt": "a oil painting of a 19th century town, detailed textures, masterpiece",
"num_outputs": 1,
"control_image": "https://replicate.delivery/pbxt/JpU8SBPAZv0avvZ03CNqkiRBZlexOgeYEDjXg2UcBqF7tmeh/checkers_mid.jpg",
"guidance_scale": 7.5,
"negative_prompt": "ugly, disfigured, low quality, blurry, nsfw",
"prompt_strength": 0.85,
"sizing_strategy": "width/height",
"num_inference_steps": 40,
"controlnet_conditioning_scale": 1.8
}
}' \
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-11-06T11:18:14.742806Z",
"created_at": "2023-11-06T11:18:08.114850Z",
"data_removed": false,
"error": null,
"id": "fa67gn3bgwlp3idv2ylncbla4e",
"input": {
"seed": -1,
"image": "https://replicate.delivery/pbxt/JouANiZNiW2mwouIgIk1VySvjL9MBmaPD6Ib8HyfW81CJzRR/out-0-44.png",
"width": 768,
"height": 768,
"prompt": "a oil painting of a 19th century town, detailed textures, masterpiece",
"num_outputs": 1,
"control_image": "https://replicate.delivery/pbxt/JpU8SBPAZv0avvZ03CNqkiRBZlexOgeYEDjXg2UcBqF7tmeh/checkers_mid.jpg",
"guidance_scale": 7.5,
"negative_prompt": "ugly, disfigured, low quality, blurry, nsfw",
"prompt_strength": 0.85,
"sizing_strategy": "width/height",
"num_inference_steps": 40,
"controlnet_conditioning_scale": 1.8
},
"logs": "img2img mode\nUsing given dimensions\n 0%| | 0/34 [00:00<?, ?it/s]\n 3%|▎ | 1/34 [00:00<00:07, 4.24it/s]\n 6%|▌ | 2/34 [00:00<00:05, 5.98it/s]\n 9%|▉ | 3/34 [00:00<00:04, 6.88it/s]\n 12%|█▏ | 4/34 [00:00<00:04, 7.40it/s]\n 15%|█▍ | 5/34 [00:00<00:03, 7.73it/s]\n 18%|█▊ | 6/34 [00:00<00:03, 7.95it/s]\n 21%|██ | 7/34 [00:00<00:03, 8.08it/s]\n 24%|██▎ | 8/34 [00:01<00:03, 8.17it/s]\n 26%|██▋ | 9/34 [00:01<00:03, 8.23it/s]\n 29%|██▉ | 10/34 [00:01<00:02, 8.27it/s]\n 32%|███▏ | 11/34 [00:01<00:02, 8.31it/s]\n 35%|███▌ | 12/34 [00:01<00:02, 8.33it/s]\n 38%|███▊ | 13/34 [00:01<00:02, 8.34it/s]\n 41%|████ | 14/34 [00:01<00:02, 8.35it/s]\n 44%|████▍ | 15/34 [00:01<00:02, 8.35it/s]\n 47%|████▋ | 16/34 [00:02<00:02, 8.35it/s]\n 50%|█████ | 17/34 [00:02<00:02, 8.36it/s]\n 53%|█████▎ | 18/34 [00:02<00:01, 8.37it/s]\n 56%|█████▌ | 19/34 [00:02<00:01, 8.37it/s]\n 59%|█████▉ | 20/34 [00:02<00:01, 8.37it/s]\n 62%|██████▏ | 21/34 [00:02<00:01, 8.37it/s]\n 65%|██████▍ | 22/34 [00:02<00:01, 8.37it/s]\n 68%|██████▊ | 23/34 [00:02<00:01, 8.37it/s]\n 71%|███████ | 24/34 [00:02<00:01, 8.37it/s]\n 74%|███████▎ | 25/34 [00:03<00:01, 8.36it/s]\n 76%|███████▋ | 26/34 [00:03<00:00, 8.36it/s]\n 79%|███████▉ | 27/34 [00:03<00:00, 8.37it/s]\n 82%|████████▏ | 28/34 [00:03<00:00, 8.36it/s]\n 85%|████████▌ | 29/34 [00:03<00:00, 8.36it/s]\n 88%|████████▊ | 30/34 [00:03<00:00, 8.36it/s]\n 91%|█████████ | 31/34 [00:03<00:00, 8.38it/s]\n 94%|█████████▍| 32/34 [00:03<00:00, 8.39it/s]\n 97%|█████████▋| 33/34 [00:04<00:00, 8.40it/s]\n100%|██████████| 34/34 [00:04<00:00, 8.40it/s]\n100%|██████████| 34/34 [00:04<00:00, 8.14it/s]",
"metrics": {
"predict_time": 6.633376,
"total_time": 6.627956
},
"output": [
"https://replicate.delivery/pbxt/0RhRq9yiZgbaAVC9rgWHo9sjOEB2D3KpGieB4hcCm6i66z6IA/output-0.png"
],
"started_at": "2023-11-06T11:18:08.109430Z",
"status": "succeeded",
"urls": {
"get": "https://api.replicate.com/v1/predictions/fa67gn3bgwlp3idv2ylncbla4e",
"cancel": "https://api.replicate.com/v1/predictions/fa67gn3bgwlp3idv2ylncbla4e/cancel"
},
"version": "7f0be5988e9838359a66b7481bb9b18290eb11a3ae76ccedd9c9bafd14f5bf7b"
}
img2img mode
Using given dimensions
0%| | 0/34 [00:00<?, ?it/s]
3%|▎ | 1/34 [00:00<00:07, 4.24it/s]
6%|▌ | 2/34 [00:00<00:05, 5.98it/s]
9%|▉ | 3/34 [00:00<00:04, 6.88it/s]
12%|█▏ | 4/34 [00:00<00:04, 7.40it/s]
15%|█▍ | 5/34 [00:00<00:03, 7.73it/s]
18%|█▊ | 6/34 [00:00<00:03, 7.95it/s]
21%|██ | 7/34 [00:00<00:03, 8.08it/s]
24%|██▎ | 8/34 [00:01<00:03, 8.17it/s]
26%|██▋ | 9/34 [00:01<00:03, 8.23it/s]
29%|██▉ | 10/34 [00:01<00:02, 8.27it/s]
32%|███▏ | 11/34 [00:01<00:02, 8.31it/s]
35%|███▌ | 12/34 [00:01<00:02, 8.33it/s]
38%|███▊ | 13/34 [00:01<00:02, 8.34it/s]
41%|████ | 14/34 [00:01<00:02, 8.35it/s]
44%|████▍ | 15/34 [00:01<00:02, 8.35it/s]
47%|████▋ | 16/34 [00:02<00:02, 8.35it/s]
50%|█████ | 17/34 [00:02<00:02, 8.36it/s]
53%|█████▎ | 18/34 [00:02<00:01, 8.37it/s]
56%|█████▌ | 19/34 [00:02<00:01, 8.37it/s]
59%|█████▉ | 20/34 [00:02<00:01, 8.37it/s]
62%|██████▏ | 21/34 [00:02<00:01, 8.37it/s]
65%|██████▍ | 22/34 [00:02<00:01, 8.37it/s]
68%|██████▊ | 23/34 [00:02<00:01, 8.37it/s]
71%|███████ | 24/34 [00:02<00:01, 8.37it/s]
74%|███████▎ | 25/34 [00:03<00:01, 8.36it/s]
76%|███████▋ | 26/34 [00:03<00:00, 8.36it/s]
79%|███████▉ | 27/34 [00:03<00:00, 8.37it/s]
82%|████████▏ | 28/34 [00:03<00:00, 8.36it/s]
85%|████████▌ | 29/34 [00:03<00:00, 8.36it/s]
88%|████████▊ | 30/34 [00:03<00:00, 8.36it/s]
91%|█████████ | 31/34 [00:03<00:00, 8.38it/s]
94%|█████████▍| 32/34 [00:03<00:00, 8.39it/s]
97%|█████████▋| 33/34 [00:04<00:00, 8.40it/s]
100%|██████████| 34/34 [00:04<00:00, 8.40it/s]
100%|██████████| 34/34 [00:04<00:00, 8.14it/s]