class_docstr: Describes a numpy array or scalar shape and dtype.
  
  An `ArraySpec` allows an API to describe the arrays that it accepts or
  returns, before that array exists.
  The equivalent version describing a `tf.Tensor` is `TensorSpec`.
docstr: Initializes a new `ArraySpec`.
  
  Args:
    shape: An iterable specifying the array shape.
    dtype: numpy dtype or string specifying the array dtype.
    name: Optional string containing a semantic name for the corresponding
      array. Defaults to `None`.
  
  Raises:
    TypeError: If the shape is not an iterable or if the `dtype` is an invalid
      numpy dtype.
docstr_tok: ["Initializes","a","new","`","ArraySpec","`",".","Args",":","shape",":","An","iterable","specifying","the","array","shape",".","dtype",":","numpy","dtype","or","string","specifying","the","array","dtype",".","name",":","Optional","string","containing","a","semantic","name","for","the","corresponding","array",".","Defaults","to","`","None","`",".","Raises",":","TypeError",":","If","the","shape","is","not","an","iterable","or","if","the","`","dtype","`","is","an","invalid","numpy","dtype","."]
code: def __init__(self, shape, dtype, name=None):
      """Initializes a new `ArraySpec`.
  
      Args:
        shape: An iterable specifying the array shape.
        dtype: numpy dtype or string specifying the array dtype.
        name: Optional string containing a semantic name for the corresponding
          array. Defaults to `None`.
  
      Raises:
        TypeError: If the shape is not an iterable or if the `dtype` is an invalid
          numpy dtype.
      """
      self._shape = tuple(shape)
      self._dtype = np.dtype(dtype)
      self._name = name
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import numbers
  import gin
  import numpy
  import tensorflow
label_desc: Use image node_id 1 to create a new ArraySpec object from inherited base classes: object with example: obj = ArraySpec(shape, dtype, name)