class_docstr: A compile-time operation that returns a constant output value upon dequantizing its constant inputs.
  
  This operation is used to represent constant 8-bit quantized data with affine/linear quantization.
  The quantized data is stored in the parameter ``quantized_data``.
  The other parameters -- ``scale``, ``zero_point``, and ``axis`` -- describe how
  unquantized values can be extracted from it, using the equation for affine/linear quantization:
  
  .. sourcecode:: python
  
      unquantized_data = scale * (quantized_data - zero_point)
  
  Although all of the parameters of this op are constants, this op is not constant folded
  to a single const op at the time of model serialization. The unquantized output will
  be decompressed later, based on the implementation detail (either at model load time or runtime).
  
  Parameters
  ----------
  quantized_data: const tensor<SrcT, [1..]> (Required)
  
  zero_point: const tensor<ZeroPointT, [0..1]> (Required)
         * ``zero_point`` can be either a scalar or a vector.
         * ``zero_point`` follows similar broadcasting rules and size constraints as ``scale``.
  
  scale: const tensor<DstT, [0..1]> (Required)
     * ``scale`` can be either a scalar or a vector.
     * If ``scale`` is a vector, for implementation it is broadcast to the following shape:
        * The rank of ``scale`` becomes the same as the rank of ``quantized_data``.
        * The constraint: ``size(scale-vector) == quantized_data.shape[axis]``.
        * For ``i == axis``, ``scale.shape[i] == quantized_data.shape[i]``.
        * For ``i != axis``, ``scale.shape == 1``.
          For example, assume ``quantized_data.shape = (2, 3, 4, 5)`` and ``axis = 1``.
          If ``scale`` is a vector, then ``scale.size`` needs to be equal to
          ``quantized_data.shape[axis] i.e = 3``, which would be broadcast to ``(1, 3, 1, 1)``.
  
  axis: const tensor<int32, []> (Required)
  
  Returns
  -------
  const tensor<DstT, [1..]>
  
  Attributes
  ----------
  SrcT: uint8, int8
  ZeroPointT: uint8, int8, fp32
  DstT: fp16, fp32
class_docstr_tok: ["A","compile-time","operation","that","returns","a","constant","output","value","upon","dequantizing","its","constant","inputs",".","This","operation","is","used","to","represent","constant","8-bit","quantized","data","with","affine\/linear","quantization",".","The","quantized","data","is","stored","in","the","parameter","``","quantized_data","``",".","The","other","parameters","--","``","scale","``",",","``","zero_point","``",",","and","``","axis","``","--","describe","how","unquantized","values","can","be","extracted","from","it",",","using","the","equation","for","affine\/linear","quantization",":","..","sourcecode",":",":","python","unquantized_data","=","scale","*","(","quantized_data","-","zero_point",")","Although","all","of","the","parameters","of","this","op","are","constants",",","this","op","is","not","constant","folded","to","a","single","const","op","at","the","time","of","model","serialization",".","The","unquantized","output","will","be","decompressed","later",",","based","on","the","implementation","detail","(","either","at","model","load","time","or","runtime",")",".","Parameters","--","--","--","--","--","quantized_data",":","const","tensor","<","SrcT",",","[","1","..","]",">","(","Required",")","zero_point",":","const","tensor","<","ZeroPointT",",","[","0","..","1","]",">","(","Required",")","*","``","zero_point","``","can","be","either","a","scalar","or","a","vector",".","*","``","zero_point","``","follows","similar","broadcasting","rules","and","size","constraints","as","``","scale","``",".","scale",":","const","tensor","<","DstT",",","[","0","..","1","]",">","(","Required",")","*","``","scale","``","can","be","either","a","scalar","or","a","vector",".","*","If","``","scale","``","is","a","vector",",","for","implementation","it","is","broadcast","to","the","following","shape",":","*","The","rank","of","``","scale","``","becomes","the","same","as","the","rank","of","``","quantized_data","``",".","*","The","constraint",":","``","size","(","scale-vector",")","==","quantized_data.shape","[","axis","]","``",".","*","For","``","i","==","axis","``",",","``","scale.shape","[","i","]","==","quantized_data.shape","[","i","]","``",".","*","For","``","i","!","=","axis","``",",","``","scale.shape","==","1","``",".","For","example",",","assume","``","quantized_data.shape","=","(","2",",","3",",","4",",","5",")","``","and","``","axis","=","1","``",".","If","``","scale","``","is","a","vector",",","then","``","scale.size","``","needs","to","be","equal","to","``","quantized_data.shape","[","axis","]","i.e","=","3","``",",","which","would","be","broadcast","to","``","(","1",",","3",",","1",",","1",")","``",".","axis",":","const","tensor","<","int32",",","[","]",">","(","Required",")","Returns","--","--","--","-","const","tensor","<","DstT",",","[","1","..","]",">","Attributes","--","--","--","--","--","SrcT",":","uint8",",","int8","ZeroPointT",":","uint8",",","int8",",","fp32","DstT",":","fp16",",","fp32"]
code: def materialized_val_inference(self):
      return self.decompress(
          self.quantized_data.val,
          self.zero_point.val,
          self.scale.val,
          self.axis.val,
      )
  
imports: import numpy
  from coremltools.converters.mil.mil import types
  from coremltools.converters.mil.mil.input_type import InputSpec, TensorInputType
  from coremltools.converters.mil.mil.operation import Operation
  from coremltools.converters.mil.mil.ops.defs._op_reqs import register_op
  from coremltools.converters.mil.mil.ops.defs._utils import restore_elements_from_packed_bits
  from coremltools.converters.mil.mil.ops.defs.iOS16 import _IOS16_TARGET
label_desc: Use image node_id 2 for calling the constexpr_affine_dequantize obj's underlying member method code with example usage: obj.materialized_val_inference() and returns: self