Stable-Diffusion-v1.5: Optimized for Qualcomm Devices

Generates high resolution images from text prompts using a latent diffusion model. This model uses CLIP ViT-L/14 as text encoder, U-Net based latent denoising, and VAE based decoder to generate the final image.

This is based on the implementation of Stable-Diffusion-v1.5 found here. This repository contains pre-exported model files optimized for Qualcomm® devices. You can use the Qualcomm® AI Hub Models library to export with custom configurations. More details on model performance across various devices, can be found here.

Qualcomm AI Hub Models uses Qualcomm AI Hub Workbench to compile, profile, and evaluate this model. Sign up to run these models on a hosted Qualcomm® device.

Deploy to Snapdragon X Elite NPU

Please follow the Stable Diffusion Windows App tutorial to quantize model with custom weights.

Quantize and Deploy Your Own Fine-Tuned Stable Diffusion

Please follow the Quantize Stable Diffusion tutorial to quantize model with custom weights.

Getting Started

There are two ways to deploy this model on your device:

Option 1: Download Pre-Exported Models

Below are pre-exported model assets ready for deployment.

Runtime Precision Chipset SDK Versions Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite QAIRT 2.45, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite QAIRT 2.45, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile QAIRT 2.45, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) QAIRT 2.45, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 QAIRT 2.45, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 QAIRT 2.45, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile QAIRT 2.45, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Mobile QAIRT 2.45, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Gen 5 Mobile QAIRT 2.45, ONNX Runtime 1.27.1 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8775P QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® SA7255P QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Mobile QAIRT 2.45 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 Mobile QAIRT 2.45 Download

For more device-specific assets and performance metrics, visit Stable-Diffusion-v1.5 on Qualcomm® AI Hub.

Option 2: Export with Custom Configurations

Use the Qualcomm® AI Hub Models Python library to compile and export the model with your own:

  • Custom weights (e.g., fine-tuned checkpoints)
  • Custom input shapes
  • Target device and runtime configurations

This option is ideal if you need to customize the model beyond the default configuration provided here.

See our repository for Stable-Diffusion-v1.5 on GitHub for usage instructions.

Model Details

Model Type: Model_use_case.image_generation

Model Stats:

  • Input: Text prompt to generate image

Performance Summary

Model Runtime Precision Chipset Inference Time (ms) Peak Memory Range (MB) Primary Compute Unit
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite 1.517 ms 1 - 1 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite 3.428 ms 157 - 157 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile 2.298 ms 0 - 14 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 3.247 ms 0 - 162 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 3.335 ms 0 - 3 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-X7181 3.428 ms 157 - 157 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 25.613 ms 0 - 10 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-7790 3.675 ms 0 - 6 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-8750 1.75 ms 0 - 7 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Mobile 1.75 ms 0 - 7 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Gen 5 Mobile 1.542 ms 0 - 11 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile 3.675 ms 0 - 6 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite 1.769 ms 1 - 1 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite 3.612 ms 0 - 0 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile 2.32 ms 0 - 7 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8275 7.466 ms 0 - 9 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 3.244 ms 0 - 1 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8775P 3.487 ms 0 - 5 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8650P 3.487 ms 0 - 5 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8255P 3.487 ms 0 - 5 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 3.318 ms 0 - 2 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-X7181 3.612 ms 0 - 0 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 24.117 ms 0 - 6 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-7790 3.665 ms 0 - 6 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-8750 1.754 ms 0 - 13 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® SA7255P 7.466 ms 0 - 9 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Mobile 1.754 ms 0 - 13 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 Mobile 1.548 ms 0 - 9 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile 3.665 ms 0 - 6 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite 46.316 ms 1 - 1 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite 113.599 ms 843 - 843 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile 80.741 ms 1 - 12 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 113.9 ms 0 - 898 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 105.698 ms 0 - 3 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-X7181 113.599 ms 843 - 843 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 2239.725 ms 1 - 11 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-7790 178.115 ms 0 - 11 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-8750 61.717 ms 0 - 11 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Mobile 61.717 ms 0 - 11 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Gen 5 Mobile 47.791 ms 0 - 12 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile 178.115 ms 0 - 11 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite 46.482 ms 0 - 0 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite 113.842 ms 0 - 0 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile 80.609 ms 14 - 20 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8275 262.571 ms 0 - 10 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 113.278 ms 1 - 2 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8775P 105.963 ms 0 - 9 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8650P 105.963 ms 0 - 9 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8255P 105.963 ms 0 - 9 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 105.772 ms 2 - 4 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-X7181 113.842 ms 0 - 0 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 1993.704 ms 0 - 7 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-7790 177.846 ms 0 - 6 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-8750 58.995 ms 1 - 10 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® SA7255P 262.571 ms 0 - 10 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Mobile 58.995 ms 1 - 10 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 Mobile 45.936 ms 0 - 9 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile 177.846 ms 0 - 6 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite 127.3 ms 4 - 4 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite 257.362 ms 62 - 62 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile 197.255 ms 3 - 16 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 261.324 ms 4 - 5 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 240.491 ms 3 - 6 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-X7181 257.362 ms 62 - 62 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 6341.169 ms 4 - 10 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-7790 505.877 ms 2 - 7 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-8750 171.137 ms 4 - 10 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Mobile 171.137 ms 4 - 10 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Gen 5 Mobile 121.904 ms 3 - 10 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile 505.877 ms 2 - 7 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite 127.494 ms 0 - 0 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite 257.798 ms 0 - 0 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile 196.367 ms 0 - 7 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8275 711.84 ms 0 - 9 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 260.731 ms 1 - 3 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8775P 243.881 ms 0 - 10 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8650P 243.881 ms 0 - 10 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8255P 243.881 ms 0 - 10 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 240.398 ms 2 - 5 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-X7181 257.798 ms 0 - 0 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 6222.56 ms 3 - 10 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-7790 504.887 ms 1 - 7 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-8750 172.765 ms 0 - 13 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® SA7255P 711.84 ms 0 - 9 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Mobile 172.765 ms 0 - 13 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 Mobile 120.035 ms 0 - 9 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile 504.887 ms 1 - 7 MB NPU

License

  • The license for the original implementation of Stable-Diffusion-v1.5 can be found here.

References

Community

Usage and Limitations

This model may not be used for or in connection with any of the following applications:

  • Accessing essential private and public services and benefits;
  • Administration of justice and democratic processes;
  • Assessing or recognizing the emotional state of a person;
  • Biometric and biometrics-based systems, including categorization of persons based on sensitive characteristics;
  • Education and vocational training;
  • Employment and workers management;
  • Exploitation of the vulnerabilities of persons resulting in harmful behavior;
  • General purpose social scoring;
  • Law enforcement;
  • Management and operation of critical infrastructure;
  • Migration, asylum and border control management;
  • Predictive policing;
  • Real-time remote biometric identification in public spaces;
  • Recommender systems of social media platforms;
  • Scraping of facial images (from the internet or otherwise); and/or
  • Subliminal manipulation
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Paper for qualcomm/Stable-Diffusion-v1.5