class_docstr: The iOS16 version.
  This section documents only the differences between this version and the
  iOS 15 :py:class:`~.iOS15.scatter_gather.gather`.
  
  This version supports ``batch_dims``, similar to `tf.gather <https://www.tensorflow.org/api_docs/python/tf/gather>`_.
  Input parameter ``indices`` now supports ``int16`` and ``uint16``.
  
  Parameters
  ----------
  x: tensor<\*D, T> (Required)
  indices: tensor<\*N, I> (Required)
      * Indices values may be negative. More precisely, ``-D[axis]<= v < D[axis]`` for ``v`` in ``indices``.
  axis: const i32 (Optional. Default=``0``)
      * Negative axis is supported.
  batch_dims: const i32 (Optional. Default=``0``)
      * The number of batch dimensions.
  
  Returns
  -------
  tensor<\*K, T>
      * Where ``K = D[:axis] + N[batch_dims:] + D[axis+1:]``.
  
  Attributes
  ----------
  T: fp16, fp32, i32
  I: uint16, int16, int32
  
  References
  ----------
  See `tf.gather <https://www.tensorflow.org/api_docs/python/tf/gather>`_.
class_docstr_tok: ["The","iOS16","version",".","This","section","documents","only","the","differences","between","this","version","and","the","iOS","15",":","py",":","class",":","`","~.iOS15.scatter_gather.gather","`",".","This","version","supports","``","batch_dims","``",",","similar","to","`","tf.gather","<","https",":","\/\/www.tensorflow.org\/api_docs\/python\/tf\/gather",">","`","_",".","Input","parameter","``","indices","``","now","supports","``","int16","``","and","``","uint16","``",".","Parameters","--","--","--","--","--","x",":","tensor","<","\\","*","D",",","T",">","(","Required",")","indices",":","tensor","<","\\","*","N",",","I",">","(","Required",")","*","Indices","values","may","be","negative",".","More","precisely",",","``","-D","[","axis","]","<","=","v","<","D","[","axis","]","``","for","``","v","``","in","``","indices","``",".","axis",":","const","i32","(","Optional",".","Default=","``","0","``",")","*","Negative","axis","is","supported",".","batch_dims",":","const","i32","(","Optional",".","Default=","``","0","``",")","*","The","number","of","batch","dimensions",".","Returns","--","--","--","-","tensor","<","\\","*","K",",","T",">","*","Where","``","K","=","D","[",":","axis","]","+","N","[","batch_dims",":","]","+","D","[","axis+1",":","]","``",".","Attributes","--","--","--","--","--","T",":","fp16",",","fp32",",","i32","I",":","uint16",",","int16",",","int32","References","--","--","--","--","--","See","`","tf.gather","<","https",":","\/\/www.tensorflow.org\/api_docs\/python\/tf\/gather",">","`","_","."]
code: def default_inputs(self):
      return DefaultInputs(
          axis=0,
          batch_dims=0,
      )
  
file_path: coremltools/coremltools/converters/mil/mil/ops/defs/iOS16/scatter_gather.py
imports: from coremltools.converters.mil.mil import Operation, types
  from coremltools.converters.mil.mil.input_type import DefaultInputs, InputSpec, TensorInputType
  from coremltools.converters.mil.mil.operation import SYMBOL, VALUE, precondition
  from coremltools.converters.mil.mil.ops.defs._op_reqs import register_op
  from coremltools.converters.mil.mil.ops.defs._utils import compute_gather
  from coremltools.converters.mil.mil.ops.defs.iOS15.scatter_gather import gather_along_axis
  from coremltools.converters.mil.mil.ops.defs.iOS16 import _IOS16_TARGET
label_desc: Use image node_id 1 for calling the gather obj's underlying member method code with example usage: obj.default_inputs() and returns: DefaultInputs