class_docstr: Stateful Gated Recurrent Unit function (GRU).
  
  Stateful GRU function has six parameters :math:`W_r`, :math:`W_z`,
  :math:`W`, :math:`U_r`, :math:`U_z`, and :math:`U`.
  The three parameters :math:`W_r`, :math:`W_z`, and :math:`W` are
  :math:`n \times m` matrices, and the others :math:`U_r`, :math:`U_z`,
  and :math:`U` are :math:`n \times n` matrices, where :math:`m` is the
  length of input vectors and :math:`n` is the length of hidden vectors.
  
  Given input vector :math:`x`, Stateful GRU returns the next
  hidden vector :math:`h'` defined as
  
  .. math::
  
     r &=& \sigma(W_r x + U_r h), \\
     z &=& \sigma(W_z x + U_z h), \\
     \bar{h} &=& \tanh(W x + U (r \odot h)), \\
     h' &=& (1 - z) \odot h + z \odot \bar{h},
  
  where :math:`h` is current hidden vector.
  
  As the name indicates, :class:`~chainer.links.StatefulGRU` is *stateful*,
  meaning that it also holds the next hidden vector `h'` as a state.
  For a *stateless* GRU, use :class:`~chainer.links.StatelessGRU`.
  
  Args:
      in_size(int): Dimension of input vector :math:`x`.
      out_size(int): Dimension of hidden vector :math:`h`.
      init: Initializer for GRU's input units (:math:`W`).
          It is a callable that takes :ref:`ndarray` and edits its value.
          If it is ``None``, the default initializer is used.
      inner_init: Initializer for the GRU's inner
          recurrent units (:math:`U`).
          It is a callable that takes :ref:`ndarray` and edits its value.
          If it is ``None``, the default initializer is used.
      bias_init: Bias initializer.
          It is a callable that takes :ref:`ndarray` and edits its value.
          If ``None``, the bias is set to zero.
  
  Attributes:
      h(~chainer.Variable): Hidden vector that indicates the state of
          :class:`~chainer.links.StatefulGRU`.
  
  .. seealso::
      * :class:`~chainer.links.StatelessGRU`
      * :class:`~chainer.links.GRU`: an alias of
        :class:`~chainer.links.StatefulGRU`
  
  .. admonition:: Example
  
      There are several ways to make a ``StatefulGRU`` link.
      Let ``x`` be a two-dimensional input array:
  
      >>> in_size = 10
      >>> out_size = 20
      >>> x = np.zeros((1, in_size), dtype=np.float32)
  
      1. Give only ``in_size`` and ``out_size`` arguments:
  
          >>> l = L.StatefulGRU(in_size, out_size)
          >>> h_new = l(x)
          >>> h_new.shape
          (1, 20)
  
      2. Give all optional arguments:
  
          >>> init = np.zeros((out_size, in_size), dtype=np.float32)
          >>> inner_init = np.zeros((out_size, out_size), dtype=np.float32)
          >>> bias = np.zeros((1, out_size), dtype=np.float32)
          >>> l = L.StatefulGRU(in_size, out_size, init=init,
          ...     inner_init=inner_init, bias_init=bias)
          >>> h_new = l(x)
          >>> h_new.shape
          (1, 20)
code: def set_state(self, h):
      assert isinstance(h, variable.Variable)
      h.to_device(self.device)
      self.h = h
  
imports: from chainer.functions.activation import sigmoid
  from chainer.functions.activation import tanh
  from chainer.functions.math import linear_interpolate
  from chainer import link
  from chainer.links.connection import linear
  from chainer import variable
label_desc: Use image node_id 3 for calling the StatefulGRU obj's underlying member method code with example usage: obj.set_state(h) without return types