Get losses table from a loaded model

hi

when exploring using notebooks, I usually save models and only fit when a saved version doesn’t exist.

such as in this code

model = ...
learn = ...

path_model = Path(MODEL_DIRECTORY)/'my_model'
if ( path_model.with_suffix('.pth').exists() ):
    learn = learn.load(path_model)
else:
    learn.fit_one_cycle(5, 5e-3)
    learn.save(path_model)

that way it is very fast to Restart Kernel and run all cells.

However I would like to display table losses from a loaded model
image

Maybe there is something to do with recorder

I have given a look to leaner.fit to understand how this table is built but this is not clear to me.

How would you do such thing?