C1_W3_Logistic_Regression non-graded cell error

On running the code,
TypeError: unsupported format string passed to numpy.ndarray.__format__
the above error pops up in the 13th cell and the cell after it. Cannot complete the assignment before it and am not allowed to make changes in this cell either. I would be grateful if someone could help me with how to proceed with this one.

It means your code is not correct. The non-graded cell only calls your code to check it. Can you please share the full error?



Hi, thank you for replying. Attaching the images with the complete error.
I tried to write the code my way and changed it to write it exactly how the hints suggest and I still get the same error.

It means the error is in your compute_cost function code. Please Check the hint and more hints given to you.

1 Like

The cost returned by the function compute_cost must be a scalar value.

1 Like

There was an error in my code, fixed it and the problem was solved. I got my certificate, thank you!

Congratulations on your achievement, @Sanhita!

1 Like

thank you so much, @rmwkwok !