Where is __str__ and __repr__ methods in torch.optim.Optimizer

Hello

When printing an optimizer instance, we get a list of parameter groups, which is normal, however I can’t find the __str__ and __repr__ methods in Optimizer class or in its children. Do you you know where is the script responsible for this print.

This __repr__ method should be used.

1 Like