I’m experiencing a grading issue with the Week 1 assignment. When I submit my notebook, I receive an error that says:
“There was a problem compiling the code from your notebook, please check that you saved before submitting. Details: name ‘series_valid’ is not defined.”
I have followed all the instructions carefully and have only modified the code between the designated markers (### START CODE HERE ### and ### END CODE HERE ###) without altering any provided instructions or code outside these markers. In particular:
My train_val_split function correctly defines time_valid and series_valid.
All unittests pass when I run the notebook locally.
I have restarted the kernel, refreshed the notebook, and saved a fresh copy before submitting.
Despite all this, the grader still reports that series_valid is undefined. I suspect this might be due to how the grader compiles the notebook. Has anyone else experienced this issue, or does anyone have further suggestions to resolve it? Please help me Ill send you my code in the DM PLEASE HELP
in the previous comment where I mentioned a linked comment. please refer point7 and point 8 where your codes are incorrect.
You have hard coded the past series. your code would be same as naive forecast except you use 365 as you are calculating from the previous cycle in the original time series. please don’t use any len function for past series or smooth past series.
for smooth past series, use the correct split of series
as window size is 11. As you know 370 is seasonality plus the noise, window size of 11, gives 359, hence the correct split would be
(SERIES[SPLIT_TIME - 370:-359], 11)
you will come across further similar exercise where when series is mentioned you aren’t supposed to use range, but mention the set range assigned to the series which len function can cause issue in these case but that doesn’t mean you cannot use in time series.
In the assignment you worked or will work, understanding the forecast detection is based on a set range and how the time split is determined based on the trend and seasonality.