We use essential cookies to make our site work. With your consent, we may also use non-essential cookies to improve user experience and analyze website traffic…

FLUX.2 is live! High-fidelity image generation made simple.

A short intro on running Stable Diffusion on DeepInfra
Published on 2023.03.08 by Iskren
A short intro on running Stable Diffusion on DeepInfra

Pick a model

You can browse available text-to-image models on the models page.

For example, we'll use runwayml/stable-diffusion-v1-5.

Using the API

curl -X POST \
    -d '{"prompt": "A photo of a cube floating in space"}' \
    -H 'Content-Type: application/json' \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -o cube.jpg \
    'https://api.deepinfra.com/v1/inference/runwayml/stable-diffusion-v1-5'
copy

And check out the output in cube.jpg.

Advanced options

You can check all the available settings on the model page or via the API documentation tab.

Related articles
The easiest way to build AI applications with Llama 2 LLMs.The easiest way to build AI applications with Llama 2 LLMs.The long awaited Llama 2 models are finally here! We are excited to show you how to use them with DeepInfra. These collection of models represent the state of the art in open source language models. They are made available by Meta AI and the l...
Power the Next Era of Image Generation with FLUX.2 Visual Intelligence on DeepInfraPower the Next Era of Image Generation with FLUX.2 Visual Intelligence on DeepInfraDeepInfra is excited to support FLUX.2 from day zero, bringing the newest visual intelligence model from Black Forest Labs to our platform at launch. We make it straightforward for developers, creators, and enterprises to run the model with high performance, transparent pricing, and an API designed for productivity.
Building a Voice Assistant with Whisper, LLM, and TTSBuilding a Voice Assistant with Whisper, LLM, and TTSLearn how to create a voice assistant using Whisper for speech recognition, LLM for conversation, and TTS for text-to-speech.