C1_W2_Linear_Regression compute gradient

Hello all foe the second problem in the linear regression compute gradient I keep getting this error when checking my code, any insight or guidance would be greatly appreciated!

AssertionError: Case 1: dj_db is wrong: -0.5 != -2

The most common reason for getting the wrong results is if your code has incorrect indentation.

Python uses indentation to define its code execution blocks.


please explain what is the actually the error about & how do i correct it .

There are two related errors shown. Both of them indicate your compute_gradient() function doesn’t return the correct return values.
First is this pair of results:

The second is that an assert is thrown by the compute_gradient_test() test case function.

You fix it by making your compute_gradient() function work correctly.

Start by checking all of the Hints in the notebook.