Edit model card

This is the highly optimized version of the Stable Diffusion model for pokemon generation. The model was optimized with a combination of two methods:

  • Quantization-aware training from NNCF.
  • A modification of the Token Merging method from here.

To run the model use the following code:

%pip install optimum[openvino,diffusers]

from optimum.intel.openvino import OVStableDiffusionPipeline
from diffusers import LMSDiscreteScheduler, DDPMScheduler

import torch
import random
import numpy as np

pipe = OVStableDiffusionPipeline.from_pretrained("OpenVINO/stable-diffusion-pokemons-tome-quantized-aggressive", compile=False)
pipe.reshape(batch_size=1, height=512, width=512, num_images_per_prompt=1)
pipe.compile()

# Use original model to compare
# pipe = OVStableDiffusionPipeline.from_pretrained("svjack/Stable-Diffusion-Pokemon-en", export=True, compile=False)

prompt = "cartoon bird"
output = pipe(prompt, num_inference_steps=50, output_type="pil")
output.images[0].save("output.png")
Downloads last month
0
Unable to determine this model's library. Check the docs .

Dataset used to train OpenVINO/stable-diffusion-pokemons-tome-quantized-aggressive

Space using OpenVINO/stable-diffusion-pokemons-tome-quantized-aggressive 1