Concise Linear Regression

http://d2l.ai/chapter_linear-networks/linear-regression-concise.html

By simply replace loss = tf.keras.losses.Huber() or with your choice of delta.
Note here is Huber Loss behaves better than MSE and MAE

Hi,
Is the Huber loss function supposed to perform better than Mean Squared Error as my notebooks are showing different results

As you can see from the screens, MSE actually performed better than Huber.

1 Like

Great try @gopalakrishna-r! It really depends on the data you are trying to fit. In general, huber loss is less sensitive to outliers in data than MSE.