fastai / courses

fast.ai Courses
Apache License 2.0
5.61k stars 2.74k forks source link

dl1 notebooks improvements #222

Closed stas00 closed 6 years ago

stas00 commented 6 years ago

Issues with DL Part 1 notebooks:

  1. lesson1.ipynb

plot_val_with_title is defined twice in adjacent cells

def plot_val_with_title(idxs, title):
    imgs = np.stack([data.val_ds[x][0] for x in idxs])
    title_probs = [probs[x] for x in idxs]
    print(title)
    return plots(data.val_ds.denorm(imgs), rows=1, titles=title_probs)

and 2 cells later:

def plot_val_with_title(idxs, title):
    imgs = [load_img_id(data.val_ds,x) for x in idxs]
    title_probs = [probs[x] for x in idxs]
    print(title)
    return plots(imgs, rows=1, titles=title_probs, figsize=(16,8))

one or the other should probably be deleted?

Thanks.

stas00 commented 6 years ago

moved to https://github.com/fastai/fastai/issues/605