code: def quantize_per_tensor(
      g: jit_utils.GraphContext, input, scale, zero_point, dtype
  ):
      dtype = symbolic_helper._get_const(dtype, "i", "dtype")
      # TODO(justinchuby): Extract all the cast ops into a helper function.
      zero_point = g.op(
          "Cast",
          zero_point,
          to_i=_type_utils.JitScalarType(dtype).onnx_type(),
      )
      scale = g.op(
          "Cast", scale, to_i=_C_onnx.TensorProtoDataType.FLOAT
      )
      return symbolic_helper.quantize_helper(
          g, input, scale, zero_point
      )
  
imports: from __future__ import annotations
  import functools
  import sys
  import warnings
  from typing import List, Optional, Sequence, Tuple, Union
  import torch
  import torch._C._onnx
  import torch.onnx
  from torch import _C
  from torch.onnx import _constants, _type_utils, errors, symbolic_helper, symbolic_opset9
  from torch.onnx._globals import GLOBALS
  from torch.onnx._internal import _beartype, jit_utils, registration
label_desc: Use image node_id 23 for calling a global function with example usage: quantize_per_tensor(g, input, scale, zero_point, dtype) and returns: symbolic_helper