Torch.optim is a module that implements various optimization algorithm used for building neural networks. Most of the commonly used syntax is already supported.
Below is the code of Adam optimizer
Optimizer = torch.optim.Adam(mode1, parameters( ), lr=learning rate