Instructions to use ovedrive/ERNIE-Image-nf4 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use ovedrive/ERNIE-Image-nf4 with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("ovedrive/ERNIE-Image-nf4", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
- Local Apps
- Draw Things
- DiffusionBee
| { | |
| "architectures": [ | |
| "Ministral3ForCausalLM" | |
| ], | |
| "attention_dropout": 0.0, | |
| "bos_token_id": 1, | |
| "dtype": "bfloat16", | |
| "eos_token_id": 2, | |
| "head_dim": 128, | |
| "hidden_act": "silu", | |
| "hidden_size": 3072, | |
| "initializer_range": 0.02, | |
| "intermediate_size": 9216, | |
| "max_position_embeddings": 262144, | |
| "model_type": "ministral3", | |
| "num_attention_heads": 32, | |
| "num_hidden_layers": 26, | |
| "num_key_value_heads": 8, | |
| "pad_token_id": 11, | |
| "quantization_config": { | |
| "_load_in_4bit": true, | |
| "_load_in_8bit": false, | |
| "bnb_4bit_compute_dtype": "bfloat16", | |
| "bnb_4bit_quant_storage": "uint8", | |
| "bnb_4bit_quant_type": "nf4", | |
| "bnb_4bit_use_double_quant": true, | |
| "llm_int8_enable_fp32_cpu_offload": false, | |
| "llm_int8_has_fp16_weight": false, | |
| "llm_int8_skip_modules": null, | |
| "llm_int8_threshold": 6.0, | |
| "load_in_4bit": true, | |
| "load_in_8bit": false, | |
| "quant_method": "bitsandbytes" | |
| }, | |
| "rms_norm_eps": 1e-05, | |
| "rope_parameters": { | |
| "beta_fast": 32.0, | |
| "beta_slow": 1.0, | |
| "factor": 16.0, | |
| "llama_4_scaling_beta": 0.1, | |
| "mscale": 1.0, | |
| "mscale_all_dim": 1.0, | |
| "original_max_position_embeddings": 16384, | |
| "rope_theta": 1000000.0, | |
| "rope_type": "yarn", | |
| "type": "yarn" | |
| }, | |
| "sliding_window": null, | |
| "tie_word_embeddings": true, | |
| "transformers_version": "5.6.2", | |
| "use_cache": true, | |
| "vocab_size": 131072 | |
| } | |