Skip to content

Commit af381ad

Browse files
committed
update
1 parent 0ed31bc commit af381ad

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/diffusers/models/model_loading_utils.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -467,11 +467,13 @@ def load_gguf_checkpoint(gguf_checkpoint_path, return_tensors=False):
467467
# if the tensor is a torch supported dtype do not use GGUFParameter
468468
is_gguf_quant = quant_type not in [gguf.GGMLQuantizationType.F32, gguf.GGMLQuantizationType.F16]
469469
if is_gguf_quant and quant_type not in SUPPORTED_GGUF_QUANT_TYPES:
470+
_supported_quants_str = "\n".join([str(type) for type in SUPPORTED_GGUF_QUANT_TYPES])
470471
raise ValueError(
471472
(
472-
f"{name} has a quantization type: {quant_type} which is unsupported."
473-
f" Currently the following quantization types are supported: {SUPPORTED_GGUF_QUANT_TYPES}"
474-
"To request support for this quantization type please open an issue here: https://github.com/huggingface/diffusers"
473+
f"{name} has a quantization type: {str(quant_type)} which is unsupported."
474+
"\n\nCurrently the following quantization types are supported: \n\n"
475+
f"{_supported_quants_str}"
476+
"\n\nTo request support for this quantization type please open an issue here: https://github.com/huggingface/diffusers"
475477
)
476478
)
477479

0 commit comments

Comments
 (0)