I’ve been stuck on this for a while. I’ve tried np.dot and np.multiply:
{moderator edit: code removed}
As far as I know, both shapes being 1, 2000 is correct, logloss has a shape of 1, 2000 and that seems to be correct, I am not sure order matters in np.multiply, I average out the logloss by m, and I retain the negative sign.
Note that the first ‘minus’ is outside the first np.multiply().
Also, the cost value is going to depend on the values of Y and A2. Be sure that every time you modify the code in any cell, that you go back and re-run any cells that modify Y or A2.