diff --git a/comfy/ops.py b/comfy/ops.py index 81a97a30b..8c0aaec55 100644 --- a/comfy/ops.py +++ b/comfy/ops.py @@ -975,6 +975,7 @@ def pick_operations(weight_dtype, compute_dtype, load_device=None, disable_fast_ if not fp8_compute: disabled.add("float8_e4m3fn") disabled.add("float8_e5m2") + disabled.add("mxfp8") return mixed_precision_ops(model_config.quant_config, compute_dtype, disabled=disabled) if ( diff --git a/comfy/quant_ops.py b/comfy/quant_ops.py index 43c6fd7ce..76e755c5f 100644 --- a/comfy/quant_ops.py +++ b/comfy/quant_ops.py @@ -38,6 +38,9 @@ except ImportError as e: class _CKNvfp4Layout: pass + class _CKMxfp8Layout: + pass + def register_layout_class(name, cls): pass @@ -138,7 +141,8 @@ register_layout_class("TensorCoreFP8Layout", TensorCoreFP8Layout) register_layout_class("TensorCoreFP8E4M3Layout", TensorCoreFP8E4M3Layout) register_layout_class("TensorCoreFP8E5M2Layout", TensorCoreFP8E5M2Layout) register_layout_class("TensorCoreNVFP4Layout", TensorCoreNVFP4Layout) -register_layout_class("TensorCoreMXFP8Layout", TensorCoreMXFP8Layout) +if _CK_AVAILABLE: + register_layout_class("TensorCoreMXFP8Layout", TensorCoreMXFP8Layout) QUANT_ALGOS = { "float8_e4m3fn": {