Using TensorBoard in Jupyter workspaces
Overview
TensorBoard is a tool for visualizing TensorFlow data. TensorBoard operates by reading events files, which contain summary data that generated by TensorFlow. You can visualize your TensorFlow graph, plot quantitative metrics about graph, and show additional data that passes through the graph.
You can use TensorBoard inside your Domino Jupyter workspace by installing and enabling the Jupyter-TensorBoard server extension in your compute environment.
Environment Setup
You will need to create or modify an environment to enable this extension in your Domino workspaces. Read about Compute Environment Management if you aren't already familiar.
In Domino, click Environments in the top navigation bar.
Click Create Environment.
Give the environment an informative name, and then choose a base image that has Python 3.6+ installed. You can use an environment as a base image if it uses this Domino standard:
quay.io/domino/base:standard-py3.6-v1.3+
After selecting the appropriate base image, choosing a visibility setting, and optionally providing a description, click Create Environment to finalize.
The environment will be created and you will be automatically redirected to its Overview page. Scroll down to the Docker Settings and click Edit Dockerfile.
Add the following two lines to the Dockerfile Instructions:
RUN pip install ipython jupyter jupyter-tensorboard --upgrade RUN jupyter tensorboard enable --system
Click Build. You will be redirected to the Revisions page for the environment. If the new revision builds successfully, you are ready to use this environment.
Using Jupyter-TensorBoard
Open the project you want to use with Jupyter-Tensorboard, then click Settings in the left navigation bar.
In the Compute environment panel, use the dropdown menu to choose the environment you created in the previous section. A notification will appear verifying that the new environment is now set.
Click Workspaces in the left navigation bar, then select Jupyter and launch a new workspace.
From the Files tab in the workspace, click New -> Tensorboard.
You can now access the new TensorBoard from the Running tab.
Refer to the TensorBoard README to learn how to start consuming TensorFlow events.
Troubleshooting
If you encounter issues loading Tensorboard initially, ensure that Tensorflow is operating properly first. Loading the UI has a dependency on Tensorflow. Furthermore, by default, Domino's standard compute environments have tensorflow-gpu installed (e.g. pip install tensorflow-gpu). Thus, Tensorboard and Tensorflow will not work on a CPU hardware tier. If you'd like to use Tensorboard on a CPU make sure that CPU optimized Tensorflow is installed (e.g. pip install tensorflow).
Comments
0 comments
Please sign in to leave a comment.