def __init__(self, wrt, fprime, step_rate=.0002,
                 decay=1-1e-8,
                 decay_mom1=0.1,
                 decay_mom2=0.001,
                 momentum=0,
                 offset=1e-8, args=None):
        if not 0 < decay < 1:
            raise ValueError('decay has to lie in (0, 1)')
        if not 0 < decay_mom1 <= 1:
            raise ValueError('decay_mom1 has to lie in (0, 1]')
        if not 0 < decay_mom2 <= 1:
            raise ValueError('decay_mom2 has to lie in (0, 1]')
        if not (1 - decay_mom1 * 2) / (1 - decay_mom2) ** 0.5 < 1:
            warnings.warn("constraint from convergence analysis for adam not "
                          "satisfied; check original paper to see if you "
                          "really want to do this.")

        super(Adam, self).__init__(wrt, args=args)

        self.fprime = fprime
        self.step_rate = step_rate
        self.decay = decay
        self.decay_mom1 = decay_mom1
        self.decay_mom2 = decay_mom2
        self.offset = offset
        self.momentum = momentum
        self.est_mom1 = 0
        self.est_mom2 = 0
        self.est_mom1_b = 0
        self.est_mom2_b = 0
        self.step = 0
Create an Adam object.
dataset/ETHPy150Open BRML/climin/climin/adam.py/Adam.__init__