I tried but only see the effect in the method call (second row) with no adjustable parameters, when using partial it is like magnitude had no effect (first row).
(Fun fact: these notebooks are how I get familiar with the code, not the documentation yet ) I’ll look at the rest later when I can (unless someone else can answer your questions.) (@sgugger?)
Cuda() is no longer a transform! (If you’re running the most recent version). It’s automatically assumed if the device (cuda) is available. Try that! (Just passing in Normalize and IntToFloat). I’ll look at it and adjust that notebook tommorow. Nice catch
A related problem (it seems).:
After I define tfms, and gpu_tfms without Cuda() and then execute
dbunch = dsrc.dataloaders(bs=128, after_item=tfms, after_batch=gpu_tfms)
Then do dbunch.show_batch() I get this error:
RuntimeError: expected device cuda:0 but got device cpu
But that is strange for if I look in the dataloaders source
if device = None: device = default.device() AND
if I check in a separate cell in the nb what my default device is by typing default_device() I get
device(type=‘cuda’, index=0)
So what gives? Why does dbunch.show_batch() have a RuntimeError? What am I missing?
OK. Now I am encountering an even more basic problem.
After I run the basic installation scripts when I run
from fastai2.vision.all import *
I get the error cannot import name ‘PILLOW_VERSION’ which points to this line of code:
from PIL import Image, ImageOps, ImageEnhance, PILLOW_VERSION
which seems to exist in this module:
[
/usr/local/lib/python3.6/dist-packages/torchvision/transforms/functional.py]
SO says:
Pillow 7.0.0 removed PILLOW_VERSION , you should use __version__ in your own code instead
Any thoughts on this new error? It just popped up on the latest version of the nb I just downloaded. I did not see this error when I was working with the nb last night.
I see that there is a difference in the installation commands between the two nbs.
Older version says:
import os
!pip install -q fastai2 fastcore torch feather-format kornia pyarrow wandb nbdev fastprogress --upgrade
!pip install torchvision==0.4.2
!pip install Pillow==6.2.1 --upgrade
os._exit(00)
Seems to fix torchvision and Pillow versions (note that error reported with PILLOW_VERSION is only in Pillow 7.0.0) so this could be the cause???. Do not know whether fixing torchvision version is important as well??
There is an issue with DataBlock currently so for the time being I’ve revered to using an older version of fastai2, pre-dataloaders etc. The notebooks all show this change and install the correct version
Major change to DataBlock: Include the transforms in it. The notebooks will be updated shortly
Really appreciate the notebooks you organized and videos you are creating.
Have been wondering how to go about running fastai2 on video data or data with multiple 2d slices of images with variable length. Meaning x is a set of 2d slices composing a 3d volume and between two distinct x’s the number of 2d slices may vary (i.e. one video may have more frames than the other since its a longer shot).
Just a little plug for Dokku as a free/ on-premise option for Heroku buildpacks. I’m using it on a workstation and some rented servers and it’s great PaaS…
After giving it some thought, I rearranged when pose detection will show up. I believe this will be better as the technique uses both of the topics discussed the previous week. (Object and keypoints)