/tensorboard_demos

Make sense of deep neural networks using TensorBoard

Primary LanguageHTMLApache License 2.0Apache-2.0

Make Sense of Deep Neural Networks using TensorBoard

Binder

Getting Started

Note: Notebooks in this repo are written in Python 3 and use TensorFlow (version 1.x). You'll need Jupyter/iPython to run them.

Local installation

Fetch the repo: github.com/PythonWorkshop/tensorboard_demos

git clone git@github.com:PythonWorkshop/tensorboard_demos
cd tensorboard_demos/

Then, choose one of the options below: Conda (if you have Anaconda and conda-env installed), otherwise pip.

Option A: Conda install

  1. Create a conda environment (auto-installs packages as per environment.yml) and activate it:
conda env create
source activate tensorflow
  1. Run notebook:
jupyter notebook tensorboard_basics.ipynb

For troubleshooting, see TensorFlow's Anaconda installation instructions.

Option B: Pip install

  1. Install dependencies first (NumPy, matplotlib, scikit-learn):
pip3 install numpy matplotlib scikit-learn
  1. Install TensorFlow as per instructions for your platform.

  2. Run notebook:

jupyter notebook tensorboard_basics.ipynb

Binder

Binder

If you have trouble getting TensorFlow to work, hit the launch binder badge to run in the cloud. Note that this is an experimental feature.

Running TensorBoard

Follow the notebook to build a neural network and train it. During training, make sure events are logged using tf.summary.FileWriter (code included in demo). Then run TensorBoard, pointing it to the log directory:

tensorboard --logdir=logs

And then open the URL that gets printed, in your browser (typically: http://0.0.0.0:6006).

Explore the structure of the neural network in the Graph tab, and the summaries you reported in the Events tab.