Adaptive moment estimation (Adam) is an efficient optimisation algorithm for deep learning. It builds on stochastic gradient descent by using both momentum and RMS prop.

In code

In PyTorch, we access Adam with the torch.optim.Adam() function.