Skip to content

Commit 51519b1

Browse files
formatting
Signed-off-by: Brian Dellabetta <[email protected]>
1 parent e79c6c0 commit 51519b1

File tree

1 file changed

+16
-11
lines changed

1 file changed

+16
-11
lines changed

tests/llmcompressor/pytorch/utils/test_sparse.py

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
import pytest
22
import torch
3-
from compressed_tensors.quantization import QuantizationArgs, QuantizationScheme, QuantizationStrategy, QuantizationType
3+
from compressed_tensors.quantization import (
4+
QuantizationArgs,
5+
QuantizationScheme,
6+
QuantizationStrategy,
7+
QuantizationType,
8+
)
49
from torch.nn import Linear, Module, ReLU
510

611
from llmcompressor.pytorch.utils import ModuleSparsificationInfo
@@ -14,16 +19,16 @@ def __init__(self):
1419
self.relu = ReLU()
1520

1621
self.fc1.quantization_scheme = QuantizationScheme(
17-
targets=["Linear"],
18-
weights=QuantizationArgs(
19-
num_bits=4,
20-
type=QuantizationType.INT,
21-
group_size=128,
22-
strategy=QuantizationStrategy.GROUP,
23-
symmetric=True,
24-
dynamic=False,
25-
)
26-
)
22+
targets=["Linear"],
23+
weights=QuantizationArgs(
24+
num_bits=4,
25+
type=QuantizationType.INT,
26+
group_size=128,
27+
strategy=QuantizationStrategy.GROUP,
28+
symmetric=True,
29+
dynamic=False,
30+
),
31+
)
2732

2833

2934
def test_module_quantization_info():

0 commit comments

Comments
 (0)