I tried to implement cross-validation in fastai, but I failed.
I have used sklearn to help generate the folds, then train a fastai classifier on each train and validation dataset combination.
Can you tell me in more detail? I divided the data set into 5 folds to train, and when I did the second iteration, I got an error.
This my way to implement Stratified K Fold cross validation with fast.ai and scikitlearn
I think that is ok and easy but I’m a newbie
How does get_transforms work?
have u ever raise an error : out of memory? thanks for advance!
I guess probably you can reduce the batch_size to avoid that error.
I was just asking myself: which is the purpose of cross-validation in this situation? My guess: to get a better estimate of the accuracy of the model in the test_set?
Also what about early stopping if error starts increasing in the validation set, how can we do it?
Regarding your second question you should probably have a look at the EarlyStoppingCallback in the docs.
Is the y in df[‘y’] the tags/label column in the df?
Yes, it is
Thank you muellerzr!