xuekt's picture
Upload folder using huggingface_hub
46989a2 verified
|
Raw History Blame Contribute Delete
1.64 kB

FLUX.1-dev Q8_0 GGUF (hybrid layout)

Q8_0 quantized FLUX.1-dev transformer for 32 GB-VRAM GPUs. Other components (text encoders / tokenizers / VAE) are shared via NTFS junctions + hardlinks with FLUX.1-dev/ (bf16) -- no duplicate storage.

Source

Layout

FLUX.1-dev-Q8-GGUF/
+- README.md            (hardlink -> FLUX.1-dev/README.md)
+- model_index.json     (hardlink -> FLUX.1-dev/model_index.json)
+- text_encoder/        (junction -> FLUX.1-dev/text_encoder)
+- text_encoder_2/      (junction -> FLUX.1-dev/text_encoder_2)
+- tokenizer/           (junction -> FLUX.1-dev/tokenizer)
+- tokenizer_2/         (junction -> FLUX.1-dev/tokenizer_2)
+- vae/                 (junction -> FLUX.1-dev/vae)
+- transformer/
   +- flux1-dev-Q8_0.gguf  (real, 12.7 GB)

Inference (diffusers GGUF loader)

import torch
from diffusers import FluxPipeline
from diffusers.quantizers.quantization_config import GGUFQuantizationConfig

pipe = FluxPipeline.from_pretrained(
    "project_codes/PRISM/weights/FLUX.1-dev-Q8-GGUF",
    transformer_quant_config=GGUFQuantizationConfig(compute_dtype=torch.bfloat16),
    torch_dtype=torch.bfloat16,
)
pipe.to("cuda")

See https://huggingface.co/docs/diffusers/main/en/quantization/gguf for the current API (exact arg name may vary by diffusers version).

Disk usage

  • Real files (only this folder): 12.7 GB (the .gguf itself)
  • Shared with FLUX.1-dev/: 0 GB extra (junctions / hardlinks)