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
| { | |
| "status": "metrics_recorded", | |
| "source_model_id": "black-forest-labs/FLUX.2-klein-4B", | |
| "source_revision": "e7b7dc27f91deacad38e78976d1f2b499d76a294", | |
| "weight_bits": 2, | |
| "activation_bits": 4, | |
| "target_policy": "flux2", | |
| "runtime_mode": "dequant_bf16", | |
| "activation_kernel_backend": "triton_cuda", | |
| "quantization_device": "cuda", | |
| "weight_quantization_backend": "triton_cuda", | |
| "quantization_staging_mode": "component", | |
| "synchronize_per_module": false, | |
| "quantization_elapsed_seconds": 1.5810900568030775, | |
| "orbitquant_seconds": 0.19174260506406426, | |
| "adaln_seconds": 0.33127500861883163, | |
| "device_transfer_seconds": 1.0542921121232212, | |
| "module_device_transfer_count": 1, | |
| "source_linear_device_counts": { | |
| "cpu": 109 | |
| }, | |
| "quantized_buffer_device_counts": { | |
| "cuda:0": 206 | |
| }, | |
| "metrics": { | |
| "original": { | |
| "records": 10, | |
| "latest": { | |
| "split": "original", | |
| "metrics": { | |
| "generated_samples": 1, | |
| "wall_time_seconds": 1.3608336239121854, | |
| "peak_vram_bytes": 18602007552 | |
| }, | |
| "metadata": { | |
| "suite": "flux2-native", | |
| "prompt": "A reflective chrome teapot partly hidden behind orange flowers, with the room visible as a coherent reflection on the metal", | |
| "prompt_record": { | |
| "id": "occlusion-reflection", | |
| "category": "occlusion_reflection", | |
| "prompt": "A reflective chrome teapot partly hidden behind orange flowers, with the room visible as a coherent reflection on the metal" | |
| }, | |
| "seed": 0, | |
| "height": 1024, | |
| "width": 1024, | |
| "frames": null, | |
| "steps": 4, | |
| "guidance": 1.0, | |
| "bit_setting": "original", | |
| "output_path": "/workspace/artifacts/native/flux2-native-w2a4/assets/flux2-native_seed0_original_occlusion-reflection.png", | |
| "metadata_path": "/workspace/artifacts/native/flux2-native-w2a4/assets/flux2-native_seed0_original_occlusion-reflection.png.json", | |
| "asset_paths": [], | |
| "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": 16037566464, | |
| "cuda_memory_reserved_bytes": 21021851648, | |
| "cuda_peak_memory_allocated_bytes": 18602007552 | |
| }, | |
| "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" | |
| } | |
| } | |
| } | |
| } | |
| }, | |
| "orbitquant": { | |
| "records": 10, | |
| "latest": { | |
| "split": "orbitquant", | |
| "metrics": { | |
| "generated_samples": 1, | |
| "wall_time_seconds": 1.6052065640687943, | |
| "peak_vram_bytes": 19604974592 | |
| }, | |
| "metadata": { | |
| "suite": "flux2-native", | |
| "prompt": "A reflective chrome teapot partly hidden behind orange flowers, with the room visible as a coherent reflection on the metal", | |
| "prompt_record": { | |
| "id": "occlusion-reflection", | |
| "category": "occlusion_reflection", | |
| "prompt": "A reflective chrome teapot partly hidden behind orange flowers, with the room visible as a coherent reflection on the metal" | |
| }, | |
| "seed": 0, | |
| "height": 1024, | |
| "width": 1024, | |
| "frames": null, | |
| "steps": 4, | |
| "guidance": 1.0, | |
| "bit_setting": "W2A4", | |
| "output_path": "/workspace/artifacts/native/flux2-native-w2a4/assets/flux2-native_seed0_W2A4_occlusion-reflection.png", | |
| "metadata_path": "/workspace/artifacts/native/flux2-native-w2a4/assets/flux2-native_seed0_W2A4_occlusion-reflection.png.json", | |
| "asset_paths": [], | |
| "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" | |
| } | |
| } | |
| } | |
| } | |
| } | |
| } | |
| } | |