Hi there! I’m stuck with the third programming assignment “Gradient Checking”, precisely in the gradient_check_n, when I run this code it said that "Wrong value. It is not one of the expected values when I had done well the cells before with the same logic.
If somebody can help with a tip or some advice if it’s possible in the Coursera terms and conditions.
Interesting. Your difference value is close to 1. Check your implementation of the difference. Are you sure you didn’t add instead of subtracting in the numerator of the fraction there? Also check your “order of operations” in the formula that has 2\epsilon in the denominator. Try the following and watch what happens:
m = 5.
x = 1. / 2. * m
y = 1. / (2. * m)
If you’re expecting x and y to have the same value, you’re in for a surprise.
1 Like