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.
andreasjansson /stable-diffusion-animation:a0cd8005
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 andreasjansson/stable-diffusion-animation using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"andreasjansson/stable-diffusion-animation:a0cd8005509b772461dd2a4dc58d304bac1d150d93fa35fdc80dc5835f766d4d",
{
input: {
width: 512,
height: 512,
prompt_end: "tall rectangular black monolith, a white room in the future with a bed, victorian details and a tall black monolith, a detailed matte painting by Wes Anderson, behance, light and space, reimagined by industrial light and magic, matte painting, criterion collection",
prompt_start: "tall rectangular black monolith, monkeys in the desert looking at a large tall monolith, a detailed matte painting by Wes Anderson, behance, light and space, reimagined by industrial light and magic, matte painting, criterion collection",
gif_ping_pong: true,
output_format: "mp4",
guidance_scale: 7.5,
prompt_strength: 0.9,
film_interpolation: true,
num_inference_steps: 50,
num_animation_frames: 25,
gif_frames_per_second: 20,
num_interpolation_steps: 5
}
}
);
// 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 andreasjansson/stable-diffusion-animation using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"andreasjansson/stable-diffusion-animation:a0cd8005509b772461dd2a4dc58d304bac1d150d93fa35fdc80dc5835f766d4d",
input={
"width": 512,
"height": 512,
"prompt_end": "tall rectangular black monolith, a white room in the future with a bed, victorian details and a tall black monolith, a detailed matte painting by Wes Anderson, behance, light and space, reimagined by industrial light and magic, matte painting, criterion collection",
"prompt_start": "tall rectangular black monolith, monkeys in the desert looking at a large tall monolith, a detailed matte painting by Wes Anderson, behance, light and space, reimagined by industrial light and magic, matte painting, criterion collection",
"gif_ping_pong": True,
"output_format": "mp4",
"guidance_scale": 7.5,
"prompt_strength": 0.9,
"film_interpolation": True,
"num_inference_steps": 50,
"num_animation_frames": 25,
"gif_frames_per_second": 20,
"num_interpolation_steps": 5
}
)
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 andreasjansson/stable-diffusion-animation 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": "andreasjansson/stable-diffusion-animation:a0cd8005509b772461dd2a4dc58d304bac1d150d93fa35fdc80dc5835f766d4d",
"input": {
"width": 512,
"height": 512,
"prompt_end": "tall rectangular black monolith, a white room in the future with a bed, victorian details and a tall black monolith, a detailed matte painting by Wes Anderson, behance, light and space, reimagined by industrial light and magic, matte painting, criterion collection",
"prompt_start": "tall rectangular black monolith, monkeys in the desert looking at a large tall monolith, a detailed matte painting by Wes Anderson, behance, light and space, reimagined by industrial light and magic, matte painting, criterion collection",
"gif_ping_pong": true,
"output_format": "mp4",
"guidance_scale": 7.5,
"prompt_strength": 0.9,
"film_interpolation": true,
"num_inference_steps": 50,
"num_animation_frames": 25,
"gif_frames_per_second": 20,
"num_interpolation_steps": 5
}
}' \
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-08-28T21:01:43Z",
"created_at": "2022-08-28T20:56:18.476932Z",
"data_removed": false,
"error": "",
"id": "wsdaibdifnhlnptfyeyq6dgm4q",
"input": {
"width": 512,
"height": 512,
"prompt_end": "tall rectangular black monolith, a white room in the future with a bed, victorian details and a tall black monolith, a detailed matte painting by Wes Anderson, behance, light and space, reimagined by industrial light and magic, matte painting, criterion collection",
"prompt_start": "tall rectangular black monolith, monkeys in the desert looking at a large tall monolith, a detailed matte painting by Wes Anderson, behance, light and space, reimagined by industrial light and magic, matte painting, criterion collection",
"gif_ping_pong": true,
"output_format": "mp4",
"guidance_scale": 7.5,
"prompt_strength": 0.9,
"film_interpolation": true,
"num_inference_steps": 50,
"num_animation_frames": "25",
"gif_frames_per_second": 20,
"num_interpolation_steps": 5
},
"logs": "Using seed: 52273\r\nGenerating initial latents for 4 steps\r\nGenerating frame 0\r\nGenerating frame 1\r\nGenerating frame 2\r\nGenerating frame 3\r\nGenerating frame 4\r\nGenerating frame 5\r\nGenerating frame 6\r\nGenerating frame 7\r\nGenerating frame 8\r\nGenerating frame 9\r\nGenerating frame 10\r\nGenerating frame 11\r\nGenerating frame 12\r\nGenerating frame 13\r\nGenerating frame 14\r\nGenerating frame 15\r\nGenerating frame 16\r\nGenerating frame 17\r\nGenerating frame 18\r\nGenerating frame 19\r\nGenerating frame 20\r\nGenerating frame 21\r\nGenerating frame 22\r\nGenerating frame 23\r\nGenerating frame 24\r\nInterpolating images with FILM\r\nSaving MP4",
"metrics": {
"predict_time": 133,
"total_time": 324.523068
},
"output": "https://replicate.delivery/mgxm/56df19d7-3776-4119-a0f9-d278b26a4a8a/output.mp4",
"started_at": "2022-08-28T20:59:30Z",
"status": "succeeded",
"urls": {
"get": "https://api.replicate.com/v1/predictions/wsdaibdifnhlnptfyeyq6dgm4q",
"cancel": "https://api.replicate.com/v1/predictions/wsdaibdifnhlnptfyeyq6dgm4q/cancel"
},
"version": "a0cd8005509b772461dd2a4dc58d304bac1d150d93fa35fdc80dc5835f766d4d"
}
Using seed: 52273
Generating initial latents for 4 steps
Generating frame 0
Generating frame 1
Generating frame 2
Generating frame 3
Generating frame 4
Generating frame 5
Generating frame 6
Generating frame 7
Generating frame 8
Generating frame 9
Generating frame 10
Generating frame 11
Generating frame 12
Generating frame 13
Generating frame 14
Generating frame 15
Generating frame 16
Generating frame 17
Generating frame 18
Generating frame 19
Generating frame 20
Generating frame 21
Generating frame 22
Generating frame 23
Generating frame 24
Interpolating images with FILM
Saving MP4