Lesson 10 - Train Loss and everything else NAN

Hi there, total noob here.

This is my problem: 2021-06-16_17-13-59

I am trying to build on top of lesson 10, got a .csv from the YAHOO_ANSWERS dataset, and proceeded this way:

def get_x_txt(r): return df.iloc[:,1]
dls = DataBlock(
blocks=TextBlock.from_df(‘test’, seq_len=72),
get_items=get_x_txt, splitter=RandomSplitter(0.1)).dataloaders(df, bs=64)

if I do dls.show_batch(max_n=2) it is all going to look all-right:

but then when I:

learn = language_model_learner(
dls, AWD_LSTM, drop_mult=0.3,
metrics=[accuracy, Perplexity()]).to_fp16()

I get what shown in this screenshot: 2021-06-16_17-13-59
Also, if I do learn.lr_find(), I will get this error:
‘SequentialRNN’ object has no attribute ‘smooth_loss’

I don’t get it, what am I doing wrong?

Thank you
R.

hi, I didn’t see the dataset but first of all, if you are building a language model learner I think you have to set is_lm=True on TextBlock.from_df

1 Like

Ah, of course I missed something that simple! Thank you, you saved my day!