Skip to content

Commit 9a13736

Browse files
committed
remove score printing
1 parent 20fd87d commit 9a13736

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

quant/quantizer.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ def forward(self, x: torch.Tensor):
257257
out = x_dq * 1 / i
258258

259259
score = lp_loss(x, out, p=2, reduction="all")
260-
print(f"scale: {i}, score: {score}")
260+
# print(f"scale: {i}, score: {score}")
261261

262262
if score < best_score:
263263
best_score = score
@@ -271,6 +271,7 @@ def forward(self, x: torch.Tensor):
271271
print(x_q.unique().numel(), x_q.unique())
272272
print(x_dq.unique().numel(), x_dq.unique())
273273
print(x.unique().numel(), x.unique())
274+
print()
274275
if int_max == 384:
275276
assert x.unique().numel() <= 17
276277
elif int_max == 256:

test_quant.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def get_args_parser():
5454
)
5555
parser.add_argument(
5656
"--log_quant_scheme",
57-
default="Sqrt2_17",
57+
default="BitLog2_Half_17",
5858
choices=[
5959
"Sqrt2_16",
6060
"Sqrt2_17", # Original RepQ-ViT

0 commit comments

Comments
 (0)