fastbook
fastbook copied to clipboard
Fix LMModel7 callback in Learner (Chapter 12)
Fixes #445
The change is to provide rnn_cbs(alpha=2, beta=1) as the callback for the LMModel7 custom Learner in the main notebook 12_nlp_dive.ipynb and in clean/12_nlp_dive.ipynb. No changes needed for TextLearner as it does this internally.
Also changed the text just before defining the Learner from
We can create a regularized Learner using the RNNRegularizer callback:
to
We can create a regularized Learner and use the rnn_cbs function to generate a list of all the callbacks (ModelResetter, RNNRegularizer and RNNCallback) that we need:
P.S. This matters only if we try learn.fit right after defining the Learner.
Check out this pull request on ![]()
See visual diffs & provide feedback on Jupyter Notebooks.
Powered by ReviewNB