tensorflowkerastensorboardx

How to use the What If Tool (WIT) provided by google in my Keras Model?


I use the Tensorboard callback and I am able to access all the graphs provided but how to use the What If Tool in the Tensorboard environment. I went through the official Google post but could not figure out much. Could someone please outline the different steps to be followed from a normal Tensorboard callback?


Solution

  • If you want to use WIT for a keras model, check out the information on using WIT inside of jupyter or colab notebooks, where you can write a wrapper for your keras model to use it with WIT directly in the notebook.

    documentation: https://github.com/tensorflow/tensorboard/tree/master/tensorboard/plugins/interactive_inference#notebook-mode-details

    a colab example of wrapping a Keras model to use with WIT: https://colab.research.google.com/github/pair-code/what-if-tool/blob/master/WIT_Toxicity_Text_Model_Comparison.ipynb