Skip to content

Commit 7cf58da

Browse files
committed
up
1 parent 2f400ca commit 7cf58da

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

backends/transforms/duplicate_dynamic_quant_chain.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,9 @@
1111

1212
from torch.fx.node import map_arg
1313
from torch.fx.passes.infra.pass_base import PassBase, PassResult
14+
from torchao.quantization.pt2e.quantizer import is_valid_annotation
1415

15-
from torchao.quantization.pt2e.utils import (
16-
_filter_sym_size_users,
17-
_is_valid_annotation, # @nocommit not found
18-
)
19-
16+
from torchao.quantization.pt2e.utils import _filter_sym_size_users
2017

2118
logger = logging.getLogger(__name__)
2219
logger.setLevel(logging.WARNING)
@@ -129,7 +126,7 @@ def _maybe_duplicate_dynamic_quantize_chain(
129126
dq_node_users = list(dq_node.users.copy())
130127
for user in dq_node_users:
131128
annotation = user.meta.get("quantization_annotation", None)
132-
if not _is_valid_annotation(annotation):
129+
if not is_valid_annotation(annotation):
133130
return
134131
with gm.graph.inserting_after(dq_node):
135132
new_node = gm.graph.node_copy(dq_node)

0 commit comments

Comments
 (0)