Skip to content

Commit e14b2a2

Browse files
authored
[rls2.6] Re-align order of WOQ.from_weight() (#3481)
* Re-align order of woq.from_weight * Update woq_linear.py
1 parent 88a794f commit e14b2a2

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

intel_extension_for_pytorch/llm/quantization/woq_linear.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,9 @@ def from_weight(
7070
bias,
7171
group_size,
7272
g_idx,
73-
dtype,
7473
quant_method,
74+
dtype,
75+
**kwargs
7576
)
7677
return cls(woq_linear_impl)
7778

intel_extension_for_pytorch/nn/modules/weight_only_quantization.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,8 +372,8 @@ def from_weight(
372372
bias: Optional[torch.Tensor] = None,
373373
group_size: int = -1,
374374
g_idx: Optional[torch.Tensor] = None,
375-
dtype: int = 0,
376375
quant_method: QuantMethod = QuantMethod.GPTQ_GEMM,
376+
dtype: QuantDtype = QuantDtype.INT4,
377377
**kwargs,
378378
):
379379
r"""Create a weight-only quantized module from weight

0 commit comments

Comments
 (0)