Hi there!
I went ahead and managed to get through the whole pipeline of DataFrame -> TabularDataBunch -> TabularDataModel unharmed, but now I’m a bit stuck (also due to the considerable differences of 0.7 from the MOOCs to 1.0).
I’m basically at the point of
learn = get_tabular_learner(data, layers=[200,100], metrics=accuracy)
learn.fit(3, 1e-2)
…which nicely trains me a model where I’m happy with over/underfitting and accuracy.
And now I’m stuck. The docs basically end there, but how do I use the model to predict new data? learn.predict()
gives me an error (AttributeError: 'Learner' object has no attribute 'predict'
) and even if it worked, it only works with the training and validation set.
I’d like to get a prediction from the model from brand new input. I’ve read some stuff on the forums already that seems applicable (especially Single Prediction with NLP example ), but as far as I understand, the TabularDataBunch and -Learner do some “magic” under the hood such as looking up embeddings and do some kinds of normalization.
If I have a new input event now that wasn’t part of any of the original [test,train,validation] sets, how can I apply the same transformations to the raw data and get a single or batch prediction from my newly trained model?
Thanks in advance,
Dominik