docstr: ivy.Array instance method variant of ivy.adam_update. This method
  simply wraps the function, and so the docstring for ivy.adam_update
  also applies to this method with minimal changes.
  
  Parameters
  ----------
  self
      Weights of the function to be updated.
  dcdw
      Derivates of the cost c with respect to the weights ws, [dc/dw for w in ws].
  lr
      Learning rate(s), the rate(s) at which the weights should be updated
      relative to the gradient.
  mw_tm1
      running average of the gradients, from the previous time-step.
  vw_tm1
      running average of second moments of the gradients, from the previous
      time-step.
  step
      training step.
  beta1
      gradient forgetting factor (Default value = 0.9).
  beta2
      second moment of gradient forgetting factor (Default value = 0.999).
  epsilon
      divisor during adam update, preventing division by zero
      (Default value = 1e-7).
  stop_gradients
      Whether to stop the gradients of the variables after each gradient step.
      Default is ``True``.
  out
      optional output array, for writing the result to. It must have a shape that
      the inputs broadcast to.
  
  Returns
  -------
  ret
      The new function weights ws_new, and also new mw and vw, following the adam
      updates.
  
  Examples
  --------
  With :class:`ivy.Array` inputs:
  
  >>> w = ivy.array([1., 2, 3.])
  >>> dcdw = ivy.array([0.2,0.1,0.3])
  >>> lr = ivy.array(0.1)
  >>> vw_tm1 = ivy.zeros(1)
  >>> mw_tm1 = ivy.zeros(3)
  >>> step = 2
  >>> updated_weights = w.adam_update(dcdw, lr, mw_tm1, vw_tm1, step)
  >>> print(updated_weights)
  (ivy.array([0.92558753, 1.92558873, 2.92558718]),
  ivy.array([0.02, 0.01, 0.03]),
  ivy.array([4.00000063e-05, 1.00000016e-05, 9.00000086e-05]))
code: def adam_update(
      self: ivy.Array,
      dcdw: Union[ivy.Array, ivy.NativeArray],
      lr: Union[float, ivy.Array, ivy.NativeArray],
      mw_tm1: Union[ivy.Array, ivy.NativeArray],
      vw_tm1: Union[ivy.Array, ivy.NativeArray],
      step: int,
      /,
      *,
      beta1: float = 0.9,
      beta2: float = 0.999,
      epsilon: float = 1e-7,
      stop_gradients: bool = True,
      out: Optional[ivy.Array] = None,
  ) -> ivy.Array:
      """ivy.Array instance method variant of ivy.adam_update. This method
      simply wraps the function, and so the docstring for ivy.adam_update
      also applies to this method with minimal changes.
  
      Parameters
      ----------
      self
          Weights of the function to be updated.
      dcdw
          Derivates of the cost c with respect to the weights ws, [dc/dw for w in ws].
      lr
          Learning rate(s), the rate(s) at which the weights should be updated
          relative to the gradient.
      mw_tm1
          running average of the gradients, from the previous time-step.
      vw_tm1
          running average of second moments of the gradients, from the previous
          time-step.
      step
          training step.
      beta1
          gradient forgetting factor (Default value = 0.9).
      beta2
          second moment of gradient forgetting factor (Default value = 0.999).
      epsilon
          divisor during adam update, preventing division by zero
          (Default value = 1e-7).
      stop_gradients
          Whether to stop the gradients of the variables after each gradient step.
          Default is ``True``.
      out
          optional output array, for writing the result to. It must have a shape that
          the inputs broadcast to.
  
      Returns
      -------
      ret
          The new function weights ws_new, and also new mw and vw, following the adam
          updates.
  
      Examples
      --------
      With :class:`ivy.Array` inputs:
  
      >>> w = ivy.array([1., 2, 3.])
      >>> dcdw = ivy.array([0.2,0.1,0.3])
      >>> lr = ivy.array(0.1)
      >>> vw_tm1 = ivy.zeros(1)
      >>> mw_tm1 = ivy.zeros(3)
      >>> step = 2
      >>> updated_weights = w.adam_update(dcdw, lr, mw_tm1, vw_tm1, step)
      >>> print(updated_weights)
      (ivy.array([0.92558753, 1.92558873, 2.92558718]),
      ivy.array([0.02, 0.01, 0.03]),
      ivy.array([4.00000063e-05, 1.00000016e-05, 9.00000086e-05]))
      """
      return ivy.adam_update(
          self,
          dcdw,
          lr,
          mw_tm1,
          vw_tm1,
          step,
          beta1=beta1,
          beta2=beta2,
          epsilon=epsilon,
          stop_gradients=stop_gradients,
          out=out,
      )
  
file_path: ivy/ivy/data_classes/array/gradients.py
imports: import abc
  from typing import Union, Optional
  import ivy
label_desc: Use image node_id 6 for calling the _ArrayWithGradients obj's underlying member method code with example usage: obj.adam_update() and returns: ivy