Diffusers
Safetensors
OrbitQuantComponentArtifact
orbitquant
quantized
diffusion-transformer
8-bit precision
Instructions to use WaveCut/FLUX.2-klein-4B-OrbitQuant-W2A4 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use WaveCut/FLUX.2-klein-4B-OrbitQuant-W2A4 with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("WaveCut/FLUX.2-klein-4B-OrbitQuant-W2A4", 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
| { | |
| "suite": "flux2-native", | |
| "model_id": "black-forest-labs/FLUX.2-klein-4B", | |
| "prompt": "A blue cube beside a yellow sphere and a green pyramid on a gray table", | |
| "seed": 0, | |
| "height": 1024, | |
| "width": 1024, | |
| "frames": null, | |
| "steps": 4, | |
| "guidance": 1.0, | |
| "bit_settings": [ | |
| "W4A4", | |
| "W3A3", | |
| "W2A4", | |
| "W2A3" | |
| ], | |
| "device": "cuda", | |
| "runtime_device": { | |
| "requested_device": "cuda", | |
| "resolved_device_type": "cuda", | |
| "cuda_available": true, | |
| "cuda_active": true, | |
| "cuda_device_index": 0, | |
| "cuda_device_name": "NVIDIA RTX PRO 6000 Blackwell Server Edition", | |
| "cuda_device_capability": [ | |
| 12, | |
| 0 | |
| ], | |
| "cuda_memory_allocated_bytes": 17040533504, | |
| "cuda_memory_reserved_bytes": 22443720704, | |
| "cuda_peak_memory_allocated_bytes": 19604974592 | |
| }, | |
| "dtype": "bfloat16", | |
| "pipeline_class": "Flux2KleinPipeline", | |
| "scheduler": { | |
| "class": "FlowMatchEulerDiscreteScheduler", | |
| "config": { | |
| "num_train_timesteps": 1000, | |
| "shift": 3.0, | |
| "use_dynamic_shifting": true, | |
| "base_shift": 0.5, | |
| "max_shift": 1.15, | |
| "base_image_seq_len": 256, | |
| "max_image_seq_len": 4096, | |
| "invert_sigmas": false, | |
| "shift_terminal": null, | |
| "use_karras_sigmas": false, | |
| "use_exponential_sigmas": false, | |
| "use_beta_sigmas": false, | |
| "time_shift_type": "exponential", | |
| "stochastic_sampling": false, | |
| "_class_name": "FlowMatchEulerDiscreteScheduler", | |
| "_diffusers_version": "0.37.0.dev0" | |
| } | |
| }, | |
| "wall_time_seconds": 1.6692825159989297, | |
| "peak_vram_bytes": 19604974592, | |
| "contact_sheet_path": null, | |
| "quantization": { | |
| "config": { | |
| "quant_method": "orbitquant", | |
| "weight_bits": 2, | |
| "activation_bits": 4, | |
| "rotation": "rpbh", | |
| "rotation_seed": 0, | |
| "block_size": "paper", | |
| "codebook": "lloyd_max", | |
| "codebook_dtype": "float32", | |
| "row_norm_dtype": "bfloat16", | |
| "activation_norm_dtype": "float32", | |
| "activation_eps": 1e-12, | |
| "weight_pack_dtype": "uint8", | |
| "target_policy": "flux2", | |
| "adaln_policy": "int4_rtn", | |
| "adaln_group_size": 64, | |
| "modules_to_not_convert": [], | |
| "modules_dtype_dict": {}, | |
| "artifact_format_version": 1, | |
| "runtime_mode": "dequant_bf16", | |
| "activation_kernel_backend": "triton_cuda" | |
| }, | |
| "summary": null, | |
| "prewarm": { | |
| "orbitquant_modules": 100, | |
| "adaln_modules": 3, | |
| "total_modules": 103, | |
| "elapsed_seconds": 0.37310984497889876, | |
| "device": "cuda", | |
| "dtype": "bfloat16" | |
| } | |
| } | |
| } | |