Help on Week 3 Lab Cost Function (Tensor flow introduction)

For the Cost Function I got this…

(Solution code removed, as posting it publicly is against the honour code of this community, regardless if it is correct or not)

and it seems to be consistent with what is being asked in that section but for some reason I am still getting and error.

Here is the check list of the most common mistakes. It looks like maybe item 1 is the most likely in your case.


@paulinpaloalto It worked thank you so much ! Do I need to transpose them because when doing backprop whenever the derivatives are being calculated they matrixes need to be transposed for the whole process to work properly ?

No, it’s because Prof Ng used a different order of the dimensions than the TF loss function expects. Here’s a thread which discusses that point.