Course 2, Week-1, Assignment-3, Wrong Value in Exercise 4 Test

So i’m getting this Assertion Error and due to this i got 60/100
The Grader Output also pointed to this Error
I’ve checked the code thoroughly and couldn’t find any mistake

Interesting. From the test, it looks like you are doing the “n dimensional” gradient checking section, but the answer you get is exactly what I show as the answer for the 1D case earlier in the notebook:

Your backward propagation works perfectly fine! difference = 2.919335883291695e-10
 All tests passed.

So something very odd is going on. Are you sure you didn’t copy any cells around?

Thank You for your analysis Sir
After going through the code 3-4 more times i found that I had the wrong spelling of variable ‘difference’, i had a single f in place of double f
And cause of this the function didn’t return anything and the previous value of difference was used in this cell which gave the Error

Wow! That sounds like a hard bug to find. Glad you were able to solve it. :nerd_face:

1 Like