defaultAn astronaut riding a rainbow unicorn, cinematic, dramatic
typetext
{
"apply_watermark": true,
"guidance_scale": 2,
"height": 1024,
"lora_scale": 0.6,
"negative_prompt": "Gothic, Medieval, Abstract, Futuristic, Rustic, Victorian, Graffiti, Fantasy, Horror, Industrial, Cubism, Impressionism, Surrealism, Baroque, Renaissance, Expressionism, Pop-art, Dystopian, Steampunk, Cyberpunk, Ugly, Bad proportion, Distorted, Cluttered, Chaotic, Mismatched, Overcrowded, Imbalanced, Inharmonious, Disproportionate, Unpleasant, Grungy, Messy, Unrefined, Crude, Grotesque, Disarray, Jumbled, Haphazard, Unsymmetrical\n",
"num_inference_steps": 6,
"num_outputs": 4,
"prompt": "In the style of TOK. A mid-century modern house with a pool, surrounded by palm trees ",
"prompt_strength": 0.8,
"scheduler": "LCM",
"width": 1024
}npm install replicate
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_1nM**********************************
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 doriandarko/lcm-hiroshinagai using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"doriandarko/lcm-hiroshinagai:b43c25e9643af233e1258c839b6c6726504cbc25a1843ff80d83d911b8c99faa",
{
input: {
apply_watermark: true,
guidance_scale: 2,
height: 1024,
lora_scale: 0.6,
negative_prompt: "Gothic, Medieval, Abstract, Futuristic, Rustic, Victorian, Graffiti, Fantasy, Horror, Industrial, Cubism, Impressionism, Surrealism, Baroque, Renaissance, Expressionism, Pop-art, Dystopian, Steampunk, Cyberpunk, Ugly, Bad proportion, Distorted, Cluttered, Chaotic, Mismatched, Overcrowded, Imbalanced, Inharmonious, Disproportionate, Unpleasant, Grungy, Messy, Unrefined, Crude, Grotesque, Disarray, Jumbled, Haphazard, Unsymmetrical\n",
num_inference_steps: 6,
num_outputs: 4,
prompt: "In the style of TOK. A mid-century modern house with a pool, surrounded by palm trees ",
prompt_strength: 0.8,
scheduler: "LCM",
width: 1024
}
}
);
// To access the file URL:
console.log(output[0].url()); //=> "http://example.com"
// To write the file to disk:
fs.writeFile("my-image.png", output[0]);
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_1nM**********************************
This is your API token. Keep it to yourself.
import replicate
Run doriandarko/lcm-hiroshinagai using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"doriandarko/lcm-hiroshinagai:b43c25e9643af233e1258c839b6c6726504cbc25a1843ff80d83d911b8c99faa",
input={
"apply_watermark": True,
"guidance_scale": 2,
"height": 1024,
"lora_scale": 0.6,
"negative_prompt": "Gothic, Medieval, Abstract, Futuristic, Rustic, Victorian, Graffiti, Fantasy, Horror, Industrial, Cubism, Impressionism, Surrealism, Baroque, Renaissance, Expressionism, Pop-art, Dystopian, Steampunk, Cyberpunk, Ugly, Bad proportion, Distorted, Cluttered, Chaotic, Mismatched, Overcrowded, Imbalanced, Inharmonious, Disproportionate, Unpleasant, Grungy, Messy, Unrefined, Crude, Grotesque, Disarray, Jumbled, Haphazard, Unsymmetrical\n",
"num_inference_steps": 6,
"num_outputs": 4,
"prompt": "In the style of TOK. A mid-century modern house with a pool, surrounded by palm trees ",
"prompt_strength": 0.8,
"scheduler": "LCM",
"width": 1024
}
)
# To access the file URL:
print(output[0].url())
#=> "http://example.com"
# To write the file to disk:
with open("my-image.png", "wb") as file:
file.write(output[0].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_1nM**********************************
This is your API token. Keep it to yourself.
Run doriandarko/lcm-hiroshinagai 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": "doriandarko/lcm-hiroshinagai:b43c25e9643af233e1258c839b6c6726504cbc25a1843ff80d83d911b8c99faa",
"input": {
"apply_watermark": true,
"guidance_scale": 2,
"height": 1024,
"lora_scale": 0.6,
"negative_prompt": "Gothic, Medieval, Abstract, Futuristic, Rustic, Victorian, Graffiti, Fantasy, Horror, Industrial, Cubism, Impressionism, Surrealism, Baroque, Renaissance, Expressionism, Pop-art, Dystopian, Steampunk, Cyberpunk, Ugly, Bad proportion, Distorted, Cluttered, Chaotic, Mismatched, Overcrowded, Imbalanced, Inharmonious, Disproportionate, Unpleasant, Grungy, Messy, Unrefined, Crude, Grotesque, Disarray, Jumbled, Haphazard, Unsymmetrical\\n",
"num_inference_steps": 6,
"num_outputs": 4,
"prompt": "In the style of TOK. A mid-century modern house with a pool, surrounded by palm trees ",
"prompt_strength": 0.8,
"scheduler": "LCM",
"width": 1024
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
{
"id": "7bf2dkdbrkv2q374bxvmoons6a",
"model": "doriandarko/lcm-hiroshinagai",
"version": "b43c25e9643af233e1258c839b6c6726504cbc25a1843ff80d83d911b8c99faa",
"input": {
"apply_watermark": true,
"guidance_scale": 2,
"height": 1024,
"lora_scale": 0.6,
"negative_prompt": "Gothic, Medieval, Abstract, Futuristic, Rustic, Victorian, Graffiti, Fantasy, Horror, Industrial, Cubism, Impressionism, Surrealism, Baroque, Renaissance, Expressionism, Pop-art, Dystopian, Steampunk, Cyberpunk, Ugly, Bad proportion, Distorted, Cluttered, Chaotic, Mismatched, Overcrowded, Imbalanced, Inharmonious, Disproportionate, Unpleasant, Grungy, Messy, Unrefined, Crude, Grotesque, Disarray, Jumbled, Haphazard, Unsymmetrical\n",
"num_inference_steps": 6,
"num_outputs": 4,
"prompt": "In the style of TOK. A mid-century modern house with a pool, surrounded by palm trees ",
"prompt_strength": 0.8,
"scheduler": "LCM",
"width": 1024
},
"logs": "Using seed: 5739\nEnsuring enough disk space...\nFree disk space: 1456477806592\nDownloading weights: https://replicate.delivery/pbxt/2qPgVBQfv02WJapYb0CrvfE0tEPGSWInWTo3Of2QTKDZZAxjA/trained_model.tar\nb'Downloaded 186 MB bytes in 0.989s (188 MB/s)\\nExtracted 186 MB in 0.057s (3.3 GB/s)\\n'\nDownloaded weights in 1.2983520030975342 seconds\nLoading fine-tuned model\nDoes not have Unet. assume we are using LoRA\nLoading Unet LoRA\nPrompt: In the style of <s0><s1>. A mid-century modern house with a pool, surrounded by palm trees\ntxt2img mode\nThe config attributes {'skip_prk_steps': True} were passed to LCMScheduler, but are not expected and will be ignored. Please verify your scheduler_config.json configuration file.\n 0%| | 0/6 [00:00<?, ?it/s]/root/.pyenv/versions/3.10.13/lib/python3.10/site-packages/diffusers/models/attention_processor.py:1821: FutureWarning: `LoRAAttnProcessor2_0` is deprecated and will be removed in version 0.26.0. Make sure use AttnProcessor2_0 instead by settingLoRA layers to `self.{to_q,to_k,to_v,to_out[0]}.lora_layer` respectively. This will be done automatically when using `LoraLoaderMixin.load_lora_weights`\ndeprecate(\n 17%|█▋ | 1/6 [00:01<00:05, 1.14s/it]\n 33%|███▎ | 2/6 [00:02<00:04, 1.06s/it]\n 50%|█████ | 3/6 [00:03<00:03, 1.03s/it]\n 67%|██████▋ | 4/6 [00:04<00:02, 1.02s/it]\n 83%|████████▎ | 5/6 [00:05<00:01, 1.01s/it]\n100%|██████████| 6/6 [00:06<00:00, 1.01s/it]\n100%|██████████| 6/6 [00:06<00:00, 1.02s/it]",
"output": [
"https://replicate.delivery/pbxt/XejekARL6gmq6EMG08QYKPn0XsfZenw9v8oGhVlXPdQHdBiHB/out-0.png",
"https://replicate.delivery/pbxt/42yML1nyvz6XK9JOyRnbGsHu1NhYFxbRleFIB8uHViRpLQ8IA/out-1.png",
"https://replicate.delivery/pbxt/ETzexSZM3lUWR6byZICrlTIz71iP00IoocLpwYePfXOmuAxjA/out-2.png",
"https://replicate.delivery/pbxt/Ukgl1mSWC0qtJ9ut0mVLfN30h0k3shYj9WGSe0UlWbNUXg4RA/out-3.png"
],
"data_removed": false,
"error": null,
"source": "web",
"status": "succeeded",
"created_at": "2023-11-15T05:14:43.142398Z",
"started_at": "2023-11-15T05:14:45.243293Z",
"completed_at": "2023-11-15T05:15:00.408645Z",
"urls": {
"cancel": "https://api.replicate.com/v1/predictions/7bf2dkdbrkv2q374bxvmoons6a/cancel",
"get": "https://api.replicate.com/v1/predictions/7bf2dkdbrkv2q374bxvmoons6a"
},
"metrics": {
"predict_time": 15.165352,
"total_time": 17.266247
}
}


