C3_W2_Collaborative_RecSys_Assignmentt


i dont understand this error i try to solve it more time but the error still occur !!!

1 Like

check your regularization term.

your error is stating you have implemented the regularization term lambda_ incorrectly to J.

refer the hints below the grader cell.

you code is ending at j = j/2

i
regularizationRegularization just squares each element of the W array and X array and them sums all the squared elements. You can utilize np.square() and np.sum().

1 Like


its the last error that occur

1 Like

1 Like

Check your codes for J.
While implementing codes for cost is for non-regularized implementation

and then

for regularization implementation

you are probably doing in the incorrect way of first using the regularized implementation and then applying the non-regularized implementation, hence getting this error.

the same error was still occur

1 Like

tell me all the codes you wrote for J

tell me the first
Step 1. J code where it mention under the loop below ( notice the position of this code is not same as the other two steps as it comes under loop

step 2 then J = J/2

step 3 then regularized implemented J code

Compute the cost without regularization

{moderator edit: code removed}

1 Like

{moderator edit: code removed}

1 Like

this code is incorrect. Did you try to have a look at the hints below the grader cell where you wrote codes.

hints step by step,

this is not required

Incorrect code, you do not require to sum up b to the regularized implementation of cost J

thanks so much for you it graded all tests is pass :smile:

1 Like

@TMosh Thanks Tom Tom for removing the codes.

Salma don’t post codes next time, I only asked for correcting purpose. It is against community guidelines. :slight_smile:

1 Like

Sorry i will be careful for the next time

1 Like

hey DEEPTI i am having the same problem

1 Like

@NATHAN_CHRISTOPHER_M, please see the other thread where you replied.

Hi Salma, could you please share how you made it work? I am facing the same issue.

1 Like

is your issue resolved???