Getting infinite loss with my simple Linear Regression model

hello below is my first linear regression model with PyTorch.
if I increase num_data to 1000, the loss become infinite…
I don’t know why
any help would be appreciated so much!!

My Colab Link :
https://colab.research.google.com/drive/1oi9jZyb5TucwUERMSaVw1ZEVOt9uxrT4)

Solved it by changing learning_rate. but I don’t know what’s going on :frowning:

Brother, I don’t know if it’s any help to you, but you hadn’t used an activation function. You must use one, preferrably sigmoid (its simpler) or RELU (a little complexity for the system but still okay)

Hope it helps some new students out there