oPipelineForText2Image.from_pretrained(
    "runwayml/stable-diffusion-v1-5", torch_dtype=torch.float16, use_safetensors=True
).to("cuda")
prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"

image = pipeline(prompt, num_inference_steps=25).images[0] Check out the AutoPipeline tutorial to learn how to use this API! AutoPipeline supports text-to-image, image-to-image, and inpainting for the following diffusion models