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.
tgohblio /instant-id-albedobase-xl:2a2afbff
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 tgohblio/instant-id-albedobase-xl using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"tgohblio/instant-id-albedobase-xl:2a2afbff09996b53247b0714577d4ff82d2c9da8e8b00c5499b5b34510bb8b5e",
{
input: {
image: "https://replicate.delivery/pbxt/KIuaBkQJUNjzsAce8hZDbWmKAdOYIhoeCcyA4EBoguEnhjDU/bp_lisa.png",
width: 640,
height: 640,
prompt: "photorealistic RAW photo by rob hefferan, fashionista woman wearing gorgeous floral dress with victorian hat, highly detailed skin pores, 4K, sharp focus, deep shadows, beautiful spring season, vibrant small flowers, masterpiece",
guidance_scale: 0,
safety_checker: true,
negative_prompt: "amateur quality, vague shapes, vague texture, wrong perspective, wrong angle, ugly, dowdy style, grainy",
ip_adapter_scale: 0.8,
num_inference_steps: 6,
controlnet_conditioning_scale: 0.8
}
}
);
// 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 tgohblio/instant-id-albedobase-xl using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"tgohblio/instant-id-albedobase-xl:2a2afbff09996b53247b0714577d4ff82d2c9da8e8b00c5499b5b34510bb8b5e",
input={
"image": "https://replicate.delivery/pbxt/KIuaBkQJUNjzsAce8hZDbWmKAdOYIhoeCcyA4EBoguEnhjDU/bp_lisa.png",
"width": 640,
"height": 640,
"prompt": "photorealistic RAW photo by rob hefferan, fashionista woman wearing gorgeous floral dress with victorian hat, highly detailed skin pores, 4K, sharp focus, deep shadows, beautiful spring season, vibrant small flowers, masterpiece",
"guidance_scale": 0,
"safety_checker": True,
"negative_prompt": "amateur quality, vague shapes, vague texture, wrong perspective, wrong angle, ugly, dowdy style, grainy",
"ip_adapter_scale": 0.8,
"num_inference_steps": 6,
"controlnet_conditioning_scale": 0.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 tgohblio/instant-id-albedobase-xl 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": "tgohblio/instant-id-albedobase-xl:2a2afbff09996b53247b0714577d4ff82d2c9da8e8b00c5499b5b34510bb8b5e",
"input": {
"image": "https://replicate.delivery/pbxt/KIuaBkQJUNjzsAce8hZDbWmKAdOYIhoeCcyA4EBoguEnhjDU/bp_lisa.png",
"width": 640,
"height": 640,
"prompt": "photorealistic RAW photo by rob hefferan, fashionista woman wearing gorgeous floral dress with victorian hat, highly detailed skin pores, 4K, sharp focus, deep shadows, beautiful spring season, vibrant small flowers, masterpiece",
"guidance_scale": 0,
"safety_checker": true,
"negative_prompt": "amateur quality, vague shapes, vague texture, wrong perspective, wrong angle, ugly, dowdy style, grainy",
"ip_adapter_scale": 0.8,
"num_inference_steps": 6,
"controlnet_conditioning_scale": 0.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": "2024-01-28T08:57:12.115544Z",
"created_at": "2024-01-28T08:56:57.964762Z",
"data_removed": false,
"error": null,
"id": "ld7kjulbo72xixtgpn3vsl4tv4",
"input": {
"image": "https://replicate.delivery/pbxt/KIuaBkQJUNjzsAce8hZDbWmKAdOYIhoeCcyA4EBoguEnhjDU/bp_lisa.png",
"width": 640,
"height": 640,
"prompt": "photorealistic RAW photo by rob hefferan, fashionista woman wearing gorgeous floral dress with victorian hat, highly detailed skin pores, 4K, sharp focus, deep shadows, beautiful spring season, vibrant small flowers, masterpiece",
"guidance_scale": 0,
"safety_checker": true,
"negative_prompt": "amateur quality, vague shapes, vague texture, wrong perspective, wrong angle, ugly, dowdy style, grainy",
"ip_adapter_scale": 0.8,
"num_inference_steps": 6,
"controlnet_conditioning_scale": 0.8
},
"logs": "0%| | 0/6 [00:00<?, ?it/s]\n 17%|█▋ | 1/6 [00:00<00:00, 5.32it/s]\n 33%|███▎ | 2/6 [00:00<00:00, 5.33it/s]\n 50%|█████ | 3/6 [00:00<00:00, 5.33it/s]\n 67%|██████▋ | 4/6 [00:00<00:00, 5.33it/s]\n 83%|████████▎ | 5/6 [00:00<00:00, 5.32it/s]\n100%|██████████| 6/6 [00:01<00:00, 5.33it/s]\n100%|██████████| 6/6 [00:01<00:00, 5.33it/s]",
"metrics": {
"predict_time": 14.100746,
"total_time": 14.150782
},
"output": "https://replicate.delivery/pbxt/KXeGFxxHaLQfBUZjMdfBK4LrxDT81ocoHrAezlgw2aqfckHSC/result.jpg",
"started_at": "2024-01-28T08:56:58.014798Z",
"status": "succeeded",
"urls": {
"get": "https://api.replicate.com/v1/predictions/ld7kjulbo72xixtgpn3vsl4tv4",
"cancel": "https://api.replicate.com/v1/predictions/ld7kjulbo72xixtgpn3vsl4tv4/cancel"
},
"version": "2a2afbff09996b53247b0714577d4ff82d2c9da8e8b00c5499b5b34510bb8b5e"
}
0%| | 0/6 [00:00<?, ?it/s]
17%|█▋ | 1/6 [00:00<00:00, 5.32it/s]
33%|███▎ | 2/6 [00:00<00:00, 5.33it/s]
50%|█████ | 3/6 [00:00<00:00, 5.33it/s]
67%|██████▋ | 4/6 [00:00<00:00, 5.33it/s]
83%|████████▎ | 5/6 [00:00<00:00, 5.32it/s]
100%|██████████| 6/6 [00:01<00:00, 5.33it/s]
100%|██████████| 6/6 [00:01<00:00, 5.33it/s]