Programming Assignment: Single Perceptron Neural Networks for Linear Regression


Hi
I have completed the task and coded correctly as well it is giving me the same value as expected value but when I run the test it is giving me an " Assertion Error". I have tried everything but nothing helps. Please help me in this.

Regards

I had the same issue, you most likely have x and y switched. Took me a longer than I wish to admit to catch the error.

  W = np.random.randn(n_y, n_x) * 0.01
  b = np.zeros((n_y, 1))