Skip to content

Commit

Permalink
fix nf4 xpu finetune
Browse files Browse the repository at this point in the history
Signed-off-by: jiqing-feng <[email protected]>
  • Loading branch information
jiqing-feng committed Jan 21, 2025
1 parent b7ca20b commit 337c3f4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bitsandbytes/backends/xpu.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ def dequantize_4bit(
if blocksize is None:
blocksize = 64
assert_on_xpu([A, absmax, out])
if quant_type == "nf4":
if quant_type == "nf4" and getattr(quant_state, "ipex", False):
output = torch.ops.torch_ipex.dequantize_4bit(A, "nf4", quant_state.shape, absmax, None, blocksize).t()
else:
output = dequantize_4bit_impl(A, quant_state, absmax, out, blocksize, quant_type)
Expand Down

0 comments on commit 337c3f4

Please sign in to comment.