Readme
This model doesn't have a readme.
SDXL fine-tuned on photos of freshly inked tattoos
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 fofr/sdxl-fresh-ink using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"fofr/sdxl-fresh-ink:8515c238222fa529763ec99b4ba1fa9d32ab5d6ebc82b4281de99e4dbdcec943",
{
input: {
width: 1024,
height: 1024,
prompt: "A fresh ink TOK tattoo",
refine: "expert_ensemble_refiner",
scheduler: "K_EULER",
lora_scale: 0.6,
num_outputs: 1,
guidance_scale: 7.5,
apply_watermark: false,
high_noise_frac: 0.9,
negative_prompt: "ugly, broken, distorted",
prompt_strength: 0.8,
num_inference_steps: 25
}
}
);
// 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=<paste-your-token-here>
Find your API token in your account settings.
import replicate
Run fofr/sdxl-fresh-ink using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"fofr/sdxl-fresh-ink:8515c238222fa529763ec99b4ba1fa9d32ab5d6ebc82b4281de99e4dbdcec943",
input={
"width": 1024,
"height": 1024,
"prompt": "A fresh ink TOK tattoo",
"refine": "expert_ensemble_refiner",
"scheduler": "K_EULER",
"lora_scale": 0.6,
"num_outputs": 1,
"guidance_scale": 7.5,
"apply_watermark": False,
"high_noise_frac": 0.9,
"negative_prompt": "ugly, broken, distorted",
"prompt_strength": 0.8,
"num_inference_steps": 25
}
)
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/sdxl-fresh-ink 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": "fofr/sdxl-fresh-ink:8515c238222fa529763ec99b4ba1fa9d32ab5d6ebc82b4281de99e4dbdcec943",
"input": {
"width": 1024,
"height": 1024,
"prompt": "A fresh ink TOK tattoo",
"refine": "expert_ensemble_refiner",
"scheduler": "K_EULER",
"lora_scale": 0.6,
"num_outputs": 1,
"guidance_scale": 7.5,
"apply_watermark": false,
"high_noise_frac": 0.9,
"negative_prompt": "ugly, broken, distorted",
"prompt_strength": 0.8,
"num_inference_steps": 25
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
brew install cog
If you don’t have Homebrew, there are other installation options available.
Run this to download the model and run it in your local environment:
cog predict r8.im/fofr/sdxl-fresh-ink@sha256:8515c238222fa529763ec99b4ba1fa9d32ab5d6ebc82b4281de99e4dbdcec943 \
-i 'width=1024' \
-i 'height=1024' \
-i 'prompt="A fresh ink TOK tattoo"' \
-i 'refine="expert_ensemble_refiner"' \
-i 'scheduler="K_EULER"' \
-i 'lora_scale=0.6' \
-i 'num_outputs=1' \
-i 'guidance_scale=7.5' \
-i 'apply_watermark=false' \
-i 'high_noise_frac=0.9' \
-i 'negative_prompt="ugly, broken, distorted"' \
-i 'prompt_strength=0.8' \
-i 'num_inference_steps=25'
To learn more, take a look at the Cog documentation.
Run this to download the model and run it in your local environment:
docker run -d -p 5000:5000 --gpus=all r8.im/fofr/sdxl-fresh-ink@sha256:8515c238222fa529763ec99b4ba1fa9d32ab5d6ebc82b4281de99e4dbdcec943
curl -s -X POST \ -H "Content-Type: application/json" \ -d $'{ "input": { "width": 1024, "height": 1024, "prompt": "A fresh ink TOK tattoo", "refine": "expert_ensemble_refiner", "scheduler": "K_EULER", "lora_scale": 0.6, "num_outputs": 1, "guidance_scale": 7.5, "apply_watermark": false, "high_noise_frac": 0.9, "negative_prompt": "ugly, broken, distorted", "prompt_strength": 0.8, "num_inference_steps": 25 } }' \ http://localhost:5000/predictions
To learn more, take a look at the Cog documentation.
Add a payment method to run this model.
Each run costs approximately $0.013. Alternatively, try out our featured models for free.
By signing in, you agree to our
terms of service and privacy policy
{
"completed_at": "2024-01-09T16:48:48.991666Z",
"created_at": "2024-01-09T16:48:36.980298Z",
"data_removed": false,
"error": null,
"id": "qxwo2ylbjcpcobsx5ouimg7x3a",
"input": {
"width": 1024,
"height": 1024,
"prompt": "A fresh ink TOK tattoo",
"refine": "expert_ensemble_refiner",
"scheduler": "K_EULER",
"lora_scale": 0.6,
"num_outputs": 1,
"guidance_scale": 7.5,
"apply_watermark": false,
"high_noise_frac": 0.9,
"negative_prompt": "ugly, broken, distorted",
"prompt_strength": 0.8,
"num_inference_steps": 25
},
"logs": "Using seed: 33170\nEnsuring enough disk space...\nFree disk space: 2130453733376\nDownloading weights: https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar\n2024-01-09T16:48:40Z | INFO | [ Initiating ] dest=/src/weights-cache/9f5b12ce3d673053 minimum_chunk_size=150M url=https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar\n2024-01-09T16:48:41Z | INFO | [ Complete ] dest=/src/weights-cache/9f5b12ce3d673053 size=\"186 MB\" total_elapsed=0.820s url=https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar\nb''\nDownloaded weights in 0.9461627006530762 seconds\nLoading fine-tuned model\nDoes not have Unet. assume we are using LoRA\nLoading Unet LoRA\nPrompt: A fresh ink <s0><s1> tattoo\ntxt2img mode\n 0%| | 0/18 [00:00<?, ?it/s]\n 6%|▌ | 1/18 [00:00<00:04, 3.72it/s]\n 11%|█ | 2/18 [00:00<00:04, 3.69it/s]\n 17%|█▋ | 3/18 [00:00<00:04, 3.69it/s]\n 22%|██▏ | 4/18 [00:01<00:03, 3.68it/s]\n 28%|██▊ | 5/18 [00:01<00:03, 3.69it/s]\n 33%|███▎ | 6/18 [00:01<00:03, 3.69it/s]\n 39%|███▉ | 7/18 [00:01<00:02, 3.68it/s]\n 44%|████▍ | 8/18 [00:02<00:02, 3.68it/s]\n 50%|█████ | 9/18 [00:02<00:02, 3.68it/s]\n 56%|█████▌ | 10/18 [00:02<00:02, 3.69it/s]\n 61%|██████ | 11/18 [00:02<00:01, 3.69it/s]\n 67%|██████▋ | 12/18 [00:03<00:01, 3.69it/s]\n 72%|███████▏ | 13/18 [00:03<00:01, 3.69it/s]\n 78%|███████▊ | 14/18 [00:03<00:01, 3.69it/s]\n 83%|████████▎ | 15/18 [00:04<00:00, 3.69it/s]\n 89%|████████▉ | 16/18 [00:04<00:00, 3.69it/s]\n 94%|█████████▍| 17/18 [00:04<00:00, 3.69it/s]\n100%|██████████| 18/18 [00:04<00:00, 3.69it/s]\n100%|██████████| 18/18 [00:04<00:00, 3.69it/s]\n 0%| | 0/3 [00:00<?, ?it/s]\n 33%|███▎ | 1/3 [00:00<00:00, 4.31it/s]\n 67%|██████▋ | 2/3 [00:00<00:00, 4.27it/s]\n100%|██████████| 3/3 [00:00<00:00, 4.27it/s]\n100%|██████████| 3/3 [00:00<00:00, 4.28it/s]",
"metrics": {
"predict_time": 8.706767,
"total_time": 12.011368
},
"output": [
"https://replicate.delivery/pbxt/KXrjXKjczHK6MxVIjgoCeJffm0uP5LlzEyPrHjwceeXDeqsiE/out-0.png"
],
"started_at": "2024-01-09T16:48:40.284899Z",
"status": "succeeded",
"urls": {
"get": "https://api.replicate.com/v1/predictions/qxwo2ylbjcpcobsx5ouimg7x3a",
"cancel": "https://api.replicate.com/v1/predictions/qxwo2ylbjcpcobsx5ouimg7x3a/cancel"
},
"version": "8515c238222fa529763ec99b4ba1fa9d32ab5d6ebc82b4281de99e4dbdcec943"
}
Using seed: 33170
Ensuring enough disk space...
Free disk space: 2130453733376
Downloading weights: https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar
2024-01-09T16:48:40Z | INFO | [ Initiating ] dest=/src/weights-cache/9f5b12ce3d673053 minimum_chunk_size=150M url=https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar
2024-01-09T16:48:41Z | INFO | [ Complete ] dest=/src/weights-cache/9f5b12ce3d673053 size="186 MB" total_elapsed=0.820s url=https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar
b''
Downloaded weights in 0.9461627006530762 seconds
Loading fine-tuned model
Does not have Unet. assume we are using LoRA
Loading Unet LoRA
Prompt: A fresh ink <s0><s1> tattoo
txt2img mode
0%| | 0/18 [00:00<?, ?it/s]
6%|▌ | 1/18 [00:00<00:04, 3.72it/s]
11%|█ | 2/18 [00:00<00:04, 3.69it/s]
17%|█▋ | 3/18 [00:00<00:04, 3.69it/s]
22%|██▏ | 4/18 [00:01<00:03, 3.68it/s]
28%|██▊ | 5/18 [00:01<00:03, 3.69it/s]
33%|███▎ | 6/18 [00:01<00:03, 3.69it/s]
39%|███▉ | 7/18 [00:01<00:02, 3.68it/s]
44%|████▍ | 8/18 [00:02<00:02, 3.68it/s]
50%|█████ | 9/18 [00:02<00:02, 3.68it/s]
56%|█████▌ | 10/18 [00:02<00:02, 3.69it/s]
61%|██████ | 11/18 [00:02<00:01, 3.69it/s]
67%|██████▋ | 12/18 [00:03<00:01, 3.69it/s]
72%|███████▏ | 13/18 [00:03<00:01, 3.69it/s]
78%|███████▊ | 14/18 [00:03<00:01, 3.69it/s]
83%|████████▎ | 15/18 [00:04<00:00, 3.69it/s]
89%|████████▉ | 16/18 [00:04<00:00, 3.69it/s]
94%|█████████▍| 17/18 [00:04<00:00, 3.69it/s]
100%|██████████| 18/18 [00:04<00:00, 3.69it/s]
100%|██████████| 18/18 [00:04<00:00, 3.69it/s]
0%| | 0/3 [00:00<?, ?it/s]
33%|███▎ | 1/3 [00:00<00:00, 4.31it/s]
67%|██████▋ | 2/3 [00:00<00:00, 4.27it/s]
100%|██████████| 3/3 [00:00<00:00, 4.27it/s]
100%|██████████| 3/3 [00:00<00:00, 4.28it/s]
This model costs approximately $0.013 to run on Replicate, or 76 runs per $1, but this varies depending on your inputs. It is also open source and you can run it on your own computer with Docker.
This model runs on Nvidia L40S GPU hardware. Predictions typically complete within 14 seconds.
This model doesn't have a readme.
This model is warm. You'll get a fast response if the model is warm and already running, and a slower response if the model is cold and starting up.
This model costs approximately $0.013 to run on Replicate, but this varies depending on your inputs. View more.
Choose a file from your machine
Hint: you can also drag files onto the input
Choose a file from your machine
Hint: you can also drag files onto the input
Using seed: 33170
Ensuring enough disk space...
Free disk space: 2130453733376
Downloading weights: https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar
2024-01-09T16:48:40Z | INFO | [ Initiating ] dest=/src/weights-cache/9f5b12ce3d673053 minimum_chunk_size=150M url=https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar
2024-01-09T16:48:41Z | INFO | [ Complete ] dest=/src/weights-cache/9f5b12ce3d673053 size="186 MB" total_elapsed=0.820s url=https://replicate.delivery/pbxt/GueLVKd75jxiXKEAmKAIV0dSwa0f7aHMYIl0itvXuFlRekVkA/trained_model.tar
b''
Downloaded weights in 0.9461627006530762 seconds
Loading fine-tuned model
Does not have Unet. assume we are using LoRA
Loading Unet LoRA
Prompt: A fresh ink <s0><s1> tattoo
txt2img mode
0%| | 0/18 [00:00<?, ?it/s]
6%|▌ | 1/18 [00:00<00:04, 3.72it/s]
11%|█ | 2/18 [00:00<00:04, 3.69it/s]
17%|█▋ | 3/18 [00:00<00:04, 3.69it/s]
22%|██▏ | 4/18 [00:01<00:03, 3.68it/s]
28%|██▊ | 5/18 [00:01<00:03, 3.69it/s]
33%|███▎ | 6/18 [00:01<00:03, 3.69it/s]
39%|███▉ | 7/18 [00:01<00:02, 3.68it/s]
44%|████▍ | 8/18 [00:02<00:02, 3.68it/s]
50%|█████ | 9/18 [00:02<00:02, 3.68it/s]
56%|█████▌ | 10/18 [00:02<00:02, 3.69it/s]
61%|██████ | 11/18 [00:02<00:01, 3.69it/s]
67%|██████▋ | 12/18 [00:03<00:01, 3.69it/s]
72%|███████▏ | 13/18 [00:03<00:01, 3.69it/s]
78%|███████▊ | 14/18 [00:03<00:01, 3.69it/s]
83%|████████▎ | 15/18 [00:04<00:00, 3.69it/s]
89%|████████▉ | 16/18 [00:04<00:00, 3.69it/s]
94%|█████████▍| 17/18 [00:04<00:00, 3.69it/s]
100%|██████████| 18/18 [00:04<00:00, 3.69it/s]
100%|██████████| 18/18 [00:04<00:00, 3.69it/s]
0%| | 0/3 [00:00<?, ?it/s]
33%|███▎ | 1/3 [00:00<00:00, 4.31it/s]
67%|██████▋ | 2/3 [00:00<00:00, 4.27it/s]
100%|██████████| 3/3 [00:00<00:00, 4.27it/s]
100%|██████████| 3/3 [00:00<00:00, 4.28it/s]