videorebirth commited on
Commit
2662932
·
verified ·
1 Parent(s): 991c8ba

Model card and NOTICE: ComfyUI INT8 convrot safetensors (*_int8_convrot_comfyui/)

Browse files
Files changed (2) hide show
  1. NOTICE +2 -0
  2. README.md +25 -10
NOTICE CHANGED
@@ -10,6 +10,8 @@ Modifications from MiniMax H3 (Section III.2):
10
  rotated W8A8 INT8.
11
  - fl2va_gguf/ and ref2va_gguf/: The compressed transformer weights are converted to the stable-diffusion.cpp tensor
12
  layout and quantized to GGUF.
 
 
13
  - hyperflow_h3_flash_transformer.py: Modified from the diffusers MiniMax-H3 transformer (paired with
14
  hyperflow_h3_flash_int8.py for rotated INT8 linear layers).
15
  - The upstream text encoder, VAEs, tokenizer, and processor are not redistributed here and remain the official
 
10
  rotated W8A8 INT8.
11
  - fl2va_gguf/ and ref2va_gguf/: The compressed transformer weights are converted to the stable-diffusion.cpp tensor
12
  layout and quantized to GGUF.
13
+ - fl2va_int8_convrot_comfyui/ and ref2va_int8_convrot_comfyui/: The INT8 convrot transformers are converted to the
14
+ ComfyUI tensor layout. The INT8 codes and scales are unchanged.
15
  - hyperflow_h3_flash_transformer.py: Modified from the diffusers MiniMax-H3 transformer (paired with
16
  hyperflow_h3_flash_int8.py for rotated INT8 linear layers).
17
  - The upstream text encoder, VAEs, tokenizer, and processor are not redistributed here and remain the official
README.md CHANGED
@@ -43,25 +43,27 @@ Code, setup guides, and ComfyUI workflows are in [`Video-Rebirth/hyperflow-h3-fl
43
 
44
  ### Supported Tasks
45
 
46
- | Task | Input | Hub partition | ComfyUI template | GGUF support | Python INT8 support |
47
- |---|---|---|---|---|---|
48
- | `t2va` | Text prompt | `fl2va_*` | `hyperflow_t2v` | Yes | Yes |
49
- | `fl2va` | Prompt + first keyframe, or first and last keyframes | `fl2va_*` | `hyperflow_i2v`, `hyperflow_flf2v` | Yes | Yes |
50
- | `ref2va` | Prompt + up to 12 references | `ref2va_*` | `hyperflow_ref2v` | Images only | Images, videos, and audio |
 
 
51
 
52
  ---
53
 
54
  ## Choose a Weight Format
55
 
56
- **Decision rule:** Use **GGUF** on any PC with 64 GB of system RAM or less. Use **INT8 convrot** on data-center GPUs, or on 24 GB+ RTX GPUs with at least 69 GiB of system RAM.
57
 
58
  | Feature | GGUF | INT8 convrot |
59
  |---|---|---|
60
- | **Hub folders** | `fl2va_gguf/`, `ref2va_gguf/` | `fl2va_int8_convrot/`, `ref2va_int8_convrot/` |
61
  | **Precision & size** | `Q3_K_M` to `Q8_0` (7.2–15.2 GB) | W8A8 INT8 + low-rank (~16 GB) |
62
- | **Runtime** | ComfyUI, Unsloth Studio, `stable-diffusion.cpp` | [`hyperflow-h3-flash`](https://github.com/Video-Rebirth/hyperflow-h3-flash) CLI and `diffusers` |
63
  | **Target GPU** | Consumer GPUs; measured on **24 GB and 32 GB** RTX GPUs (16 GB GPUs not measured yet) | **H100 / H200 / B200 / B300** (1–8 GPUs), or **24 GB+ RTX GPUs** |
64
- | **System RAM** | **16 GB+** | **~16 GiB** without offload; **≥ 69 GiB** (`fp8` text encoder) or **≥ 91 GiB** (`bf16`) with offload |
65
  | **`ref2va` inputs** | Images | Images, videos, and audio |
66
 
67
  ---
@@ -71,6 +73,8 @@ Code, setup guides, and ComfyUI workflows are in [`Video-Rebirth/hyperflow-h3-fl
71
  ```text
72
  fl2va_int8_convrot/ config.json, diffusion_pytorch_model-0000{1..3}-of-00003.safetensors (+ index), model code
73
  ref2va_int8_convrot/ config.json, diffusion_pytorch_model-0000{1..4}-of-00004.safetensors (+ index), model code
 
 
74
  fl2va_gguf/ minimax_h3_fl2va_hyperflow_flash_14b-<QUANT>.gguf (6 quant levels)
75
  ref2va_gguf/ minimax_h3_ref2va_hyperflow_flash_14b-<QUANT>.gguf (6 quant levels)
76
  ```
@@ -89,7 +93,7 @@ This repository stores only the compressed transformers (`transformer` for `fl2v
89
 
90
  | Quant | `fl2va_gguf/` | `ref2va_gguf/` | Recipe | When to use |
91
  |---|---:|---:|---|---|
92
- | **`Q4_K_M`** | **9.1 GB** | **9.2 GB** | `Q4_K` (lifted layers `Q6_K`) | **Recommended default for 24 GB GPUs** |
93
  | `Q8_0` | 14.9 GB | 15.2 GB | `Q8_0` | Closest to full precision when VRAM and RAM fit |
94
  | `Q6_K` | 11.6 GB | 11.8 GB | `Q6_K` | High quality, smaller than `Q8_0` |
95
  | `Q5_K_M` | 10.3 GB | 10.5 GB | `Q5_K` (lifted layers `Q6_K`) | Balanced intermediate quant |
@@ -103,6 +107,7 @@ Full setup instructions are in [`integrations/README.md`](https://github.com/Vid
103
  2. Put the `.gguf` file in `models/diffusion_models/` and download the 15.7 GB `qwen3vl_32b_minimax_h3_nvfp4_awq` text encoder.
104
  3. On 16 GB or 32 GB RAM PCs, start ComfyUI with `python main.py --fast-disk`.
105
  4. Open **Workflow > Browse Templates > ComfyUI-HyperFlow-Flash** and select `hyperflow_t2v`, `hyperflow_i2v`, `hyperflow_flf2v`, or `hyperflow_ref2v`.
 
106
  - **Unsloth Studio:** Point `SD_CLI_PATH` at the patched `sd-cli` binary (`export SD_CLI_PATH=/path/to/stable-diffusion.cpp/build/bin/sd-cli`), run `unsloth studio`, and load `VideoRebirthAI/hyperflow-h3-flash` (`fl2va_gguf/` or `ref2va_gguf/`). Studio downloads the companion files and runs the 6-step schedule at `CFG = 1`.
107
  - **stable-diffusion.cpp:** Apply [`integrations/stable-diffusion.cpp/hyperflow-two-time.patch`](https://github.com/Video-Rebirth/hyperflow-h3-flash/tree/main/integrations/stable-diffusion.cpp) to upstream commit `3be2378`, build, and run:
108
  ```bash
@@ -209,6 +214,15 @@ model.set_attention_backend("_flash_3_hub")
209
 
210
  > Note: The transformer requires `endpoint_timestep` on every forward pass for two-time `(t, r)` conditioning. Use `load_pipeline` or `hyperflow_h3_flash.flash_blocks` to run the full sampling loop.
211
 
 
 
 
 
 
 
 
 
 
212
  ---
213
 
214
  ## Benchmarks and Memory
@@ -226,6 +240,7 @@ All benchmarks measure end-to-end generation (text encoding, 6-step transformer,
226
 
227
  - **GGUF columns:** Use the 15.7 GB `nvfp4_awq` text encoder. `--fast-disk` streams unresident weights from the OS file page cache instead of pinned RAM, keeping anonymous RSS at ~8–16 GiB.
228
  - **¹ INT8 column:** Requires ≥ 91 GiB system RAM with the `bf16` text encoder, or ~69 GiB with `--text-encoder-precision fp8`.
 
229
 
230
  **Reference to video (`ref2va`) on one RTX GPU (`5.2 s / 15 s` total time):**
231
 
 
43
 
44
  ### Supported Tasks
45
 
46
+ | Task | Input | Hub partition | ComfyUI template | GGUF support | ComfyUI INT8 support | Python INT8 support |
47
+ |---|---|---|---|---|---|---|
48
+ | `t2va` | Text prompt | `fl2va_*` | `hyperflow_t2v` | Yes | Yes | Yes |
49
+ | `fl2va` | Prompt + first keyframe, or first and last keyframes | `fl2va_*` | `hyperflow_i2v`, `hyperflow_flf2v` | Yes | Yes | Yes |
50
+ | `ref2va` | Prompt + up to 12 references | `ref2va_*` | `hyperflow_ref2v` | Images only | Images only | Images, videos, and audio |
51
+
52
+ Each ComfyUI template also comes as `*_int8` with the INT8 safetensors.
53
 
54
  ---
55
 
56
  ## Choose a Weight Format
57
 
58
+ **Decision rule:** In ComfyUI on 24 GB+ RTX GPUs, use the **INT8 safetensors** (`*_int8_convrot_comfyui/`; 16 GB+ of system RAM; a PyTorch built for CUDA 13.0 or newer, or `--enable-triton-backend`). Use **GGUF** on smaller GPUs and in stable-diffusion.cpp or Unsloth Studio. Use the **INT8 convrot** Python package on data-center GPUs, or on 24 GB+ RTX GPUs with at least 69 GiB of system RAM.
59
 
60
  | Feature | GGUF | INT8 convrot |
61
  |---|---|---|
62
+ | **Hub folders** | `fl2va_gguf/`, `ref2va_gguf/` | `fl2va_int8_convrot/`, `ref2va_int8_convrot/`; single-file ComfyUI copies in `fl2va_int8_convrot_comfyui/`, `ref2va_int8_convrot_comfyui/` |
63
  | **Precision & size** | `Q3_K_M` to `Q8_0` (7.2–15.2 GB) | W8A8 INT8 + low-rank (~16 GB) |
64
+ | **Runtime** | ComfyUI, Unsloth Studio, `stable-diffusion.cpp` | [`hyperflow-h3-flash`](https://github.com/Video-Rebirth/hyperflow-h3-flash) CLI and `diffusers`; ComfyUI (`*_comfyui/` files) |
65
  | **Target GPU** | Consumer GPUs; measured on **24 GB and 32 GB** RTX GPUs (16 GB GPUs not measured yet) | **H100 / H200 / B200 / B300** (1–8 GPUs), or **24 GB+ RTX GPUs** |
66
+ | **System RAM** | **16 GB+** | **16 GB+** in ComfyUI. Python package: **~16 GiB** without offload; **≥ 69 GiB** (`fp8` text encoder) or **≥ 91 GiB** (`bf16`) with offload |
67
  | **`ref2va` inputs** | Images | Images, videos, and audio |
68
 
69
  ---
 
73
  ```text
74
  fl2va_int8_convrot/ config.json, diffusion_pytorch_model-0000{1..3}-of-00003.safetensors (+ index), model code
75
  ref2va_int8_convrot/ config.json, diffusion_pytorch_model-0000{1..4}-of-00004.safetensors (+ index), model code
76
+ fl2va_int8_convrot_comfyui/ minimax_h3_fl2va_hyperflow_flash_14b-int8_convrot.safetensors (ComfyUI, 16.0 GB)
77
+ ref2va_int8_convrot_comfyui/ minimax_h3_ref2va_hyperflow_flash_14b-int8_convrot.safetensors (ComfyUI, 16.4 GB)
78
  fl2va_gguf/ minimax_h3_fl2va_hyperflow_flash_14b-<QUANT>.gguf (6 quant levels)
79
  ref2va_gguf/ minimax_h3_ref2va_hyperflow_flash_14b-<QUANT>.gguf (6 quant levels)
80
  ```
 
93
 
94
  | Quant | `fl2va_gguf/` | `ref2va_gguf/` | Recipe | When to use |
95
  |---|---:|---:|---|---|
96
+ | **`Q4_K_M`** | **9.1 GB** | **9.2 GB** | `Q4_K` (lifted layers `Q6_K`) | **Recommended GGUF quant** |
97
  | `Q8_0` | 14.9 GB | 15.2 GB | `Q8_0` | Closest to full precision when VRAM and RAM fit |
98
  | `Q6_K` | 11.6 GB | 11.8 GB | `Q6_K` | High quality, smaller than `Q8_0` |
99
  | `Q5_K_M` | 10.3 GB | 10.5 GB | `Q5_K` (lifted layers `Q6_K`) | Balanced intermediate quant |
 
107
  2. Put the `.gguf` file in `models/diffusion_models/` and download the 15.7 GB `qwen3vl_32b_minimax_h3_nvfp4_awq` text encoder.
108
  3. On 16 GB or 32 GB RAM PCs, start ComfyUI with `python main.py --fast-disk`.
109
  4. Open **Workflow > Browse Templates > ComfyUI-HyperFlow-Flash** and select `hyperflow_t2v`, `hyperflow_i2v`, `hyperflow_flf2v`, or `hyperflow_ref2v`.
110
+ 5. On 24 GB+ GPUs, skip ComfyUI-GGUF and use the INT8 safetensors from `fl2va_int8_convrot_comfyui/` or `ref2va_int8_convrot_comfyui/` with the `*_int8` templates; see [INT8 convrot in ComfyUI](#int8-convrot-in-comfyui).
111
  - **Unsloth Studio:** Point `SD_CLI_PATH` at the patched `sd-cli` binary (`export SD_CLI_PATH=/path/to/stable-diffusion.cpp/build/bin/sd-cli`), run `unsloth studio`, and load `VideoRebirthAI/hyperflow-h3-flash` (`fl2va_gguf/` or `ref2va_gguf/`). Studio downloads the companion files and runs the 6-step schedule at `CFG = 1`.
112
  - **stable-diffusion.cpp:** Apply [`integrations/stable-diffusion.cpp/hyperflow-two-time.patch`](https://github.com/Video-Rebirth/hyperflow-h3-flash/tree/main/integrations/stable-diffusion.cpp) to upstream commit `3be2378`, build, and run:
113
  ```bash
 
214
 
215
  > Note: The transformer requires `endpoint_timestep` on every forward pass for two-time `(t, r)` conditioning. Use `load_pipeline` or `hyperflow_h3_flash.flash_blocks` to run the full sampling loop.
216
 
217
+ ### INT8 convrot in ComfyUI
218
+
219
+ `fl2va_int8_convrot_comfyui/` and `ref2va_int8_convrot_comfyui/` hold the same INT8 transformers as single safetensors files in ComfyUI's tensor layout: the INT8 linears are ComfyUI `int8_tensorwise` + convrot layers with unchanged INT8 codes and scales, and the low-rank linears stay bf16.
220
+
221
+ 1. Install [ComfyUI-HyperFlow-Flash](https://github.com/Video-Rebirth/ComfyUI-HyperFlow-Flash) 1.1.0 or newer (ComfyUI-GGUF is not needed), put the file in `models/diffusion_models/`, and download the same text encoder and VAEs as for a GGUF.
222
+ 2. Open `hyperflow_t2v_int8`, `hyperflow_i2v_int8`, `hyperflow_flf2v_int8`, or `hyperflow_ref2v_int8`. **HyperFlow Loader** reads the file; stock loaders do not support the two-time embedder or factorized linear layers.
223
+ 3. Start ComfyUI with `--enable-triton-backend`, or use a PyTorch built for CUDA 13.0 or newer; ComfyUI's PyTorch INT8 fallback is about 50% slower. On the RTX 5090 and 4090 the INT8 file is 5–15% faster end-to-end than `Q4_K_M`, and as fast as the `Q8_0` and `BF16` GGUFs on one H200 ([timings](https://github.com/Video-Rebirth/hyperflow-h3-flash/blob/main/integrations/README.md#int8-performance)).
224
+ 4. It runs on PCs with 16 GB of system RAM: measured with 12 GiB left to ComfyUI 0.44.0 on the RTX 5090 and 4090.
225
+
226
  ---
227
 
228
  ## Benchmarks and Memory
 
240
 
241
  - **GGUF columns:** Use the 15.7 GB `nvfp4_awq` text encoder. `--fast-disk` streams unresident weights from the OS file page cache instead of pinned RAM, keeping anonymous RSS at ~8–16 GiB.
242
  - **¹ INT8 column:** Requires ≥ 91 GiB system RAM with the `bf16` text encoder, or ~69 GiB with `--text-encoder-precision fp8`.
243
+ - **ComfyUI INT8 safetensors:** 5–15% faster end-to-end than `Q4_K_M` on the same RTX 5090 and 4090, also with 12 GiB of system RAM left to ComfyUI ([timings](https://github.com/Video-Rebirth/hyperflow-h3-flash/blob/main/integrations/README.md#int8-performance)).
244
 
245
  **Reference to video (`ref2va`) on one RTX GPU (`5.2 s / 15 s` total time):**
246