[Lesson 3] Multilabel from folder

Hello!

I tried to create my own multilabel model based on this dataset from Kaggle: https://www.kaggle.com/jutrera/stanford-car-dataset-by-classes-folder

The issue I’m facing is that the labels are in the folder name, such as “AM General Hummer SUV 2000”. Using the ImageDataBunch.from_folder is creating the title as one single label, and there is no label_delim parameter I could use to split the folder name.

Do you have any idea how to handle this kind of labeling?

Thank you,

Sebastien De Spiegeleer

Hi Sebastian,

I’m on my mobile, and can’t check the code and available functions right now. Thinking aloud, I would probably try to parse the folder names (using string substitution and/or RegEx) into a csv file with the image filenames and multi-labels, and then feed the data into fastai library that way.

Yijin