Currently trying to bring in a custom image dataset as a datablock per here https://fastai1.fast.ai/data_block.html#data_block
Have just completed a new install on conda env (python 3.8.3)
Running fastai version 2.3.1 locallly.
I’m working in Jupyter
I ran
from fastai.vision import *
data = (ImageList.from_folder('UGI_data')
.split_by_folder()
.label_from_folder()
.databunch())
I got this error - name 'ImageList' is not defined
Have tried restarting the kernel, however there was no change.
Any help/advice much appreciated, thank you
Thank you for your time and for pointing what I should have picked up.
The correct datablocks documentation for fastai v2 is here, am I correct?
I have a dataset composed of unlabelled test and train images, all are .png files.
After bringing in the following from fastai.vision.all import * from fastai.vision.core import * from fastai.vision.data import *
I managed to get the image files as follows fnames = get_image_files('UGI_data')
or path = Path('UGI_data') Preformatted textpath.ls()
which gives [Path('UGI_data/testA'),Path('UGI_data/testB'),Path('UGI_data/trainA'),Path('UGI_data/trainB')]
then into a datablock
dsets = dblock.datasets(fnames)
I am unclear as to how I could follow the existing fastai v2 documentation further as the examples use predefined, labelled datasets as far as I can see. If you aware of any v2 documentation that covers working with custom, unlabelled datasets I hope you would point me in the right direction. Thus far I have only been able to find examples covering MNIST, CelebA etc.
Thank you again for your time and advice.