Wrong values for A2 in forward_propagation function

Here’s a post in Balaji’s list that shows the intermediate values for Z1 and A1 and Z2 and the Z2 differs from yours.

One thing to check is to make sure you got the activation function right for layer 1: it’s tanh, right? Not relu or sigmoid.