From f2ab48cd75ec04a41349f05233ebcd8974a2b076 Mon Sep 17 00:00:00 2001 From: lin-bot23 Date: Thu, 23 Jul 2026 06:13:33 +0800 Subject: [PATCH 1/2] docs: explain FP8 format suffixes (e4m3fn, e5m2, e8m0fnu) in startup flags page --- development/comfyui-server/startup-flags.mdx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/development/comfyui-server/startup-flags.mdx b/development/comfyui-server/startup-flags.mdx index 8b6da247f..9f7775b4a 100644 --- a/development/comfyui-server/startup-flags.mdx +++ b/development/comfyui-server/startup-flags.mdx @@ -106,6 +106,11 @@ python main.py --disable-auto-launch | `--fp8_e5m2-unet` | Store UNet weights in fp8 (e5m2). | | `--fp8_e8m0fnu-unet` | Store UNet weights in fp8 (e8m0fnu). | +The suffix in each FP8 flag identifies the IEEE-compatible format: +- **e4m3fn** — 4 exponent bits, 3 mantissa bits. Good balance of precision and range for model weights on NVIDIA Ada Lovelace and newer GPUs. +- **e5m2** — 5 exponent bits, 2 mantissa bits. Wider dynamic range but lower precision than e4m3fn. Useful when weight magnitudes vary widely. +- **e8m0fnu** — 8 exponent bits, 0 mantissa bits. Maximum dynamic range with no fractional precision (acts as a per-tensor scale factor). + ### VAE precision | Flag | Description | @@ -125,6 +130,8 @@ python main.py --disable-auto-launch | `--fp32-text-enc` | Store text encoder weights in fp32. | | `--bf16-text-enc` | Store text encoder weights in bf16. | +See the [UNET precision](#unet-precision) table for the explanation of each FP8 format suffix. + ### Other inference options | Flag | Default | Description | From 0b57c75982886b63f72f4c4ec69260fd44491038 Mon Sep 17 00:00:00 2001 From: ComfyUI Wiki Date: Fri, 24 Jul 2026 17:15:31 +0800 Subject: [PATCH 2/2] docs: polish FP8 format notes and sync zh/ja/ko startup flags Clarify ONNX/OCP spec wording, block scaling for e8m0fnu, and cross-link phrasing across locales. --- development/comfyui-server/startup-flags.mdx | 10 +++++----- ja/development/comfyui-server/startup-flags.mdx | 17 +++++++++++++++-- ko/development/comfyui-server/startup-flags.mdx | 17 +++++++++++++++-- zh/development/comfyui-server/startup-flags.mdx | 17 +++++++++++++++-- 4 files changed, 50 insertions(+), 11 deletions(-) diff --git a/development/comfyui-server/startup-flags.mdx b/development/comfyui-server/startup-flags.mdx index 9f7775b4a..42d7b1a72 100644 --- a/development/comfyui-server/startup-flags.mdx +++ b/development/comfyui-server/startup-flags.mdx @@ -106,10 +106,10 @@ python main.py --disable-auto-launch | `--fp8_e5m2-unet` | Store UNet weights in fp8 (e5m2). | | `--fp8_e8m0fnu-unet` | Store UNet weights in fp8 (e8m0fnu). | -The suffix in each FP8 flag identifies the IEEE-compatible format: -- **e4m3fn** — 4 exponent bits, 3 mantissa bits. Good balance of precision and range for model weights on NVIDIA Ada Lovelace and newer GPUs. -- **e5m2** — 5 exponent bits, 2 mantissa bits. Wider dynamic range but lower precision than e4m3fn. Useful when weight magnitudes vary widely. -- **e8m0fnu** — 8 exponent bits, 0 mantissa bits. Maximum dynamic range with no fractional precision (acts as a per-tensor scale factor). +Each FP8 flag suffix names an 8-bit float layout from the industry FP8 spec (ONNX / OCP): +- **e4m3fn**: 4 exponent bits, 3 mantissa bits. Good balance of precision and range for model weights on NVIDIA Ada Lovelace and newer GPUs. +- **e5m2**: 5 exponent bits, 2 mantissa bits. Wider dynamic range but lower precision than e4m3fn. Useful when weight magnitudes vary widely. +- **e8m0fnu**: 8 exponent bits, 0 mantissa bits. Maximum dynamic range with no fractional precision. Typically used as a block scaling factor (powers of two only). ### VAE precision @@ -130,7 +130,7 @@ The suffix in each FP8 flag identifies the IEEE-compatible format: | `--fp32-text-enc` | Store text encoder weights in fp32. | | `--bf16-text-enc` | Store text encoder weights in bf16. | -See the [UNET precision](#unet-precision) table for the explanation of each FP8 format suffix. +See the [UNET precision](#unet-precision) section for the explanation of each FP8 format suffix. ### Other inference options diff --git a/ja/development/comfyui-server/startup-flags.mdx b/ja/development/comfyui-server/startup-flags.mdx index 8d1a1ee37..f0b0f08b4 100644 --- a/ja/development/comfyui-server/startup-flags.mdx +++ b/ja/development/comfyui-server/startup-flags.mdx @@ -3,7 +3,7 @@ title: "起動オプション" sidebarTitle: "起動オプション" description: "ComfyUI main.py コマンドライン引数の完全リファレンス" icon: "terminal" -translationSourceHash: 9ff91388 +translationSourceHash: 36e139e1 translationFrom: development/comfyui-server/startup-flags.mdx translationBlockHashes: "_intro": 10812161 @@ -11,7 +11,7 @@ translationBlockHashes: "Directories": a888efb3 "Launch & Browser": c34b0f9e "Devices & CUDA": 64727146 - "Precision & Inference": b288036f + "Precision & Inference": 3211a33a "Preview": 92d0c26e "Cache": 2e1855f7 "Attention": 35477f4d @@ -24,6 +24,12 @@ translationBlockHashes: --- + + + + + + `python main.py` で ComfyUI を起動する際、コマンドライン引数を指定できます。このページでは [`comfy/cli_args.py`](https://github.com/Comfy-Org/ComfyUI/blob/master/comfy/cli_args.py) で定義されているすべてのフラグを説明します。 @@ -125,6 +131,11 @@ python main.py --disable-auto-launch | `--fp8_e5m2-unet` | UNet 重みを fp8(e5m2)で保存。 | | `--fp8_e8m0fnu-unet` | UNet 重みを fp8(e8m0fnu)で保存。 | +各 FP8 フラグのサフィックスは、業界 FP8 仕様(ONNX / OCP)の 8 ビット浮動小数点レイアウトを示します: +- **e4m3fn**:指数 4 ビット、仮数 3 ビット。NVIDIA Ada Lovelace 以降の GPU で、モデル重みの精度とダイナミックレンジのバランスに優れます。 +- **e5m2**:指数 5 ビット、仮数 2 ビット。e4m3fn よりダイナミックレンジは広いが精度は低い。重みの大きさが大きく変動する場合に有用です。 +- **e8m0fnu**:指数 8 ビット、仮数 0 ビット。ダイナミックレンジが最大で小数精度はありません。ブロック単位のスケール係数として使われます(2 の累乗のみ)。 + ### VAE 精度 | フラグ | 説明 | @@ -144,6 +155,8 @@ python main.py --disable-auto-launch | `--fp32-text-enc` | テキストエンコーダー重みを fp32 で保存。 | | `--bf16-text-enc` | テキストエンコーダー重みを bf16 で保存。 | +各 FP8 形式サフィックスの説明は [UNET 精度](#unet-精度) セクションを参照してください。 + ### その他の推論オプション | フラグ | デフォルト | 説明 | diff --git a/ko/development/comfyui-server/startup-flags.mdx b/ko/development/comfyui-server/startup-flags.mdx index d4004ebbb..d31805998 100644 --- a/ko/development/comfyui-server/startup-flags.mdx +++ b/ko/development/comfyui-server/startup-flags.mdx @@ -3,7 +3,7 @@ title: "시작 플래그" sidebarTitle: "시작 플래그" description: "ComfyUI main.py 명령줄 인수에 대한 완전한 참조" icon: "terminal" -translationSourceHash: 9ff91388 +translationSourceHash: 36e139e1 translationFrom: development/comfyui-server/startup-flags.mdx translationBlockHashes: "_intro": 10812161 @@ -11,7 +11,7 @@ translationBlockHashes: "Directories": a888efb3 "Launch & Browser": c34b0f9e "Devices & CUDA": 64727146 - "Precision & Inference": b288036f + "Precision & Inference": 3211a33a "Preview": 92d0c26e "Cache": 2e1855f7 "Attention": 35477f4d @@ -22,6 +22,12 @@ translationBlockHashes: "Frontend & API": 29822d6a "Logging & Misc": c42cbeb6 --- + + + + + + ComfyUI는 `python main.py`로 시작할 때 명령줄 인수를 허용합니다. 이 페이지는 [`comfy/cli_args.py`](https://github.com/Comfy-Org/ComfyUI/blob/master/comfy/cli_args.py)에 정의된 모든 플래그를 설명합니다. @@ -123,6 +129,11 @@ python main.py --disable-auto-launch | `--fp8_e5m2-unet` | UNet 가중치를 fp8(e5m2)로 저장합니다. | | `--fp8_e8m0fnu-unet` | UNet 가중치를 fp8(e8m0fnu)로 저장합니다. | +각 FP8 플래그 접미사는 업계 FP8 사양(ONNX / OCP)의 8비트 부동소수점 레이아웃을 나타냅니다: +- **e4m3fn**: 지수 4비트, 가수 3비트. NVIDIA Ada Lovelace 이상 GPU에서 모델 가중치의 정밀도와 동적 범위 사이의 균형이 좋습니다. +- **e5m2**: 지수 5비트, 가수 2비트. e4m3fn보다 동적 범위는 넓지만 정밀도는 낮습니다. 가중치 크기가 크게 변하는 경우에 유용합니다. +- **e8m0fnu**: 지수 8비트, 가수 0비트. 동적 범위가 최대이며 소수 정밀도는 없습니다. 블록 단위 스케일 팩터로 사용됩니다(2의 거듭제곱만 표현). + ### VAE 정밀도 | 플래그 | 설명 | @@ -142,6 +153,8 @@ python main.py --disable-auto-launch | `--fp32-text-enc` | 텍스트 인코더 가중치를 fp32로 저장합니다. | | `--bf16-text-enc` | 텍스트 인코더 가중치를 bf16으로 저장합니다. | +각 FP8 형식 접미사에 대한 설명은 [UNET 정밀도](#unet-정밀도) 섹션을 참고하세요. + ### 기타 추론 옵션 | 플래그 | 기본값 | 설명 | diff --git a/zh/development/comfyui-server/startup-flags.mdx b/zh/development/comfyui-server/startup-flags.mdx index dac319a78..a29a42e47 100644 --- a/zh/development/comfyui-server/startup-flags.mdx +++ b/zh/development/comfyui-server/startup-flags.mdx @@ -3,7 +3,7 @@ title: "启动参数" sidebarTitle: "启动参数" description: "ComfyUI main.py 命令行启动参数完整参考" icon: "terminal" -translationSourceHash: 9ff91388 +translationSourceHash: 36e139e1 translationFrom: development/comfyui-server/startup-flags.mdx translationBlockHashes: "_intro": 10812161 @@ -11,7 +11,7 @@ translationBlockHashes: "Directories": a888efb3 "Launch & Browser": c34b0f9e "Devices & CUDA": 64727146 - "Precision & Inference": b288036f + "Precision & Inference": 3211a33a "Preview": 92d0c26e "Cache": 2e1855f7 "Attention": 35477f4d @@ -24,6 +24,12 @@ translationBlockHashes: --- + + + + + + 使用 `python main.py` 启动 ComfyUI 时可传入命令行参数。本页记录了 [`comfy/cli_args.py`](https://github.com/Comfy-Org/ComfyUI/blob/master/comfy/cli_args.py) 中定义的全部启动参数。 @@ -125,6 +131,11 @@ python main.py --disable-auto-launch | `--fp8_e5m2-unet` | 以 fp8(e5m2)存储 UNet 权重。 | | `--fp8_e8m0fnu-unet` | 以 fp8(e8m0fnu)存储 UNet 权重。 | +每个 FP8 参数后缀对应业界 FP8 规范(ONNX / OCP)中的一种 8 位浮点布局: +- **e4m3fn**:4 位指数、3 位尾数。在 NVIDIA Ada Lovelace 及更新 GPU 上,为模型权重提供精度与动态范围的良好平衡。 +- **e5m2**:5 位指数、2 位尾数。动态范围比 e4m3fn 更宽,但精度较低。适用于权重幅度变化较大的场景。 +- **e8m0fnu**:8 位指数、0 位尾数。动态范围最大,无小数精度。通常用作块级缩放因子(仅能表示 2 的幂)。 + ### VAE 精度 | 参数 | 说明 | @@ -144,6 +155,8 @@ python main.py --disable-auto-launch | `--fp32-text-enc` | 以 fp32 存储文本编码器权重。 | | `--bf16-text-enc` | 以 bf16 存储文本编码器权重。 | +有关各 FP8 格式后缀的说明,请参见 [UNET 精度](#unet-精度) 小节。 + ### 其他推理选项 | 参数 | 默认值 | 说明 |