What does err_i in code refers to?

In course 1 week 3 optional lab “Gradient descent for logistic regression”:

def compute_gradient_logistic(X, y, w, b): 

    for i in range(m):
        *err_i*  = f_wb_i  - y[i]                       # What does it refer to?!



We name it as err (or error) because it is the difference between prediction and label.


PS: @Fatomk11295, I modified your post to show the name of the lab and only a sufficient part of the function to identify the variable you were asking about.

1 Like

Thanks !