Skip to content

Commit

Permalink
cleanup code
Browse files Browse the repository at this point in the history
  • Loading branch information
LRL-ModelCloud committed Jun 28, 2024
1 parent 8670dc4 commit f37b4ae
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
6 changes: 0 additions & 6 deletions gptqmodel/nn_modules/qlinear/qlinear_exllama.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,9 @@ def __init__(self, bits: int, group_size: int , sym:bool, desc_act: bool, infeat
self.original_outfeatures = outfeatures
self.original_infeatures = infeatures

# code bug prevention
del infeatures
del outfeatures
del group_size

self.maxq = 2**self.bits - 1

assert self.infeatures % 32 == 0
assert self.infeatures % self.group_size == 0
assert self.outfeatures % 32 == 0

self.register_buffer(
Expand Down
7 changes: 0 additions & 7 deletions gptqmodel/nn_modules/qlinear/qlinear_exllamav2.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,16 +118,9 @@ def __init__(self, bits: int, group_size: int, sym: bool, desc_act: bool, infeat
# backup original values
self.original_outfeatures = outfeatures
self.original_infeatures = infeatures

# code bug prevention
del infeatures
del outfeatures
del group_size

self.maxq = 2**self.bits - 1

assert self.infeatures % 32 == 0
assert self.infeatures % self.group_size == 0
assert self.outfeatures % 32 == 0

# I need to register the tensors, otherwise, we won't be able to load them easily using transformers ...
Expand Down

0 comments on commit f37b4ae

Please sign in to comment.