WK#1 C3_W1_Assignment zero one error

The dataset generated from the generator functions is not identical to the expect one.

Falling back to the pre-loaded one.

One error
There was a problem compiling the code from your notebook. Details:
name ‘prob_of_X_given_C’ is not defined
Every line
Score zero

But

My output is lined up with correct outputs so how can this be?

Don’t worry about the “falling back to pre-loaded dataset” issue. Everyone’s code does that. It’s a bug in the assignment.

The grader looks at the cell metadata to see which cells it should compile. If the metadata gets scrambled, erased, or modified, this can confuse the grader.

I suspect this what happened to your function.

Any of these actions can cause issues with the metadata:

  • Downloading the notebook onto some other platform, then uploading it back to Coursera for grading.
  • Deleting a cell and then trying to restore it.
  • Adding new cells to the notebook.

You may need to get a fresh copy of the notebook and start over.

How do I get a fresh copy? I will gladly start over.
Example dog has breed 1 and features: height = 28.63, weight = 21.56, bark_days = 13.00, ear_head_ratio = 0.27

Probability of these features if dog is classified as breed 0: 6.989632718589115e-11
Probability of these features if dog is classified as breed 1: 0.0038267778327024885
Probability of these features if dog is classified as breed 2: 7.959172138800562e-08 This is close to desired output but not identical, so should not be a zero score. Expected Output

Example dog has breed 1 and features: height = 28.63, weight = 21.56, bark_days = 13.00, ear_head_ratio = 0.27

Probability of these features if dog is classified as breed 0: 6.989632718589114e-11
Probability of these features if dog is classified as breed 1: 0.0038267778327024894
Probability of these features if dog is classified as breed 2: 7.959172138800559e-08

Go to the File menu, and Rename your current notebook. This is so you can still reference it later - but you cannot submit it for grading.

Then go to the Help menu and use “Get latest version”.
This will install a new copy of the notebook into your file folder.
Then go to the File → Open menu, and double-click on the notebook that you just installed.

Thank you.
That did it. Got 100% the pain taught me a lesson. haha.

Happy New Year to you and all.