Hi @sgugger, based on your advice, I used following logic to concatenate two ImageLists:
data_wiki = (ImageList.from_df(df_age, path, cols=['full_path'], folder ='../wiki-face-data/wiki_crop/wiki_crop/').split_none().label_from_df(label_cls=FloatList)) .add(ImageList.from_folder(path_utk).split_none().label_from_func(extract_age, label_cls=FloatList)) .split_by_rand_pct(0.2, seed=42) .transform(tfms, resize_method=ResizeMethod.CROP, padding_mode='border', size=224) .databunch(bs=64*2,num_workers=0) .normalize(imagenet_stats)
But I got below error:
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-33-b6c65e6de23c> in <module>()
7 symmetric_warp(magnitude=(-0.1,0.1)) ])
8
----> 9 data_wiki = (ImageList.from_df(df_age, path, cols=['full_path'], folder ='../wiki-face-data/wiki_crop/wiki_crop/').split_none().label_from_df(label_cls=FloatList)).add(ImageList.from_folder(path_utk).split_none().label_from_func(extract_age, label_cls=FloatList)).split_by_rand_pct(0.2, seed=42).transform(tfms, resize_method=ResizeMethod.CROP, padding_mode='border', size=224).databunch(bs=64*2,num_workers=0).normalize(imagenet_stats)
/opt/conda/lib/python3.6/site-packages/fastai/data_block.py in _inner(*args, **kwargs)
461 assert isinstance(fv, Callable)
462 def _inner(*args, **kwargs):
--> 463 self.train = ft(*args, from_item_lists=True, **kwargs)
464 assert isinstance(self.train, LabelList)
465 kwargs['label_cls'] = self.train.y.__class__
TypeError: add() got an unexpected keyword argument 'from_item_lists'
How to resolve this error?
Best Regards
Abhik