Skip to content

Commit 1c04035

Browse files
committed
simplify code
Signed-off-by: Kyle Sayers <[email protected]>
1 parent 5c8206f commit 1c04035

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/llmcompressor/observers/base.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,7 @@ def get_global_scale(self, observed: torch.Tensor) -> torch.nn.Parameter:
8484
"""
8585
observed = observed.reshape((1, 1, -1)) # per tensor reshape
8686
min_vals, max_vals = self.get_min_max(observed)
87-
global_scale = generate_gparam(min_vals, max_vals)
88-
89-
return global_scale
87+
return generate_gparam(min_vals, max_vals)
9088

9189
def _get_module_param(self, name: str) -> Optional[torch.nn.Parameter]:
9290
if self.module is None:

0 commit comments

Comments
 (0)