Neural Networks

Solution: optimizer got an empty parameter list

Recently while building a custom Pytorch model i got a puzzling error “ValueError: optimizer got an empty parameter list” which got some hours of troublshooting, only to find that it just needs a small trick. Reproducing the error: It usually happens when you have a model with your own defined parameters, e.g. consider following example with only one parameter: While…

Read More