C1_W3 Can't get graded

I keep getting 0 when i submit my assignment.
Renaming and starting from scratch based on the copy created, like offered in previous posts, didn’t resolve the issue.

LAB ID: cjzqngofytfy

Kindly share a screenshot of your submission grader output

Cell #16. Can’t compile the student’s code. Error: AssertionError(‘Not all tests were passed for soft_dice_loss. Check your equations and avoid using global variables inside the function.’,)

Did you check the cell being mentioned here? And do you know what are global variables?

The error is telling you are using a global variable inside a function. So look in the cell 16

Thanks for the reply, I know what they are in general but couldn’t figure where I used one in my code. furthermore - if my mistake is in exercise 5 how come i get 0%?

Because in some assignment, few of exercises or grader cells are related. Can you DM the cell 16 code as screenshot by personal DM. Do not post codes here as it is against community guidelines. Click on my name and then message.


Hello @ittaim11 ,

your dice denominator code is incorrect, notice the denominator in the image below your prediction and true values are squared and those are sumed up.


1 Like

Your’e right!
Thanks a lot.

Happy to help!

Keep learning!!