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.
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 kuprel/min-dalle using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"kuprel/min-dalle:cb2da7da16a54c78ad915be99f00c028a8d619031946ed4de46fa02c677230f1",
{
input: {
text: "singularity, hyperrealism",
top_k: 64,
seamless: true,
grid_size: 5,
save_as_png: false,
temperature: 1,
progressive_outputs: true,
supercondition_factor: 16
}
}
);
// 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 kuprel/min-dalle using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"kuprel/min-dalle:cb2da7da16a54c78ad915be99f00c028a8d619031946ed4de46fa02c677230f1",
input={
"text": "singularity, hyperrealism",
"top_k": 64,
"seamless": True,
"grid_size": 5,
"save_as_png": False,
"temperature": 1,
"progressive_outputs": True,
"supercondition_factor": 16
}
)
# The kuprel/min-dalle model can stream output as it's running.
# The predict method returns an iterator, and you can iterate over that output.
for item in output:
# https://replicate.com/kuprel/min-dalle/api#output-schema
print(item)
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 kuprel/min-dalle 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": "kuprel/min-dalle:cb2da7da16a54c78ad915be99f00c028a8d619031946ed4de46fa02c677230f1",
"input": {
"text": "singularity, hyperrealism",
"top_k": 64,
"seamless": true,
"grid_size": 5,
"save_as_png": false,
"temperature": 1,
"progressive_outputs": true,
"supercondition_factor": 16
}
}' \
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": "2022-07-17T17:20:49.135146Z",
"created_at": "2022-07-17T17:20:16.982050Z",
"data_removed": false,
"error": null,
"id": "m3xm2lguo5benlijih2gbksoeu",
"input": {
"text": "singularity, hyperrealism",
"top_k": 64,
"seamless": true,
"grid_size": "5",
"temperature": "1",
"progressive_outputs": true,
"supercondition_factor": "16"
},
"logs": "tokenizing text\n['Ġsingular', 'ity', ',']\n['Ġhyper', 'real', 'ism']\n8 text tokens [0, 30129, 223, 11, 6139, 4646, 822, 2]\nencoding text tokens\ndetokenizing image\ndetokenizing image\ndetokenizing image\ndetokenizing image\ndetokenizing image\ndetokenizing image\ndetokenizing image\ndetokenizing image",
"metrics": {
"predict_time": 15.969548,
"total_time": 32.153096
},
"output": [
"https://replicate.delivery/mgxm/f4809a49-31c7-43cf-92ae-a42972718c18/min-dalle-iter-1.jpg",
"https://replicate.delivery/mgxm/153da01d-0055-4384-8814-9b8fc94c6cbc/min-dalle-iter-2.jpg",
"https://replicate.delivery/mgxm/7f3a13ef-cf4f-4cf9-893c-854b675685fe/min-dalle-iter-3.jpg",
"https://replicate.delivery/mgxm/4f25e5b4-b6cb-4758-b4d6-fd866aaa06dc/min-dalle-iter-4.jpg",
"https://replicate.delivery/mgxm/a39a43eb-d1fd-45d8-9adb-1e58f32a822e/min-dalle-iter-5.jpg",
"https://replicate.delivery/mgxm/75bc106c-8d99-4947-a2ac-1ed0924db72d/min-dalle-iter-6.jpg",
"https://replicate.delivery/mgxm/d77bf31a-bc40-4589-bd10-8e9aaf41bbd8/min-dalle-iter-7.jpg",
"https://replicate.delivery/mgxm/0715b9a1-f457-4329-aed4-bed16272ab88/min-dalle-iter-8.jpg"
],
"started_at": "2022-07-17T17:20:33.165598Z",
"status": "succeeded",
"urls": {
"get": "https://api.replicate.com/v1/predictions/m3xm2lguo5benlijih2gbksoeu",
"cancel": "https://api.replicate.com/v1/predictions/m3xm2lguo5benlijih2gbksoeu/cancel"
},
"version": "cb2da7da16a54c78ad915be99f00c028a8d619031946ed4de46fa02c677230f1"
}
tokenizing text
['Ġsingular', 'ity', ',']
['Ġhyper', 'real', 'ism']
8 text tokens [0, 30129, 223, 11, 6139, 4646, 822, 2]
encoding text tokens
detokenizing image
detokenizing image
detokenizing image
detokenizing image
detokenizing image
detokenizing image
detokenizing image
detokenizing image