nncf/torch/quantization/layers.py
def from_state(cls, state: Dict[str, Any]) -> 'PTQuantizationPoint':
        """
        Creates the object from its state.

        :param state: Output of `get_state()` method.
        """
        kwargs = {
            cls._state_names.NUM_BITS: state['num_bits'],
            cls._state_names.MODE: state['mode'],
            cls._state_names.SIGNED_TO_FORCE: state['signedness_to_force'],
            cls._state_names.NARROW_RANGE: state['narrow_range'],
            cls._state_names.HALF_RANGE: state['half_range'],
            cls._state_names.SCALE_SHAPE: state['scale_shape'],
            cls._state_names.LOGARITHM_SCALE: state['logarithm_scale'],
            cls._state_names.IS_QUANTIZED_ON_EXPORT: state['is_quantized_on_export'],
            cls._state_names.COMPRESSION_LR_MULTIPLIER: state['compression_lr_multiplier']
        }
        return cls(**kwargs)

        Creates the object from its state.

        :param state: Output of `get_state()` method.
        
Creates the object from its state.
Creates the object from its state .
def from_state(cls, state: Dict[str, Any]) -> 'PTQuantizationPoint':
        kwargs = {
            cls._state_names.NUM_BITS: state['num_bits'],
            cls._state_names.MODE: state['mode'],
            cls._state_names.SIGNED_TO_FORCE: state['signedness_to_force'],
            cls._state_names.NARROW_RANGE: state['narrow_range'],
            cls._state_names.HALF_RANGE: state['half_range'],
            cls._state_names.SCALE_SHAPE: state['scale_shape'],
            cls._state_names.LOGARITHM_SCALE: state['logarithm_scale'],
            cls._state_names.IS_QUANTIZED_ON_EXPORT: state['is_quantized_on_export'],
            cls._state_names.COMPRESSION_LR_MULTIPLIER: state['compression_lr_multiplier']
        }
        return cls(**kwargs)
def from_state ( cls , state : Dict [ str , Any ] ) -> 'PTQuantizationPoint' : kwargs = { cls . _state_names . NUM_BITS : state [ 'num_bits' ] , cls . _state_names . MODE : state [ 'mode' ] , cls . _state_names . SIGNED_TO_FORCE : state [ 'signedness_to_force' ] , cls . _state_names . NARROW_RANGE : state [ 'narrow_range' ] , cls . _state_names . HALF_RANGE : state [ 'half_range' ] , cls . _state_names . SCALE_SHAPE : state [ 'scale_shape' ] , cls . _state_names . LOGARITHM_SCALE : state [ 'logarithm_scale' ] , cls . _state_names . IS_QUANTIZED_ON_EXPORT : state [ 'is_quantized_on_export' ] , cls . _state_names . COMPRESSION_LR_MULTIPLIER : state [ 'compression_lr_multiplier' ] } return cls ( ** kwargs )
Creates the object from its state.
Creates the object from its state .
"""
        Creates the object from its state.

        :param state: Output of `get_state()` method.
        """
cls
state
Dict[str, Any]
Output of `get_state()` method.
Output of ` get_state () ` method .