Week 3 Perceptron Assignment Exercise 3 - Assert Error

Hello DL AI,

I am receiving an assert error on exercise 3 - on attachement. The output matches the expected output and I did not modify the assert


code ?

Please let me know how to resolve…

– Germán

1 Like

Hello @dlphsrle7

The assert is looking at the shape of W and b. It is expecting the shape of W to be equal to (n_y, n_x) and that of b to be equal to (n_y,1)

If the asserion is failing it means your shape of W and/or b is wrong.

You will need to correct it.

1 Like

Hello @shanup,

Thank you for you reply. I was able to resolve… syntax…

– German

1 Like

Hi, How did you solve this problem, can you guide me too??

1 Like

Hello Syed,

Yes… please look carefully at the instructions for the inputs / output - just below the def statement and make certain that it matches exactly the code segments you are writing… specifically in relation to the n_x, n_y…

– Germán

1 Like

@dlphsrle7 , could you please help me too and point to where I might have it wrong?

1 Like

Hello @frittmeyer,

Please look carefully at the instructions in red above the ## Start Code. and make certain that the shape of the matrices match your code…

– Germán

1 Like

Thank you, German. Will try it again.

1 Like