Hello everyone, I have been struggling with this particular section of the coding assignment during week 2 i.e Logistic Regression using Neural Network mindset. My issue lies in exercise -8 where i am constantly getting the following error due to which iβm not able to pass the tests.
#---------------------------------------------------------------------------------------------------------------------
AssertionError Traceback (most recent call last)
in
----> 1 model_test(model)
~/work/release/W2A2/public_tests.py in model_test(target)
117 assert type(d[βwβ]) == np.ndarray, f"Wrong type for d[βwβ]. {type(d[βwβ])} != np.ndarray"
118 assert d[βwβ].shape == (X.shape[0], 1), f"Wrong shape for d[βwβ]. {d[βwβ].shape} != {(X.shape[0], 1)}"
β 119 assert np.allclose(d[βwβ], expected_output[βwβ]), f"Wrong values for d[βwβ]. {d[βwβ]} != {expected_output[βwβ]}"
120
121 assert np.allclose(d[βbβ], expected_output[βbβ]), f"Wrong values for d[βbβ]. {d[βbβ]} != {expected_output[βbβ]}"
AssertionError: Wrong values for d[βwβ]. [[ 2.12603857]
[-1.35973515]
[ 1.58122002]
[ 1.04546508]] != [[ 0.00194946]
[-0.0005046 ]
[ 0.00083111]
[ 0.00143207]]
#---------------------------------------------------------------------------------------------------------------------
Interestingly, the same UDF which is used for this calculation passes the test during exercise 5.
Can anyone please help me out and guide me towards how to rectify it?