class_docstr: Quantize tensor based on range the last batch of values.
class_docstr_tok: ["Quantize","tensor","based","on","range","the","last","batch","of","values","."]
docstr: Construct a LastValueQuantizer.
  
  This is an experimental API not subject to backward compatibility.
  
  Args:
    num_bits: Number of bits for quantization
    per_axis: Whether to apply per_axis quantization. The last dimension is
      used as the axis.
    symmetric: If true, use symmetric quantization limits instead of training
      the minimum and maximum of each quantization range separately.
    narrow_range: In case of 8 bits, narrow_range nudges the quantized range
      to be [-127, 127] instead of [-128, 127]. This ensures symmetric
      range has 0 as the centre.
code: def __init__(self, num_bits, per_axis, symmetric, narrow_range):
      """Construct a LastValueQuantizer.
  
      This is an experimental API not subject to backward compatibility.
  
      Args:
        num_bits: Number of bits for quantization
        per_axis: Whether to apply per_axis quantization. The last dimension is
          used as the axis.
        symmetric: If true, use symmetric quantization limits instead of training
          the minimum and maximum of each quantization range separately.
        narrow_range: In case of 8 bits, narrow_range nudges the quantized range
          to be [-127, 127] instead of [-128, 127]. This ensures symmetric
          range has 0 as the centre.
      """
      self.num_bits = num_bits
      self.per_axis = per_axis
      self.symmetric = symmetric
      self.narrow_range = narrow_range
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import abc
  import six
  import tensorflow
  from tensorflow_model_optimization.python.core.quantization.keras import quant_ops
label_desc: Use image node_id 1 to create a new LastValueQuantizer object from inherited base classes: _QuantizeHelper, Quantizer with example: obj = LastValueQuantizer(num_bits, per_axis, symmetric, narrow_range)