code: def _quantize_per_tensor():
      def _impl(inputs, _):
          dim = len(infer_shape(inputs[0]))
          if dim > 1:
              axis = 1
          else:
              axis = 0
  
          return relay.qnn.op.quantize(
              inputs[0],
              _expr.const(inputs[1]),
              _expr.const(inputs[2]),
              out_dtype="uint8",
              axis=axis,
          )
  
      return _impl
  
imports: import numpy
  import tvm
  from tvm import relay
  from tvm.relay import expr
  from tvm.relay import op
  from tvm.relay.frontend.common import infer_shape
  from .common import logger
  from .pytorch_utils import is_version_greater_than
label_desc: Use image node_id 19 for calling a global function with example usage: _quantize_per_tensor() and returns: _impl, relay