C1-W3 lab predict function

Hi Im getting an error running the predict function and not sure where the problem lies:
my code:
{moderator edit: code removed}

Stack trace:

AssertionError Traceback (most recent call last)
—> 11 predict_test(predict)

~/work/public_tests.py in predict_test(target)
69 raise ValueError(“Did you apply the sigmoid before applying the threshold?”)
70 assert result.shape == (len(X),), f"Wrong length. Expected : {(len(X),)} got: {result.shape}"
—> 71 assert np.allclose(result, expected_1), f"Wrong output: Expected : {expected_1} got: {result}"
73 b = -1.7

AssertionError: Wrong output: Expected : [1.0, 1.0, 1.0, 0.0, 1.0, 0.0, 0.0, 1.0] got: [0. 0. 0. 0. 0. 0. 0. 1.]

First, please don’t post your code on the forum. That’s not allowed by the Code of Conduct.
I’ll edit your message to remove the code.
If a mentor wants to see your code, we’ll contact you with instructions.

As a hint, please check whether you have used correct indentation within the function. That’s how Python defines code blocks.

Another thing to try: Change your code that uses the if-statement, and write it as a regular code block (not inline).

that didn’t work - is the code correct tho?

If you get the wrong results, your code isn’t correct.