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.
ekgren /structureddreaming:b56546b3
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 ekgren/structureddreaming using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"ekgren/structureddreaming:b56546b3a819d4ff42c657ba03b932304a94db80b59398aaf62293377bdf9fbb",
{
input: {
prompt: "portrait painting of neon gods by Into the Void",
iterations: 300,
display_frequency: 30
}
}
);
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 ekgren/structureddreaming using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"ekgren/structureddreaming:b56546b3a819d4ff42c657ba03b932304a94db80b59398aaf62293377bdf9fbb",
input={
"prompt": "portrait painting of neon gods by Into the Void",
"iterations": 300,
"display_frequency": 30
}
)
# The ekgren/structureddreaming 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/ekgren/structureddreaming/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 ekgren/structureddreaming 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": "b56546b3a819d4ff42c657ba03b932304a94db80b59398aaf62293377bdf9fbb",
"input": {
"prompt": "portrait painting of neon gods by Into the Void",
"iterations": 300,
"display_frequency": 30
}
}' \
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": "2021-10-05T21:41:00.795314Z",
"created_at": "2021-10-05T21:37:18.213030Z",
"data_removed": false,
"error": null,
"id": "s4s6brg2tffqxlaowbqqreuju4",
"input": {
"prompt": "portrait painting of neon gods by Into the Void",
"iterations": "300",
"display_frequency": "30"
},
"logs": "Generating image.\nSetting up PyTorch plugin \"bias_act_plugin\"...\nDone.\nSetting up PyTorch plugin \"upfirdn2d_plugin\"...\nDone.\nstep: 30, loss: -20.546875, img.min: -0.04773811250925064, img.max: 0.9971683621406555\nstep: 60, loss: -25.734375, img.min: -0.049006085842847824, img.max: 1.026373267173767\nstep: 90, loss: -26.46875, img.min: -0.07080622762441635, img.max: 1.0104471445083618\nstep: 120, loss: -34.125, img.min: -0.0940389633178711, img.max: 1.0469348430633545\nstep: 150, loss: -31.5, img.min: -0.1317528337240219, img.max: 1.000837802886963\nstep: 180, loss: -35.15625, img.min: -0.11546284705400467, img.max: 1.0702193975448608\nstep: 210, loss: -34.46875, img.min: -0.05544739216566086, img.max: 0.9569833278656006\nstep: 240, loss: -30.828125, img.min: -0.09335537254810333, img.max: 0.9662722945213318\nstep: 270, loss: -38.53125, img.min: -0.07021424919366837, img.max: 0.9920296669006348",
"metrics": {
"total_time": 222.582284
},
"output": [
{
"file": "https://replicate.delivery/mgxm/b498e10e-c1d8-4f1e-bcd5-6c4bf4b29bc7/out.png"
},
{
"file": "https://replicate.delivery/mgxm/37b92194-1742-45c9-abe7-109fd094335d/out.png"
},
{
"file": "https://replicate.delivery/mgxm/8b0c81ed-b418-4b1a-8d89-4f4650b76574/out.png"
},
{
"file": "https://replicate.delivery/mgxm/c4ad6c52-736b-43e8-a3c8-76c4e08fef09/out.png"
},
{
"file": "https://replicate.delivery/mgxm/b0bf6d75-dee5-4b1f-aa30-140977d18baf/out.png"
},
{
"file": "https://replicate.delivery/mgxm/cd1cb97a-480c-48df-b750-6c8f0ae07c30/out.png"
},
{
"file": "https://replicate.delivery/mgxm/e9c79f9d-5def-4778-9057-c54883ee1b8d/out.png"
},
{
"file": "https://replicate.delivery/mgxm/261943fe-25be-4c4b-8eb8-d1f3f893e2d7/out.png"
},
{
"file": "https://replicate.delivery/mgxm/12a407bb-0374-4f8a-9141-6dedd2c2eb59/out.png"
}
],
"started_at": "2022-06-16T08:39:22.504610Z",
"status": "succeeded",
"urls": {
"get": "https://api.replicate.com/v1/predictions/s4s6brg2tffqxlaowbqqreuju4",
"cancel": "https://api.replicate.com/v1/predictions/s4s6brg2tffqxlaowbqqreuju4/cancel"
},
"version": "b6a248320b3a985ea4c9f0709ad1843b0ac3a320863a79d546bb9809ec6c4df4"
}
Generating image.
Setting up PyTorch plugin "bias_act_plugin"...
Done.
Setting up PyTorch plugin "upfirdn2d_plugin"...
Done.
step: 30, loss: -20.546875, img.min: -0.04773811250925064, img.max: 0.9971683621406555
step: 60, loss: -25.734375, img.min: -0.049006085842847824, img.max: 1.026373267173767
step: 90, loss: -26.46875, img.min: -0.07080622762441635, img.max: 1.0104471445083618
step: 120, loss: -34.125, img.min: -0.0940389633178711, img.max: 1.0469348430633545
step: 150, loss: -31.5, img.min: -0.1317528337240219, img.max: 1.000837802886963
step: 180, loss: -35.15625, img.min: -0.11546284705400467, img.max: 1.0702193975448608
step: 210, loss: -34.46875, img.min: -0.05544739216566086, img.max: 0.9569833278656006
step: 240, loss: -30.828125, img.min: -0.09335537254810333, img.max: 0.9662722945213318
step: 270, loss: -38.53125, img.min: -0.07021424919366837, img.max: 0.9920296669006348
This example was created by a different version, ekgren/structureddreaming:b6a24832.