Hello! I’ve had several problems with my assignment.
First of all sigismoid function test with array didn’t work since a first try, even though with scalar i was inputing it did.
showing this error
sigmoid([ -1, 0, 1, 2]) = [0.73105858 0.5 0.26894142 0.11920292]
AssertionError Traceback (most recent call last)
in
3 # UNIT TESTS
4 from public_tests import *
----> 5 sigmoid_test(sigmoid)
~/work/public_tests.py in sigmoid_test(target)
3
4 def sigmoid_test(target):
----> 5 assert np.isclose(target(3.0), 0.9525741268224334), “Failed for scalar input”
6 assert np.allclose(target(np.array([2.5, 0])), [0.92414182, 0.5]), “Failed for 1D array”
7 assert np.allclose(target(np.array([[2.5, -2.5], [0, 1]])),
AssertionError: Failed for scalar input
some outputs are matching the expected though.
Next i had much more difficulties with computing the cost, mixed up indention, but i have a thought maybe a big restart could help but dont know how to perform it in Jupiter. I would really like someone taking a look into my code and helping me with the restart.
I think maybe my code is affected by something what’s wrong with the sigismoid function not only indentation and the values after many tries are not suiting the solution.
Hope to sort it out soon,
Many thanks!