Dealing with helper module issues (Lesson 4)

Source: Deep Learning on Medium


Go to the profile of Avinash

In Lesson 4, we are introduced to PyTorch and Jupyter notebooks. In these lessons we use a custom python module called helper.py and as the name says, it contains bunch of helper functions to display the images etc.

If the file is not available for Python, then you will get either:

Module not found: helper

or

AttributeError: module 'helper' has no attribute 'view_classify'

If you are using Google Colab, you might need to upload this file manually or mount from Google Drive. However, I have a simplest solution. We will just download the module file using wget and rest everything should work without changing any piece of the code.

So, just add this cell in your Jupyter notebook and run it:

!wget -c https://raw.githubusercontent.com/udacity/deep-learning-v2-pytorch/master/intro-to-pytorch/helper.py

This will download the file and place it in current directory where notebook is being run. And will solve all the helper module issues!