Skip to content

Commit

Permalink
missing device (#232)
Browse files Browse the repository at this point in the history
  • Loading branch information
mikekgfb authored and malfet committed Jul 17, 2024
1 parent 6dfce10 commit 4cda110
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions quantize.py
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,11 @@ def forward(self, input: torch.Tensor) -> torch.Tensor:


def replace_embedding_weight_only_grouped_int8_per_channel(
module, device, bitwidth: int = 8, groupsize: Optional[int] = None, packed=False
module,
device,
bitwidth: int = 8,
groupsize: Optional[int] = None,
packed=False
):
for name, child in module.named_children():
# print(f"name: {name}")
Expand All @@ -535,7 +539,7 @@ def replace_embedding_weight_only_grouped_int8_per_channel(
)
else:
replace_embedding_weight_only_grouped_int8_per_channel(
child, bitwidth, groupsize, packed
child, device, bitwidth, groupsize, packed
)


Expand Down

0 comments on commit 4cda110

Please sign in to comment.