ValueError Traceback (most recent call last)

in

1 # Note:

2 # Actual values are not checked here in the unit tests (due to random initialization).now3_unittest.test_nn_model(nn_model)

----> 3 w3_unittest.test_nn_model(nn_model)

~/work/w3_unittest.py in test_nn_model(target_nn_model)

357 for test_case in test_cases:

358

→ 359 result = target_nn_model(test_case[“input”][“X”], test_case[“input”][“Y”], test_case[“input”][“num_iterations”], False)

360

361 try:

in nn_model(X, Y, num_iterations, print_cost)

28 ### START CODE HERE ### (~ 2 lines of code)

29 # Forward propagation. Inputs: “X, parameters”. Outputs: “Y_hat”.

—> 30 Y_hat = forward_propagation(X, parameters)

31

32 # Cost function. Inputs: “Y_hat, Y”. Outputs: “cost”.

in forward_propagation(X, parameters)

18 # Implement Forward Propagation to calculate Z.

19 ### START CODE HERE ### (~ 2 lines of code)

—> 20 Z = np.dot(W, X) + b

21 Y_hat = Z

22 ### END CODE HERE ###

<**array_function** internals> in dot(*args, **kwargs)

ValueError: shapes (1,1) and (2,5) not aligned: 1 (dim 1) != 2 (dim 0)