You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
data_clas = (TextList.from_folder(path, vocab=data_lm.vocab)
#grab all the text files in path
.split_by_folder(valid='test')
#split by train and valid folder (that only keeps 'train' and 'test' so no need to filter)
.label_from_folder(classes=['neg', 'pos'])
.filter_missing_y() #the error is the same even comments this line
#label them all with their folders
.databunch(bs=bs))
data_clas.save('tmp_clas')
KeyError Traceback (most recent call last)
/usr/anaconda/envs/pytorch10/lib/python3.7/site-packages/fastai/data_block.py in process_one(self, item)
277 def process_one(self,item):
--> 278 try: return self.c2i[item] if item is not None else None
279 except:
KeyError: 'unsup'
...
exception: Your validation data contains a label that isn't present in the training set, please fix your data.
The text was updated successfully, but these errors were encountered:
data_clas = (TextList.from_folder(path, vocab=data_lm.vocab)
#grab all the text files in path
.split_by_folder(valid='test')
#split by train and valid folder (that only keeps 'train' and 'test' so no need to filter)
.label_from_folder(classes=['neg', 'pos'])
.filter_missing_y() #the error is the same even comments this line
#label them all with their folders
.databunch(bs=bs))
data_clas.save('tmp_clas')
KeyError Traceback (most recent call last)
/usr/anaconda/envs/pytorch10/lib/python3.7/site-packages/fastai/data_block.py in process_one(self, item)
277 def process_one(self,item):
--> 278 try: return self.c2i[item] if item is not None else None
279 except:
KeyError: 'unsup'
...
exception: Your validation data contains a label that isn't present in the training set, please fix your data.
The text was updated successfully, but these errors were encountered: