Lesson 1 discussion

@jeremy - Thanks for clarifying. I did notice the part where it said “for display later”. However, I was not sure if this was the only purpose.

I think there is something about vgg that I did not understand until today, but I’d like to confirm it here:

The vgg model is already trained, meaning it has all the weights already to apply to many classification problems. Finetune means to classify it to fewer classes (like cats and dogs or 10 cases in statefarm problem). Then it makes sense to me that we are ‘retraining’ vgg for the statefarm problem. Somehow the word finetune is counterintuitive to me. I thought it means the opposite.

1 Like

It is probably most suitable for image classification problems. When you normally retrain (or fine tune) - we are retraining for new dense layer after popping out the last dense layer (originally 1000 categories). The convolution layers are not touched (so far in the class) and only the dense layers’s weights are recalculated … you can retrain the last layer or layers preceding it up until the last layer. Yep fine tune sounds counter intuitive here but it means to fine tune to your classification problem.

2 Likes

To help me with teaching in the future, can you guys tell me what feels counter-intuitive about the word ‘fine-tune’, and how you would explain it to deep learning new-comers?

1 Like

May be something like “adapt(numClasses)”?

2 Likes

It could just be me. I feel like finetune means making something more complicated. I thought the word ‘fine’ means further classify, like i start with 2 classes: dogs and cats, now I want to further classify them into more categories.

I am facing with an error in Lesson 1 Notebook

ImportError: cannot import name count_nonzero

I am using python 2.7.13 (Anaconda) on Mac OS 10.12, with skicit-learn 0.19 dev

Before I was using skicit-learn 0.14.1 (default from conda install skicit-learn) and had an error of “cannot import name TNSE”.

In fact, when I tried with t2.large image, I found two errors (again in Lesson 1 notebook)

  1. cannot import cv2

then I tried conda install opencv

run again then I have this error:

cannot import name ReduceLROnPlateau

I am trying out lesson 1 on a p2.xlarge AWS instance type and launched the AMI number: ami-bc508adc and got the same error “cannot import cv2” when trying to run the command:

import utils; reload(utils)
from utils import plots

Ran the same steps to install opencv using the conda command and got the same “cannot import name ReduceLROnPlateau” error.

I checked out the version of Keras and it has version 1.1.0 installed.

Do we need a later version of Keras?

1 Like

In fact, you can install opencv3 instead of opencv2 (they both can be imported by calling import cv2 - wonderful).

However, you might have another error.

I fixed it by updating keras to version 1.2.0 via pip. Now seems to work fine

You mean, you keep to use opencv2 with keras 1.2.0? I installed keras today and in fact it is already 1.2.0.

I was stuck with “cannot import name ReduceLROnPlateau” issue too. I forced the upgrade of keras with “pip install git+git://github.com/fchollet/keras.git --upgrade” and now, I do not get this issue.

HI all, i am new, is this lesson running on CPU ubuntu ?

You can simply comment out the line ‘import cv2’ in utils.py. Sorry we accidentally left that in from an earlier version!

5 Likes

You should follow through the lessons in the order shown here: http://course.fast.ai/lessons/lessons.html . The first one shows the required setup, which will answer this question for you (in short - GPU Ubuntu using a custom AMI we created for the course)

Hi, is it possible to make the videos available as files that can be downloaded and viewed offline?

This would make it possible for people to watch them e.g. on a train without wifi.

Cheers

You can download them directly from youtube.

if u download from youtube just change http to ss : this ex ssyoutube.com/watch?v=8rjRfW4JM2I

3 Likes

Neat trick! Another good option is https://rg3.github.io/youtube-dl/ . Also recent versions of the youtube app (at least on android) let you download.

1 Like