misbahsy / woolitize-diffusion

Diffusion model to generate Woolitize images

  • Public
  • 173 runs
  • T4
  • License

Run misbahsy/woolitize-diffusion with an API

Use one of our client libraries to get started quickly.

Set the REPLICATE_API_TOKEN environment variable

export REPLICATE_API_TOKEN=<paste-your-token-here>

Learn more about authentication

Install Replicate’s Node.js client library

npm install replicate
Learn more about setup

Run misbahsy/woolitize-diffusion using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.

import Replicate from "replicate";
const replicate = new Replicate();

const input = {
    prompt: "woolitize photo of elon musk"
};

const output = await replicate.run("misbahsy/woolitize-diffusion:5411e9efb858ef003e1c2787181c29d9592c7eba9a436597bf303ecb0b2667f8", { input });

import { writeFile } from "node:fs/promises";
for (const [index, item] of Object.entries(output)) {
  await writeFile(`output_${index}.png`, item);
}
//=> output_0.png written to disk
Learn more