fastai / course-nlp

A Code-First Introduction to NLP course

Home Page:https://www.fast.ai/2019/07/08/fastai-nlp/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Quick Fix if trouble getting an error when assigning wiki_itos in 5-nn-imdb.ipynb

hemphillmc opened this issue · comments

At least in the Google Colab version doc, the line below points to a file that doesn't exist and thus causes an error:

wiki_itos = pickle.load(open(Config().model_path()/'wt103-1/itos_wt103.pkl', 'rb'))

Quick fix is to change the name of directory as shown below:

wiki_itos = pickle.load(open(Config().model_path()/'wt103-fwd/itos_wt103.pkl', 'rb'))

Hope this helps!

Thank you! I am having that exact problem while running that nb in jupyter on a server. I'll try making that change to my notebook. Also, #37 was just merged which made some substantial changes to nb 5 but I'm going to stick to the old one for the moment so I can directly follow along with the lecture.