title: jupyter notebook from GCP instance not able to import wget or fastai
body: <p>I have a VM instance running on google cloud platform. I followed the instructions here: <a href="https://towardsdatascience.com/running-jupyter-notebook-in-google-cloud-platform-in-15-min-61e16da34d52" rel="nofollow noreferrer">https://towardsdatascience.com/running-jupyter-notebook-in-google-cloud-platform-in-15-min-61e16da34d52</a> to setup a Jupyter notebook for the instance. If I open a python3 notebook I can import certain packages (etc., matplotlib), but for some reason if I try to import wget or fastai I receive </p>
  
  <blockquote>
    <p>ImportError: No module named 'fastai'</p>
  </blockquote>
  
  <p>or </p>
  
  <blockquote>
    <p>ImportError: No module named 'wget' </p>
  </blockquote>
  
  <p>The instance was a prebuilt pytorch deep learning setup which is supposed to come with fastai, and wget works within the SSH terminal before any kind of install. I've tried installing wget and fastai anyway with conda and pip commands but neither make these modules accessible in jupyter. I'm assuming since these modules are prebuilt in this instance I need to access/import them differently somehow?</p>
  
  <p>If in the SSH terminal (without any conda/pip install) I ask <code>whereis wget</code>, I receive:</p>
  
  <blockquote>
    <p>wget: /usr/bin/wget /opt/anaconda3/bin/wget
    /usr/share/man/man1/wget.1.gz /usr/share/info/wget.info.gz</p>
  </blockquote>
  
  <p>If in the SSH terminal (without any conda/pip install) I ask <code>whereis fastai</code>, I receive:</p>
  
  <blockquote>
    <p>fastai:</p>
  </blockquote>
  
  <p>How can I get the import to work?</p>
  
  <pre><code>import fastai
  import wget
  </code></pre>
  
  <p>If in my Jupyter notebook I run: </p>
  
  <pre><code>!pip install wget
  import wget
  </code></pre>
  
  <p>I get:</p>
  
  <blockquote>
    <p>/home/me/anaconda3/lib/python3.5/site-packages/pip/_vendor/requests/<strong>init</strong>.py:83:
    RequestsDependencyWarning: Old version of cryptography ([1, 3]) may
    cause slowdown.   warnings.warn(warning, RequestsDependencyWarning)
    Requirement already satisfied: wget in
    /home/me/anaconda3/lib/python3.5/site-packages (3.2)
    --------------------------------------------------------------------------- ImportError                               Traceback (most recent call
    last)  in 
          4 import yaml
          5 get_ipython().system('pip install wget')
    ----> 6 import wget</p>
    
    <p>ImportError: No module named 'wget'</p>
  </blockquote>
  
  <p>Quick update:
  it does seem to be some issue with wget and fastai already being installed. I cannot import, but I can use the modules within my jupyter notebook. So <code>wget.download(stuff)</code> raises a </p>
  
  <blockquote>
    <p>NameError: name 'wget' is not defined error</p>
  </blockquote>
  
  <p>but <code>!wget.download(stuff)</code> works.  </p>
  
  <p>Still would prefer to be able to import. But as is, is there a way to refer to fastai base classes? Right now if I try </p>
  
  <pre><code>class newClass(LearnerCallback):
      new stuff
  </code></pre>
  
  <p>I get:</p>
  
  <blockquote>
    <p>NameError: name 'LearnerCallback' is not defined</p>
  </blockquote>
  
  <p>Which I assume is due to the un-imported fastai. How do I get around this?  </p>