TrainingExtensions/tensorflow/src/python/aimet_tensorflow/quantsim_config/quantsim_config.py
def _set_config_for_param(self, param_quantize_op: tf.Operation, param_config: ConfigType):
        """
        Set configurations for a specific param quantize op
        :param param_quantize_op: Quantize op to set configurations for
        :param param_config: Configuration for the quantize op
        """
        vars_with_value = {}
        if ConfigDictKeys.IS_QUANTIZED in param_config:
            if param_config[ConfigDictKeys.IS_QUANTIZED]:
                vars_with_value[param_quantize_op.name + '_op_mode'] = \
                    int(pymo.TensorQuantizerOpMode.oneShotQuantizeDequantize)
            else:
                vars_with_value[param_quantize_op.name + '_op_mode'] = \
                    int(pymo.TensorQuantizerOpMode.passThrough)
        if ConfigDictKeys.IS_SYMMETRIC in param_config:
            vars_with_value[param_quantize_op.name + '_use_symmetric_encoding'] = \
                param_config[ConfigDictKeys.IS_SYMMETRIC]
        update_variables_with_values(self._sess, vars_with_value)

        Set configurations for a specific param quantize op
        :param param_quantize_op: Quantize op to set configurations for
        :param param_config: Configuration for the quantize op
        
Set configurations for a specific param quantize op
Set configurations for a specific param quantize op
def _set_config_for_param(self, param_quantize_op: tf.Operation, param_config: ConfigType):
        vars_with_value = {}
        if ConfigDictKeys.IS_QUANTIZED in param_config:
            if param_config[ConfigDictKeys.IS_QUANTIZED]:
                vars_with_value[param_quantize_op.name + '_op_mode'] = \
                    int(pymo.TensorQuantizerOpMode.oneShotQuantizeDequantize)
            else:
                vars_with_value[param_quantize_op.name + '_op_mode'] = \
                    int(pymo.TensorQuantizerOpMode.passThrough)
        if ConfigDictKeys.IS_SYMMETRIC in param_config:
            vars_with_value[param_quantize_op.name + '_use_symmetric_encoding'] = \
                param_config[ConfigDictKeys.IS_SYMMETRIC]
        update_variables_with_values(self._sess, vars_with_value)
def _set_config_for_param ( self , param_quantize_op : tf . Operation , param_config : ConfigType ) : vars_with_value = { } if ConfigDictKeys . IS_QUANTIZED in param_config : if param_config [ ConfigDictKeys . IS_QUANTIZED ] : vars_with_value [ param_quantize_op . name + '_op_mode' ] = int ( pymo . TensorQuantizerOpMode . oneShotQuantizeDequantize ) else : vars_with_value [ param_quantize_op . name + '_op_mode' ] = int ( pymo . TensorQuantizerOpMode . passThrough ) if ConfigDictKeys . IS_SYMMETRIC in param_config : vars_with_value [ param_quantize_op . name + '_use_symmetric_encoding' ] = param_config [ ConfigDictKeys . IS_SYMMETRIC ] update_variables_with_values ( self . _sess , vars_with_value )
Set configurations for a specific param quantize op
Set configurations for a specific param quantize op
"""
        Set configurations for a specific param quantize op
        :param param_quantize_op: Quantize op to set configurations for
        :param param_config: Configuration for the quantize op
        """
self
param_quantize_op
tf.Operation
Quantize op to set configurations for
Quantize op to set configurations for
param_config
ConfigType
Configuration for the quantize op
Configuration for the quantize op