import { default } from "https://deno.land/x/stable_diffusion_client@0.1.0/mod.ts";
Examples
const api = new StableDiffusionApi()
const result = await api.txt2img({
prompt: "A computer that has more brain power than a human being",
batch_size: 2,
})
const api = new StableDiffusionApi() const result = await api.txt2img({ prompt: "A computer that has more brain power than a human being", batch_size: 2, })
// Save the first image result.image.toFile("result.png")
// Save all images
result.images.forEach((image, i) => {
image.toFile(result_${i}.png
)
})
Constructors
Properties
Methods
Stable Diffusion extra's call for batch images
Stable Diffusion extra's call for single images
Gets the name of the current Stable Diffusion checkpoint being used
Gets the progress status of the current session
Stable Diffusion img2img call
Interrogates an image with an interrogation model
Set the authentication for the axios API
Sets the Stable Diffusion checkpoint to use
Stable Diffusion txt2img call
Waits for the Stable Diffusion server to be ready to accept new requests