fazzy007/stable-diffusion-2-1-base-mnn
By fazzy007 · ↓ 0 · ♥ 1 · Updated 2025-08-22
What's in this repo
This page lists the files in fazzy007/stable-diffusion-2-1-base-mnn.
- No .onnx files in this repository
- 8 files, including 5 .mnn, 1 .md, 1 .json
- Last updated 2025-08-22
ONNX files
This repository has no .onnx files. See the full file list on the right for other formats.
How to use
These ONNX files can be loaded with ONNX Runtime. To inspect a model graph, upload the file to the Netron viewer. Download links point to the original files on Hugging Face.
README
Stable Diffusion 2.1 (MNN Conversion)
This repository contains a Stable Diffusion 2.1 model converted to the MNN format for efficient inference on CPU.
The base model is stabilityai/stable-diffusion-2-1-base.
Conversion Process
-
Exported the original model to ONNX using MNN:
cd mnn_path/transformers/diffusion/export python onnx_export.py \ --model_path stabilityai/stable-diffusion-2-1-base \ --output_path output/path -
Converted each component from ONNX → MNN:
# Clip (text encoder) ./MNNConvert -f ONNX --modelFile ./text_encoder.onnx --MNNModel ./text_encoder.mnn --fp16 # Unet ./MNNConvert -f ONNX --modelFile ./unet.onnx --MNNModel ./unet.mnn --weightQuantBits 8 --weightQuantAsymmetric --weightQuantBlock 32 # VAE decoder ./MNNConvert -f ONNX --modelFile ./vae_decoder.onnx --MNNModel ./vae_decoder.mnn --fp16
Model info
Created: 2025-08-21
Updated: 2025-08-22
View on Hugging FaceFiles (8)
Related models
More from fazzy007
No other models by this author.
More models
No task type declared.