Week 3 prediction not working

Hello,

I got all tests working in week3, except when running prediction method (the last test), it will not classify precisely. The result from the forward progagation are a vector with all values close to 0.5.

Am I missing a step, or is it something wrong with my classifier? It is hard to know what to do, since all the other tests are passing, also training the neural network and the classification seems to be correct.

What do you mean “will not classify precisely”? Perhaps you could show us just the output of running that test cell in order to clarify what you mean by that. I also added the following print statement in my predict function to show the intermediate A2 value:

print(f"A2 = {A2}")

Here are my results from running the test cell with that print statement added:

A2 = [[0.5015406633580661  0.49899566460505673 0.5021378262730082 ]]
Predictions: [[1. 0. 1.]]
A2 = [[0.5015406633580661  0.49899566460505673 0.5021378262730082 ]]
A2 = [[0.5015406633580661  0.49899566460505673 0.5021378262730082 ]]
A2 = [[0.5015406633580661  0.49899566460505673 0.5021378262730082 ]]
 All tests passed.

What do you get?

Thank you @paulinpaloalto ! I see the tests got updated, that made me find my silly error. It was in the forwardpropagation.

Cheers!
Tom

That’s great! Thanks for confirming.