Skip to content

Commit

Permalink
Constant folding is enabled for OpenVINOQuantizer
Browse files Browse the repository at this point in the history
  • Loading branch information
daniil-lyakhov committed Dec 5, 2024
1 parent bba9ee5 commit 3440d82
Show file tree
Hide file tree
Showing 5 changed files with 13,611 additions and 17,096 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
from nncf.experimental.common.quantization.algorithms.quantizer.base_quantizer import NNCFQuantizer
from nncf.experimental.torch.fx.nncf_graph_builder import GraphConverter
from nncf.experimental.torch.fx.node_utils import get_graph_node_by_name
from nncf.experimental.torch.fx.transformations import fold_constant_except_qdq
from nncf.parameters import ModelType
from nncf.parameters import QuantizationMode
from nncf.parameters import TargetDevice
Expand Down Expand Up @@ -164,3 +165,7 @@ def _convert_nncf_qspec_to_inductor_qspec(self, qspec: NNCFQuantizerConfig, is_w

def validate(self, model: torch.fx.GraphModule) -> None:
pass

def transform_for_annotation(self, model: torch.fx.GraphModule) -> torch.fx.GraphModule:
fold_constant_except_qdq(model)
return model
Loading

0 comments on commit 3440d82

Please sign in to comment.