Course 1, week 4; Programming Assignment Part 2:Application

Hello everyone!
After running the cell in the uploaded picture there was an exception thrown “Value Error: too many values to unpack”. Is there a possibility that there is something wrong with the given code or is it my fault?

I did not encounter that error. It looks like you must have changed the “return” statement in the function two_layer_model to return more than 2 items. That was part of the template code that they gave you and should not need to be changed. Here’s what it looks like in a clean copy of the notebook:

return parameters, costs

Please compare that to the code in your notebook and see if there is any difference.

1 Like