Instructions to use tsolful/MOSS_Image_INT6_INT4GPTQ with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusion Single File
How to use tsolful/MOSS_Image_INT6_INT4GPTQ with Diffusion Single File:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -29,6 +29,21 @@ The official ComfyUI repackage (BF16 and INT8 ConvRot diffusion models, text enc
|
|
| 29 |
|
| 30 |
## Files
|
| 31 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 32 |
### Plain rounding (RTN)
|
| 33 |
|
| 34 |
* `moss_image_base_W6A8.safetensors`: the MOSS-Image-Base diffusion transformer as a single file in ComfyUI's native INT6 W6A8 format.
|
|
@@ -36,12 +51,7 @@ The official ComfyUI repackage (BF16 and INT8 ConvRot diffusion models, text enc
|
|
| 36 |
* `moss_image_sft_W6A8.safetensors`: the MOSS-Image-SFT diffusion transformer as a single file in ComfyUI's native INT6 W6A8 format.
|
| 37 |
* `moss_image_sft_W4A8.safetensors`: the MOSS-Image-SFT diffusion transformer as a single file in ComfyUI's native INT4 W4A8 (codebook) format.
|
| 38 |
|
| 39 |
-
###
|
| 40 |
-
|
| 41 |
-
* `moss_image_base_W4A8_GPTQ.safetensors`: the MOSS-Image-Base diffusion transformer, GPTQ-quantized with mixed W4A8 / W6A8 layers.
|
| 42 |
-
* `moss_image_sft_W4A8_GPTQ.safetensors`: the MOSS-Image-SFT diffusion transformer, GPTQ-quantized with mixed W4A8 / W6A8 layers.
|
| 43 |
-
|
| 44 |
-
These use GPTQ instead of plain rounding. Blocks 0β23 are W4A8 (group size 16). The **last 18 blocks (24β41) are kept at W6A8** (group size 32). Those extra bits make the files larger than the plain W4A8 files (3.84 GB vs 3.33 GB), but output quality is much higher. These files are smaller than the all-W6A8 files and have about half their output error. See [GPTQ results](#gptq-results).
|
| 45 |
|
| 46 |
The text encoder and VAE are not included here. Download them from [Comfy-Org/MOSS-Image](https://huggingface.co/Comfy-Org/MOSS-Image):
|
| 47 |
|
|
@@ -56,12 +66,14 @@ Place the files in the following folders:
|
|
| 56 |
π ComfyUI/
|
| 57 |
βββ π models/
|
| 58 |
β βββ π diffusion_models/
|
|
|
|
|
|
|
| 59 |
β β βββ moss_image_base_W6A8.safetensors
|
| 60 |
β β βββ moss_image_base_W4A8.safetensors
|
| 61 |
-
β β βββ
|
|
|
|
| 62 |
β β βββ moss_image_sft_W6A8.safetensors
|
| 63 |
-
β β
|
| 64 |
-
β β βββ moss_image_sft_W4A8_GPTQ.safetensors
|
| 65 |
β βββ π text_encoders/
|
| 66 |
β β βββ qwen3.5_9b_int8_convrot.safetensors
|
| 67 |
β β βββ qwen3.5_9b_w4a8_gptq.safetensors
|
|
@@ -69,10 +81,12 @@ Place the files in the following folders:
|
|
| 69 |
β βββ flux2-vae.safetensors
|
| 70 |
```
|
| 71 |
|
|
|
|
|
|
|
| 72 |
Load the diffusion model with ComfyUI's **Load Diffusion Model** node, the same way as the [Comfy-Org](https://huggingface.co/Comfy-Org/MOSS-Image) files. The tensor names match Comfy-Org's repackage, and the quantization settings are stored in ComfyUI's native `_quantization_metadata` header, so no extra loader is needed.
|
| 73 |
|
| 74 |
The original model recommends 50 steps, CFG 3, shift 5, and negative-branch skipping at layer 22.
|
| 75 |
-
I've been finding good results at a minimum of 25 steps, CFG 3, and negative-branch skipping at layer 22
|
| 76 |
|
| 77 |
## Conversion details
|
| 78 |
|
|
@@ -84,11 +98,12 @@ The large layers of all 42 transformer blocks (168 layers) are stored at 6 bits
|
|
| 84 |
|---|---|---|---|---|
|
| 85 |
| BF16 ([Comfy-Org](https://huggingface.co/Comfy-Org/MOSS-Image)) | 10.2 GB | 100 % | 188 % | 0 % |
|
| 86 |
| INT8 ConvRot ([Comfy-Org](https://huggingface.co/Comfy-Org/MOSS-Image)) | 5.4 GB | 53 % | 100 % | ~1 % (estimated) |
|
|
|
|
| 87 |
| **W6A8** (this repo) | ~4.4 GB | ~43 % | ~81 % | **2.3 %** |
|
| 88 |
| **W4A8 GPTQ mixed** (this repo) | ~3.8 GB | ~38 % | ~71 % | see [GPTQ results](#gptq-results) |
|
| 89 |
| **W4A8** (this repo) | ~3.3 GB | ~33 % | ~62 % | **7.3 %** |
|
| 90 |
|
| 91 |
-
**Image prediction difference vs BF16 (SFT model):**
|
| 92 |
|
| 93 |
| Format | First step (pure noise) | By step 4 |
|
| 94 |
|---|---|---|
|
|
@@ -105,13 +120,18 @@ Output error is the relative L2 difference of the model output vs BF16 (lower is
|
|
| 105 |
|
| 106 |
| Layout | Model | Method | Bits/weight | File size | Output relL2 vs BF16 |
|
| 107 |
|---|---|---|---|---|---|
|
| 108 |
-
| All W4A8 (g16) | SFT |
|
| 109 |
-
| All
|
| 110 |
-
| W6A8
|
| 111 |
-
| W6A8
|
| 112 |
-
|
| 113 |
-
|
| 114 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 115 |
|
| 116 |
Check output quality for your own prompts and workflows before relying on it.
|
| 117 |
|
|
|
|
| 29 |
|
| 30 |
## Files
|
| 31 |
|
| 32 |
+
### GPTQ (recommended)
|
| 33 |
+
|
| 34 |
+
* `moss_image_base_W6A8_GPTQ.safetensors`: the MOSS-Image-Base diffusion transformer, GPTQ-quantized to W6A8 on all blocks. Highest quality in this repo.
|
| 35 |
+
* `moss_image_sft_W6A8_GPTQ.safetensors`: the MOSS-Image-SFT diffusion transformer, GPTQ-quantized to W6A8 on all blocks. Highest quality in this repo.
|
| 36 |
+
* `moss_image_base_W4A8_GPTQ.safetensors`: the MOSS-Image-Base diffusion transformer, GPTQ-quantized with mixed W4A8 / W6A8 layers. Best balance of size and quality.
|
| 37 |
+
* `moss_image_sft_W4A8_GPTQ.safetensors`: the MOSS-Image-SFT diffusion transformer, GPTQ-quantized with mixed W4A8 / W6A8 layers. Best balance of size and quality.
|
| 38 |
+
* `moss_image_base_W4A8_GPTQ_quant_report.json` / `moss_image_sft_W4A8_GPTQ_quant_report.json`: quantization reports from the GPTQ conversion of the mixed files (for reference only, not needed in ComfyUI).
|
| 39 |
+
|
| 40 |
+
These use GPTQ instead of plain rounding (RTN), which gives lower error at the same file size.
|
| 41 |
+
|
| 42 |
+
* **W6A8 GPTQ:** same size as the plain W6A8 files (4.37 GB), with about half the output error (0.042 β 0.020).
|
| 43 |
+
* **W4A8 GPTQ (mixed):** blocks 0β23 are W4A8 (group size 16). The **last 18 blocks (24β41) are kept at W6A8** (group size 32). Those extra bits make the files larger than the plain W4A8 files (3.84 GB vs 3.33 GB), but output quality is much higher. Their output error (0.023) is almost as low as W6A8 GPTQ, with files 0.53 GB smaller.
|
| 44 |
+
|
| 45 |
+
See [GPTQ results](#gptq-results).
|
| 46 |
+
|
| 47 |
### Plain rounding (RTN)
|
| 48 |
|
| 49 |
* `moss_image_base_W6A8.safetensors`: the MOSS-Image-Base diffusion transformer as a single file in ComfyUI's native INT6 W6A8 format.
|
|
|
|
| 51 |
* `moss_image_sft_W6A8.safetensors`: the MOSS-Image-SFT diffusion transformer as a single file in ComfyUI's native INT6 W6A8 format.
|
| 52 |
* `moss_image_sft_W4A8.safetensors`: the MOSS-Image-SFT diffusion transformer as a single file in ComfyUI's native INT4 W4A8 (codebook) format.
|
| 53 |
|
| 54 |
+
### Text encoder and VAE
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 55 |
|
| 56 |
The text encoder and VAE are not included here. Download them from [Comfy-Org/MOSS-Image](https://huggingface.co/Comfy-Org/MOSS-Image):
|
| 57 |
|
|
|
|
| 66 |
π ComfyUI/
|
| 67 |
βββ π models/
|
| 68 |
β βββ π diffusion_models/
|
| 69 |
+
β β βββ moss_image_base_W6A8_GPTQ.safetensors
|
| 70 |
+
β β βββ moss_image_base_W4A8_GPTQ.safetensors
|
| 71 |
β β βββ moss_image_base_W6A8.safetensors
|
| 72 |
β β βββ moss_image_base_W4A8.safetensors
|
| 73 |
+
β β βββ moss_image_sft_W6A8_GPTQ.safetensors
|
| 74 |
+
β β βββ moss_image_sft_W4A8_GPTQ.safetensors
|
| 75 |
β β βββ moss_image_sft_W6A8.safetensors
|
| 76 |
+
β β βββ moss_image_sft_W4A8.safetensors
|
|
|
|
| 77 |
β βββ π text_encoders/
|
| 78 |
β β βββ qwen3.5_9b_int8_convrot.safetensors
|
| 79 |
β β βββ qwen3.5_9b_w4a8_gptq.safetensors
|
|
|
|
| 81 |
β βββ flux2-vae.safetensors
|
| 82 |
```
|
| 83 |
|
| 84 |
+
You only need the diffusion model files you plan to use.
|
| 85 |
+
|
| 86 |
Load the diffusion model with ComfyUI's **Load Diffusion Model** node, the same way as the [Comfy-Org](https://huggingface.co/Comfy-Org/MOSS-Image) files. The tensor names match Comfy-Org's repackage, and the quantization settings are stored in ComfyUI's native `_quantization_metadata` header, so no extra loader is needed.
|
| 87 |
|
| 88 |
The original model recommends 50 steps, CFG 3, shift 5, and negative-branch skipping at layer 22.
|
| 89 |
+
I've been finding good results at a minimum of 25 steps, CFG 3, and negative-branch skipping at layer 22. With the shift node at 5, the results are identical to running without the node.
|
| 90 |
|
| 91 |
## Conversion details
|
| 92 |
|
|
|
|
| 98 |
|---|---|---|---|---|
|
| 99 |
| BF16 ([Comfy-Org](https://huggingface.co/Comfy-Org/MOSS-Image)) | 10.2 GB | 100 % | 188 % | 0 % |
|
| 100 |
| INT8 ConvRot ([Comfy-Org](https://huggingface.co/Comfy-Org/MOSS-Image)) | 5.4 GB | 53 % | 100 % | ~1 % (estimated) |
|
| 101 |
+
| **W6A8 GPTQ** (this repo) | ~4.4 GB | ~43 % | ~81 % | see [GPTQ results](#gptq-results) |
|
| 102 |
| **W6A8** (this repo) | ~4.4 GB | ~43 % | ~81 % | **2.3 %** |
|
| 103 |
| **W4A8 GPTQ mixed** (this repo) | ~3.8 GB | ~38 % | ~71 % | see [GPTQ results](#gptq-results) |
|
| 104 |
| **W4A8** (this repo) | ~3.3 GB | ~33 % | ~62 % | **7.3 %** |
|
| 105 |
|
| 106 |
+
**Image prediction difference vs BF16 (SFT model, RTN files):**
|
| 107 |
|
| 108 |
| Format | First step (pure noise) | By step 4 |
|
| 109 |
|---|---|---|
|
|
|
|
| 120 |
|
| 121 |
| Layout | Model | Method | Bits/weight | File size | Output relL2 vs BF16 |
|
| 122 |
|---|---|---|---|---|---|
|
| 123 |
+
| All W4A8 (g16) | SFT | RTN | 4.50 | 3.33 GB | 0.111 |
|
| 124 |
+
| All W4A8 (g16) | Base | RTN | 4.50 | 3.33 GB | 0.123 |
|
| 125 |
+
| All W6A8 (g32) | SFT | RTN | 6.25 | 4.37 GB | 0.042 |
|
| 126 |
+
| All W6A8 (g32) | Base | RTN | 6.25 | 4.37 GB | 0.042 |
|
| 127 |
+
| W6A8 blocks 24β41, rest W4A8 (g16) | Base | GPTQ | β 5.36 | 3.84 GB | **0.023** |
|
| 128 |
+
| W6A8 blocks 24β41, rest W4A8 (g16) | SFT | GPTQ | β 5.36 | 3.84 GB | **0.023** |
|
| 129 |
+
| All W6A8 (g32) | Base | GPTQ | 6.25 | 4.37 GB | **0.020** |
|
| 130 |
+
| All W6A8 (g32) | SFT | GPTQ | 6.25 | 4.37 GB | **0.020** |
|
| 131 |
+
|
| 132 |
+
* **W6A8 GPTQ:** the lowest error in this repo (0.020), about half that of plain W6A8 at the same size.
|
| 133 |
+
* **W4A8 GPTQ mixed:** keeping the last 18 blocks at W6A8 adds about 0.5 GB over plain W4A8. In return, output error drops by about 5Γ (0.111 / 0.123 β 0.023). That is nearly as good as W6A8 GPTQ, with files 0.53 GB smaller.
|
| 134 |
+
* **Plain W4A8:** the smallest files, but with the highest error, especially on Base (0.123).
|
| 135 |
|
| 136 |
Check output quality for your own prompts and workflows before relying on it.
|
| 137 |
|