Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
andrey-churkin committed Jan 31, 2025
1 parent 6024dce commit 1c51fd8
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion nncf/tensorflow/utils/state.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import tensorflow as tf

from nncf.common.compression import BaseCompressionAlgorithmController
from nncf.tensorflow.quantization.algorithm import TFQuantizationSetup

# TODO(achurkin): remove pylint ignore after 120296 ticked is fixed

Expand Down Expand Up @@ -105,7 +106,12 @@ def serialize(self) -> str:
:return: A serialized config.
"""
return json.dumps(self.config)
data = {
"quantization": {
"quantizer_setup": TFQuantizationSetup.from_state(self.config["quantizer_setup"]).get_state(),
}
}
return json.dumps(data)

def deserialize(self, string_value: str) -> None:
"""
Expand Down

0 comments on commit 1c51fd8

Please sign in to comment.