ControlNet-Canny: Optimized for Qualcomm Devices

On-device, high-resolution image synthesis from text and image prompts. ControlNet guides Stable-diffusion with provided input image to generate accurate images from given input prompt.

This is based on the implementation of ControlNet-Canny 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.

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® 8 Elite Gen 5 For Galaxy Mobile QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite For Galaxy Mobile QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-8275 QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 QAIRT 2.50, ONNX Runtime 1.27.1 Download
PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile QAIRT 2.50, ONNX Runtime 1.27.1 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite For Galaxy Mobile QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-8275 QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8775P QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Qualcomm® SA7255P QAIRT 2.50 Download
QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile QAIRT 2.50 Download

For more device-specific assets and performance metrics, visit ControlNet-Canny 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 ControlNet-Canny on GitHub for usage instructions.

Model Details

Model Type: Model_use_case.image_generation

Model Stats:

  • Conditioning Input: Canny-Edge
  • ControlNet Number of parameters: 361M
  • Input: Text prompt and input image as a reference
  • Model size: 1.4GB
  • Text Encoder Number of parameters: 340M
  • UNet Number of parameters: 865M
  • VAE Decoder Number of parameters: 83M

Performance Summary

Model Runtime Precision Chipset Inference Time (ms) Peak Memory Range (MB) Primary Compute Unit
controlnet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile 23.473 ms 32 - 43 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite For Galaxy Mobile 44.041 ms 32 - 43 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite 29.226 ms 33 - 33 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite 65.95 ms 351 - 351 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile 59.029 ms 33 - 45 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-8275 65.452 ms 30 - 35 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 70.907 ms 0 - 384 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 54.923 ms 32 - 37 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-X7181 65.95 ms 351 - 351 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 1130.799 ms 2 - 13 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-7790 114.332 ms 34 - 43 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-8750 44.041 ms 32 - 43 MB NPU
controlnet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile 114.332 ms 34 - 43 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile 23.268 ms 2 - 10 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite For Galaxy Mobile 43.29 ms 2 - 14 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite 29.815 ms 2 - 2 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite 66.026 ms 2 - 2 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile 54.135 ms 4 - 12 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-8275 65.489 ms 2 - 19 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 70.753 ms 2 - 4 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8650P 70.402 ms 2 - 10 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8255P 70.402 ms 2 - 10 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 54.41 ms 0 - 17 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-X7181 66.026 ms 2 - 2 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 1143.84 ms 0 - 6 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-7790 113.441 ms 4 - 11 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-8750 43.29 ms 2 - 14 MB NPU
controlnet QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile 113.441 ms 4 - 11 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile 1.563 ms 0 - 11 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite For Galaxy Mobile 1.736 ms 0 - 12 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite 1.609 ms 1 - 1 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite 3.149 ms 156 - 156 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile 2.209 ms 0 - 13 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-8275 3.07 ms 0 - 4 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 3.034 ms 0 - 162 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 3.158 ms 0 - 3 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-X7181 3.149 ms 156 - 156 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 21.183 ms 0 - 12 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-7790 3.306 ms 0 - 6 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-8750 1.736 ms 0 - 12 MB NPU
text_encoder PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile 3.306 ms 0 - 6 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile 1.554 ms 0 - 8 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite For Galaxy Mobile 1.732 ms 0 - 8 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite 1.886 ms 0 - 0 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite 3.34 ms 0 - 0 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile 2.205 ms 0 - 7 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-8275 3.052 ms 0 - 3 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 3.025 ms 0 - 1 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8650P 3.52 ms 0 - 5 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8255P 3.52 ms 0 - 5 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 3.152 ms 2 - 4 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-X7181 3.34 ms 0 - 0 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 21.13 ms 0 - 6 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-7790 3.295 ms 0 - 6 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-8750 1.732 ms 0 - 8 MB NPU
text_encoder QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile 3.295 ms 0 - 6 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile 49.928 ms 6 - 18 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite For Galaxy Mobile 58.972 ms 6 - 18 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite 46.404 ms 13 - 13 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite 110.571 ms 828 - 828 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile 77.417 ms 13 - 23 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-8275 102.148 ms 3 - 19 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 108.622 ms 0 - 883 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 103.47 ms 13 - 29 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-X7181 110.571 ms 828 - 828 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 2016.771 ms 13 - 24 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-7790 164.945 ms 13 - 24 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-8750 58.972 ms 6 - 18 MB NPU
unet PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile 164.945 ms 13 - 24 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile 47.858 ms 6 - 14 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite For Galaxy Mobile 58.711 ms 6 - 19 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite 46.512 ms 12 - 12 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite 110.518 ms 13 - 13 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile 75.467 ms 13 - 20 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-8275 102.855 ms 3 - 18 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 108.014 ms 13 - 15 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8650P 107.02 ms 11 - 19 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8255P 107.02 ms 11 - 19 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 103.352 ms 12 - 27 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-X7181 110.518 ms 13 - 13 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 1831.377 ms 13 - 25 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-7790 165.091 ms 11 - 18 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-8750 58.711 ms 6 - 19 MB NPU
unet QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile 165.091 ms 11 - 18 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile 78.474 ms 3 - 11 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Elite For Galaxy Mobile 125.689 ms 4 - 11 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X2 Elite 90.212 ms 4 - 4 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® X Elite 218.205 ms 58 - 58 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 8 Gen 3 Mobile 152.57 ms 5 - 13 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-8275 210.511 ms 3 - 7 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 221.889 ms 0 - 66 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-9075 189.439 ms 4 - 7 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ IQ-X7181 218.205 ms 58 - 58 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-6690 5627.971 ms 0 - 7 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-7790 380.928 ms 6 - 11 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Qualcomm® Dragonwing™ Q-8750 125.689 ms 4 - 11 MB NPU
vae PRECOMPILED_QNN_ONNX w8a16 Snapdragon® 7 Gen 4 Mobile 380.928 ms 6 - 11 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite Gen 5 For Galaxy Mobile 79.031 ms 0 - 8 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Elite For Galaxy Mobile 125.649 ms 0 - 8 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® X2 Elite 90.2 ms 0 - 0 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® X Elite 218.264 ms 0 - 0 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® 8 Gen 3 Mobile 151.728 ms 1 - 8 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-8275 210.233 ms 0 - 4 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ QCS8550 (Proxy) 220.532 ms 0 - 2 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8650P 243.787 ms 0 - 9 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® SA8255P 243.787 ms 0 - 9 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-9075 189.394 ms 2 - 6 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ IQ-X7181 218.264 ms 0 - 0 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-6690 5613.095 ms 2 - 8 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-7790 382.316 ms 0 - 6 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Qualcomm® Dragonwing™ Q-8750 125.649 ms 0 - 8 MB NPU
vae QNN_CONTEXT_BINARY w8a16 Snapdragon® 7 Gen 4 Mobile 382.316 ms 0 - 6 MB NPU

License

  • The license for the original implementation of ControlNet-Canny 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/ControlNet-Canny