Rate this Page

torch.optim.functional.adagrad#

torch.optim.functional.adagrad(params, grads, state_sums, state_steps, fused=None, grad_scale=None, found_inf=None, has_sparse_grad=False, foreach=None, differentiable=False, has_complex=False, *, lr, weight_decay, lr_decay, eps, maximize)[source]#

Functional API that performs Adagrad algorithm computation.

This function updates the provided parameters and optimizer state in place. The caller must initialize and retain optimizer state. Unless intentionally constructing a differentiable update with a supported differentiable=True argument, call this function under torch.no_grad. See Functional optimizer API for the common functional optimizer contract and examples, and Adagrad for algorithm details.