6chan commited on
Commit
0f93f89
·
verified ·
1 Parent(s): b6cea7c

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +28 -38
README.md CHANGED
@@ -13,50 +13,40 @@ tags:
13
  - diffusion-single-file
14
  pipeline_tag: image-to-image
15
  ---
 
16
  # flux1-kontext-dev-fp8
17
 
18
- This repository provides FP8-quantized weights for [black-forest-labs/FLUX.1-Kontext-dev](https://huggingface.co/black-forest-labs/FLUX.1-Kontext-dev). Both E4M3FN and E5M2 FP8 formats are available.
19
 
20
  ## Model Overview
21
-
22
- - **Source model:** [black-forest-labs/FLUX.1-Kontext-dev](https://huggingface.co/black-forest-labs/FLUX.1-Kontext-dev)
23
- - **Quantization:** All weights are converted to FP8 (float8_e4m3fn and float8_e5m2) for reduced storage and memory usage.
24
- - **Intended use:** For research and testing on hardware and software stacks supporting FP8 (PyTorch 2.4+, CUDA 12.4+, Hopper/Ada GPUs).
25
- - **Disclaimer:** FP8 quantization may lead to reduced inference quality. Not all software/hardware supports FP8.
26
-
27
- ## Key Features
28
-
29
- 1. **FP8 Quantization:** Weights are provided in both E4M3FN and E5M2 FP8 formats for maximum compatibility and efficiency.
30
- 2. **Storage & Memory Efficient:** Significantly reduces model file size and GPU memory usage compared to float16/bfloat16.
31
- 3. **ComfyUI Compatible:** Ready to use with [ComfyUI](https://github.com/comfyanonymous/ComfyUI) and other frameworks supporting FP8.
32
-
33
- ## Files
34
-
35
- - flux1-kontext-dev-fp8-e4m3fn.safetensors FP8 (E4M3FN) quantized weights
36
- - `flux1-kontext-dev-fp8-e5m2.safetensors` — FP8 (E5M2) quantized weights
37
-
38
- ## Usage (Recommended: ComfyUI)
39
-
40
- We recommend using these weights with [ComfyUI](https://github.com/comfyanonymous/ComfyUI) and its FP8 support.
41
- To use:
42
-
43
- 1. Place the `.safetensors` file in your ComfyUI models directory.
44
- 2. Make sure your ComfyUI and PyTorch installation support FP8 (PyTorch 2.4+, CUDA 12.4+, Hopper/Ada GPU).
45
- 3. Select the FP8 model in your ComfyUI workflow as you would with standard weights.
46
-
47
- ## Credits
48
-
49
- - Original model by [black-forest-labs](https://huggingface.co/black-forest-labs)
50
-
51
- # License
52
- This model falls under the [FLUX.1 \[dev\] Non-Commercial License](https://github.com/black-forest-labs/flux/blob/main/model_licenses/LICENSE-FLUX1-dev).
53
-
54
- # Citation
55
-
56
  ```bib
57
  @misc{labs2025flux1kontextflowmatching,
58
- title={FLUX.1 Kontext: Flow Matching for In-Context Image Generation and Editing in Latent Space}, Add commentMore actions
59
- author={Black Forest Labs and Stephen Batifol and Andreas Blattmann and Frederic Boesel and Saksham Consul and Cyril Diagne and Tim Dockhorn and Jack English and Zion English and Patrick Esser and Sumith Kulal and Kyle Lacey and Yam Levi and Cheng Li and Dominik Lorenz and Jonas Müller and Dustin Podell and Robin Rombach and Harry Saini and Axel Sauer and Luke Smith},
60
  year={2025},
61
  eprint={2506.15742},
62
  archivePrefix={arXiv},
 
13
  - diffusion-single-file
14
  pipeline_tag: image-to-image
15
  ---
16
+
17
  # flux1-kontext-dev-fp8
18
 
19
+ FP8-quantized weights for [FLUX.1-Kontext-dev](https://huggingface.co/black-forest-labs/FLUX.1-Kontext-dev) diffusion models. Supports both E4M3FN and E5M2 formats.
20
 
21
  ## Model Overview
22
+ - **Base Model**: [FLUX.1-Kontext-dev](https://huggingface.co/black-forest-labs/FLUX.1-Kontext-dev) (diffusion model component)
23
+ - **Quantization**: Per-tensor dynamic quantization to FP8 (E4M3FN/E5M2)
24
+ - **Size Reduction**: ~40% smaller than original weights
25
+ - **Model Scope**: This is **only the diffusion_model** component (not full pipeline), should be placed in ComfyUI's `diffusion_models` directory
26
+ - **Compatibility**:
27
+ - ✅ ComfyUI (with PyTorch 2.4+ and CUDA 12.4+)
28
+ - Diffusers (currently unsupported)
29
+
30
+ ## Available Files
31
+ - `flux1-kontext-dev-fp8-e4m3fn.safetensors` - Balanced performance/accuracy
32
+ - `flux1-kontext-dev-fp8-e5m2.safetensors` - Higher throughput on Hopper GPUs
33
+
34
+ ## Usage
35
+ 1. Move the `.safetensors` file to your ComfyUI `diffusion_models` directory
36
+ 2. Select fp8 modes in UNet Loader like `fp8_e4m3fn`.
37
+
38
+ ## Known Limitations
39
+ 1. Not compatible with standard Diffusers pipelines
40
+ 2. Requires patched PyTorch versions for optimal performance
41
+
42
+ ## License
43
+ This model is distributed under the [FLUX.1(dev) Non-Commercial License](https://github.com/black-forest-labs/flux/blob/main/model_licenses/LICENSE-FLUX1-dev). Commercial use prohibited without authorization.
44
+
45
+ ## Citation
 
 
 
 
 
 
 
 
 
 
 
46
  ```bib
47
  @misc{labs2025flux1kontextflowmatching,
48
+ title={FLUX.1 Kontext: Flow Matching for In-Context Image Generation and Editing in Latent Space},
49
+ author={Black Forest Labs et al.},
50
  year={2025},
51
  eprint={2506.15742},
52
  archivePrefix={arXiv},