Wiki: Lesson 1

I added a link in the original post above. Here you go:

I’ve written a few basic scripts that help with the workflow for setting up problems similar to Cats and Dogs. Deep Learning Utilities

There are three simple scripts:, and I developed these tools because I wanted to very simply experiment with the Lesson 1 image classifier on a variety of different datasets.

Here is a sample work flow: 'bmw' 500 --engine 'bing' --gui 'cadillac' 500 --engine 'google'
mv dataset cars cars/bmw cars/cadillac cars --train .75 --valid .25

I’ve used these on a variety of training exercises. All I need to do is change the path in Lesson1.ipynb and it’s very straight-forward to try out new sets of images.

I’ve added these to GitHub. Please feel free to clone and use. If anyone has questions or feedback, please feel free to let me know.


I use the Google cloud platform to run the jupyter notebook. However, i often face one problem.
The Kernel is always restarting. The error message is “The kernel appears to have died. It will restart automatically.”

Is there something wrong with my GCP set? I wonder if I ran out of memory.

Hi, I discovered the ML course kind of by accident here. A previous question’s answer implies that it’s okay for us lay public people to watch it, that you won’t get in trouble if I do BUT the lecture says to watch it on and not on YouTube for reasons which were highly unclear. However, I can’t find those lessons on

Should I be waiting until they are up on or is it okay to watch them on YouTube?

Hi Kaitlin,

Here is the link for Deep Learning Part 1 lessons at

It’s ok to watch them on YouTube until the videos are posted to the website (possibly later with some edits)
machine learning videos

1 Like

Hi, I am signed into Colaboratory with my gmail account. I loaded the Fastai lesson1 notebook and saved it to my Google Drive. But I can not run any of the cells in the notebook.

I click File > Open recent, and the notebook is loaded from Google Drive.

When I try to run any of the cells in the notebook I get the message:

Running read-only notebooks is not supported.

How can I run the notebook cells?


Hi Hwang,
I am running GCE too, and although there may be some weirdness around GCE (google compute engine) the errors, the most common error I have is the GPU running out of memory. You can lower memory by manually lowering the batch size bs in the ConvLearner constructor.

Hi How can I enable multiple GPUs on fastai?

Is it just me or is Paperspace now requiring security clearance even on the lowest machine after selecting Public Templates. Actually the security block comes on right after selecting Public Templates. This is my 2nd day of waiting for clearance and I am eager to get started. Perhaps they have more customers than they can handle. What are they worried about? North Korean hackers?

I reached the end of the Lesson 1 video, but it stopped at the “Improving our model” section of the Jupyter notebook. Will the rest of the notebook be covered in a later video, or are we supposed to explore the rest of the notebook ourselves?

Encountered the same Paperspace problem, been days and I still can not have access to create even an Ubuntu instance! How long do you guys need to wait to be approved?

Is there a good alternative to Paperspace?


I found out from the first lesson that I have to configure web services like ‘paperspace’. But, I have a laptop with GTX1050, is it not possible to configure this GPU itself and run the programs??

Please help me understand this.

Thank you!

It’s obviously possible with a 1050…

1 Like

I came across the same issue last week when I was trying to set up my machine. I waited about 3 days before I sent a support ticket and they approved my request within 24 hours after.

I am using Google Cloud Computing, I get 300$ credit free when register. I follow this guide for setup. It take 2-3 days for the step increasing GPU quotas. Everything works fine.

1 Like

As long as your GPU has CUDA 3.0 you’re good to go. I has GTX 745 but still works fine.

1 Like

Hi, I had run the lesson 1 notebook earlier on Google Colab without any issue. However yesterday when I tried to re-run it, facing below error.
AxisError: axis 1 is out of bounds for array of dimension 1

The notebook is same as what @manikanta_s put up in this post here

Step: Fine-tuning and differential learning rate annealing

log_preds,y = learn.TTA()
probs = np.mean(np.exp(log_preds),0)
accuracy(probs, y) <<<<< Error in this line

AxisError Traceback (most recent call last)
in ()
----> 1 accuracy(probs, y)

/usr/local/lib/python3.6/dist-packages/fastai/ in accuracy(preds, targs)
      4 def accuracy(preds, targs):
----> 5     preds = np.argmax(preds, axis=1)
      6     return (preds==targs).mean()

/usr/local/lib/python3.6/dist-packages/numpy/core/ in argmax(a, axis, out)
   1003     """
-> 1004     return _wrapfunc(a, 'argmax', axis=axis, out=out)

/usr/local/lib/python3.6/dist-packages/numpy/core/ in _wrapfunc(obj, method, *args, **kwds)
     50 def _wrapfunc(obj, method, *args, **kwds):
     51     try:
---> 52         return getattr(obj, method)(*args, **kwds)
     54     # An AttributeError occurs if the object does not have

AxisError: axis 1 is out of bounds for array of dimension 1

Any idea why I am getting this error now?


1 Like

Well, looks like ‘log_preds’ should be used instead of ‘probs’. Is this a recent change in the accuracy function? Thanks.

1 Like


Thanks for the reply!
I am new to these GPU configurations. Could you please clarify my below thoughts.

  1. We use WEB services for training when one does not have a GPU in his\her PC.
  2. If the appropriate GPU is available in PC, we do not need to use any WEB services. Right? We just have to configure the GPU available on PC for training.

If my understanding is correct, how do I configure GPU on my laptop for trainin g?

Thank you!