AssertionError for Dropout Regularization Assignment

{moderator edit - solution code removed}

I am am having an error when checking the Dropout portion of the Regularization assignment. I have checked my code and i don’t seem to see anything wrong with it. The first portion of the test which returns A3 computed fine, but the second portion came with an AssertionError.

I have restarted the Kernel and even reverted to the original checkpoint, and yet the error won’t go away.

Please find attached the portion of the code and the error return.

Your answers are wrong because your code is incorrect. You’ve made what is probably the most common error here: you are using the random Gaussian distribution to compute the “drop” masks, but that’s not what they asked you to do. Please have a more careful look at the instructions and the comments in the template code there.

1 Like

Thank you very much Paul. I didn’t pay attention to the type of np.random specified.