Error in Grading

I submitted the Trigger Word Detection assignment and successfully executed all the functions but the grader is giving me 0/100 and the following error:
Cell #29. Can’t compile the student’s code. Error: NameError(“name ‘X’ is not defined”)

Kindly help me out
Thanks in advance
Sheel

Restart the kernel.
Re-run all of the cells in the notebook.
Then examine every output cell for any error messages.
Then submit the code again.

1 Like

Thanks for the help
It got rectified :slight_smile:

I have the same issue, grading failure, in DLS Course 5, W3A2, error:
“Cell #7. Can’t compile the student’s code. Error: NameError(“name ‘x’ is not defined”).”

I have restarted the kerner, re-run all cells, found no error messages.
It did not work for me.

Are you using a variable named ‘x’ anywhere? Maybe it’s a global variable that the grader doesn’t have access to.

Thank you for replying!

I found the source of this error:
“Cell #7. Can’t compile the student’s code. Error: NameError(“name ‘x’ is not defined”).”

I added cell #7 to plot one row of x values that created an error. Good to know this.
After removing this cell, the error was fixed.

Thanks for your report. Adding cells can make the grader very unhappy.

I ran into the same issue in another exercise, most likely caused by adding a new cell to try something out. I tried to restart the kernel, and that didn’t work. So I revert to the original checkpoint and re-entered my code (without adding new cells), and the submission went through.