Lesson 2 In-Class Discussion ✅

I was thinking of the same.

1 Like

! sudo add-apt-repository ppa:mc3man/trusty-media

  • For this line am getting a prompt asking me for password

! sudo apt-get -y update
! sudo apt-get install -y ffmpeg
! 1sudo apt-get install frei0r-plugins

  • For these I get /bin/sh: 1: 1sudo: not found

These are for the animation in matplotlib. Any fix for this?

I upgraded the fastai in Salamander using:
!pip install fastai --upgrade

import fastai
fastai. version

its showing me fastai. version as : ‘1.0.11’ instead of 1.0.18
Even after the upgrade. I am getting the same not found error for download_images ?

Can anyone help resolve the error?

download_images works in colab but colab has other issues related to memory(Bus Error) and it keeps getting 502 bad gateway.

1 Like

Hmm, kinda like fastai -> pytorch as responder -> starlette. Not quite, but something like that.

I have written a brief blog post based on my notes for lesson 2. Do have a look, and suggest if there are some errors/ missing points.

6 Likes

Can you share some of those thing here
https://forums.fast.ai/t/deep-learning-lesson-2-notes/28772/8
As soon as Jeremy change it to wiki so anyone can edit the notes.

2 Likes

In the part about cleaning up your dataset, Jeremy goes through this code:

losses,idxs = interp.top_losses()  # returns the top losses in the 
top_loss_paths = data.valid_ds.x[idxs]

Now we can pass in these paths to our widget.

fd = FileDeleter(file_paths=top_loss_paths)

And then he mentions that we should run the same thing, but replace valid_ds by train_ds to also cleanup the training set. It seems to me that this isn’t correct. The indici returned by interp.top_losses() are indici into the validation set, so if we only replace valid_ds by train_ds we will select images from our training set based based on the losses of validation images. It seems we should first modify something so that the interp instance is applied to the trainingset instead of the validation set (not sure how though?). Or am I misunderstanding something?

7 Likes

Sure. Let me paste it there too

was same problem,
fastai version : 1.0.14
torch version : 1.0.0.dev20181028
after upgrade everything OK.
now vers:
fastai version : 1.0.18
torch version : 1.0.0.dev20181029

thx ! you using this command to upgrade?

sudo /opt/anaconda3/bin/conda install -c fastai fastai

wondering, how pytorch gets upgraded with this. Maybe sth like this from notebook: !pip install pytorch --upgrade

#1 - I’m not sure if it is just specific to my keyboard (French), but, for me to get the Java console it was CmdOptC, not J as posted.

#2. The code posted just returns me null so far. Am I doing something wrong? Thanks!

you mean javascript console ?

you should get a file to download after running. I only got that after unchecking the adblocker

Allez les bleus

1 Like

Hoy, merci! Ah, yes. I forgot to mention that I am on Safari. You said adblocker but in my preferences I only see settings for Content Blockers, Notifications, and Pop-up Windows.

in chrome for me it was that, if you allow pop ups you get the download file

actually, a did conda install in new conda env.
But, its in FAQ:

  • If using conda please try: conda update conda -y
    conda update -c fastai fastai

Does anybody know where filenames are stored or how to modify data.show_batch() to display the file name as the image title?

I tried using the widget for deleting bad images that was demo’d in class but it didn’t really work in my jupyter lab environment. In addition, I wanted to get a random batch of images rather than the most incorrect because the model isn’t good enough yet for most incorrect to be that useful (35% error rate). Given this data.show_batch() already seems suited to the task. I just can’t seem to find where the file name is stored in the dataloader or dataset

looks interesting, any experience with it? The Github repo seems created 1 month only?

Can we get some tips on how to deal with less number of samples while training an image classifier or may be a model in general ?Also can Jeremy repeat some details about rectangular images vs square images in the training data ?

4 Likes

fastai lib is changing from lesson to lesson, should we stick to a specific release from lesson to lesson or should we always get the latest release?

I have been doing:

pip install --upgrade fastai

Between lessons to keep current. YMMV.