Hi I can not find my error ,I passed the test in the propagate function but in optmize I get this error.
Why I get the wrong cost if my code passed the test in the propagate function?
Hi I can not find my error ,I passed the test in the propagate function but in optmize I get this error.
Why I get the wrong cost if my code passed the test in the propagate function?
Notice that your first cost value (at 0 iterations) is correct, but the second one increases instead of decreasing. This suggests that there is something wrong with your “update parameters” logic, which is part of optimize
. E.g. are you sure you are subtracting instead of adding the gradient times the learning rate? In other words, this is not a problem with propagate
: the problem is that you are passing propagate
incorrect values because of a bug in your optimize
logic.
Thanks for the answer. I will check that and I will update here when I solve it.Thanks for the support.
I have solved the issue with the code.Thanks for your answer
It’s great news that you were able to find the solution. Nice work!