A small taste of Tensorboard thanks to fastai callbacks

TensorBoard is a suite of visualization tools very very useful to debug and optimize deep nets.

Looking inside the fastai repo I found this nice callback file tensorboard.py. I assume it will be introduced sometime in the next lessons, but if you want to start playing with it you need just few steps:

  • Install and run Tensorboard:
    pip install tensorflow==2.0.0-alpha0
    pip install tensorboard
    conda install -c conda-forge tensorboardx 
    tensorboard --logdir **path-to-your-log**/
  • Add these few lines into your notebook:

    1. from fastai.callbacks.tensorboard import *
    2. tboard_path = Path('**path-to-your-log**')
    3. learn.callback_fns.append(partial(LearnerTensorboardWriter, base_dir=tboard_path, name='Smthng'))
  • Fit your model and see the results in tesorboard:

Super Easy!! Thanks again to the nice callback system we can now have traces of our training.
I am sure Jeremy will introduce it more deeply in the future but in the meantime why don’t you try :wink:


This is thanks to @jsa169.

I’m not planning to cover it in this course - but if anyone wants to practice their doc-writing skills, we’d be delighted to accept a PR adding docs for this nice module.


Thanks for posting @fabris ! This looks super useful.

New Video from TF Team :

Inside TensorFlow: Summaries and TensorBoard