class_docstr: Animates a pcolormesh
  
  Parameters
  ----------
  X : 1D or 2D np.ndarray, optional
  Y : 1D or 2D np.ndarray, optional
  C : list of 2D np.ndarray or a 3D np.ndarray
  ax : matplotlib.axes.Axes, optional
      The matplotlib axes to attach the block to.
      Defaults to matplotlib.pyplot.gca()
  t_axis : int, optional
      The axis of the array that represents time. Defaults to 0.
      No effect if C is a list.
  
  Attributes
  ----------
  ax : matplotlib axis
      The matplotlib axes that the block is attached to.
  
  Notes
  -----
  All other keyword arguments get passed to ``axis.pcolormesh``
  see :meth:`matplotlib.axes.Axes.pcolormesh` for details.
code: def __init__(self, *args, ax=None, t_axis=0, **kwargs):
      if len(args) == 1:
          self.C = args[0]
          self._arg_len = 1
      elif len(args) == 3:
          self.X, self.Y, self.C = args
          self._arg_len = 3
          if len(self.X.shape) not in [1, 2]:
              raise TypeError("X must be a 1D or 2D arrays")
          if len(self.Y.shape) not in [1, 2]:
              raise TypeError("Y must be a 1D or 2D arrays")
      else:
          raise TypeError(
              "Illegal arguments to pcolormesh; see help(pcolormesh)"
          )
  
      super().__init__(ax, t_axis)
  
      self._is_list = isinstance(self.C, list)
      self.C = np.asanyarray(self.C)
  
      Slice = self._make_slice(0, 3)
  
      # replicate matplotlib logic for setting default shading value because
      # matplotlib resets the _shading member variable of the QuadMesh to "flat" after
      # interpolating X and Y to corner positions
      self.shading = kwargs.get(
          "shading", plt.rcParams.get("pcolor.shading", "flat")
      )
      Nx = self.X.shape[-1]
      Ny = self.Y.shape[0]
      if self.shading == "auto":
          if (Ny, Nx) == self.C[Slice].shape:
              self.shading = "nearest"
          else:
              self.shading = "flat"
      if self.shading == "flat" and (
          (Ny - 1, Nx - 1) == self.C[Slice].shape
      ):
          # Need to slice without the workaround in _update()
          self.shading = "flat_corner_grid"
  
      if self._arg_len == 1:
          self.quad = self.ax.pcolormesh(self.C[Slice], **kwargs)
      elif self._arg_len == 3:
          self.quad = self.ax.pcolormesh(
              self.X, self.Y, self.C[Slice], **kwargs
          )
  
file_path: animatplot/animatplot/blocks/image_like.py
imports: from .base import Block
  import matplotlib.pyplot
  import numpy
label_desc: Use image node_id 1 to create a new Pcolormesh object from inherited base classes: Block with example: obj = Pcolormesh()