I could never run the complete notebook on Coursera since the kernel kept terminating in Ex6. So, I downloaded the whole assignment to run locally to test my code.
However, when running on the local machine, my gram_matrix function failed with the wrong values even though it passed when running in Coursera’s lab environment.
This is the output I got when running the notebook on my local machine.
You will need to have the same versions of the libraries and frameworks used by Coursera. Please read this guide for the local machine and this for Colab.
This can mean that there can something be possibly wrong with your code. And if so, even if you run the assignment locally (which is only recommended after you passed the assignment in the coursera environment), you could still possibly fail the autograder.
It is.
So imagine, you are writing code which could be exceeding that resource on Coursera, but will work on your local, because essentially you have a lot more resource on your local. When you’ll put the assignment back on Coursera for grading, it still has to run in that limited resource for grading, hence, the code could fail.
Thanks @Mubsi and @saifkhanengr, for your advice. So, I figured out that my code was wrong, which made the notebook run out of memory and stuck after executing cell 26. I changed my code and reran the whole notebook. I got better results and no issues throughout the assignment. Unfortunately, when I submitted my revised notebook, I got this vague feedback: Sorry, your submission was incorrect. Please try again. Expecting value: line 1 column 1 (char 0) I am not sure what to do. Please advise. Thanks